Posted by Ryan on July 20, 1998 at 22:44:41:
OK, I'm in the process of writing my first real cog (all the others were VERY simple) and I have a few questions. What I want to do is have the sky texture change during the level. There's one catch though--the "daytime" sky is scrolling. Here's what code I have: (a button activates it for now)
code
startup:
SlideHorizonSky(5, 5); // Daytime sky is scrolling // upon level start
Return;
# .................................................................................
activated:
SetWallCel(switch0, 1);
SetSurfaceMat(sky0, nightsky);
SlideHorizonSky(0, 0);
Return;
end
Will the second SlideHorizonSky with 0, 0 override the first, or should I use 2 cogs: 1 which scrolls the sky and the other which changes the texture and sends a message to the 1st cog, telling it to Sleep. By the way, will SendMessage(Sleep(cogname, -1)) stop a cog indefinitely?
Ryan