I'd like to point out that just because it can already be done, doesn't mean that it's not a decent feature request. Most features can be duplicated in soft-code. In fact quite a few features came after somebody had done it in soft-code. Hence, workarounds. I've come across numerous libraries and demos of things that have since been implemented BYOND-side.

P.S. I'll make a better request and put up a demo for ya.
Features & Bug Fixes with no workarounds > Feature requests with workarounds
This technically doesn't have any soft code workarounds. The best you can do as a workaround is to edit the pixel_z of every single turf you want to stack after placing it in the map editor. If you have anything more than a few small rooms it makes mapping incredibly tedious and time consuming.
Bravo1 wrote:
This technically doesn't have any soft code workarounds. The best you can do as a workaround is to edit the pixel_z of every single turf you want to stack after placing it in the map editor. If you have anything more than a few small rooms it makes mapping incredibly tedious and time consuming.

To stack one z level on top of another, create objs on the first z level that represent the turfs on the second z level (make their icon, icon_state, layer, density, etc. all match) and set their pixel_z to 32. Then override the Enter proc to consider collisions with these objects only when the mob's elevation matches the obj's elevation.

This isn't difficult, CPU intensive, or much of a stretch of how BYOND works. Things like this are the reason why you can override Enter().
True, and mapping is almost complete absurdity because you have to generate an instance for each object for each z level.

EDIT: ^ What he said. ^
True, but the mapping of buildings, especially in isometric will become incredibly difficult as you'd be looking at a mass of ground level objects that will auto-adjust to their heights with New(). Either that or you'd have to create subtypes for each building block that matches the initial pixel_z requirement.

I don't think it's difficult at all to work around this, it's just that the only possible workarounds are either incredibly long-winded, requiring you to use up a ton of time which could be spent elsewhere, or would cause the map to look incredibly odd while you're building it.

It's not that a work around isn't possible, it's just that the viable workarounds aren't much better than the initial issue.
http://files.byondhome.com/Forumaccount/map-stacker.zip

You build each map on a separate z level then write some code to define how maps are stacked. You create an instance of the /MapStack object. It's constructor takes any number of arguments, the arguments are the z levels you want to stack (in the order they'll be stacked). Then call the object's stack() proc to generate the objs. A demo is included.

It has verbs to let you change elevation but there are no automatic ways to change elevation (ex: stairs). It also uses a very basic method to manage the showing and hiding of objects. These are both things that you could handle many different ways, but you have the whole DM language at your disposal.

I don't see any reason why the performance will be unacceptable or why you can't put another 30-60 minutes into it to have it ready to use in a game.
Status: Resolved
Thank you, but we have our alternative already planned out and it takes into account how things can more easily be mapped. What your alternative doesn't take into account is that, while it decreases the number steps it also makes it more difficult to view the actual map while editing, making the "library" moot.
A minute ago BYOND was way too slow to handle this and it absolutely had to be a built-in feature. Now we have two solutions. We're on a roll, what feature do you want to tackle next? :-)
It's not that byond can't handle it, it's the actual process of mapping that is slow and tedious without this feature, but we'll take the slow alternative route since it doesn't seem like were going to make any headway here.
I already told you that we had a system for it. The "solution" still doesn't account for mapping. Our solution is tedious but manageable. Your solution is easier but not so manageable.

I also did not say that BYOND was too slow to handle it. I said that BYOND was too slow to handle the other functions that go along with it. range_3D() is simple enough, but view_3D() is another story entirely. We are working to get around that limitation but we're finding that every different situation needs a different workaround instead of just using view_3D().
I'm not sure why mapping is such a problem. In the example I posted you make maps how you normally would and they're stacked at runtime. If you want to define a 30x30x3 block of turfs, you have to place 2700 turfs in the map editor. Placing 2700 turfs on the map is tedious but there's no way around it.

Hiro, I'm curious how your solution makes mapping easier. Care to explain?
Yes, but it's made more tedious by either having to either manually edit pixel_z or create new objects for each layer. Doing what you do which was proxies, or just having world/New() move everything from every other mapz and move it to the correct place on the the first map, either one is made difficult by not being able to see all of the layers at once. Either way, it's an issue.
I think the best way to make everyone happy is to just allow you to automatically set the pixel_z level when placing blocks so that we don't have to create new subtypes just for pixel_z offsets, or edit them as they're placed, or add some new system.

I'm also going to request a feature that supports rotating of the map during editing. (unless it's possible and I'm just unobservant in which case, sorry XD)
Forum_account wrote:
http://files.byondhome.com/Forumaccount/map-stacker.zip

Using pixel_z (more like pixel_y) seems like a bad choice for a flat game world, it may help simplify hit detection, but can cause some serious visual fails; like moving your character completely out of view (which could be accounted for with client.pixel_z, but that causes other problems). It will also cause o/view() related problems, and it would cause somewhat flunky movement behavior if you actually implemented it into gameplay elements like stairs or ladders. It also makes it difficult to get an accurate in-game view of the map from DM's map builder; Though, that's probably going to be the case with any non-built-in implementation.

Elevation based opacity doesn't work. Though, that's partially due to a BYOND bug with opacity on invisible objects.

Presumably, as seen in the original post here, you would want to be able to see the entire exterior of the building while outside.

Running your if(!turf) checks in stack_map() seems rather pointless. Those situations should always return a turf. Assuming you were attempting to prevent the game from pointlessly duplicating "empty" tiles, you would want to check the turf's type against the default. Though, that would skip any "floating" objects, without another minor change.

Also, you would probably want to do some kind of cleanup (location nulling for non-turfs) after duplicating the layers. Since having multiple copies of the same objects could pointlessly bog down multiple aspects of the game.
Forum_account wrote:
I'm not sure why mapping is such a problem. In the example I posted you make maps how you normally would and they're stacked at runtime. If you want to define a 30x30x3 block of turfs, you have to place 2700 turfs in the map editor. Placing 2700 turfs on the map is tedious but there's no way around it.

Hiro, I'm curious how your solution makes mapping easier. Care to explain?

This is the mapping method that I used for the examples I posted. However, this leaves all those Z levels completely empty in the end, which may eventually be a problem.
Kaiochao wrote:
Forum_account wrote:
I'm not sure why mapping is such a problem. In the example I posted you make maps how you normally would and they're stacked at runtime. If you want to define a 30x30x3 block of turfs, you have to place 2700 turfs in the map editor. Placing 2700 turfs on the map is tedious but there's no way around it.

Hiro, I'm curious how your solution makes mapping easier. Care to explain?

This is the mapping method that I used for the examples I posted. However, this leaves all those Z levels completely empty in the end, which may eventually be a problem.

You can make the maps on separate z levels, compress them into one z level at runtime, then save the result.

I guess it depends on the kind of environment you're making. If you have a generally 2D map with a few elevated platforms, I'd just deal with creating the map as one z level initially. If you have a lot of multi-floor buildings, it'd be easier to map them as separate z levels.
This is a really much needed feature but being able to see to other floors in the map editor but make something easy so you know your not adding/editing that floor(darkened out some) would be nice, and switching floors just brings stuff to the top not seeing whats above only below & that floor(below made darker)

This is how the map editor should work for this type & would be a really useful map type.
Bump.
Page: 1 2 3 4