Whats the point of this func ? It also blocks all name changes, just lets through if
oldname == newname. I need a way server could recognize , where
I change player name , and let me do it , but if
a player tries to do it , stop him.
EDIT: Tried this:
PHP Code:
public client_infochanged(id) {
if(!get_pcvar_num(cvar))
return PLUGIN_HANDLED
new newname[32]
get_user_info(id,"name",newname,31)
new oldname[32]
get_user_name(id,oldname,31)
if(!equal(newname,oldname))
{
set_user_info(id,"name",oldname)
return PLUGIN_HANDLED
}
return PLUGIN_CONTINUE
}
(code by
#8 SickneSS)
thought if I changed oldname into the name I want , everything would work , but this func ended in an infinite loop , don't know how to get out of it. If someone could show me the right path in achieving what I want, I would be very grateful. Full code isn't needed , just a working idea. Thanks anybody in advance.