Hello some map (hide and seek) has set mp_t_default_secondary weapon_knife and mp_ct_default_secondary weapon_knife and i can't modify that with plugin or with rcon commands
I have this script to force health points, but could you modify this to force secondary weapon to deagle and knife for ct and t ?
Code:
#include <sourcemod>
#include <sdktools>
#include <sdkhooks>
#pragma semicolon 1
#pragma newdecls required
public void OnPluginStart()
{
HookEvent("player_spawn", Event_PlayerSpawn);
}
public void Event_PlayerSpawn(Event event, const char[] name, bool dontBroadcast)
{
RequestFrame(Frame_Callback, event.GetInt("userid"));
}
public void Frame_Callback(int userid)
{
int client = GetClientOfUserId(userid);
if (client && IsClientInGame(client) && IsPlayerAlive(client))
{
if (GetClientTeam(client) == 2)
{
CreateTimer(2.0, Timer_Callback, GetClientUserId(client), TIMER_FLAG_NO_MAPCHANGE);
} else {
SetEntityHealth(client, 999);
}
}
}
public Action Timer_Callback(Handle timer, int userid)
{
int client = GetClientOfUserId(userid);
if (client && IsClientInGame(client) && IsPlayerAlive(client) && GetClientTeam(client) == 2)
{
SetEntityHealth(client, 100);
}
}
or maybe just a script give deagle when player spawn.
Sorry for my bad english, and it's my last request for my serveur hide and seek.
And thanks to people who help me to create scripts !