From d1e158d6f723b6fcb2f1edf1ffac29b81ed307e7 Mon Sep 17 00:00:00 2001 From: truelight Date: Thu, 24 Mar 2005 17:03:37 +0000 Subject: (svn r2046) -Codechange: moved all waypoint code to waypoint.c/waypoint.h -Codechange: rewrote some functions while moving waypoint-stuff -Add: added support for 64k waypoints -Fix: made the waypoint struct a bit more logic (no bit-fucking) --- order_gui.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'order_gui.c') diff --git a/order_gui.c b/order_gui.c index a681a7c3c..0a92caa84 100644 --- a/order_gui.c +++ b/order_gui.c @@ -13,6 +13,7 @@ #include "command.h" #include "viewport.h" #include "depot.h" +#include "waypoint.h" static int OrderGetSel(Window *w) { @@ -219,7 +220,7 @@ static Order GetOrderCmdFromTile(Vehicle *v, uint tile) && (_map5[tile]&0xFE)==0xC4) { order.type = OT_GOTO_WAYPOINT; order.flags = 0; - order.station = GetWaypointByTile(tile); + order.station = GetWaypointByTile(tile)->index; return order; } @@ -379,7 +380,7 @@ static void OrdersWndProc(Window *w, WindowEvent *e) xy = GetDepot(ord->station)->xy; break; case OT_GOTO_WAYPOINT: /* goto waypoint order */ - xy = _waypoints[ord->station].xy; + xy = GetWaypoint(ord->station)->xy; } if (xy) -- cgit v1.2.3-54-g00ecf