mirror of
https://github.com/frizbee19/FebGameJam.git
synced 2026-11-11 04:22:40 +00:00
9 files changed
+5905
-397
No files matched your search
@@ -26,8 +26,8 @@ Transform:
|
|||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
m_GameObject: {fileID: 1863913792}
|
m_GameObject: {fileID: 1863913792}
|
||||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
m_LocalPosition: {x: 0, y: 1.21, z: 0}
|
||||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
m_LocalScale: {x: 1, y: 0.5, z: 1}
|
||||||
m_Children: []
|
m_Children: []
|
||||||
m_Father: {fileID: 4058488523496122551}
|
m_Father: {fileID: 4058488523496122551}
|
||||||
m_RootOrder: 1
|
m_RootOrder: 1
|
||||||
@@ -45,6 +45,7 @@ MonoBehaviour:
|
|||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
cam: {fileID: 0}
|
cam: {fileID: 0}
|
||||||
|
offset: 0
|
||||||
--- !u!61 &1863913794
|
--- !u!61 &1863913794
|
||||||
BoxCollider2D:
|
BoxCollider2D:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -80,7 +81,7 @@ PrefabInstance:
|
|||||||
m_Modifications:
|
m_Modifications:
|
||||||
- target: {fileID: 8525598097607813777, guid: b7f2f989c2081d545b71b393bd6a1795, type: 3}
|
- target: {fileID: 8525598097607813777, guid: b7f2f989c2081d545b71b393bd6a1795, type: 3}
|
||||||
propertyPath: m_Name
|
propertyPath: m_Name
|
||||||
value: Cloud Ceiling
|
value: Cloud Ceiling Variant
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 8525598097607813804, guid: b7f2f989c2081d545b71b393bd6a1795, type: 3}
|
- target: {fileID: 8525598097607813804, guid: b7f2f989c2081d545b71b393bd6a1795, type: 3}
|
||||||
propertyPath: m_RootOrder
|
propertyPath: m_RootOrder
|
||||||
|
|||||||
@@ -393,11 +393,13 @@ MonoBehaviour:
|
|||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
forceInteract: 1
|
forceInteract: 1
|
||||||
repeatable: 0
|
repeatable: 1
|
||||||
value: 0
|
value: 0
|
||||||
despawnTimer: 5
|
despawnTimer: 5
|
||||||
entity: {fileID: 1489501924}
|
entity: {fileID: 1489501924}
|
||||||
startPos: {x: 0, y: 0}
|
startPos: {x: 0, y: 0}
|
||||||
|
respawns: 1
|
||||||
|
respawnTime: 1
|
||||||
--- !u!61 &814501016
|
--- !u!61 &814501016
|
||||||
BoxCollider2D:
|
BoxCollider2D:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -423,7 +425,7 @@ BoxCollider2D:
|
|||||||
m_AutoTiling: 0
|
m_AutoTiling: 0
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
m_Size: {x: 3, y: 3}
|
m_Size: {x: 3, y: 3}
|
||||||
m_EdgeRadius: 2
|
m_EdgeRadius: 9
|
||||||
--- !u!4 &814501017
|
--- !u!4 &814501017
|
||||||
Transform:
|
Transform:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
|||||||
File diff suppressed because it is too large.
Load diff
@@ -13,10 +13,15 @@ public class Platform : MonoBehaviour
|
|||||||
{
|
{
|
||||||
if(isMoving)
|
if(isMoving)
|
||||||
{
|
{
|
||||||
startPos = transform.position;
|
Activate();
|
||||||
StartCoroutine(LerpPosition(positionToMoveTo, length));
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void Activate() {
|
||||||
|
startPos = transform.position;
|
||||||
|
StartCoroutine(LerpPosition(positionToMoveTo, length));
|
||||||
|
|
||||||
|
}
|
||||||
IEnumerator LerpPosition(Vector3 targetPosition, float duration)
|
IEnumerator LerpPosition(Vector3 targetPosition, float duration)
|
||||||
{
|
{
|
||||||
float time = 0;
|
float time = 0;
|
||||||
|
|||||||
@@ -0,0 +1,13 @@
|
|||||||
|
using System.Collections;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
public class PlatformTrigger : Trigger
|
||||||
|
{
|
||||||
|
public GameObject platform;
|
||||||
|
public override void Action()
|
||||||
|
{
|
||||||
|
platform.GetComponent<Platform>().isMoving = true;
|
||||||
|
platform.GetComponent<Platform>().Activate();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,11 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 705c1491fdb252841a61a0ff750d556d
|
||||||
|
MonoImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -7,7 +7,6 @@ public class SpawnTrigger : Trigger
|
|||||||
[SerializeField] float despawnTimer = 10f;
|
[SerializeField] float despawnTimer = 10f;
|
||||||
[SerializeField] GameObject entity;
|
[SerializeField] GameObject entity;
|
||||||
[SerializeField] Vector2 startPos;
|
[SerializeField] Vector2 startPos;
|
||||||
private GameObject clone;
|
|
||||||
private bool spawned;
|
private bool spawned;
|
||||||
[SerializeField] bool respawns = false;
|
[SerializeField] bool respawns = false;
|
||||||
[SerializeField] float respawnTime = 3f;
|
[SerializeField] float respawnTime = 3f;
|
||||||
@@ -17,11 +16,15 @@ public class SpawnTrigger : Trigger
|
|||||||
|
|
||||||
//And function itself
|
//And function itself
|
||||||
IEnumerator SpawnDespawn(){
|
IEnumerator SpawnDespawn(){
|
||||||
|
GameObject clone;
|
||||||
|
|
||||||
clone = Instantiate(entity, startPos, Quaternion.identity);
|
clone = Instantiate(entity, startPos, Quaternion.identity);
|
||||||
clone.gameObject.SetActive(true);
|
clone.gameObject.SetActive(true);
|
||||||
yield return new WaitForSeconds(despawnTimer);
|
yield return new WaitForSeconds(despawnTimer);
|
||||||
Destroy(clone);
|
Destroy(clone);
|
||||||
this.gameObject.SetActive(false);
|
if(!respawns) {
|
||||||
|
this.gameObject.SetActive(false);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
public override void Action() {
|
public override void Action() {
|
||||||
if(!spawned && !respawns) {
|
if(!spawned && !respawns) {
|
||||||
@@ -29,10 +32,11 @@ public class SpawnTrigger : Trigger
|
|||||||
StartCoroutine(SpawnDespawn());
|
StartCoroutine(SpawnDespawn());
|
||||||
}
|
}
|
||||||
else if(respawns) {
|
else if(respawns) {
|
||||||
if(elapsed < respawnTime) {
|
elapsed += Time.deltaTime;
|
||||||
elapsed = 0;
|
if(elapsed > respawnTime) {
|
||||||
|
|
||||||
StartCoroutine(SpawnDespawn());
|
elapsed = 0;
|
||||||
|
StartCoroutine(SpawnDespawn());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -56,8 +56,8 @@ public abstract class Trigger : MonoBehaviour
|
|||||||
if(forceInteract)
|
if(forceInteract)
|
||||||
{
|
{
|
||||||
Action();
|
Action();
|
||||||
hasOccurred = true;
|
|
||||||
if(!repeatable) {
|
if(!repeatable) {
|
||||||
|
hasOccurred = true;
|
||||||
isActive = false;
|
isActive = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -9,6 +9,21 @@ EditorUserSettings:
|
|||||||
value: 22424703114646680e0b0227036c78111b1258192f2d28353e663032ebee7415e7e923a7f234362820
|
value: 22424703114646680e0b0227036c78111b1258192f2d28353e663032ebee7415e7e923a7f234362820
|
||||||
flags: 0
|
flags: 0
|
||||||
RecentlyUsedScenePath-1:
|
RecentlyUsedScenePath-1:
|
||||||
|
<<<<<<< HEAD
|
||||||
|
value: 22424703114646680e0b0227036c78111b1258192f2d28353e662a32f6e52678cee220eceb742a323016f6
|
||||||
|
flags: 0
|
||||||
|
RecentlyUsedScenePath-2:
|
||||||
|
value: 22424703114646680e0b0227036c78111b1258192f2d28353e663932f0eb7414e7f133e5a92f31352d1b
|
||||||
|
flags: 0
|
||||||
|
RecentlyUsedScenePath-3:
|
||||||
|
value: 22424703114646680e0b0227036c78111b1258192f2d28353e662e23e7e53078cee220eceb742a323016f6
|
||||||
|
flags: 0
|
||||||
|
RecentlyUsedScenePath-4:
|
||||||
|
value: 22424703114646680e0b0227036c7c0219001c396c1c23233967083debf42d
|
||||||
|
flags: 0
|
||||||
|
RecentlyUsedScenePath-5:
|
||||||
|
value: 22424703114646680e0b0227036c78111b1258192f2d28353e663536ebe73c2cf1a71aecf13f33722c0ce6281d
|
||||||
|
=======
|
||||||
value: 22424703114646680e0b0227036c71091503173a242724392c67083debf42d
|
value: 22424703114646680e0b0227036c71091503173a242724392c67083debf42d
|
||||||
flags: 0
|
flags: 0
|
||||||
RecentlyUsedScenePath-2:
|
RecentlyUsedScenePath-2:
|
||||||
@@ -25,6 +40,7 @@ EditorUserSettings:
|
|||||||
flags: 0
|
flags: 0
|
||||||
RecentlyUsedScenePath-6:
|
RecentlyUsedScenePath-6:
|
||||||
value: 22424703114646680e0b0227036c78111b1258192f2d28353e662f36e3ec740fedf53aeda92f31352d1b
|
value: 22424703114646680e0b0227036c78111b1258192f2d28353e662f36e3ec740fedf53aeda92f31352d1b
|
||||||
|
>>>>>>> origin/main
|
||||||
flags: 0
|
flags: 0
|
||||||
vcSharedLogLevel:
|
vcSharedLogLevel:
|
||||||
value: 0d5e400f0650
|
value: 0d5e400f0650
|
||||||
|
|||||||
Reference in new issue
Block a user