I wanted y'all to know I noticed there is already tilemap forums already open, but I wanted to make a new one so I can (hopefully) get help quicker, as some posts are old and probably no one looks at them anymore. I posted this in a forum about TilemapE.

As I stated I use TilemapE, a tilemap editor. It's useful but I can never get the tilemap to draw correctly. I am attempting a 2D Minecraft, and I tried making a full 172 by 172 world, a 16 by 16 world and so forth. I want to make it big but also small enough to save some archive, since I always archive all appvars and programs so a ram reset won't erase my programs. Can someone help? I can live with a 100 by 100 world, I want 62 blocks (I will start with grass, dirt, stone, and bedrock, then later ores and other stuff). I need help using LoadData() and DefineTilemap() in ice.
Step 1: Don't use TilemapE. That's not what it was made for. Read the ICE documentation on how to properly create tilemaps and use the tools correctly. There's an example as well.
MateoConLechuga wrote:
Step 1: Don't use TilemapE. That's not what it was made for. Read the ICE documentation on how to properly create tilemaps and use the tools correctly. There's an example as well.


I did indeed do this. I have The Worlds Hardest Game on my CE from Ice Compiler. The problem is I have a Macbook, owned by my school system, so I cannot install or run commands, and the macbook is limited. I can get TI Connect CE. So maybe is it possible to make an on-calc Tilemap editor, in basically the same way a computer would convert one? Thank you Mateo for the help!
TileMapE is best used for making sprite sets at this current time.
To export a sprite set, press [del] when editing a sprite. It will prompt for a file name. This will export all of the sprites into an appvar for easy use.
To access the sprite set:

Code:

Open(APPVAR,"r"->D
GetDataPtr(D->PTR
Close(D
NSPRITES*3->N
Alloc(N->SPRITES
0->A
Repeat A=N
PTR->{SPRITES+A
PTR+SPRITESIZE->PTR
A+3->A
End

Where SPRITESIZE is the number of bytes per sprite (Xsize*Ysize+2)
and NSPRITES is the number of sprites that you have in the file.
APPVAR is the name of the appvar which was exported form TileMapE
SPRITES points to an array of pointers, and each of those pointers point to the sprites in the sprite appvar.

To access an individual sprite:

Code:

{SPRITES+N*3

This will point to the sprite in the appvar, and can be used with any of the sprite displaying commands.
Where N is the sprite number.



Side note to Mateo:
If this isn't the structure that a tilemap uses to store its sprites, then BY ALL MEANS correct me.
Also, I have gotten tilemaps to work, WITHOUT the "DefineTilemap(" command Wink so I think I know what I'm doing.
beckadamtheinventor wrote:
TileMapE is best used for making sprite sets at this current time.
To export a sprite set, press [del] when editing a sprite. It will prompt for a file name. This will export all of the sprites into an appvar for easy use.
To access the sprite set:

Code:

Open(APPVAR,"r"->D
GetDataPtr(D->PTR
Close(D
NSPRITES*3->N
Alloc(N->SPRITES
0->A
Repeat A=N
PTR->{SPRITES+A
PTR+SPRITESIZE->PTR
A+3->A
End

Where SPRITESIZE is the number of bytes per sprite (Xsize*Ysize+2)
and NSPRITES is the number of sprites that you have in the file.
APPVAR is the name of the appvar which was exported form TileMapE
SPRITES points to an array of pointers, and each of those pointers point to the sprites in the sprite appvar.

To access an individual sprite:

Code:

{SPRITES+N*3

This will point to the sprite in the appvar, and can be used with any of the sprite displaying commands.
Where N is the sprite number.



Side note to Mateo:
If this isn't the structure that a tilemap uses to store its sprites, then BY ALL MEANS correct me.
Also, I have gotten tilemaps to work, WITHOUT the "DefineTilemap(" command Wink so I think I know what I'm doing.



I forgot to check on this until now. I wanted to thank y'all both for the help!! Just a little help would suffice and that's what I got so thank y'all
And if you were able to get tilemaps to work, how can I do it using the program TilemapE if thats what you did on my CE?
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement