PHP Code:
function onCreated() {
this.setshape(1, 32, 32);
}
function onActionSetMatchServer(match,vplayer,splayer){
if (temp.match == "1"){
serverr.sdematch1 = {temp.vplayer, temp.splayer};
}
if (temp.match == "2"){
serverr.sdematch2 = {temp.vplayer, temp.splayer};
}
if (temp.match == "3"){
serverr.sdematch3 = {temp.vplayer, temp.splayer};
}
if (temp.match == "4"){
serverr.sdematch4 = {temp.vplayer, temp.splayer};
}
if (temp.match == "5"){
serverr.sdematch5 = {temp.vplayer, temp.splayer};
}
if (temp.match == "6"){
serverr.sdematch6 = {temp.vplayer, temp.splayer};
}
if (temp.match == "7"){
serverr.sdematch7 = {temp.vplayer, temp.splayer};
}
if (temp.match == "8"){
serverr.sdematch8 = {temp.vplayer, temp.splayer};
}
if (temp.match == "9"){
serverr.sdematch9 = {temp.vplayer, temp.splayer};
}
if (temp.match == "10"){
serverr.sdematch10 = {temp.vplayer, temp.splayer};
}
}
//#CLIENTSIDE
function onCreated() {
this.setshape(1, 32, 32);
}
function onPlayerChats(){
if (!(player.account in {"sssssssssss", "Decus_Arillias"})) return;
if (player.chat.starts("setmatch")) {
temp.match = player.chat.tokenize()[1];
temp.vplayer = player.chat.tokenize()[2];
temp.splayer = player.chat.tokenize()[3];
triggeraction(this.x + 0.5, this.y + 0.5, "SetMatchServer", temp.match, temp.vplayer,temp.splayer);
}
}
ok, now what I'm trying to do, obviously, is set 10 matches. There has got to be a better way to do this than have 10 different server flags isnt there?
I know I could go reading 10 in the array, and I think to pull it out i'd need a for(), but I tried. I've been out of this for 4 years. Sorry guys.