This commit is contained in:
2026-05-30 09:16:35 +07:00
parent 2f87ce19a7
commit 1c0ee6efb7
4001 changed files with 3363438 additions and 1738 deletions

View File

@@ -0,0 +1,37 @@
using UnityEngine;
namespace Invector.vCharacterController
{
public class vRagdollCollision
{
private GameObject sender;
private Collision collision;
private float impactForce;
/// <summary>
/// Gameobjet receiver of collision info
/// </summary>
public GameObject Sender { get { return sender; } }
/// <summary>
/// Collision info
/// </summary>
public Collision Collision { get { return collision; } }
/// <summary>
/// Magnitude of relative linear velocity of the two colliding objects
/// </summary>
public float ImpactForce { get { return impactForce; } }
/// <summary>
/// Create a New collision info seu trouxa
/// </summary>
/// <param name="sender">current gameobjet</param>
/// <param name="collision">current collision info</param>
public vRagdollCollision(GameObject sender, Collision collision)
{
this.sender = sender;
this.collision = collision;
this.impactForce = collision.relativeVelocity.magnitude;
}
}
}