Commit 77bda0c2 authored by 18손재민's avatar 18손재민

Merge remote-tracking branch 'origin/interact'

parents 5f8bc94b 99b0af01
...@@ -90,6 +90,7 @@ GameObject: ...@@ -90,6 +90,7 @@ GameObject:
- component: {fileID: 439939669} - component: {fileID: 439939669}
- component: {fileID: 896145114} - component: {fileID: 896145114}
- component: {fileID: 7514060783340336889} - component: {fileID: 7514060783340336889}
- component: {fileID: 1176797860003478902}
m_Layer: 0 m_Layer: 0
m_Name: camera m_Name: camera
m_TagString: Untagged m_TagString: Untagged
...@@ -161,6 +162,20 @@ NavMeshObstacle: ...@@ -161,6 +162,20 @@ NavMeshObstacle:
m_CarveOnlyStationary: 1 m_CarveOnlyStationary: 1
m_Center: {x: 0, y: 0.5, z: 0} m_Center: {x: 0, y: 0.5, z: 0}
m_TimeToStationary: 0.5 m_TimeToStationary: 0.5
--- !u!136 &1176797860003478902
CapsuleCollider:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6001025753464815805}
m_Material: {fileID: 0}
m_IsTrigger: 0
m_Enabled: 1
m_Radius: 0.26
m_Height: 0.57
m_Direction: 1
m_Center: {x: 0, y: 0.42, z: 0}
--- !u!1 &6001025753464815807 --- !u!1 &6001025753464815807
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
......
...@@ -66,7 +66,7 @@ public class Briefcase : MonoBehaviour, IObject, IPlayerInteractor ...@@ -66,7 +66,7 @@ public class Briefcase : MonoBehaviour, IObject, IPlayerInteractor
if (GameManager.nCase >= 0) if (GameManager.nCase >= 0)
MapManager.inst.currentMap.clearConditions[GameManager.nCase].IsDone(1); MapManager.inst.currentMap.clearConditions[GameManager.nCase].IsDone(1);
floor.objOnFloor = null; floor.objOnFloor = null;
Destroy(gameObject); MapManager.inst.currentMap.RemoveObject(Position);
} }
} }
......
...@@ -21,7 +21,7 @@ public class CameraTurret : MonoBehaviour, IObject, IBreakable, IPlayerInteracto ...@@ -21,7 +21,7 @@ public class CameraTurret : MonoBehaviour, IObject, IBreakable, IPlayerInteracto
MapManager.inst.currentMap.clearConditions[GameManager.aTurret].IsDone(1); MapManager.inst.currentMap.clearConditions[GameManager.aTurret].IsDone(1);
if (GameManager.nTurret >= 0) if (GameManager.nTurret >= 0)
MapManager.inst.currentMap.clearConditions[GameManager.nTurret].IsDone(1); MapManager.inst.currentMap.clearConditions[GameManager.nTurret].IsDone(1);
Destroy(gameObject); MapManager.inst.currentMap.RemoveObject(Position);
} }
private void OnDestroy() private void OnDestroy()
......
...@@ -270,6 +270,7 @@ public class Map : MonoBehaviour ...@@ -270,6 +270,7 @@ public class Map : MonoBehaviour
PlayerController.inst.OnPlayerMove -= objectGrid[pos].GetObject().GetComponent<IPlayerInteractor>().Interact; PlayerController.inst.OnPlayerMove -= objectGrid[pos].GetObject().GetComponent<IPlayerInteractor>().Interact;
Destroy(objectGrid[pos].GetObject()); Destroy(objectGrid[pos].GetObject());
objectGrid.Remove(pos); objectGrid.Remove(pos);
floorGrid[pos].objOnFloor = null;
StartCoroutine(MapManager.inst.Rebaker()); StartCoroutine(MapManager.inst.Rebaker());
} }
else else
......
...@@ -7,7 +7,7 @@ public class Mirror : Wall, IBulletInteractor, IBreakable ...@@ -7,7 +7,7 @@ public class Mirror : Wall, IBulletInteractor, IBreakable
{ {
public void Break() public void Break()
{ {
Destroy(gameObject); MapManager.inst.currentMap.RemoveWall(this.mapPos);
} }
public void Interact(Bullet bullet) public void Interact(Bullet bullet)
......
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