adding image in runtime to a supertile

Post here your questions about the OpenSpace 2.x or notify bugs and suggestions.

Moderators: Lapo, Bax

kuzniz
Posts: 19
Joined: 05 Jan 2012, 07:21

adding image in runtime to a supertile

Postby kuzniz » 19 Oct 2012, 21:17

Hi,

I aould like to add in runtime an image for a supertile placed on the map, what approch to take ?

shachar
User avatar
Bax
Site Admin
Posts: 4609
Joined: 29 Mar 2005, 09:50
Location: Italy
Contact:

Re: adding image in runtime to a supertile

Postby Bax » 22 Oct 2012, 07:55

I think the tile should already contain the image, as an hidden skin. Then you could have a method on the skin's class to make it visible when needed.

Otherwise you have to add an empty skin with a name to a tile, then use the Tile.getSkinByName method to access it and add the new image to it dynamically.
Paolo Bax
The SmartFoxServer Team

Return to “OpenSpace v2 discussions and help”

Who is online

Users browsing this forum: No registered users and 22 guests