1 /***************************************************************************** 2 * Copyright (c) 2014-2020 OpenRCT2 developers 3 * 4 * For a complete list of all authors, please refer to contributors.md 5 * Interested in contributing? Visit https://github.com/OpenRCT2/OpenRCT2 6 * 7 * OpenRCT2 is licensed under the GNU General Public License version 3. 8 *****************************************************************************/ 9 10 #pragma once 11 12 #include "GameAction.h" 13 14 class GuestSetNameAction final : public GameActionBase<GameCommand::SetGuestName> 15 { 16 private: 17 uint16_t _spriteIndex{ SPRITE_INDEX_NULL }; 18 std::string _name; 19 20 public: 21 GuestSetNameAction() = default; 22 GuestSetNameAction(uint16_t spriteIndex, const std::string& name); 23 24 uint16_t GetSpriteIndex() const; 25 std::string GetGuestName() const; 26 27 void AcceptParameters(GameActionParameterVisitor& visitor) override; 28 29 uint16_t GetActionFlags() const override; 30 31 void Serialise(DataSerialiser& stream) override; 32 GameActions::Result::Ptr Query() const override; 33 GameActions::Result::Ptr Execute() const override; 34 }; 35