Add: NewGRF Badges.
This commit is contained in:
committed by
Peter Nelson
parent
ca3b5ed6c1
commit
8f14894024
@@ -12,6 +12,7 @@
|
||||
#include "station_base.h"
|
||||
#include "waypoint_base.h"
|
||||
#include "roadstop_base.h"
|
||||
#include "newgrf_badge.h"
|
||||
#include "newgrf_cargo.h"
|
||||
#include "newgrf_station.h"
|
||||
#include "newgrf_spritegroup.h"
|
||||
@@ -292,6 +293,8 @@ TownScopeResolver *StationResolverObject::GetTown()
|
||||
}
|
||||
break;
|
||||
|
||||
case 0x7A: return GetBadgeVariableResult(*this->ro.grffile, this->statspec->badges, parameter);
|
||||
|
||||
case 0xFA: return ClampTo<uint16_t>(TimerGameCalendar::date - CalendarTime::DAYS_TILL_ORIGINAL_BASE_YEAR); // Build date, clamped to a 16 bit value
|
||||
}
|
||||
|
||||
@@ -393,6 +396,8 @@ TownScopeResolver *StationResolverObject::GetTown()
|
||||
return 0xFFFE;
|
||||
}
|
||||
|
||||
case 0x7A: return GetBadgeVariableResult(*this->ro.grffile, this->statspec->badges, parameter);
|
||||
|
||||
/* General station variables */
|
||||
case 0x82: return 50;
|
||||
case 0x84: return this->st->string_id;
|
||||
|
||||
Reference in New Issue
Block a user