Не воспроизводит звук в игре

Сообщения
460
Реакции
68
Помог
7 раз(а)
Ошибка
Ошибок нет
ОС
Linux
Amx Mod X
AMX Mod X 1.9.0.5263 (http://www.amxmodx.org)
Authors:
David "BAILOPAN" Anderson, Pavol "PM OnoTo" Marko
Felix "SniperBeamer" Geyer, Jonny "Got His Gun" Bergstrom
Lukasz "SidLuke" Wlasinski, Christian "Basic-Master" Hammacher
Borja "faluco" Ferrer, Scott "DS" Ehlert
Compiled: Oct 27 2019 16:23:31
Built from: https://github.com/alliedmodders/amxmodx/commit/15a14a0
Build ID: 5263:15a14a0
Core mode: JIT+ASM32
Билд
Protocol version 48
Exe version 1.1.2.7/Stdio (cstrike)
ReHLDS version: 3.7.0.696-dev
Build date: 18:46:47 May 18 2020 (2228)
Build from: https://github.com/dreamstalker/rehlds/commit/987ee51
ReGamedll
ReGameDLL version: 5.17.0.466-dev
Build date: 02:56:24 May 27 2020
Build from: https://github.com/s1lentq/ReGameDLL_CS/commit/bffb373
Версия Metamod
Metamod-r v1.3.0.128, API (5:13)
Metamod-r build: 17:47:54 Aug 24 2018
Metamod-r from: https://github.com/theAsmodai/metamod-r/commit/0cf2f70
Список метамодулей
[ 1] SafeNameAndChat  RUN   -    SafeNameAndChat.so          v1.1             ini  ANY   ANY  
[ 2] Reunion RUN - reunion_mm_i386.so v0.1.0.92c ini Start Never
[ 3] ReAuthCheck RUN - reauthcheck_mm_i386.so v0.1.6 ini Start Never
[ 4] VoiceTranscoder RUN - VoiceTranscoder.so v2017RC5 ini ANY ANY
[ 5] AMX Mod X RUN - amxmodx_mm_i386.so v1.9.0.5263 ini Start ANY
[ 6] WHBlocker RUN - whblocker_mm_i386.so v1.5.696 ini Chlvl ANY
[ 7] ReSemiclip RUN - resemiclip_mm_i386.so v2.3.9 ini Chlvl ANY
[ 8] Rechecker RUN - rechecker_mm_i386.so v2.5 ini Chlvl ANY
[ 9] YaPB RUN - yapb.so v2.92 ini Chlvl ANY
[10] ReAimDetector RUN - reaimdetector_amxx_i386.so v0.2.2 pl5 ANY Never
[11] ReAPI RUN - reapi_amxx_i386.so v5.14.0.195-dev pl5 ANY Never
[12] SQLite RUN - sqlite_amxx_i386.so v1.9.0.5263 pl5 ANY ANY
[13] hackdetector RUN - hackdetector_amxx_i386.so v0.15.328.lite pl5 ANY ANY
[14] CStrike RUN - cstrike_amxx_i386.so v1.9.0.5263 pl5 ANY ANY
[15] Engine RUN - engine_amxx_i386.so v1.9.0.5263 pl5 ANY ANY
[16] FakeMeta RUN - fakemeta_amxx_i386.so v1.9.0.5263 pl5 ANY ANY
[17] Ham Sandwich RUN - hamsandwich_amxx_i386.so v1.9.0.5263 pl5 ANY ANY
[18] SxGeo RUN - sxgeo_amxx_i386.so v2.2 pl5 ANY Never
18 plugins, 18 running
Список плагинов
[  1] FreshBans               1.4.2b      kanagava          fresh_bans_142_  running  
[ 2] ReAimDetector API 0.2.2 ReHLDS Team reaimdetector.a running
[ 3] ScreenMaker 1.1 neygomon screen_maker.am running
[ 4] CSStatsX SQL 0.7.4+2 serfreeman1337 csstatsx_sql.am running
[ 5] RC BaseChanger freesrv custom rc_basechanger. stopped
[ 6] ReChecker Logging freesrv custom rc_logging.amxx running
[ 7] Lite Admin ESP 1.1 neygomon, AcE admin_esp_ace.a running
[ 8] Advanced Kill Assists 1.3b Xelson next21_kill_ass running
[ 9] Admin Base 1.9.0.5263 AMXX Dev Team admin.amxx running
[ 10] B_F_HUD 1.0 mut2nt/HARDCORE B_F_H.amxx running
[ 11] Ping Control 1.33 neygomon+wopox+H ping_control_N_ running
[ 12] AFK Control ReNew 1.2(a) neygomon afk_control.amx running
[ 13] AES: StatsX 0.5+1 serfreeman1337 aes_statsx_cstr running
[ 14] Stats Configuration 1.9.0.5263 AMXX Dev Team statscfg.amxx running
[ 15] Advanced Gag 1.9.0 neygomon amx_gag.amxx running
[ 16] Maps Menu 1.9.0.5263 AMXX Dev Team mapsmenu.amxx running
[ 17] Server Menu 1.5.0 F@nt0M server_menu.amx running
[ 18] Parachute Lite [ReAPI] 14.0 Leo_[BH] parachute_leo_1 running
[ 19] Demo Recorder 2.4.1 F@nt0M demo_recorder.a running
[ 20] Rock to Ban 1.02 Safety1st rock2ban.amxx running
[ 21] Players Menu 1.7 neugomon players_menu.am running
[ 22] [ReAPI] Kills Counter 0.3 serfreeman1337 kills_counter.a running
[ 23] lite screen fade 1.0 AcE re_lite_screen_ running
[ 24] [ReAPI] Damager 1.1 phe re_damager.amxx running
[ 25] SF Warn Menu 0.1.4g serfreeman1337 sf_admin_warns. running
[ 26] AES: StatsX Info Rank 0.1 serfreeman1337 aes_statsx_rank running
[ 27] Adverts 1.0 pUzzlik adverts_message running
[ 28] Advanced MapChooser 1.4 neygomon map_chooser_CSD running
[ 29] GameName Changer 1.0 neugomon gamename_change running
[ 30] DM AutoBalance 0.4.0 Nordic Warrior AutoBalance.amx running
[ 31] AntiFlood Change Name 28.11.2018 sergrib AntiFlood_Chang running
[ 32] Radio Hudmsg Block 1.0 AcE radio_hudmsg_bl running
[ 33] resetscore(ReAPI) 1.0 Phantom resetscore.amxx running
[ 34] ProKreedz Hook v2.3 vato loco [GE-S] dr_hook.amxx running
[ 35] BunnyHop 1.0 PurposeLess bunnyhop.amxx running
[ 36] Easy MultiJump 1.6 twistedeuphoria/ reapi_multijump running
[ 37] CSDM Core 0.0.8 Vaqtincha csdm_core.amxx running
[ 38] CSDM Equip Manager 0.0.8 Vaqtincha csdm_equip_mana running
[ 39] CSDM Map Cleaner 0.0.8 Vaqtincha csdm_map_cleane running
[ 40] CSDM Misc 0.0.8 Vaqtincha csdm_misc.amxx running
[ 41] CSDM Protection 0.0.8 Vaqtincha csdm_protection running
[ 42] CSDM Spawn Manager 0.0.8 Vaqtincha csdm_spawn_mana running
[ 43] AMX Vampire 0.1 F@nt0M amx_vampire.amx running
[ 44] [SxGeo] Connect Info 1.0p s1lent sxgeo_connect_i running
[ 45] Steam Models 0.1b+mod.l Freedo.m steam_models.am running
[ 46] Admin Loger 1.0 HARDCORE admin_loger.amx running
[ 47] Team Select 1.6.0 F@nt0M teamselect.amxx running
[ 48] Weaponmenu 1.0 HARDCORE weaponmenu.amxx running
[ 49] Music Connection 1.0.0 Jumper Music_Connectio running
[ 50] Lite Translit 2.8 neygomon lite_translit_c running
[ 51] Ping Faker 1.3 MeRcyLeZZ pingfaker.amxx running
[ 52] Advanced Experience Sy 0.5.9 [REA serfreeman1337/s aes_main.amxx running
[ 53] AES: CStrike Addon 0.5.9 [REA serfreeman1337/s aes_exp_cstrike running
[ 54] AES: Informer 0.5.9 [REA serfreeman1337/s aes_informer.am running
[ 55] AES: Admin Tools 0.5.9 [REA serfreeman1337/s aes_exp_editor. running
Автор плагина
mut2nt/HARDCORE
Версия плагина
1.0
Исходный код
#include <amxmodx>

new toggle_sound, toggle_blood, toggle_msg

public plugin_init()
{
register_plugin("B_F_HUD", "1.0", "mut2nt/HARDCORE")
register_event("DeathMsg", "head", "a")

toggle_sound = register_cvar( "h_sound", "1" );
toggle_blood = register_cvar( "h_blood", "1" );
toggle_msg = register_cvar( "h_msg", "1");
}

public head()
{
new iOrigin[3]
new killer = read_data(1)
new victim = read_data(2)

if(read_data(3))
{
if (get_pcvar_num(toggle_sound) != 0)
client_cmd(killer,"spk kill/headshot")

if (get_pcvar_num(toggle_blood) != 0)
{
get_user_origin(victim,iOrigin)
fx_headshot(iOrigin)
}

if (get_pcvar_num(toggle_msg) != 0)
set_hudmessage(0, 255, 0, -1.0, 0.20, 2, 0.02, 6.0, 0.01, 0.1, -1)
show_hudmessage(killer, ".:HEADSHOT:.")
}
}

fx_headshot(origin[3])
{
message_begin(MSG_PVS, SVC_TEMPENTITY, origin)
write_byte(TE_BLOODSTREAM)
write_coord(origin[0])
write_coord(origin[1])
write_coord(origin[2] + 30)
write_coord(random_num(-20, 20))
write_coord(random_num(-20, 20))
write_coord(random_num(50, 300))
write_byte(70)
write_byte(random_num(100, 200))
message_end()
message_begin(MSG_PVS, SVC_TEMPENTITY, origin)
write_byte(TE_BLOODSTREAM)
write_coord(origin[0])
write_coord(origin[1])
write_coord(origin[2] +10)
write_coord(random_num(-360, 360))
write_coord(random_num(-360, 360))
write_coord(-10)
write_byte(70)
write_byte(random_num(50, 100))
message_end()
}
public plugin_precache()
{
precache_sound("kill/headshot.wav");

}
Всем привет помогите решить задачку) Короч всё роз бросал по папкам, звук на клиент загружается но в игре не воспроизводиться.
9 Июн 2020
Хотел добавить я не скриптур) По этому если отписываете то немного понятнее в плане человеческого языка( то есть как в простонародье) :mosking:
 
В этой теме было размещено решение! Перейти к решению.
Сообщения
1,560
Реакции
1,572
Помог
2 раз(а)
9 Июн 2020
Может событие самого звука нужно ниже опустить,раз уж худ сообщения показываеться ,то может и за ним поставить сам звук...
 
Последнее редактирование:
Сообщения
460
Реакции
68
Помог
7 раз(а)
MayroN, спапасибо. Приду домай попробую отпишу.
 
Сообщения
2,143
Реакции
1,225
Помог
44 раз(а)
MayroN, смысл, если ничего не изменится?!
HARDCORE, Попробуй не client_cmd, а send_audio отправлять.
 
Сообщения
460
Реакции
68
Помог
7 раз(а)
Minni, и вам спасибо добрый человек попробую отпишу.
 
Сообщения
460
Реакции
68
Помог
7 раз(а)
Minni, сделал так
C++:
#include <amxmodx>

new toggle_sound, toggle_blood, toggle_msg

public plugin_init()
{
register_plugin("B_F_HUD", "1.0", "mut2nt/HARDCORE")
register_event("DeathMsg", "head", "a")

toggle_sound = register_cvar( "cfg_hs_sound", "1" );
toggle_blood = register_cvar( "cfg_hs_blood", "1" );
toggle_msg = register_cvar( "cfg_hs_msg", "1");
}

public head()
{
new iOrigin[3]
new killer = read_data(1)
new victim = read_data(2)

if(read_data(3))
{
if (get_pcvar_num(toggle_sound) != 0)
send_audio(killer,"sound/kill/headshot.wav", toggle_sound)

if (get_pcvar_num(toggle_blood) != 0)
{
get_user_origin(victim,iOrigin)
fx_headshot(iOrigin)
}

if (get_pcvar_num(toggle_msg) != 0)
set_hudmessage(0, 255, 0, -1.0, 0.20, 2, 0.02, 6.0, 0.01, 0.1, -1)
show_hudmessage(killer, ".:HEADSHOT:.");
}
}

fx_headshot(origin[3])
{
    message_begin(MSG_PVS, SVC_TEMPENTITY, origin)
    write_byte(TE_BLOODSTREAM)
    write_coord(origin[0])
    write_coord(origin[1])
    write_coord(origin[2] + 30)
    write_coord(random_num(-20, 20))
    write_coord(random_num(-20, 20))
    write_coord(random_num(50, 300))
    write_byte(70)
    write_byte(random_num(100, 200))
    message_end()
    message_begin(MSG_PVS, SVC_TEMPENTITY, origin)
    write_byte(TE_BLOODSTREAM)
    write_coord(origin[0])
    write_coord(origin[1])
    write_coord(origin[2] +10)
    write_coord(random_num(-360, 360))
    write_coord(random_num(-360, 360))
    write_coord(-10)
    write_byte(70)
    write_byte(random_num(50, 100))
    message_end()
}

stock send_audio(id, audio[], pitch)
{
    static msg_send_audio; if(!msg_send_audio) msg_send_audio = get_user_msgid("SendAudio");

    message_begin( id ? MSG_ONE_UNRELIABLE : MSG_BROADCAST, msg_send_audio, _, id);
    write_byte(id);
    write_string(audio);
    write_short(pitch);
    message_end();
}

public plugin_precache()
{
precache_sound("kill/headshot.wav");

}
Тоже самое звук не воспроизводится а сообщение и фонтан крови есть.
Может еще какие варианты. Я не очень разбираюсь в этом.
 
Сообщения
1,560
Реакции
1,572
Помог
2 раз(а)
Значит пробовал я с Вашим кодом в первом посте - звук работает
Далее с моим вариантом от Minni "ничего не измениться"- звук работает
И потом с вариантом send_audio - звук работает

А вижу тут 2 причины - либо чёт со звуком самим или откл.все плагины и проверяйте
Также попробуйте с моим Звуком )
 

Вложения

Сообщения
460
Реакции
68
Помог
7 раз(а)
MayroN, ок перепробую всё что советуюте. Отпишу позже.
 

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

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