Home   Help Search Login Register  

Author Topic: explain me plz  (Read 462 times)

0 Members and 1 Guest are viewing this topic.

Offline Blanco

  • Former Staff
  • ****
explain me plz
« on: 17 Jan 2003, 22:56:28 »
Plz, correct me if I wrong...

NOT is the same as !

IF is the same as ?

THEN is the same as :

OR is the same as ||

but...

ELSE is the same as  ???


Search or search or search before you ask.

Offline Sui

  • Former Staff
  • ****
    • OFPEC
Re:explain me plz
« Reply #1 on: 18 Jan 2003, 00:45:00 »
Yeah... kind of ;)

the ? : statement is kind of the same as an IF THEN statement, the exception being you can't put an ELSE on the end.

However, due to BIS's great genius... you can now use the syntax:

if (condition) then {command} else {othercommand}

So for example:

if (alive Bob) then {[Bob] ordergetin true} else {unassignvehicle Bob}

So that line will see if Bob is alive, and tell him to get in the vehicle. If he's dead, it'll unassign bob from the vehicle ;)

Offline Blanco

  • Former Staff
  • ****
Re:explain me plz
« Reply #2 on: 18 Jan 2003, 00:53:50 »
aha... :D thx
Search or search or search before you ask.