Spawn Detail Presets: Difference between revisions

(navbox)
(Ruined structure is no longer a preset. Spawned some updated details)
 
Line 1: Line 1:
{{TOC|right}}
{{TOC|right}}
== Preface ==
== Preface ==
The JSONs in the <code>spawn_detail_presets</code> folder create the <code>presets</code> that are used in Pokémon spawn files. Presets are simply a collection of <code>conditions</code>, <code>anticonditions</code>, and <code>contexts</code> that are bundled up into a new <code>preset</code> named after the JSON file name! They are a great way to make familiar scenes into a simple tag you can use when making spawns.  
The JSONs in the <code>spawn_detail_presets</code> folder create the <code>presets</code> that are used in Pokémon [[Spawn_Pool_World|spawn files]]. Presets are simply a collection of <code>conditions</code>, <code>anticonditions</code>, and <code>contexts</code> that are bundled up into a new <code>preset</code> named after the JSON file name! They are a great way to make familiar scenes into a simple tag you can use when making spawns.  


=== Preset Breakdown ===
=== Preset Breakdown ===
You can make a <code>preset</code> as simple or complex as you like. The complexity of it depends on your understanding of [https://gitlab.com/cable-mc/cobblemon/-/wikis/Spawner/Spawn-Condition spawn conditions], [https://docs.google.com/document/d/1iB0EJSc2r6mRJXIo1n3XpHbZ5udwJVnrh2pXdhTyH8c/edit biomes], and your creativity. Almost all presets include one major condition. This condition is a list of blocks that the Pokémon can spawn on.
You can make a <code>preset</code> as simple or complex as you like. The complexity of it depends on your understanding of [[Spawn_Condition|spawn conditions]], [https://docs.google.com/document/d/1iB0EJSc2r6mRJXIo1n3XpHbZ5udwJVnrh2pXdhTyH8c/edit biomes], and your creativity. Almost all presets include one major condition. This condition is a list of blocks that the Pokémon can spawn on.


Here is a breakdown of the <code>ruined_structure</code> preset. Its conditions are very similar to being in a Stronghold. Hover over the underlined text to see more information.
Here is a breakdown of the <code>stronghold</code> preset. Its conditions require you to be in a naturally generated stronghold with some block requirements. Hover over the underlined text to see more information.


  {
  {
     "<abbr title="Here you will list spawn conditions that will allow a Pokémon to spawn">condition</abbr>": {
     "<abbr title="Here you will list spawn conditions that will allow a Pokémon to spawn">condition</abbr>": {
         "<abbr title="Whether or not the sky is visible. True or false">canSeeSky</abbr>": false,
         "<abbr title="A list of structures that a Pokémon can spawn in the area of. You will need to list the structure id which can be identified in game using the locate structure command.">structures</abbr>": [
            "<abbr title="The ID for minecraft's stronghold structure. This will allow Pokémon with this preset to spawn in strongholds provided the other conditions are also met.">minecraft:stronghold</abbr>"
        ],
        "<abbr title="Here you are specifying the max Y level the Pokémon can spawn at.">maxY</abbr>": <abbr title="In this case, pokemon using this preset wont spawn above Y:62">62</abbr>,
         "<abbr title="A list of blocks that a Pokémon can spawn on top of. Can list block id's or block tags.">neededBaseBlocks</abbr>": [
         "<abbr title="A list of blocks that a Pokémon can spawn on top of. Can list block id's or block tags.">neededBaseBlocks</abbr>": [
             "<abbr title="The block id for cracked stone bricks">minecraft:cracked_stone_bricks</abbr>",
             "<abbr title="The block tag for the different kinds of stone bricks.">#minecraft:stone_bricks</abbr>"
            "<abbr title="The block id for mossy stone bricks">minecraft:mossy_stone_bricks</abbr>",
            "<abbr title="The block id for chiseled stone bricks">minecraft:chiseled_stone_bricks</abbr>",
            "<abbr title="The block id for mossy cobblestone">minecraft:mossy_cobblestone</abbr>",
            "<abbr title="The block id for iron bars">minecraft:iron_bars</abbr>"
         ],
         ],
         "<abbr title="A list of biomes that a Pokémon can spawn in. Can list specific vanilla or modded biomes. Can also list biome tags.">biomes</abbr>": [
         "<abbr title="A list of blocks required to be nearby in order for a Pokémon to spawn. Only one block from the list is required to be nearby.">neededNearbyBlocks</abbr>": [
             "<abbr title="The Cobblemon tag for all overworld biomes">#cobblemon:is_overworld</abbr>"
             "<abbr title="The block ID for cracked stone bricks">minecraft:cracked_stone_bricks</abbr>",
        ]
             "<abbr title="The block ID for mossy stone bricks">minecraft:mossy_stone_bricks</abbr>"
    },
    "<abbr title="A list of spawn conditions that will PREVENT a Pokémon from spawning.">anticondition</abbr>": {
        "<abbr title="A list of biomes that a Pokémon will never spawn in. Can list specific vanilla or modded biomes. Can also list biome tags.">biomes</abbr>": [
             "<abbr title="The Cobblemon tag for abyss. Which is the deep dark biome and some caves from Terralith.">#cobblemon:is_abyss</abbr>"
         ]
         ]
     }
     }
  }
  }


