New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[modify_unit] in advance events causes a loop #5298
Comments
What if you apply the effect in a It doesn't sound like a bug to me, [modify_unit] is going to put a unit on the map that has more XP than it needs to advance, so that probably should trigger an infinite loop. I just checked whether this was a regression that would break SXC, and saw that SXC already uses a Edit: when using an |
It's not putting a unit on the map, it's altering one that's already there. The [modify_unit] tag doesn't use store-unstore for most changes. Unless it alters experience, I don't think this should happen; and even if it does alter experience there should be some exit condition in the engine so it doesn't loop infinitely.
Nothng in WML code should trigger an infinite loop. |
I wanted to use the However, I actually don't need to use So, no use case anymore. |
This error also happens in |
If the unit, which is going to advance right after this event, is modified in any wayby [modify_unit], the advancement-choice dialog is shown again.
As afterwards as expected advance events are triggered, it result's in a loop.
The wiki explains a similar case, but it should not happen here:
It's enough to give an object or change hp. Example code:
Applying the commented-out object without the use of [modify_unit] does not trigger this, so this points to [modify_unit].
My intention was to use [modify_unit] to apply an [advancement].
Tested with version 1.15 - 31a5120
The text was updated successfully, but these errors were encountered: