1
Fork 0
mirror of https://github.com/SapphireServer/Sapphire.git synced 2025-05-05 02:07:46 +00:00
sapphire/src/world/Manager/ActionMgr.h

48 lines
1.6 KiB
C
Raw Normal View History

#ifndef SAPPHIRE_ACTIONMGR_H
#define SAPPHIRE_ACTIONMGR_H
#include "ForwardsZone.h"
namespace Sapphire::Data
{
struct Action;
using ActionPtr = std::shared_ptr< Action >;
2019-02-09 21:48:42 +11:00
struct ItemAction;
using ItemActionPtr = std::shared_ptr< ItemAction >;
struct EventItem;
using EventItemPtr = std::shared_ptr< EventItem >;
}
namespace Sapphire::World::Manager
{
2020-03-01 01:00:57 +11:00
class ActionMgr
{
public:
2020-03-01 01:00:57 +11:00
ActionMgr() = default;
~ActionMgr() = default;
2023-03-12 00:39:46 +09:00
void handleTargetedAction( Entity::Chara& chara, uint32_t actionId,
2019-07-26 20:28:01 +10:00
Data::ActionPtr actionData, uint64_t targetId, uint16_t sequence );
2023-03-12 00:39:46 +09:00
void handlePlacedAction( Entity::Chara& chara, uint32_t actionId,
2019-07-26 20:28:01 +10:00
Data::ActionPtr actionData, Common::FFXIVARR_POSITION3 pos, uint16_t sequence );
void handleItemAction( Entity::Player& player, uint32_t itemId, Data::ItemActionPtr itemActionData,
uint16_t itemSourceSlot, uint16_t itemSourceContainer );
2019-02-09 19:26:31 +11:00
void handleEventItemAction( Entity::Player& player, uint32_t itemId, Data::EventItemPtr itemActionData, uint32_t sequence, uint64_t targetId );
2020-01-23 22:43:16 +09:00
void handleMountAction( Entity::Player& player, uint16_t mountId,
2020-01-23 22:36:01 +09:00
Data::ActionPtr actionData, uint64_t targetId, uint16_t sequence );
private:
2023-03-12 00:39:46 +09:00
void bootstrapAction( Entity::Chara& chara, Action::ActionPtr currentAction, Data::Action& actionData );
2019-02-09 21:48:42 +11:00
// item action handlers
void handleItemActionVFX( Entity::Player& player, uint32_t itemId, uint16_t vfxId );
};
}
#endif //SAPPHIRE_ACTIONMGR_H