Don't store inactive timers in the saved game
Thanks to @fosnola for spotting this.
This commit is contained in:
@@ -22,6 +22,12 @@
|
||||
#include "damage.hpp"
|
||||
#include "fields.hpp"
|
||||
|
||||
bool cTimer::is_valid() const {
|
||||
if(time < 0) return false;
|
||||
if(node < 0) return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
cSpecial::cSpecial(){
|
||||
type = eSpecType::NONE;
|
||||
sd1 = -1;
|
||||
|
@@ -98,6 +98,7 @@ public:
|
||||
long time = 0;
|
||||
eSpecCtxType node_type = eSpecCtxType::SCEN;
|
||||
short node = -1;
|
||||
bool is_valid() const;
|
||||
};
|
||||
|
||||
// HAIL means called when initiating conversation.
|
||||
|
Reference in New Issue
Block a user