This article's documentation is for anything that uses the Source engine. Click here for more information.

Func physbox multiplayer: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
(-in css csgo fgd)
No edit summary
 
(3 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{Ent not in fgd|none|except={{css}}{{csgo}}}}
{{Ent not in fgd|none|except={{css}}{{csgo}}}}
{{this is a|e2|name=func_physbox_multiplayer}} It is identical to [[func_physbox]], except not Solid to players by default and the runtime collisions use a more bouncy method that avoids the prediction errors normal physics objects get.  
{{CD|CPhysBoxMultiplayer|file1=props.cpp}}
{{this is a|brush entity|name=func_physbox_multiplayer}} It is identical to {{ent|func_physbox}}, except not Solid to players by default and the runtime collisions use a more bouncy method that avoids the prediction errors normal physics objects get.  


In code it is represented by class CPhysBoxMultiplayer, defined in props.cpp.


{{OtherKIO|func_physbox|All}}
{{stub}}
== FGD Code ==
== FGD Code ==


Line 12: Line 15:
   ]
   ]


== Flags ==
* 4096 : Start Asleep
* 8192 : Ignore +USE for Pickup
* 16384 : Debris - Don't collide with the player or other debris
* 32768 : Motion Disabled
* 65536 : Use Preferred Carry Angles
* 131072 : Enable motion on Physcannon grab
* 262144 : Not affected by rotor wash
* 524288 : Generate output on +USE
* 1048576 : Physgun can ALWAYS pick up. No matter what.
* 2097152 : Physgun is NOT allowed to pick this up.
* 4194304 : Physgun is NOT allowed to punt this object.
* 8388608 : Prevent motion enable on player bump
{{Fl BreakableBrush}}
== Keyvalues ==
{{KV|Minimum Light Level|string|The minimum level of ambient light that hits this brush.}}
{{KV|Impact Damage Type|choices|Sets the "sharpness" of the brush. Sharp objects are far more damaging.}}
:* 0 : Blunt
:* 1 : Sharp
{{KV|Mass Scale|float|A scale multiplier for the object's mass.}}
{{KV|Override Parameters|string|A list of physics key/value pairs that are usually in a physics prop .qc file. Format is 'key,value,key,value,etc'.}}
{{KV|Health Level to Override Motion|int|If specified, this object will start motion disabled. Once its health has dropped below this specified amount, it will enable motion.}}
{{KV|Physics Impact Force to Override Motion|float|If specified, this object will start motion disabled. Any impact that imparts a force greater than this value on the physbox will enable motion.}}
{{KV|Strength|int|Number of points of damage to take before breaking.  0 means don't break.}}
{{KV|Preferred Player-carry Angles|vector|If the 'Use Preferred Carry Angles' spawnflag is set, this angle is the angle which the object should orient to when the player picks it up, with the physgun or +USE.}}
{{KV|Not solid to world|choices|If set, the object will pass through world geometry. }}
:* 0 : Solid to World
:* 1 : Passes through World
{{KV BreakableBrush}}
{{KV BaseEntity}}
== Inputs ==
{{IO|Wake|Wake up this physics object, if it is sleeping.}}
{{IO|Sleep|Put this physics object to sleep. It will wake if given the <code>Wake</code> input, or if force is applied to it. Note that physics objects go to sleep automatically after coming to rest for a while, so you don't really need to use this.}}
{{IO|EnableMotion|Enable physics motion/collision response.}}
{{IO|DisableMotion|Disable physics motion/collision response.}}
{{IO|ForceDrop|If this object is being carried by a player, with the physgun or +USE, force it to be dropped.}}
{{I BreakableBrush}}
{{I BaseEntity|prel4d=1}}
== Outputs ==
{{IO|OnDamaged|Fired when this entity is damaged.}}
{{IO|OnAwakened|Fired when this entity becomes awake (collision/force is applied).}}
{{IO|OnMotionEnabled|Fired when motion is enabled due to damage/physcannon/force.}}
{{IO|OnPhysGunPickup|Fired when a player picks this object up, either with the physgun or +USE.}}
{{IO|OnPhysGunPunt|Fired when a player punts this object with the physgun.}}
{{IO|OnPhysGunOnlyPickup|Fired when a player picks this object up WITH THE PHYSGUN. +USE pickups do not fire this output.}}
{{IO|OnPhysGunDrop|Fired when a player drops this object.}}
{{IO|OnPlayerUse|Fired when the player tries to +USE the physbox. This output will fire only if the Generate output on +USE spawnflag is set.}}
{{O Breakable}}
{{O BaseEntity|l4d=1}}


[[Category:Entities]]
[[Category:Physics]]
[[Category:Physics]]

Latest revision as of 13:45, 30 July 2024

Icon-NotInFGD.png
This entity is not in the FGD by default, except in Counter-Strike: SourceCounter-Strike: Global Offensive.
See below for instructions on making it available.
C++ Class hierarchy
CPhysBoxMultiplayer
CPhysBox
CBreakable
CBaseEntity
C++ props.cpp

func_physbox_multiplayer is a brush entity available in all Source Source games. It is identical to func_physbox, except not Solid to players by default and the runtime collisions use a more bouncy method that avoids the prediction errors normal physics objects get.


Note.pngNote:All Keyvalues / Inputs / Outputs are same as func_physbox.

Stub

This article or section is a stub. You can help by expanding it.

FGD Code

 @SolidClass base(func_physbox) = func_physbox_multiplayer: "This entity is identical to func_physbox, " +
     "except the runtime collisions use a more bouncy method that avoids " +
     "the prediction errors normal physics objects get."
 [
 ]