←  Problemy

AMXX.pl: Support AMX Mod X i SourceMod

»

[ROZWIĄZANE] Komenda Spec na Surfa

SqNw0w - zdjęcie SqNw0w 28.07.2012

Dziala lecz to:

#include <amxmodx>
#include <amxmisc>
#include <cstrike>
#include <hamsandwich>

#define PLUGIN "Spec/Back"
#define AUTHOR "kramesa"
#define VERSION "v1.1"

new bool:TerroristTeam[33];
new CountTime[33];

public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR);

register_clcmd("say /spec", "Spec");
register_clcmd("say /back", "Back");

}
public Spec(id)
{
if(cs_get_user_team(id) == CS_TEAM_T)
{
TerroristTeam[id] = true;
}
else
{
TerroristTeam[id] = false;
}

if(cs_get_user_team(id) == CS_TEAM_SPECTATOR)
{
client_print(id, print_chat, "Jestes na spekcie!");
return PLUGIN_HANDLED;
}
else
{
cs_set_user_team(id, CS_TEAM_SPECTATOR);
user_kill(id, 1);
client_print(id, print_chat, "Zostales przeniesiony na spect!");

CountTime[id]++;

return PLUGIN_HANDLED;
}
return PLUGIN_HANDLED;
}
public Back(id)
{
if(cs_get_user_team(id) != CS_TEAM_SPECTATOR)
{
client_print(id, print_chat, "Nie jestes na spekcie");
return PLUGIN_HANDLED;
}

if(cs_get_user_team(id) == CS_TEAM_SPECTATOR)
{
if(TerroristTeam[id] == true)
{
cs_set_user_team(id, CS_TEAM_T);
client_print(id, print_chat, "Jestes znowu w TT");
cs_set_user_deaths(id, 0);
ExecuteHamB(Ham_CS_RoundRespawn, id);
return PLUGIN_HANDLED;
} else {
cs_set_user_team(id, CS_TEAM_CT);
client_print(id, print_chat, "Jestes znowu w CT");
cs_set_user_deaths(id, 0);
ExecuteHamB(Ham_CS_RoundRespawn, id);
return PLUGIN_HANDLED;
}
}
return PLUGIN_HANDLED;
}

Close !:)
Użytkownik SqNw0w edytował ten post 28.07.2012 01:42
Odpowiedz

Gość_21977_* 29.07.2012

Wiadomość wygenerowana automatycznie


Ten temat został zamknięty przez moderatora.

Powód: Pomoc udzielona

Jeśli się z tym nie zgadzasz, Dołączona grafika raportuj ten post, a moderator lub administrator rozpatrzy go ponownie.


Z pozdrowieniami,
Zespół AMXX.PL
Odpowiedz