Yeah!please look at my code!
PHP Code:
new pCvar_TaskTime
#include <amxmodx>
#include <amxmisc>
#define PLUGIN_NAME "my plugin"
#define PLUGIN_VERSION "1.0"
#define PLUGIN_AUTHOR "K.K.Lv"
public plugin_init()
{
register_plugin(PLUGIN_NAME, PLUGIN_VERSION, PLUGIN_AUTHOR)
pCvar_TaskTime = register_cvar("amx_task_time", "8")
register_event("HLTV", "NewRound", "a", "1=0", "2=0")
}
public NewRound()
{
for (new id = 1; id < get_maxplayers(); id++)
{
static iMsg[128
format(iMsg, 127, "Hello This is a Example")
Create_Show(id, iMsg)
}
}
stock Create_Show(id, iMsg[])
{
message_begin(MSG_ONE_UNRELIABLE, get_user_msgid("TutorText"), {0, 0, 0}, id)
write_string(iMsg)
write_byte(0)
write_short(0)
write_short(0)
message_end()
remove_task(id)
set_task(get_pcvar_float(pCvar_TaskTime), "Remove_Show", id)
}
public Remove_Show(id)
{
remove_task(id)
message_begin(MSG_ONE_UNRELIABLE, get_user_msgid("TutorClose"), {0, 0, 0}, id)
message_end()
}
This my simple code !can some one point the bug out !
thx !!!
__________________