Home   Help Search Login Register  

Author Topic: How many lines does @ last for  (Read 1082 times)

0 Members and 2 Guests are viewing this topic.

Offline U_Z

  • Members
  • *
How many lines does @ last for
« on: 31 Aug 2006, 07:07:21 »
How many lines does @ last for?
@(true)
[] exec "rofl.sqs"
[] exec "Do_I_get_execed_too.sqs"
[] exec "what_about_me?.sqs"

Offline bedges

  • Administrator
  • *****
    • OFPEC The Editing Center
Re: How many lines does @ last for
« Reply #1 on: 31 Aug 2006, 08:36:44 »
hmmm.... just so you understand what this @ command does, it waits until the condition stated after it is true. so. my chopper is patrolling the skies, i want there to be a rescue attempt if it ever goes down. i could write a script that started

Code: [Select]
@not (canmove my_chopper)
*rescue code*

the script would not continue to the *code* part until the chopper was incapacitated.

so to answer the question, @ lasts for one line.

Offline Trapper

  • Honoured Contributor
  • ***
  • I'm a llama!
Re: How many lines does @ last for
« Reply #2 on: 31 Aug 2006, 18:33:46 »
...and OFP interpretes scripts line by line, so it lasts forever until the condition is met.

Offline Chris Death

  • Former Staff
  • ****
  • Finally Death's gonna get ya
    • OFPEC
Re: How many lines does @ last for
« Reply #3 on: 01 Sep 2006, 03:41:34 »
OK, when i read your question and the answers to it i must admit they're totally right, but
the way you asked your question and considering a probability of you didn't understand
anything else but the straight answer to your question i will explain it once more.

@something

will wait for something

This means the script pauses there and will not continue.

Nothing below @something will run, until something happens (or become true).

Once something happens (or becomes true), the script continues to the next line.
Then to the next and the next .... until you tell the script that it should wait like (@something_else).

@bedges and Trapper - i don't wanna be a smartass, but i got some experience with ppl new to editing
getting answers featuring more than 'no' or 'yes' or 'one' or 'two'.  :D Both of you where absolutely right
with your answers but it could be the tiny little bit too much (i don't want to exclude myself aswell from
that theory btw - cought me more than once getting from pontius to pilatus while explaining simple things)  :yes:

@U_Z - if you understood everything from first answer by bedges and think now i'm trying to downgrade your
level of understanding then i'm really sorry for that, just felt there were some gaps to be closed before you
could probably get mislead for some time until you realize it's not like you thought.

And to all - soz for bothering with so much words for a simple answer, but i'm just finding my way back into
ofp-editing and into helping ppl on forums. 

~S~ CD
Dont argue with idiots....they will bring you down to their level and beat you there with experience.

How to use Waypoint type Scripted

Offline macguba

  • Former Staff
  • ****
    • macguba's operation flashpoint page
Re: How many lines does @ last for
« Reply #4 on: 01 Sep 2006, 11:30:34 »
It's good to have you back CD.
Plenty of reviewed ArmA missions for you to play

Offline U_Z

  • Members
  • *
Re: How many lines does @ last for
« Reply #5 on: 03 Sep 2006, 10:14:00 »
Thanks everyone. I guess I simpily didn't understand exactly what @did.