View Single Post
Old 09-11-2006, 08:48 PM   #4
lassev
cryptoscripter
 
lassev's Avatar
 
Join Date: Jun 2002
Location: Finland
Posts: 1,087
Something like this:

Code:
if ( $get( FLOAT, "open") = 1$ )
	{
		rem ( "case 1" );
		affect ( "door", /*@AFFECT_TYPE*/ FLUSH )
		{
			rotate ( < 0.000 0.000 0.000 >, 1000.000 );
		}

		set ( "open", "0" );
	}


else (  )
	{
		rem ( "case 2" );
		affect ( "door", /*@AFFECT_TYPE*/ FLUSH )
		{
			rotate ( < 0.000 90.000 0.000 >, 1000.000 );
		}

		set ( "open", "1" );
	}
That code could be something of a Frankenstein; I just put it together from bits and pieces, but it should give some ideas.

You gotta get your syntax right first, then logic and such things.

And declaring variables is essential. It guarantees no typos and also JA has a limited amount of variables allowed (32 per type or something), so requiring declaring makes it easier to keep track of them. Although I can't imagine anybody needing 32 variables at the same time in JA...


Frozen by ICARUS
lassev is offline   you may: quote & reply,