Page 1 of 1

I've asked this before but this is more advanced - Map makin

PostPosted: Wed Mar 31, 2010 12:20 pm
by Hblade
Alright, I'm here again with yet another question :P. I think I ask more questions then a walrus wonders why it lives in the water but breathes air.

Alright, now for the question. How can I use a tool that can make maps, (got that part... I think), but how can I like, say if I made a map... with dimensions with that of uh.... 64 tiles width, and 56 tiles high, how could I prevent the view from leaving the max, and minimum map width / height, also, how would I load a new map without having to use the moveto function?

If I could do this it'd make game making that much easier, and that less stressfull.

My next question is, how the heck can I get my tile editor to not place another tile of the same layer on top of each other, for example, I have the ground... Okay, I plant the ground. I click again, and theres another ground on the same layer, or say I have an edge, or a rock, and I place it on layer 1, instead of deleting the ground under it, it plants it over that. I want to only be able to plant things on layer 1 if I'm on layer 2, or 3. Sorta like how RPG maker works.

Sound hard? If you can help me I'll credit :D Since I'm not making any profit from the games I make, I can't really award you with any cash, so uh, you'll just be rewarded with a point I guess :P.

Re: I've asked this before but this is more advanced - Map m

PostPosted: Wed Mar 31, 2010 11:46 pm
by skydereign
For view control, you already know the tile width, so you know the dimensions. Using this you can prevent the view from passing it, from either your player, view actor, or whatever controls the views movements... Maybe I don't get what you are asking as in the actual screen movement you would just use the dimensions.

The other question depends on how you are setting it up, mainly the layers. If it is a 3d array, then you would have a variable determining which layer you are currently on, so when you click, it uses that to place the tile. Before it does that it would check if that sub of the array has a value already, if it does you would either have it replace it or not place the current tile.

Re: I've asked this before but this is more advanced - Map m

PostPosted: Thu Apr 01, 2010 12:11 am
by Hblade
Thanks, Sky, but I made my question wrong I guess. I understand how to do it, but what I dont understand is how to do it, you know what I mean? I know the concept, but I dont know anything on how to code it.

Re: I've asked this before but this is more advanced - Map m

PostPosted: Thu Apr 01, 2010 3:00 pm
by Bee-Ant
What if you just post your current demo or email us, we can fix them faster than post the code one by one here...

Re: I've asked this before but this is more advanced - Map m

PostPosted: Thu Apr 01, 2010 4:20 pm
by Hblade
Well my files got wiped... so screw it :P