Join our discord
In partnership with NodeCraft Logo NodeCraft


You are not logged in! Create an account or login to contribute! Log in here!

Research Examples

From Pixelmon Wiki
Revision as of 03:44, 18 June 2025 by Isi (talk | contribs) (Created page with "{{DISPLAYTITLE:Research Examples}} {{#seo: |title=Pixelmon Research Examples |title_mode=replace |keywords=pixelmon research examples, research json examples, pixelmon ques...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)


Introduction

This page provides practical examples of Research configurations, demonstrating how to implement different types of challenges. Use these as templates for your own Research creations.

Research Example

This multi-stage Ice-type gym challenge demonstrates advanced Research features with progression tracking and narrative elements.

JSON Structure

{
  "stages": [ /* ... */ ],
  "abandonable": false,
  "repeatable": true,
  "unique": true,
  "name": "A Winter's Soldier"
}
  • Non-abandonable: Players must complete the challenge
  • Repeatable: Can be attempted multiple times - cooldowns can be used alongside this
  • Unique: Only one instance can be active per player

Stage Breakdown

Stage 0: Introduction

Features:

  • Dialogue trigger with Professor Wisteria
  • No objectives (pure narrative introduction)
  • Custom GUI sprites
{
  "objectives": [],
  "result": {
    "type": "pixelmon:open_professor_dialogue",
    "dialogue": {
      "pages": [{
        "title": "Prof. Wisteria",
        "text": "Your dialogue here, %player_name%"
      }],
      "rendering_handler": {
        "type": "pixelmon:player",
        "texture": "pixelmon:textures/steve/professorwisteria.png"
      }
    }
  }
}

Stage 1-3: Trainer Battles

Pattern: 1. Defeat two gym trainers (objectives) 2. Receive:

  * Dialogue update
  * ₽500
  * 200 XP

3. Progress to next tier

Sample Objective:

{
  "condition": {
    "type": "pixelmon:string_compare_case_insensitive",
    "first": {"type": "pixelmon:string_context", "key": "pixelmon:trainer"},
    "second": {"type": "pixelmon:constant_string", "value": "trainer_gym_ice_1"}
  },
  "result": [{"type": "pixelmon:give_experience", "exp": 50.0}],
  "name": "Defeat Gym Novice Eule",
  "event": "pixelmon:defeat_trainer"
}

Stage 4: Leader Battle

Final Challenge:

  • Defeat Leader Pulao (leader_gym_dragon_1)
  • Immediate reward: 50 XP

Full Configuration:

{
  "objectives": [{
    "condition": {
      "type": "pixelmon:string_compare_case_insensitive",
      "first": {"type": "pixelmon:string_context", "key": "pixelmon:leader"},
      "second": {"type": "pixelmon:constant_string", "value": "leader_gym_dragon_1"}
    },
    "result": [{"type": "pixelmon:give_experience", "exp": 50.0}],
    "required_amount": 1,
    "name": "Defeat Pulao, the Dragon Gym Leader",
    "sprite": "minecraft:textures/item/experience_bottle.png",
    "event": "pixelmon:defeat_leader"
  }],
  "result": [
    {
      "type": "pixelmon:open_professor_dialogue",
      "dialogue": {
        "pages": [{
          "title": "Prof. Wisteria",
          "text": "Your dialogue here, %player_name%"
        }],
        "rendering_handler": {
          "type": "pixelmon:player",
          "texture": "pixelmon:textures/steve/professorwisteria.png"
        }
      }
    },
    {
      "type": "pixelmon:give_money",
      "money": 500.0
    },
    {
      "type": "pixelmon:give_item",
      "items": [{
        "id": "pixelmon:tm_gen9",
        "components": {
          "minecraft:custom_data": {"tm": 114}
        },
        "count": 1
      }]
    },
    {
      "type": "pixelmon:set_cooldown",
      "player": {"type": "pixelmon:context_player", "key": "pixelmon:player"},
      "key": "pixelmon:cooldown_trigger_trial_by_dragonfire",
      "cooldown": 30,
      "unit": "DAYS"
    }
  ],
  "result_sprites": [
    {"resource": "pixelmon:textures/gui/research/speech_bubble.png"},
    {"resource": "pixelmon:textures/item/badges/legendbadge.png", "description": "Legend Badge"},
    {"resource": "pixelmon:textures/item/tms/tmdragon.png", "description": "TM:114"},
    {"resource": "pixelmon:textures/gui/research/money_pouch.png", "description": "₽500"}
  ]
}

Full Example

▼ Full JSON Configuration


Notes

1. Cooldown System:

  * 30-day real-world cooldown (unit: "DAYS")
  * Persistent using pixelmon:cooldown_trigger_trial_by_dragonfire key

Usage Notes

1. Research ID: pixelmon:research/battle/gym/dragon_1 2. Required permission: Level 2 3. Cooldown is account-bound, not world-bound


Assignment Example

Overview

A simple Assignment that rewards players for defeating any raid battle.

JSON Structure

{
  "stages": [
    {
      "objectives": [
        {
          "condition": {"type": "pixelmon:true"},
          "result": [{"type": "pixelmon:give_money", "money": 500.0}],
          "required_amount": 1,
          "name": {
            "translate": "research.standard.defeat.raid.1", 
            "fallback": "Defeat a Raid"
          },
          "sprite": "pixelmon:textures/gui/research/money_pouch.png",
          "event": "pixelmon:defeat_raid"
        }
      ]
    }
  ],
  "abandonable": true,
  "repeatable": true,
  "unique": false
}

Notes

1. Minimal Objective

"condition": {"type": "pixelmon:true"}
"event": "pixelmon:defeat_raid"

- Triggers on any raid completion - No additional requirements

2. Instant Reward

"result": [{
  "type": "pixelmon:give_money",
  "money": 500.0
}]

- Awards ₽500 immediately - Uses default money pouch sprite

3. Properties

"abandonable": true,
"repeatable": true, 
"unique": false

- Can be canceled and retaken - No completion limits - Multiple can be active

Suggested Use Cases

1. Daily raid challenges 2. New player tutorials 3. Server-wide events 4. Research chains (as first step)

Collection Example

Overview

This "Fish Out of Water" Collection challenges players to collect various Magikarp forms and evolve one into Gyarados.

JSON Structure

{
  "stages": [ /* Collection objectives */ ],
  "abandonable": false,
  "repeatable": true,
  "unique": true,
  "name": {
    "translate": "research.collection.magikarp",
    "fallback": "Fish Out of Water"
  }
}

Overview

1. Collection Objectives

  • Capture 7 Magikarp variants:
 - Normal
 - Valencian
 - Brown Tiger
 - Calico
 - Skelly
 - Roasted
 - Shiny
  • Evolve any Magikarp into Gyarados

2. Reward Structure

  • ₽1000
  • Super Rod item
  • Completion badge

Objective Breakdown

Standard Magikarp Capture

{
  "condition": {
    "type": "pixelmon:spec_matches",
    "pokemon": {
      "type": "pixelmon:context_pokemon",
      "key": "pixelmon:pokemon"
    },
    "spec": "magikarp palette:none"
  },
  "sprite": "pixelmon:textures/pokemon/129_magikarp/male/base/none/sprite.png",
  "event": "pixelmon:capture_pokemon"
}

Special Variant Example (Valencian)

{
  "condition": {
    "type": "pixelmon:spec_matches",
    "spec": "magikarp palette:valencian"
  },
  "sprite": "pixelmon:textures/pokemon/129_magikarp/male/base/valencian/sprite.png",
  "name": "Capture a Valencian Magikarp"
}

Evolution Objective

{
  "event": "pixelmon:evolve_pokemon",
  "condition": {
    "type": "pixelmon:spec_matches",
    "spec": "gyarados"
  },
  "sprite": {
    "resource": [
      {
        "resource": "pixelmon:textures/pokemon/130_gyarados/all/base/none/sprite.png"
      },
      {
        "resource": "pixelmon:textures/item/healingitems/rarecandy.png",
        "offset": [8.25, 8.5, 0],
        "scale": [0.5, 0.5]
      }
    ]
  }
}

Reward Configuration

"result": [
  {
    "type": "pixelmon:give_money",
    "money": 1000.0
  },
  {
    "type": "pixelmon:give_item",
    "items": [{
      "id": "pixelmon:super_rod",
      "Count": 1
    }]
  }
],
"result_sprites": [
  {
    "resource": "pixelmon:textures/gui/research/money_pouch.png",
    "description": "₽1000"
  },
  {
    "resource": "pixelmon:textures/item/superrod.png"
  }
]

Full Example

▼ Full JSON Configuration


Feature Notes

1. Spec Matching

  - Uses pixelmon:spec_matches for precise Pokémon identification

2. Added sprite offsets

  - Evolution shows composite image (Gyarados + Rare Candy)
  - Defining a second sprite and providing a scale and offset can achieve this

3. Properties

  - abandonable: false - Must complete once started
  - unique: true - Prevents duplicate instances
  

Trigger Example

Overview

This trigger activates when a player discovers an Ice-type gym, initiating the "A Winter's Soldier" Research if they meet all conditions. The trigger uses complex logical checks to ensure proper cooldown management and location validation.

JSON Structure

{
  "events": ["pixelmon:find_structure"],
  "condition": {
    "type": "pixelmon:logical_and",
    "conditions": [
      /* Location validation */
      {
        "type": "pixelmon:interaction_condition",
        "condition": {
          "type": "pixelmon:structure_is_one_of",
          "structures": ["pixelmon:gyms/ice"]
        }
      },
      /* Cooldown checks */
      {
        "type": "pixelmon:interaction_condition",
        "condition": {
          "type": "pixelmon:logical_not",
          "condition": {
            "type": "pixelmon:interaction_condition",
            "condition": {
              "type": "pixelmon:on_cooldown",
              "player": {
                "type": "pixelmon:context_player",
                "key": "pixelmon:player"
              },
              "cooldown_key": "pixelmon:cooldown_trigger_a_winters_soldier",
              "cooldown": 30,
              "unit": "DAYS"
            }
          }
        }
      }
    ]
  },
  "research": {
    "reward_rolls_max": 1,
    "guaranteed_reward": {
      "research": "pixelmon:battle/gym/ice_1",
      "condition": {"type": "pixelmon:true"}
    }
  }
}

Breakdown

1. Event Trigger

"events": ["pixelmon:find_structure"]

- Activates when player discovers any structure - Filtered by subsequent conditions

2. Compound Conditions

"type": "pixelmon:logical_and"

- All nested conditions must be true - Contains three key checks:

 a) Valid gym structure
 b) Not on cooldown for this quest
 c) Not on cooldown for related quests

3. Structure Validation

"type": "pixelmon:structure_is_one_of",
"structures": ["pixelmon:gyms/ice"]

- Ensures trigger only activates at Ice gyms - Uses Pixelmon's structure registry IDs

4. Cooldown Management

"type": "pixelmon:on_cooldown",
"cooldown_key": "pixelmon:cooldown_trigger_a_winters_soldier",
"cooldown": 30,
"unit": "DAYS"

- Prevents re-triggering for 30 real-world days - Uses same key as Research's cooldown system - Wrapped in logical_not to invert condition

5. Research Assignment

"guaranteed_reward": {
  "research": "pixelmon:battle/gym/ice_1"
}

- 100% chance to assign specified Research - Uses Research registry ID - No additional random rewards

Full Example

▼ Full JSON Configuration


Notes

1. Event Timing:

  - Triggers when player first loads chunk containing structure
  - Only fires once per structure discovery

2. Cooldown Stacking:

  - Checks multiple cooldown keys
  - Prevents overlapping quest triggers

Suggested Use Cases

  1. Gym challenge initiation
  2. Legendary encounter triggers
  3. Region-specific Research unlocks
  4. Dungeon exploration Assignments
  5. Seasonal Research

Related Pages

© 2012 - 2025 Pixelmon Mod