From 4ea6222f27c11ca102c6c497fde4e80c9e0b08dc Mon Sep 17 00:00:00 2001 From: Maximilian Wagner Date: Tue, 30 May 2023 20:40:18 +0200 Subject: [PATCH] Scene Change und basic Inventory implementiert --- Assets/AssetsFORELLE/Script/ChangeScene.cs | 29 + .../AssetsFORELLE/Script/ChangeScene.cs.meta | 11 + .../AssetsFORELLE/Script/PickupCollision.cs | 40 ++ .../Script/PickupCollision.cs.meta | 11 + Assets/Scenes/SampleScene.unity | 619 +++++++++++++----- ProjectSettings/EditorBuildSettings.asset | 3 + ProjectSettings/TagManager.asset | 3 + 7 files changed, 548 insertions(+), 168 deletions(-) create mode 100644 Assets/AssetsFORELLE/Script/ChangeScene.cs create mode 100644 Assets/AssetsFORELLE/Script/ChangeScene.cs.meta create mode 100644 Assets/AssetsFORELLE/Script/PickupCollision.cs create mode 100644 Assets/AssetsFORELLE/Script/PickupCollision.cs.meta diff --git a/Assets/AssetsFORELLE/Script/ChangeScene.cs b/Assets/AssetsFORELLE/Script/ChangeScene.cs new file mode 100644 index 0000000..d007f92 --- /dev/null +++ b/Assets/AssetsFORELLE/Script/ChangeScene.cs @@ -0,0 +1,29 @@ +using System; +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.SceneManagement; + +public class ChangeScene : MonoBehaviour +{ + public Scene changeTo; + // Start is called before the first frame update + void Start() + { + + } + + // Update is called once per frame + void Update() + { + + } + + private void OnCollisionEnter2D(Collision2D other) + { + if (other.gameObject.CompareTag("SceneChanger")) + { + SceneManager.LoadScene(other.gameObject.name); + } + } +} diff --git a/Assets/AssetsFORELLE/Script/ChangeScene.cs.meta b/Assets/AssetsFORELLE/Script/ChangeScene.cs.meta new file mode 100644 index 0000000..b7a879d --- /dev/null +++ b/Assets/AssetsFORELLE/Script/ChangeScene.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: deb75ec73a5f4ec2b6cd07709279ceba +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/AssetsFORELLE/Script/PickupCollision.cs b/Assets/AssetsFORELLE/Script/PickupCollision.cs new file mode 100644 index 0000000..505bd98 --- /dev/null +++ b/Assets/AssetsFORELLE/Script/PickupCollision.cs @@ -0,0 +1,40 @@ +using System.Collections.Generic; +using System.Linq; +using UnityEngine; + +public class PickupCollision : MonoBehaviour +{ + private List items; + // Start is called before the first frame update + void Start() + { + items = new List(); + } + + // Update is called once per frame + void Update() + { + + } + + private void OnCollisionEnter2D(Collision2D other) + { + switch (other.gameObject.tag) // switch-case hier damit in zukunft einfach fälle hinzugefügt werden können + { + case "Item": + other.gameObject.SetActive(false); + items.Add(other.gameObject); + Debug.Log("Pickup: Take " + other.gameObject.name); + break; + + case "Openable": + // Entfernt den ersten "Key" welcher unter den Items gefunden wird, falls es einen gibt + if ( items.Remove((from item in items where item.name == "Key" select item).First()) ) + { // falls ein "Key" gefunden wurde, wird dieser genutzt + other.gameObject.SetActive(false); + Debug.Log("Pickup: Use Key"); + } + break; + } + } +} diff --git a/Assets/AssetsFORELLE/Script/PickupCollision.cs.meta b/Assets/AssetsFORELLE/Script/PickupCollision.cs.meta new file mode 100644 index 0000000..a9bcb83 --- /dev/null +++ b/Assets/AssetsFORELLE/Script/PickupCollision.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 5c8672c5b58eae84da6091aa48615de7 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Scenes/SampleScene.unity b/Assets/Scenes/SampleScene.unity index 7d1e522..ab07a48 100644 --- a/Assets/Scenes/SampleScene.unity +++ b/Assets/Scenes/SampleScene.unity @@ -377,7 +377,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -387,7 +387,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -397,7 +397,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -407,7 +407,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -417,7 +417,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -427,7 +427,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -437,7 +437,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -447,7 +447,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -457,7 +457,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -467,7 +467,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -477,7 +477,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -487,7 +487,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -497,7 +497,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -507,7 +507,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -517,7 +517,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -527,7 +527,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -537,7 +537,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -547,7 +547,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -557,7 +557,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -567,7 +567,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -577,7 +577,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -587,7 +587,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -597,7 +597,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -607,7 +607,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -617,7 +617,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -627,7 +627,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -637,7 +637,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -647,7 +647,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -657,7 +657,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -667,7 +667,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -677,7 +677,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -687,7 +687,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -697,7 +697,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -707,7 +707,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -717,7 +717,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -727,7 +727,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -737,7 +737,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -747,7 +747,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -757,7 +757,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -767,7 +767,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 0 - m_TileSpriteIndex: 0 + m_TileSpriteIndex: 1 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -777,7 +777,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -787,7 +787,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -797,7 +797,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 2 - m_TileSpriteIndex: 2 + m_TileSpriteIndex: 4294967295 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -807,7 +807,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 2 - m_TileSpriteIndex: 2 + m_TileSpriteIndex: 4294967295 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -817,7 +817,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 2 - m_TileSpriteIndex: 2 + m_TileSpriteIndex: 4294967295 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -827,7 +827,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 2 - m_TileSpriteIndex: 2 + m_TileSpriteIndex: 4294967295 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -837,7 +837,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -847,7 +847,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -857,7 +857,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 2 - m_TileSpriteIndex: 2 + m_TileSpriteIndex: 4294967295 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -867,7 +867,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 2 - m_TileSpriteIndex: 2 + m_TileSpriteIndex: 4294967295 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -877,7 +877,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 2 - m_TileSpriteIndex: 2 + m_TileSpriteIndex: 4294967295 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -887,7 +887,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 2 - m_TileSpriteIndex: 2 + m_TileSpriteIndex: 4294967295 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -897,7 +897,7 @@ Tilemap: second: serializedVersion: 2 m_TileIndex: 1 - m_TileSpriteIndex: 1 + m_TileSpriteIndex: 0 m_TileMatrixIndex: 0 m_TileColorIndex: 0 m_TileObjectToInstantiateIndex: 65535 @@ -912,12 +912,10 @@ Tilemap: - m_RefCount: 8 m_Data: {fileID: 11400000, guid: c042b0168f183084b9a8c850ca289a16, type: 2} m_TileSpriteArray: - - m_RefCount: 20 - m_Data: {fileID: -1225805465, guid: 45efae2189e416f4b9b78c0a9569ac0f, type: 3} - m_RefCount: 25 m_Data: {fileID: 1920180403, guid: 45efae2189e416f4b9b78c0a9569ac0f, type: 3} - - m_RefCount: 8 - m_Data: {fileID: 21300000, guid: 14205121399f9f440894480250b61b09, type: 3} + - m_RefCount: 20 + m_Data: {fileID: -1225805465, guid: 45efae2189e416f4b9b78c0a9569ac0f, type: 3} m_TileMatrixArray: - m_RefCount: 53 m_Data: @@ -1000,78 +998,22 @@ CompositeCollider2D: m_ColliderPaths: - m_Collider: {fileID: 456358848} m_ColliderPaths: - - - X: 120000000 - Y: -30000000 - - X: 60000000 - Y: -30000000 - - X: 60000000 - Y: 20000000 - - X: 50000000 - Y: 20000000 - - X: 50000000 - Y: -30000000 - - X: -80000000 + - - X: -80000000 Y: -30000000 - X: -80000000 Y: -50000000 - X: 120000000 Y: -50000000 - - - X: -60000000 - Y: 11250000 - - X: -59375000 - Y: 10625000 - - X: -50000000 - Y: 10625000 - - X: -50000000 - Y: 11250000 - - X: -49375000 - Y: 10625000 - - X: -40000000 - Y: 10625000 - - X: -40000000 - Y: 11250000 - - X: -39375000 - Y: 10625000 - - X: -30000000 - Y: 10625000 - - X: -30000000 + - X: 120000000 + Y: -30000000 + - X: 60000000 + Y: -30000000 + - X: 60000000 Y: 20000000 - - X: -70000000 + - X: 50000000 Y: 20000000 - - X: -70000000 - Y: 11250000 - - X: -69375000 - Y: 10625000 - - X: -60000000 - Y: 10625000 - - - X: 10000000 - Y: -8750000 - - X: 10625000 - Y: -9375000 - - X: 20000000 - Y: -9375000 - - X: 20000000 - Y: -8750000 - - X: 20625000 - Y: -9375000 - - X: 30000000 - Y: -9375000 - - X: 30000000 - Y: -8750000 - - X: 30625000 - Y: -9375000 - - X: 40000000 - Y: -9375000 - - X: 40000000 - Y: 0 - - X: 0 - Y: 0 - - X: 0 - Y: -8750000 - - X: 625000 - Y: -9375000 - - X: 10000000 - Y: -9375000 + - X: 50000000 + Y: -30000000 m_CompositePaths: m_Paths: - - {x: 12, y: -3} @@ -1082,34 +1024,6 @@ CompositeCollider2D: - {x: -8, y: -3} - {x: -8, y: -5} - {x: 12, y: -5} - - - {x: -6, y: 1.125} - - {x: -5.9375, y: 1.0625} - - {x: -5, y: 1.0625} - - {x: -5, y: 1.125} - - {x: -4.9375, y: 1.0625} - - {x: -4, y: 1.0625} - - {x: -4, y: 1.125} - - {x: -3.9375, y: 1.0625} - - {x: -3, y: 1.0625} - - {x: -3, y: 2} - - {x: -7, y: 2} - - {x: -7, y: 1.125} - - {x: -6.9375, y: 1.0625} - - {x: -6, y: 1.0625} - - - {x: 1, y: -0.875} - - {x: 1.0625, y: -0.9375} - - {x: 2, y: -0.9375} - - {x: 2, y: -0.875} - - {x: 2.0625, y: -0.9375} - - {x: 3, y: -0.9375} - - {x: 3, y: -0.875} - - {x: 3.0625, y: -0.9375} - - {x: 4, y: -0.9375} - - {x: 4, y: 0} - - {x: 0, y: 0} - - {x: 0, y: -0.875} - - {x: 0.0625, y: -0.9375} - - {x: 1, y: -0.9375} m_VertexDistance: 0.0005 m_OffsetDistance: 0 --- !u!50 &456358850 @@ -1251,6 +1165,39 @@ Transform: m_Father: {fileID: 0} m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &529666191 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 529666192} + m_Layer: 0 + m_Name: Items + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &529666192 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 529666191} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: + - {fileID: 690535037} + - {fileID: 1371744858} + m_Father: {fileID: 1561360181} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &619394800 GameObject: m_ObjectHideFlags: 0 @@ -1362,6 +1309,107 @@ Transform: m_Father: {fileID: 0} m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &690535036 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 690535037} + - component: {fileID: 690535039} + - component: {fileID: 690535040} + m_Layer: 0 + m_Name: Key + m_TagString: Item + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &690535037 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 690535036} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: -5.96, y: -3, z: 0.087166585} + m_LocalScale: {x: 0.2553, y: 0.3085, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 529666192} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!212 &690535039 +SpriteRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 690535036} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 0 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: a97c105638bdf8b4a8650670310a4cd3, type: 2} + m_StaticBatchInfo: + firstSubMesh: 0 + subMeshCount: 0 + m_StaticBatchRoot: {fileID: 0} + m_ProbeAnchor: {fileID: 0} + m_LightProbeVolumeOverride: {fileID: 0} + m_ScaleInLightmap: 1 + m_ReceiveGI: 1 + m_PreserveUVs: 0 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 1 + m_SelectedEditorRenderState: 0 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_Sprite: {fileID: -9095717837082945937, guid: 207ee8102dd4143d288186ef0be518ee, type: 3} + m_Color: {r: 0.9339623, g: 0.7881125, b: 0.083704144, a: 1} + m_FlipX: 0 + m_FlipY: 0 + m_DrawMode: 0 + m_Size: {x: 1, y: 2} + m_AdaptiveModeThreshold: 0.5 + m_SpriteTileMode: 0 + m_WasSpriteAssigned: 1 + m_MaskInteraction: 0 + m_SpriteSortPoint: 0 +--- !u!70 &690535040 +CapsuleCollider2D: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 690535036} + m_Enabled: 1 + m_Density: 1 + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_UsedByEffector: 0 + m_UsedByComposite: 0 + m_Offset: {x: -0.0000009536743, y: 0} + m_Size: {x: 1, y: 2} + m_Direction: 0 --- !u!1 &792973161 GameObject: m_ObjectHideFlags: 0 @@ -1373,10 +1421,11 @@ GameObject: - component: {fileID: 792973167} - component: {fileID: 792973166} - component: {fileID: 792973165} - - component: {fileID: 792973168} - component: {fileID: 792973169} - component: {fileID: 792973170} - component: {fileID: 792973171} + - component: {fileID: 792973172} + - component: {fileID: 792973173} m_Layer: 0 m_Name: Player m_TagString: Untagged @@ -1472,22 +1521,6 @@ Transform: m_Father: {fileID: 0} m_RootOrder: 3 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!70 &792973168 -CapsuleCollider2D: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 792973161} - m_Enabled: 1 - m_Density: 1 - m_Material: {fileID: 0} - m_IsTrigger: 0 - m_UsedByEffector: 0 - m_UsedByComposite: 0 - m_Offset: {x: 0, y: 0} - m_Size: {x: 0.98, y: 1} - m_Direction: 0 --- !u!70 &792973169 CapsuleCollider2D: m_ObjectHideFlags: 0 @@ -1534,6 +1567,32 @@ MonoBehaviour: m_Name: m_EditorClassIdentifier: inFirstDim: 1 +--- !u!114 &792973172 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 792973161} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5c8672c5b58eae84da6091aa48615de7, type: 3} + m_Name: + m_EditorClassIdentifier: +--- !u!114 &792973173 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 792973161} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: deb75ec73a5f4ec2b6cd07709279ceba, type: 3} + m_Name: + m_EditorClassIdentifier: + changeTo: + m_Handle: 0 --- !u!4 &921148901 stripped Transform: m_CorrespondingSourceObject: {fileID: 1690754592808301329, guid: b689b743b78fab64ba927428b8f042ac, type: 3} @@ -1570,6 +1629,117 @@ Transform: m_Father: {fileID: 1432947759} m_RootOrder: 2 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &1371744857 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1371744858} + - component: {fileID: 1371744861} + - component: {fileID: 1371744859} + m_Layer: 0 + m_Name: Door + m_TagString: Openable + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1371744858 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1371744857} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -4.6599, y: -2.1, z: 0.087166585} + m_LocalScale: {x: 0.9601, y: 3.2208, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 529666192} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!61 &1371744859 +BoxCollider2D: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1371744857} + m_Enabled: 1 + m_Density: 1 + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_UsedByEffector: 0 + m_UsedByComposite: 0 + m_Offset: {x: 0, y: 0} + m_SpriteTilingProperty: + border: {x: 0, y: 0, z: 0, w: 0} + pivot: {x: 0.5, y: 0.5} + oldSize: {x: 1, y: 1} + newSize: {x: 1, y: 1} + adaptiveTilingThreshold: 0.5 + drawMode: 0 + adaptiveTiling: 0 + m_AutoTiling: 0 + serializedVersion: 2 + m_Size: {x: 1, y: 1} + m_EdgeRadius: 0 +--- !u!212 &1371744861 +SpriteRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1371744857} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 0 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: a97c105638bdf8b4a8650670310a4cd3, type: 2} + m_StaticBatchInfo: + firstSubMesh: 0 + subMeshCount: 0 + m_StaticBatchRoot: {fileID: 0} + m_ProbeAnchor: {fileID: 0} + m_LightProbeVolumeOverride: {fileID: 0} + m_ScaleInLightmap: 1 + m_ReceiveGI: 1 + m_PreserveUVs: 0 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 1 + m_SelectedEditorRenderState: 0 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_Sprite: {fileID: 7482667652216324306, guid: 311925a002f4447b3a28927169b83ea6, type: 3} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_FlipX: 0 + m_FlipY: 0 + m_DrawMode: 0 + m_Size: {x: 1, y: 1} + m_AdaptiveModeThreshold: 0.5 + m_SpriteTileMode: 0 + m_WasSpriteAssigned: 1 + m_MaskInteraction: 0 + m_SpriteSortPoint: 0 --- !u!1 &1432947758 GameObject: m_ObjectHideFlags: 0 @@ -1627,7 +1797,7 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1561360180} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 2.3932476, y: 0.73239166, z: -0.087166585} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 @@ -1635,6 +1805,8 @@ Transform: - {fileID: 453912789} - {fileID: 921148901} - {fileID: 1432947759} + - {fileID: 529666192} + - {fileID: 1949346886} m_Father: {fileID: 0} m_RootOrder: 4 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} @@ -1853,6 +2025,117 @@ SpriteRenderer: m_WasSpriteAssigned: 1 m_MaskInteraction: 0 m_SpriteSortPoint: 0 +--- !u!1 &1949346885 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1949346886} + - component: {fileID: 1949346888} + - component: {fileID: 1949346889} + m_Layer: 0 + m_Name: Prototype + m_TagString: SceneChanger + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1949346886 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1949346885} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -12.6333, y: -2.5468, z: 0.087166585} + m_LocalScale: {x: 0.93347776, y: 2.3030007, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 1561360181} + m_RootOrder: 4 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!212 &1949346888 +SpriteRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1949346885} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 0 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: a97c105638bdf8b4a8650670310a4cd3, type: 2} + m_StaticBatchInfo: + firstSubMesh: 0 + subMeshCount: 0 + m_StaticBatchRoot: {fileID: 0} + m_ProbeAnchor: {fileID: 0} + m_LightProbeVolumeOverride: {fileID: 0} + m_ScaleInLightmap: 1 + m_ReceiveGI: 1 + m_PreserveUVs: 0 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 1 + m_SelectedEditorRenderState: 0 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_Sprite: {fileID: 7482667652216324306, guid: 311925a002f4447b3a28927169b83ea6, type: 3} + m_Color: {r: 0.8584906, g: 0.54659605, b: 0.26321647, a: 1} + m_FlipX: 0 + m_FlipY: 0 + m_DrawMode: 0 + m_Size: {x: 1, y: 1} + m_AdaptiveModeThreshold: 0.5 + m_SpriteTileMode: 0 + m_WasSpriteAssigned: 1 + m_MaskInteraction: 0 + m_SpriteSortPoint: 0 +--- !u!61 &1949346889 +BoxCollider2D: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1949346885} + m_Enabled: 1 + m_Density: 1 + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_UsedByEffector: 0 + m_UsedByComposite: 0 + m_Offset: {x: 0, y: 0} + m_SpriteTilingProperty: + border: {x: 0, y: 0, z: 0, w: 0} + pivot: {x: 0.5, y: 0.5} + oldSize: {x: 1, y: 1} + newSize: {x: 1, y: 1} + adaptiveTilingThreshold: 0.5 + drawMode: 0 + adaptiveTiling: 0 + m_AutoTiling: 0 + serializedVersion: 2 + m_Size: {x: 1, y: 1} + m_EdgeRadius: 0 --- !u!1 &2021624529 GameObject: m_ObjectHideFlags: 0 diff --git a/ProjectSettings/EditorBuildSettings.asset b/ProjectSettings/EditorBuildSettings.asset index 5f7c784..372e78d 100644 --- a/ProjectSettings/EditorBuildSettings.asset +++ b/ProjectSettings/EditorBuildSettings.asset @@ -8,4 +8,7 @@ EditorBuildSettings: - enabled: 1 path: Assets/Scenes/SampleScene.unity guid: 8c9cfa26abfee488c85f1582747f6a02 + - enabled: 1 + path: Assets/Scenes/Prototype.unity + guid: 690ad3268ada5f94b8d8d2ab06075ca8 m_configObjects: {} diff --git a/ProjectSettings/TagManager.asset b/ProjectSettings/TagManager.asset index 2358349..2f6e4aa 100644 --- a/ProjectSettings/TagManager.asset +++ b/ProjectSettings/TagManager.asset @@ -6,6 +6,9 @@ TagManager: tags: - PressurePlatable - PlayerIsOnIt + - Item + - Openable + - SceneChanger layers: - Default - TransparentFX