Massassi Forums Logo

This is the static archive of the Massassi Forums. The forums are closed indefinitely. Thanks for all the memories!

You can also download Super Old Archived Message Boards from when Massassi first started.

"View" counts are as of the day the forums were archived, and will no longer increase.

ForumsCog Forum → Lightswitch
Lightswitch
2002-12-21, 4:07 AM #1
Dould someone give the code to turn the geo of some specified surfaces to 4, then back to 0. Thankyou.
Daddy, why doesn't this magnet pick up this floppy disk?
2002-12-21, 4:48 AM #2
Here. Just for you. [http://forums.massassi.net/html/tongue.gif]
Code:
#Jedi Knight Cog Script
#
# Not really a lightswitch cog, I don't see how...
#
# [DP]
#
symbols
surface          change              nolink
surface          change1             nolink
surface          change2             nolink
surface          change3             nolink
surface          change4             nolink
surface          switch

int              i                   local

message          activated

end

# ........................................................................................

code

Activated:
   For(i=0;i<5;i=i+1)
      SetFaceGeoMode(change, 4-GetFaceGeoMode(change));
   Return;

end

When adding more surfaces, make sure they follow after 'change4' (ex change5), have the 'nolink', and you increase 'i' in the For statement.

------------------
The Sniper Missions. Current project, The Sniper Missions

The Magician Saber System.

[This message has been edited by Descent_pilot (edited December 21, 2002).]
Major projects working on:
SATNRT, JK Pistol Mod, Aliens TC, Firearms

Completed
Judgement Day (HLP), My level pack
2002-12-21, 4:53 AM #3
Just for me? Thanks. I've heard some things about how bad For() loops are. Is it safe to use it?
Daddy, why doesn't this magnet pick up this floppy disk?
2002-12-21, 5:12 AM #4
The only bad thing about a for() loop is if you start counting up towards the millions, it can cause JK to pause for a half a second. 5 isn't gonna hurt even a 286. [http://forums.massassi.net/html/tongue.gif]
-Hell Raiser
2002-12-21, 5:19 AM #5
Thanks for the info. [http://forums.massassi.net/html/smile.gif]

[This message has been edited by Axle (edited December 21, 2002).]
Daddy, why doesn't this magnet pick up this floppy disk?
2002-12-21, 7:20 AM #6
Quote:
<font face="Verdana, Arial" size="2">Originally posted by Axle:
I've heard some things about how bad For() loops are. Is it safe to use it?</font>


WTF? For() loops are perfectly safe. The only time you might encounter problems is if your trying to run HasLOS() on every obejct in a level . . . or something like that . . . as long a the action your performing in the loop is farily easy, the loop itself wont case any problems.
And when the moment is right, I'm gonna fly a kite.

↑ Up to the top!