gtixon
Участник
- Сообщения
- 1,078
- Реакции
- 401
Спасибо, работает. А как я могу проиграть звук для игрока котрый убил?gtixon, мог бы сам вставить код отсюда: Написание плагинов
C-подобный:public OnPluginStart() { HookEvent("player_death", Event_PlayerDeath); } public Event_PlayerDeath(Handle:event, const String:name[], bool:dontBroadcast) { new attacker = GetClientOfUserId(GetEventInt(event, "attacker")); if(!attacker) return; new health = GetClientHealth(attacker); if(health < 100) { health += 20; // здесь ставим свой инкремент SetEntityHealth(attacker, health > 100 ? 100 : health); } PerformFade(attacker, 600, {62, 255, 107, 70}); } PerformFade(client, duration, const color[4]) { new Handle:message = StartMessageOne("Fade", client); PbSetInt(message, "duration", duration); PbSetInt(message, "hold_time", 0); PbSetInt(message, "flags", 0x0001); PbSetColor(message, "clr", color); EndMessage(); }
Я так понимаю мне нужно взять переменную attaker, прекешировать звук, и исполнить его для игрока?