Logic playerproxy: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
m (→‎Inputs: Added specific update that the ending scene was changed in)
m (New inputs in P2CE)
Line 24: Line 24:
{{IO|SetMotionBlurAmount|Forces the motion blur effect on the player. Set to <<nowiki>=</nowiki> 0 to disable this override.|param=float|since={{portal2}}}}
{{IO|SetMotionBlurAmount|Forces the motion blur effect on the player. Set to <<nowiki>=</nowiki> 0 to disable this override.|param=float|since={{portal2}}}}
{{IO|SetFallDamageEnabled|Enables or disables fall damage on the player.|param=bool|only={{P2CE}}}}
{{IO|SetFallDamageEnabled|Enables or disables fall damage on the player.|param=bool|only={{P2CE}}}}
{{IO|GiveBoots|Gives long fall boots to the player.|only={{P2CE}}}}
{{IO|RemoveBoots|Removes long fall boots to the player.|only={{P2CE}}}}
{{IO|GivePaintGunFull|Gives the player a full paint gun.|only={{P2CE}}}}
{{IO|GivePaintGunBasic|Gives the player a basic paint gun.|only={{P2CE}}}}
{{IO|RemovePaintGun|Removes the player's paint gun.|only={{P2CE}}}}
{{IO|RemovePortalGun|Removes the player's portal gun.|only={{P2CE}}}}
{{I Targetname}}
{{I Targetname}}
{{I DamageFilter}}
{{I DamageFilter}}

Revision as of 03:31, 14 June 2022

Template:Base point multi It is used to relay inputs/outputs to the player and back to the world.

Keyvalues

Name (targetname) <string>[ Edit ]
The name that other entities refer to this entity by, via Inputs/Outputs or other keyvalues (e.g. parentname or target).
Also displayed in Hammer's 2D views and Entity Report.
See also:  Generic Keyvalues, Inputs and Outputs available to all entities

DamageFilter:

Damage Filter (damagefilter) <targetname>
Name of the filter_damage_type entity that controls which entities can damage us.


Inputs

RequestPlayerHealth
Requests the current player's health from the proxy. This will fire the PlayerHealth output with the value.
SetFlashlightSlowDrain
Puts the player's flashlight in slow-power-drain mode (for Episodic darkness)
SetFlashlightNormalDrain
Puts the player's flashlight to default power drain
SetPlayerHealth <integerRedirectInput/integer>
Sets the player's health to this value.
RequestAmmoState
Request the ammo state of the player. It will fire PlayerHasAmmo or PlayerHasNoAmmo outputs.
LowerWeapon  (in all games since Half-Life 2: Episode Two)
Lowers the players weapon.
EnableCappedPhysicsDamage  (in all games since Half-Life 2: Episode Two)
Cause player to take less damage from physics objects, and never more than 30 points from any individual strike.
DisableCappedPhysicsDamage  (in all games since Half-Life 2: Episode Two)
Undo effects of EnableCappedPhysicsDamage
SetLocatorTargetEntity <stringRedirectInput/string> (only in Half-Life 2: Episode Two)
Set the entity that the HUD locator should track. (Usually a vehicle)
SuppressCrosshair  (only in Portal) !FGD
Hides the crosshair.
Note.pngNote:Unlike the command crosshair 0, the crosshair is enabled again when a new game is started or a save made before firing the input is loaded.
Note.pngNote:Added in the March 3rd, 2010 update. Seems to be a backported Portal 2 input that was removed from Portal 2 before release.
AddPotatosToPortalgun  (only in Portal 2)
Change portalgun bodygroup to show PotatOS.
RemovePotatosFromPortalgun  (only in Portal 2)
Change portalgun bodygroup to not show PotatOS.
SetDropEnabled <booleanRedirectInput/boolean> (in all games since Portal 2)
Set wether the player is allowed to drop a carried object.
ForceVMGrabController  (in all games since Portal 2)
Force the player to use the view model grab controller for all objects that are picked up.
ForcePhysicsGrabController  (in all games since Portal 2)
Force the player to use the physics grab controller for all objects that are picked up.
ResetGrabControllerBehavior  (in all games since Portal 2)
Resets the grab controller used by the player to its default behavior.
SetMotionBlurAmount <floatRedirectInput/float> (in all games since Portal 2)
Forces the motion blur effect on the player. Set to <= 0 to disable this override.
SetFallDamageEnabled <booleanRedirectInput/boolean> (only in Portal 2: Community Edition)
Enables or disables fall damage on the player.
GiveBoots  (only in Portal 2: Community Edition)
Gives long fall boots to the player.
RemoveBoots  (only in Portal 2: Community Edition)
Removes long fall boots to the player.
GivePaintGunFull  (only in Portal 2: Community Edition)
Gives the player a full paint gun.
GivePaintGunBasic  (only in Portal 2: Community Edition)
Gives the player a basic paint gun.
RemovePaintGun  (only in Portal 2: Community Edition)
Removes the player's paint gun.
RemovePortalGun  (only in Portal 2: Community Edition)
Removes the player's portal gun.

DamageFilter:

SetDamageFilter <stringRedirectInput/string>
Sets the entity to use as damage filter. Pass in an empty string (no parameter) to clear the damage filter.

Outputs

OnFlashlightOn <floatRedirectInput/float>
Fired when the player turns on his flashlight. This output has the value of how much energy the player had when this happened [0..1].
OnFlashlightOff <floatRedirectInput/float>
Fired when the player turns off his flashlight. This output has the value of how much energy the player had when this happened [0..1].
PlayerHealth <integerRedirectInput/integer>
The player's current health value.
PlayerHasAmmo
Fired by request if the player has any ammo.
PlayerHasNoAmmo
Fired by request if the player doesn't have any ammo.
PlayerMissedAR2AltFire  (only in Half-Life 2: Episode Two)
Player fired an AR2 combine ball that didn't kill any enemies.
PlayerDied  (in all games since Half-Life 2: Episode Two)
Fires when the player dies.
OnStartSlowingTime  (only in Portal 2: Community Edition)
Fired when a Portal player initiates slow time.
OnStopSlowingTime  (only in Portal 2: Community Edition)
Fired when a Portal player stops slowing time.
OnPrimaryPortalPlaced  (only in Portal 2)
Fired when a Portal player successfully places the primary portal.
OnSecondaryPortalPlaced  (only in Portal 2)
Fired when a Portal player successfully places the secondary portal.
OnDuck  (in all games since Portal 2)
Fired when a player starts to duck.
OnUnDuck  (in all games since Portal 2)
Fired when a player releases the duck button.
OnJump  (in all games since Portal 2)
Fired when a player jumps.