Implements BattleRandom class with support for Effect Chance, and script hooks to modify this.
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
@@ -7,6 +7,7 @@
|
||||
#include "../Library/BattleLibrary.hpp"
|
||||
#include "../TurnChoices/BaseTurnChoice.hpp"
|
||||
#include "BattleParty.hpp"
|
||||
#include "BattleRandom.hpp"
|
||||
#include "BattleResult.hpp"
|
||||
#include "BattleSide.hpp"
|
||||
#include "CreatureIndex.hpp"
|
||||
@@ -19,7 +20,7 @@ namespace CreatureLib::Battling {
|
||||
uint8_t _numberOfSides;
|
||||
uint8_t _creaturesPerSide;
|
||||
std::vector<BattleSide*> _sides;
|
||||
Core::Random _random;
|
||||
BattleRandom _random;
|
||||
ChoiceQueue* _currentTurnQueue = nullptr;
|
||||
bool _hasEnded = false;
|
||||
BattleResult _battleResult = BattleResult::Empty();
|
||||
@@ -55,7 +56,7 @@ namespace CreatureLib::Battling {
|
||||
void CheckChoicesSetAndRun();
|
||||
|
||||
[[nodiscard]] ChoiceQueue* GetCurrentTurnQueue() const;
|
||||
Core::Random& GetRandom();
|
||||
BattleRandom& GetRandom();
|
||||
|
||||
bool CreatureInField(const Creature* creature) const;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user