Posted August 29, 20205 yr Hello, I am in the process of learning how to make a mod but I am stuck on the spawning portion. My current mapping is: mappings channel: 'snapshot', version: '20200723-1.16.1' The errors I get are: error: cannot find symbol .add(new Biome.SpawnListEntry(ModEntityTypes.BENGAL_CAT.get(), 10, 3, 5)); ^ symbol: class SpawnListEntry location: class Biome and error: cannot find symbol biome.getSpawns(EntityClassification.CREATURE) ^ symbol: method getSpawns(EntityClassification) location: variable biome of type Biome Here is the code. package com.undecimber.naturereconstructed.world.gen; import com.undecimber.naturereconstructed.naturereconstructed; import com.undecimber.naturereconstructed.init.ModEntityTypes; import net.minecraft.entity.EntityClassification; import net.minecraft.world.biome.Biome; import net.minecraftforge.eventbus.api.SubscribeEvent; import net.minecraftforge.fml.common.Mod; import net.minecraftforge.fml.event.lifecycle.FMLLoadCompleteEvent; import net.minecraftforge.registries.ForgeRegistries; @Mod.EventBusSubscriber(modid = naturereconstructed.MOD_ID, bus = Mod.EventBusSubscriber.Bus.MOD) public class ModEntitySpawns { @SubscribeEvent public static void spawnEntities(FMLLoadCompleteEvent event) { for (Biome biome : ForgeRegistries.BIOMES) { // Nether Mobs if (biome.getCategory() == Biome.Category.NETHER) { } // End Mobs else if (biome.getCategory() == Biome.Category.THEEND) { } // Overworld Mobs else { if (biome.getCategory() != Biome.Category.OCEAN) { biome.getSpawns(EntityClassification.CREATURE) .add(new Biome.SpawnListEntry(ModEntityTypes.BENGAL_CAT.get(), 10, 3, 5)); } } } } } Edited August 29, 20205 yr by Undecimber
August 29, 20205 yr The correct name for your mappings would be: 20200723-1.16.1 Check out the port of the BetterEnd fabric mod (WIP): https://www.curseforge.com/minecraft/mc-mods/betterend-forge-port
August 29, 20205 yr Author 3 minutes ago, Beethoven92 said: The correct name for your mappings would be: 20200723-1.16.1 I typed it in this website incorrectly. My mappings is: mappings channel: 'snapshot', version: '20200723-1.16.1'
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.