Chodzi mi o zrobienie rozgrzewki na same deagle przez 60 sekund z respawnem
plugin rundy rozgrzewkowej:
#include <amxmodx>
#include <amxmisc>
// Plugin Version
#define VERSION "1.7"
// Define the access for admin commands
#define ACCESS ADMIN_KICK
new Float:g_LastRestart[33];
// Count cvars
new cvar_enabled;
new map[32]
new cvar_hostname;
new cvar_time;
new say_text;
public plugin_init()
{
// Register plugin
register_plugin("Round Restart", VERSION, "xxxx");
// Register plugin version
register_cvar("restart_version", VERSION, FCVAR_SERVER|FCVAR_SPONLY);
set_cvar_string("restart_version", VERSION);
// Register admin commands
register_clcmd("say /rrlive","say_restart",ACCESS)
register_clcmd("say_team /rrlive","say_restart",ACCESS)
register_clcmd("say /rr","say_restart",ACCESS)
register_clcmd("say_team /rr","say_restart",ACCESS)
register_clcmd("say /live","say_restart",ACCESS)
register_clcmd("say_team /live","say_restart",ACCESS)
register_clcmd("say /restart","say_restart",ACCESS)
register_clcmd("say_team /restart","say_restart",ACCESS)
// Register language file
register_dictionary("round_restart.txt");
// Enable/Disable plugin ingame from server console
cvar_enabled = register_cvar("restart_enabled","1" );
if(!get_pcvar_num(cvar_enabled))
return
// Register plugin cvars
cvar_time = register_cvar("restart_waittime","60.0" );
cvar_hostname = get_cvar_pointer("hostname");
say_text = get_user_msgid("SayText");
get_mapname(map, charsmax(map));
}
public say_restart(id,level,cid )
{
if(!cmd_access(id,level,cid,2))
{
return PLUGIN_CONTINUE;
}
new Float:Time = get_gametime();
if(Time - g_LastRestart[id] < get_pcvar_float(cvar_time))
{
client_printc(id,"%L", id, "RR_WAIT");
return PLUGIN_CONTINUE;
}
g_LastRestart[id] = Time;
new hostname[64];
get_pcvar_string(cvar_hostname, hostname, charsmax(hostname));
server_cmd("sv_restart 5")
client_printc(0, "%L", id, "RR_MSG", hostname);
client_printc(0, "%L", id, "RR_MSG2", map);
client_printc(0, "%L", id, "RR_MSG3");
client_printc(0, "%L", id, "RR_MSG4");
client_cmd(0, "speak ^"loading environment^"");
return PLUGIN_CONTINUE;
}
stock client_printc(const id, const string[], {Float, Sql, Resul,_}:...) {
new msg[191], players[32], count = 1;
vformat(msg, sizeof msg - 1, string, 3);
replace_all(msg,190,"!g","^4");
replace_all(msg,190,"!y","^1");
replace_all(msg,190,"!t","^3");
if(id)
players[0] = id;
else
get_players(players,count,"ch");
new index;
for (new i = 0 ; i < count ; i++)
{
index = players[i];
message_begin(MSG_ONE_UNRELIABLE, say_text,_, index);
write_byte(index);
write_string(msg);
message_end();
}
}
Plugin respawnu:
#include <amxmodx>
#include <cstrike>
#define PLUGIN "Respawn"
#define VERSION "0.1"
#define AUTHOR "xxxxx"
new bool:g_bActive;
public plugin_init()
{
register_plugin(PLUGIN,VERSION,AUTHOR);
register_event("DeathMsg","Event_DeathMsg","a");
register_clcmd("say /respawn","ClCmd_Respawn");
}
public plugin_cfg()
{
new szMap[64];
get_mapname(szMap,63);
if(containi(szMap,"surf_")!=-1)
{
g_bActive = true;
}
else
{
g_bActive = false;
}
}
public Event_DeathMsg()
{
if(g_bActive == false)
return;
new id = read_data(2);
set_task(0.3,"Respawn",id);
}
public ClCmd_Respawn(id)
{
if(is_user_alive(id) || !g_bActive)
return PLUGIN_CONTINUE;
set_task(0.3,"Respawn",id);
return PLUGIN_CONTINUE;
}
public Respawn(id)
{
cs_user_spawn(id);
}
Plugin:dania bronizmiany broni :
#define PLUGINNAME "Pistol Rounds"
#define VERSION "1.6"
#define AUTHOR "zp"
#include <amxmodx>
#include <fakemeta>
#include <fakemeta_util>
#include <hamsandwich>
#include <cstrike>
new pistolrounds
public plugin_init(){
register_plugin(PLUGINNAME, VERSION, AUTHOR);
pistolrounds = register_cvar("amx_pistolrounds", "0")
RegisterHam(Ham_Spawn, "player", "reset_weapons", 1);
}
public reset_weapons(id){
if(get_pcvar_num(pistolrounds)!=1){
return PLUGIN_HANDLED
}
if(is_user_alive(id)){
fm_strip_user_weapons(id);
cs_set_user_money(id, 800, 0);
fm_give_item(id, "weapon_knife");
cs_set_user_armor(id, 0, CS_ARMOR_NONE);
switch(get_user_team(id)){
case CS_TEAM_T:
{
fm_give_item(id, "weapon_knife");
cs_set_user_bpammo(id, CSW_GLOCK18, 40);
}
case CS_TEAM_CT:
{
fm_give_item(id, "weapon_knife");
cs_set_user_bpammo(id, CSW_USP, 24);
cs_set_user_defuse(id, 0);
}
}
}
return HAM_IGNORED;
}
@@Chodzi mi o to zzeby je polaczyc i wyrzucic z kodow co nie potrzebne z zrobic jeden plugin czyli runde rozgrzewka na deagle z respawnem
Witamy w Nieoficjalnym polskim support'cie AMX Mod X
Witamy w Nieoficjalnym polskim support'cie AMX Mod X, jak w większości społeczności internetowych musisz się zarejestrować aby móc odpowiadać lub zakładać nowe tematy, ale nie bój się to jest prosty proces w którym wymagamy minimalnych informacji.
|
Guest Message by DevFuse
3 odpowiedzi w tym temacie
#1
Napisano 05.06.2009 12:57
#3
Napisano 05.06.2009 13:33
raczej za bardzo skaplikowany mi zalezy aby byl respawn ,Deagle i res na koniec tylko tlye
#4
Napisano 05.06.2009 13:40
to może ten http://amxx.pl/viewtopic.php?t=3724
Nie ma co robić nowego plugin, jak pełno jest gotowych
Nie ma co robić nowego plugin, jak pełno jest gotowych
Również z jednym lub większą ilością słów kluczowych: Nowy Plugin
|
Nowy Plugin
[KOSZ] pluginNapisany przez Frodo1981 , 25.02.2024 nowy plugin |
|
|
||
Nowy Plugin
vip pbNapisany przez One ShooT , 04.02.2024 nowy plugin |
|
|
|||
Nowy Plugin
Admin menuNapisany przez stół z powyłamywanymi , 22.09.2022 nowy plugin |
|
|
|||
Nowy Plugin
Prośba o napisanie pluginuNapisany przez stół z powyłamywanymi , 15.08.2022 nowy plugin |
|
|
|||
Nowy Plugin
PLUGIN NA DRplugin Napisany przez bawarskagolonka123 , 25.06.2021 nowy plugin |
|
|
Użytkownicy przeglądający ten temat: 1
0 użytkowników, 1 gości, 0 anonimowych