19.04.2015, 07:12
How do i detect if that function is used, My own function, not native function or etc.
For Example:
some code for GetPlayerName
For Example:
PHP код:
public OnPlayerConnect(playerid)
{
# if i use that IsValidRoleplayName, GetPlayerName must be GetPlayerName(playerid, true) but if not
# GetPlayerName(playerid)
/* if (!IsValidRoleplayName(GetPlayerName(playerid, true))) {
Kick(playerid);
return 0;
}
*/
printf("%s", GetPlayerName(playerid));
return 1;
}
PHP код:
# What should i do if IsValidRoleplay name is used?
#define GetPlayerName g_lib_function_GetPlayerName
#else
#define GetPlayerName g_lib_function_GetPlayerName_