Animals not being able to bite

Hi, i use this in a customized pet script and it work fine for me, the dog attack the ped that the player is aiming at but you need to add a function to detect which ped the player is aiming at.

https://runtime.fivem.net/doc/natives/#_0xF166E48407BAC484

The same kind of aiming detection i’m using: