change: Finished MushroomVillage
This includes changes such as putting enemies in levels, adding projectiles, and finalizing the bounces for the moving platforms The cymbal has been implemented, and provides a short immunity to projectiles Every section is playable, and includes a final ending object, although there is no transistion to the level from the previous level yet
This commit is contained in:
@@ -10,21 +10,26 @@ public class GameUIController : MonoBehaviour
|
||||
public GameObject trumpetBackground;
|
||||
public GameObject tambourineBackground;
|
||||
public GameObject clarinetBackground;
|
||||
public GameObject cymbalBackground;
|
||||
[HideInInspector] public GameObject trumpetUI;
|
||||
[HideInInspector] public GameObject tambourineUI;
|
||||
[HideInInspector] public GameObject clarinetUI;
|
||||
[HideInInspector] public GameObject cymbalUI;
|
||||
|
||||
void Awake()
|
||||
{
|
||||
this.trumpetUI = trumpetBackground.transform.GetChild(0).gameObject;
|
||||
this.tambourineUI = tambourineBackground.transform.GetChild(0).gameObject;
|
||||
this.clarinetUI = clarinetBackground.transform.GetChild(0).gameObject;
|
||||
this.cymbalUI = this.cymbalBackground.transform.GetChild(0).gameObject;
|
||||
}
|
||||
|
||||
void Start() {
|
||||
void Start()
|
||||
{
|
||||
this.trumpetBackground.SetActive(StateController.Instance.HasTrumpet());
|
||||
this.tambourineBackground.SetActive(StateController.Instance.HasTambourine());
|
||||
this.clarinetBackground.SetActive(StateController.Instance.HasClarinet());
|
||||
this.cymbalBackground.SetActive(StateController.Instance.HasCymbal());
|
||||
}
|
||||
|
||||
public void ToggleTrumpet(bool toggleState)
|
||||
@@ -54,10 +59,20 @@ public class GameUIController : MonoBehaviour
|
||||
}
|
||||
}
|
||||
|
||||
public void ToggleCymbal(bool desiredState)
|
||||
{
|
||||
bool curEnabled = clarinetUI.GetComponent<Image>().enabled;
|
||||
if (curEnabled != desiredState)
|
||||
{
|
||||
cymbalUI.GetComponent<Image>().enabled = desiredState;
|
||||
}
|
||||
}
|
||||
|
||||
public void UpdateInstrumentUI()
|
||||
{
|
||||
this.ToggleTrumpet(StateController.Instance.HasTrumpet());
|
||||
this.ToggleTambourine(StateController.Instance.HasTambourine());
|
||||
this.ToggleClarinet(StateController.Instance.HasClarinet());
|
||||
this.ToggleCymbal(StateController.Instance.HasCymbal());
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user