mirror of
https://github.com/GTNewHorizons/Chisel.git
synced 2026-11-22 13:19:52 +00:00
Add IMC for adding/removing variations and registering oredict
This commit is contained in:
1 parent
c527d5d7c5
commit
968782ba0e
3 files changed
+124
No files matched your search
@@ -0,0 +1,59 @@
|
||||
package com.cricketcraft.chisel.api;
|
||||
|
||||
import com.cricketcraft.chisel.Chisel;
|
||||
|
||||
/**
|
||||
* Use the enum constants (using {@link #key} or calling {@link #toString()}) in this class as keys for IMC messages sent to chisel
|
||||
*/
|
||||
public enum IMC {
|
||||
|
||||
/**
|
||||
* Adds a variation to a group.
|
||||
*
|
||||
* Use this to add a variation to a group. String syntax:
|
||||
* <p>
|
||||
* groupname|blockname|meta
|
||||
* <p>
|
||||
* An example would be {@code "mygroup|minecraft:dirt|1"} and this will add the vanilla dirt block with metadata 1 to the "mygroup" group, creating that group if need be.
|
||||
*/
|
||||
ADD_VARIATION("variation:add"),
|
||||
|
||||
/**
|
||||
* Removes a variation from a group.
|
||||
*
|
||||
* Use this to remove a variation from a group. String syntax:
|
||||
* <p>
|
||||
* groupname|blockname|meta
|
||||
* <p>
|
||||
* An example would be {@code "mygroup|minecraft:dirt|1"} and this will add the vanilla dirt block with metadata 1 to the "mygroup" group, creating that group if need be.
|
||||
*/
|
||||
REMOVE_VARIATION("variation:remove"),
|
||||
|
||||
/**
|
||||
* Registers an oredict name to a group. This can be used to automatically add all blocks with this oredict name to a group. String syntax:
|
||||
* <p>
|
||||
* groupname|oredictname
|
||||
* <p>
|
||||
* An example would be {@code "mygroup|plankWood"} which will add all blocks registered in the oredict as "plankWood" to your group called "mygroup".
|
||||
*/
|
||||
REGISTER_GROUP_ORE("group:ore");
|
||||
|
||||
/**
|
||||
* The IMC message key for this message type.
|
||||
*/
|
||||
public final String key;
|
||||
|
||||
IMC(String key) {
|
||||
this.key = key;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return key;
|
||||
}
|
||||
|
||||
/**
|
||||
* The modid of Chisel so you can easily send IMC to this mod.
|
||||
*/
|
||||
public static final String CHISEL_MODID = Chisel.MOD_ID;
|
||||
}
|
||||
Reference in new issue
Block a user