This commit is contained in:
Juzlus 2025-09-24 05:31:41 +02:00
parent ac53655184
commit e5ead42dfa
34 changed files with 953 additions and 1333 deletions

View file

@ -8,9 +8,9 @@ using CounterStrikeSharp.API.Modules.Utils;
using System.Runtime.InteropServices;
using WASDMenuAPI.Classes;
using WASDSharedAPI;
using static CounterStrikeSharp.API.Core.Listeners;
using System.Collections.Concurrent;
using src.player;
using src.player.skills;
namespace src.utils
{
@ -97,6 +97,14 @@ namespace src.utils
if (pawn == null || !pawn.IsValid || pawn.LifeState != (byte)LifeState_t.LIFE_ALIVE)
return;
if (pawn.Controller.Value != null && pawn.Controller.Value.IsValid)
{
var playerInfo = jRandomSkills.Instance.SkillPlayer.FirstOrDefault(p => p.SteamID == pawn.Controller.Value.SteamID);
if (playerInfo == null) return;
if (playerInfo.Skill == Skills.Jester && Jester.GetJesterMode())
return;
}
int newHealth = (int)(pawn.Health - damage);
pawn.Health = newHealth;
Utilities.SetStateChanged(pawn, "CBaseEntity", "m_iHealth");