|H|A|K|E|R|_227
Пользователь
- Регистрация
- 22 Дек 2018
- Сообщения
- 2
- Симпатии
- 0
- OS
- Windows
- Amx Mod X
- AMXX 1.9.0
- Билд
- 3.8.0.702
- ReGamedll
- 5.20.0.492
- Metamod
- v1.21p38
- Meta модули
-
Код:Currently loaded plugins:
description stat pend file vers src load unlod
[ 1] Reunion RUN - reunion_mm.dll v0.1.0.9 ini Start Never
[ 2] AMX Mod X RUN - amxmodx_mm.dll v1.9.0.5 ini Start ANY
[ 3] mmtimer RUN - mmtimer.dll v1.6 ini ANY Never
[ 4] Revoice RUN - revoice_mm.dll v0.1.0.3 ini Start Never
[ 5] ReSemiclip RUN - resemiclip_mm.dl v2.3.9 ini Chlvl ANY
[ 6] WHBlocker RUN - whblocker_mm.dll v1.5.697 ini Chlvl ANY
[ 7] Rechecker RUN - rechecker_mm.dll v2.5 ini Chlvl ANY
[ 8] YaPB RUN - yapb.dll v4.2.598 ini Chlvl ANY
[ 9] ReAimDetector RUN - reaimdetector_am v0.2.2 pl2 ANY Never
[10] FakeMeta RUN - fakemeta_amxx.dl v1.9.0.5 pl2 ANY ANY
[11] CStrike RUN - cstrike_amxx.dll v1.9.0.5 pl2 ANY ANY
[12] ReAPI RUN - reapi_amxx.dll v5.19.0. pl2 ANY Never
[13] Ham Sandwich RUN - hamsandwich_amxx v1.9.0.5 pl2 ANY ANY
[14] Engine RUN - engine_amxx.dll v1.9.0.5 pl2 ANY ANY
[15] Fun RUN - fun_amxx.dll v1.9.0.5 pl2 ANY ANY
[16] CSX RUN - csx_amxx.dll v1.9.0.5 pl2 ANY ANY
[17] MySQL RUN - mysql_amxx.dll v1.9.0.5 pl2 ANY ANY
17 plugins, 17 running
- Плагины
-
Код:Сurrently loaded plugins:
name version author file status
[ 1] Admin Base 1.9.0.5271 AMXX Dev Team admin.amxx running
[ 2] Admin Commands 1.8.1.3746 AMXX Dev Team admincmd.amxx running
[ 3] Slots Reservation 1.9.0.5271 AMXX Dev Team adminslots.amxx running
[ 4] Menus Front-End 1.9.0.5271 AMXX Dev Team menufront.amxx running
[ 5] Commands Menu 1.9.0.5271 AMXX Dev Team cmdmenu.amxx running
[ 6] Players Menu 1.8.1.3746 AMXX Dev Team plmenu.amxx running
[ 7] Teleport Menu 1.9.0.5271 AMXX Dev Team telemenu.amxx running
[ 8] Maps Menu 1.8.1.3746 AMXX Dev Team mapsmenu.amxx running
[ 9] Admin Chat 1.9.0.5271 AMXX Dev Team adminchat.amxx running
[ 10] Anti Flood 1.9.0.5271 AMXX Dev Team antiflood.amxx running
[ 11] Scrolling Message 1.9.0.5271 AMXX Dev Team scrollmsg.amxx running
[ 12] Info. Messages 1.9.0.5271 AMXX Dev Team imessage.amxx running
[ 13] Admin Votes 1.9.0.5271 Wildness Team adminvote.amxx running
[ 14] NextMap 1.9.0.5271 AMXX Dev Team nextmap.amxx running
[ 15] Nextmap Chooser 1.9.0.5271 AMXX Dev Team mapchooser.amxx running
[ 16] TimeLeft 1.9.0.5271 AMXX Dev Team timeleft.amxx running
[ 17] Pause Plugins 1.9.0.5271 AMXX Dev Team pausecfg.amxx running
[ 18] Plugin Menu 1.9.0.5271 AMXX Dev Team pluginmenu.amxx running
[ 19] Restrict Weapons 1.9.0.5271 AMXX Dev Team restmenu.amxx running
[ 20] ReAimDetector API 0.2.2 ReHLDS Team reaimdetector.a debug
[ 21] Advanced Kill Assists 1.3c Xelson next21_kill_ass running
[ 22] SF Bets 0.1.5 serfreeman1337 sf_bets.amxx running
[ 23] [ReAPI] Healthnade 0.0.2 F@nt0M reapi_healthnad running
[ 24] [190] Map Spawns Edito 20.06.06 SKAJIbnEJIb & iG MapSpawnsEditor running
[ 25] AntiSpam FlashLight 1.2a Leo_[BH] flashlight_no_s running
[ 26] Best Player in Round [ 1.0 Leo_[BH] best_player_in_ running
[ 27] Simple Damager 2.1.0 fl0wer simple_damager. running
[ 28] AntiFlash FINAL 5.0 Leo_[BH] antiflash5.amxx running
[ 29] AFK Kicker cs_get_user 1.0 Leo_[BH] afk_kicker.amxx running
[ 30] Check Admin & Vip 2.2 Leo_[BH] check_admin_vip running
[ 31] Check Steam Players 1.0 Leo_[BH] check_steam.amx running
[ 32] Parachute 2.0 Leo_[BH] parachute.amxx running
[ 33] [AMXX] Admin Gift 02.01.2018 Edit By Number O OnlineGiveAdmin running
[ 34] VIP 1.5 by4udilo admin_vip_2.amx running
[ 35] Crux Ansata 1.0 DUKKHAZ0R crux_ansata.amx debug
[ 36] [ReAPI] AWPoff 1.4.3 PAffAEJIkA :3 awp_off.amxx running
[ 37] Ping Control 1.31 neygomon Ping_Control.am running
[ 38] DeathGift 1.2.1 ArKaNeMaN DeathGift.amxx running
[ 39] Advanced Ultimate Weap 0.1.0b steelzzz auw.amxx debug
[ 40] ReChecker Logging freesrv AMXX rc_logging.amxx running
[ 41] RC BaseChanger freesrv AMXX rc_basechanger. running
[ 42] Top Round Damage 1.0.4 ReAP Dager* *.* -G- damage_round_on running
[ 43] NoSpectFlash v3.1 [reap PAffAEJIkA :3 NoSpectFlash.am running
[ 44] [ReAPI] No Team Flash 0.0.2 Vaqtincha no_team_flash.a running
[ 45] Vampire 1.0c Shalfey vampire.amxx running
[ 46] VIP bonus time 1.0 DUKKHAZ0R vip_bonus_time. running
[ 47] [ReAPI] Custom Models 1.6.1 neugomon custom_models.a running
[ 48] TOP VIP (Auto Set) 1.0a Leo_[BH] top_vip.amxx running
[ 49] Nade Messages 1.0 v3x nademessages.am running
[ 50] Reklama 16.03.2020 mx?! reklama.amxx running
[ 51] Mode 2x2 2.5re s1lent mode.amxx running
[ 52] Info Rank 0.1 by CepeH9 INFO_RANK_V0.1. running
[ 53] Spray Block 0.4 neugomon no_logo.amxx running
[ 54] Lite Admin ESP 1.0 neygomon admin_esp.amxx running
[ 55] Lite VoteBan 1.4 neygomon lite_voteban.am running
[ 56] New Plug-In 1.0 author menu.amxx running
[ 57] [DG] MoreBonuses 1.0 ArKaNeMaN dgMoreBonuses.a debug
[ 58] [DG][MB] More Function 1.1 ArKaNeMaN dgmbMoreFuncs.a debug
[ 59] AES: StatsX 0.5 Vega serfreeman1337 aes_statsx_cstr running
[ 60] StatsX 1.9.0.5271 AMXX Dev Team statsx.amxx running
[ 61] Advanced Experience Sy 0.4 serfreeman1337 aes_main.amxx running
[ 62] AES: Exp CSTRIKE 0.3 serfreeman1337 aes_exp_cstrike running
[ 63] AES: Informer 0.2 serfreeman1337 aes_informer.am running
[ 64] AES: Experience Editor 0.1 serfreeman1337 aes_exp_editor. running
[ 65] AES: Bonus System 0.2 serfreeman1337 aes_bonus_syste running
[ 66] AES: Bonus PUBLIC 0.1.1 serfreeman1337 aes_bonus_pub.a running
[ 67] AES: Bonus CSTRIKE 0.4 serfreeman1337 aes_bonus_cstri running
[ 68] Prefix Chat + AES 0.2 spree aes_chat.amxx running
68 plugins, 68 running
- Amxx Модули
-
Код:Список загруженных модулей:
Наименовани верси Автор Состо
ReAimDetector 0.2.2 ReHLDS Team running
FakeMeta 1.9.0.5271 AMX Mod X Dev Team running
CStrike 1.9.0.5271 AMX Mod X Dev Team running
ReAPI 5.19.0.210 Asmodai & s1lent running
Ham Sandwich 1.9.0.5271 AMX Mod X Dev Team running
Engine 1.9.0.5271 AMX Mod X Dev Team running
Fun 1.9.0.5271 AMX Mod X Dev Team running
CSX 1.9.0.5271 AMX Mod X Dev Team running
nVault 1.9.0.5271 AMX Mod X Dev Team running
MySQL 1.9.0.5271 AMX Mod X Dev Team running
Всего 10 модулей
- Ошибка
-
Код:// D:\╠юш фюъєьхэЄ√\Counter-Strike\╠√ ╧ э√х фхЄър\cstrike\addons\amxmodx\scripti
ng\weapon_menu.sma(1) : error 010: invalid function or declaration
- Исходник
-
Код:#include <amxmodx>
#include <amxmisc>
#include <hamsandwich>
#include <fakemeta>
#include <engine>
#include <fun>
#include <cstrike>
#include <WPMGPrintChatColor>
#include <fakemeta_util>
#define PLUGIN "New Plug-In"
#define VERSION "1.0"
#define AUTHOR "author"
new const Float:g_flCoords[][] = {
{0.50, 0.40},
{0.56, 0.44},
{0.60, 0.50},
{0.56, 0.56},
{0.50, 0.60},
{0.44, 0.56},
{0.40, 0.50},
{0.44, 0.44}
}
new g_iPlayerPos[33]
new gMaxPlayer;
new bool:gbShowDamage[33];
new gSzView[][] = {
"Круговой",
"Звёздочкой",
"Обычный"
}
new gPlTypeView[33];
new Float:gFlSpeed[33];
enum _:TOTAL_TEAMS {//Команда игрока.
TEAM_NULL,
TEAM_T,
TEAM_CT,
TEAM_SPEC
};
stock Player_GetTeam(id) { //Проверяем команду игрока.
return (pev_valid(id) != 2) ? 0 : get_pdata_int(id, 114,5);
}
new gUse[33];
//Для проверки слотов.
#define PRIMARY_WEAPONS ((1<<CSW_SCOUT) | (1<<CSW_XM1014) | (1<<CSW_MAC10) | (1<<CSW_AUG) | (1<<CSW_UMP45) | (1<<CSW_SG550) | (1<<CSW_GALIL) | (1<<CSW_FAMAS) | (1<<CSW_AWP) | (1<<CSW_MP5NAVY) | (1<<CSW_M249) | (1<<CSW_M3) | (1<<CSW_M4A1) | (1<<CSW_TMP) | (1<<CSW_G3SG1) | (1<<CSW_SG552) | (1<<CSW_AK47) | (1<<CSW_P90))
#define SECONDARY_WEAPONS ((1<<CSW_P228) | (1<<CSW_ELITE) | (1<<CSW_FIVESEVEN) | (1<<CSW_USP) | (1<<CSW_GLOCK18) | (1<<CSW_DEAGLE))
#define EV_INT_WEAPONKEY EV_INT_impulse
const MENU_LENGTH = 512;
new CHATTAG[] = "!t[!gВипМеню!t]";
//Для работы меню выбора оружия.
enum _:STRWEAPON {
WEAPON_RBLOCK,
WEAP_PRIMARY,
WEAP_COST,
WEAP_ID,
WEAP_CSW,
WEAP_TEXT[14],
WEAP_NAME[20],
WEAP_CLIP,
WEAP_AMMO,
Float:WEAP_DAMAGE,
WEAP_OLDMODELS[64],
WEAP_V[64],
WEAP_P[64],
WEAP_W[64]
}
new gArrWeapon[][STRWEAPON] = {
{ 0 ,0,0, 399,CSW_DEAGLE,"deagle" ,"weapon_deagle", 7,35, 1.7 ,"models/w_deagle.mdl" ,"models/weapn/gold/v_deagle.mdl" ,"models/weapn/gold/p_deagle.mdl" ,"models/weapn/gold/w_deagle.mdl" },
{ 3 ,1,2500, 400,CSW_AWP, "awp" ,"weapon_awp" , 10,30, 1.9 , "models/w_awp.mdl" ,"models/weapn/gold/v_awp.mdl" ,"models/weapn/gold/p_awp.mdl" ,"models/weapn/gold/w_awp.mdl" },
{ 2 ,1,2500, 401,CSW_FAMAS, "famas" ,"weapon_famas" , 30,90, 1.7 , "models/w_famas.mdl" ,"models/weapn/gold/v_famas.mdl" ,"models/weapn/gold/p_famas.mdl" ,"models/weapn/gold/w_famas.mdl"},
{ 2 ,1,2500, 402,CSW_AK47, "ak47" ,"weapon_ak47" , 30,90, 1.7 ,"models/w_ak47.mdl" ,"models/weapn/gold/v_ak47.mdl" ,"models/weapn/gold/p_ak47.mdl" ,"models/weapn/gold/w_ak47.mdl" },
{ 2 ,1,2500, 403,CSW_M4A1, "m4a1" ,"weapon_m4a1" , 30,90, 1.7 ,"models/w_m4a1.mdl" ,"models/weapn/gold/v_m4a1.mdl" ,"models/weapn/gold/p_m4a1.mdl" ,"models/weapn/gold/w_m4a1.mdl" },
{ 0, -1,0 ,404,CSW_KNIFE,"gold_knife","weapon_knife", 0,0, 1.7 ,"models/w_deagle.mdl" ,"models/weapn/gold/v_knife.mdl" ,"models/weapn/gold/p_knife.mdl" ,"models/w_deagle.mdl" }
}
new g_has_weapon[sizeof gArrWeapon][33];
//Квары
new cvar_vip_flag;
new cvar_set_max_speed;
new gRound = 0;
public plugin_precache() {
for(new weap=0;weap<sizeof(gArrWeapon);weap++) {
precache_model(gArrWeapon[weap][WEAP_V]);
precache_model(gArrWeapon[weap][WEAP_P]);
precache_model(gArrWeapon[weap][WEAP_W]);
}
}
public plugin_init() {
gMaxPlayer = get_maxplayers();
register_forward(FM_SetModel, "fw_SetModel");
for(new weap=0;weap<sizeof(gArrWeapon);weap++) {
if(!equali(gArrWeapon[weap][WEAP_NAME],"weapon_knife")) {
RegisterHam(Ham_Item_Deploy, gArrWeapon[weap][WEAP_NAME], "Item_Deploy_Post", 1);
RegisterHam(Ham_Item_AddToPlayer, gArrWeapon[weap][WEAP_NAME], "fw_AddToPlayer")
} else {
RegisterHam(Ham_Item_Deploy, "weapon_knife" , "Fwd_ItemDeploy_Knife_Post", 1 ) //Для замени моделей ножей.
}
}
RegisterHam(Ham_Item_PreFrame, "player", "Ham_ItemPreFrame_Pre", 0);
RegisterHam(Ham_Spawn,"player","player_respawn")
RegisterHam(Ham_TakeDamage,"player","TakeDamage",0)
register_menu("MenuId", 1023, "MenuFunc");
register_menu("MenuDamage", 1023, "MenuFuncDamage");
RegisterHam(Ham_Touch, "weaponbox", "blockweapon");
register_event("HLTV", "NewRound", "a", "1=0", "2=0")
register_clcmd("vipmenu","WeaponMenu");
register_clcmd("say /vipmenu","WeaponMenu");
register_clcmd("say_team /vipmenu","WeaponMenu");
register_plugin(PLUGIN, VERSION, AUTHOR);
//Квары
cvar_vip_flag = register_cvar("vipmenu_vip_flag","t"); //Флаг доступа к меню випа
cvar_set_max_speed = register_cvar("vipmenu_set_max_speed","280"); //Скорость
new mapname[32];
get_mapname(mapname, charsmax(mapname));
new maps[][] = { "awp", "aim", "35hp", "$" };
for(new i; i < sizeof maps; i++){
if(containi(mapname, maps) != -1){
pause("ad");
return;
}
}
}
public player_respawn(id) {
if(get_admin_flag(id)) {
g_has_weapon[5][id] = true;
set_task(0.3,"TaskSpawn",id);
}
gFlSpeed[id] = 0.0;
}
public TaskSpawn(id) {
if(is_user_alive(id)) {
give_item(id,"weapon_hegrenade")
give_item(id,"weapon_flashbang")
give_item(id,"weapon_flashbang")
give_item(id,"weapon_smokegrenade")
drop_secondary(id);
g_has_weapon[0][id] = true;
fm_give_items(id,0);
cs_set_user_armor(id,100,CS_ARMOR_VESTHELM)
}
}
public NewRound() {
gRound++;
for(new i=0;i<sizeof(gUse);i++) {
gUse = 0;
}
}
public client_putinserver(id) {
for(new i=0;i<sizeof(gArrWeapon);i++) {
g_has_weapon[id] = false;
gFlSpeed[id] = 0.0;
}
if(get_admin_flag(id)) {
gbShowDamage[id] = true;
gPlTypeView[id] = 0;
} else {
gbShowDamage[id] = false;
gPlTypeView[id] = 0;
}
}
public WeaponMenu(id) {
static menu[512], len;
len = 0;
if(!get_admin_flag(id)) {
PrintChatColor(id, PRINT_COLOR_PLAYERTEAM, "%s !tУ вас недостаточно прав.", CHATTAG);
return PLUGIN_HANDLED;
}
len += formatex(menu[len], charsmax(menu) - len, "\r[\wVIP\r] \wМеню \r[\yЭто Паблик, Детка!=)\r]^n^n");
len += formatex(menu[len], charsmax(menu) - len, "\r1. \wЗолотой AWP \r(\y%d$\r)^n",gArrWeapon[1][WEAP_COST]);
len += formatex(menu[len], charsmax(menu) - len, "\r2. \wЗолотой Famas \r(\y%d$\r)^n",gArrWeapon[1][WEAP_COST]);
len += formatex(menu[len], charsmax(menu) - len, "\r3. \wЗолотой AK47 \r(\y%d$\r)^n",gArrWeapon[1][WEAP_COST]);
len += formatex(menu[len], charsmax(menu) - len, "\r4. \wЗолотой M4A1 \r(\y%d$\r)^n",gArrWeapon[1][WEAP_COST]);
len += formatex(menu[len], charsmax(menu) - len, "\r5. \wСкорость^n");
len += formatex(menu[len], charsmax(menu) - len, "\r6. \y120\wHP^n");
len += formatex(menu[len], charsmax(menu) - len, "\r7. \y16000\w$^n");
len += formatex(menu[len], charsmax(menu) - len, "\r8. \wМеню урона^n^n");
len += formatex(menu[len], charsmax(menu) - len, "\r0. \wВыход" );
new keys = MENU_KEY_0|MENU_KEY_1|MENU_KEY_2|MENU_KEY_3|MENU_KEY_4|MENU_KEY_5|MENU_KEY_6|MENU_KEY_7|MENU_KEY_8
show_menu(id, keys, menu, -1, "MenuId");
return PLUGIN_HANDLED;
}
public MenuFunc(id,key) {
if(key == 9)
return PLUGIN_HANDLED;
if(!get_admin_flag(id)) {
PrintChatColor(id, PRINT_COLOR_PLAYERTEAM, "%s !tУ вас недостаточно прав.", CHATTAG);
return PLUGIN_HANDLED;
}
if(gUse[id] >= 3 && key < 7) {
PrintChatColor(id, PRINT_COLOR_PLAYERTEAM, "%s !tНелья брать больше 3-х раз за раунд.", CHATTAG);
return PLUGIN_HANDLED;
}
if(key < 4) {
if(!is_user_alive(id)) {
PrintChatColor(id, PRINT_COLOR_PLAYERTEAM, "%s !tВы должны быть живы что бы взять оружие.", CHATTAG);
return PLUGIN_HANDLED;
}
if(gRound < 3 && key < 4) {
PrintChatColor(id, PRINT_COLOR_PLAYERTEAM, "%s !tМожно брать оружия только со второго раунда.", CHATTAG);
return PLUGIN_HANDLED;
}
// drop_secondary(id);
// fm_give_items(id,0);
key += 1;
if(cs_get_user_money(id) - gArrWeapon[key][WEAP_COST] > 0) {
cs_set_user_money(id,cs_get_user_money(id) - gArrWeapon[key][WEAP_COST]);
drop_primary(id);
g_has_weapon[key][id] = true;
fm_give_items(id,key);
gUse[id]++;
} else {
PrintChatColor(id, PRINT_COLOR_PLAYERTEAM, "%s !tНе хватает денег.");
}
WeaponMenu(id);
return PLUGIN_HANDLED;
} else {
switch(key) {
case 4: {
if(gFlSpeed[id] == 0.0) {
gFlSpeed[id] = get_pcvar_float(cvar_set_max_speed);
PrintChatColor(id, PRINT_COLOR_PLAYERTEAM, "!tВы взяли скорость.");
gUse[id]++;
Ham_ItemPreFrame_Pre(id);
} else {
PrintChatColor(id, PRINT_COLOR_PLAYERTEAM, "!tУ вас уже есть скорость!");
}
}
case 5: {
set_user_health(id,120);
PrintChatColor(id, PRINT_COLOR_PLAYERTEAM, "!tВы взяли !g120HP!t.");
gUse[id]++;
}
case 6: {
cs_set_user_money(id,16000);
PrintChatColor(id, PRINT_COLOR_PLAYERTEAM, "!tВы взяли !g16000$!t.");
gUse[id]++;
}
case 7: {
//Здесь вызывать меню настройки урона.
MenuDamage(id);
return PLUGIN_HANDLED;
}
}
}
WeaponMenu(id);
return PLUGIN_HANDLED;
}
public MenuDamage(id) {
static menu[512], len;
len = 0;
/*
[Меню отображения урона]
1. Отображать урон [Вкл]
2. Внешний вид [Круговой/Звёздочкой/Обычно]
*/
len += formatex(menu[len], charsmax(menu) - len, "\r[\yМеню отображения урона\r]^n^n");
len += formatex(menu[len], charsmax(menu) - len, "\r1. \wОтображать урон \w[\y%s\w]^n",gbShowDamage[id] ? "Выкл":"Вкл");
len += formatex(menu[len], charsmax(menu) - len, "\r2. \wВнешний вид \w[\y%s\w]^n^n",gSzView[gPlTypeView[id]]);
len += formatex(menu[len], charsmax(menu) - len, "\r0. \wВыход" );
new keys = MENU_KEY_0|MENU_KEY_1|MENU_KEY_2
show_menu(id, keys, menu, -1, "MenuDamage");
return PLUGIN_HANDLED;
}
public MenuFuncDamage(id,key) {
if(key == 9)
return PLUGIN_HANDLED;
switch(key) {
case 0: {
if(gbShowDamage[id])
gbShowDamage[id] = false;
else
gbShowDamage[id] = true;
}
case 1: {
if(gPlTypeView[id] < charsmax(gSzView)) {
gPlTypeView[id]++;
} else {
gPlTypeView[id] = 0;
}
}
}
MenuDamage(id)
return PLUGIN_HANDLED;
}
public TakeDamage(victim, inflictor, attacker, Float:damage){ //Нанесение урона.
if(!is_user_connected(attacker) || victim == attacker || !victim)
return;
new iWeaponUsed = get_user_weapon( attacker ,_,_)
for(new iweap = 0;iweap<sizeof(gArrWeapon);iweap++) {
if(iWeaponUsed == gArrWeapon[iweap][WEAP_CSW]) {
if(g_has_weapon[iweap][attacker]) {
SetHamParamFloat(4, damage * gArrWeapon[iweap][WEAP_DAMAGE])
break;
}
}
}
if( (1 <= attacker <= gMaxPlayer) && gbShowDamage[attacker] && (1 <= victim <= gMaxPlayer) && is_user_alive(attacker) ) {
new iPos = ++g_iPlayerPos[attacker]
if(gPlTypeView[attacker] == 0) {
if( iPos == sizeof(g_flCoords) ) {
iPos = g_iPlayerPos[attacker] = 0
}
} else if(gPlTypeView[attacker] == 1) {
iPos = g_iPlayerPos[attacker] = 0
} else if(gPlTypeView[attacker] == 2) {
iPos = g_iPlayerPos[attacker] = 0
}
set_hudmessage(0, 0,255, Float:g_flCoords[iPos][0], Float:g_flCoords[iPos][1], 0, 0.1, 1.0, 0.02, 0.02, -1)
new str[128];
if(gPlTypeView[attacker] == 0) {
formatex(str,charsmax( str),"%d",read_data(2))
} else if(gPlTypeView[attacker] == 1) {
formatex(str,charsmax( str),"*")
} else if(gPlTypeView[attacker] == 2) {
formatex(str,charsmax( str),"%d",read_data(2))
}
show_hudmessage(attacker, "%s", str)
}
}
new gTimeBlockMess[33];
public blockweapon(weapon,id) {
if(!is_valid_ent(weapon) || !is_user_connected(id))
return HAM_IGNORED;
if(entity_get_int(weapon, EV_INT_WEAPONKEY) != 0) {
for(new iweap = 0;iweap<sizeof(gArrWeapon);iweap++) {
if(entity_get_int(weapon, EV_INT_WEAPONKEY) == gArrWeapon[iweap][WEAP_ID]) {
if(!get_admin_flag(id)) {
if(gTimeBlockMess[id] < get_systime()) {
gTimeBlockMess[id] = get_systime();
PrintChatColor(id, PRINT_COLOR_PLAYERTEAM, "%s !tТолько !gVIP!t-игрок может поднять это оружие!", CHATTAG);
}
return HAM_SUPERCEDE; //Блокируем.
}
}
}
}
return HAM_IGNORED;
}
public fw_AddToPlayer(ent, id) { //Ловим косание с оружием.
if(!is_user_alive(id))
return HAM_IGNORED;
if(entity_get_int(ent, EV_INT_WEAPONKEY) != 0) {
new weapon = cs_get_weapon_id(ent);
for(new iweap = 0;iweap<sizeof(gArrWeapon);iweap++) {
if(weapon == gArrWeapon[iweap][WEAP_CSW]) {
if(entity_get_int(ent, EV_INT_WEAPONKEY) == gArrWeapon[iweap][WEAP_ID]) {
g_has_weapon[iweap][id] = true;
entity_set_int(ent, EV_INT_WEAPONKEY, 0);
}
}
}
}
return HAM_IGNORED;
}
stock drop_primary(id) {
new weapons[ 32 ], num;
get_user_weapons( id, weapons, num );
for( new i = 0; i < num; i++ ) {
if( PRIMARY_WEAPONS & (1<<weapons[ i ]) ) {
static wname[ 32 ];
get_weaponname( weapons[ i ], wname, sizeof wname - 1 );
engclient_cmd( id, "drop", wname );
}
}
}
stock drop_secondary(id) {
new weapons[ 32 ], num;
get_user_weapons( id, weapons, num );
for( new i = 0; i < num; i++ ) {
if( SECONDARY_WEAPONS & (1<<weapons[ i ]) ) {
static wname[ 32 ];
get_weaponname( weapons[ i ], wname, sizeof wname - 1 );
engclient_cmd( id, "drop", wname );
}
}
}
stock fm_give_items(index, num) {
new ent = engfunc(EngFunc_CreateNamedEntity, engfunc(EngFunc_AllocString, gArrWeapon[num][WEAP_NAME]))
if (!pev_valid(ent))return 0;
new Floatrigin[3];
pev(index, pev_origin, origin);
set_pev(ent, pev_origin, origin);
set_pev(ent, pev_spawnflags, pev(ent, pev_spawnflags) | SF_NORESPAWN);
dllfunc(DLLFunc_Spawn, ent);
new save = pev(ent, pev_solid);
dllfunc(DLLFunc_Touch, ent, index);
new wEnt = get_weapon_ent(index, gArrWeapon[num][WEAP_CSW]);
if(pev_valid(wEnt)) {
cs_set_weapon_ammo(wEnt, gArrWeapon[num][WEAP_CLIP])
cs_set_user_bpammo (index, gArrWeapon[num][WEAP_CSW], gArrWeapon[num][WEAP_AMMO])
}
if(pev(ent, pev_solid) != save)return ent;
engfunc(EngFunc_RemoveEntity, ent);
return -1;
}
stock get_weapon_ent(id,wpnid=0,wpnName[]="") {
static newName[32]
if(wpnid) get_weaponname(wpnid,newName,31)
else formatex(newName,31,"%s",wpnName)
if(!equal(newName,"weapon_",7))
format(newName,31,"weapon_%s",newName)
new ent
while((ent = engfunc(EngFunc_FindEntityByString,ent,"classname",newName)) && pev(ent,pev_owner) != id) {}
return ent
}
public fw_SetModel(entity, model[]) {
if(!is_valid_ent(entity))
return FMRES_IGNORED;
static szClassName[33];
entity_get_string(entity, EV_SZ_classname, szClassName, charsmax(szClassName));
if(!equal(szClassName, "weaponbox"))
return FMRES_IGNORED;
static iOwner;
iOwner = entity_get_edict(entity, EV_ENT_owner);
static iweaponID;
for(new iweap = 0;iweap<sizeof(gArrWeapon);iweap++) {
if(equal(model, gArrWeapon[iweap][WEAP_OLDMODELS])) {
iweaponID = find_ent_by_owner(-1, gArrWeapon[iweap][WEAP_NAME], entity);
if(!is_valid_ent(iweaponID))
return FMRES_IGNORED;
if(g_has_weapon[iweap][iOwner]) {
g_has_weapon[iweap][iOwner] = false;
entity_set_int(iweaponID, EV_INT_WEAPONKEY, gArrWeapon[iweap][WEAP_ID]);
entity_set_int(entity, EV_INT_WEAPONKEY, gArrWeapon[iweap][WEAP_ID]);
entity_set_model(entity, gArrWeapon[iweap][WEAP_W]);
return FMRES_SUPERCEDE;
}
}
}
return FMRES_IGNORED;
}
public Item_Deploy_Post(ent) {
const XO_WEAPON = 4
const m_pPlayer = 41
new id = get_pdata_cbase( ent, m_pPlayer, XO_WEAPON );
replace_weapon_models(id);
}
replace_weapon_models(id) {
if(is_user_connected(id)) {
new weapon = get_pdata_int(get_pdata_cbase(id, 373, 5), 43, 4)
for(new iweap = 0;iweap<sizeof(gArrWeapon);iweap++) {
if(weapon == gArrWeapon[iweap][WEAP_CSW]) {
if(g_has_weapon[iweap][id]) {
set_pev(id, pev_viewmodel2, gArrWeapon[iweap][WEAP_V]);
set_pev(id, pev_weaponmodel2, gArrWeapon[iweap][WEAP_P]);
}
}
}
}
}
public get_admin_flag(id) {
new flags[24]
get_pcvar_string(cvar_vip_flag, flags, charsmax(flags))
if(get_user_flags(id) & read_flags(flags)) {
return true;
}
return false;
}
public Ham_ItemPreFrame_Pre(id) {
if(is_user_connected(id) && is_user_alive(id)) {
if(gFlSpeed[id] != 0) {
set_user_maxspeed(id,gFlSpeed[id]);
return HAM_SUPERCEDE;
}
}
return HAM_IGNORED;
}
public Fwd_ItemDeploy_Knife_Post( ent ) {
const XO_WEAPON = 4
const m_pPlayer = 41
new id = get_pdata_cbase( ent, m_pPlayer, XO_WEAPON );
new weapon = get_pdata_int(get_pdata_cbase(id, 373, 5), 43, 4)
for(new iweap = 0;iweap<sizeof(gArrWeapon);iweap++) {
if(weapon == gArrWeapon[iweap][WEAP_CSW]) {
if(g_has_weapon[iweap][id]) {
set_pev(id, pev_viewmodel2, gArrWeapon[iweap][WEAP_V]);
set_pev(id, pev_weaponmodel2, gArrWeapon[iweap][WEAP_P]);
}
}
}
}
вот ошибка
//AMXXPC compile.exe
// by the AMX Mod X Dev Team
//// weapon_menu.sma
//
// D:\╠юш фюъєьхэЄ√\Counter-Strike\╠√ ╧ э√х фхЄър\cstrike\addons\amxmodx\scripti
ng\weapon_menu.sma(1) : error 010: invalid function or declaration
//
// 1 Error.
// Could not locate output file D:\╠юш фюъєьхэЄ√\Counter-Strike\╠√ ╧ э√х фхЄър\c
strike\addons\amxmodx\scripting\compiled\weapon_menu.amx (compile failed).
//
// Compilation Time: 1,28 sec
// ----------------------------------------
Press enter to exit ...
вот файл
//AMXXPC compile.exe
// by the AMX Mod X Dev Team
//// weapon_menu.sma
//
// D:\╠юш фюъєьхэЄ√\Counter-Strike\╠√ ╧ э√х фхЄър\cstrike\addons\amxmodx\scripti
ng\weapon_menu.sma(1) : error 010: invalid function or declaration
//
// 1 Error.
// Could not locate output file D:\╠юш фюъєьхэЄ√\Counter-Strike\╠√ ╧ э√х фхЄър\c
strike\addons\amxmodx\scripting\compiled\weapon_menu.amx (compile failed).
//
// Compilation Time: 1,28 sec
// ----------------------------------------
Press enter to exit ...
вот файл
Вложения
-
17,2 KB Просмотры: 12