AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Is a message triggered when you look at someone in DOD? (https://forums.alliedmods.net/showthread.php?t=29260)

Geesu 06-02-2006 01:39

Is a message triggered when you look at someone in DOD?
 
Or is any pdata value or entity data set when you look at a player?

I know CS has the StatusValue message that is triggered everytime you look at someone...

Anyone know if there is a similar message? (I know I can loop and check get_user_aiming, but I'd prefer not to)

Thanks,
Josh

Hawk552 06-02-2006 07:36

Try the message logging plugin by Damaged Soul.

Geesu 06-02-2006 08:39

I did, thats why i'm posting here...

VEN 06-03-2006 14:22

I think somethig like this will work, if not, you can try post hook.
But do not run this on <1.75 because of that bug: http://forums.alliedmods.net/showthread.php?t=28004

Code:
new g_phit[33] public plugin_init() {     register_forward(FM_TraceLine, "forward_trace_line") } public forward_trace_line(const Float:start[3], const Float:dest[3], ignore_monsters, skip_ent, ptr) {     if (skip_ent && is_user_alive(skip_ent)) {         new phit = get_tr2(ptr, TR_pHit)         if (phit != g_phit[skip_ent]) {             if (phit && is_user_alive(phit))                 server_print("%d start aiming at %d", skip_ent, phit)             g_phit[skip_ent] = phit         }     } }

Geesu 06-03-2006 17:21

DUH - gosh so simple!!! WHy didn't I think of that LOL... I've been doing the get_user_aiming check every 0.1 seconds... sweet thanks :) :) :)


All times are GMT -4. The time now is 16:33.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.