View Single Post
Author Message
Mitchell
~lick~
Join Date: Mar 2010
Old 02-27-2014 , 12:44   [Any] Super Targeting (Filters) |Updated 2/25/16|
Reply With Quote #1

Super Targeting
=========

Super Targeting adds in a config for server operators to make their own filter for the ProcessTargetString which is used in many of the SM commands.

Future Work
-----------

I plan on adding in a way to check to see if the following conditions are met to the list of filters a operator can set.
• Check active weapon, (index number, class name, slot #)
• Check to see if a player has a certain wearable (type, quality, level)
• Check all weapons to look for: index number, class name, quality, level.
If you have any filter you would like to see added onto this please post below!
• Premium Check
• Flag checking [DONE!]
• Alive Checking [DONE!]
• Bot Checking [DONE!]
• Multi-Game Class Checking [DONE!]
• Invert Check [DONE!]
• Random Player [DONE!]

Installation & Setup
===========

Code:
SuperTargeting.smx -> Sourcemod/plugins/
SuperTargeting.cfg -> Sourcemod/configs/
Configuration
------------

The format is so:
Code:
"@<filtername>"
{
	 "text"		"<language text>"
	 "team"		"<team>"
	 "class"	"<class>" //TF2|DOD:S|L4D|L4D2
	 "alive"	"<0/1>"
	 "bots"	"<0/1>"
	 "cond"	"<condition #>" //TF2 ONLY!
	 "flag"	"<a/z>"
	 "invert"	"<0/1>"
	 "random"	"<#>"
}
Here is what can be put into each one:
Code:
<filtername> : this can be anything, but i would refrain from making it anything that is already in use. Start it off with an exclamation point (!) to negate the filter
<team>  : this can be 0 to 3, anything else it will ignore the filter. Set to 0 to ignore the team number.
<class> : this is a number from 0 to 9, anything other than that the filter will be ignored.
<language text> : This is the text that is printed out when a plugin uses this filter
<alive> : -1 ignores this filter (or just dont add the filter.), 0 - Only dead players, 1 - Only alive players
<bots> : -1 ignores this filter (or just dont add the filter.), 0 - Only Players, 1 - Only Bots
<cond> : Full list below, checks to see if a player is in a certain condition.
<flag> : Any flags to check for. (For root admins that just have the 'z' flag make sure you add the z in the flag string so if you wanted to check for admins do: "flag"    "bz" (cont below)
<invert> : This will invert the entire check, if you need to do so, without using a '!' at the beginning.
<random> : This will compile all players that meet the conditions and then choose X amount of players from that list at random.
List of all the class/team/cond numbers:
Code:
Classes:
0 : Any Class
1 : Scout
2 : Sniper
3 : Soldier
4 : Demoman
5 : Medic
6 : Heavy
7 : Pyro
8 : Spy
9 : Engineer

Teams:
0 : Any team
1 : Spectator
2 : RED/T
3 : BLU/CT

Conditions:
There are just too many conditions to check so ill only post ones that would be good to use.
-1 : Ignore (this is the default)
0 : Slowed
1 : Zoomed // Snipers zooming in.
3 : Disguised //Spys that are disguised.
4 : Cloaked //Player is cloaked.
5 : Ubercharged
6 : TeleportedGlow // a user that had just teleported.
7 : Taunting
11 : Kritzkrieged 
14 : Bonked
15 : Dazed
16 : Buffed
17 : Charging
19 : CritCola
21 : Healing
22 : OnFire
23 : Overhealed
24 : Jarated
25 : Bleeding
27 : Milked
30 : MarkedForDeath
32 : SpeedBuffAlly
36 : CritHype // scout's hype?
77 : HalloweenGhostMode

Flags:
a-t, z: All flags
If you add a # this means that players must ONLY have those flags so "#ab" cleints must ONLY have flags A and flag B. Normal "ab" means that they only have to have that in the mix.
Below this is an example that will target all scouts
Code:
"@scout"
{
	 "text"		"all Scouts"
	 "team"		"0"
	 "class"		"1"
}
When used it will display: ***** all Scouts.
i.e.: [SM] Slayed all Scouts.
Updater
-----------
This plugin doesn't require Updater, but it does support it.
to disable Updating on the specific plugin go here: tf/cfg/sourcemod/plugin.SuperTargeting.cfg
and change sm_supertargeting_update to 0

Credit where it's due
-----------
- ReFlexPoison : Created the base of the code and most of the filters syntax for the config. [Class Target Filters]
- ddhoward : He also made a similar plugin of ReFlexPoison's, it had a few custom filters that I appended onto the config. [Class Targeting]

DOWNLOAD
=========
These are all the current version on the main branch in bitbucket.
PLUGIN
CONFIG -right click -> save as...
SOURCE

Last edited by Mitchell; 02-25-2016 at 10:37.
Mitchell is offline