Battle Talent  V11
Public Member Functions | Public Attributes | Static Public Attributes | Protected Member Functions | Protected Attributes | Properties | List of all members
CrossLink.Network.NetworkRagdollSync Class Reference

Inherits CrossLink.Network.NetworkSyncBase.

Public Member Functions

override void OnStartServer ()
 
override void OnStopServer ()
 
override void OnStartClient ()
 
override void OnStopClient ()
 
void MarkAsKeyframe ()
 
void BroadcastKeyframe ()
 
override void OnSerialize (NetworkWriter writer, bool initialState)
 
override void OnDeserialize (NetworkReader reader, bool initialState)
 
virtual bool CompareSnapshots (RagdollSnapshot currentSnapshot)
 
bool GetRagdollActiveSelf ()
 
List< int > GetRagdollJointMotions ()
 
int GetRagdollJointMotion (ConfigurableJoint joint)
 
void GetMotionValue (ConfigurableJointMotion motion, ref int motionValue, int motionIndex)
 
List< Vector3 > GetRagdollNodePositions ()
 
List< Quaternion > GetRagdollNodeRotations ()
 
List< Quaternion > GetRagdollJointTargetRotations ()
 
List< Vector3 > GetRagdollNodeVelocities ()
 
List< Vector3 > GetRagdollNodeAngularVelocities ()
 
void SetRagdollActiveSelf (bool activeSelf)
 
void SetRagdollJointMotions (List< int > jointMotions)
 
void SetRagdollJointMotion (ConfigurableJoint joint, int motionValue)
 
ConfigurableJointMotion SetMotionValue (int motionValue, int motionIndex)
 
void SetRagdollNodePositions (List< Vector3 > positions)
 
void SetRagdollNodeRotations (List< Quaternion > rotations)
 
void SetRagdollJointTargetRotations (List< Quaternion > rotations)
 
void SetRagdollNodeVelocities (List< Vector3 > velocities)
 
void SetRagdollNodeAngularVelocities (List< Vector3 > angularVelocities)
 
virtual RagdollSnapshot Construct ()
 
void ServerAddSnapshot (RagdollSnapshot snapshot)
 
void ClientAddSnapshot (RagdollSnapshot snapshot)
 
void ServerTargetHardApply (NetworkConnectionToClient conn)
 
void TargetHardApply (NetworkConnectionToClient conn, RagdollSnapshot snapshot)
 
void HardApply ()
 
void HardApply (RagdollSnapshot snapshot)
 
virtual void Reset ()
 

Public Attributes

List< Transform > ragdollNodes
 
List< Rigidbody > ragdollRBs
 
List< ConfigurableJoint > ragdollJoints
 
NetworkCharacterBase networkCharacter
 
bool onlySyncOnChange = true
 
float onlySyncOnChangeCorrectionMultiplier = 2
 
float bufferResetMultiplier = 3
 
bool compressRotation = true
 
float positionSensitivity = 0.01f
 
float rotationSensitivity = 0.01f
 
float targetRotationSensitivity = 0.01f
 
float velocitySensitivity = 0.01f
 
float angularVelocitySensitivity = 0.01f
 
bool syncLocalTrans
 
bool syncJointMotion = true
 
bool syncVelocity = false
 
bool syncAngularVelocity = false
 
bool physicsFollow = true
 
bool interpolatePositions = true
 
bool interpolateRotations = true
 
bool timelineOffset = false
 
RagdollSnapshot lastSnapshot
 
readonly SortedList< double, RagdollSnapshotclientSnapshots = new SortedList<double, RagdollSnapshot>(16)
 
readonly SortedList< double, RagdollSnapshotserverSnapshots = new SortedList<double, RagdollSnapshot>(16)
 
Queue< RagdollSnapshotcacheSnapshots = new Queue<RagdollSnapshot>()
 

Static Public Attributes

static RagdollProfile deadProfile
 
static RagdollProfile standRemoteProfile
 
static RagdollProfile standRemoteBossProfile
 

Protected Member Functions

override void LateUpdate ()
 
virtual void OnEnable ()
 
virtual void OnDisable ()
 
override void FixedUpdateServerLerp ()
 
override void FixedUpdateClientLerp ()
 
void AddSnapshot (SortedList< double, RagdollSnapshot > snapshots, double timeStamp, bool activeSelf, RagdollSnapshot.RagdollFrameType frameType, List< int > jointMotions, List< Vector3 > positions, List< Quaternion > rotations, List< Quaternion > targetRotations, List< Vector3 > velocities, List< Vector3 > angularVelocities)
 
virtual void Apply (RagdollSnapshot interpolated, RagdollSnapshot endGoal)
 
void OnC2SSync (List< int > bitMaskList, bool activeSelf, RagdollSnapshot.RagdollFrameType frameType, List< int > jointMotions, List< Vector3 > positions, List< Quaternion > rotations, List< Quaternion > targetRotations, List< Vector3 > velocities, List< Vector3 > angularVelocities)
 
void OnS2CSync (List< int > bitMaskList, bool activeSelf, RagdollSnapshot.RagdollFrameType frameType, List< int > jointMotionList, List< Vector3 > positions, List< Quaternion > rotations, List< Quaternion > targetRotations, List< Vector3 > velocities, List< Vector3 > angularVelocities)
 

Protected Attributes

bool ragdollChanged
 
bool cachedSnapshotComparison
 
bool hasSentUnchangedRagdoll
 

Properties

bool RagdollChanged [get]
 
double timeStampAdjustment [get]
 
double offset [get]
 
bool IsRagdoll [get, set]
 

Member Data Documentation

◆ lastSnapshot

RagdollSnapshot CrossLink.Network.NetworkRagdollSync.lastSnapshot
Initial value:
= new RagdollSnapshot()
{
remoteTime = 0,
localTime = 0,
activeSelf = true,
frameType = RagdollSnapshot.RagdollFrameType.Anim,
nodeJointMotionList = new List<int>(),
nodePositionList = new List<Vector3>(),
nodeRotationList = new List<Quaternion>(),
nodeTargetRotationList = new List<Quaternion>(),
nodeVelocityList = new List<Vector3>(),
nodeAngularVelocityList = new List<Vector3>()
}