Browse Source

Final Push

develop
Joshua Reason 3 years ago
parent
commit
9f5508f550
6 changed files with 19 additions and 11 deletions
  1. BIN
      Assets/Scenes/CreditScreen.unity
  2. BIN
      Assets/Scenes/MainGameplayScene.unity
  3. +3
    -3
      Assets/Scripts/Behaviours/YeetController.cs
  4. +8
    -0
      Assets/Scripts/UI/CreditScreen/CreditUIController.cs
  5. BIN
      ProjectSettings/EditorBuildSettings.asset
  6. BIN
      ProjectSettings/ProjectSettings.asset

BIN
Assets/Scenes/CreditScreen.unity (Stored with Git LFS) View File

size 50920

BIN
Assets/Scenes/MainGameplayScene.unity (Stored with Git LFS) View File

size 729828

+ 3
- 3
Assets/Scripts/Behaviours/YeetController.cs View File

@ -34,7 +34,7 @@ public class YeetController : InputBehaviour
private LineRenderer m_lineRenderer; private LineRenderer m_lineRenderer;
private AudioSource m_audioSource; private AudioSource m_audioSource;
private Transform m_OldChildParent;
private Transform m_SpawnerTransform;
private Vector3 preyeetPosition; private Vector3 preyeetPosition;
@ -46,6 +46,7 @@ public class YeetController : InputBehaviour
m_body = this.gameObject; m_body = this.gameObject;
m_audioSource = gameObject.AddComponent<AudioSource>(); m_audioSource = gameObject.AddComponent<AudioSource>();
m_audioSource.spatialBlend = 0f; m_audioSource.spatialBlend = 0f;
m_SpawnerTransform = FindObjectOfType<spawner>().transform;
} }
public void Hold(GameObject child) public void Hold(GameObject child)
@ -53,7 +54,6 @@ public class YeetController : InputBehaviour
m_audioSource.clip = childClips[Random.Range(0, childClips.Length)]; m_audioSource.clip = childClips[Random.Range(0, childClips.Length)];
_child = child; _child = child;
m_OldChildParent = _child.transform.parent;
_child.transform.parent = parent.transform; _child.transform.parent = parent.transform;
_child.GetComponent<YeetHandle>().held = true; _child.GetComponent<YeetHandle>().held = true;
_child.GetComponent<YeetHandle>().lastHeld = parent; _child.GetComponent<YeetHandle>().lastHeld = parent;
@ -86,7 +86,7 @@ public class YeetController : InputBehaviour
m_YeetAnimator.SetBool("Yeet", false); m_YeetAnimator.SetBool("Yeet", false);
m_YeetAnimator.SetBool("Carry", false); m_YeetAnimator.SetBool("Carry", false);
_child.transform.parent = m_OldChildParent;
_child.transform.parent = m_SpawnerTransform;
_child.transform.rotation = parent.transform.rotation; _child.transform.rotation = parent.transform.rotation;
_child.GetComponent<YeetHandle>().held = false; _child.GetComponent<YeetHandle>().held = false;

+ 8
- 0
Assets/Scripts/UI/CreditScreen/CreditUIController.cs View File

@ -29,6 +29,9 @@ public class CreditUIController : MonoBehaviour
[SerializeField] [SerializeField]
public List<CreditData> m_Credits; public List<CreditData> m_Credits;
[SerializeField,NaughtyAttributes.Scene]
public string m_MainMenuScene;
private int Count; private int Count;
@ -115,6 +118,11 @@ public class CreditUIController : MonoBehaviour
newPlayer.SetActive(true); newPlayer.SetActive(true);
} }
public void OnMenuClick()
{
UnityEngine.SceneManagement.SceneManager.LoadScene(m_MainMenuScene);
}
[System.Serializable] [System.Serializable]
public struct CreditReferences public struct CreditReferences
{ {

BIN
ProjectSettings/EditorBuildSettings.asset (Stored with Git LFS) View File

size 661

BIN
ProjectSettings/ProjectSettings.asset (Stored with Git LFS) View File

size 19727

Loading…
Cancel
Save