Barotrauma Server Doc
|
Public Member Functions | |||
bool | TryGetCollider (int index, out PhysicsBody collider) | ||
void | SubtractMass (Limb limb) | ||
virtual void | Recreate (RagdollParams ragdollParams=null) | ||
Call this to create the ragdoll from the RagdollParams. More... | |||
Ragdoll (Character character, string seed, RagdollParams ragdollParams=null) | |||
void | SaveRagdoll (string fileNameWithoutExtension=null) | ||
Saves all serializable data in the currently selected ragdoll params. This method should properly handle character flipping. More... | |||
void | ResetRagdoll (bool forceReload=false) | ||
Resets the serializable data to the currently selected ragdoll params. Force reloading always loads the xml stored on the disk. More... | |||
void | ResetJoints () | ||
Resets the current joint values to the serialized joint params. More... | |||
void | ResetLimbs () | ||
Resets the current limb values to the serialized limb params. More... | |||
void | AddJoint (JointParams jointParams) | ||
void | AddLimb (Limb limb) | ||
void | RemoveLimb (Limb limb) | ||
bool | OnLimbCollision (Fixture f1, Fixture f2, Contact contact) | ||
float | GetImpactDamage (float impact, float? impactTolerance=null) | ||
bool | SeverLimbJoint (LimbJoint limbJoint) | ||
virtual void | Flip () | ||
Vector2 | GetCenterOfMass () | ||
void | MoveLimb (Limb limb, Vector2 pos, float amount, bool pullFromCenter=false) | ||
| |||
void | ResetPullJoints (Func< Limb, bool > condition=null) | ||
void | FindHull (Vector2? worldPosition=null, bool setSubmarine=true) | ||
void | Teleport (Vector2 moveAmount, Vector2 velocityChange, bool detachProjectiles=true) | ||
void | Update (float deltaTime, Camera cam) | ||
void | ForceRefreshFloorY () | ||
float | GetSurfaceY () | ||
Get the position of the surface of water at the position of the character, in display units (taking into account connected hulls above the hull the character is in) More... | |||
void | SetPosition (Vector2 simPosition, bool lerp=false, bool ignorePlatforms=true, bool forceMainLimbToCollider=false, bool detachProjectiles=true) | ||
void | Hang () | ||
Limb | GetLimb (LimbType limbType, bool excludeSevered=true) | ||
Note that if there are multiple limbs of the same type, only the first (valid) limb is returned. More... | |||
Vector2? | GetMouthPosition () | ||
Vector2 | GetColliderBottom () | ||
Limb | FindLowestLimb () | ||
void | ReleaseStuckLimbs () | ||
void | HideAndDisable (LimbType limbType, float duration=0, bool ignoreCollisions=true) | ||
void | RestoreTemporarilyDisabled () | ||
void | Remove () | ||
Static Public Member Functions | |
static void | UpdateAll (float deltaTime, Camera cam) |
static void | RemoveAll () |
Public Attributes | |
LimbJoint[] | LimbJoints |
Vector2 | movement |
Structure | Stairs |
Direction | TargetDir |
bool | forceStanding |
bool | forceNotStanding |
Static Public Attributes | |
const float | MAX_SPEED = 20 |
Protected Member Functions | |
void | CreateColliders () |
void | CreateJoints () |
void | CreateLimbs () |
void | AddLimb (LimbParams limbParams) |
List< Limb > | GetConnectedLimbs (Limb limb) |
void | LogAccessedRemovedCharacterError () |
void | TrySetLimbPosition (Limb limb, Vector2 original, Vector2 simPosition, float rotation, bool lerp=false, bool ignorePlatforms=true) |
void | CheckDistFromCollider () |
Protected Attributes | |
Hull | currentHull |
Character | character |
float | strongestImpact |
Vector2 | targetMovement |
Vector2 | overrideTargetMovement |
float | floorY |
Fixture | floorFixture |
Vector2 | floorNormal = Vector2.UnitY |
float | surfaceY |
bool | inWater |
bool | onGround |
Direction | dir |
List< PhysicsBody > | collider |
int | colliderIndex = 0 |
bool | levitatingCollider = true |
Properties | |
abstract RagdollParams | RagdollParams [get, protected set] |
Limb[] | Limbs [get] |
bool | HasMultipleLimbsOfSameType [get] |
bool?? | Frozen [get, set] |
Character | Character [get] |
bool | OnGround [get] |
float | ColliderHeightFromFloor [get] |
In sim units. Joint scale applied. More... | |
bool | IsStuck [get] |
PhysicsBody? | Collider [get] |
int | ColliderIndex [get, set] |
float | FloorY [get] |
float | Mass [get] |
Limb?? | MainLimb [get] |
Vector2? | WorldPosition [get] |
bool? | SimplePhysicsEnabled [get, set] |
Vector2? | TargetMovement [get, set] |
abstract ? float | HeadPosition [get] |
abstract ? float | HeadAngle [get] |
abstract ? float | TorsoPosition [get] |
abstract ? float | TorsoAngle [get] |
float?? | ImpactTolerance [get] |
bool | Draggable [get] |
bool | CanEnterSubmarine [get] |
float | Dir [get] |
Direction | Direction [get] |
bool | InWater [get] |
bool | HeadInWater [get] |
Hull? | CurrentHull [get, set] |
bool | IgnorePlatforms [get, set] |
bool | IsFlipped [get] |
bool? | BodyInRest [get, set] |
bool | Invalid [get] |
bool | IsHanging [get, protected set] |
Definition at line 18 of file Ragdoll.cs.
Barotrauma.Ragdoll.Ragdoll | ( | Character | character, |
string | seed, | ||
RagdollParams | ragdollParams = null |
||
) |
Definition at line 458 of file Ragdoll.cs.
void Barotrauma.Ragdoll.AddJoint | ( | JointParams | jointParams | ) |
Definition at line 574 of file Ragdoll.cs.
void Barotrauma.Ragdoll.AddLimb | ( | Limb | limb | ) |
Definition at line 625 of file Ragdoll.cs.
|
protected |
Definition at line 607 of file Ragdoll.cs.
|
protected |
Definition at line 1965 of file Ragdoll.cs.
|
protected |
Definition at line 465 of file Ragdoll.cs.
|
protected |
Definition at line 488 of file Ragdoll.cs.
|
protected |
Definition at line 525 of file Ragdoll.cs.
void Barotrauma.Ragdoll.FindHull | ( | Vector2? | worldPosition = null , |
bool | setSubmarine = true |
||
) |
Definition at line 1036 of file Ragdoll.cs.
Limb Barotrauma.Ragdoll.FindLowestLimb | ( | ) |
Definition at line 2108 of file Ragdoll.cs.
|
virtual |
Reimplemented in Barotrauma.HumanoidAnimController, and Barotrauma.FishAnimController.
Definition at line 949 of file Ragdoll.cs.
void Barotrauma.Ragdoll.ForceRefreshFloorY | ( | ) |
Definition at line 1653 of file Ragdoll.cs.
Vector2 Barotrauma.Ragdoll.GetCenterOfMass | ( | ) |
Definition at line 979 of file Ragdoll.cs.
Vector2 Barotrauma.Ragdoll.GetColliderBottom | ( | ) |
Definition at line 2085 of file Ragdoll.cs.
Definition at line 911 of file Ragdoll.cs.
float Barotrauma.Ragdoll.GetImpactDamage | ( | float | impact, |
float? | impactTolerance = null |
||
) |
Definition at line 853 of file Ragdoll.cs.
Note that if there are multiple limbs of the same type, only the first (valid) limb is returned.
Definition at line 2049 of file Ragdoll.cs.
Vector2? Barotrauma.Ragdoll.GetMouthPosition | ( | ) |
Definition at line 2074 of file Ragdoll.cs.
float Barotrauma.Ragdoll.GetSurfaceY | ( | ) |
Get the position of the surface of water at the position of the character, in display units (taking into account connected hulls above the hull the character is in)
Definition at line 1800 of file Ragdoll.cs.
void Barotrauma.Ragdoll.Hang | ( | ) |
Definition at line 1910 of file Ragdoll.cs.
void Barotrauma.Ragdoll.HideAndDisable | ( | LimbType | limbType, |
float | duration = 0 , |
||
bool | ignoreCollisions = true |
||
) |
Definition at line 2133 of file Ragdoll.cs.
|
protected |
Definition at line 1565 of file Ragdoll.cs.
void Barotrauma.Ragdoll.MoveLimb | ( | Limb | limb, |
Vector2 | pos, | ||
float | amount, | ||
bool | pullFromCenter = false |
||
) |
pullFromCenter | if false, force is applied to the position of pullJoint |
Definition at line 1013 of file Ragdoll.cs.
bool Barotrauma.Ragdoll.OnLimbCollision | ( | Fixture | f1, |
Fixture | f2, | ||
Contact | contact | ||
) |
Definition at line 698 of file Ragdoll.cs.
|
virtual |
Call this to create the ragdoll from the RagdollParams.
Reimplemented in Barotrauma.HumanoidAnimController, and Barotrauma.AnimController.
Definition at line 377 of file Ragdoll.cs.
void Barotrauma.Ragdoll.ReleaseStuckLimbs | ( | ) |
Definition at line 2127 of file Ragdoll.cs.
void Barotrauma.Ragdoll.Remove | ( | ) |
Definition at line 2146 of file Ragdoll.cs.
|
static |
Definition at line 2182 of file Ragdoll.cs.
void Barotrauma.Ragdoll.RemoveLimb | ( | Limb | limb | ) |
Definition at line 636 of file Ragdoll.cs.
void Barotrauma.Ragdoll.ResetJoints | ( | ) |
Resets the current joint values to the serialized joint params.
Definition at line 560 of file Ragdoll.cs.
void Barotrauma.Ragdoll.ResetLimbs | ( | ) |
Resets the current limb values to the serialized limb params.
Definition at line 568 of file Ragdoll.cs.
void Barotrauma.Ragdoll.ResetPullJoints | ( | Func< Limb, bool > | condition = null | ) |
Definition at line 1018 of file Ragdoll.cs.
void Barotrauma.Ragdoll.ResetRagdoll | ( | bool | forceReload = false | ) |
Resets the serializable data to the currently selected ragdoll params. Force reloading always loads the xml stored on the disk.
Definition at line 550 of file Ragdoll.cs.
void Barotrauma.Ragdoll.RestoreTemporarilyDisabled | ( | ) |
void Barotrauma.Ragdoll.SaveRagdoll | ( | string | fileNameWithoutExtension = null | ) |
Saves all serializable data in the currently selected ragdoll params. This method should properly handle character flipping.
Definition at line 541 of file Ragdoll.cs.
void Barotrauma.Ragdoll.SetPosition | ( | Vector2 | simPosition, |
bool | lerp = false , |
||
bool | ignorePlatforms = true , |
||
bool | forceMainLimbToCollider = false , |
||
bool | detachProjectiles = true |
||
) |
Definition at line 1856 of file Ragdoll.cs.
bool Barotrauma.Ragdoll.SeverLimbJoint | ( | LimbJoint | limbJoint | ) |
Definition at line 861 of file Ragdoll.cs.
void Barotrauma.Ragdoll.SubtractMass | ( | Limb | limb | ) |
Definition at line 213 of file Ragdoll.cs.
void Barotrauma.Ragdoll.Teleport | ( | Vector2 | moveAmount, |
Vector2 | velocityChange, | ||
bool | detachProjectiles = true |
||
) |
Definition at line 1144 of file Ragdoll.cs.
bool Barotrauma.Ragdoll.TryGetCollider | ( | int | index, |
out PhysicsBody | collider | ||
) |
Definition at line 152 of file Ragdoll.cs.
|
protected |
Definition at line 1918 of file Ragdoll.cs.
void Barotrauma.Ragdoll.Update | ( | float | deltaTime, |
Camera | cam | ||
) |
Definition at line 1232 of file Ragdoll.cs.
|
static |
Definition at line 1028 of file Ragdoll.cs.
|
protected |
Definition at line 95 of file Ragdoll.cs.
|
protected |
Definition at line 137 of file Ragdoll.cs.
|
protected |
Definition at line 138 of file Ragdoll.cs.
|
protected |
Definition at line 50 of file Ragdoll.cs.
|
protected |
Definition at line 133 of file Ragdoll.cs.
|
protected |
Definition at line 115 of file Ragdoll.cs.
|
protected |
Definition at line 116 of file Ragdoll.cs.
|
protected |
Definition at line 114 of file Ragdoll.cs.
bool Barotrauma.Ragdoll.forceNotStanding |
Definition at line 1230 of file Ragdoll.cs.
bool Barotrauma.Ragdoll.forceStanding |
Definition at line 1229 of file Ragdoll.cs.
|
protected |
Definition at line 119 of file Ragdoll.cs.
|
protected |
Definition at line 1207 of file Ragdoll.cs.
LimbJoint [] Barotrauma.Ragdoll.LimbJoints |
Definition at line 90 of file Ragdoll.cs.
|
static |
Definition at line 295 of file Ragdoll.cs.
Vector2 Barotrauma.Ragdoll.movement |
Definition at line 106 of file Ragdoll.cs.
|
protected |
Definition at line 120 of file Ragdoll.cs.
|
protected |
Definition at line 112 of file Ragdoll.cs.
Structure Barotrauma.Ragdoll.Stairs |
Definition at line 131 of file Ragdoll.cs.
|
protected |
Definition at line 97 of file Ragdoll.cs.
|
protected |
Definition at line 117 of file Ragdoll.cs.
Direction Barotrauma.Ragdoll.TargetDir |
Definition at line 135 of file Ragdoll.cs.
|
protected |
Definition at line 108 of file Ragdoll.cs.
|
getset |
Definition at line 1216 of file Ragdoll.cs.
|
get |
Definition at line 338 of file Ragdoll.cs.
|
get |
Definition at line 94 of file Ragdoll.cs.
|
get |
Definition at line 144 of file Ragdoll.cs.
|
get |
In sim units. Joint scale applied.
Definition at line 129 of file Ragdoll.cs.
|
getset |
Definition at line 166 of file Ragdoll.cs.
|
getset |
Definition at line 354 of file Ragdoll.cs.
|
get |
Definition at line 340 of file Ragdoll.cs.
|
get |
Definition at line 342 of file Ragdoll.cs.
|
get |
Definition at line 337 of file Ragdoll.cs.
|
get |
Definition at line 202 of file Ragdoll.cs.
|
getset |
Definition at line 71 of file Ragdoll.cs.
|
get |
Definition at line 68 of file Ragdoll.cs.
|
get |
Definition at line 312 of file Ragdoll.cs.
|
get |
Definition at line 349 of file Ragdoll.cs.
|
get |
Definition at line 311 of file Ragdoll.cs.
|
getset |
Definition at line 372 of file Ragdoll.cs.
|
get |
Definition at line 317 of file Ragdoll.cs.
|
get |
Definition at line 1459 of file Ragdoll.cs.
|
get |
Definition at line 344 of file Ragdoll.cs.
|
get |
Definition at line 947 of file Ragdoll.cs.
|
getprotected set |
Definition at line 1908 of file Ragdoll.cs.
|
get |
Definition at line 142 of file Ragdoll.cs.
|
get |
Definition at line 55 of file Ragdoll.cs.
|
get |
Definition at line 221 of file Ragdoll.cs.
|
get |
Definition at line 207 of file Ragdoll.cs.
|
get |
Definition at line 121 of file Ragdoll.cs.
|
getprotected set |
Definition at line 20 of file Ragdoll.cs.
|
getset |
Definition at line 256 of file Ragdoll.cs.
|
getset |
Definition at line 297 of file Ragdoll.cs.
|
get |
Definition at line 314 of file Ragdoll.cs.
|
get |
Definition at line 313 of file Ragdoll.cs.
|
get |
Definition at line 246 of file Ragdoll.cs.