SA-MP Forums Archive
OnPlayerTakeDamage blocked - cleo - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: OnPlayerTakeDamage blocked - cleo (/showthread.php?tid=556892)



OnPlayerTakeDamage blocked - cleo - JonathanFeitosa - 11.01.2015

How do i Detect when a CallBack(OnPlayerTakeDamage) Isn't called when supposed to? There's a cleo Blocking the Callback. I can not use the OnPlayerGiveDamage because of 'LAG'. Explosion and fall, the blood falls normally.(OnPlayerTakeDamage it works). Even using Hook method 7 not it works.


Re: OnPlayerTakeDamage blocked - cleo - Rudy_ - 12.01.2015

try ?
https://sampwiki.blast.hk/wiki/OnPlayerWeaponShot


Re: OnPlayerTakeDamage blocked - cleo - JonathanFeitosa - 12.01.2015

This callback Doesn't Work for a melee fight.


Re: OnPlayerTakeDamage blocked - cleo - JonathanFeitosa - 13.01.2015

Can somebody else give me a opnion?


Re: OnPlayerTakeDamage blocked - cleo - n0minal - 16.01.2015

Try ai:

Код:
public OnPlayerGiveDamage(playerid, damagedid, Float:amount, weaponid, bodypart)
{
new Float:oldhealth; GetPlayerHealth(playerid, oldhealth); SetTimerEx("OnPlayerRecieveDamage", 500, false, "dff", damagedid, amount, oldhealth); return 1;
} forward OnPlayerRecieveDamage(playerid, amount, Float:oldhealth); public OnPlayerRecieveDamage(playerid, amount, Float:oldhealth) {
new Float:health; GetPlayerHealth(playerid, health); if(health > oldhealth - amount) {
for(new i; i < MAX_PLAYERS;i++) { if(IsPlayerAdmin(i)) { new string[128]; format(string, sizeof(string), "Possible health hacker detected (id %d)", playerid); SendClientMessage(i, -1, string); } }
} return 1;
}
PS: Non-tested, you should do it compatible with your restoring health systems.


Re: OnPlayerTakeDamage blocked - cleo - Lordzy - 16.01.2015

It can happen if any includes that you use aren't properly hooked on OnPlayerTakeDamage part.


Re: OnPlayerTakeDamage blocked - cleo - n0minal - 16.01.2015

Quote:
Originally Posted by Lordzy
Посмотреть сообщение
It can happen if any includes that you use aren't properly hooked on OnPlayerTakeDamage part.
Its not a scripting problem bro, the hack bypass the native callback and prevent the hacker to taking damage, it seems like if nobody happens in game, the hacker simply dont take any damage, it can be easily detected if player uses weapons, but when its only punching its hard to detect...

[ame="http://www.youtube.com/watch?v=lMtr6m72jqg"]Look the video about the hack.[/ame]


Re: OnPlayerTakeDamage blocked - cleo - Lordzy - 16.01.2015

From what I've seen, looks like the player is not getting hit and that's what the actual reason is - OnPlayerTakeDamage gets called only when a player takes damage. If it's really the lag.cs which causes this, why don't you try debugging OnPlayerTakeDamage when you fall of from anywhere and gets your health reduced?


Re: OnPlayerTakeDamage blocked - cleo - n0minal - 16.01.2015

Quote:
Originally Posted by Lordzy
Посмотреть сообщение
From what I've seen, looks like the player is not getting hit and that's what the actual reason is - OnPlayerTakeDamage gets called only when a player takes damage. If it's really the lag.cs which causes this, why don't you try debugging OnPlayerTakeDamage when you fall of from anywhere and gets your health reduced?
The server from video uses lagshot, hes taking shoots but hes not recieving/taking damage, but the problem is that on him server people don't use weapons to kill, only knife, bat, stick and stuff... And the hack bypass the OnPlayerTakeDamage, it means if i hit the hacker by punch, knife or bat, he will not take damage and OnPlayerTakeDamage will not be called, but if he fall, if he get shotted, if he take damage from explosion, the health will decrease, only dont decrease from punching, knifing or punching by bat or stick the hacker don't takes damage and OnPlayerTakeDamage isn't called...


Re: OnPlayerTakeDamage blocked - cleo - RedFusion - 16.01.2015

This is a cleo that makes the user like a ghost, like dust, bullets go straight through without detection. As far as i know the bullets only go "through" on the cheater's screen. So using OnPlayerTakeDamage will obviously not work, as the cheater does not take any damage. Your only choice is to use OnPlayerGiveDamage, give it a shot.


Re: OnPlayerTakeDamage blocked - cleo - n0minal - 16.01.2015

Quote:
Originally Posted by RedFusion
Посмотреть сообщение
This is a cleo that makes the user like a ghost, like dust, bullets go straight through without detection. As far as i know the bullets only go "through" on the cheater's screen. So using OnPlayerTakeDamage will obviously not work, as the cheater does not take any damage. Your only choice is to use OnPlayerGiveDamage, give it a shot.
Thats it exactly...