Hello!
PHP Code:
#include <amxmodx>
#include <amxmisc>
#define PLUGIN "New Plug-In"
#define VERSION "1.0"
#define AUTHOR "author"
new g_maxplayers
public plugin_init()
{
register_plugin("test", "1.0", "tester")
register_logevent("logevent_round_end", 2, "1=Round_End")
g_maxplayers = get_maxplayers()
}
public logevent_round_end()
{
new top1[33], top2[33], top3[33]
for(new try = 0; try < 4; try++) // Check all player 3 time...
{
for(new i=0; i<=g_maxplayers; i++) {
if(is_user_connected(i))
{
new name[33], tempFrags
get_user_name(i, name,32)
tempFrags = get_user_frags(i)
if(top1[i] < tempFrags)
{
format(top1, charsmax(top1), "%s", name)
}
if((top2[i] < tempFrags) && (tempFrags < top1[i]))
{
format(top2, charsmax(top2), "%s", name)
}
if((top3[i] < tempFrags) && (tempFrags < top2[i]))
{
format(top3, charsmax(top3), "%s", name)
}
else
{
break
}
}
}
set_hudmessage(0, 255, 0, -1.0, -1.0)
show_hudmessage(0, "Best Frager:^n%s^n%s^n%s", top1, top2, top3)
}
//Set the top fragger to 0 here again
}
I have this code, bud he's not works correctly. Can you help me with him?
http://forums.alliedmods.net/showthread.php?t=168284
This script calculate top 3 fraggers of round.
__________________