Editing Combat State Overview

Jump to navigation Jump to search

Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.

Latest revision Your text
Line 1: Line 1:
== Combat State Overview ==
== Combat State Overview ==
This page provides a general overview of how the <code>Combat</code> state works. The combat state is divided into two main "phases": the '''"decision phase"''' and the '''"action phase"'''. For non-server games, there is also an additional '''"draw phase"''' which draws and animates the results of the action phase.
== Summary ==
Here is a short summary of the game logic for combat:
http://i.imgur.com/Xfhmp0b.png
=== Decision Phase ===
The decision phase is part of combat where all players in a match choose the action they'd like to perform. After all players have made a decision, the action phase starts and resolves the actions that the players chose.
* Wait for all players in a match to decide on an action.
* Decision phase ends.
=== Action Phase ===
The action phase is responsible for carrying out the actions that the players have chosen and any combat effects (such as poison effects, etc.) in the appropriate order. This is also known as "resolving" the actions and effects. The action phase can be further sub-divided into the '''"Pre-Action== Combat State Overview ==
This page provides a general overview of how the <code>Combat</code> state works. The combat state is divided into two main "phases": the '''"decision phase"''' and the '''"action phase"'''. For non-server games, there is also an additional '''"draw phase"''' which draws and animates the results of the action phase.
This page provides a general overview of how the <code>Combat</code> state works. The combat state is divided into two main "phases": the '''"decision phase"''' and the '''"action phase"'''. For non-server games, there is also an additional '''"draw phase"''' which draws and animates the results of the action phase.


Line 51: Line 66:
* Resolve all '''"Post-Phase"''' effects (E.g. effects on monsters that happen ''after'' all actions have been carried out)
* Resolve all '''"Post-Phase"''' effects (E.g. effects on monsters that happen ''after'' all actions have been carried out)
** Check if match is over.
** Check if match is over.
* Action phase ends.
=== Draw Phase (client-only) ===
* Draw and animate the results.
* Draw phase ends (decision phase begins again).
Phase"''', '''"Action Phase"''', and '''"Post-Action Phase"''' phases.
Here is an explanation for each of these sub-phases:
* '''Pre-Action Phase''' - Effects on monsters that happen ''before'' '''all''' players' actions are carried out.
* '''Action Phase''' - Each player's actions are carried out.
* '''Pre-Action''' - Effects on monster ''before'' they carry out their individual action.
* '''Action''' - Single player's action is resolved.
* '''Post-Action''' - Effects on monster ''after'' they carry out their individual action.
* '''Post-Action Phase''' - Effects on monsters that happen ''after'' '''all''' players' actions have been carried out
Here is a break-down of exactly how the action phase should be resolved:
* Resolve all '''"Pre-Action Phase"''' effects (E.g. effects on monsters that happen ''before'' actions are carried out)
* Check if match is over.
* Resolve all '''"Run Away"''' actions.
* Check if run away is successful.
* Resolve all '''"Monster Switch"''' actions.
* Check if monster can be switched out. (Effects may prevent monster switching)
* Resolve '''"Post-Action"''' effect for monster if they could not be switched. (E.g. poison damage, etc.)
* Check if match is over.
* Resolve all '''"Use Item"''' actions in order of monster speed in the following way:
* Resolve '''"Pre-Action"''' effects for player using item. (E.g. effects that happen before the monster can perform their action)
* Check if match is over.
* Resolve '''"Use Item"''' action for player using an item.
* Check if match is over.
* Resolve '''"Post-Action"''' effects for player using item. (E.g. poison damage, etc.)
* Check if match is over.
* Resolve all '''"Technique"''' actions in order of monster speed in the following way:
* Resolve '''"Pre-Action"''' effects for player using technique. (E.g. effects that happen before the monster can perform their action)
* Check if match is over.
* Resolve '''"Technique"''' action for player using technique.
* Check if match is over.
* Resolve '''"Post-Action"''' effects for player using technique. (E.g. poison damage, etc.)
* Check if match is over.
* Resolve all '''"Post-Phase"''' effects (E.g. effects on monsters that happen ''after'' all actions have been carried out)
* Check if match is over.
* Action phase ends.
* Action phase ends.


Please note that all contributions to Tuxepedia are considered to be released under the Creative Commons Attribution-ShareAlike (see Tuxepedia:Copyrights for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource. Do not submit copyrighted work without permission!

Cancel Editing help (opens in new window)