Author Topic: [Solved] Problem with redrawing a Level  (Read 1553 times)

Liaf

  • Member
  • **
  • Posts: 19
  • Karma: +0/-0
  • yay!
    • View Profile
[Solved] Problem with redrawing a Level
« on: Wed, Feb 17, 2010 »
After redrawing a Level, my player is behind my Level. Of Course I know why this happens, but I don't know how to redraw my Player to get him back on Front.
I'm using the newest flixel version, so all these tutorials about FlxLayers (I think this got something to do with my problem) are really useless.
« Last Edit: Wed, Feb 17, 2010 by Liaf »

Matoking

  • Member
  • **
  • Posts: 57
  • Karma: +0/-0
    • View Profile
Re: Problem with redrawing a Level
« Reply #1 on: Wed, Feb 17, 2010 »
I'm a noob, but I think it should be fixed by calling render() on player before HUD but after everything else.

Liaf

  • Member
  • **
  • Posts: 19
  • Karma: +0/-0
  • yay!
    • View Profile
Re: Problem with redrawing a Level
« Reply #2 on: Wed, Feb 17, 2010 »
Tried that out right now, but unfortunately it didn't work  :-\

Matoking

  • Member
  • **
  • Posts: 57
  • Karma: +0/-0
    • View Profile
Re: Problem with redrawing a Level
« Reply #3 on: Wed, Feb 17, 2010 »
What does the code look like?

JAH2488

  • Guest
Re: Problem with redrawing a Level
« Reply #4 on: Wed, Feb 17, 2010 »
After redrawing a Level, my player is behind my Level. Of Course I know why this happens, but I don't know how to redraw my Player to get him back on Front.
I'm using the newest flixel version, so all these tutorials about FlxLayers (I think this got something to do with my problem) are really useless.

FlxLayers simply need to be changed FlxGroups and make sure they are added to the stage in the right order. Thats all the advice i can give.

Liaf

  • Member
  • **
  • Posts: 19
  • Karma: +0/-0
  • yay!
    • View Profile
Re: Problem with redrawing a Level
« Reply #5 on: Wed, Feb 17, 2010 »
FlxLayers simply need to be changed FlxGroups and make sure they are added to the stage in the right order. Thats all the advice i can give.
Thanks for the help, I didn't know you could add the FlxGroups in the right order and change them afterwards to have all your stuff in the right order.