Codechange: strongly type RoadStopID

This commit is contained in:
Rubidium 2025-02-01 02:47:31 +01:00 committed by rubidium42
parent d10499f2f1
commit f9f19de8c2
2 changed files with 3 additions and 2 deletions

View File

@ -15,7 +15,7 @@
#include "core/bitmath_func.hpp"
#include "vehicle_type.h"
typedef Pool<RoadStop, RoadStopID, 32, 64000> RoadStopPool;
using RoadStopPool = Pool<RoadStop, RoadStopID, 32, RoadStopID::End().base()>;
extern RoadStopPool _roadstop_pool;
/** A Stop for a Road Vehicle */

View File

@ -10,11 +10,12 @@
#ifndef STATION_TYPE_H
#define STATION_TYPE_H
#include "core/pool_type.hpp"
#include "core/smallstack_type.hpp"
#include "tilearea_type.h"
typedef uint16_t StationID;
typedef uint16_t RoadStopID;
using RoadStopID = PoolID<uint16_t, struct RoadStopIDTag, 64000, 0xFFFF>;
struct BaseStation;
struct Station;