Set up mod info and stuff.

This commit is contained in:
Hazel Layne Aranda 2021-02-23 02:27:52 -05:00
parent f4b08c13ef
commit 7729cd9b90
7 changed files with 28 additions and 57 deletions

View File

@ -8,9 +8,9 @@ org.gradle.jvmargs=-Xmx1G
loader_version=0.11.0
# Mod Properties
mod_version = 1.0.0
maven_group = com.example
archives_base_name = fabric-example-mod
maven_group = net.hazelra
archives_base_name = traincarts
mod_version = 0.1.0
# Dependencies
# currently not on the main fabric site, check on the maven: https://maven.fabricmc.net/net/fabricmc/fabric-api/fabric-api

View File

@ -1,14 +0,0 @@
package net.fabricmc.example;
import net.fabricmc.api.ModInitializer;
public class ExampleMod implements ModInitializer {
@Override
public void onInitialize() {
// This code runs as soon as Minecraft is in a mod-load-ready state.
// However, some things (like resources) may still be uninitialized.
// Proceed with mild caution.
System.out.println("Hello Fabric world!");
}
}

View File

@ -1,15 +0,0 @@
package net.fabricmc.example.mixin;
import net.minecraft.client.gui.screen.TitleScreen;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.injection.At;
import org.spongepowered.asm.mixin.injection.Inject;
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
@Mixin(TitleScreen.class)
public class ExampleMixin {
@Inject(at = @At("HEAD"), method = "init()V")
private void init(CallbackInfo info) {
System.out.println("This line is printed by an example mod mixin!");
}
}

View File

@ -0,0 +1,12 @@
package net.hazelra.traincarts;
import net.fabricmc.api.ModInitializer;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
public class TraincartsMod implements ModInitializer {
public static final Logger log = LogManager.getLogger("Train Carts");
public static final String logPrefix = "[Train Carts]";
public void onInitialize() { log.info(logPrefix + "Hello, blocky world!"); }
}

View File

Before

Width:  |  Height:  |  Size: 453 B

After

Width:  |  Height:  |  Size: 453 B

View File

@ -1,37 +1,28 @@
{
"schemaVersion": 1,
"id": "modid",
"id": "traincarts",
"version": "${version}",
"name": "Example Mod",
"description": "This is an example description! Tell everyone what your mod is about!",
"authors": [
"Me!"
],
"name": "Train Carts",
"description": "Allows linking trains together with chains.",
"authors": ["Hazel Snider"],
"contact": {
"homepage": "https://fabricmc.net/",
"sources": "https://github.com/FabricMC/fabric-example-mod"
"homepage": "https://github.com/hazelLanes/traincarts",
"sources": "https://github.com/hazelLanes/traincarts"
},
"license": "CC0-1.0",
"icon": "assets/modid/icon.png",
"license": "MIT",
"icon": "assets/traincarts/icon.png",
"environment": "*",
"entrypoints": {
"main": [
"net.fabricmc.example.ExampleMod"
]
"main": ["net.hazelra.traincarts.TraincartsMod"]
},
"mixins": [
"modid.mixins.json"
],
"mixins": [],
"depends": {
"fabricloader": ">=0.7.4",
"fabric": "*",
"minecraft": "1.16.x"
},
"suggests": {
"another-mod": "*"
}
}

View File

@ -1,13 +1,10 @@
{
"required": true,
"minVersion": "0.8",
"package": "net.fabricmc.example.mixin",
"package": "net.hazelra.traincarts.mixin",
"compatibilityLevel": "JAVA_8",
"mixins": [
],
"client": [
"ExampleMixin"
],
"mixins": [],
"client": ["ExampleMixin"],
"injectors": {
"defaultRequire": 1
}