AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Vars...... (https://forums.alliedmods.net/showthread.php?t=117674)

ProIcons 02-03-2010 12:09

Vars......
 
[Gather] (1) Kill with (umm4a1)
[Gather] (2) Kill with (mm4a1)
[Gather] (3) Kill with (m4a1)
PHP Code:

public list(id)
{
    
Killers(id)
    for (new 
i=1<= Pkills[MKiller]; i++)
    {
       
client_print(id,print_chat,"[Gather] (%d) Kill with (%s)",i,wen[MKiller][i]);
    }
    return 
PLUGIN_CONTINUE    
}



{
         
Pkills[MKiller] += 1;
         
Pdeaths[MVictim] += 1;
         new 
tmp1=Pkills[MKiller];
         
server_print("[Gather] CODE Reached (%s)",weapon_name);
         
copy(wen[MKiller][tmp1],299,weapon_name)
         
server_print("[Gather] Now Kills %d | Deaths %d | Now Kill with gun: %s",Pkills[MKiller],Pdeaths[MKiller],wen[MKiller][Pkills[MKiller]]);
         
client_print(0,print_chat,"[Gather] Now Kills %d | Deaths %d | Now Kill with gun: %s",Pkills[MKiller],Pdeaths[MKiller],wen[MKiller][Pkills[MKiller]]);


Well I have this 2 codes... when i am killling someone is tis appearing normaly:
[Gather] Now Kills 3 | Deaths 0 | Now Kill with gun: m4a

BUT when i am typing .list and call function List with the loop
if example i have 3 guns it will appear in the first gun the first letter of the first gun , the first letter of the second gun and the third gun,
the second gun will have the first letter of the second gun and the third gun
and finaly in the 3rd gun will apear only the third gun, why it is doing this?


All times are GMT -4. The time now is 07:19.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.