Skip to content

Skirk: .skirk.void_rifts appears stale immediately after charge, allowing an impossible second charge branch #2588

@antamial

Description

@antamial

I found what looks like a bug in Skirk's Void Rift handling.

After skirk charge;, the field .skirk.void_rifts does not appear to update immediately. Because of that, the script can enter the charge branch again on the very next loop iteration, which should be impossible in-game.

In practice, this means the simulator can allow two consecutive CHARGE branches based on stale void_rifts state.

A simplified pattern is:

while 1 {
    if .skirk.void_rifts >= 2 {
        print("CHARGE", " frame=", f(), " vr=", .skirk.void_rifts);
        skirk charge;
        continue;
    }

    # other actions 
}

Expected behavior

After skirk charge;, Void Rifts should be consumed immediately for subsequent script logic.

So on the next loop iteration, .skirk.void_rifts should reflect the consumed state and should not still satisfy the same void_rifts >= ... condition.

Actual behavior

Immediately after skirk charge;, .skirk.void_rifts still seems to have the old value for script branching purposes.

As a result, this can happen:

  • CHARGE at frame 1055 vr=3
  • CHARGE again at frame 1085 vr=3

This second charge branch appears to be caused by .skirk.void_rifts still being seen as high enough right after the first charge.

Why this looks incorrect

My understanding is that Skirk's charge attack consumes Void Rifts.
So after skirk charge;, it should not be possible for .skirk.void_rifts to still remain above the threshold required for another immediate charge branch, unless a new rift had already been generated — and even then it should not remain at the previous multi-rift value.

Minimal reproduction idea

The issue can be reproduced with a loop that:

  1. checks .skirk.void_rifts
  2. does skirk charge; when the threshold is reached
  3. immediately re-checks .skirk.void_rifts on the next loop iteration

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions