Jump to content

Board component best option


adicirstei
 Share

Recommended Posts

I need to create a board for a match three type game. The board is comprised of tiles and a border. The board shape is not always a rectangle. 

 

The user do not interact with it in any way. It just need to stay behind.

 

What is the best option memory wise to create it?

 

 

1 a group of sprites / images

2 a BitmapData object on which I draw the images

3 any other solution?

 

Thanks!

Link to comment
Share on other sites

Ah... you can create a group (game.add.group) and then draw a bunch of tiles into it.

var pGroup = game.add.group();pGroup.create(0, 0, "myTiles", 32);pGroup.create(40, 0, "myTiles", 30);// etc

When you need a new level just pGroup.destroy(true);

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

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