Jump to content

  • Log In with Google      Sign In   
  • Create Account


Map editor


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
6 replies to this topic

#1 Mast3r67   Members   -  Reputation: 104

Like
0Likes
Like

Posted 16 August 2011 - 08:25 AM

Hey. Not sure if this would be the best place to post this but anyway. I'd like to know if I can export map/txt files using Mappy or any other map editor that will look like this.

Example:

3 Tiles clips from a image.png coresponding to a number:

tile_1 = 1;
tile_2 = 2;
tile_3 = 3;

And the text file will look like this, every number coresponding to the respective tile.
1 1 1 2 2 2
2 3 1 2 2 2
3 3 2 2 2 2

I can do this in notepad but it takes a lot and also mistakes can be made pretty easy.

Sponsor:

#2 szecs   Members   -  Reputation: 2095

Like
0Likes
Like

Posted 16 August 2011 - 08:30 AM

How about Excell? Then copy/paste into Notepad?

#3 Mast3r67   Members   -  Reputation: 104

Like
0Likes
Like

Posted 16 August 2011 - 08:36 AM

How about Excell? Then copy/paste into Notepad?



In mappy you can load the tiles images, and place pictures on the screen. You don't type numbers, you just place the pictures you want to create the level. But I'm not sure how I can export that in the format that I want.

#4 szecs   Members   -  Reputation: 2095

Like
1Likes
Like

Posted 16 August 2011 - 08:40 AM

I mentioned Excell because you can easily copy data and you can copy/paste in a format like
1	1	1	1
1	1	1	1
1	1	1	1
1	1	1	1
1	1	1	1
1	1	1	1
1	1	1	1
1	1	1	1
1	1	1	1
1	1	1	1
(tabs between the numbers).

When I was about 12, I made a whole heightmap with Excell (256x256 if I recall correctly)

#5 0Circle0   Members   -  Reputation: 342

Like
2Likes
Like

Posted 16 August 2011 - 12:54 PM

I use mappy all the time, makes making maps really easy. Once you export as text if you want that format where it is just the numbers just open with notepad remove the initial
const short tt_map0[100][100] =
then find/replace all "{" with "" and "}" with "" and "," with "" and ";" with ""
that will give you this look
 73 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 
74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 
74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 
74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 
74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 
74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 
74 74 74 75 
 79 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 80 
 79 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 80 
spaces between each, though I would keep the "," so you can easily signify a new tile, you can also post it directly into your source when you first export as text with minimal changes, which is the preferred way.

Sprite Creator 3 VX & XP

WARNING: I edit my posts constantly.


#6 Mast3r67   Members   -  Reputation: 104

Like
0Likes
Like

Posted 17 August 2011 - 12:34 AM

I use mappy all the time, makes making maps really easy. Once you export as text if you want that format where it is just the numbers just open with notepad remove the initial

const short tt_map0[100][100] =
then find/replace all "{" with "" and "}" with "" and "," with "" and ";" with ""
that will give you this look
 73 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 
74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 
74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 
74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 
74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 
74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 
74 74 74 75 
 79 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 80 
 79 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
1 1 1 80 
spaces between each, though I would keep the "," so you can easily signify a new tile, you can also post it directly into your source when you first export as text with minimal changes, which is the preferred way.



Where do you specify the number of each tile?

#7 0Circle0   Members   -  Reputation: 342

Like
1Likes
Like

Posted 17 August 2011 - 05:28 AM

Where do you specify the number of each tile?


That is done automatically with mappy. First tile on the tile sheet at (0, 0) = Tile 1. (0, 1) = Tile 2. And so on down the sheet. With mappy you can even remove unused tiles to make the tile sheet smaller in size, or join more than one tile sheet(assuming they are the same size tiles) together and export as a single big image. Mappy also has collision code that you can export, trigger code as well. Lots of stuff. I think mappy has header files for SDL. I know it does for allegro cause I use mappy all the time with allegro. I have to do some minor editing for it to work with java and there isn't a native library like for C/C++ but even then it works well.

Sprite Creator 3 VX & XP

WARNING: I edit my posts constantly.





Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS