Fixed Camera Point Added
This commit is contained in:
parent
d6c026bd99
commit
1dc131645d
|
@ -0,0 +1,33 @@
|
||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!1 &3929850441380138760
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 5137337335022132405}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: Fixed Camera Point
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!4 &5137337335022132405
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 3929850441380138760}
|
||||||
|
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: []
|
||||||
|
m_Father: {fileID: 0}
|
||||||
|
m_RootOrder: 0
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
|
@ -0,0 +1,7 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 8bb5d26746f32bd41bb00bc9809065ac
|
||||||
|
PrefabImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -13,6 +13,8 @@ namespace Level
|
||||||
private GameObject instance = null;
|
private GameObject instance = null;
|
||||||
private bool needsRestart = true;
|
private bool needsRestart = true;
|
||||||
|
|
||||||
|
public Transform FixedCameraPoint { get; private set; } = null;
|
||||||
|
|
||||||
public void SetLevel(int levelNumber)
|
public void SetLevel(int levelNumber)
|
||||||
{
|
{
|
||||||
LevelNumber = levelNumber;
|
LevelNumber = levelNumber;
|
||||||
|
@ -36,6 +38,8 @@ namespace Level
|
||||||
|
|
||||||
instance = Instantiate(prefab, transform.position, Quaternion.identity, transform);
|
instance = Instantiate(prefab, transform.position, Quaternion.identity, transform);
|
||||||
StartingPoint = instance.transform.Find("Starting Point");
|
StartingPoint = instance.transform.Find("Starting Point");
|
||||||
|
FixedCameraPoint = instance.transform.Find("Fixed Camera Point");
|
||||||
|
|
||||||
gameObject.SetActive(false);
|
gameObject.SetActive(false);
|
||||||
needsRestart = false;
|
needsRestart = false;
|
||||||
}
|
}
|
||||||
|
|
|
@ -36,6 +36,7 @@ namespace Level
|
||||||
}
|
}
|
||||||
|
|
||||||
private Level currentLevel = null;
|
private Level currentLevel = null;
|
||||||
|
public Level CurrentLevel => currentLevel;
|
||||||
|
|
||||||
private void Awake()
|
private void Awake()
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue