Rohan Verma



Commit Diff


commit - 5664245ffdadef9dd7116c9b50ff7c7a38d7cde7
commit + dd41c79fb7602b9bbb98e427b931677c61980cea
blob - 699ce2a44582acfe2d78b977618285eee1f6eec7
blob + 54a7ff5c0c3efc4bcab14581b21b0e1b36e8bf4d
--- build.gradle
+++ build.gradle
@@ -1,211 +1,204 @@
-buildscript {

-    repositories {

-        // These repositories are only for Gradle plugins, put any other repositories in the repository block further below

-        maven { url = 'https://maven.minecraftforge.net' }

-        maven { url = 'https://maven.parchmentmc.org' }

-        mavenCentral()

-    }

-    dependencies {

-        classpath group: 'net.minecraftforge.gradle', name: 'ForgeGradle', version: '5.1.+', changing: true

-        classpath 'org.parchmentmc:librarian:1.+'

-    }

-}

-// Only edit below this line, the above code adds and enables the necessary things for Forge to be setup.

-plugins {

-    id 'eclipse'

-    id 'maven-publish'

-}

-apply plugin: 'net.minecraftforge.gradle'

-apply plugin: 'org.parchmentmc.librarian.forgegradle'

-

-

-version = '0.0.1'

-group = 'com.techsupportred.capybaramod' // http://maven.apache.org/guides/mini/guide-naming-conventions.html

-archivesBaseName = 'capybaramod'

-

-// Mojang ships Java 17 to end users in 1.18+, so your mod should target Java 17.

-java.toolchain.languageVersion = JavaLanguageVersion.of(17)

-

-println "Java: ${System.getProperty 'java.version'}, JVM: ${System.getProperty 'java.vm.version'} (${System.getProperty 'java.vendor'}), Arch: ${System.getProperty 'os.arch'}"

-minecraft {

-    // The mappings can be changed at any time and must be in the following format.

-    // Channel:   Version:

-    // official   MCVersion             Official field/method names from Mojang mapping files

-    // parchment  YYYY.MM.DD-MCVersion  Open community-sourced parameter names and javadocs layered on top of official

-    //

-    // You must be aware of the Mojang license when using the 'official' or 'parchment' mappings.

-    // See more information here: https://github.com/MinecraftForge/MCPConfig/blob/master/Mojang.md

-    //

-    // Parchment is an unofficial project maintained by ParchmentMC, separate from MinecraftForge

-    // Additional setup is needed to use their mappings: https://github.com/ParchmentMC/Parchment/wiki/Getting-Started

-    //

-    // Use non-default mappings at your own risk. They may not always work.

-    // Simply re-run your setup task after changing the mappings to update your workspace.

-    mappings channel: 'parchment', version: '1.18.2-2022.11.27-1.19.2'

-    mappings channel: 'official', version: '1.19.2'

-

-    // accessTransformer = file('src/main/resources/META-INF/accesstransformer.cfg') // Currently, this location cannot be changed from the default.

-

-    // Default run configurations.

-    // These can be tweaked, removed, or duplicated as needed.

-    runs {

-        client {

-            workingDirectory project.file('run')

-

-            // Recommended logging data for a userdev environment

-            // The markers can be added/remove as needed separated by commas.

-            // "SCAN": For mods scan.

-            // "REGISTRIES": For firing of registry events.

-            // "REGISTRYDUMP": For getting the contents of all registries.

-            property 'forge.logging.markers', 'REGISTRIES'

-

-            // Recommended logging level for the console

-            // You can set various levels here.

-            // Please read: https://stackoverflow.com/questions/2031163/when-to-use-the-different-log-levels

-            property 'forge.logging.console.level', 'debug'

-

-            // Comma-separated list of namespaces to load gametests from. Empty = all namespaces.

-            property 'forge.enabledGameTestNamespaces', 'capybaramod'

-

-            mods {

-                capybaramod {

-                    source sourceSets.main

-                }

-            }

-        }

-

-        server {

-            workingDirectory project.file('run')

-

-            property 'forge.logging.markers', 'REGISTRIES'

-

-            property 'forge.logging.console.level', 'debug'

-

-            // Comma-separated list of namespaces to load gametests from. Empty = all namespaces.

-            property 'forge.enabledGameTestNamespaces', 'capybaramod'

-

-            mods {

-                capybaramod {

-                    source sourceSets.main

-                }

-            }

-        }

-

-        // This run config launches GameTestServer and runs all registered gametests, then exits.

-        // By default, the server will crash when no gametests are provided.

-        // The gametest system is also enabled by default for other run configs under the /test command.

-        gameTestServer {

-            workingDirectory project.file('run')

-

-            // Recommended logging data for a userdev environment

-            // The markers can be added/remove as needed separated by commas.

-            // "SCAN": For mods scan.

-            // "REGISTRIES": For firing of registry events.

-            // "REGISTRYDUMP": For getting the contents of all registries.

-            property 'forge.logging.markers', 'REGISTRIES'

-

-            // Recommended logging level for the console

-            // You can set various levels here.

-            // Please read: https://stackoverflow.com/questions/2031163/when-to-use-the-different-log-levels

-            property 'forge.logging.console.level', 'debug'

-

-            // Comma-separated list of namespaces to load gametests from. Empty = all namespaces.

-            property 'forge.enabledGameTestNamespaces', 'capybaramod'

-

-            mods {

-                capybaramod {

-                    source sourceSets.main

-                }

-            }

-        }

-

-        data {

-            workingDirectory project.file('run')

-

-            property 'forge.logging.markers', 'REGISTRIES'

-

-            property 'forge.logging.console.level', 'debug'

-

-            // Specify the modid for data generation, where to output the resulting resource, and where to look for existing resources.

-            args '--mod', 'capybaramod', '--all', '--output', file('src/generated/resources/'), '--existing', file('src/main/resources/')

-

-            mods {

-                capybaramod {

-                    source sourceSets.main

-                }

-            }

-        }

-    }

-}

-

-// Include resources generated by data generators.

-sourceSets.main.resources { srcDir 'src/generated/resources' }

-

-repositories {

-    // Put repositories for dependencies here

-    // ForgeGradle automatically adds the Forge maven and Maven Central for you

-

-    // If you have mod jar dependencies in ./libs, you can declare them as a repository like so:

-    // flatDir {

-    //     dir 'libs'

-    // }

-    maven { url 'https://dl.cloudsmith.io/public/geckolib3/geckolib/maven/' }

-}

-

-dependencies {

-    // Specify the version of Minecraft to use. If this is any group other than 'net.minecraft', it is assumed

-    // that the dep is a ForgeGradle 'patcher' dependency, and its patches will be applied.

-    // The userdev artifact is a special name and will get all sorts of transformations applied to it.

-    minecraft 'net.minecraftforge:forge:1.19.2-43.2.1'

-

-    // Real mod deobf dependency examples - these get remapped to your current mappings

-    // compileOnly fg.deobf("mezz.jei:jei-${mc_version}:${jei_version}:api") // Adds JEI API as a compile dependency

-    // runtimeOnly fg.deobf("mezz.jei:jei-${mc_version}:${jei_version}") // Adds the full JEI mod as a runtime dependency

-    // implementation fg.deobf("com.tterrag.registrate:Registrate:MC${mc_version}-${registrate_version}") // Adds registrate as a dependency

-

-    // Examples using mod jars from ./libs

-    // implementation fg.deobf("blank:coolmod-${mc_version}:${coolmod_version}")

-

-    // For more info...

-    // http://www.gradle.org/docs/current/userguide/artifact_dependencies_tutorial.html

-    // http://www.gradle.org/docs/current/userguide/dependency_management.html

-    implementation fg.deobf('software.bernie.geckolib:geckolib-forge-1.19:3.1.39')

-}

-

-// Example for how to get properties into the manifest for reading at runtime.

-jar {

-    manifest {

-        attributes([

-                "Specification-Title"     : "capybaramod",

-                "Specification-Vendor"    : "capybaramodsareus",

-                "Specification-Version"   : "1", // We are version 1 of ourselves

-                "Implementation-Title"    : project.name,

-                "Implementation-Version"  : project.jar.archiveVersion,

-                "Implementation-Vendor"   : "capybaramodsareus",

-                "Implementation-Timestamp": new Date().format("yyyy-MM-dd'T'HH:mm:ssZ")

-        ])

-    }

-}

-

-// Example configuration to allow publishing using the maven-publish plugin

-// This is the preferred method to reobfuscate your jar file

-jar.finalizedBy('reobfJar')

-// However if you are in a multi-project build, dev time needs unobfed jar files, so you can delay the obfuscation until publishing by doing

-// publish.dependsOn('reobfJar')

-

-publishing {

-    publications {

-        mavenJava(MavenPublication) {

-            artifact jar

-        }

-    }

-    repositories {

-        maven {

-            url "file://${project.projectDir}/mcmodsrepo"

-        }

-    }

-}

-

-tasks.withType(JavaCompile).configureEach {

-    options.encoding = 'UTF-8' // Use the UTF-8 charset for Java compilation

-}

+plugins {
+    id 'eclipse'
+    id 'maven-publish'
+    id 'net.minecraftforge.gradle' version '5.1.+'
+    id 'org.parchmentmc.librarian.forgegradle' version '1.+'
+}
+
+version = '0.0.2-1.19.2'
+group = 'com.techsupportred.capybaramod' // http://maven.apache.org/guides/mini/guide-naming-conventions.html
+archivesBaseName = 'capybaramod'
+
+// Mojang ships Java 17 to end users in 1.18+, so your mod should target Java 17.
+java.toolchain.languageVersion = JavaLanguageVersion.of(17)
+
+println "Java: ${System.getProperty 'java.version'}, JVM: ${System.getProperty 'java.vm.version'} (${System.getProperty 'java.vendor'}), Arch: ${System.getProperty 'os.arch'}"
+minecraft {
+    // The mappings can be changed at any time and must be in the following format.
+    // Channel:   Version:
+    // official   MCVersion             Official field/method names from Mojang mapping files
+    // parchment  YYYY.MM.DD-MCVersion  Open community-sourced parameter names and javadocs layered on top of official
+    //
+    // You must be aware of the Mojang license when using the 'official' or 'parchment' mappings.
+    // See more information here: https://github.com/MinecraftForge/MCPConfig/blob/master/Mojang.md
+    //
+    // Parchment is an unofficial project maintained by ParchmentMC, separate from MinecraftForge
+    // Additional setup is needed to use their mappings: https://github.com/ParchmentMC/Parchment/wiki/Getting-Started
+    //
+    // Use non-default mappings at your own risk. They may not always work.
+    // Simply re-run your setup task after changing the mappings to update your workspace.
+    mappings channel: 'parchment', version: '2022.08.14-1.19.2'
+
+    accessTransformer = file('src/main/resources/META-INF/accesstransformer.cfg') // Currently, this location cannot be changed from the default.
+
+    // Default run configurations.
+    // These can be tweaked, removed, or duplicated as needed.
+    runs {
+        client {
+            workingDirectory project.file('run')
+
+            // Recommended logging data for a userdev environment
+            // The markers can be added/remove as needed separated by commas.
+            // "SCAN": For mods scan.
+            // "REGISTRIES": For firing of registry events.
+            // "REGISTRYDUMP": For getting the contents of all registries.
+            property 'forge.logging.markers', 'REGISTRIES'
+
+            // Recommended logging level for the console
+            // You can set various levels here.
+            // Please read: https://stackoverflow.com/questions/2031163/when-to-use-the-different-log-levels
+            property 'forge.logging.console.level', 'debug'
+
+            // Comma-separated list of namespaces to load gametests from. Empty = all namespaces.
+            property 'forge.enabledGameTestNamespaces', 'capybaramod'
+
+            mods {
+                capybaramod {
+                    source sourceSets.main
+                }
+            }
+        }
+
+        server {
+            workingDirectory project.file('run')
+
+            property 'forge.logging.markers', 'REGISTRIES'
+
+            property 'forge.logging.console.level', 'debug'
+
+            property 'forge.enabledGameTestNamespaces', 'capybaramod'
+
+            mods {
+                capybaramod {
+                    source sourceSets.main
+                }
+            }
+        }
+
+        // This run config launches GameTestServer and runs all registered gametests, then exits.
+        // By default, the server will crash when no gametests are provided.
+        // The gametest system is also enabled by default for other run configs under the /test command.
+        gameTestServer {
+            workingDirectory project.file('run')
+
+            property 'forge.logging.markers', 'REGISTRIES'
+
+            property 'forge.logging.console.level', 'debug'
+
+            property 'forge.enabledGameTestNamespaces', 'capybaramod'
+
+            mods {
+                capybaramod {
+                    source sourceSets.main
+                }
+            }
+        }
+
+        data {
+            workingDirectory project.file('run')
+
+            property 'forge.logging.markers', 'REGISTRIES'
+
+            property 'forge.logging.console.level', 'debug'
+
+            // Specify the modid for data generation, where to output the resulting resource, and where to look for existing resources.
+            args '--mod', 'capybaramod', '--all', '--output', file('src/generated/resources/'), '--existing', file('src/main/resources/')
+
+            mods {
+                capybaramod {
+                    source sourceSets.main
+                }
+            }
+        }
+    }
+}
+
+// Include resources generated by data generators.
+sourceSets.main.resources { srcDir 'src/generated/resources' }
+
+repositories {
+    maven {
+        // location of the maven that hosts JEI files
+        name = "Progwml6 maven"
+        url = "https://dvs1.progwml6.com/files/maven/"
+    }
+    maven {
+        // location of a maven mirror for JEI files, as a fallback
+        name = "ModMaven"
+        url = "https://modmaven.dev"
+    }
+    maven {
+        url "https://cursemaven.com"
+        content {
+            includeGroup "curse.maven"
+        }
+    }
+    maven { url 'https://dl.cloudsmith.io/public/geckolib3/geckolib/maven/' }
+}
+
+dependencies {
+    // Specify the version of Minecraft to use. If this is any group other than 'net.minecraft', it is assumed
+    // that the dep is a ForgeGradle 'patcher' dependency, and its patches will be applied.
+    // The userdev artifact is a special name and will get all sorts of transformations applied to it.
+    minecraft 'net.minecraftforge:forge:1.19.2-43.2.1'
+
+    // compile against the JEI API but do not include it at runtime
+    // compileOnly(fg.deobf("mezz.jei:jei-${mc_version}-common-api:${jei_version}"))
+    // compileOnly(fg.deobf("mezz.jei:jei-${mc_version}-forge-api:${jei_version}"))
+    // at runtime, use the full JEI jar for Forge
+    // runtimeOnly(fg.deobf("mezz.jei:jei-${mc_version}-forge:${jei_version}"))
+
+    //runtimeOnly fg.deobf("curse.maven:mekanism-268560:3922056")
+
+    implementation fg.deobf('software.bernie.geckolib:geckolib-forge-1.19:3.1.39')
+
+    // Real mod deobf dependency examples - these get remapped to your current mappings
+    // compileOnly fg.deobf("mezz.jei:jei-${mc_version}:${jei_version}:api") // Adds JEI API as a compile dependency
+    // runtimeOnly fg.deobf("mezz.jei:jei-${mc_version}:${jei_version}") // Adds the full JEI mod as a runtime dependency
+    // implementation fg.deobf("com.tterrag.registrate:Registrate:MC${mc_version}-${registrate_version}") // Adds registrate as a dependency
+
+    // Examples using mod jars from ./libs
+    // implementation fg.deobf("blank:coolmod-${mc_version}:${coolmod_version}")
+
+    // For more info...
+    // http://www.gradle.org/docs/current/userguide/artifact_dependencies_tutorial.html
+    // http://www.gradle.org/docs/current/userguide/dependency_management.html
+}
+
+// Example for how to get properties into the manifest for reading at runtime.
+jar {
+    manifest {
+        attributes([
+                "Specification-Title"     : "capybaramod",
+                "Specification-Vendor"    : "capybaramodsareus",
+                "Specification-Version"   : "1", // We are version 1 of ourselves
+                "Implementation-Title"    : project.name,
+                "Implementation-Version"  : project.jar.archiveVersion,
+                "Implementation-Vendor"   : "capybaramodsareus",
+                "Implementation-Timestamp": new Date().format("yyyy-MM-dd'T'HH:mm:ssZ")
+        ])
+    }
+}
+
+// Example configuration to allow publishing using the maven-publish plugin
+// This is the preferred method to reobfuscate your jar file
+jar.finalizedBy('reobfJar')
+// However if you are in a multi-project build, dev time needs unobfed jar files, so you can delay the obfuscation until publishing by doing
+// publish.dependsOn('reobfJar')
+
+publishing {
+    publications {
+        mavenJava(MavenPublication) {
+            artifact jar
+        }
+    }
+    repositories {
+        maven {
+            url "file://${project.projectDir}/mcmodsrepo"
+        }
+    }
+}
+
+tasks.withType(JavaCompile).configureEach {
+    options.encoding = 'UTF-8' // Use the UTF-8 charset for Java compilation
+}
blob - d357e11210a8d0b71e962ef6669d908ca53d81e6
blob + 8867a6d1e1b2c75f8f31fbe1faa4a65fcba1251d
--- settings.gradle
+++ settings.gradle
@@ -1,7 +1,7 @@
-pluginManagement {

-    repositories {

-        gradlePluginPortal()

-        maven { url = 'https://maven.minecraftforge.net/' }

-        maven { url = 'https://maven.parchmentmc.org' }

-    }

+pluginManagement {
+    repositories {
+        gradlePluginPortal()
+        maven { url = 'https://maven.minecraftforge.net/' }
+        maven { url = 'https://maven.parchmentmc.org' }
+    }
 }
\ No newline at end of file
blob - d0cdcf0d9bb40996fc386910243a382a017d592c
blob + 0a7e7f1d6dcb3544e7f9d8fa85ba5bc4c7e30f05
--- src/main/java/com/techsupportred/capybaramod/capybaramod.java
+++ src/main/java/com/techsupportred/capybaramod/capybaramod.java
@@ -1,56 +1,61 @@
-package com.techsupportred.capybaramod;

-

-import com.mojang.logging.LogUtils;

-import com.techsupportred.capybaramod.entity.client.CapybaraRenderer;

-import com.techsupportred.capybaramod.item.ModItems;

-import net.minecraft.client.renderer.entity.EntityRenderers;

-import net.minecraft.world.entity.SpawnPlacements;

-import net.minecraft.world.entity.animal.Animal;

-import net.minecraft.world.level.levelgen.Heightmap;

-import net.minecraftforge.common.MinecraftForge;

-import net.minecraftforge.eventbus.api.IEventBus;

-import net.minecraftforge.eventbus.api.SubscribeEvent;

-import net.minecraftforge.fml.common.Mod;

-import net.minecraftforge.fml.event.lifecycle.FMLClientSetupEvent;

-import net.minecraftforge.fml.event.lifecycle.FMLCommonSetupEvent;

-import net.minecraftforge.fml.javafmlmod.FMLJavaModLoadingContext;

-import org.slf4j.Logger;

-import software.bernie.geckolib3.GeckoLib;

-import com.techsupportred.capybaramod.entity.ModEntityTypes;

-

-// The value here should match an entry in the META-INF/mods.toml file

-@Mod(capybaramod.MOD_ID)

-public class capybaramod {

-    public static final String MOD_ID = "capybaramod";

-    private static final Logger LOGGER = LogUtils.getLogger();

-

-    public capybaramod() {

-        IEventBus modEventBus = FMLJavaModLoadingContext.get().getModEventBus();

-

-        ModItems.register(modEventBus);

-

-        ModEntityTypes.register(modEventBus);

-

-        GeckoLib.initialize();

-

-        modEventBus.addListener(this::commonSetup);

-

-        MinecraftForge.EVENT_BUS.register(this);

-    }

-

-    private void commonSetup(final FMLCommonSetupEvent event) {

-        event.enqueueWork(() -> {

-            SpawnPlacements.register(ModEntityTypes.CAPYBARA.get(),

-                    SpawnPlacements.Type.ON_GROUND, Heightmap.Types.MOTION_BLOCKING_NO_LEAVES,

-                    Animal::checkAnimalSpawnRules);

-        });

-    }

-

-    @Mod.EventBusSubscriber(modid = MOD_ID, bus = Mod.EventBusSubscriber.Bus.MOD)

-    public static class ClientModEvents {

-        @SubscribeEvent

-        public static void onClientSetup(FMLClientSetupEvent event) {

-            EntityRenderers.register(ModEntityTypes.CAPYBARA.get(), CapybaraRenderer::new);

-        }

-    }

-}
\ No newline at end of file
+package com.techsupportred.capybaramod;
+
+import com.mojang.logging.LogUtils;
+import com.techsupportred.capybaramod.entity.ModEntityTypes;
+import com.techsupportred.capybaramod.entity.client.CapybaraRenderer;
+import com.techsupportred.capybaramod.item.ModItems;
+import net.minecraft.client.renderer.entity.EntityRenderers;
+import net.minecraft.world.entity.SpawnPlacements;
+import net.minecraft.world.entity.animal.Animal;
+import net.minecraft.world.entity.monster.Monster;
+import net.minecraft.world.level.levelgen.Heightmap;
+import net.minecraftforge.common.MinecraftForge;
+import net.minecraftforge.eventbus.api.IEventBus;
+import net.minecraftforge.eventbus.api.SubscribeEvent;
+import net.minecraftforge.fml.common.Mod;
+import net.minecraftforge.fml.event.lifecycle.FMLClientSetupEvent;
+import net.minecraftforge.fml.event.lifecycle.FMLCommonSetupEvent;
+import net.minecraftforge.fml.javafmlmod.FMLJavaModLoadingContext;
+import org.slf4j.Logger;
+import software.bernie.geckolib3.GeckoLib;
+
+// The value here should match an entry in the META-INF/mods.toml file
+@Mod(capybaramod.MOD_ID)
+public class capybaramod {
+    public static final String MOD_ID = "capybaramod";
+    private static final Logger LOGGER = LogUtils.getLogger();
+
+    // Very Important Comment
+    public capybaramod() {
+        IEventBus modEventBus = FMLJavaModLoadingContext.get().getModEventBus();
+
+        ModItems.register(modEventBus);
+
+        ModEntityTypes.register(modEventBus);
+
+        GeckoLib.initialize();
+
+        modEventBus.addListener(this::commonSetup);
+
+        MinecraftForge.EVENT_BUS.register(this);
+    }
+
+    private void commonSetup(final FMLCommonSetupEvent event) {
+        event.enqueueWork(() -> {
+            SpawnPlacements.register(ModEntityTypes.CAPYBARA.get(),
+                    SpawnPlacements.Type.ON_GROUND, Heightmap.Types.MOTION_BLOCKING_NO_LEAVES,
+                    Animal::checkAnimalSpawnRules);
+
+        });
+    }
+
+    // You can use EventBusSubscriber to automatically register all static methods in the class annotated with @SubscribeEvent
+    @Mod.EventBusSubscriber(modid = MOD_ID, bus = Mod.EventBusSubscriber.Bus.MOD)
+    public static class ClientModEvents {
+        @SubscribeEvent
+        public static void onClientSetup(FMLClientSetupEvent event) {
+
+            EntityRenderers.register(ModEntityTypes.CAPYBARA.get(), CapybaraRenderer::new);
+        }
+    }
+}
blob - a8e98156e78e3539542eeec6963b050523189194
blob + e0e121ac5eced3a31fbd7d97779b2df04de68cb6
--- src/main/java/com/techsupportred/capybaramod/entity/ModEntityTypes.java
+++ src/main/java/com/techsupportred/capybaramod/entity/ModEntityTypes.java
@@ -1,27 +1,27 @@
-package com.techsupportred.capybaramod.entity;

-

-import com.techsupportred.capybaramod.capybaramod;

-import com.techsupportred.capybaramod.entity.custom.CapybaraEntity;

-import net.minecraft.resources.ResourceLocation;

-import net.minecraft.world.entity.EntityType;

-import net.minecraft.world.entity.MobCategory;

-import net.minecraftforge.eventbus.api.IEventBus;

-import net.minecraftforge.registries.DeferredRegister;

-import net.minecraftforge.registries.ForgeRegistries;

-import net.minecraftforge.registries.RegistryObject;

-

-public class ModEntityTypes {

-    public static final DeferredRegister<EntityType<?>> ENTITY_TYPES =

-            DeferredRegister.create(ForgeRegistries.ENTITY_TYPES, capybaramod.MOD_ID);

-

-    public static final RegistryObject<EntityType<CapybaraEntity>> CAPYBARA =

-            ENTITY_TYPES.register("capybara",

-                    () -> EntityType.Builder.of(CapybaraEntity::new, MobCategory.CREATURE)

-                            .sized(0.4f, 1.5f)

-                            .build(new ResourceLocation(capybaramod.MOD_ID, "capybara").toString()));

-

-

-    public static void register(IEventBus eventBus) {

-        ENTITY_TYPES.register(eventBus);

-    }

-}
\ No newline at end of file
+package com.techsupportred.capybaramod.entity;
+
+import com.techsupportred.capybaramod.capybaramod;
+import com.techsupportred.capybaramod.entity.custom.CapybaraEntity;
+import net.minecraft.resources.ResourceLocation;
+import net.minecraft.world.entity.EntityType;
+import net.minecraft.world.entity.MobCategory;
+import net.minecraftforge.eventbus.api.IEventBus;
+import net.minecraftforge.registries.DeferredRegister;
+import net.minecraftforge.registries.ForgeRegistries;
+import net.minecraftforge.registries.RegistryObject;
+
+public class ModEntityTypes {
+    public static final DeferredRegister<EntityType<?>> ENTITY_TYPES =
+            DeferredRegister.create(ForgeRegistries.ENTITY_TYPES, capybaramod.MOD_ID);
+
+    public static final RegistryObject<EntityType<CapybaraEntity>> CAPYBARA =
+            ENTITY_TYPES.register("capybara",
+                    () -> EntityType.Builder.of(CapybaraEntity::new, MobCategory.CREATURE)
+                            .sized(0.8f, 0.8f)
+                            .build(new ResourceLocation(capybaramod.MOD_ID, "capybara").toString()));
+
+
+    public static void register(IEventBus eventBus) {
+        ENTITY_TYPES.register(eventBus);
+    }
+}
blob - 37b20495ef6be3163b3ae5be2be73d799409e1ee
blob + c15a1b4e0d46b0f8a394a2a4deb6437b661fcaba
--- src/main/java/com/techsupportred/capybaramod/entity/client/CapybaraModel.java
+++ src/main/java/com/techsupportred/capybaramod/entity/client/CapybaraModel.java
@@ -1,23 +1,23 @@
-package com.techsupportred.capybaramod.entity.client;

-

-import com.techsupportred.capybaramod.capybaramod;

-import com.techsupportred.capybaramod.entity.custom.CapybaraEntity;

-import net.minecraft.resources.ResourceLocation;

-import software.bernie.geckolib3.model.AnimatedGeoModel;

-

-public class CapybaraModel extends AnimatedGeoModel<CapybaraEntity> {

-    @Override

-    public ResourceLocation getModelResource(CapybaraEntity object) {

-        return new ResourceLocation(capybaramod.MOD_ID, "geo/capybara.geo.json");

-    }

-

-    @Override

-    public ResourceLocation getTextureResource(CapybaraEntity object) {

-        return new ResourceLocation(capybaramod.MOD_ID, "textures/entity/capybara/capybara.png");

-    }

-

-    @Override

-    public ResourceLocation getAnimationResource(CapybaraEntity animatable) {

-        return new ResourceLocation(capybaramod.MOD_ID, "animations/capybara.animation.json");

-    }

-}

+package com.techsupportred.capybaramod.entity.client;
+
+import com.techsupportred.capybaramod.capybaramod;
+import com.techsupportred.capybaramod.entity.custom.CapybaraEntity;
+import net.minecraft.resources.ResourceLocation;
+import software.bernie.geckolib3.model.AnimatedGeoModel;
+
+public class CapybaraModel extends AnimatedGeoModel<CapybaraEntity> {
+    @Override
+    public ResourceLocation getModelResource(CapybaraEntity object) {
+        return new ResourceLocation(capybaramod.MOD_ID, "geo/capybara.geo.json");
+    }
+
+    @Override
+    public ResourceLocation getTextureResource(CapybaraEntity object) {
+        return new ResourceLocation(capybaramod.MOD_ID, "textures/entity/capybara_texture.png");
+    }
+
+    @Override
+    public ResourceLocation getAnimationResource(CapybaraEntity animatable) {
+        return new ResourceLocation(capybaramod.MOD_ID, "animations/capybara.animation.json");
+    }
+}
blob - f7cdc38c4d22e372aea223b32b894ca72c88ac73
blob + e1f8e025923caabeec2f4588394ac951d99eb01b
--- src/main/java/com/techsupportred/capybaramod/entity/client/CapybaraRenderer.java
+++ src/main/java/com/techsupportred/capybaramod/entity/client/CapybaraRenderer.java
@@ -1,35 +1,37 @@
-package com.techsupportred.capybaramod.entity.client;

-

-import com.mojang.blaze3d.vertex.PoseStack;

-import com.mojang.blaze3d.vertex.VertexConsumer;

-import com.techsupportred.capybaramod.capybaramod;

-import com.techsupportred.capybaramod.entity.custom.CapybaraEntity;

-import net.minecraft.client.renderer.MultiBufferSource;

-import net.minecraft.client.renderer.RenderType;

-import net.minecraft.client.renderer.entity.EntityRendererProvider;

-import net.minecraft.resources.ResourceLocation;

-import software.bernie.geckolib3.renderers.geo.GeoEntityRenderer;

-

-public class CapybaraRenderer extends GeoEntityRenderer<CapybaraEntity> {

-    public CapybaraRenderer(EntityRendererProvider.Context renderManager) {

-        super(renderManager, new CapybaraModel());

-        this.shadowRadius = 0.3f;

-    }

-

-    @Override

-    public ResourceLocation getTextureLocation(CapybaraEntity instance) {

-        return new ResourceLocation(capybaramod.MOD_ID, "textures/entity/capybara/capybara.png");

-    }

-

-    @Override

-    public RenderType getRenderType(CapybaraEntity animatable, float partialTicks, PoseStack stack,

-                                    MultiBufferSource renderTypeBuffer, VertexConsumer vertexBuilder, int packedLightIn,

-                                    ResourceLocation textureLocation) {

-        if(animatable.isBaby()) {

-            stack.scale(0.4F, 0.4F, 0.4F);

-        } else {

-            stack.scale(0.8F, 0.8F, 0.8F);

-        }

-        return super.getRenderType(animatable, partialTicks, stack, renderTypeBuffer, vertexBuilder, packedLightIn, textureLocation);

-    }

-}
\ No newline at end of file
+package com.techsupportred.capybaramod.entity.client;
+
+import com.mojang.blaze3d.vertex.PoseStack;
+import com.mojang.blaze3d.vertex.VertexConsumer;
+import com.techsupportred.capybaramod.capybaramod;
+import com.techsupportred.capybaramod.entity.custom.CapybaraEntity;
+import net.minecraft.client.renderer.MultiBufferSource;
+import net.minecraft.client.renderer.RenderType;
+import net.minecraft.client.renderer.entity.EntityRendererProvider;
+import net.minecraft.resources.ResourceLocation;
+import org.jetbrains.annotations.Nullable;
+import software.bernie.geckolib3.renderers.geo.GeoEntityRenderer;
+
+public class CapybaraRenderer extends GeoEntityRenderer<CapybaraEntity> {
+    public CapybaraRenderer(EntityRendererProvider.Context renderManager) {
+        super(renderManager, new CapybaraModel());
+        this.shadowRadius = 0.3f;
+    }
+
+    @Override
+    public ResourceLocation getTextureLocation(CapybaraEntity instance) {
+        return new ResourceLocation(capybaramod.MOD_ID, "textures/entity/capybara_texture.png");
+    }
+
+    @Override
+    public RenderType getRenderType(CapybaraEntity animatable, float partialTicks, PoseStack stack,
+                                    @Nullable MultiBufferSource renderTypeBuffer,
+                                    @Nullable VertexConsumer vertexBuilder, int packedLightIn,
+                                    ResourceLocation textureLocation) {
+        if(animatable.isBaby()) {
+            stack.scale(0.4F, 0.4F, 0.4F);
+        } else {
+            stack.scale(0.8F, 0.8F, 0.8F);
+        }
+        return super.getRenderType(animatable, partialTicks, stack, renderTypeBuffer, vertexBuilder, packedLightIn, textureLocation);
+    }
+}
blob - 45f0e2c1927d455fe954b91016589cb9ba8d2784
blob + 5b7823197dea7668b31e302967d7b8455e1b05bf
--- src/main/java/com/techsupportred/capybaramod/entity/custom/CapybaraEntity.java
+++ src/main/java/com/techsupportred/capybaramod/entity/custom/CapybaraEntity.java
@@ -1,208 +1,218 @@
-package com.techsupportred.capybaramod.entity.custom;

-

-import com.techsupportred.capybaramod.entity.ModEntityTypes;

-import net.minecraft.core.BlockPos;

-import net.minecraft.nbt.CompoundTag;

-import net.minecraft.network.syncher.EntityDataAccessor;

-import net.minecraft.network.syncher.EntityDataSerializers;

-import net.minecraft.network.syncher.SynchedEntityData;

-import net.minecraft.server.level.ServerLevel;

-import net.minecraft.sounds.SoundEvent;

-import net.minecraft.sounds.SoundEvents;

-import net.minecraft.world.InteractionHand;

-import net.minecraft.world.InteractionResult;

-import net.minecraft.world.entity.AgeableMob;

-import net.minecraft.world.entity.EntityType;

-import net.minecraft.world.entity.TamableAnimal;

-import net.minecraft.world.entity.ai.attributes.AttributeSupplier;

-import net.minecraft.world.entity.ai.attributes.Attributes;

-import net.minecraft.world.entity.ai.goal.*;

-import net.minecraft.world.entity.ai.goal.target.HurtByTargetGoal;

-import net.minecraft.world.entity.player.Player;

-import net.minecraft.world.item.Item;

-import net.minecraft.world.item.ItemStack;

-import net.minecraft.world.item.Items;

-import net.minecraft.world.level.Level;

-import net.minecraft.world.level.block.state.BlockState;

-import net.minecraft.world.scores.Team;

-import net.minecraftforge.event.ForgeEventFactory;

-import org.jetbrains.annotations.Nullable;

-import software.bernie.geckolib3.core.IAnimatable;

-import software.bernie.geckolib3.core.PlayState;

-import software.bernie.geckolib3.core.builder.AnimationBuilder;

-import software.bernie.geckolib3.core.controller.AnimationController;

-import software.bernie.geckolib3.core.event.predicate.AnimationEvent;

-import software.bernie.geckolib3.core.manager.AnimationData;

-import software.bernie.geckolib3.core.manager.AnimationFactory;

-

-public class CapybaraEntity extends TamableAnimal implements IAnimatable {

-    private AnimationFactory factory = new AnimationFactory(this);

-

-    private static final EntityDataAccessor<Boolean> SITTING =

-            SynchedEntityData.defineId(CapybaraEntity.class, EntityDataSerializers.BOOLEAN);

-

-    public CapybaraEntity(EntityType<? extends TamableAnimal> entityType, Level level1) {

-        super(entityType, level1);

-    }

-

-    public static AttributeSupplier setAttributes() {

-        return TamableAnimal.createMobAttributes()

-                .add(Attributes.MAX_HEALTH, 10.0D)

-                .add(Attributes.MOVEMENT_SPEED, 0.3f).build();

-    }

-

-    @Override

-

-    protected void registerGoals() {

-        this.goalSelector.addGoal(1, new FloatGoal(this));

-        this.goalSelector.addGoal(1, new SitWhenOrderedToGoal(this));

-        this.goalSelector.addGoal(2, new PanicGoal(this,1.250));

-        this.goalSelector.addGoal(2, new BreedGoal(this, 1.250));

-        this.goalSelector.addGoal(3, new LookAtPlayerGoal(this, Player.class, 8.0F));

-        this.goalSelector.addGoal(3, new FollowOwnerGoal(this, 1.0D, 10.0F, 2.0F, false));

-

-        this.goalSelector.addGoal(4, new WaterAvoidingRandomStrollGoal(this, 1.0D));

-        this.goalSelector.addGoal(5, new RandomLookAroundGoal(this));

-        this.targetSelector.addGoal(6, (new HurtByTargetGoal(this)).setAlertOthers());

-    }

-

-    @Nullable

-    @Override

-    public AgeableMob getBreedOffspring(ServerLevel serverLevel, AgeableMob ageableMob) {

-        return ModEntityTypes.CAPYBARA.get().create(serverLevel);

-    }

-

-    @Override

-    public boolean isFood(ItemStack pStack) {

-        return pStack.getItem() == Items.APPLE;

-    }

-

-        private <E extends IAnimatable> PlayState predicate(AnimationEvent<E> event) {

-            if (event.isMoving()) {

-                event.getController().setAnimation(new AnimationBuilder().addAnimation("animation.capybara.walk", true));

-                return PlayState.CONTINUE;

-            }

-

-            if (this.isSitting()) {

-                event.getController().setAnimation(new AnimationBuilder().addAnimation("animation.capybara.sitting"));

-                return PlayState.CONTINUE;

-            }

-

-            event.getController().setAnimation(new AnimationBuilder().addAnimation("animation.capybara.idle", true));

-            return PlayState.CONTINUE;

-        }

-

-        @Override

-        public void registerControllers(AnimationData data) {

-            data.addAnimationController(new AnimationController(this, "controller",

-                    0, this::predicate));

-        }

-

-        @Override

-        public AnimationFactory getFactory() {

-            return this.factory;

-        }

-        protected void playStepSound(BlockPos pos, BlockState blockIn) {

-            this.playSound(SoundEvents.SWEET_BERRY_BUSH_PICK_BERRIES, 0.15F, 1.0F);

-        }

-

-        protected SoundEvent getAmbientSound() {

-            return SoundEvents.FOX_AMBIENT;

-        }

-

-        protected SoundEvent getDeathSound() {

-            return SoundEvents.DOLPHIN_DEATH;

-        }

-

-        protected float getSoundVolume() { return 0.2F; }

-

-

-    @Override

-    public InteractionResult mobInteract(Player player, InteractionHand hand) {

-        ItemStack itemstack = player.getItemInHand(hand);

-        Item item = itemstack.getItem();

-

-        Item itemForTaming = Items.SUGAR_CANE;

-

-        if(isFood(itemstack)) {

-            return super.mobInteract(player, hand);

-        }

-

-        if (item == itemForTaming && !isTame()) {

-            if (this.level.isClientSide) {

-                return InteractionResult.CONSUME;

-            } else {

-                if (!player.getAbilities().instabuild) {

-                    itemstack.shrink(1);

-                }

-

-                if (!ForgeEventFactory.onAnimalTame(this, player)) {

-                    if (!this.level.isClientSide) {

-                        super.tame(player);

-                        this.navigation.recomputePath();

-                        this.setTarget(null);

-                        this.level.broadcastEntityEvent(this, (byte)7);

-                        setSitting(true);

-                    }

-                }

-

-                return InteractionResult.SUCCESS;

-            }

-        }

-

-

-        if(isTame() && !this.level.isClientSide && hand == InteractionHand.MAIN_HAND) {

-            setSitting(!isSitting());

-            return InteractionResult.SUCCESS;

-        }

-

-        if (itemstack.getItem() == itemForTaming) {

-            return InteractionResult.PASS;

-        }

-

-        return super.mobInteract(player, hand);

-    }

-

-    @Override

-        public void readAdditionalSaveData(CompoundTag tag) {

-            super.readAdditionalSaveData(tag);

-            setSitting(tag.getBoolean("isSitting"));

-        }

-

-        @Override

-        public void addAdditionalSaveData(CompoundTag tag) {

-            super.addAdditionalSaveData(tag);

-            tag.putBoolean("isSitting", this.isSitting());

-        }

-

-        @Override

-        protected void defineSynchedData() {

-            super.defineSynchedData();

-            this.entityData.define(SITTING, false);

-        }

-

-        public void setSitting(boolean sitting) {

-            this.entityData.set(SITTING, sitting);

-            this.setOrderedToSit(sitting);

-        }

-

-        public boolean isSitting() {

-            return this.entityData.get(SITTING);

-        }

-

-        @Override

-        public Team getTeam() {

-            return super.getTeam();

-        }

-

-        public boolean canBeLeashed(Player player) {

-            return true;

-        }

-

-    @Override

-    public void setTame(boolean tamed) {

-        super.setTame(tamed);

-        getAttribute(Attributes.MAX_HEALTH).setBaseValue(10.0D);

-        getAttribute(Attributes.MOVEMENT_SPEED).setBaseValue((double)0.3f);

-    }

+package com.techsupportred.capybaramod.entity.custom;
+
+import com.techsupportred.capybaramod.entity.ModEntityTypes;
+import net.minecraft.core.BlockPos;
+import net.minecraft.nbt.CompoundTag;
+import net.minecraft.network.syncher.EntityDataAccessor;
+import net.minecraft.network.syncher.EntityDataSerializers;
+import net.minecraft.network.syncher.SynchedEntityData;
+import net.minecraft.server.level.ServerLevel;
+import net.minecraft.sounds.SoundEvent;
+import net.minecraft.sounds.SoundEvents;
+import net.minecraft.world.InteractionHand;
+import net.minecraft.world.InteractionResult;
+import net.minecraft.world.damagesource.DamageSource;
+import net.minecraft.world.entity.ai.attributes.AttributeSupplier;
+import net.minecraft.world.entity.ai.attributes.Attributes;
+import net.minecraft.world.entity.ai.goal.*;
+import net.minecraft.world.entity.ai.goal.target.HurtByTargetGoal;
+import net.minecraft.world.entity.player.Player;
+import net.minecraft.world.item.Item;
+import net.minecraft.world.item.ItemStack;
+import net.minecraft.world.item.Items;
+import net.minecraft.world.level.Level;
+import net.minecraft.world.level.block.state.BlockState;
+import net.minecraft.world.scores.Team;
+import net.minecraftforge.event.ForgeEventFactory;
+import org.jetbrains.annotations.Nullable;
+import software.bernie.geckolib3.core.IAnimatable;
+import software.bernie.geckolib3.core.PlayState;
+import software.bernie.geckolib3.core.builder.AnimationBuilder;
+import software.bernie.geckolib3.core.controller.AnimationController;
+import software.bernie.geckolib3.core.event.predicate.AnimationEvent;
+import software.bernie.geckolib3.core.manager.AnimationData;
+import software.bernie.geckolib3.core.manager.AnimationFactory;
+import net.minecraft.world.entity.AgeableMob;
+import net.minecraft.world.entity.EntityType;
+import net.minecraft.world.entity.TamableAnimal;
+
+public class CapybaraEntity extends TamableAnimal implements IAnimatable {
+    private AnimationFactory factory = new AnimationFactory(this);
+
+    private static final EntityDataAccessor<Boolean> SITTING =
+            SynchedEntityData.defineId(CapybaraEntity.class, EntityDataSerializers.BOOLEAN);
+
+    public CapybaraEntity(EntityType<? extends TamableAnimal> entityType, Level level) {
+        super(entityType, level);
+    }
+
+    public static AttributeSupplier setAttributes() {
+        return TamableAnimal.createMobAttributes()
+                .add(Attributes.MAX_HEALTH, 10.0D)
+                .add(Attributes.MOVEMENT_SPEED, 0.2f).build();
+    }
+
+    protected void registerGoals() {
+        this.goalSelector.addGoal(1, new FloatGoal(this));
+        this.goalSelector.addGoal(1, new SitWhenOrderedToGoal(this));
+        this.goalSelector.addGoal(2, new PanicGoal(this, 1.25D));
+        this.goalSelector.addGoal(2, new BreedGoal(this, 1.25D));
+        this.goalSelector.addGoal(3, new LookAtPlayerGoal(this, Player.class, 8.0F));
+        this.goalSelector.addGoal(3, new FollowOwnerGoal(this, 1.0D, 10.0F, 2.0F, false));
+
+        this.goalSelector.addGoal(4, new WaterAvoidingRandomStrollGoal(this, 1.0D));
+        this.goalSelector.addGoal(5, new RandomLookAroundGoal(this));
+        this.targetSelector.addGoal(6, (new HurtByTargetGoal(this)).setAlertOthers());
+    }
+
+    @Nullable
+    @Override
+    public AgeableMob getBreedOffspring(ServerLevel serverLevel, AgeableMob mob) {
+        return ModEntityTypes.CAPYBARA.get().create(serverLevel);
+    }
+
+    @Override
+    public boolean isFood(ItemStack pStack) {
+        return pStack.getItem() == Items.APPLE;
+    }
+
+    private <E extends IAnimatable> PlayState predicate(AnimationEvent<E> event) {
+        if (event.isMoving()) {
+            event.getController().setAnimation(new AnimationBuilder().addAnimation("animation.capybara.walk", true));
+            return PlayState.CONTINUE;
+        }
+
+        if (this.isSitting()) {
+            event.getController().setAnimation(new AnimationBuilder().addAnimation("animation.capybara.sitting", true));
+            return PlayState.CONTINUE;
+        }
+
+        event.getController().setAnimation(new AnimationBuilder().addAnimation("animation.capybara.idle", true));
+        return PlayState.CONTINUE;
+    }
+
+    @Override
+    public void registerControllers(AnimationData data) {
+        data.addAnimationController(new AnimationController(this, "controller",
+                0, this::predicate));
+    }
+
+    @Override
+    public AnimationFactory getFactory() {
+        return this.factory;
+    }
+
+    protected void playStepSound(BlockPos pos, BlockState blockIn) {
+        this.playSound(SoundEvents.SWEET_BERRY_BUSH_PICK_BERRIES, 0.15F, 1.0F);
+    }
+
+    protected SoundEvent getAmbientSound() {
+        return SoundEvents.FOX_AMBIENT;
+    }
+
+    protected SoundEvent getHurtSound(DamageSource damageSourceIn) {
+        return SoundEvents.DOLPHIN_HURT;
+    }
+
+    protected SoundEvent getDeathSound() {
+        return SoundEvents.DOLPHIN_DEATH;
+    }
+
+    protected float getSoundVolume() {
+        return 0.2F;
+    }
+
+    /* TAMEABLE */
+    @Override
+    public InteractionResult mobInteract(Player player, InteractionHand hand) {
+        ItemStack itemstack = player.getItemInHand(hand);
+        Item item = itemstack.getItem();
+
+        Item itemForTaming = Items.SUGAR_CANE;
+
+        if(isFood(itemstack)) {
+            return super.mobInteract(player, hand);
+        }
+
+        if (item == itemForTaming && !isTame()) {
+            if (this.level.isClientSide) {
+                return InteractionResult.CONSUME;
+            } else {
+                if (!player.getAbilities().instabuild) {
+                    itemstack.shrink(1);
+                }
+
+                if (!ForgeEventFactory.onAnimalTame(this, player)) {
+                    if (!this.level.isClientSide) {
+                        super.tame(player);
+                        this.navigation.recomputePath();
+                        this.setTarget(null);
+                        this.level.broadcastEntityEvent(this, (byte)7);
+                        setSitting(true);
+                    }
+                }
+
+                return InteractionResult.SUCCESS;
+            }
+        }
+
+        if(isTame() && !this.level.isClientSide && hand == InteractionHand.MAIN_HAND) {
+            setSitting(!isSitting());
+            return InteractionResult.SUCCESS;
+        }
+
+        if (itemstack.getItem() == itemForTaming) {
+            return InteractionResult.PASS;
+        }
+
+        return super.mobInteract(player, hand);
+    }
+
+    @Override
+    public void readAdditionalSaveData(CompoundTag tag) {
+        super.readAdditionalSaveData(tag);
+        setSitting(tag.getBoolean("isSitting"));
+    }
+
+    @Override
+    public void addAdditionalSaveData(CompoundTag tag) {
+        super.addAdditionalSaveData(tag);
+        tag.putBoolean("isSitting", this.isSitting());
+    }
+
+    @Override
+    protected void defineSynchedData() {
+        super.defineSynchedData();
+        this.entityData.define(SITTING, false);
+    }
+
+    public void setSitting(boolean sitting) {
+        this.entityData.set(SITTING, sitting);
+        this.setOrderedToSit(sitting);
+    }
+
+    public boolean isSitting() {
+        return this.entityData.get(SITTING);
+    }
+
+    @Override
+    public Team getTeam() {
+        return super.getTeam();
+    }
+
+    public boolean canBeLeashed(Player player) {
+        return false;
+    }
+
+    @Override
+    public void setTame(boolean tamed) {
+        super.setTame(tamed);
+        if (tamed) {
+            getAttribute(Attributes.MAX_HEALTH).setBaseValue(10.0D);
+            getAttribute(Attributes.MOVEMENT_SPEED).setBaseValue((double)0.2f);
+        } else {
+            getAttribute(Attributes.MAX_HEALTH).setBaseValue(10.0D);
+            getAttribute(Attributes.MOVEMENT_SPEED).setBaseValue((double)0.2f);
+        }
+    }
 }
\ No newline at end of file
blob - 8b7f8611a7e77260d1fa6e9816a4d69e7b881d71
blob + c5dc9b9c2ae0417fed6e8cd8c1e81db1ccb2bde8
--- src/main/java/com/techsupportred/capybaramod/event/ModEvents.java
+++ src/main/java/com/techsupportred/capybaramod/event/ModEvents.java
@@ -1,17 +1,21 @@
-package com.techsupportred.capybaramod.event;

-

-import com.techsupportred.capybaramod.capybaramod;

-import com.techsupportred.capybaramod.entity.ModEntityTypes;

-import com.techsupportred.capybaramod.entity.custom.CapybaraEntity;

-import net.minecraftforge.event.entity.EntityAttributeCreationEvent;

-import net.minecraftforge.eventbus.api.SubscribeEvent;

-import net.minecraftforge.fml.common.Mod;

-

-@Mod.EventBusSubscriber(modid = capybaramod.MOD_ID, bus = Mod.EventBusSubscriber.Bus.MOD)

-public class ModEvents {

-

-    @SubscribeEvent

-    public static void entityAttributeEvent(EntityAttributeCreationEvent event) {

-        event.put(ModEntityTypes.CAPYBARA.get(), CapybaraEntity.setAttributes());

-    }

-}
\ No newline at end of file
+package com.techsupportred.capybaramod.event;
+
+import com.techsupportred.capybaramod.entity.ModEntityTypes;
+import com.techsupportred.capybaramod.entity.custom.CapybaraEntity;
+import com.techsupportred.capybaramod.capybaramod;
+import net.minecraftforge.event.entity.EntityAttributeCreationEvent;
+import net.minecraftforge.eventbus.api.SubscribeEvent;
+import net.minecraftforge.fml.common.Mod;
+
+public class ModEvents {
+    @Mod.EventBusSubscriber(modid = capybaramod.MOD_ID)
+    public static class ForgeEvents {
+
+    @Mod.EventBusSubscriber(modid = capybaramod.MOD_ID, bus = Mod.EventBusSubscriber.Bus.MOD)
+    public static class ModEventBusEvents {
+        @SubscribeEvent
+        public static void entityAttributeEvent(EntityAttributeCreationEvent event) {
+            event.put(ModEntityTypes.CAPYBARA.get(), CapybaraEntity.setAttributes());
+        }
+    }
+}}
blob - e3b494dece03ee5558c937bb0baf186122d52ea9
blob + f4c7e76b0dd45cc4eec6fcf7d155f903df5617c8
--- src/main/java/com/techsupportred/capybaramod/item/ModItems.java
+++ src/main/java/com/techsupportred/capybaramod/item/ModItems.java
@@ -1,24 +1,23 @@
-package com.techsupportred.capybaramod.item;

-

-import com.techsupportred.capybaramod.capybaramod;

-import com.techsupportred.capybaramod.entity.ModEntityTypes;

-import net.minecraft.world.item.*;

-import net.minecraftforge.common.ForgeSpawnEggItem;

-import net.minecraftforge.eventbus.api.IEventBus;

-import net.minecraftforge.registries.DeferredRegister;

-import net.minecraftforge.registries.ForgeRegistries;

-import net.minecraftforge.registries.RegistryObject;

-

-public class ModItems {

-    public static final DeferredRegister<Item> ITEMS =

-            DeferredRegister.create(ForgeRegistries.ITEMS, capybaramod.MOD_ID);

-

-    public static final RegistryObject<Item> CAPYBARA_SPAWN_EGG = ITEMS.register("capybara_spawn_egg",

-            () -> new ForgeSpawnEggItem(ModEntityTypes.CAPYBARA,0xC4A484, 0x5C4033,

-                    new Item.Properties().tab(CreativeModeTab.TAB_MISC)));

-

-    public static void register(IEventBus eventBus) {

-        ITEMS.register(eventBus);

-    }

-}

-

+package com.techsupportred.capybaramod.item;
+
+import com.techsupportred.capybaramod.capybaramod;
+import com.techsupportred.capybaramod.entity.ModEntityTypes;
+import net.minecraft.world.item.*;
+import net.minecraftforge.common.ForgeSpawnEggItem;
+import net.minecraftforge.eventbus.api.IEventBus;
+import net.minecraftforge.registries.DeferredRegister;
+import net.minecraftforge.registries.ForgeRegistries;
+import net.minecraftforge.registries.RegistryObject;
+
+public class ModItems {
+    public static final DeferredRegister<Item> ITEMS =
+            DeferredRegister.create(ForgeRegistries.ITEMS, capybaramod.MOD_ID);
+
+    public static final RegistryObject<Item> CAPYBARA_SPAWN_EGG = ITEMS.register("capybara_spawn_egg",
+            () -> new ForgeSpawnEggItem(ModEntityTypes.CAPYBARA, 0xC4A484, 0x5C4033,
+                    new Item.Properties().tab(ModCreativeModeTab.CAPYBARA_TAB)));
+
+    public static void register(IEventBus eventBus) {
+        ITEMS.register(eventBus);
+    }
+}
blob - /dev/null
blob + 249dc5b7f42b8b6418f2ac7e5bfa0f24a137fc7c (mode 644)
--- /dev/null
+++ src/main/java/com/techsupportred/capybaramod/item/ModCreativeModeTab.java
@@ -0,0 +1,13 @@
+package com.techsupportred.capybaramod.item;
+
+import net.minecraft.world.item.CreativeModeTab;
+import net.minecraft.world.item.ItemStack;
+
+public class ModCreativeModeTab {
+    public static final CreativeModeTab CAPYBARA_TAB = new CreativeModeTab("capybaratab") {
+        @Override
+        public ItemStack makeIcon() {
+            return new ItemStack(ModItems.CAPYBARA_SPAWN_EGG.get());
+        }
+    };
+}
blob - 860402dd316d90cef3f3a50edb0bf59b38ca2427
blob + def28fd4d20431aab51a6d4e58f8fd866d19da2a
--- src/main/resources/META-INF/mods.toml
+++ src/main/resources/META-INF/mods.toml
@@ -1,62 +1,66 @@
-# This is an example mods.toml file. It contains the data relating to the loading mods.

-# There are several mandatory fields (#mandatory), and many more that are optional (#optional).

-# The overall format is standard TOML format, v0.5.0.

-# Note that there are a couple of TOML lists in this file.

-# Find more information on toml format here:  https://github.com/toml-lang/toml

-# The name of the mod loader type to load - for regular FML @Mod mods it should be javafml

-modLoader="javafml" #mandatory

-# A version range to match for said mod loader - for regular FML @Mod it will be the forge version

-loaderVersion="[40,)" #mandatory This is typically bumped every Minecraft version by Forge. See our download page for lists of versions.

-# The license for you mod. This is mandatory metadata and allows for easier comprehension of your redistributive properties.

-# Review your options at https://choosealicense.com/. All rights reserved is the default copyright stance, and is thus the default here.

-license="MIT"

-# A URL to refer people to when problems occur with this mod

-#issueTrackerURL="https://change.me.to.your.issue.tracker.example.invalid/" #optional

-# A list of mods - how many allowed here is determined by the individual mod loader

-[[mods]] #mandatory

-# The modid of the mod

-modId="capybaramod" #mandatory

-# The version number of the mod - there's a few well known ${} variables useable here or just hardcode it

-# ${file.jarVersion} will substitute the value of the Implementation-Version as read from the mod's JAR file metadata

-# see the associated build.gradle script for how to populate this completely automatically during a build

-version="0.0.1" #mandatory

- # A display name for the mod

-displayName="capybara" #mandatory

-# A URL to query for updates for this mod. See the JSON update specification https://mcforge.readthedocs.io/en/latest/gettingstarted/autoupdate/

-#updateJSONURL="https://change.me.example.invalid/updates.json" #optional

-# A URL for the "homepage" for this mod, displayed in the mod UI

-#displayURL="https://change.me.to.your.mods.homepage.example.invalid/" #optional

-# A file name (in the root of the mod JAR) containing a logo for display

-logoFile="examplemod.png" #optional

-# A text field displayed in the mod UI

-credits="Thanks for this example mod goes to Java" #optional

-# A text field displayed in the mod UI

-authors="TechSupportRed" #optional

-# The description text for the mod (multi line!) (#mandatory)

-description='''

-This is a long form description of the mod. You can write whatever you want here

-

-Have some lorem ipsum.

-

-Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed mollis lacinia magna. Orci varius natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Sed sagittis luctus odio eu tempus. Interdum et malesuada fames ac ante ipsum primis in faucibus. Pellentesque volutpat ligula eget lacus auctor sagittis. In hac habitasse platea dictumst. Nunc gravida elit vitae sem vehicula efficitur. Donec mattis ipsum et arcu lobortis, eleifend sagittis sem rutrum. Cras pharetra quam eget posuere fermentum. Sed id tincidunt justo. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

-'''

-# A dependency - use the . to indicate dependency for a specific modid. Dependencies are optional.

-[[dependencies.capybaramod]] #optional

-    # the modid of the dependency

-    modId="forge" #mandatory

-    # Does this dependency have to exist - if not, ordering below must be specified

-    mandatory=true #mandatory

-    # The version range of the dependency

-    versionRange="[40,)" #mandatory

-    # An ordering relationship for the dependency - BEFORE or AFTER required if the relationship is not mandatory

-    ordering="NONE"

-    # Side this dependency is applied on - BOTH, CLIENT or SERVER

-    side="BOTH"

-# Here's another dependency

-[[dependencies.capybaramod]]

-    modId="minecraft"

-    mandatory=true

-# This version range declares a minimum of the current minecraft version up to but not including the next major version

-    versionRange="[1.19.2,1.20)"

-    ordering="NONE"

-    side="BOTH"

+# This is an example mods.toml file. It contains the data relating to the loading mods.
+# There are several mandatory fields (#mandatory), and many more that are optional (#optional).
+# The overall format is standard TOML format, v0.5.0.
+# Note that there are a couple of TOML lists in this file.
+# Find more information on toml format here:  https://github.com/toml-lang/toml
+# The name of the mod loader type to load - for regular FML @Mod mods it should be javafml
+modLoader="javafml" #mandatory
+# A version range to match for said mod loader - for regular FML @Mod it will be the forge version
+loaderVersion="[41,)" #mandatory This is typically bumped every Minecraft version by Forge. See our download page for lists of versions.
+# The license for you mod. This is mandatory metadata and allows for easier comprehension of your redistributive properties.
+# Review your options at https://choosealicense.com/. All rights reserved is the default copyright stance, and is thus the default here.
+license="MIT License"
+# A URL to refer people to when problems occur with this mod
+#issueTrackerURL="https://change.me.to.your.issue.tracker.example.invalid/" #optional
+# A list of mods - how many allowed here is determined by the individual mod loader
+[[mods]] #mandatory
+# The modid of the mod
+modId="capybaramod" #mandatory
+# The version number of the mod - there's a few well known ${} variables useable here or just hardcode it
+# ${file.jarVersion} will substitute the value of the Implementation-Version as read from the mod's JAR file metadata
+# see the associated build.gradle script for how to populate this completely automatically during a build
+version="0.0.2-1.19.2" #mandatory
+ # A display name for the mod
+displayName="Capybara Mod" #mandatory
+# A URL to query for updates for this mod. See the JSON update specification https://mcforge.readthedocs.io/en/latest/gettingstarted/autoupdate/
+#updateJSONURL="https://change.me.example.invalid/updates.json" #optional
+# A URL for the "homepage" for this mod, displayed in the mod UI
+#displayURL="https://change.me.to.your.mods.homepage.example.invalid/" #optional
+# A file name (in the root of the mod JAR) containing a logo for display
+logoFile="examplemod.png" #optional
+# A text field displayed in the mod UI
+credits="Capybara Mod Forge Official" #optional
+# A text field displayed in the mod UI
+authors="TechSupportRed" #optional
+# Display Test controls the display for your mod in the server connection screen
+# MATCH_VERSION means that your mod will cause a red X if the versions on client and server differ. This is the default behaviour and should be what you choose if you have server and client elements to your mod.
+# IGNORE_SERVER_VERSION means that your mod will not cause a red X if it's present on the server but not on the client. This is what you should use if you're a server only mod.
+# IGNORE_ALL_VERSION means that your mod will not cause a red X if it's present on the client or the server. This is a special case and should only be used if your mod has no server component.
+# NONE means that no display test is set on your mod. You need to do this yourself, see IExtensionPoint.DisplayTest for more information. You can define any scheme you wish with this value.
+# IMPORTANT NOTE: this is NOT an instruction as to which environments (CLIENT or DEDICATED SERVER) your mod loads on. Your mod should load (and maybe do nothing!) whereever it finds itself.
+#displayTest="MATCH_VERSION" # MATCH_VERSION is the default if nothing is specified (#optional)
+
+# The description text for the mod (multi line!) (#mandatory)
+description='''
+The Official Capybara Mod! Adds capybaras that you can tame with sugar cane and breed with apples!
+'''
+# A dependency - use the . to indicate dependency for a specific modid. Dependencies are optional.
+[[dependencies.capybaramod]] #optional
+    # the modid of the dependency
+    modId="forge" #mandatory
+    # Does this dependency have to exist - if not, ordering below must be specified
+    mandatory=true #mandatory
+    # The version range of the dependency
+    versionRange="[41,)" #mandatory
+    # An ordering relationship for the dependency - BEFORE or AFTER required if the relationship is not mandatory
+    ordering="NONE"
+    # Side this dependency is applied on - BOTH, CLIENT or SERVER
+    side="BOTH"
+# Here's another dependency
+[[dependencies.capybaramod]]
+    modId="minecraft"
+    mandatory=true
+# This version range declares a minimum of the current minecraft version up to but not including the next major version
+    versionRange="[1.19.2,1.20)"
+    ordering="NONE"
+    side="BOTH"
blob - /dev/null
blob + ba2ee1bd01a78cf8da0573c6cde027a5c0608412 (mode 644)
--- /dev/null
+++ src/main/resources/META-INF/accesstransformer.cfg
@@ -0,0 +1,2 @@
+public net.minecraft.world.level.levelgen.structure.pools.StructureTemplatePool f_210560_ # templates
+public-f net.minecraft.world.level.levelgen.structure.pools.StructureTemplatePool f_210559_ # rawTemplates
\ No newline at end of file
blob - f58aa56e10be890f779eec860ba32a62d2fcea6c
blob + caee515e0534ad734dc7f0924fbfdba7bc7915c9
--- src/main/resources/assets/capybaramod/lang/en_us.json
+++ src/main/resources/assets/capybaramod/lang/en_us.json
@@ -1,3 +1,5 @@
 {

-  "item.capybaramod.capybara_spawn_egg": "Capybara Spawn Egg"

+  "item.capybaramod.capybara_spawn_egg": "Capybara Spawn Egg",

+

+  "itemGroup.capybaratab": "Capybara Tutorial Tab"

 }
\ No newline at end of file
blob - 38194e8c1dbc456128e907840a4422c3825fb65e
blob + d1aaa9d6efdd855226de4eaa4f770bde2465d5fb
--- src/main/resources/assets/capybaramod/models/item/capybara_spawn_egg.json
+++ src/main/resources/assets/capybaramod/models/item/capybara_spawn_egg.json
@@ -1,3 +1,3 @@
-{

-  "parent": "minecraft:item/template_spawn_egg"

+{
+  "parent": "minecraft:item/template_spawn_egg"
 }
\ No newline at end of file
blob - /dev/null
blob + 1f1e859464030296a7598c612467da8e52620cb7 (mode 644)
Binary files /dev/null and src/main/resources/assets/capybaramod/textures/entity/capybara_texture.png differ
blob - /dev/null
blob + 109087838e63077c64dc28d34c6d01c31991a4f4 (mode 644)
Binary files /dev/null and src/main/resources/assets/capybaramod/textures/entity/villager/profession/jumpy_master.png differ
blob - 2f974103773ecc4ebbff0fa68d97109c4253d778
blob + b643e13f8884acd18e03d2660f7ca4c59021d82e
--- src/main/resources/pack.mcmeta
+++ src/main/resources/pack.mcmeta
@@ -1,8 +1,8 @@
-{

-    "pack": {

-        "description": "examplemod resources",

-        "pack_format": 9,

-        "forge:resource_pack_format": 8,

-        "forge:data_pack_format": 9

-    }

-}

+{
+    "pack": {
+        "description": "examplemod resources",
+        "pack_format": 9,
+        "forge:resource_pack_format": 9,
+        "forge:data_pack_format": 10
+    }
+}
blob - /dev/null
blob + c00901d70e37cd30adca38ed2bd9fb5adcec3f0b (mode 644)
--- /dev/null
+++ src/main/resources/data/capybaramod/forge/biome_modifier/spawn_capybara.json
@@ -0,0 +1,12 @@
+{
+  "type": "forge:add_spawns",
+  "biomes": [
+    "minecraft:jungle"
+  ],
+  "spawners": {
+    "type": "capybaramod:capybara",
+    "weight": 150,
+    "minCount": 1,
+    "maxCount": 3
+  }
+}
\ No newline at end of file