Problem description: By using the TweakPNG program, you can assign the zTXt chunk to be able to easily splice up a PNG file. By doing this, it appears to arrange the sprites in a vertical arrangement. (Rows -> Columns) Many sprite animation programs arrange the sprites in a horizontal arrangement and don't allow for vertical arrangement; is there any way to change the way my DM arranges sprites? |
Oct 11 2016, 2:07 pm
|
|
DM uses reading order; it goes by a horizontal arrangement. It starts on the top row and moves left to right, then the next row down from left to right, and so on.
|
In response to Lummox JR
|
|
For frames/dirs, does it extend down a row?
|
It should just continue going in order. An icon state with 3 frames and 4 dirs will take up 12 sprites in the image.
When an icon has both dirs and frames, the dirs for the first frame come first, then dirs for the second frame, etc. The order of the dirs is, from dmg.h: typedef enum { In the future (or better yet in the past) I would very much prefer a more streamlined form that recognized repeat images, and could therefore save memory. The problem at this point is the compatibility divide. |
In the PNG format, this is the way the sprites are arranged, in reading order:
When formatted directly into BYOND, this is the way dream maker reads it with the parameters state = "walk" It shows the DM is not rendering the sprites in reading format like you previously said. However, it appears this only happens with frames. When another state is declared, it goes back to reading order and then switches back to vertical reading. |
But that's exactly what I said. The dirs for the first frame are read first, then the next frame's dirs, and so on.
For a 4x4 icon state, the icons are read in this order: Frame 1, south Frame 1, north Frame 1, east Frame 1, west Frame 2, south Frame 2, north Frame 2, east Frame 2, west Frame 3, south Frame 3, north Frame 3, east Frame 3, west Frame 4, south Frame 4, north Frame 4, east Frame 4, west That's why you're seeing those results. |
So returning to my original question, is there any way to change the way my DM arranges sprites?
|
Konlet wrote:
So returning to my original question, is there any way to change the way my DM arranges sprites? No. The order is implicit to the format. |
In response to Ter13
|
|
Alright, thanks for the info however Lummox.
|