Commit d052546b authored by 18강현모's avatar 18강현모

CameraController, GameState 등 코드 넣음. TetrisMap scale 동기화, UI 요소들 Canvas에 담음.

parent f7585de5
...@@ -52,7 +52,7 @@ Transform: ...@@ -52,7 +52,7 @@ Transform:
m_GameObject: {fileID: 1690644780631946} m_GameObject: {fileID: 1690644780631946}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: -4.3699484, y: 1.660439, z: 0} m_LocalPosition: {x: -4.3699484, y: 1.660439, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1} m_LocalScale: {x: 24, y: 24, z: 1}
m_Children: m_Children:
- {fileID: 4653007209432888} - {fileID: 4653007209432888}
m_Father: {fileID: 0} m_Father: {fileID: 0}
...@@ -82,7 +82,7 @@ MonoBehaviour: ...@@ -82,7 +82,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
......
...@@ -129,7 +129,7 @@ Transform: ...@@ -129,7 +129,7 @@ Transform:
m_GameObject: {fileID: 1986824515730090} m_GameObject: {fileID: 1986824515730090}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 7.85, y: 2.58, z: 0} m_LocalPosition: {x: 7.85, y: 2.58, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1} m_LocalScale: {x: 24, y: 24, z: 1}
m_Children: m_Children:
- {fileID: 4959807369913172} - {fileID: 4959807369913172}
- {fileID: 4417427676875474} - {fileID: 4417427676875474}
...@@ -175,7 +175,7 @@ MonoBehaviour: ...@@ -175,7 +175,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -192,7 +192,7 @@ MonoBehaviour: ...@@ -192,7 +192,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -209,7 +209,7 @@ MonoBehaviour: ...@@ -209,7 +209,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -247,7 +247,7 @@ MonoBehaviour: ...@@ -247,7 +247,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
......
...@@ -155,7 +155,7 @@ Transform: ...@@ -155,7 +155,7 @@ Transform:
m_GameObject: {fileID: 1058256109692646} m_GameObject: {fileID: 1058256109692646}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 2.15, y: -0.97, z: 0} m_LocalPosition: {x: 2.15, y: -0.97, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1} m_LocalScale: {x: 24, y: 24, z: 1}
m_Children: m_Children:
- {fileID: 4770256559059570} - {fileID: 4770256559059570}
- {fileID: 4403275080892776} - {fileID: 4403275080892776}
...@@ -175,7 +175,7 @@ MonoBehaviour: ...@@ -175,7 +175,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -192,7 +192,7 @@ MonoBehaviour: ...@@ -192,7 +192,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -209,7 +209,7 @@ MonoBehaviour: ...@@ -209,7 +209,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -226,7 +226,7 @@ MonoBehaviour: ...@@ -226,7 +226,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
......
...@@ -142,7 +142,7 @@ Transform: ...@@ -142,7 +142,7 @@ Transform:
m_GameObject: {fileID: 1409840693504816} m_GameObject: {fileID: 1409840693504816}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 2.77, y: 3.1, z: 0} m_LocalPosition: {x: 2.77, y: 3.1, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1} m_LocalScale: {x: 24, y: 24, z: 1}
m_Children: m_Children:
- {fileID: 4480540641426352} - {fileID: 4480540641426352}
- {fileID: 4890462092246654} - {fileID: 4890462092246654}
...@@ -175,7 +175,7 @@ MonoBehaviour: ...@@ -175,7 +175,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -192,7 +192,7 @@ MonoBehaviour: ...@@ -192,7 +192,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -209,7 +209,7 @@ MonoBehaviour: ...@@ -209,7 +209,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -226,7 +226,7 @@ MonoBehaviour: ...@@ -226,7 +226,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
......
...@@ -103,7 +103,7 @@ Transform: ...@@ -103,7 +103,7 @@ Transform:
m_GameObject: {fileID: 1599875259397162} m_GameObject: {fileID: 1599875259397162}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 5.6, y: -0.21, z: 0} m_LocalPosition: {x: 5.6, y: -0.21, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1} m_LocalScale: {x: 24, y: 24, z: 1}
m_Children: m_Children:
- {fileID: 4959495535370206} - {fileID: 4959495535370206}
- {fileID: 4534782373203126} - {fileID: 4534782373203126}
...@@ -175,7 +175,7 @@ MonoBehaviour: ...@@ -175,7 +175,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -192,7 +192,7 @@ MonoBehaviour: ...@@ -192,7 +192,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -230,7 +230,7 @@ MonoBehaviour: ...@@ -230,7 +230,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -247,7 +247,7 @@ MonoBehaviour: ...@@ -247,7 +247,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
......
...@@ -142,7 +142,7 @@ Transform: ...@@ -142,7 +142,7 @@ Transform:
m_GameObject: {fileID: 1051411815441030} m_GameObject: {fileID: 1051411815441030}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 10.24, y: 0.14, z: 0} m_LocalPosition: {x: 10.24, y: 0.14, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1} m_LocalScale: {x: 24, y: 24, z: 1}
m_Children: m_Children:
- {fileID: 4996993573163862} - {fileID: 4996993573163862}
- {fileID: 4153319652066896} - {fileID: 4153319652066896}
...@@ -175,7 +175,7 @@ MonoBehaviour: ...@@ -175,7 +175,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -192,7 +192,7 @@ MonoBehaviour: ...@@ -192,7 +192,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -209,7 +209,7 @@ MonoBehaviour: ...@@ -209,7 +209,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -247,7 +247,7 @@ MonoBehaviour: ...@@ -247,7 +247,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
......
...@@ -142,7 +142,7 @@ Transform: ...@@ -142,7 +142,7 @@ Transform:
m_GameObject: {fileID: 1216064749225226} m_GameObject: {fileID: 1216064749225226}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 14.87, y: 0.76, z: 0} m_LocalPosition: {x: 14.87, y: 0.76, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1} m_LocalScale: {x: 24, y: 24, z: 1}
m_Children: m_Children:
- {fileID: 4373465258801912} - {fileID: 4373465258801912}
- {fileID: 4268777523006110} - {fileID: 4268777523006110}
...@@ -175,7 +175,7 @@ MonoBehaviour: ...@@ -175,7 +175,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -192,7 +192,7 @@ MonoBehaviour: ...@@ -192,7 +192,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -209,7 +209,7 @@ MonoBehaviour: ...@@ -209,7 +209,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -226,7 +226,7 @@ MonoBehaviour: ...@@ -226,7 +226,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
......
...@@ -116,7 +116,7 @@ Transform: ...@@ -116,7 +116,7 @@ Transform:
m_GameObject: {fileID: 1597348377621660} m_GameObject: {fileID: 1597348377621660}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 11.8, y: 3.97, z: 0} m_LocalPosition: {x: 11.8, y: 3.97, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1} m_LocalScale: {x: 24, y: 24, z: 1}
m_Children: m_Children:
- {fileID: 4665049468911534} - {fileID: 4665049468911534}
- {fileID: 4244611340582260} - {fileID: 4244611340582260}
...@@ -175,7 +175,7 @@ MonoBehaviour: ...@@ -175,7 +175,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -213,7 +213,7 @@ MonoBehaviour: ...@@ -213,7 +213,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -230,7 +230,7 @@ MonoBehaviour: ...@@ -230,7 +230,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
...@@ -247,7 +247,7 @@ MonoBehaviour: ...@@ -247,7 +247,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3} m_Script: {fileID: 11500000, guid: f935789f55ec07f4ca6b334fba78ddb1, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
mapLocation: {x: 0, y: 0, z: 0} mapCoord: {x: 0, y: 0, z: 0}
doorInfo: doorInfo:
stage: 0 stage: 0
roomConcept: 0 roomConcept: 0
......
This diff is collapsed.
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class CameraController : MonoBehaviour {
GameManager.GameState lastGameState;
Vector3 destination;
// Use this for initialization
void Start()
{
lastGameState = GameManager.GameState.Ingame;
destination = transform.position;
}
// Update is called once per frame
void Update()
{
if (lastGameState != GameManager.gameState)
{
StartCoroutine("ChangeScene");
lastGameState = GameManager.gameState;
}
else if (lastGameState == GameManager.GameState.Ingame)
{
SetDestination();
}
GotoDestination();
}
IEnumerator ChangeScene()
{
yield return null;
}
void SetDestination()
{
}
void GotoDestination()
{
}
}
fileFormatVersion: 2
guid: 6ef4279cf32e10f4dbc71e2206514212
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
...@@ -3,7 +3,7 @@ using System.Collections.Generic; ...@@ -3,7 +3,7 @@ using System.Collections.Generic;
using UnityEngine; using UnityEngine;
public class Player : MonoBehaviour { public class Player : MonoBehaviour {
public LifeCrystalUI LCUI;
// Use this for initialization // Use this for initialization
void Start () { void Start () {
......
...@@ -7,18 +7,24 @@ public class PlayerController : MonoBehaviour { ...@@ -7,18 +7,24 @@ public class PlayerController : MonoBehaviour {
// Speeds of player // Speeds of player
[SerializeField] [SerializeField]
private float maxSpeed;
[SerializeField]
private float speed; private float speed;
[SerializeField] [SerializeField]
private float speedAir;
[SerializeField]
private float jumpSpeed; private float jumpSpeed;
[SerializeField] [SerializeField]
private float doubleJumpSpeed; private float doubleJumpSpeed;
// Bool values for jump & doublejump // Bool values for jump & doublejump
private bool isGrounded = true; private bool isGrounded = true;
private bool isJumpable = true; // Can player jump or doublejump? private bool isJumpable = true; // Can player jump or doublejump?
// Inputs // Inputs
private float horizontal = 0; private float horizontal = 0;
private float horizontalRaw = 0;
private bool jump = false; private bool jump = false;
// Variables for IsGrounded() // Variables for IsGrounded()
...@@ -35,6 +41,8 @@ public class PlayerController : MonoBehaviour { ...@@ -35,6 +41,8 @@ public class PlayerController : MonoBehaviour {
// Update is called once per frame // Update is called once per frame
void Update () { void Update () {
horizontal = Input.GetAxis("Horizontal"); horizontal = Input.GetAxis("Horizontal");
horizontalRaw = Input.GetAxisRaw("Horizontal");
if (Input.GetButtonDown("Jump")) if (Input.GetButtonDown("Jump"))
{ {
jump = true; jump = true;
...@@ -60,10 +68,21 @@ public class PlayerController : MonoBehaviour { ...@@ -60,10 +68,21 @@ public class PlayerController : MonoBehaviour {
isJumpable = false; isJumpable = false;
} }
} }
rb.velocity = new Vector2(horizontal * speed * Time.fixedDeltaTime, vertical);
//rb.velocity = new Vector2(horizontal * speed * Time.fixedDeltaTime, vertical);
// rb.velocity = new Vector2(rb.velocity.x, vertical);
rb.AddForce(horizontalRaw * speed * Time.fixedDeltaTime * Vector2.right);
if (((horizontalRaw==0) || (rb.velocity.x > 0 && horizontalRaw < 0)
|| (rb.velocity.x < 0 && horizontalRaw > 0)) &&(isGrounded))
{
rb.AddForce(rb.velocity.x * (-10f) * Vector2.right);
}
rb.velocity = new Vector2(Mathf.Clamp(rb.velocity.x, -maxSpeed*Time.fixedDeltaTime, maxSpeed * Time.fixedDeltaTime), vertical);
jump = false; jump = false;
} }
bool IsGrounded() // Is player grounded? bool IsGrounded() // Is player grounded?
{ {
RaycastHit2D hit = Physics2D.Raycast(transform.position, Vector2.down, rayDistance, groundLayer); RaycastHit2D hit = Physics2D.Raycast(transform.position, Vector2.down, rayDistance, groundLayer);
......
...@@ -4,10 +4,18 @@ using UnityEngine; ...@@ -4,10 +4,18 @@ using UnityEngine;
public class GameManager : MonoBehaviour { public class GameManager : MonoBehaviour {
// Use this for initialization public enum GameState { MainMenu, Ingame, Tetris, Pause, Inventory }
void Start () {
/// <summary>
} /// Which state this game is.
/// change later
/// </summary>
public static GameState gameState;
// Use this for initialization
void Start () {
gameState = GameState.Ingame;
}
// Update is called once per frame // Update is called once per frame
void Update () { void Update () {
......
...@@ -7,11 +7,7 @@ public class MapManager : MonoBehaviour { ...@@ -7,11 +7,7 @@ public class MapManager : MonoBehaviour {
/* /*
* variables * variables
* */ * */
/// <summary>
/// If camera is at tetris map, it is true.
/// If camera is at player, it is false.
/// </summary>
public bool inTetris;
/// <summary> /// <summary>
/// Tetris map's size. /// Tetris map's size.
/// </summary> /// </summary>
...@@ -206,14 +202,14 @@ public class MapManager : MonoBehaviour { ...@@ -206,14 +202,14 @@ public class MapManager : MonoBehaviour {
}*/ }*/
public void TetriminoMove(Tetrimino TE) public void TetriminoMove(Tetrimino TE)
{ {
if (Input.GetKeyDown(KeyCode.LeftArrow) && inTetris) if (Input.GetKeyDown(KeyCode.LeftArrow) && GameManager.gameState == GameManager.GameState.Tetris)
{ {
TE.mapCoord += new Vector3(-1, 0, 0); TE.mapCoord += new Vector3(-1, 0, 0);
SetRoomMapCoord(currentTetrimino); SetRoomMapCoord(currentTetrimino);
if (IsRightTetrimino(TE) != 0) if (IsRightTetrimino(TE) != 0)
TE.mapCoord += new Vector3(1, 0, 0); TE.mapCoord += new Vector3(1, 0, 0);
} }
else if (Input.GetKeyDown(KeyCode.RightArrow) && inTetris) else if (Input.GetKeyDown(KeyCode.RightArrow) && GameManager.gameState == GameManager.GameState.Tetris)
{ {
TE.mapCoord += new Vector3(1, 0, 0); TE.mapCoord += new Vector3(1, 0, 0);
SetRoomMapCoord(currentTetrimino); SetRoomMapCoord(currentTetrimino);
...@@ -244,7 +240,7 @@ public class MapManager : MonoBehaviour { ...@@ -244,7 +240,7 @@ public class MapManager : MonoBehaviour {
// Use this for initialization // Use this for initialization
void Start () { void Start () {
inTetris = true;
} }
// Update is called once per frame // Update is called once per frame
......
...@@ -228,7 +228,7 @@ public class LifeCrystalUI : MonoBehaviour ...@@ -228,7 +228,7 @@ public class LifeCrystalUI : MonoBehaviour
/// </summary> /// </summary>
void FixedUpdate () void FixedUpdate ()
{ {
textUI.text = "Life: " + lifeCount + ", Gold: " + goldCount; //textUI.text = "Life: " + lifeCount + ", Gold: " + goldCount;
} }
////////////////////////////////////////////////// Hidden functions ////////////////////////////////////////////////// Hidden functions
/// <summary> /// <summary>
......
...@@ -31,7 +31,7 @@ TextureImporter: ...@@ -31,7 +31,7 @@ TextureImporter:
maxTextureSize: 2048 maxTextureSize: 2048
textureSettings: textureSettings:
serializedVersion: 2 serializedVersion: 2
filterMode: -1 filterMode: 0
aniso: -1 aniso: -1
mipBias: -100 mipBias: -100
wrapU: 1 wrapU: 1
...@@ -63,7 +63,7 @@ TextureImporter: ...@@ -63,7 +63,7 @@ TextureImporter:
maxTextureSize: 2048 maxTextureSize: 2048
resizeAlgorithm: 0 resizeAlgorithm: 0
textureFormat: -1 textureFormat: -1
textureCompression: 1 textureCompression: 0
compressionQuality: 50 compressionQuality: 50
crunchedCompression: 0 crunchedCompression: 0
allowsAlphaSplitting: 0 allowsAlphaSplitting: 0
...@@ -74,7 +74,7 @@ TextureImporter: ...@@ -74,7 +74,7 @@ TextureImporter:
maxTextureSize: 2048 maxTextureSize: 2048
resizeAlgorithm: 0 resizeAlgorithm: 0
textureFormat: -1 textureFormat: -1
textureCompression: 1 textureCompression: 0
compressionQuality: 50 compressionQuality: 50
crunchedCompression: 0 crunchedCompression: 0
allowsAlphaSplitting: 0 allowsAlphaSplitting: 0
...@@ -85,7 +85,7 @@ TextureImporter: ...@@ -85,7 +85,7 @@ TextureImporter:
maxTextureSize: 2048 maxTextureSize: 2048
resizeAlgorithm: 0 resizeAlgorithm: 0
textureFormat: -1 textureFormat: -1
textureCompression: 1 textureCompression: 0
compressionQuality: 50 compressionQuality: 50
crunchedCompression: 0 crunchedCompression: 0
allowsAlphaSplitting: 0 allowsAlphaSplitting: 0
......
...@@ -90,7 +90,7 @@ InputManager: ...@@ -90,7 +90,7 @@ InputManager:
descriptiveName: descriptiveName:
descriptiveNegativeName: descriptiveNegativeName:
negativeButton: negativeButton:
positiveButton: space positiveButton: up
altNegativeButton: altNegativeButton:
altPositiveButton: altPositiveButton:
gravity: 1000 gravity: 1000
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment