Difference between revisions of "Lua:Flags"
m |
(Clip flags added.) |
||
Line 193: | Line 193: | ||
<code><pre> | <code><pre> | ||
ApplyToAll({ AT.kRemovePacks, AT.kRemoveProjectiles, AT.kRespawnPlayers, AT.kRemoveBuildables, AT.kRemoveRagdolls, AT.kStopPrimedGrens, AT.kReloadClips }) | ApplyToAll({ AT.kRemovePacks, AT.kRemoveProjectiles, AT.kRespawnPlayers, AT.kRemoveBuildables, AT.kRemoveRagdolls, AT.kStopPrimedGrens, AT.kReloadClips }) | ||
+ | </pre></code> | ||
+ | }} | ||
+ | |||
+ | {{Lua:FlagType | ||
+ | |prefix=ClipFlags | ||
+ | |usage=Used with [[Lua:trigger_ff_clip]] to determine what types of entities are allowed to pass through the trigger. | ||
+ | |flags= | ||
+ | {{Lua:Flag|ClipFlags.kClipTeamBlue|Use in conjunction with "ByTeam" flags.}} | ||
+ | {{Lua:Flag|ClipFlags.kClipTeamRed|Use in conjunction with "ByTeam" flags.}} | ||
+ | {{Lua:Flag|ClipFlags.kClipTeamYellow|Use in conjunction with "ByTeam" flags.}} | ||
+ | {{Lua:Flag|ClipFlags.kClipTeamGreen|Use in conjunction with "ByTeam" flags.}} | ||
+ | {{Lua:Flag|ClipFlags.kClipAllPlayers|}} | ||
+ | {{Lua:Flag|ClipFlags.kClipAllGrenades|}} | ||
+ | {{Lua:Flag|ClipFlags.kClipAllProjectiles|projectiles such as nails and rockets.}} | ||
+ | {{Lua:Flag|ClipFlags.kClipAllBullets|hitscan weapons such as shotguns.}} | ||
+ | {{Lua:Flag|ClipFlags.kClipAllBuildables|Can buildables be placed?}} | ||
+ | {{Lua:Flag|ClipFlags.kClipAllBuildableWeapons|Can sentries fire through?}} | ||
+ | {{Lua:Flag|ClipFlags.kClipAllBackpacks|Thrown/dropped ammo.}} | ||
+ | {{Lua:Flag|ClipFlags.kClipAllInfoScripts|Flags, balls, etc. These currently cannot be filtered by team.}} | ||
+ | {{Lua:Flag|ClipFlags.kClipAllSpawnTurrets|}} | ||
+ | {{Lua:Flag|ClipFlags.kClipAllNonPlayers|}} | ||
+ | {{Lua:Flag|ClipFlags.kClipPlayersByTeam or ClipFlags.kClipPlayers|The following pairs behave identically; the first form is preferred, but the second form is for backwards-compatibility.}} | ||
+ | {{Lua:Flag|ClipFlags.kClipGrenadesByTeam or ClipFlags.kClipGrenades|}} | ||
+ | {{Lua:Flag|ClipFlags.kClipProjectilesByTeam or ClipFlags.kClipProjectiles|}} | ||
+ | {{Lua:Flag|ClipFlags.kClipBulletsByTeam or ClipFlags.kClipBullets|}} | ||
+ | {{Lua:Flag|ClipFlags.kClipBuildablesByTeam or ClipFlags.kClipBuildables|}} | ||
+ | {{Lua:Flag|ClipFlags.kClipBuildableWeaponsByTeam or ClipFlags.kClipBuildableWeapons|}} | ||
+ | {{Lua:Flag|ClipFlags.kClipBackpacksByTeam or ClipFlags.kClipBackpacks|}} | ||
+ | {{Lua:Flag|ClipFlags.kClipSpawnTurretsByTeam or ClipFlags.kClipSpawnTurrets|}} | ||
+ | {{Lua:Flag|ClipFlags.kClipNonPlayersByTeam or ClipFlags.kClipNonPlayers|}} | ||
+ | |||
+ | |example= | ||
+ | This clip brush will be solid to everything except blue players. | ||
+ | <code><pre> | ||
+ | clip_example = trigger_ff_clip:new({ clipflags = { | ||
+ | ClipFlags.kClipPlayersByTeam, ClipFlags.kClipTeamRed, | ||
+ | ClipFlags.kClipTeamYellow, ClipFlags.kClipTeamGreen, | ||
+ | ClipFlags.kClipAllNonPlayers} }) | ||
</pre></code> | </pre></code> | ||
}} | }} |
Revision as of 21:55, 25 June 2011
TeamReturns a specific team's ID
Example
GrenadeReturns a specific grenade's ID
Example
DamageReturns a specific damage type's ID; predominately used to detect fall damage
Example
AmmoReturns a specific ammo type's ID; predominately used to add or remove ammo from a player
Example
EFReturns a specific status effect's ID
Example
ATReturns a specific "apply to" ID; Applies various commands to players, or to the entire server. Use with ApplyToAll(ApplyToFlags), ApplyToTeam(team, ApplyToFlags), or ApplyToPlayer(player, ApplyToFlags) (not all flags are suitable for all functions).
Example
ClipFlagsUsed with Lua:trigger_ff_clip to determine what types of entities are allowed to pass through the trigger.
ExampleThis clip brush will be solid to everything except blue players.
CFReturns a specific "collection filter" ID;. Use with Collection() functions to add certain entities to a list.
Example
Color.kDefault, Color.kBlue, Color.kRed, Color.kYellow, Color.kGreen, Color.kWhite, Color.kBlack, Color.kOrange, Color.kPink, Color.kPurple, Color.kGrey, Color.kInvalid ColorShorthand for some common colors-- used for Category:HUD_Items
ExampleNo example provided |