1
0
mirror of https://github.com/OpenTTD/OpenTTD synced 2026-01-22 03:42:41 +01:00

Fix 11a8b71: Set direction and rotation of ships upon building (#13625)

This commit is contained in:
SamuXarick
2025-02-22 23:33:25 +00:00
committed by GitHub
parent b28dca2222
commit 718a45b845

View File

@@ -912,7 +912,12 @@ CommandCost CmdBuildShip(DoCommandFlags flags, TileIndex tile, const Engine *e,
v->y_pos = y;
v->z_pos = GetSlopePixelZ(x, y);
v->direction = DiagDirToDir(GetShipDepotDirection(tile));
/* UpdateDeltaXY() requires rotation to be initialised as well. */
v->rotation = v->direction;
v->UpdateDeltaXY();
v->vehstatus = VS_HIDDEN | VS_STOPPED | VS_DEFPAL;
v->spritenum = svi->image_index;