Compare commits

...

2 commits

Author SHA1 Message Date
572b8e9783
oh hi it does something 2025-06-26 19:15:40 +02:00
d2066d8e5d
ups forgot one 2025-06-25 20:04:01 +02:00
3 changed files with 16 additions and 2 deletions

View file

@ -1,5 +1,8 @@
package xyz.minecommune.micomc;
import net.fabricmc.fabric.api.command.v2.CommandRegistrationCallback;
import net.minecraft.server.command.CommandManager;
import net.minecraft.text.Text;
import org.quiltmc.loader.api.ModContainer;
import org.quiltmc.qsl.base.api.entrypoint.ModInitializer;
import org.slf4j.Logger;
@ -10,10 +13,21 @@ public class MicoMc implements ModInitializer {
// This logger is used to write text to the console and the log file.
// It is considered best practice to use your mod name as the logger's name.
// That way, it's clear which mod wrote info, warnings, and errors.
public static final Logger LOGGER = LoggerFactory.getLogger("Example Mod");
public static final Logger LOGGER = LoggerFactory.getLogger("MicoMc");
@Override
public void onInitialize(ModContainer mod) {
LOGGER.info("Hello Quilt world from {}!", mod.metadata().name());
CommandRegistrationCallback.EVENT.register(
(dispatcher, registryAccess, enviroment) ->
dispatcher.register(
CommandManager.literal("foo").executes(context -> {
context
.getSource()
.sendFeedback(() -> Text.literal("hii"), false);
return 1;
})
)
);
}
}

View file

@ -35,5 +35,5 @@
}
]
},
"mixin": "mico-mod.mixins.json"
"mixin": "micomc.mixins.json"
}