From 22891bf59032ba88262824255a706d652031384b Mon Sep 17 00:00:00 2001 From: chai Date: Thu, 10 Mar 2022 14:07:40 +0800 Subject: * move folder --- Assets/Scripts/Physics/PhysicsBox.cs | 82 ------------------------------------ 1 file changed, 82 deletions(-) delete mode 100644 Assets/Scripts/Physics/PhysicsBox.cs (limited to 'Assets/Scripts/Physics/PhysicsBox.cs') diff --git a/Assets/Scripts/Physics/PhysicsBox.cs b/Assets/Scripts/Physics/PhysicsBox.cs deleted file mode 100644 index f8b4fee4..00000000 --- a/Assets/Scripts/Physics/PhysicsBox.cs +++ /dev/null @@ -1,82 +0,0 @@ -using System.Collections; -using System.Collections.Generic; -using UnityEngine; - -/// -/// AABB碰撞盒 -/// -public class PhysicsBox : PhysicsPrimitive -{ - public override PrimitiveType Type - { - get - { - return PrimitiveType.Box; - } - } - - [SerializeField] - private Vector3 m_Size; - public Vector3 Size - { - get - { - return m_Size; - } - } - - public float Long { get { return m_Size.x; } } - public float Wide { get { return m_Size.z; } } - public float Height { get { return m_Size.y; } } - - public bool m_DrawGizmo = true; - - public float Top - { - get - { - return Position.y + Height / 2f; - } - } - - public float Left - { - get - { - return Position.x - Long / 2f; - } - } - - public float Right - { - get - { - return Position.x + Long / 2f; - } - } - - public float Bottom - { - get - { - return Position.y - Height / 2f; - } - } - - public void OnDrawGizmos() - { - if (!m_IsActive || !m_DrawGizmo) - return; - Vector3 pos = Position; - Gizmos.color = m_HintColor; - Gizmos.DrawCube(pos, m_Size); - //Gizmos.color = Color.blue; - //Gizmos.DrawSphere(pos, 0.1f); - } - - private void Start() - { - base.OnInit(); - } - -} -- cgit v1.1-26-g67d0