Add: Configuration of NewGRF badges.
This commit is contained in:
committed by
Peter Nelson
parent
daef052329
commit
c2d4098afa
@@ -10,6 +10,7 @@
|
||||
#include "stdafx.h"
|
||||
#include "newgrf.h"
|
||||
#include "newgrf_badge.h"
|
||||
#include "newgrf_badge_config.h"
|
||||
#include "newgrf_badge_type.h"
|
||||
#include "newgrf_spritegroup.h"
|
||||
#include "stringfilter_type.h"
|
||||
@@ -42,6 +43,15 @@ std::span<const Badge> GetBadges()
|
||||
return _badges.specs;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get a read-only view of class badge index.
|
||||
* @return Span of badges.
|
||||
*/
|
||||
std::span<const BadgeID> GetClassBadges()
|
||||
{
|
||||
return _badges.classes;
|
||||
}
|
||||
|
||||
/**
|
||||
* Assign a BadgeClassID to the given badge.
|
||||
* @param index Badge ID of badge that should be assigned.
|
||||
|
||||
Reference in New Issue
Block a user