Jump to content

Creating & Switch Tilemaps dynamically


sharks
 Share

Recommended Posts

Hi guys,

I've worked on a part of the system which loads multiple layers for a given tile map for a key "Map A" (All of them are static). Now at some time, I'd like to move the user to the next map with key "Map B". What's the best way to destroy a tilemap/layers and recreate the world?

 

Thanks,

S

Link to comment
Share on other sites

From what I can tell Phaser seems to handle cleanup pretty well as I have run into a lot of errors whenever I have tried to manually destroy objects in the shutdown method of the secene. I've been leaving the objects in place for now as I'll worry about memory management later on when I get closer to completion. I've been working on a template some time now that might be of help. It's a work in progress but it handles loading tilemaps dynamically as you have mentioned:

 

Phaser 3 Tilemap & File Pack Project Template

Link to comment
Share on other sites

  • 2 years later...

Hey guys, I'm making an partly open world rpg game similar to the original pokemon games. I want to know how to switch between tilemaps just by walking to a certain point on the map. For example: I want to get to the next city and i need to walk along a path; when i get to the end of the path for that tilemap i want to go to the next tilemap which will be the city. Does anyone know how i would do that?

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

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