Forum begins after the advertisement:


[Part 6] Spikes cause game crash error

Home Forums Video Game Tutorial Series Creating a Metroidvania in Unity [Part 6] Spikes cause game crash error

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #14482
    Ethan
    Level 4
    Participant
    Helpful?
    Up
    0
    ::

    I currently have an issue when standing on the spikes causing my game to stop running is there a way to get around this ? let me know if i have to submit any code or videos

    #14483
    Ethan
    Level 4
    Participant
    Helpful?
    Up
    0
    ::

    Ive done some more testing and when i make the spikes instantly kill my player there are no issuses it only seems to be when i want my player to not be one hit by them that it causes a crash

    #14489
    Joseph Tang
    Level 13
    Moderator
    Helpful?
    Up
    0
    ::

    For spikes causing the game to freeze, this is caused by “IEnumerator RespawnPoint()” in Spikes.cs scaling time to 0 and using “WaitForSeconds”. Simply, change all “WaitForSeconds” codes in Spikes.cs to “WaitForSecondsRealTime”. This allows the enumerator to continue as intended while in stopped time without freezing the game.

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.

Go to Login Page →


Advertisement below: