Omnimaga

Calculator Community => Other Calc-Related Projects and Ideas => TI Z80 => Topic started by: meishe91 on March 20, 2010, 12:15:57 am

Title: Map Converter
Post by: meishe91 on March 20, 2010, 12:15:57 am
Hello Omnimaga Community,

I have spent the past couple of weeks working on six seperate programs that will make converting maps easy/easier than before (hopefully). This program gives you the options for both going to a string and going from a string:
To String:
-String►Matrix
-String►List
-String►Pic
From String:
-Matrix►String
-List►String
-Pic►String
With just a couple runs of the program you can easily convert from one data type to another.

What I have done is tried to make this as user friendly as possible. Though currently it will only do two character maps (meaning you can only have to types of characters on the map (usually a wall and a walking area)). Hopefully I can figure out a good way to include more but ya, until then it is only two. I also hope to add a feature that allows you to choose the numbers for your list/matrix (currently walls are represented as "0" and spaces as "1").

I hope someone finds this useful in it's current state.

For use:
W - Width of the map.
H - Height of the map.
Spaces: - What your floor/walkable character is.
Choose a Wall: - Choose what you want your wall character to be (a.k.a. the character you wouldn't be able to move through in the game).
Title: Re: Map Converter
Post by: trevmeister66 on March 20, 2010, 12:19:40 am
Mmm I think Calculator Projects and Ideas would be a better location, so maybe a mod or DJ can move it when they see this, unless this is the correct location, then I apologize.

To show a screenie, you will have to upload it to a file hosting site (preferably video file hosting) and then copy the link and put it in your post.
Title: Re: Map Converter
Post by: meishe91 on March 20, 2010, 12:23:28 am
Well I considered that area but I didn't really consider this a project that would really go there. I could be wrong though.

And ya, that's what I figured, but the file kept uploading wrong onto photobucket so I could try a different hosting site (any suggestions?).

Edit: Thanks for moving this, Eeems! :)
Title: Re: Map Converter
Post by: DJ Omnimaga on March 20, 2010, 12:33:08 am
Wow nice to see you're working on this :)

For uploading an image, click Reply, then below the text form, click "Additional Options" and it should reveal an upload form below. There you can upload many types of files.

Otherwise, Imageshack.us and Mediafire.com is a good option.

Btw how will any format > pic work?
Title: Re: Map Converter
Post by: meishe91 on March 20, 2010, 01:09:43 am
Wow nice to see you're working on this :)

For uploading an image, click Reply, then below the text form, click "Additional Options" and it should reveal an upload form below. There you can upload many types of files.

Otherwise, Imageshack.us and Mediafire.com is a good option.

Btw how will any format > pic work?

Ya, I kinda spaced just using a different thread :P, but I wanted it all together so I'll upload it with this one and then edit the first one when I get things figured out.

As for the string/matrix/list►pic thing. It only supports going from a string to pic right now. But if you run the program a couple of times you can get any map into a string and then use that string to convert to a pic. I'm not sure if I will make conversions for all data types to the others because that could get really big in file size. But if people don't mind that and want it I can make the other conversions.

Please give me feedback and suggestions of what you would like and such.

By the way, I'm aware I made mistakes in making the .gif file. I haven't used WabbitEmu long so that is why :P
Title: Re: Map Converter
Post by: DJ Omnimaga on March 20, 2010, 01:16:47 am
that's pretty nice, so for strings I assume you will eventually have to specify which character is the floor, right, so it knows which character will be a white pixel?
Title: Re: Map Converter
Post by: meishe91 on March 20, 2010, 01:18:42 am
That is what the section that says "Spaces:" is. You type in what your floor/walkable character is.

Edit: I modified the original post to show what each enterable section is for.
Title: Re: Map Converter
Post by: DJ Omnimaga on March 20, 2010, 02:05:26 am
aaah ok, didn't notice that part x.x
Title: Re: Map Converter
Post by: meishe91 on March 20, 2010, 02:08:56 am
It's fine, no worries :)
Title: Re: Map Converter
Post by: ztrumpet on March 20, 2010, 02:37:45 pm
Nice!  I'm glad you decided to release info on this! ;D
When are you going to release the programs?  Oh, and you added the ')'s to the For loops, right. :)
Title: Re: Map Converter
Post by: DJ Omnimaga on March 20, 2010, 02:45:27 pm
I hate that For() glitch x.x
Title: Re: Map Converter
Post by: meishe91 on March 20, 2010, 03:32:15 pm
Well I'm not sure if I will release all six individual programs. They are all in the CNVRT program that is in the first post though. And ya I did do that haha, thanks again for helping with that.
Title: Re: Map Converter
Post by: DJ Omnimaga on March 20, 2010, 11:22:17 pm
Seems like a good deal to me (providing the final version is not too massive with all 6 programs in one. Otherwise, I would suggest both a 1-file version and one with separate files, so people can keep the less used ones archived or delete them)
Title: Re: Map Converter
Post by: meishe91 on March 21, 2010, 12:08:34 am
Well with the name it is 1430 bytes. I don't know if that is to big or not :P
Title: Re: Map Converter
Post by: DJ Omnimaga on March 21, 2010, 12:16:18 am
Nope that's pretty small actually. I was more worried about something like 7-9 KB. I remember it was hectic to use Nitacku grayscale ditherer and Lolje map editor due to them taking too much RAM before. I had to archive/unarchive/garbage collect almost everytime I debugged/added stuff
Title: Re: Map Converter
Post by: meishe91 on March 21, 2010, 12:30:37 am
Ah ok, sweet. I have a poor sense of what is big and what isn't when it comes to program size :P Glad to hear its not to big :)
Title: Re: Map Converter
Post by: DJ Omnimaga on March 21, 2010, 12:46:12 am
It's generally a matter of opinion, altough it seems typical for dev tools like this that 6 KB is starting to get big to BASIC programmer eyes, since they have only 18 KB left for the rest and can't run their game with the editor unarchived
Title: Re: Map Converter
Post by: meishe91 on March 21, 2010, 12:48:41 am
Hmmm ok, good to know. Thanks :)
Title: Re: Map Converter
Post by: ztrumpet on March 21, 2010, 10:50:58 am
Ah, I missed the link at the top.  I found it (the program), and it works really well!  Awesome job meishe! :D

Oh, and meishe, nice sig.  I'm glad you found Eeems' banner. ;D
Title: Re: Map Converter
Post by: Builderboy on March 21, 2010, 11:29:23 am
Nice, this looks like it could be really useful ^^ I would recommend a single file program, but also let the user download any of the individual ones onto their calc to keep memory at a minimum.  For those developing games it might be worthwile to just have the single program needed for their type of maps.  But also include the full program for those messing with maps, or for those who just want to have the whole shebang on there at once ^^
Title: Re: Map Converter
Post by: meishe91 on March 21, 2010, 08:07:15 pm
Thanks Z :D Need to find a couple others or something. And glad ya like the program.

@Builderboy
Ya, I've been considering the individuals. I just need the time to get a .zip file set up and everything.

Glad people are enjoying this :)
Title: Re: Map Converter
Post by: DJ Omnimaga on March 21, 2010, 09:23:02 pm
I might add to the Calc RPG programming tools section of the site once it comes out, so it's easier for people to find (at least, besides ticalc.org)
Title: Re: Map Converter
Post by: meishe91 on March 22, 2010, 12:42:00 am
Ok, sounds good.
Title: Re: Map Converter
Post by: meishe91 on March 26, 2010, 07:06:53 pm
So, I hate double posting because I know it is annoying, just was trying to get some people's input and wasn't sure how else I could really (if there is a easier way to make this re-visable and such please tell me) but I would like some people's input on what they would like this to do. I just really need something to work on to get stuff off my mind so ya. Not sure what you guys wanna see as improvements.

(Could be more conversions, new features, anything.)
Title: Re: Map Converter
Post by: DJ Omnimaga on March 26, 2010, 07:48:37 pm
Oh there,s no problem with double posting with such time between posts ^^, check the new double-posting rule added on the forums a week ago:

Quote
3: The only time double-posting is allowed (posting two messages in a row in the same topic) is either if there has been 6 hours since your last post, 3 hours if your thread has been bumped out of the New Posts page, 1 hour if it's a project update or immediately if you need to upload more than 10 file attachments at once. Otherwise, update the last post using the "EDIT" button. It will be marked as unread for all members (altough it won't bump the thread).
Basically your double-post is not even close from breaking the rules :P (I think on UTI, you must delete your first post then repost a new one. On Cemetech you must wait 72 hours or so)

Never just edit your last post after over 12 hours, cuz sometimes the board is so active it will be missed, since it won,t bump the thread.

As for improvements, I am not sure really x.x. Does your converter supports multiple map sizes (including from pics)?

It would be also nice with pics if we could convert a certain part of a pic in particular to another format, for example, starting at X=5 Y=8 and finishing at X=29 Y=19, only converting this portion of the pic map. Was this added alerady?
Title: Re: Map Converter
Post by: meishe91 on March 26, 2010, 07:58:59 pm
Oh, well I just don't like it because it can get annoying if someone abused it so I avoid doing it :) But thanks for letting me know ;D

As for the first part of that, ya it suports 2x5, 46x6, 5837578x395948 (in theory), etc. You enter what the width and height of the map are. As long as you were accurate while entering it my program will be too :)

That second part, no it hasn't been added but I don't think it will really be to hard. I already have an idea of how to do it and its a really simple fix. I'll work on it after I eat and get a screenshot up after to see if that is what you mean.
Title: Re: Map Converter
Post by: DJ Omnimaga on March 26, 2010, 08:26:01 pm
WHAT?????? >9000x>9000???????????

jk but glad you have multiple map width support ^^
Title: Re: Map Converter
Post by: meishe91 on March 26, 2010, 08:43:24 pm
Haha ya, I'm working on the code now.
Title: Re: Map Converter
Post by: meishe91 on May 24, 2010, 04:20:03 pm
Updated the program for when your choosing a wall character that it uses the reordered tokens (http://ourl.ca/5906/91257;topicseen#new) I did. No other update was done, should probably do some though.
Title: Re: Map Converter
Post by: DJ Omnimaga on May 24, 2010, 04:30:47 pm
I should really include those in the archives one day...