mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-15 11:03:00 +01:00
committed by
GitHub
parent
fcd16cb00a
commit
13795ce082
@@ -857,7 +857,7 @@ namespace OpenRCT2::Ui
|
||||
const auto& widget = w.widgets[widgetIndex];
|
||||
|
||||
// Get the image
|
||||
if (widget.image.GetIndex() == kSpriteIdNull)
|
||||
if (widget.image.GetIndex() == kImageIndexUndefined)
|
||||
return;
|
||||
auto image = widget.image;
|
||||
|
||||
|
||||
@@ -917,7 +917,7 @@ namespace OpenRCT2::Ui::Windows
|
||||
for (size_t i = 0; i < std::size(ObjectSelectionPages); i++)
|
||||
{
|
||||
auto& widget = widgets[WIDX_TAB_1 + i];
|
||||
if (ObjectSelectionPages[i].Image != kSpriteIdNull)
|
||||
if (ObjectSelectionPages[i].Image != kImageIndexUndefined)
|
||||
{
|
||||
widget.type = WidgetType::tab;
|
||||
widget.left = x;
|
||||
|
||||
@@ -48,7 +48,7 @@ namespace OpenRCT2::Ui::Windows
|
||||
{
|
||||
ObjectEntryIndex entryIndex = kObjectEntryIndexNull;
|
||||
StringId stringId = kStringIdNone;
|
||||
ImageIndex imageId = kSpriteIdNull;
|
||||
ImageIndex imageId = kImageIndexUndefined;
|
||||
};
|
||||
|
||||
enum WindowEditorParkEntranceListWidgetIdx
|
||||
|
||||
@@ -688,8 +688,8 @@ namespace OpenRCT2::Ui::Windows
|
||||
if (gFootpathSelection.LegacyPath == kObjectEntryIndexNull)
|
||||
{
|
||||
// Set footpath and queue type button images
|
||||
auto pathImage = kSpriteIdNull;
|
||||
auto queueImage = kSpriteIdNull;
|
||||
auto pathImage = kImageIndexUndefined;
|
||||
auto queueImage = kImageIndexUndefined;
|
||||
auto pathEntry = GetPathSurfaceEntry(gFootpathSelection.NormalSurface);
|
||||
if (pathEntry != nullptr)
|
||||
{
|
||||
@@ -706,7 +706,7 @@ namespace OpenRCT2::Ui::Windows
|
||||
WindowFootpathDrawDropdownButton(rt, WIDX_QUEUELINE_TYPE, queueImage);
|
||||
|
||||
// Set railing
|
||||
auto railingsImage = kSpriteIdNull;
|
||||
auto railingsImage = kImageIndexUndefined;
|
||||
auto railingsEntry = GetPathRailingsEntry(gFootpathSelection.Railings);
|
||||
if (railingsEntry != nullptr)
|
||||
{
|
||||
@@ -719,8 +719,8 @@ namespace OpenRCT2::Ui::Windows
|
||||
auto& objManager = OpenRCT2::GetContext()->GetObjectManager();
|
||||
|
||||
// Set footpath and queue type button images
|
||||
auto pathImage = kSpriteIdNull;
|
||||
auto queueImage = kSpriteIdNull;
|
||||
auto pathImage = kImageIndexUndefined;
|
||||
auto queueImage = kImageIndexUndefined;
|
||||
const auto* pathObj = objManager.GetLoadedObject<FootpathObject>(gFootpathSelection.LegacyPath);
|
||||
if (pathObj != nullptr)
|
||||
{
|
||||
|
||||
@@ -18,8 +18,6 @@
|
||||
using colour_t = uint8_t;
|
||||
enum class FilterPaletteID : int32_t;
|
||||
|
||||
static constexpr ImageIndex kImageIndexUndefined = std::numeric_limits<ImageIndex>::max();
|
||||
|
||||
enum class ImageCatalogue
|
||||
{
|
||||
UNKNOWN,
|
||||
|
||||
@@ -14,4 +14,4 @@
|
||||
|
||||
using ImageIndex = uint32_t;
|
||||
|
||||
constexpr ImageIndex kSpriteIdNull = std::numeric_limits<ImageIndex>::max();
|
||||
constexpr ImageIndex kImageIndexUndefined = std::numeric_limits<ImageIndex>::max();
|
||||
|
||||
@@ -296,7 +296,7 @@ struct TrackDrawerEntry
|
||||
// or because they are not realistic for the ride type (e.g. LIM boosters in Mini Roller Coasters).
|
||||
RideTrackGroups extraTrackGroups{};
|
||||
|
||||
ImageIndex icon = kSpriteIdNull;
|
||||
ImageIndex icon = kImageIndexUndefined;
|
||||
StringId tooltip = kStringIdNone;
|
||||
|
||||
void GetAvailableTrackGroups(RideTrackGroups& res) const;
|
||||
@@ -642,7 +642,7 @@ constexpr RideTypeDescriptor kDummyRTD =
|
||||
.PhotoItem = ShopItem::photo,
|
||||
.BonusValue = 0,
|
||||
.ColourPresets = kDefaultFlatRideColourPreset,
|
||||
.ColourPreview = { kSpriteIdNull, kSpriteIdNull },
|
||||
.ColourPreview = { kImageIndexUndefined, kImageIndexUndefined },
|
||||
.ColourKey = RideColourKey::Ride,
|
||||
.Name = "invalid",
|
||||
.RatingsData =
|
||||
|
||||
Reference in New Issue
Block a user