User Tools

Site Tools


card-actions

Card Actions

Card Actions are effects that can happen at the start of a battle, at the start of a turn, or when you play a Card or use an Item. These effects can be used in sequence to create more versatile effects.

Skills/Items

Card Actions can be added to a Skill or Item by using the following notetag format:

<Card Actions>
    Action
    Action
    Action
</Card Actions> 

The actions will execute in the order they are listed for the User of the Card.

Card Target Actions execute actions for the Target of the skill/item using the following notetag format:

<Card Target Actions>
    Action
    Action
    Action
</Card Target Actions>

These can be used for example to have an ally draw cards as part of a Card effect.

Note: Since Enemies do not have Cards or Decks (as of MYTH_CGC_CoreEngine v1.6.0), they can't process Card Target Actions. This feature is currently limited to an Actor and their allied Party members.

The list of Actions available in the Core Plugin are as follows:

Draw X Where X is a number, target draws that many cards from Hand.
Draw Until X Where X is a number, draw until your Hand size reaches that number.
Discard X Where X is a number, discard that many cards
Discard Until X Where X is a number, discard until your hand size reaches that number.
Remove X Where X is a number, remove that many cards from play. These cards are only removed for the current battle.
Remove Until X Where X is a number, remove until your hand size reaches that number.
Add [skillID] to [zoneName] Adds a card directly to a zone. For example, ““Add 7 to hand”” will create a card of Skill ID 7 in your Hand.
Mill X Moves X cards from the deck directly to the discard
Move X from [zoneName] to [zoneName] A generic form of Draw/Discard/Mill where you can specify any zone. For example “Move 3 from Discard to Hand” will return 3 cards to the hand.
Search For X Where X is either a Skill ID or the name of a Skill/Card, it will find that card in your deck and draw it if it is present.
Wait X Where X is the amount of frames to wait before executing the next Card Action or moving on. This basically adds buffer time between actions. Note that this Action does not execute during Battle Start Actions or Turn Start Actions.
Shuffle Deck Shuffles the target's deck
Eval [expression] Everything after the word “eval” is executed as code.

eval $gameVariables.setValue(4, user.handSize);

This gets the user of the card’s handSize variable and stores it in Game Variable 4.

In place of a number in Card Actions, you can also use \V[x] to use a Game Variable, just like with message boxes.

If you’re using Card Types plugin, you also have access to these Card Actions:

Draw X Type Y Where X is a number and Y is the name of a Card Type, the game will search the player’s deck for cards of type Y and draw the first X amount of them.
Discard X Type Y Where X is a number and Y is the name of a Card Type, the game will search the player's deck for cards of type Y and discard the first X amount of them.
Remove X Type Y Where X is a number and Y is the name of a Card Type, the game will search the player's deck for cards of type Y and remove the first X amount of them.
Mill Until Type X Where X is the name of a Card Type, the game will discard the top card of the player’s deck until a card of card type Y is on the top of the deck. It will not draw or discard this card - these actions would be a separate notetag.

Note: All spellings of card type names are case sensitive.

If you are using the plugin Conditional Card Actions, you also have access to these Card Actions:

if [expression] This will evaluate the expression, and if it's true, it will execute the next Card Action. If false, it will skip that action.
label [labelName] This will define a label, which is important for the jump to Action.
jump to [labelName] This will search for the label with the same name, and move to that label. If the label is after this Card Action, it will skip all Card Actions between the two. If the label is before this Card Action, it will execute the Card Actions between the two a second time.

Example of how these Card Actions can be used:

<Card Actions>
  label start
  if (user.handSize >= 10)
  jump to end
  draw 1
  wait 5
  jump to start
  label end
</Card Actions>

These card actions will draw 1 card, wait 5 frames, and then repeat until the player has 10 cards in their hand.

If you are using the plugin Card Action Pack 1, you also have access to these Card Actions:

Selection Card Actions

Select X from zoneName
Replace 'X' with a number or game variable, and replace 'zoneName' with 'deck', 'discard' or 'hand'. This opens the Card Selection Window and makes the player choose X cards from the specified zone.
Select X of Y from zoneName location
Replace 'X' with a number, 'Y' with another number,'zoneName' with a zone, and a 'location'.

This makes the player choose X cards from a selection of Y cards from the specified zone. Replace 'zoneName' with 'deck', 'discard' or 'hand'. Replace 'location' with 'Top', 'Bottom', 'Random'. If 'Top', The pool of cards will be grabbed from the top Y cards. If 'Bottom', the bottom. If 'random', cards will be grabbed randomly from the zone.
Select X from skills Y, Z, A, B
Replace X, Y, Z, etc with numbers.This makes the player choose X cards from a list of Skill IDs. The list of IDs can be any size.
Select X Type typeName from zoneName
Requires CardTypes. Replace X with a number, typeName with the name of a Card Type, and zoneName with a zone. This makes the player choose X cards from the specified zone filtered to only include the specified Card Type.
Select X of Y Type typename from zoneName location
Requires CardTypes. This makes the player choose X cards from the specified zone, filtered to only include the specified Card Type, with a pool size of Y grabbed from the top/bottom or grabbed randomly from the zone.

Movement Card Actions

Move selected to zoneName
Replace 'zoneName' with a zone. This will move the selected cards from their previous zone to the specified zone.
Remove selected
This will remove the selected cards from play.
Add selected to zoneName
Replace 'zoneName' with a zone. This will add a copy of each selected card to the specified zone. Note that this is the only Movement Card Action that works when using the Card Action “Select from Skills” because it's the only one that does not require a zone of origin.

Clear Card Actions

Clear Selected
Clear Selection
This will evaluate the expression, and if it's true, it will execute the next Card Action. If false, it will skip that action.

Battle Start/Turn Start

Using the Battle Start Actions parameter, Card Actions can be executed at the start of a battle. Simply input each command on a new line like so:

  Shuffle Deck
  Draw 5

This example will shuffle the deck at the start of the battle and draw 5 cards to the player.

Turn Start Actions works the same way, except that these Card Actions are executed at the beginning of every turn except for the first turn:

  Discard Until 0
  Draw 5

This example will cause the player to discard their entire hand and draw 5 new cards.

The Battle Start Actions will execute on turn 0, and the Turn Start Actions will execute at the start of every turn after that.

card-actions.txt · Last modified: 2024/03/23 20:31 by banerjeesw