PDA

View Full Version : Block the "silent aim" cheat



qwrtyp
18th March 2014, 14:48
It would be possible to prevent this cheat, where shots do not hit the enemy, go far and still results in death?
This is not serverside cheat, is something that is infesting the game, punkbuster does not detect. I believe the only solution to this would be some mod to annul this effect.



http://www.youtube.com/watch?v=9_zIpgj12u8

serthy
18th March 2014, 16:21
yh its possible to detect serverside via mod:

//call in Callback_PlayerDamage(): (self == victim)
if( checkSilentAim( sMeansOfDeath , self , attacker ) )
iDamage = 0;

checkSilentAim( sMeansOfDeath , victim , attacker )
{
// check only bullet weapons
if( sMeansOfDeath != "MOD_HEAD_SHOT" && !isSubStr( sMeansOfDeath , "BULLET" ) )
return false;

attackerViewDir = anglesToForward( attacker getPlayerAngles() );
attackerToVictimDir = vectorToAngles( victim.origin - attacker.origin ); // maybe change the origins here
angleBetweenDirs = vectorDot( attackerViewDir , attackerToVictimDir ); // returns acos of angle
maxAngle = aCos( 5 ); // 5 degrees

if( angleBetweenDirs <= maxAngle )
return false;

return true;
}

vectorDot( v1 , v2 )
{
return v1[0] * v2[0] + v1[1] * v2[1] + v1[2] * v2[2];
}

I'm not sure if this works on the first try, but this is one (easy) way to go

btw, how sad is this hack!? aimbot without aim lmao..

qwrtyp
18th March 2014, 18:58
hi ,
I do not have much knowledge about modding and scripting, so I will trying until something works.

I had put this part within the Callback_PlayerDamage,

//call in Callback_PlayerDamage(): (self == victim)
if( checkSilentAim( sMeansOfDeath , self , attacker ) )
iDamage = 0;

and this just below the end of Callback_PlayerDamage ( )

checkSilentAim( sMeansOfDeath , victim , attacker )
{
// check only bullet weapons
if( sMeansOfDeath != "MOD_HEAD_SHOT" && !isSubStr( sMeansOfDeath , "BULLET" ) )
return false;

attackerViewDir = anglesToForward( attacker getPlayerAngles() );
attackerToVictimDir = vectorToAngles( victim.origin - attacker.origin ); // maybe change the origins here
angleBetweenDirs = vectorDot( attackerViewDir , attackerToVictimDir ); // returns acos of angle
maxAngle = aCos( 5 ); // 5 degrees

if( angleBetweenDirs <= maxAngle )
return false;

return true;
}

vectorDot( v1 , v2 )
{
return v1[0] * v2[0] + v1[1] * v2[1] + v1[2] * v2[2];
}


thus resulted in this error:

******* Script compile error *******
uninitialised variable ' attacker ' : ( file ' maps / mp / gametypes / sd.gsc ' , line 433 )
*if ( checkSilentAim ( sMeansOfDeath , self , Attacker ) )
*****************************************
I changed the first "atracker" by "eAttacker" , and server runs. I have no idea if it has any difference.:(
I did right?
thank you very much for your help, sorry that I can not verify if it worked in practice, because I have no hacks to test.
I think everyone should use it on their servers, it has much of this "silent aim" in cod2 and cod4.

serthy
18th March 2014, 19:10
sorry that I can not verify if it worked in practice
You could comment out the first if-condition and test with a grenade on yourself:


checkSilentAim( sMeansOfDeath , victim , attacker )
{
// check only bullet weapons
//if( sMeansOfDeath != "MOD_HEAD_SHOT" && !isSubStr( sMeansOfDeath , "BULLET" ) )
// return false;

attackerViewDir = anglesToForward( attacker getPlayerAngles() );
attackerToVictimDir = vectorToAngles( victim.origin - attacker.origin ); // maybe change the origins here
angleBetweenDirs = vectorDot( attackerViewDir , attackerToVictimDir ); // returns acos of angle
maxAngle = aCos( 5 ); // 5 degrees

if( angleBetweenDirs <= maxAngle )
return false;

iPrintLnBold( "TEST: angle = " + cos( angleBetweenDirs ) );

return true;
}

MeGaBooM
18th March 2014, 19:35
never saw this before, 1.0 bug?

serthy
18th March 2014, 20:17
never saw this before, 1.0 bug?

Same for me, but simply google'ing "silent aim" and you'll find a shitload of youtube vids and hacks

qwrtyp
19th March 2014, 04:12
I'm still trying and could not make it work, i must be doing something wrong. (I'm trying to learn)
I tried to change "attacker" with "eattacker",
threw the grenade and not appeared iPrintLnBold

