Skip to content

Card.UpdateAttack

Source Code | Usage Examples | Card Functions

Increases the ATK of a card by a specified value (or decreases it if the value is negative).

Signature

Card.UpdateAttack(Card c, int amount, [int reset, Card rc = c, int reset_count = 1]) → int

lua
c:UpdateAttack(amount,reset,rc,reset_count)

Parameters

  • Card c

    The card to update the ATK of.

  • int amount

    The value to add to the card's current ATK. Can be negative to decrease the card's ATK.

  • int reset

    Optional.

    Composite Reset value describing when the ATK change stops applying.

  • Card rc

    Optional. Defaults to c.

    The card causing the ATK change.

  • int reset_count

    Optional. Defaults to 1.

    How many times reset must happen for the ATK change to stop applying.

Returns

  • int

    The amount of ATK successfully changed (the difference between the card's new ATK and its previous ATK).


atk-related, registers-effect