PDA

View Full Version : Cutscene cog debugging...



herb
10-09-2000, 05:18 AM
Here's the deal.. I have my ghost, my walkplayer, and my console in an untextured box of doom. I have the frames set on the ghost and the cog applied to the ghost.. here is the cog:


# Moves a camera around when the thing
# gets activated
#Created by Hebedee
#Not supported by lucasarts
#
#


symbols
message activated
thing cam
thing console
thing player local
flex camspeed

int done=0 local
int Player local
int check local

end

code
activated:

if (done == 0)
{
check = GetSenderRef();
if (check == console)
{
player = GetLocalPlayerThing();
SetActorFlags(player, 0xa00000);
StopThing(player);
SetCameraFocus(0, cam);
MoveToFrame(cam, 1, camspeed);
sleep(1.2);
MoveToFrame(cam, 2, camspeed);
sleep(0.2);
MoveToFrame(cam, 3, camspeed);
sleep(0.2);
MoveToFrame(cam, 4, camspeed);

sleep(0.2);
MoveToFrame(cam, 5, camspeed);
sleep(0.2);
MoveToFrame(cam, 6, camspeed);
sleep(0.2);
MoveToFrame(cam, 7, camspeed);
sleep(0.2);
MoveToFrame(cam, 8, camspeed);
MoveToFrame(cam, 9, camspeed);
sleep(1.2);
SetCameraFocus(0, player);
CycleCamera();
DestroyThing(cam);
ClearActorFlags(Player, 0xa00000);
}
}

return;

end

Whats wrong with it?!



------------------
I'm better than you!
(The Pit) (http://outpostd34.com/thepit)
It 0wnz0rz j00

Hideki
10-09-2000, 06:52 AM
Simplify a bit, so problem might pop up.
Use linkid for checking things


thing console linkid=0

activated:

if(!done)
{
if(GetSenderID() == 0)
{
player = GetSourceRef();
SetActorFlags(player, 0xa00000);
StopThing(player);
SetCameraFocus(0, cam);

MoveToFrame(cam, 1, camspeed);
Sleep(1.2);

for(i=2; i<=9; i++)
{
MoveToFrame(cam, i, camspeed);
if(i != 8) Sleep(0.2);
}

Sleep(1.2);

SetCameraFocus(0, player);
CycleCamera();
DestroyThing(cam);
ClearActorFlags(Player, 0xa00000);
}



Other than that, you set the path all properly?
And you need to destroy the cam?

------------------
http://millennium.massassi.net/ - Millennium

herb
10-09-2000, 06:54 AM
I guess I dont need to destroy it..

lordvader
10-10-2000, 05:31 PM
Hey Hebedee! Take the Yun startup cog, and change the startup message to activated.