Ambrosia Garden Archive
    • Sprite problem


      Their positions seem to be random

      Well, the pic illustrates my problem quite well. The sprites are identical in their size and layout, you can see that, but still they cross the same bridge at different positions (the bridge has an accessable path that is one tile high, it was adjusted so it fits the white figure). Note also, that all three characters moved the same amount onto the bridge. That shows the offset even more.
      Apparently the game places them a bit randomly, the offset seems different everytime I test it.
      Anyone knows how to work around this?

      Posted Image

    • What we can't see is what amount of white space you have surrounding each graphic. Are they all trimmed to the same dimensions?

      The offset can definitely be changed by adding/subtracting margins.

    • @rubber-ducky, on Apr 27 2006, 09:40 AM, said in Sprite problem:

      What we can't see is what amount of white space you have surrounding each graphic. Are they all trimmed to the same dimensions?

      The offset can definitely be changed by adding/subtracting margins.

      As I said, they all have the same size, 92x112, to be exact. The positions of the sprites inside the pics are the same as well.

    • I find that Coldstone doesn't really like access that's one tile high or wide. Can you make it two please and try it then?

      Also, is your sprite actually walking? It looks like it's facing NE but trying to walk E. Do you have it 8 directions?

    • I find that Coldstone doesn't really like access that's one tile high or wide. Can you make it two please and try it then?
      The bridge is not wide enough. It is just wide enough to fit one tile, I'll have to change the tile sizes. That'll be extensive, because I made all my maps with the same size, so I'll have to change at least those with bridges. At least it'll only affect the ground and access layers. I'll tell you the result when I'm done.

      Also, is your sprite actually walking? It looks like it's facing NE but trying to walk E. Do you have it 8 directions?
      Yes, it is walking. But currently I only have the iso directions (NE, SE, SW, NW). I'm working on the regular directions (N, S, W, E), but right now the chars can walk into 8 directions, but only face into four directions.

      Edit:
      Tried to decrease the tile size to 48x48 (original size was 96x96), but that didn't help anything. Sometimes the chars seem to walk along the edges of the tile grid, sometimes they walk along the middle.
      Changing the size also caused the tiles to screw up. They were displayed correctly in the map editor, but showed up as 96x96 in the game, but in a 48x48 grid - thus half of the tile was cut off.
      To make a path two tiles wide across the bridge, I'd have to reduce the tile size to about 24x24, that would result in a map size of 208x208, resulting in memory problems, and the same graphic error.
      Well, I guess that only leaves me one chance - forget the bridges that come with the game and find or model bridges that are 200 pixels wide.

      This post has been edited by Arion : 27 April 2006 - 03:18 PM

    • The ground tiles should be 96 x 96.

      The MOVEMENT tiles should be 30 x 30, especially seeing the size of your sprites. I use the same bridge, and two movement tiles, which is the automatic size of your access tiles, will fit with the bridge. Place the bridge above the Player in the map (I think). If that doesn't work, place the Player above the bridge. Anyway, I use the grid on the map to place my bridges.

      In your map window, on the left, along with layers, events, etc. is access. To cross a bridge, block the access above and below the bridge. The movement tiles will turn red. Leave two access (movement) tiles on the bridge. It won't fit the two ends very well, but hardly noticeable once playing the game. You probably know this.

      I just can't quite see what's up.

    • I'm compelled to asnwer a few things in several posts. I do so in hopes of clarifying some areas of confusion.

      I know that the map editor opens with a default setting of 96 x 96 for both ground tiles and movement tiles but that does not seem to work out well. The "showoff" game for Coldstone (Pillars of Garendall) has ground tiles of 96 x 96 and movement tiles of 32 x 32 which is an even division making three movment tiles along each side of each ground tile. The map dimensions for outdoor maps are usually 200 x 200 movement tiles, the indoor maps or caves can be 100 x 100, 50 x 50, or even 25 x 25 movement tiles. In none of these maps do the ground tiles fit exactly on the map but always hang over the edge on the east and south sides. Experiments have shown that the maps can have as many as 440 x 440 movement tiles without a problem if the ground tile to movement tile ratio is as above.

      Movement tiles of 30 x 30, as Debra uses, also seem to work out fine even though the movement tile edges will not line up with ground tile edges very often.

      I have experienced no problem with access being only one tile wide. In fact, if the player is to travel a diagonal path, only the corners of the tiles with access need touch. Even with movement tiles which are only 30 x 30 pixels the playing character has some latitude in movement within each tile. With most sprites, the playing character can walk along the top edge of the tile, the bottom edge, or across the middle. The sprite takes about three steps on each tile as he crosses it. In the pictures showing the random placement of the character crossing the bridge, I'm wondering if this is because the movement tiles are just set too large. Each step of your sprite covers about 10 pixels which means it takes him about nine steps to cross a tile if the movement tiles are set at 96 x 96 pixels.

      If you place a character on a tile which has access blocked in all directions, the character will not move, but if the surrounding area is not blocked, he can move a short distance without leaving the tile on which he is standing.

      If your movement tiles are 96 x 96 pixels, please try this:
      ° Change the setting for movement tiles to 32 x 32.
      ° Change the map dimensions to three times what you now have.
      ° Completely redo the access portion af your map to conform to the new movement tile size.

      This will, I believe, fix a number of the problems you are experiencing.

    • Hm, that still keeps the bridge at one tile wide. It doesn't remove the problem, only causes the characters to not stray as far away from the middle.
      Apparently it keeps changing on whitch edge of a tile the char walks, because one of the chars wasn't even able to step on the bridge, while all the others were.
      Guess I still have to model wider bridges, so I can make it at least 2 tiles wide.

    • Arion, there is some other nasty thing at work here. Are the different characters consistant in their directional offset from the desired position? If their foot placement is the same in each graphic, they all should walk across the same way, or close to it. You wouldn't have a stray pixel in the border somewhere which is not pure white, would you? This could offset the centering of the sprite. If one guy is not even on the path, then widening the path is not going to fix it, only make it worse.

      If you widened the bridge graphic and kept the access narrow down the center, that would fix the visual effect, but you would be treating the symptoms and not the sickness.

      Tracing these little nasties down can be frustrating to say the least (I know, I've been there, done that) but it seems that each example brought to the forum has its own cause. Congratulations, your problem is unique. Finding the root of the problem is often time consuming and all we can offer are suggestions. I would suggest you make up a couple of new sprites, or borrow some from the graphics library, and test them on your map.

      Stick with it, and keep us informed on what results occur.

    • Alright, I'll check for stray pixels. I doubt there are any, but I'll check.

      EDIT: Checked the sprites, no stray pixels. Also checked the position of the feet, there's no difference that would explain these severe offsets.

      Yesterday I observed that a char (the feline) was unable to actually cross one of the bridges, even though the path was open. It couldn't step onto the accessible tile. It seems to me that the chars are changing their positions on the tiles. So if a char is usually positioned at the bottom-left corner of a tile, it might be slowly wandering up to the top-left corner, for example.
      I let the feline pass another bridge, and then walk the problematic one from the other side. That worked, and walking back worked as well, then.

      This post has been edited by Arion : 03 May 2006 - 11:40 PM

    • Regarding not able to cross bridge: This is why I find that two spaces are necessary instead of just one. Sometimes they're blocked. Once it's two spaces, I've had no problems.

    • Which is what I'm gonna do. Create a wider bridge and give it a path 2 tiles wide.
      You're right, it won't remove the problem, but what the players don't know doesn't make them blow.

    • @shamannils, on May 4 2006, 10:29 PM, said in Sprite problem:

      Regarding not able to cross bridge: This is why I find that two spaces are necessary instead of just one. Sometimes they're blocked. Once it's two spaces, I've had no problems.

      Coldstone sometimes stuffs up the access tiles on maps for no apparent reason. For example, in TQFTMC in two areas you can walk straight through some trees even though the editor insists that the access is blocked.

    • I think in terms of rules when working with Coldstone. I simply think in terms of what the engine likes. Ever since I followed these rules, I've had no problems at all.

      Access rules:

      1. Allow at least two wide spaces for travel.

      2. If the no-access tiles are on a diagonal, the Player can walk between them. Plug up the gap with a no-access tile. The no-access tiles then look like steps.

      3. If the access tiles are on a diagonal, make sure a tile between them is also open. The tiles then look like steps. Double the tiles so they're at least two complete steps wide.

    • GRRRR!!!!
      After revamping all maps with one-tile-wide passages, I discovered that what I did was total bullcrap.
      I changed the movement tile size to 32x32 instead of the normal 96x96. And guess what happened, what I discovered after redoing 7 maps!
      When the movement tiles and the ground tiles don't have the same size (at least it only occurs with maps where this is the case), then the minimap system becomes buggy. In fact, the player's X is not displayed in the middle of the parts of the map that get uncovered (when you have fog of war enabled). I had cases where the X was constantly in the black area, north of the part that got uncovered.
      Well, back to the original plan, making a really wide bridge, and hope that the game will not ###### up the access tiles too often. I can make a 150 pixel wide bridge at a movement tile size of 96x96, but two tiles wide, that'll make a big bridge.

    • Oh heavens. Both RD and I have told you that movement tiles really shouldn't be 96 x 96 but either 30 x 30 or, to make it divide into the 96 x 96 ground tiles, 32 x 32. I've tried to tell you to make access at least two tiles wide.

      When you change movement tiles, your maps do change, so you'll have to change your dimensions and reset WHERE you place your NPCs.

      You're going through a learning curve. Of course you'll have to work at it.

    • Uhm... you know... there's a little button, which automatically creates an updated map. I used that. Besides, changing the MAP doesn't change where the FOG OF WAR gets removed. I could even use a random doodle, that wouldn't change anything. Fact is, the X that represents the player on the minimap was NOT located where the FOG OF WAR disappeared. It was always located NORTH of it, INSIDE the FOG OF WAR. Using access tiles of 96x96 is the least buggy variant, sadly.

      Let me specify.
      This image on the left shows what it's supposed to look like, the one on the right shows what is actually happening.
      Posted Image Posted Image

      This post has been edited by Arion : 17 May 2006 - 12:39 AM

    • Yes, the fog of war will change, too, when you change the size of your movement tiles to normal. I don't see this as a problem, since the Player is what makes the fog of war. I've disabled the fog of war until I've completed my game. It does nothing for me while creating it.

      Just change your movement tiles to normal (32 x 32), adjust your maps, start ANOTHER game, run around, and then check the fog of war.

      Okay, here's why. The fog of war runs off of movement tiles. Count the movement tiles at 96x96 and it's three times that of 32x32. That's why the 'X' is two-thirds higher and to the left.

    • About start another game, that's what I did. I always recompile when I changed something.

      The effect is unacceptable, but I want to have fog of war active. The player is to explore, would be boring if s/he knew everything all along. That way the map would be like a cheat, telling you where to find what.

    • You and Debra do not seem to be saying the same thing. "Recompile" is not "starting a new game." She means to take a new character (player) fresh from the start where the fog would cover the map over again.

      I've also been thinking about your problem and what I come up with is this. When you go to draw the overhead map (the one which shows where you are), the default setting for the rendition is 440 x 440. Every time I have changed this I have run into problems. The map dimensions may change but this setting, I believe, should be left alone. Trash your map pictures (NOT your maps) and, from the Map Editor, re-draw the overheads. This is not a lot of work. Now start a new character and check the results.

      Stick with us here and I think we can get this solved. 🙂 ~RD