diff options
author | matthijs <matthijs@openttd.org> | 2005-05-02 22:13:20 +0000 |
---|---|---|
committer | matthijs <matthijs@openttd.org> | 2005-05-02 22:13:20 +0000 |
commit | 2ab5eee78b495ec73049c8446a0ed37ab4ff0920 (patch) | |
tree | d0b9834259f5e0b0d954f2722cf9ab0ce5de1d99 /order_cmd.c | |
parent | d26052c7df0e3ae640f45d72068e3112c2c21477 (diff) | |
download | openttd-2ab5eee78b495ec73049c8446a0ed37ab4ff0920.tar.xz |
(svn r2255) - Fix: [ 9680363 ] [NPF] Broken buoy handling for ships
Buoys will now try to get within 3 tiles of a buoy instead of a the actual buoy tile. This gets ships to got past buoys in a realistic (IMO) way instead of barging right through them.
- Fix: [NPF] Trains get curves penalties sometimes even when the track is straight.
- Add: [NPF] Ships get a penalty for going over buoys now, so they will try to go around.
- Add: [NPF] Ships get a penalty for curves too, yay for straight lines.
- Add: TrackdirToTrack(), TrackToTrackdir(), IsDiagonalTrack() and IsDiagonalTrackdir() helper functions.
- Add: IsBuoy() and IsBuoyTile() helper functions.
- Codechange: Rearranged part of the control flow of ShipController(), removing a goto.
Diffstat (limited to 'order_cmd.c')
-rw-r--r-- | order_cmd.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/order_cmd.c b/order_cmd.c index 63e017fea..5bdabc899 100644 --- a/order_cmd.c +++ b/order_cmd.c @@ -166,7 +166,7 @@ int32 CmdInsertOrder(int x, int y, uint32 flags, uint32 veh_sel, uint32 packed_o st = GetStation(new_order.station); if (!IsValidStation(st) || - (st->airport_type != AT_OILRIG && !(st->had_vehicle_of_type & HVOT_BUOY) && !CheckOwnership(st->owner))) { + (st->airport_type != AT_OILRIG && !(IsBuoy(st)) && !CheckOwnership(st->owner))) { return CMD_ERROR; } |