News:

Simutrans Tools
Know our tools that can help you to create add-ons, install and customize Simutrans.

Airplane stop problem

Started by Milko, February 10, 2011, 10:11:03 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Milko

Hi

I have a strange problem, I'm trying to make the model of an aircraft in an attempt to align properly I came across a strange problem that occurs with the stop of the aircraft. The problem manifests itself in the latest versions in both standard simutrans than in the experimental, and manifests itself with the air of pak128 and with what I'm doing. When a plane stops with the muzzle upward stops perfectly in the pitch (you can see in STOP1) but if it stops with the nose pointing down will stop ahead and overflowing from the tile (as seen in STOP2). In both images I left highlighted the size of the tile with the yellow border and I left the aircraft black background to show how you place the box of the plane itself. We see that the box does not stop the aircraft in the same position. I wonder is a bug?

Giuseppe

Dwachs

This is due to the position of the airplane sprite. Try moving it around in your png.
Parsley, sage, rosemary, and maggikraut.

Milko

Hi

I'm not convinced that this is a problem of the sprite, I think it is a problem in the code.

All aircraft in all packages have the same problem and all planes are centered in the sprite 128x128.

In STOP1 the land (bounded by yellow border) is perfectly aligned to 128x128 sprite plane, in fact, the corners of the yellow border coincide perfectly with the edges of the box of the plane. When the plane stops moving towards south-east or south-west (STOP2) the situation is different in this case, the box of the plane stopped over and the corners of the yellow box of the ground are no longer aligned with the box of the plane.

Giuseppe

Dwachs

Quote
All aircraft in all packages have the same problem and all planes are centered in the sprite 128x128.
Then do not center all images. This is due to how the movement code works: vehicles in stations driving north or west (STOP1) are moved forward a half tile, vehicles driving south or east are not moved forward. This is the same for all vehicles since years.

Solution: move aircraft image for S/E back a half tile in png, or provide an approproate offset (+-64,+-32) in the dat-file.
Parsley, sage, rosemary, and maggikraut.

Milko