Jump to content

Dynamic Tilemap


StefanWeck
 Share

Recommended Posts

Hey everyone!

 

Recently i have created an Random Dungeon Generator ( https://github.com/stefanweck/dungeongeneration ), and i'm porting it to a plugin for Phaser. The only problem i encounter is loading my custom map in the game!

I've tryed preloading an "empty" ( just dummy data, 0's etc ) json file, setting that as my tilemap and change it. 

I've tryed creating an empty tilemap and fill it with my data. Even tried to generate my output the same as the example json tilemap files, but that's a big pile of work.

 

Is there any solution for doing this? Is there an example where someone creates an empty tilemap object and fills it with data?

The examples on the Phaser website only load pre-defined maps as .json files.

 

Thanks in advance!

 

Stefan

Link to comment
Share on other sites

  • 4 weeks later...

Maybe you can load a default file and change it when you need.

A little like for displaying sprite, you can display a sprite but when you need it change the image that goes in this sprite.

Or for the frame of a sprite, you can change it when displaying.

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

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