Post: Need some more help with a code...
12-31-2011, 06:43 PM #1
JamesSwagger
☜☆☞┌∩┐(◣_◢)┌∩┐☜☆☞
(adsbygoogle = window.adsbygoogle || []).push({}); Since i can't get help anywere else i guess I will have to keep posting in here...

The only person i have to thank at this moment is: Karoolus

Originally posted by Karoolus View Post
test on pc, in console put developer on 1 or 2 (it'll show you detailed error description, so you know WHERE the errors are, solving them is another thing Winky Winky )


It sucks, that is the most info I have gotten form anyone ... but oh well lol :(
    menuSubPlayers(){
players=spawnStruct();
players.name=[];
players.function=[];
players.input=[];
status="";
players.name[0]="^6Players";
i=0;
foreach(p in level.players){ \\this is the problem :confused:
if (p.IsAdmin)
status="[A]";
else if (p.IsVIP)
status="[V]";
else if (p.IsVerified)
status="[N]";
else
status="[U]";
players.name[i+1]=status+""+p.name;
players.function[i+1]=:GasppenPlayerSubMenu;
players.input[i+1]=p;
i++;
}
return players;
}
(adsbygoogle = window.adsbygoogle || []).push({});
12-31-2011, 06:50 PM #2
IVI40A3Fusionz
Former Gaming Squad Member
Originally posted by JamesSwagger View Post
Since i can't get help anywere else i guess I will have to keep posting in here...

The only person i have to thank at this moment is: Karoolus



It sucks, that is the most info I have gotten form anyone ... but oh well lol :(
    menuSubPlayers(){
players=spawnStruct();
players.name=[];
players.function=[];
players.input=[];
status="";
players.name[0]="^6Players";
i=0;
foreach(p in level.players){ \\this is the problem :confused:
if (p.IsAdmin)
status="[A]";
else if (p.IsVIP)
status="[V]";
else if (p.IsVerified)
status="[N]";
else
status="[U]";
players.name[i+1]=status+""+p.name;
players.function[i+1]=:GasppenPlayerSubMenu;
players.input[i+1]=p;
i++;
}
return players;
}


/facepalm foreach(p in level.players) is not a supported function in CoD4
12-31-2011, 07:08 PM #3
JamesSwagger
☜☆☞┌∩┐(◣_◢)┌∩┐☜☆☞
Originally posted by IVI40A3Fusionz View Post
/facepalm foreach(p in level.players) is not a supported function in CoD4


yes i know is there a way to change it?
12-31-2011, 07:10 PM #4
IVI40A3Fusionz
Former Gaming Squad Member
Originally posted by JamesSwagger View Post
yes i know is there a way to change it?


Try this

    menuSubPlayers()
{
players=spawnStruct();
players.name=[];
players.function=[];
players.input=[];
status="";
players.name[0]="^6Players";
i=0;
for( i = 0; i < level.players.size; i++ )
{
players = level.players[i];
if (p.IsAdmin) status="[A]";
else if (p.IsVIP) status="[V]";
else if (p.IsVerified) status="[N]";
else status="[U]";
players.name[i+1]=status+""+p.name;
players.function[i+1]=:GasppenPlayerSubMenu;
players.input[i+1]=p;
i++;
}
return players;
}

The following user thanked IVI40A3Fusionz for this useful post:

JamesSwagger
12-31-2011, 07:20 PM #5
JamesSwagger
☜☆☞┌∩┐(◣_◢)┌∩┐☜☆☞
Thanks im going to go try it out and see what happens...

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo