1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-22 06:23:04 +01:00
Files
OpenRCT2/src/openrct2/object/AudioObject.h
Michael Steenbeek 8fe2d7de1f Rename Object and TileElement type constant (#23030)
* Rename Object::objectType to  Object::kObjectType

* Rename TileElement::ElementType to TileElement::kElementType
2024-10-20 07:10:55 +01:00

35 lines
1.0 KiB
C++

/*****************************************************************************
* Copyright (c) 2014-2024 OpenRCT2 developers
*
* For a complete list of all authors, please refer to contributors.md
* Interested in contributing? Visit https://github.com/OpenRCT2/OpenRCT2
*
* OpenRCT2 is licensed under the GNU General Public License version 3.
*****************************************************************************/
#pragma once
#include "../audio/AudioSource.h"
#include "../core/IStream.hpp"
#include "AudioSampleTable.h"
#include "Object.h"
#include <optional>
class AudioObject final : public Object
{
private:
AudioSampleTable _sampleTable;
AudioSampleTable _loadedSampleTable;
public:
static constexpr ObjectType kObjectType = ObjectType::Audio;
void ReadJson(IReadObjectContext* context, json_t& root) override;
void Load() override;
void Unload() override;
OpenRCT2::Audio::IAudioSource* GetSample(uint32_t index) const;
int32_t GetSampleModifier(uint32_t index) const;
};