Page 4 of 4

Posted: Mon Oct 23, 2006 1:24 pm
by Wertmanzzz
Hey uhm i found this in the tut's :
my_method:
for ( local.index =5; local.index < 20 ; local.index ++ )
{
iprintlnbold_noloc "Bla nr. " + local.index
wait 2
}
end
(It's under Methods)
But I can't get that + local.index right.
The MOHAA console ALWAYS says
BAD_TOKEN:
'+'

iprintlnbold_noloc "Bla nr. " + local.index
iprintlnbold_noloc "Bla nr. " ^

or something like that.
How can I solve this?
Thanks very much

Posted: Mon Oct 23, 2006 2:51 pm
by bdbodger
iprintlnbold_noloc ("Bla nr. " + local.index)

Posted: Mon Oct 23, 2006 4:06 pm
by Rookie One.pl
Or just skip the +. The iprintln* commands take any number of arguments and convert them all to string.

Posted: Mon Oct 23, 2006 4:57 pm
by Wertmanzzz
Uhm i don't know what I am doing wrong...

Code: Select all

iprintlnbold_noloc ( "Flagholder his kills " + local.flagholder.kills + ", kill him!" )
I used this in Mohdm4...
The game message returned was NIL

*Note: I first did this:

Code: Select all

iprintlnbold_noloc ( "Flagholder his kills " + local.flagholder.kills )
But also, the game message returned was NIL*

How can i solve it :S is it the map/patch/something else?

Posted: Mon Oct 23, 2006 5:06 pm
by Rookie One.pl
The value of local.flagholder.kills is NIL.

If you're trying to retrieve the player's score, give up - it's impossible.

Posted: Mon Oct 23, 2006 8:17 pm
by Wertmanzzz
:( ok. Well then no scores :D, lol.
Cya next time