View Single Post
Author Message
retsam
Veteran Member
Join Date: Aug 2008
Location: so-cal
Old 01-06-2010 , 00:03   Aim Names (v0.8)
Reply With Quote #1

Aim Names ( 0.8 )


This is a little plugin that was a request from someone in the IRC chan.

Description: This is a fairly simple plugin. It just shows names of enemies you place your crosshair on(and health for admins). The plugin uses client prefs and allows players to change the settings for themselves. Screenshots are located at the bottom.


Installation/USE: Config is auto-created(plugin.aimnames.cfg) All cvars are in this config. Place .smx into the plugins folder(duh)! Type !settings for the client prefs menu. It allows you to enable/disable the hudtext and change colors. For admins there is also a health entry added to the menu, it will not show up for non-admins. All the client prefs settings are saved.

Cvars:
sm_aimnames_enabled "1" //Enable/Disable aim names plugin (1/0 = yes/no)
sm_aimnames_adminonly "0" //Enable/Disable plugin for admins only.
sm_aimnames_flag "d" //Default: d Admin flag(s) to use if admin only.
sm_aimnames_color "0" //Default color for hudtext. (0 = red, 1 = orange, 2 = yellow, 3 = green, 4 = blue)
sm_aimnames_health "1" //Enable/Disable admins viewing players health.
sm_aimnames_holdtime "0.4" //(Default: 0.4) The hudtext number of seconds to hold/refresh the text. You might need to experiment with this to figure out exactly what it does.
sm_aimnames_distance "100.0" //(Default: 100) Distance in meters for showing aim names.
sm_aimnames_timerinterval "0.3" //(Default: 0.3) Repeat timer interval. Time in seconds between execing the timer function.


Known Issues: Well, unfortunately I do not know how to make the aiming function obey walls on maps. This means to a degree you can place your crosshair on walls and possibly locate enemies behind walls in line of sight. Just something I wanted people to be aware of. If anyone knows how to fix that lmk. (FIXED!)


Games: This plugin should work in the below listed games, however I have only tested it in Age of Chivalry and TF2.

Games Supporting hudtext:
-TF2
-Age of Chivarly
-hl2mp
-insurgency
-zombie_master
-sourceforts
-obsidian
-bg2

Changelog:

Code:
2/16/10 - v0.8 - Changed the client pref cookie for health from being disabled by default, to enabled by default.

1/23/10 - v0.7 - Fixed issue with showing names while in spectate.

1/23/10 - v0.6 - Added cvar for the timer interval. I did this for the sake of control so admins can set the timer interval to what they want, instead of what I had decided.

1/17/10 - v0.5 - Added cvars for distance and for the hudtext hold/refresh time. Lowered the default values a bit, I thought they were way too high for default distance.

1/13/10 - v0.4 - Multi-game support added. Now "should" work in handful of games/mods, though untested. Fixed issue of being able to track players names through walls by removing GetClientAimTargetmethod and replacing with(Thanks again to Antihasys) CanSeeTarget code.

1/12/10 - v0.3 - Complete recode(Much thanks to Antithasys!). Now uses client prefs. Players can enable/disable the plugin and/or set their own personal color settings now. Optional cvar for admin only. Also added health being displayed for admins only, also with a cvar.  Changed distance to 2000 instead of 1000(unsure of what this should be set to yet).

1/6/10 - v0.2 - Fixed showing names of cloaked/disguised spies. Lowered timer interval slightly.

1/5/10 - v0.1 - Initial release.

Credits:
Much thanks to Antithasys for helping recode and optimize the plugin making it 10x better!


Any issues or suggestions, lmk.
Attached Thumbnails
Click image for larger version

Name:	aimnames1.jpg
Views:	6364
Size:	10.1 KB
ID:	57578   Click image for larger version

Name:	aimnames2.jpg
Views:	4358
Size:	15.3 KB
ID:	57579   Click image for larger version

Name:	aimnames3.jpg
Views:	4068
Size:	20.6 KB
ID:	57580   Click image for larger version

Name:	aimnames4.jpg
Views:	3042
Size:	12.6 KB
ID:	57581  
Attached Files
File Type: sp Get Plugin or Get Source (aimnames.sp - 9254 views - 23.2 KB)

Last edited by retsam; 02-27-2010 at 05:18. Reason: new version
retsam is offline