should insert into
maps/pam/(sd, dm, hq, ctf...)
maps/mp/gametypes/(sd, dm, hq, ctf...)


this is a ridiculous hack, i do not understand how can this happen..
have you ever been killed and thought, "this shot did not hit me", could be true.
its not 1.0 bug

Rocky
19th March 2014, 11:32
haha this is hack,look at youtube.

Look this: https://www.youtube.com/watch?v=g79N8SmptII

0:13 s.

deivis33
20th March 2014, 05:52
I came to this post through Google, i'm admin of some servers and I noticed players are using this hack.
I do not know anything about mods, but if someone makes a fix and provide for the people put on their servers would be great. (one ".iwd" or a step by step for noobs like me)
thanks

serthy
20th March 2014, 16:53
I've chosen another approach, angles arent this save for greater distances + noaim:
673
Download here: 675


Silent Aim Cheat Fix

-> Help

Contact me:

serthy@ymail.com

See: http://killtube.org/showthread.php?1874-Block-the-quot-silent-aim-quot-cheat

-> Install

Drag'n'Drop the containing maps folder into your fs_game folder.
This will replace the default maps\mp\gametypes\_callback.gsc with
the modified one.
It also adds maps\mp\gametypes\_fix_silent_aim.gsc.

If you're already running a mod, refer to
maps\mp\gametypes\_callback.gsc -> Callback_StartGametype()
and add
level thread maps\mp\gametypes\_fix_silent_aim::init();
to the function.

-> server config

Add
set fix_silent_aim 1
to your server config.

Values:
= 0 - disabled
< 0 - debug prints and testBots enabled
> 0 - enabled

-> Testserver: fs_game

Unzip this file into your CoD2 directory (next to the main-folder).
Doubleclick silent_aim.cmd. This starts your own dedicated homeserver.
Start CoD2 Multiplayer as normal. Goto Join Server > Locale Server.
Join your testserver.

YuriJurek
20th March 2014, 17:08
killtube.org/youloop.php?v=_khvxgr4W7A

Gratzz for that guy.

serthy
21st March 2014, 16:15
Well after watching a couple of the thousands of silent aim videos a simple bullettrace would fit even better.

deivis33
21st March 2014, 19:30
thanks a lot,
the message "silent aim detected" appears only in debug mode or in fix_silent_aim 1 too?

serthy
21st March 2014, 19:54
thanks a lot,
the message "silent aim detected" appears only in debug mode or in fix_silent_aim 1 too?

debug only

hopefully there are no bugs, only tested with these bots tho

Ni3ls
21st March 2014, 20:52
serthy how did u test it? U got the silent aim hack?

serthy
21st March 2014, 22:52
serthy how did u test it? U got the silent aim hack?

Hell no...
Just implemented an aiming logic to the bots so they shoot eachother.
Then decreasing the distance calculations until no warning about silent aim is popping up any longer.
I've tested this on the stock map Brecourt (pretty large) and it seems to be OK.
Improvements and critics are welcomened ;-)

Ni3ls
22nd June 2016, 12:24
I've chosen another approach, angles arent this save for greater distances + noaim:
673
Download here: 675


Silent Aim Cheat Fix

-> Help

Contact me:

serthy@ymail.com

See: http://killtube.org/showthread.php?1874-Block-the-quot-silent-aim-quot-cheat

-> Install

Drag'n'Drop the containing maps folder into your fs_game folder.
This will replace the default maps\mp\gametypes\_callback.gsc with
the modified one.
It also adds maps\mp\gametypes\_fix_silent_aim.gsc.

If you're already running a mod, refer to
maps\mp\gametypes\_callback.gsc -> Callback_StartGametype()
and add
level thread maps\mp\gametypes\_fix_silent_aim::init();
to the function.

-> server config

Add
set fix_silent_aim 1
to your server config.

Values:
= 0 - disabled
< 0 - debug prints and testBots enabled
> 0 - enabled

-> Testserver: fs_game

Unzip this file into your CoD2 directory (next to the main-folder).
Doubleclick silent_aim.cmd. This starts your own dedicated homeserver.
Start CoD2 Multiplayer as normal. Goto Join Server > Locale Server.
Join your testserver.

Can you reupload this?

Mitch
22nd June 2016, 15:19
Can you reupload this?

1117

10 chars^^

serthy
22nd June 2016, 15:38
I've looked in the attachments in here, but couldn't find it. Also I don't have any backups from stuff like this.
I didn't even remember writing this :D

Thank you Mitch :)

agribilos
11th January 2021, 21:32
Unfortunately silent aim is not blocked using this method... Anyone got something for it?