-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
17 changed files
with
126 additions
and
14 deletions.
There are no files selected for viewing
File renamed without changes.
5 changes: 5 additions & 0 deletions
5
command-common/src/main/java/band/kessoku/lib/command/KessokuCommand.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
package band.kessoku.lib.command; | ||
|
||
public class KessokuCommand { | ||
public static final String MOD_ID = "kessoku_command"; | ||
} |
2 changes: 1 addition & 1 deletion
2
.../command/events/CommandRegistryEvent.java → ...mand/api/events/CommandRegistryEvent.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
command-fabric/src/main/java/band/kessoku/lib/command/KessokuCommandEntrypoint.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package band.kessoku.lib.command; | ||
|
||
import band.kessoku.lib.command.impl.KessokuCommandImpl; | ||
import net.fabricmc.api.ModInitializer; | ||
|
||
public class KessokuCommandEntrypoint implements ModInitializer { | ||
@Override | ||
public void onInitialize() { | ||
KessokuCommandImpl.registerCommonEvents(); | ||
} | ||
} |
10 changes: 4 additions & 6 deletions
10
.../command/KessokuCommandApiEntrypoint.java → .../lib/command/impl/KessokuCommandImpl.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...fabric/src/main/resources/fabric.mod.json → ...fabric/src/main/resources/fabric.mod.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
15 changes: 15 additions & 0 deletions
15
command-neo/src/main/java/band/kessoku/lib/command/KessokuCommandEntrypoint.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package band.kessoku.lib.command; | ||
|
||
import band.kessoku.lib.command.impl.KessokuCommandImpl; | ||
import net.neoforged.bus.api.IEventBus; | ||
import net.neoforged.fml.common.Mod; | ||
import net.neoforged.neoforge.common.NeoForge; | ||
|
||
@Mod(KessokuCommand.MOD_ID) | ||
public class KessokuCommandEntrypoint { | ||
public KessokuCommandEntrypoint(IEventBus modEventBus) { | ||
var forgeEventBus = NeoForge.EVENT_BUS; | ||
|
||
KessokuCommandImpl.registerCommonEvents(forgeEventBus); | ||
} | ||
} |
14 changes: 14 additions & 0 deletions
14
command-neo/src/main/java/band/kessoku/lib/command/impl/KessokuCommandImpl.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
package band.kessoku.lib.command.impl; | ||
|
||
import band.kessoku.lib.command.api.events.CommandRegistryEvent; | ||
import band.kessoku.lib.event.util.NeoEventUtils; | ||
import net.neoforged.bus.api.IEventBus; | ||
import net.neoforged.neoforge.event.RegisterCommandsEvent; | ||
|
||
public class KessokuCommandImpl { | ||
public static void registerCommonEvents(IEventBus forgeEventBus) { | ||
NeoEventUtils.registerEvent(forgeEventBus, RegisterCommandsEvent.class, event -> { | ||
CommandRegistryEvent.EVENT.invoker().register(event.getDispatcher(), event.getBuildContext(), event.getCommandSelection()); | ||
}); | ||
} | ||
} |
29 changes: 29 additions & 0 deletions
29
command-neo/src/main/resources/META-INF/neoforge.mods.toml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
modLoader = "javafml" | ||
loaderVersion = "[4,)" | ||
license = "LGPL-3.0-only" | ||
issueTrackerURL = "https://github.com/KessokuTeaTime/KessokuLib/issues" | ||
|
||
[[mods]] | ||
modId = "kessoku_command" | ||
version = "${version}" | ||
displayName = "Kessoku Command API" | ||
description = ''' | ||
About command registries. | ||
''' | ||
logoFile = "icon.png" | ||
authors = "Kessoku Tea Time" | ||
displayURL = "https://modrinth.com/mod/kessoku-lib" | ||
|
||
[[dependencies.kessoku-event-base]] | ||
modId = "neoforge" | ||
type = "required" | ||
versionRange = "[21.0,)" | ||
ordering = "NONE" | ||
side = "BOTH" | ||
|
||
[[dependencies.kessoku-event-base]] | ||
modId = "minecraft" | ||
type = "required" | ||
versionRange = "[1.21,)" | ||
ordering = "NONE" | ||
side = "BOTH" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
lifecycle-events-fabric/src/main/resources/fabric.mod.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
{ | ||
"schemaVersion": 1, | ||
"id": "kessoku_lifecycle_events", | ||
"version": "${version}", | ||
"name": "Kessoku Command API", | ||
"description": "About command registries.", | ||
"authors": [ | ||
"Kessoku Tea Time" | ||
], | ||
"contact": { | ||
"homepage": "https://modrinth.com/mod/kessoku-lib", | ||
"sources": "https://github.com/KessokuTeaTime/KessokuLib", | ||
"issues": "https://github.com/KessokuTeaTime/KessokuLib/issues" | ||
}, | ||
"license": "LGPL-3.0-only", | ||
"icon": "icon.png", | ||
"environment": "*", | ||
"depends": { | ||
"fabricloader": ">=0.16.0", | ||
"minecraft": "1.21", | ||
"java": ">=21", | ||
"fabric-api": "*" | ||
}, | ||
"custom": { | ||
"modmenu": { | ||
"badges": [ | ||
"library" | ||
] | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters