| 1 | #pragma once |
| 2 | |
| 3 | #include <basis/seadTypes.h> |
| 4 | #include <math/seadVector.h> |
| 5 | |
| 6 | namespace al { |
| 7 | class PlayerHolder; |
| 8 | class SceneCameraInfo; |
| 9 | |
| 10 | class SwitchAreaTargetInfo { |
| 11 | public: |
| 12 | /** |
| 13 | * @info mCameraLookAtPositions will be set to an array of cameraLookAtPositionMaxCount |
| 14 | * sead::Vector3f but only one is used/updated. |
| 15 | */ |
| 16 | SwitchAreaTargetInfo(s32 playerPositionSize, s32 cameraLookAtPositionSize); |
| 17 | /** |
| 18 | * @warning Using this ctor will cause a crash when calling update because |
| 19 | * mCameraLookAtPositions is nullptr by default. |
| 20 | */ |
| 21 | SwitchAreaTargetInfo(sead::Vector3f* playerPositions, s32 playerPositionCount); |
| 22 | |
| 23 | void update(const PlayerHolder* playerHolder, const SceneCameraInfo* sceneCameraInfo); |
| 24 | |
| 25 | sead::Vector3f* getPlayerTargetPositions() const { return mPlayerTargetPositions; } |
| 26 | |
| 27 | s32 getPlayerTargetPositionCount() const { return mPlayerTargetPositionCount; } |
| 28 | |
| 29 | sead::Vector3f* getCameraLookAtPositions() const { return mCameraLookAtPositions; } |
| 30 | |
| 31 | s32 getCameraLookAtPositionCount() const { return mCameraLookAtPositionCount; } |
| 32 | |
| 33 | private: |
| 34 | sead::Vector3f* mPlayerTargetPositions = nullptr; |
| 35 | s32 mPlayerTargetPositionCount = 0; |
| 36 | s32 mPlayerTargetPositionSize = 0; |
| 37 | sead::Vector3f* mPlayerPositions = nullptr; |
| 38 | s32 mPlayerPositionCount = 0; |
| 39 | s32 mPlayerPositionSize = 0; |
| 40 | sead::Vector3f* mCameraLookAtPositions = nullptr; |
| 41 | s32 mCameraLookAtPositionCount = 0; |
| 42 | s32 mCameraLookAtPositionSize = 0; |
| 43 | }; |
| 44 | |
| 45 | static_assert(sizeof(SwitchAreaTargetInfo) == 0x30); |
| 46 | } // namespace al |
| 47 | |