Jump to content

Simple Cutscene between levels


spawn_more_overlords
 Share

Recommended Posts

Hey guys,

im working on a 2D platformer with linear level structure. Between some levels i want to make a cutscene which consists of a background and a single sprite thats moving from left to right. Everything else like my HUD or character should disappear during that cutscene.

In my case its just a plane thats flying through the screen. Once the plane has passed the next level should start.

Can someone tell me whats the best way to achieve that.

Thanks in advance!

Link to comment
Share on other sites

Thank you, i think i understand how the states work.

However i ran into another problem:

In the example code, functions are generally written in this format: update: function update ()

In my current gamestate code which i mostly have from a tutorial, functions are written like this: PlayState.update= function ()

I dont know if these functions are working differently but when i go from menuState to my PlayState im running into several errors claiming variables cant be found/ are undefined.

 

EDIT: fixed it now -> I forgot to parse some data from one state to another, the functions were working fine.

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...