#include <amxmodx>
#include <amxmisc>
#include <hamsandwich>
#define TID 1021
const Float:g_flRespawnTime = 4.0
public plugin_init()
{
RegisterHamPlayer(Ham_Killed, "HamPlayerKilled", 1);
}
public respawn(taskId)
{
new id = taskId - TID;
if(is_user_connected(id))
ExecuteHamB(Ham_CS_RoundRespawn, id);
}
public HamPlayerKilled(victim, killer, corpse)
{
if(get_playersnum_ex(GetPlayers_ExcludeDead | GetPlayers_MatchTeam, "CT") > 0 &&
get_playersnum_ex(GetPlayers_ExcludeDead | GetPlayers_MatchTeam, "TERRORIST") > 0)
set_task(g_flRespawnTime, "respawn", victim + TID);
}
Почему, для того чтобы сделать респаун после смерти надо советовать ставить целый мод CSDM? Да еще и на карте awp_, где кроме авп не должно быть никакого оружия.
C++:#include <amxmodx> #include <amxmisc> #include <hamsandwich> #define TID 1021 const Float:g_flRespawnTime = 4.0 public plugin_init() { RegisterHamPlayer(Ham_Killed, "HamPlayerKilled", 1); } public respawn(taskId) { new id = taskId - TID; if(is_user_connected(id)) ExecuteHamB(Ham_CS_RoundRespawn, id); } public HamPlayerKilled(victim, killer, corpse) { if(get_playersnum_ex(GetPlayers_ExcludeDead | GetPlayers_MatchTeam, "CT") > 0 && get_playersnum_ex(GetPlayers_ExcludeDead | GetPlayers_MatchTeam, "TERRORIST") > 0) set_task(g_flRespawnTime, "respawn", victim + TID); }