View Single Post
Alexunder
Member
Join Date: Jun 2018
Old 07-15-2019 , 16:19   Re: respawn all dead player
Reply With Quote #4

Quote:
Originally Posted by DiogoOnAir View Post
Code:
#pragma semicolon 1

#define DEBUG

#define PLUGIN_AUTHOR "DiogoOnAir"
#define PLUGIN_VERSION "1.00"

#include <sourcemod>
#include <sdktools>
#include <cstrike>

#pragma newdecls required

public Plugin myinfo = 
{
	name = "",
	author = PLUGIN_AUTHOR,
	description = "",
	version = PLUGIN_VERSION,
	url = "https://www.steamcommunity.com/id/diogo218dv"
};

public void OnPluginStart()
{
	RegAdminCmd("sm_respawndead", Cmd_RespawnDead, ADMFLAG_CHEATS);
}

public Action Cmd_RespawnDead(int client, int args)
{
	for(int i = 1; i <= MaxClients; i++)
	{
		if(!IsPlayerAlive(i))
		{
			CS_RespawnPlayer(i);
	    }		
	}
}
You can use this one, the command to respawn all dead players is sm_respawndead
worked ! thankyou
Alexunder is offline