diff --git a/Assets/Scripts/DGemItem.cs b/Assets/Scripts/DGemItem.cs deleted file mode 100644 index b108d45..0000000 --- a/Assets/Scripts/DGemItem.cs +++ /dev/null @@ -1,26 +0,0 @@ -using UnityEngine; - -public class DGemItem : MonoBehaviour -{ - [SerializeField] private float decSpeed = 5f; - - // Start is called before the first frame update - private void Start() - { - } - - // Update is called once per frame - private void Update() - { - } - - - private void OnTriggerEnter(Collider collision) - { - if (collision.gameObject.CompareTag("Player")) - { - collision.gameObject.GetComponent().SetSpeed(decSpeed); - Destroy(gameObject); - } - } -} \ No newline at end of file diff --git a/Assets/Scripts/DGemItem.cs.meta b/Assets/Scripts/DGemItem.cs.meta deleted file mode 100644 index dc5ed7f..0000000 --- a/Assets/Scripts/DGemItem.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: b81301b367248407f8c53744b655b039 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/Scripts/Darkness/VectorFieldHandler.cs b/Assets/Scripts/Darkness/VectorFieldHandler.cs deleted file mode 100644 index 2e69793..0000000 --- a/Assets/Scripts/Darkness/VectorFieldHandler.cs +++ /dev/null @@ -1,33 +0,0 @@ -using System.Collections.Generic; -using UnityEngine; -using UnityEngine.VFX; - -public class VectorFieldHandler : MonoBehaviour -{ - [SerializeField] private float avoidanceDist; - - [SerializeField] private List avoidances; - - [SerializeField] private Vector3 size; - - [SerializeField] private VisualEffect effect; - - private Texture3D vField; - - // Start is called before the first frame update - private void Start() - { - vField = new Texture3D((int)size.x, (int)size.y, (int)size.z, TextureFormat.RFloat, 0); - for (var x = 0; x < size.x; x++) - for (var y = 0; y < size.y; y++) - for (var z = 0; z < size.z; z++) - vField.SetPixel(x, y, z, new Color(1, 0, 0, 0)); - //vField.SetPixel(0, 0, 0, new Color(1, 0, 0, 0)); - effect.SetTexture("VectorField", vField); - } - - // Update is called once per frame - private void Update() - { - } -} \ No newline at end of file diff --git a/Assets/Scripts/Darkness/VectorFieldHandler.cs.meta b/Assets/Scripts/Darkness/VectorFieldHandler.cs.meta deleted file mode 100644 index 58fd436..0000000 --- a/Assets/Scripts/Darkness/VectorFieldHandler.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 72a473445b963b24abc84791b0ffacaa -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/Scripts/GemItem.cs b/Assets/Scripts/GemItem.cs deleted file mode 100644 index b97b012..0000000 --- a/Assets/Scripts/GemItem.cs +++ /dev/null @@ -1,26 +0,0 @@ -using UnityEngine; - -public class GemItem : MonoBehaviour -{ - [SerializeField] private float instantSpeed = 98f; - - // Start is called before the first frame update - private void Start() - { - } - - // Update is called once per frame - private void Update() - { - } - - - private void OnTriggerEnter(Collider collision) - { - if (collision.gameObject.CompareTag("Player")) - { - collision.gameObject.GetComponent().SetSpeed(instantSpeed); - Destroy(gameObject); - } - } -} \ No newline at end of file diff --git a/Assets/Scripts/GemItem.cs.meta b/Assets/Scripts/GemItem.cs.meta deleted file mode 100644 index 19c0849..0000000 --- a/Assets/Scripts/GemItem.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 1330f6d70036c9847aec81a067a760d0 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/Scripts/Item/Readme.txt b/Assets/Scripts/Item/Readme.txt new file mode 100644 index 0000000..1e5223c --- /dev/null +++ b/Assets/Scripts/Item/Readme.txt @@ -0,0 +1,54 @@ +Class Definitions: +Overview: Basically the classes are built out to uniquely abstract certain types of objects. +Basically there are currently only Interactable Items that are used. Some are heavy (ie Power Cores) +used to power things like doors. The classes defined here offer functionality over serveral abstraction layers +to keep implementation of new items at a minimum with higher layers automatically performing tasks. + + +CarryableItem + - Type: Abstract Class + - Extends: MonoBehaviour + - Description: The highest level representation of an item. + - Features: Forces an item to have a size and name. + +InteractableItem + - Type: Abstract Class + - Extends: CarryableItem + - Description: Any 3D in world item that can be picked up in the game. + - Features: + - Must have a In World Canvas and Text that appears whenever the player gets close. + +Generic Interactable: + - Type: Class + - Extends: InteractableItem + - Description: Object has no functionality other than enforcing InteractableItem's features. + This was done since Abstract Classes cannot be instantiated in a scene. + +Heavy Interactable: + - Type: Class + - Extends: InteractableItem + - Description: A large item that the astronaut has to carry in their arms. + - Features: + - Offers functionality to Enable and Disable the collision systems of a Heavy + item for pickup. Additionally defines functions for classes that extend it to + define how it gets interacted with. + +Heavy Item Receiver: + - Type: Abstract Class + - Extends: InteractableItem + - Description: Represents items that stores Heavy Interactable Items within. + - Features: + - Defines space for the Heavy Item that is stored within it. + - Defines a keyword the receiver looks for when a heavy item is inserted. + +Door Interactable Item: + - Type: Class + - Extends: Heavy Item Receiver + - Description: Represents power slots for doors. Taking in a Heavy Interactable Item with + the name "Power Core" in it. + - Features: + - Defines the Interact() function for when a player clicks the interaction button. + - Checks if a player has a heavy item in its hands and moves it into the slot both + on back-end and visually. + - Then modifies the door's animator to animate it opening/closing. + diff --git a/Assets/Scripts/Darkness.meta b/Assets/Scripts/Item/Readme.txt.meta similarity index 57% rename from Assets/Scripts/Darkness.meta rename to Assets/Scripts/Item/Readme.txt.meta index 84a0318..20e9ea3 100644 --- a/Assets/Scripts/Darkness.meta +++ b/Assets/Scripts/Item/Readme.txt.meta @@ -1,7 +1,6 @@ fileFormatVersion: 2 -guid: a790bc1f421c79948b8379e14ea3907d -folderAsset: yes -DefaultImporter: +guid: 2ce538ccda9e214428659cda939799a1 +TextScriptImporter: externalObjects: {} userData: assetBundleName: