testing and debugging - magemonkeystudio/fabled GitHub Wiki

πŸ§ͺ Testing & Debugging

This guide helps you troubleshoot issues and test skills, classes, and attributes in Fabled using in-game tools, debug messages, and the web editor.


🎯 In-Game Testing Tips

πŸ›  Cast Skills In-Game

To test a skill, you must first profess into a class that contains the skill:

/class profess <class>

Then you can cast a skill using:

/class cast <skill>

⚠️ You cannot cast skills unless you're properly professed into a class that contains the skill.

Depending on the server's casting mode (set in config.yml under Casting.mode), you may have additional interfaces:

Mode How to Use
ACTION_BAR Press F to open casting mode, then 1–9 to cast skills
TITLE Press F to open casting mode, skills display as title
CHAT Press F to open casting mode, skills appear in chat
BARS Left/right-click the cast item to open hotbar or hover
COMBAT Toggle skill mode via cast item
ITEM Left/right-click the cast item to cycle skills

To organize or assign skills, use the GUI:

/class skill

🧠 You can also use /class bar in modes like BARS or COMBAT to assign and rearrange your skill bar.


🧰 Add Debugging Mechanics

Use these mechanics inside your skill to confirm signal flow and catch logic errors:

  • Message – Displays a chat message to confirm that a section of the skill was triggered.
  • Particle – Visually marks targeting areas or signal flow.
  • Title – Shows a message as a screen overlay for immediate feedback.
  • Cooldown Message – Use cooldown-message: true in your skill to show when a skill is on cooldown.
  • Signal Branch Testing – Add different messages inside Hit, Fail, or Else paths to see which condition is matched.

πŸ” Enable Console Debug Logging

To see internal plugin logs (not in-game messages), edit your config.yml file and adjust the logging levels:

Logging:
  'attribute-load': '3'
  buff: '2'
  registration: '5'
  gui: '1'
  mana: '2'

Higher numbers (1–5) will show more detail in the console. This helps when loading attributes, skills, or classes.


🧰 Web Editor Testing Tools

  • Preview Targeting – Enable preview.circle or preview.sphere in Target components to visualize range while editing.
  • Simplify First – Test new skills with only a Message or Particle before building complex logic.
  • Signal Chaining – Use chained mechanics (e.g. damage β†’ message β†’ particle) to verify flow step-by-step.

🐞 Troubleshooting Common Issues

Issue Possible Cause
Skill doesn't appear in GUI It’s not assigned to your current class
Skill appears but does nothing Missing mechanics or blocked by a failed condition
Skill file won't load YAML errors (tabs, blank lines, incorrect quoting, etc.)
Attributes don’t affect skills Missing attribute linkage or incorrect formulas in components
Targeting does nothing Incorrect range, target group, or filters blocking selection
Projectiles don’t fire Missing speed, range, effect, or bad nesting

πŸ§ͺ Example Test Skill

This basic test skill sends a message to confirm that your setup is working.

testskill:
  name: testskill
  type: Dynamic
  max-level: "1"
  skill-req-lvl: 0
  needs-permission: false
  cooldown-message: true
  msg: "&6{player} &2has cast &6{skill}"
  combo: ""
  icon: Stick
  icon-data: 0
  icon-lore:
    - "&d{name} &7({level}/{max})"
    - "&2Type: &6{type}"
    - ""
    - "{req:level}Level: {attr:level}"
    - "{req:cost}Cost: {attr:cost}"
    - ""
    - "&2Mana: {attr:mana}"
    - "&2Cooldown: {attr:cooldown}"
  attributes:
    level-base: 1
    level-scale: 0
    cost-base: "0"
    cost-scale: 0
    cooldown-base: "0"
    cooldown-scale: 0
    mana-base: 0
    mana-scale: 0
    points-spent-req-base: 0
    points-spent-req-scale: 0
  incompatible: []
  components:
    Cast:
      type: trigger
      children:
        Message:
          type: mechanic
          data:
            icon-key: ""
            counts: true
            message: "&aTest Skill activated!"

Once added to your skill list and class:

/class profess <yourclass>
/class cast testskill

If the message appears, your skill system is functioning properly.


πŸ”— Related Pages

⚠️ **GitHub.com Fallback** ⚠️