I don't think you need a fixed task for that.
PHP Code:
#include <amxmodx>
#include <amxmisc>
#define PLUGIN "New Plug-In"
#define VERSION "1.0"
#define AUTHOR "author"
new g_szName[ 32 ]
public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR)
}
public client_disconnect( id )
{
get_user_name( id, g_szName, charsmax( g_szName ) )
set_task(1.0, "OnTaskDisconnected")
}
public OnTaskDisconnected()
{
new iPlayer[ 32 ], iNum;
get_players( iPlayer, iNum, "ch" )
for( new i, iAdmin; i < iNum; i++ )
{
if( is_user_admin( ( iAdmin = iPlayer[ i ] ) ) )
{
set_hudmessage( 0, 255, 0, -1.0, -1.0 )
show_hudmessage( iAdmin, "Player %s has disconnected", g_szName )
}
}
g_szName[0] = EOS
}
__________________