Marshallew Opublikowano 27 Stycznia 2019 Udostępnij Opublikowano 27 Stycznia 2019 #include <sourcemod> #include <sdktools> #include <cstrike> #include <sdkhooks> public Plugin myinfo = { name = "x", author = "x", description = "x", version = "x", url = "x" } public void OnPluginStart() { HookEvent("player_spawn", 1shot2kill.pl_Spawn); } public void OnMapStart() { } public Action 1shot2kill.pl_Spawn(Handle event, const char[] name, bool dontBroadcast) { int client = GetClientOfUserId(GetEventInt(event, "userid")); if (IsValidPlayer(client) && IsPlayerVip(client)) { GivePlayerItem(client, "weapon_deagle"); } } stock bool IsValidPlayer(int client) { if(client >= 1 && client <= MaxClients && IsClientConnected(client) && !IsFakeClient(client) && IsClientInGame(client) ) return true; return false; } stock bool IsPlayerVip(int client) { if (CheckCommandAccess(client, "1shot2kill_vipek", ADMFLAG_RESERVATION, false)) return true; return false; } Odnośnik do komentarza https://1shot2kill.pl/topic/35896-sm-weapon-on-spawn/ Udostępnij na innych stronach Więcej opcji udostępniania...
Rekomendowane odpowiedzi