AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   A thinking problem :D (https://forums.alliedmods.net/showthread.php?t=92732)

_lol_ 05-18-2009 22:05

A thinking problem :D
 
Yeah, i check here if my XP is the nedeed for the next SO

PHP Code:

// The level required XP
new const SO[whatever] = { 05101317222938496382106138180233303394512666865,
                
11251462190023002760331239574769572368688242989011868,
                
14041155001780020160229342500027859310503470737000418004536950176,
                
5419763000700009999999 }


    for(new 
0g_maxplayers; ++i)
    {
        new 
id i
        
if(g_so[id] < sizeof (SO))
        {
            while (
g_xp[id] >= SO[g_so[id]])
            {
                
g_so[id]++
                static 
name[32]; get_user_name(idnamecharsmax(name))
                
zp_colored_print(id"^x04[Plugin] Yeah, u re on %dth SO"g_so[id])
                
emit_sound(idCHAN_ITEMSoUp1.0ATTN_NORM0PITCH_NORM)
            }
        }
    } 

but, how to check when u go down?
eg : XP 18, SO = 5, but i commit suicide and i loose 2 XP, so now my SO should be 4, how to check it?lol


All times are GMT -4. The time now is 01:36.

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