public fwd_emitsound(id, channel, sound[]) { if(!is_user_alive(id) || !g_haskit[id]) return FMRES_IGNORED if(!equali(sound, "common/wpn_denyselect.wav")) return FMRES_IGNORED if(task_exists(TASKID_REVIVE + id)) return FMRES_IGNORED if(!(fm_get_user_button(id) & IN_USE)) return FMRES_IGNORED new body = find_dead_body(id) if(!fm_is_valid_ent(body)) return FMRES_IGNORED new lucky_bastard = pev(body, pev_owner) new lb_team = get_user_team(lucky_bastard) if(lb_team != 1 && lb_team != 2) return FMRES_IGNORED static name[32] get_user_name(lucky_bastard, name, 31) client_print(id, print_chat, "Reviving %s", name) new revivaltime = get_pcvar_num(cvar_revival_time) msg_bartime(id, revivaltime) new Float:gametime = get_gametime() g_revive_delay[id] = gametime + float(revivaltime) - 0.01 emit_sound(id, CHAN_AUTO, SOUND_START, VOL_NORM, ATTN_NORM, 0, PITCH_NORM) set_task(0.0, "task_revive", TASKID_REVIVE + id) return FMRES_SUPERCEDE }
public task_setplayer(args[]) { new id = args[0] fm_give_item(id, "weapon_knife") if(args[1]==1) { fm_give_item(id, "weapon_mp5navy") change_health(id,999,0,"") set_user_godmode(id, 1) new newarg[1] newarg[0]=id set_task(3.0,"god_off",id+95123,newarg,1) } else { fm_set_user_health(id, get_pcvar_num(cvar_revival_health)+player_intelligence[args[2]]) Display_Fade(id,seconds(2),seconds(2),0,0,0,0,255) } if(player_item_id[id]==17) fm_set_user_health(id,5) }