=== Preset Examples ===
=== Preset Examples ===

Latest revision as of 06:39, 4 March 2024

Preface

The JSONs in the spawn_detail_presets folder create the presets that are used in Pokémon spawn files. Presets are simply a collection of conditions, anticonditions, and contexts that are bundled up into a new preset named after the JSON file name! They are a great way to make familiar scenes into a simple tag you can use when making spawns.

Preset Breakdown

You can make a preset as simple or complex as you like. The complexity of it depends on your understanding of spawn conditions, biomes, and your creativity. Almost all presets include one major condition. This condition is a list of blocks that the Pokémon can spawn on.

Here is a breakdown of the stronghold preset. Its conditions require you to be in a naturally generated stronghold with some block requirements. Hover over the underlined text to see more information.

{
   "condition": {
       "structures": [
           "minecraft:stronghold"
       ],
       "maxY": 62,
       "neededBaseBlocks": [
           "#minecraft:stone_bricks"
       ],
       "neededNearbyBlocks": [
           "minecraft:cracked_stone_bricks",
           "minecraft:mossy_stone_bricks"
       ]
   }
}


Preset Examples

Here are some simple examples of presets.

  • lava_surface - Allows Pokémon with this preset to spawn on top of lava
{
 "context": "surface",
 "condition": {
   "fluid": "#minecraft:lava"
 }
}


  • river - Allows Pokémon to spawn in river biomes that aren't covered in snow or ice.
{
 "condition": {
   "biomes": [ "#cobblemon:is_river" ]
 },
 "anticondition": {
   "biomes": [ "#cobblemon:is_freezing" ]
 }
}


  • redstone - Allows Pokémon to spawn near some redstone related blocks
{
   "condition": {
       "neededNearbyBlocks": [
           "minecraft:activator_rail",
           "minecraft:daylight_detector",
           "minecraft:detector_rail",
           "minecraft:dispenser",
           "minecraft:dropper",
           "minecraft:hopper",
           "minecraft:observer",
           "minecraft:piston",
           "minecraft:powered_comparator",
           "minecraft:powered_rail",
           "minecraft:powered_repeater",
           "minecraft:redstone_block",
           "minecraft:redstone_lamp",
           "minecraft:redstone_torch",
           "minecraft:redstone_wire",
           "minecraft:sticky_piston",
           "minecraft:unlit_redstone_torch",
           "minecraft:unpowered_comparator",
           "minecraft:unpowered_repeater",
           "#minecraft:redstone_ores",
           "#c:redstone_blocks",
           "#c:redstone_ores"
       ]
   }
}