fix apply_to=variation/type
apply_to=variation/type should have no effect when object were reapplied for example at unit creation. This is also the 1.12 behaviour. This also prevents infinite recursion.
This commit is contained in:
parent
694fb9d36e
commit
067b2a872f
1 changed files with 1 additions and 1 deletions
|
@ -2157,7 +2157,7 @@ void unit::add_modification(const std::string& mod_type, const config& mod, bool
|
|||
times --;
|
||||
|
||||
bool was_poisoned = get_state(STATE_POISONED);
|
||||
if ((apply_to == "variation" || apply_to == "type") && no_add == false) {
|
||||
if (apply_to == "variation" || apply_to == "type") {
|
||||
// Apply unit type/variation changes last to avoid double applying effects on advance.
|
||||
set_poisoned = false;
|
||||
last_effect = effect;
|
||||
|
|
Loading…
Add table
Reference in a new issue