Home   Help Search Login Register  

Author Topic: problem with thislist syntax...  (Read 646 times)

0 Members and 1 Guest are viewing this topic.

Offline bedges

  • Administrator
  • *****
    • OFPEC The Editing Center
problem with thislist syntax...
« on: 14 Jun 2005, 12:30:12 »
i have a trigger covering the map, east present, on activation

Code: [Select]
all_east = thislist
fine. then in the init.sqs file i have the lines

Code: [Select]
{_x setskill 1} foreach list all_east
{_x setface "enemy"} foreach list all_east

the second line is just to check the first is actually working. the second isn't - the loons' faces are all different. if i manually put the setface command into a loon's init field, fine, it works, so it's not the face.

what's wrong with the syntax above?

Offline Blanco

  • Former Staff
  • ****
Re:problem with thislist syntax...
« Reply #1 on: 14 Jun 2005, 12:40:54 »
Remove the list command in your code.

Code: [Select]
{_x setskill 1} foreach all_east
Only when you name your trigger in the namefield you have to use the list command.
Also put a 1-5 sec delay in the beginning, the trigger needs a short time to store all units.
« Last Edit: 14 Jun 2005, 12:44:14 by Blanco »
Search or search or search before you ask.

Offline bedges

  • Administrator
  • *****
    • OFPEC The Editing Center
Re:problem with thislist syntax...
« Reply #2 on: 14 Jun 2005, 12:43:42 »
hmmm, well the syntax is now correct - cheers ;) - but it still won't activate from the init.sqs file. i stuck it in the trigger itself and it works no problem, so i think i'll leave it there for the time being.

thanks again.

edit - heh, that's what it was - not enough time - i've put a pause into the init file, and presto, about 3 seconds in, everyone has the right face.

problem solved ;)
« Last Edit: 14 Jun 2005, 12:45:17 by bedges »

Offline Blanco

  • Former Staff
  • ****
Re:problem with thislist syntax...
« Reply #3 on: 14 Jun 2005, 12:49:58 »
Quote
problem solved

Do it.  :)
Search or search or search before you ask.