View Single Post
  #4  
Old 08-22-2009, 07:21 PM
screen_name screen_name is offline
is watching you
Join Date: Mar 2002
Location: The 3rd Dimension
Posts: 2,160
screen_name is on a distinguished road
Send a message via AIM to screen_name Send a message via MSN to screen_name
Quote:
Originally Posted by Gambet View Post
Yes, you can use a loop instead:

PHP Code:
function onActionSetMatchServer(matchvplayersplayer) {
  for (
temp.0temp.<= 10temp.i++) {
    if (
match == imakevar("serverr.sdematch" i) = {vplayersplayer};
  }

Please note that when defining names for parameters you do not use the temp. prefix to read their values.
Now, I've seen this in other scripts as well. Just a few questions;
1. Can you explain why the temp. is not required or that just the way it is and I better accept it?
2. Also, does it only apply to temp.variables?
3. Are there any exceptions to this rule? I've noticed that you can use pc[0....10] or whatever to access variables created with temp.pc = player.chat.tokenize();
__________________
[signature]insert here[/signature]
Reply With Quote