mirror of
https://github.com/TeamMidnightDust/MidnightLib.git
synced 2025-12-15 09:05:08 +01:00
Compare commits
2 Commits
d954b32461
...
84fc1d0d24
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
84fc1d0d24 | ||
|
|
0d2c952a54 |
@@ -1,14 +0,0 @@
|
||||
package eu.midnightdust.lib.util;
|
||||
|
||||
import java.awt.Color;
|
||||
|
||||
public class MidnightColorUtil {
|
||||
/**
|
||||
* @param colorStr e.g. "FFFFFF" or "#FFFFFF"
|
||||
* @return Color as RGB
|
||||
*/
|
||||
public static Color hex2Rgb(String colorStr) {
|
||||
try { return Color.decode("#" + colorStr.replace("#", ""));
|
||||
} catch (Exception ignored) { return Color.BLACK; }
|
||||
}
|
||||
}
|
||||
@@ -1,10 +1,10 @@
|
||||
{
|
||||
"schemaVersion": 1,
|
||||
"id": "testmod",
|
||||
"id": "modid",
|
||||
"version": "${version}",
|
||||
|
||||
"name": "MidnightLib Example",
|
||||
"description": "Wow, you can do so much.",
|
||||
"name": "MidnightLib Test Mod",
|
||||
"description": "Example Mod for Team MidnightDust's mods.",
|
||||
"authors": [ "MidnightDust" ],
|
||||
|
||||
"license": "CC0",
|
||||
|
||||
@@ -43,7 +43,7 @@ loom {
|
||||
create('midnightlib') {
|
||||
sourceSet sourceSets.main
|
||||
}
|
||||
create('testmod') {
|
||||
create('modid') { // test mod
|
||||
sourceSet sourceSets.test
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,9 +3,10 @@ package eu.midnightdust.test.neoforge;
|
||||
import eu.midnightdust.test.config.MidnightConfigExample;
|
||||
import net.neoforged.fml.common.Mod;
|
||||
|
||||
@Mod("testmod")
|
||||
@Mod(MLExampleNeoForge.MODID)
|
||||
public class MLExampleNeoForge {
|
||||
public static final String MODID = "modid";
|
||||
public MLExampleNeoForge() {
|
||||
MidnightConfigExample.init("modid", MidnightConfigExample.class);
|
||||
MidnightConfigExample.init(MODID, MidnightConfigExample.class);
|
||||
}
|
||||
}
|
||||
@@ -4,29 +4,29 @@ loaderVersion = "[2,)"
|
||||
license = "MIT License"
|
||||
|
||||
[[mods]]
|
||||
modId = "testmod"
|
||||
modId = "modid"
|
||||
version = "${version}"
|
||||
displayName = "Example Mod"
|
||||
displayName = "MidnightLib Test Mod"
|
||||
authors = "TeamMidnightDust, Motschen"
|
||||
description = '''
|
||||
Example Mod for Team MidnightDust's mods.
|
||||
'''
|
||||
|
||||
[[dependencies.testmod]]
|
||||
[[dependencies.modid]]
|
||||
modId = "neoforge"
|
||||
mandatory = true
|
||||
versionRange = "[20.5,)"
|
||||
ordering = "NONE"
|
||||
side = "BOTH"
|
||||
|
||||
[[dependencies.testmod]]
|
||||
[[dependencies.modid]]
|
||||
modId = "minecraft"
|
||||
mandatory = true
|
||||
versionRange = "[1.20.5,)"
|
||||
ordering = "NONE"
|
||||
side = "BOTH"
|
||||
|
||||
[[dependencies.testmod]]
|
||||
[[dependencies.modid]]
|
||||
modId = "midnightlib"
|
||||
mandatory = true
|
||||
versionRange = "[1.0,)"
|
||||
|
||||
Reference in New Issue
Block a user