aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/shcm/shsupercm/fabric/citresewn/cit/CIT.java
diff options
context:
space:
mode:
authorSHsuperCM <shsupercm@gmail.com>2022-03-26 11:03:40 +0300
committerSHsuperCM <shsupercm@gmail.com>2022-03-26 11:03:40 +0300
commitacc5caebf0763915d216fb35f6e37b9ad3b7f3ff (patch)
treea124ad97a41f1ae8620451fb2ac46a2611cdfc9b /src/main/java/shcm/shsupercm/fabric/citresewn/cit/CIT.java
parent0484498863626dc57d55d381b7b394b5cc9234c2 (diff)
downloadCITResewn-acc5caebf0763915d216fb35f6e37b9ad3b7f3ff.tar.gz
CITResewn-acc5caebf0763915d216fb35f6e37b9ad3b7f3ff.tar.bz2
CITResewn-acc5caebf0763915d216fb35f6e37b9ad3b7f3ff.zip
Implemented fallback behavior and fixed weight bug
Diffstat (limited to 'src/main/java/shcm/shsupercm/fabric/citresewn/cit/CIT.java')
-rw-r--r--src/main/java/shcm/shsupercm/fabric/citresewn/cit/CIT.java8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/main/java/shcm/shsupercm/fabric/citresewn/cit/CIT.java b/src/main/java/shcm/shsupercm/fabric/citresewn/cit/CIT.java
index 7c7ba5b..fa00c08 100644
--- a/src/main/java/shcm/shsupercm/fabric/citresewn/cit/CIT.java
+++ b/src/main/java/shcm/shsupercm/fabric/citresewn/cit/CIT.java
@@ -32,12 +32,18 @@ public class CIT<T extends CITType> {
*/
public final int weight;
- public CIT(Identifier propertiesIdentifier, String packName, T type, CITCondition[] conditions, int weight) {
+ /**
+ * Identifier of the cit to fallback to if this one doesn't load.
+ */
+ public final Identifier fallback;
+
+ public CIT(Identifier propertiesIdentifier, String packName, T type, CITCondition[] conditions, int weight, Identifier fallback) {
this.propertiesIdentifier = propertiesIdentifier;
this.packName = packName;
this.type = type;
this.conditions = conditions;
this.weight = weight;
+ this.fallback = fallback;
}
/**