Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <amxmodx>
- #include <hamsandwich>
- #include <cstrike>
- public plugin_init() {
- register_plugin("Respawn", "1.0", "DecaK")
- register_clcmd("say /respawn", "respawnuj")
- register_event("DeathMsg", "Smrt", "a")
- }
- public respawnuj(id) {
- if(is_user_alive(id) || !is_user_connected(id)) return PLUGIN_CONTINUE;
- new tim = CsTeams:cs_get_user_team(id)
- if(tim == CS_TEAM_CT || tim == CS_TEAM_T) ExecuteHamB(Ham_CS_RoundRespawn, id)
- }
- public proveriRespawn(id) {
- if(is_user_alive(id) || !is_user_connected(id)) return PLUGIN_CONTINUE;
- new tim = cs_get_user_team(id);
- if(tim == CS_TEAM_CT || CS_TEAM_T) ExecuteHamB(Ham_CS_RoundRespawn, id)
- else set_task(5.0, "proveriRespawn", id)
- return 1;
- }
- public client_death(a1,id,a3,a4,a5) set_task(2.0, "respawnuj", id)
- public client_putinserver(id) set_task(5.0, "proveriRespawn", id)
- public Smrt() set_task(5.0, "respawnuj", read_data(2))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement