Smoke: HealthNade 0.0.4b Ошибка в консоле

Статус
В этой теме нельзя размещать новые ответы.
Сообщения
43
Реакции
-4
Помог
2 раз(а)
Ошибка
Load fails: Plugin uses an unknown function (name "get_ent_data_float") - check your modules.ini.
ОС
Linux
Amx Mod X
1.9.0
Билд
ReHLDS version: 3.7.0.695-dev
ReGamedll
ReGameDLL version: 5.12.0.425-dev
Версия Metamod
Metamod v1.21p37  2013/05/30 (5:13)
Список метамодулей
[ 1] SafeNameAndChat  RUN   -    SafeNameAndChat.  v1.1      ini   ANY   ANY  
[ 2] Reunion RUN - reunion_mm_i386. v0.1.0.1 ini Start Never
[ 3] ReAuthCheck RUN - reauthcheck_mm_i v0.1.6 ini Start Never
[ 4] AMX Mod X RUN - amxmodx_mm_i386. v1.9.0.5 ini Start ANY
[ 5] VoiceTranscoder RUN - VoiceTranscoder. v2020MA2 ini ANY ANY
[ 6] ProcessCmds RUN - processcmds_mm_i v1.1.6 ini Start Never
[ 7] ReSemiclip RUN - resemiclip_mm_i3 v2.3.9 ini Chlvl ANY
[ 8] WHBlocker RUN - whblocker_mm_i38 v1.5.697 ini Chlvl ANY
[ 9] Rechecker RUN - rechecker_mm_i38 v2.4 ini Chlvl ANY
[10] ReAimDetector RUN - reaimdetector_am v0.2.2 pl4 ANY Never
[11] Engine RUN - engine_amxx_i386 v1.8.2 pl4 ANY ANY
[12] FakeMeta RUN - fakemeta_amxx_i3 v1.8.2 pl4 ANY ANY
[13] MySQL RUN - mysql_amxx_i386. v1.8.2 pl4 ANY ANY
[14] ReAPI RUN - reapi_amxx_i386. v5.11.0. pl4 ANY Never
[15] Ham Sandwich RUN - hamsandwich_amxx v1.8.2 pl4 ANY ANY
[16] CSX RUN - csx_amxx_i386.so v1.9.0.5 pl4 ANY ANY
[17] CStrike RUN - cstrike_amxx_i38 v1.8.2 pl4 ANY ANY
[18] Fun RUN - fun_amxx_i386.so v1.8.2 pl4 ANY ANY
[19] hackdetector RUN - hackdetector_amx v0.15.32 pl4 ANY ANY
19 plugins, 19 running
Список плагинов
[  1] Menus Front-End         18.12.18    AMXX Dev Team &   amxmodmenu_rbs.  running  
[ 2] [182] AMXBans RBS 19.11.29 SKAJIbnEJIb & La amxbans_rbs.amx running
[ 3] [182] Cvar On Map 19.12.07 SKAJIbnEJIb cvar_on_map.amx running
[ 4] [182] Ultimate Gag 17.12.22BE SKAJIbnEJIb ultimate_gag.am running
[ 5] [ReAPI][182] Ultimate 17.08.28 SKAJIbnEJIb ultimate_gag_re running
[ 6] [182] Ultimate Informe 17.10.30 SKAJIbnEJIb ultimate_inform running
[ 7] [182] Ultimate Weapons 19.11.29 SKAJIbnEJIb ultimate_weapon running
[ 8] [182] VoteBan RBS 17.10.30 SKAJIbnEJIb voteban_rbs.amx running
[ 9] [182] Radio RBS 20.03.06 SKAJIbnEJIb radio_rbs.amxx running
[ 10] [182] PTB RBS 17.10.30 Ptahhotep & SKAJ ptb_rbs.amxx running
[ 11] Admin Commands 1.8.2 AMXX Dev Team admincmd.amxx running
[ 12] Slots Reservation 1.8.2 AMXX Dev Team adminslots.amxx running
[ 13] [182] Ad From Server 19.08.29 SKAJIbnEJIb ad_from_server. running
[ 14] Admin Votes 1.8.2 AMXX Dev Team adminvote.amxx running
[ 15] Admin Chat 1.8.M AMXX Dev Team adminchat.amxx running
[ 16] [190] Army Ranks Ultim 19.11.29 SKAJIbnEJIb army_ranks_ulti running
[ 17] [182] AR Bets 17.10.30 SKAJIbnEJIb ar_bets.amxx running
[ 18] [182] AfkKicker RBS 19.08.28 SKAJIbnEJIb afkkicker_rbs.a running
[ 19] Admin Free Look 2.0 Jim admin_freelook. running
[ 20] [182] AC Spectator ESP 17.08.09 SKAJIbnEJIb & Ko ac_esp.amxx running
[ 21] Commands Menu 1.8.2 AMXX Dev Team cmdmenu.amxx running
[ 22] [182] CsStats MySQL 19.08.27 SKAJIbnEJIb csstats_mysql.a running
[ 23] [182] Stats Configurat 18.05.15 SKAJIbnEJIb & AM statscfg_rbs.am running
[ 24] [182] StatsX RBS 19.08.28 SKAJIbnEJIb & AM statsx_rbs.amxx running
[ 25] [182] MapChooser RBS 20.03.16 SKAJIbnEJIb & UF mapchooser_rbs. running
[ 26] CS Misc. Stats 1.8.2 AMXX Dev Team miscstats.amxx running
[ 27] Multi-Lingual System 1.8.2 AMXX Dev Team multilingual.am running
[ 28] Pause Plugins 1.8.2 AMXX Dev Team pausecfg.amxx running
[ 29] [DD] Quick defuse 1.0 Deadly|Darkness dd_qdefuse.amxx running
[ 30] Players Menu 1.8.M AMXX Dev Team plmenu.amxx running
[ 31] [182] Piss RBS 17.10.30 SKAJIbnEJIb & KR piss_rbs.amxx running
[ 32] Restrict Weapons 1.8.2 AMXX Dev Team restmenu.amxx running
[ 33] CS Stats Logging 1.8.2 AMXX Dev Team stats_logging.a running
[ 34] [182] NextMap 18.09.25 SKAJIbnEJIb & AM nextmap.amxx running
[ 35] [182] TimeLeft 18.09.25 SKAJIbnEJIb & AM timeleft.amxx running
[ 36] Teleport Menu 1.8.2 AMXX Dev Team telemenu.amxx running
[ 37] [182] Top Award RBS 19.08.28 SKAJIbnEJIb topaward_rbs.am running
[ 38] ReAimDetector API 0.2.2 ReHLDS Team reaimdetector.a running
[ 39] Plugin Menu 1.8.2 AMXX Dev Team pluginmenu.amxx running
[ 40] Anti DoubleDuck 1.7 Numb antidoubleduck. running
[ 41] [182] Block Reconnect 17.08.09 ShaTalKiN Block_Reconnect running
[ 42] [182] BackWeapons RBS 17.08.11 SKAJIbnEJIb & ho backweapons_rbs running
[ 43] [SRB] Fix Recoil 0.1 ServerBy905 Team Diak.amxx running
[ 44] Bomb Timer 3.2 Twe3k Bomb_DhuD.amxx running
[ 45] [182] Balancing Map Fu 17.10.30 SKAJIbnEJIb balancing_map_f running
[ 46] [182] Ultimate Models 19.12.07 SKAJIbnEJIb ultimate_models running
[ 47] [182] Chat RBS 19.12.23 SKAJIbnEJIb chat_rbs.amxx running
[ 48] [182] Skill ELO 19.09.06 SKAJIbnEJIb skill_elo.amxx running
[ 49] [182] Warmup RBS 19.12.23 SKAJIbnEJIb warmup_rbs.amxx running
[ 50] [182] Kill Assist RBS 19.11.14 SKAJIbnEJIb & Di killassist_rbs. running
[ 51] [182] High Ping Kicker 19.11.12 SKAJIbnEJIb hpk_rbs.amxx running
[ 52] [182] Stimulation RBS 19.11.02 SKAJIbnEJIb stimulation_rbs running
[ 53] [182] MapsMenu RBS 19.09.01 SKAJIbnEJIb & AM mapsmenu_rbs.am running
[ 54] [182] ESP RBS 17.10.30 SKAJIbnEJIb & Ko esp_rbs.amxx running
[ 55] [182] Nick FIX RBS 17.08.20 SKAJIbnEJIb nickfix_rbs.amx running
[ 56] [182] Parachute RBS 17.12.12 KRoT@L/JTP10181 parachute_rbs.a running
[ 57] [182] Damager RBS 19.08.30 SKAJIbnEJIb damager_rbs.amx running
[ 58] [182] Snipers RBS 19.11.29 SKAJIbnEJIb snipers_rbs.amx running
[ 59] [182] WeaponMenu RBS 20.03.20 SKAJIbnEJIb weaponmenu_rbs. running
[ 60] [182] Chat Controller 19.08.28 SKAJIbnEJIb chat_controller running
[ 61] Block HudTextArgs 1.0 ConnorMcLeod hudTextArgsBloc running
[ 62] Weapon Model + Sound R 1.2 GHW_Chronic new_weapons.amx running
[ 63] [182] VIP RBS 19.12.09 SKAJIbnEJIb vip_rbs.amxx running
[ 64] Smoke: HealthNade 0.0.3 wopox1337 Smoke_HealthNad running
[ 65] [MG] Hook by Nickron 2.0 LLInH9rA, Remake csjump_lejkee18 running
[ 66] Nade Messages 1.0 v3x nademessages.am running
[ 67] DefaultNameKicker 1.0 KsV DefaultNameKick running
[ 68] C4 CD Voice 1.1 TTuCTOH c4cdvoice.amxx running
[ 69] [182] Demo Recorder RB 18.02.08 SKAJIbnEJIb demorecorder_rb running
[ 70] [182] Ultimate Knife 19.11.12 SKAJIbnEJIb ultimate_knife. running
[ 71] Join_Music 1.2.3 White Panther join.amxx running
[ 72] Black and White Smoke 1.1 xPaw/Leo_[BH] smoke_black_whi running
[ 73] Real Damage 1.0 Leo_[BH] real_damage.amx running
[ 74] ResetScore 1.0 Leo_[BH] resetscore.amxx running
[ 75] Time Lights 1.1 Leo_[BH] time_light.amxx running
[ 76] HackDetector 0.15.lite Lev @ AGHL.RU De hackdetector.am running
[ 77] Kills Counter 0.3 serfreeman1337 kills_counter.a running
[ 78] [ReAPI] No Team Flash 1.0 ReHLDS Team noteamflash.amx running
[ 79] AMXBans: Screens 1.8.2 MA: 1.6.12 Larte Team amxbans_ssban.a running
79 plugins, 79 running
Автор плагина
wopox1337
Версия плагина
0.0.4b
Исходный код
/**
* Copyright (C) Dev-CS Team, 2018
*
* This software is licensed under the GNU General Public License, version 3 or higher.
* Additional exceptions apply. For full license details, see LICENSE.txt or visit:
* https://alliedmods.net/amxmodx-license
*
* Description:
* This plugin add a new grenade item to game names as 'HealthNade'.
* The grenade will give additional health of allies (or all) nearby.
*
* Changelog:
* - 0.0.1 (20.11.17):
* - Init;
* - 0.0.2 (23.11.17):
* - FIX: AMXX 1.8.2 compilation;
* - Removed HamSandwich module.
* - 0.0.3 (25.12.17):
* - FIX: some bugs with 'emessage' flood; (Thanks to Mistrick)
* - Removed AMXX 1.8.2 support;
* - 0.0.4 (09.08.18):
* - FIX: The blinding effect is no longer reset;
* - Add: ScreenFade effect settings;
* - Add: Customisable models use (on/off);
* - Rework function for restrict item;
* - Simply API: SHN_S(G)etStatus (realy nned it?!);
* - 0.0.4b (19.12.19):
* - Fix sprites show & work.
*
* TODO:
* - Change the principle of the replacement Item (smart replacement).
*
* Credits: Arkshine, https://forums.alliedmods.net/showpost.php?p=1567176&postcount=16
*/

#include <amxmodx>
#include <fakemeta>
#include <engine>
#include <fun>
#include <csx>

/* Settings */
/* Enable action only for the privileged */
// #define ACCESS_FLAGS ( ADMIN_LEVEL_H )

/* Enable action only for teammates */
// #define ONLY_FOR_TEAMMATES

/* Enable Screenfade effect */
#define EFFECT_SCREENFADE

const HEALTH_TO_HEAL = 50;
const HEALTH_MAX = 100;
const HEAL_RADIUS = 300;

/* You can disable those models */
#define MODEL_V "models/v_he_mk_nade1.mdl"
#define MODEL_P "models/p_he_mk_nade1.mdl"
#define MODEL_W "models/w_he_mk_nade1.mdl"

new const SPRITE_EXPLODE1[] = "sprites/heal_explodec.spr";
new const SPRITE_PROS[] = "sprites/heal_shapec.spr";

new const SOUND_HEAL[] = "woomen_expr.wav";
/* End of settings */

enum {
XO_WEAPON = 4,
XO_CGRENADE = 5,
m_pPlayer = 41,
m_usEvent = 114
}

new const EXCLASS[] = "grenade";

enum { STATUSICON_HIDE = 0, STATUSICON_FLASH = 2 };

const flagSmokeEvent = (1 << 1);

#define IsSgGrenade(%1) (get_pdata_int(%1, m_usEvent, XO_CGRENADE) & flagSmokeEvent)

#define _GetEntOwner(%1) pev(%1, pev_owner)
#define _GetEntOrigin(%1,%2) pev(%1, pev_origin, %2)

#define _SetViewModel(%1,%2) set_pev(%1, pev_viewmodel2, %2)
#define _SetWeaponModel(%1,%2) set_pev(%1, pev_weaponmodel2, %2)
#define _SetWorldModel(%1,%2) engfunc(EngFunc_SetModel, %1, %2)

#define _RemoveEntity(%1) engfunc(EngFunc_RemoveEntity, %1)

#define _get_blindStartTime(%1) get_ent_data_float(%1, "CBasePlayer", "m_blindStartTime")
#define _get_blindFadeTime(%1) get_ent_data_float(%1, "CBasePlayer", "m_blindFadeTime")

new g_MsgId_StatusIcon, g_MsgId_ScreenFade;

new g_pFirstExplosion,
g_pPros,
g_pCircle;

enum status_s { status_DISABLED = 0, status_ENABLED = 1 };
new status_s: g_bCanUseItem = status_ENABLED;

new const VERSION[] = "0.0.4b";

public plugin_natives()
{
register_native("SHN_SetStatus", "native__SetStatus", .style = 0);
register_native("SHN_GetStatus", "native__GetStatus", .style = 0);
}

public plugin_init() {
register_plugin("Smoke: HealthNade", VERSION, "wopox1337");

g_MsgId_StatusIcon = get_user_msgid("StatusIcon");
g_MsgId_ScreenFade = get_user_msgid("ScreenFade");

register_touch(EXCLASS, "*", "CGrenade_ExplodeTouch");

register_event("CurWeapon", "Event_CurWeapon", "be", "1=1");
}

public plugin_precache() {
#if defined MODEL_V
precache_model(MODEL_V);
#endif
#if defined MODEL_P
precache_model(MODEL_P);
#endif
#if defined MODEL_W
precache_model(MODEL_W);
#endif

g_pFirstExplosion = precache_model(SPRITE_EXPLODE1);
g_pPros = precache_model(SPRITE_PROS);
g_pCircle = precache_model("sprites/shockwave.spr");

precache_sound(SOUND_HEAL);
}

public Event_CurWeapon(pPlayer) {
enum { WeaponID = 2 };
if(read_data(WeaponID) == CSW_SMOKEGRENADE) {
if(!IsAllowedToUse(pPlayer)) return;

#if defined MODEL_V
OnPlayer_SetViewModels(pPlayer);
#endif

Send_StatusIcon__Cross(pPlayer);
}
else Send_StatusIcon__Cross(pPlayer, .status = STATUSICON_HIDE);
}

public grenade_throw(pPlayer, pEnt, w_id) {
if(w_id != CSW_SMOKEGRENADE)
return;

if(!IsAllowedToUse(pPlayer))
return;

#if defined MODEL_W
OnGrenade_SetWorldModel(pEnt);
#endif
}

public CGrenade_ExplodeTouch(const pEnt, const pOther) {
// Filter to another grenades type
if(!IsSgGrenade(pEnt))
return;

static iOwner; iOwner = _GetEntOwner(pEnt);

if(!IsAllowedToUse(iOwner))
return;

static Float: fOrigin[3], iOrigin[3];
_GetEntOrigin(pEnt, fOrigin);
FVecIVec(fOrigin, iOrigin);

// Show visuals
Send_Explode(iOrigin);
Send_Pros(iOrigin);
Send_ShockWave(iOrigin);
OnGrenade_PlaySound(pEnt);

// Removed default smoke entity, and his detonate event accordingly
OnGrenade_RemoveByTouch(pEnt);

// Action on near players
HealPlayersOnRadius(iOwner, fOrigin);
}

stock HealPlayersOnRadius(pInflictor, Float: fOrigin[3]) {
#if !defined ONLY_FOR_TEAMMATES
new iTeam = get_user_team(pInflictor);
#endif

for(new pPlayer = 1; pPlayer <= MaxClients; pPlayer++) {
if(is_user_alive(pPlayer)) {

#if !defined ONLY_FOR_TEAMMATES
if(iTeam != get_user_team(pPlayer))
continue;
#endif
#pragma unused pInflictor

static Float: playerOrigin[3];
_GetEntOrigin(pPlayer, playerOrigin);

if(get_distance_f(fOrigin, playerOrigin) < HEAL_RADIUS)
OnPlayer_HealEvent(pPlayer);
}
}
}

stock OnPlayer_HealEvent(const pPlayer) {
set_user_health(pPlayer, min(get_user_health(pPlayer) + HEALTH_TO_HEAL, HEALTH_MAX));

#if defined EFFECT_SCREENFADE
if(!IsBlind(pPlayer))
__UTIL_ScreenFade(pPlayer);
#endif
}

#if (defined MODEL_V || defined MODEL_P)
stock OnPlayer_SetViewModels(const pPlayer) {
#if defined MODEL_V
_SetViewModel(pPlayer, MODEL_V);
#endif
#if defined MODEL_P
_SetWeaponModel(pPlayer, MODEL_P);
#endif
}
#endif

stock OnGrenade_SetWorldModel(const pEnt)
_SetWorldModel(pEnt, MODEL_W);

stock OnGrenade_RemoveByTouch(const pEnt)
_RemoveEntity(pEnt);

stock Send_StatusIcon__Cross(const pPlayer, status = STATUSICON_FLASH) {
message_begin(MSG_ONE_UNRELIABLE, g_MsgId_StatusIcon, .player = pPlayer);
write_byte(status);
write_string("cross");
write_byte(0);
write_byte(255);
write_byte(0);
message_end();
}

stock OnGrenade_PlaySound(const pEnt)
engfunc(EngFunc_EmitSound, pEnt, CHAN_WEAPON, SOUND_HEAL, VOL_NORM, ATTN_NORM, 0, PITCH_NORM);


stock Send_Explode(iOrigin[3]) {
message_begin(MSG_PVS, SVC_TEMPENTITY);
write_byte(TE_EXPLOSION);
write_coord(iOrigin[0]);
write_coord(iOrigin[1]);
write_coord(iOrigin[2] + 65);
write_short(g_pFirstExplosion);
write_byte(30);
write_byte(20);
write_byte(TE_EXPLFLAG_NOSOUND | TE_EXPLFLAG_NOPARTICLES);
message_end();
}

stock Send_Pros(iOrigin[3]) {
message_begin(MSG_PVS, SVC_TEMPENTITY);
write_byte(TE_SPRITETRAIL);
write_coord(iOrigin[0]);
write_coord(iOrigin[1]);
write_coord(iOrigin[2] + 20);
write_coord(iOrigin[0]);
write_coord(iOrigin[1]);
write_coord(iOrigin[2] + 80);
write_short(g_pPros);
write_byte(20);
write_byte(20);
write_byte(4);
write_byte(20);
write_byte(10);
message_end();
}

stock Send_ShockWave(iOrigin[3]) {
message_begin(MSG_PVS, SVC_TEMPENTITY);
write_byte(TE_BEAMCYLINDER);
write_coord(iOrigin[0]);
write_coord(iOrigin[1]);
write_coord(iOrigin[2]);
write_coord(iOrigin[0]);
write_coord(iOrigin[1]);
write_coord(iOrigin[2] + HEAL_RADIUS);
write_short(g_pCircle);
write_byte(0);
write_byte(1);
write_byte(5);
write_byte(30);
write_byte(1);
write_byte(10);
write_byte(255);
write_byte(40);
write_byte(255);
write_byte(5);
message_end();
}

stock __UTIL_ScreenFade(const pPlayer, iColor[3] = {170, 255, 0}, iAlpha = 80, Float: flFxTime = 1.0, Float: flHoldTime = 0.3) {
const FFADE_IN = 0x0000;

message_begin(MSG_ONE_UNRELIABLE, g_MsgId_ScreenFade, .player = pPlayer);
write_short(FixedUnsigned16(flFxTime));
write_short(FixedUnsigned16(flHoldTime));
write_short(FFADE_IN);
write_byte(iColor[0]);
write_byte(iColor[1]);
write_byte(iColor[2]);
write_byte(iAlpha);
message_end();
}

stock FixedUnsigned16(Float:flValue, iScale = (1 << 12)) {
return clamp(floatround(flValue * iScale), 0, 0xFFFF);
}

stock IsUserHaveAccessToUse(const pPlayer) {
// Anytime we can add other checks like cached bool
return (get_user_flags(pPlayer) & ACCESS_FLAGS);
}

bool: IsAllowedToUse(pPlayer) {
#pragma unused pPlayer

#if defined ACCESS_FLAGS
if(!IsUserHaveAccessToUse(pPlayer)) {
return false;
}
#endif

if(g_bCanUseItem == status_DISABLED) {
// client_print_color(pPlayer, print_team_red, "^3 You no may use this grenade now!");
return false;
}

// Also you can add another conditions there...
return true;
}

stock bool: IsBlind(pPlayer) {
return bool:(Float: _get_blindStartTime(pPlayer) + Float: _get_blindFadeTime(pPlayer) >= get_gametime());
}

/* API?! */

/**
* Set item status to use.
*
* @note Usage examples:
* SHN_SetStatus(1);
*
* @param status: 1 - enabled / 0 - disabled
*
* @noreturn
*/
// native SHN_SetStatus(status)
public native__SetStatus(plugin_id, argc)
{
enum { arg_status = 1 };

g_bCanUseItem = get_param(arg_status) == 1 ? status_ENABLED : status_DISABLED;
}

/**
* Retrieves the item status to use.
*
* @note Usage examples:
* SHN_GetStatus();
*
* @return Current status: 1 - enabled / 0 - disabled
*/
// native SHN_GetStatus()
public native__GetStatus(plugin_id, argc)
{
return g_bCanUseItem == status_ENABLED ? status_ENABLED : status_DISABLED;
}
Какого модуля не хватает, что то я не пойму, помогите пожалуйста
 
В этой теме было размещено решение! Перейти к решению.
Сообщения
1,340
Реакции
529
Помог
91 раз(а)
VaDoS1997, обновите все модули до 1.9.0
[11] Engine RUN - engine_amxx_i386 v1.8.2 pl4 ANY ANY
[12] FakeMeta RUN - fakemeta_amxx_i3 v1.8.2 pl4 ANY ANY
[13] MySQL RUN - mysql_amxx_i386. v1.8.2 pl4 ANY ANY
[15] Ham Sandwich RUN - hamsandwich_amxx v1.8.2 pl4 ANY ANY
[17] CStrike RUN - cstrike_amxx_i38 v1.8.2 pl4 ANY ANY
[18] Fun RUN - fun_amxx_i386.so v1.8.2 pl4 ANY ANY
8 Май 2020
и
[ 9] Rechecker RUN - rechecker_mm_i38 v2.4
до 2.5
Чтобы сервер потом не падал
 
Сообщения
43
Реакции
-4
Помог
2 раз(а)
Всё хилка работает, но спрайты нет
 
Сообщения
43
Реакции
-4
Помог
2 раз(а)
Спасибо вам огромное всё работает на ура)
 
Статус
В этой теме нельзя размещать новые ответы.

Пользователи, просматривающие эту тему

Сейчас на форуме нет ни одного пользователя.
Сверху Снизу