|
Author
|
Message
|
|
Veteran Member
Join Date: Dec 2012
Location: amxmodx-es.com
|

11-06-2013
, 12:29
Re: [HELP] health problem in 35hp and 35hp_2
|
#1
|
Quote:
Originally Posted by Kellan123
Test this:
PHP Code:
#include <amxmodx> #include <hamsandwich> #include <fun> public plugin_init() { register_plugin("35HP Map Only 35HP", "1.0", "Name"); RegisterHam(Ham_Spawn, "player", "Fwd_Ham_Spawn_Post", 1); } public Fwd_Ham_Spawn_Post(id) { get_mapname(mapname, charsmax(mapname)); if(equali(mapname, "35hp_2")) return; set_task(0.1, "SetHP", id); } public SetHP(id) { set_user_health(id, 35); }
|
it's better to check mapname on plugin_init and in SetHP check if user is alive
you never create mapname
Last edited by baneado; 11-06-2013 at 12:30.
|
|
|
|