Quote:
Originally Posted by OciXCrom
PLUGIN_HANDLED in this case will block the /spawn command from showing in chat and will stop any other plugin from hooking it.
If it was PLUGIN_CONTINUE, the command would show in chat.
PLUGIN_HANDLED_MAIN will hide the command in chat, but won't stop any other plugins from hooking it.
It doesn't affect anything else in this case.
|
The answer that I was waiting for, thank you. But what also there happens if I don't use PLUGIN_HANDLED and it hooks with other plugins?
And, does it block the other lines / cases in the plugin?
For an example, I'm meaning:
Code:
if(cs_get_user_money(id) < get_pcvar_num(gMoney))
{
client_print_color(id, id, "^4[%s]: ^3You Don't Have Enough Money to Spawn Yourself", SERVER_INFORMATION)
return PLUGIN_HANDLED
}
I finished the task on the top line / case and wrote PLUGIN_HANDLED ( ↑ ). Will it hooking with the second line / case in the bottom ( ↓ )?
Code:
else if(cs_get_user_money(id) >= get_pcvar_num(gMoney))
{
cs_set_user_money(id, cs_get_user_money(id) - get_pcvar_num(gMoney))
cs_user_spawn(id)
client_print_color(id, id, "^4[%s]: ^3You Have Spawned Yourself!", SERVER_INFORMATION)
}