Forum begins after the advertisement:


[Part 5] A dark screen error and another error.

Home Forums Video Game Tutorial Series Creating a Metroidvania in Unity [Part 5] A dark screen error and another error.

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #14691

    Greetings to you. Such a problem: when moving to a new level, the dark screen does not disappear, and another error in the console periodically pops up. If necessary, I can drop the scripts. https://imgur.com/a/9Knwtor

    #14692
    Joseph Tang
    Moderator

    What you should do is remove any other instances of your singletons in other scenes: Player, Canvas, GameManager. From the looks of it, you have a duplicate canvas in your “Cave_2”. Perhaps that could be the reason behind your black screen?

    #14693

    Thanks, everything has been fixed, but there is another small problem: after moving to a new scene, the character flashes all the time as if he is taking damage, how can this be fixed?

    #14694
    Joseph Tang
    Moderator

    This is because of a new line i added on SceneTransition.cs to stop the player from taking damage while in scene transition, it turns on the playerstate invincible when triggered.

    To stop this, go to your playercontroller.cs FlashWhileinvincible method and add the parameter !cutscene to the if statement to stop flashing if the player is in cutscene state.

    I’ll have to re edit the scripts in the series to add this in since I didn’t realize it then.

    #14697
    Joseph Tang
    Moderator

    Update: I’ve recently updated the Article and the bug forum post about the transition invincibility issue, and should now have a working code.

    Metroidvania Part 5 Article

    Part 5 Bugfixing Forum post

    #14704

    Thanks, everything is working correctly now.

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

Go to Login Page →


Advertisement below: