Revamp stuff (no one else is reading this it's fine)

This commit is contained in:
2022-08-19 21:31:55 -07:00
parent 82fe821806
commit ab8a11c7bf
35 changed files with 2566 additions and 1422 deletions

View File

@@ -0,0 +1,23 @@
using UnityEngine;
namespace Scampz.GameJam.Assets.Scripts.SceneManagement
{
public class TeleportPlayer : MonoBehaviour
{
[SerializeField]
private Transform _spawnPoint;
private void OnTriggerEnter(Collider collider)
{
if (collider.CompareTag("Player"))
{
var player = GameObject.FindGameObjectWithTag("Player");
var cc = player.GetComponent<CharacterController>();
cc.enabled = false;
player.transform.position = _spawnPoint.position;
player.transform.rotation = _spawnPoint.rotation;
cc.enabled = true;
}
}
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: ce44efba2e7898048a76f03b184fd342
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant: