Page 1 of 1
local.player=parm.other
Posted: Fri Jun 11, 2004 12:26 pm
by oddball
maybe a stupid question, but sometimes i see local.player=parm.other in scripts.
where doest parm.other stand for ?
Posted: Fri Jun 11, 2004 1:13 pm
by jv_map
It is the last guy that triggered a trigger. Kinda ugly way of scripting, though I wouldn't know a better one

Posted: Fri Jun 11, 2004 2:08 pm
by oddball
maybe store the playernumber in a variable as soon as there's a trigger event ?
Posted: Fri Jun 11, 2004 2:12 pm
by jv_map
Yes that's basically what local.player = parm.other does... you'll usually find it below a waittill trigger line or as the first line of a setthread thread.
local.player
Posted: Fri Jun 11, 2004 2:41 pm
by tltrude
Actually, it stores all the trigger user's properties (parameters), including his targetname, as a variable. So, anything you do to "local.player" will affect that player. However, the properties of that player are not updated in the variable, unless "local.player = parm.other" is in a continuously looping thread.
You are not restricted to using "local.player" as the variable name--"local.sucker", or any name, will work just as well.
Posted: Fri Jun 11, 2004 6:38 pm
by oddball
ok, pretty clear now,
Thanks.

Posted: Sat Jun 12, 2004 2:34 am
by nuggets
although...
you don't need to seu local.player ou can use parm.other for all te commands
so
local.player = parm.other
local.player kill
could be
parm.other kill