here's what i have so far
-----------------
# Jedi Knight Cog Script
#
# GAT_Elevator.cog
#
# An cog that controls four forcefield at the base of the elevator,
# the elevator itself, and the quad doors at the top
#
#
# [GAT]
#
# (C) This cog is not made by LucasARts Entertainment Co.
# ====================================================================================
symbols
message startup
message arrived
message entered
thing door0 linkid=0
thing door1 linkid=1
thing door2 linkid=2
thing door3 linkid=3
thing elevator
surface force0a mask=0x408
surface force0b mask=0x408
surface force1a mask=0x408
surface force1b mask=0x408
surface force2a mask=0x408
surface force2b mask=0x408
surface force3a mask=0x408
surface force3b mask=0x408
surface callbutton //calls the elevator to level
flex speed=5.0 //the speed for the elevator and the quad doors
flex sleeptime=5.0 //the time the doors will remain open
sector doorsector0 local
sector doorsector1 local
sector doorsector2 local
sector doorsector3 local
sector elevatorsector local
int doorstatus local
int movestatus local
int switch local
end
## code Section
code
//-------------------------------------------------------------------------------
startup:
// This section is for the four forcefield
SetSurfaceFlags(force0a,0);
SetSurfaceFlags(force0b,0);
SetAdjoinFlags(force0a,7);
SetAdjoinFlags(force0b,7);
SetFaceGeoMode(force0a,0);
SetFaceGeoMode(force0b,0);
SetSurfaceFlags(force1a,0);
SetSurfaceFlags(force1b,0);
SetAdjoinFlags(force1a,7);
SetAdjoinFlags(force1b,7);
SetFaceGeoMode(force1a,0);
SetFaceGeoMode(force1b,0);
SetSurfaceFlags(force2a,0);
SetSurfaceFlags(force2b,0);
SetAdjoinFlags(force2a,7);
SetAdjoinFlags(force2b,7);
SetFaceGeoMode(force2a,0);
SetFaceGeoMode(force2b,0);
SetSurfaceFlags(force3a,0);
SetSurfaceFlags(force3b,0);
SetAdjoinFlags(force3a,7);
SetAdjoinFlags(force3b,7);
SetFaceGeoMode(force3a,0);
SetFaceGeoMode(force3b,0);
//This sector is for the quad doors
doorsector0=getthingsector(door0);
doorsector1=getthingsector(door1);
doorsector2=getthingsector(door2);
doorsector3=getthingsector(door3);
sectoradjoins(doorsector0, 0);
sectoradjoins(doorsector1, 0);
sectoradjoins(doorsector2, 0);
sectoradjoins(doorsector3, 0);
//This sector is for the elevator
elevatorsector=getthingsector(elevator);
return;
//-------------------------------------------------------------------------------
entered:
If (
------------------
I'm stumped on how to go on, what the cog is suported to do is the four force field at the bottom where the elevator is at is off untill the player enters the sector that the elevator is in, then after a pause, of maybe few seconds, the force field actives, and the elevator go to the next frame which would be frame 1.
When the elevator reaches frame 1, it pauses untill the four doors above it opens completely, then the elevator go to the next frame which is frame 2. Next it pauses a bit there then head back down to frame 1. When it hit frame 1, the four doors start to close, and the elevator head on down to the bottom floor where the four force field is at.
When it reaches the bottom floor the four force field turns off and the player can eighter exit, or enter it.
Finaly there is one button at the top that calls the elevator to the top.
Now i'm stuck on how to do some of this. So can some one please help.
-----------------
# Jedi Knight Cog Script
#
# GAT_Elevator.cog
#
# An cog that controls four forcefield at the base of the elevator,
# the elevator itself, and the quad doors at the top
#
#
# [GAT]
#
# (C) This cog is not made by LucasARts Entertainment Co.
# ====================================================================================
symbols
message startup
message arrived
message entered
thing door0 linkid=0
thing door1 linkid=1
thing door2 linkid=2
thing door3 linkid=3
thing elevator
surface force0a mask=0x408
surface force0b mask=0x408
surface force1a mask=0x408
surface force1b mask=0x408
surface force2a mask=0x408
surface force2b mask=0x408
surface force3a mask=0x408
surface force3b mask=0x408
surface callbutton //calls the elevator to level
flex speed=5.0 //the speed for the elevator and the quad doors
flex sleeptime=5.0 //the time the doors will remain open
sector doorsector0 local
sector doorsector1 local
sector doorsector2 local
sector doorsector3 local
sector elevatorsector local
int doorstatus local
int movestatus local
int switch local
end
## code Section
code
//-------------------------------------------------------------------------------
startup:
// This section is for the four forcefield
SetSurfaceFlags(force0a,0);
SetSurfaceFlags(force0b,0);
SetAdjoinFlags(force0a,7);
SetAdjoinFlags(force0b,7);
SetFaceGeoMode(force0a,0);
SetFaceGeoMode(force0b,0);
SetSurfaceFlags(force1a,0);
SetSurfaceFlags(force1b,0);
SetAdjoinFlags(force1a,7);
SetAdjoinFlags(force1b,7);
SetFaceGeoMode(force1a,0);
SetFaceGeoMode(force1b,0);
SetSurfaceFlags(force2a,0);
SetSurfaceFlags(force2b,0);
SetAdjoinFlags(force2a,7);
SetAdjoinFlags(force2b,7);
SetFaceGeoMode(force2a,0);
SetFaceGeoMode(force2b,0);
SetSurfaceFlags(force3a,0);
SetSurfaceFlags(force3b,0);
SetAdjoinFlags(force3a,7);
SetAdjoinFlags(force3b,7);
SetFaceGeoMode(force3a,0);
SetFaceGeoMode(force3b,0);
//This sector is for the quad doors
doorsector0=getthingsector(door0);
doorsector1=getthingsector(door1);
doorsector2=getthingsector(door2);
doorsector3=getthingsector(door3);
sectoradjoins(doorsector0, 0);
sectoradjoins(doorsector1, 0);
sectoradjoins(doorsector2, 0);
sectoradjoins(doorsector3, 0);
//This sector is for the elevator
elevatorsector=getthingsector(elevator);
return;
//-------------------------------------------------------------------------------
entered:
If (
------------------
I'm stumped on how to go on, what the cog is suported to do is the four force field at the bottom where the elevator is at is off untill the player enters the sector that the elevator is in, then after a pause, of maybe few seconds, the force field actives, and the elevator go to the next frame which would be frame 1.
When the elevator reaches frame 1, it pauses untill the four doors above it opens completely, then the elevator go to the next frame which is frame 2. Next it pauses a bit there then head back down to frame 1. When it hit frame 1, the four doors start to close, and the elevator head on down to the bottom floor where the four force field is at.
When it reaches the bottom floor the four force field turns off and the player can eighter exit, or enter it.
Finaly there is one button at the top that calls the elevator to the top.
Now i'm stuck on how to do some of this. So can some one please help.
Echoman: If I can create energy from stupidity, the world's power supply will never end...