Enemy Logik erstellt Weitere Kommentare: Ich werde herausfinden, wer Coroutinen erfunden hat und diese Person auf dieselbe Art knechten, wie ich es in den letzten 5 Stunden wurde. WaitForSeconds(5) aber alles 4000 Mal in 3 Sekunden durchlaufen, mein Arsch.

This commit is contained in:
2026-02-17 00:23:17 +01:00
parent 0b781ccb0f
commit 8b0452b1ed
32 changed files with 4665 additions and 2685 deletions

View File

@@ -26,17 +26,20 @@ public class GameOver : MonoBehaviour
[Header("ScriptPile")]
[SerializeField] GameObject scriptPile;
[SerializeField] GameObject eFie;
InventoryScript inventory;
ChangeHealth healthScript;
HandleEnergy battery;
FieScript fie;
private void Awake()
{
inventory = scriptPile.GetComponent<InventoryScript>();
healthScript = scriptPile.GetComponent<ChangeHealth>();
battery = scriptPile.GetComponent<HandleEnergy>();
fie = eFie.GetComponent<FieScript>();
}
void Start()
@@ -62,10 +65,12 @@ public class GameOver : MonoBehaviour
public void ShowDeathScreen()
{
fie.StopAllCoroutines();
//Time.timeScale = 0;
timerOn = true;
timer = 10f;
deathPanel.SetActive(true);
LeanTween.scale(deathPanel, transform.localScale * 0.5f, duration * Time.deltaTime).setDelay(.1f).setEase(LeanTweenType.easeOutBounce);
SpeakEnemy();
costText.text = cost.ToString(); //ZUM DEBUGGEN
CheckDeathTime();
@@ -107,11 +112,13 @@ public class GameOver : MonoBehaviour
inventory.Energy += battery.addEnergyValue;
}
LeanTween.scale(deathPanel, transform.localScale * 0f, duration * Time.deltaTime).setDelay(.1f).setEase(LeanTweenType.easeOutBounce);
deathPanel.SetActive(false);
//Time.timeScale = 1;
//Logik: bei Retry, soll der Player nochmal neue Energie bekommen
fie.StartStuff();
}
public void CheckDeathTime()
@@ -136,17 +143,25 @@ public class GameOver : MonoBehaviour
public void CalculateCost()
{
cost = healthScript.deathCounter * 100;
if (cost == 300)
{
infoText.text = "You must really like being here.";
}
if (cost >= 1000)
{
cost = 900;
infoText.text = "But you refused.";
}
}
public bool fieKill;
public bool silvKill;
public bool haiKill;
public void SpeakEnemy()
{
if (fieKill)
if (fie.fieKill)
{
infoText.text = "HAAHAHAHAHAAHAHAHAHAHAHAHAHA";
}