Commit 5de2a416 authored by Chae Ho Shin's avatar Chae Ho Shin

LaserLevel preliminarywork

parent c7470ac0
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class LaserLevelManager : LevelManager
{
double time = 0;
// Start is called before the first frame update
protected override void Start()
{
base.Start();
time = 0;
}
// Update is called once per frame
protected override void Update()
{
if (Input.GetKey("D"))
{
time += Time.deltaTime;
}
if (Input.GetKeyUp("D"))
time = 0;
if (WinCondition())
WinMessage();
base.Update();
}
protected override bool WinCondition()
{
if (time > 10.0)
return true;
else
return false;
}
protected override bool LoseCondition()
{
if (base.player.time > 15.0)
return true;
else return false;
}
protected bool WinMessage()
{
}
}
fileFormatVersion: 2
guid: e294c7912850770489290e50cf29dc2d
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
...@@ -363,6 +363,7 @@ GameObject: ...@@ -363,6 +363,7 @@ GameObject:
m_Component: m_Component:
- component: {fileID: 279236943} - component: {fileID: 279236943}
- component: {fileID: 279236944} - component: {fileID: 279236944}
- component: {fileID: 279236945}
m_Layer: 0 m_Layer: 0
m_Name: LevelManager m_Name: LevelManager
m_TagString: Untagged m_TagString: Untagged
...@@ -409,7 +410,19 @@ MonoBehaviour: ...@@ -409,7 +410,19 @@ MonoBehaviour:
Todo: Todo:
target1: {fileID: 535323107} target1: {fileID: 535323107}
target2: {fileID: 980429088} target2: {fileID: 980429088}
clock: {fileID: 508656476} clock: {fileID: 0}
--- !u!114 &279236945
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 279236942}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: e294c7912850770489290e50cf29dc2d, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!1 &332710466 --- !u!1 &332710466
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
...@@ -1046,23 +1059,22 @@ MonoBehaviour: ...@@ -1046,23 +1059,22 @@ MonoBehaviour:
m_GameObject: {fileID: 508656475} m_GameObject: {fileID: 508656475}
m_Enabled: 1 m_Enabled: 1
m_EditorHideFlags: 0 m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 11c0c0a758005e0408c9a767ec478e97, type: 3} m_Script: {fileID: 11500000, guid: d21dcedb7a777274ab532991e3f871d8, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
objectType: 3 objectType: 4
collisionPreset: 4 collisionPreset: 3
beta: 0 beta: 0
alpha: {x: 0, y: 0, z: 0} alpha: {x: 0, y: 0, z: 0}
v: {x: 0, y: 0, z: 0} v: {x: 0, y: 0, z: 0}
orientation: {x: 0, y: 0, z: 0} orientation: {x: 0, y: 0, z: 0}
levelManager: {fileID: 279236944} levelManager: {fileID: 0}
gamma: 1 gamma: 1
time: 0 time: 0
apparenttime: 0 apparenttime: 0
theobject: {fileID: 508656475} theobject: {fileID: 0}
mass: 1 mass: 10
isClock: 1 isClock: 0
starttime: 0
--- !u!4 &508656477 --- !u!4 &508656477
Transform: Transform:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
......
...@@ -5,7 +5,16 @@ EditorBuildSettings: ...@@ -5,7 +5,16 @@ EditorBuildSettings:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
serializedVersion: 2 serializedVersion: 2
m_Scenes: m_Scenes:
- enabled: 1 - enabled: 0
path: Assets/Scenes/SampleScene.unity path: Assets/Scenes/SampleScene.unity
guid: 2cda990e2423bbf4892e6590ba056729 guid: 2cda990e2423bbf4892e6590ba056729
- enabled: 1
path: Assets/Scenes/mainmenu.unity
guid: aa1340b26a0877b409d173fe668a77e4
- enabled: 0
path: Assets/Scenes/ClockLevel.unity
guid: 09fd81914134c4f4a823ec2102b1bbfb
- enabled: 0
path: Assets/Scenes/Tutorial2.unity
guid: 75d221baaab6fff42966b5c132c589be
m_configObjects: {} m_configObjects: {}
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