Manual: Debugging Visual Scripts

This guide explains how to debug issues when working with visual scripts in ACTION GAME MAKER.


Use the “Print Message to Console” Action Effectively

The Print Message to Console action is specifically for debugging.
When this action is executed, it outputs a custom message to the Output panel at the bottom of the screen.

Place this action in a state where an issue is occurring to check if it’s being reached.

  • If no message appears:
    The state is not being reached, which means there’s likely a problem with the transition link to that state.
  • If a message does appear:
    The state is being reached, so the issue is likely with the execution action or the collision detection settings (such as Hit/Attack Areas).

Show Hitboxes with Collision Display

Enable Visible Collision Shapes from the debug menu to visualize collision areas.
Use this to check problems such as “should be colliding but isn’t” or “objects pass through each other unexpectedly.”


Helpful for Tracking Down Issues: “Display Text” Action

The Display Text action can be used to show variables on screen.
If you set the duration to infinite, the text will remain on screen even when the state changes—useful for debugging.

For example: If you suspect that damage isn’t being applied even though an attack connects, try displaying the target’s HP variable.


Common Source of Mistakes: Collision Layer and Mask

If a state transition isn’t triggering on contact, check the Collision Layer and Collision Mask settings.

  • Detecting walls:
    This checks for collisions between Collision2D objects.
    → Make sure your object’s CollisionMask includes the other object’s CollisionLayer.
  • Detecting attack collisions:
    This checks for collisions between your HitCollision and the other object’s AttackCollision.
    → Make sure your HitArea2D’s mask matches the target’s AttackArea2D layer.
  • Detecting hit targets:
    This checks for collisions between your AttackCollision and the target’s HitCollision.
    → Make sure your AttackArea2D’s mask matches the target’s HitArea2D layer.

For more details on Collision Layers and Masks, refer to the following manual: