OpenTTD/ship.h
Darkvater 2452a20e07 (svn r5861) - Backport from trunk (r5839):
A ship in a depot must be stopped before allowed to be cloned (copied ship.h from trunk).
2006-08-12 12:22:38 +00:00

16 lines
271 B
C

/* $Id$ */
#include "vehicle.h"
static inline bool IsShipInDepot(const Vehicle* v)
{
assert(v->type == VEH_Ship);
return v->u.ship.state == 0x80;
}
static inline bool IsShipInDepotStopped(const Vehicle* v)
{
return IsShipInDepot(v) && v->vehstatus & VS_STOPPED;
}