Skip to content

Commit

Permalink
Add Cicada compat
Browse files Browse the repository at this point in the history
Signed-off-by: Noaaan <[email protected]>
  • Loading branch information
Noaaan committed Jul 2, 2024
1 parent ccb000c commit 40c99e7
Show file tree
Hide file tree
Showing 5 changed files with 76 additions and 1 deletion.
3 changes: 3 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ repositories {
maven { url = "https://maven.jamieswhiteshirt.com/libs-release" }
maven { url = "https://api.modrinth.com/maven/" }
maven { url = "https://maven.nucleoid.xyz/" }
maven { url = "https://maven.enjarai.dev/releases" }

mavenCentral()
}
Expand Down Expand Up @@ -76,6 +77,8 @@ dependencies {

// Explosive Enhancement
modApi("maven.modrinth:explosive-enhancement:${project.ee_version}")

modImplementation "nl.enjarai:cicada-lib:${project.cicada_version}"
}

sourceSets {
Expand Down
4 changes: 3 additions & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -47,4 +47,6 @@ cpa_version = 1.0.0
emi_version=1.1.7+1.21
# Explosive Enhancement
# https://modrinth.com/mod/explosive-enhancement
ee_version=1.2.3-1.21.0
ee_version=1.2.3-1.21.0
# https://maven.enjarai.dev/#/releases/nl/enjarai/cicada-lib
cicada_version=0.8.1+1.21-and-above
13 changes: 13 additions & 0 deletions src/main/java/nourl/mythicmetals/compat/CicadaInit.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
package nourl.mythicmetals.compat;

import nl.enjarai.cicada.api.conversation.ConversationManager;
import nl.enjarai.cicada.api.util.*;

public class CicadaInit implements CicadaEntrypoint {
@Override
public void registerConversations(ConversationManager conversationManager) {
conversationManager.registerSource(
JsonSource.fromResource("data/cicada/meme_metals/conversations.json"), ProperLogger.getLogger("MythicMetals")::info
);
}
}
54 changes: 54 additions & 0 deletions src/main/resources/data/cicada/meme_metals/conversations.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
{
"mod_id": "mythicmetals",
"conversations": {
"cicada:greetings": {
"lines": [
{
"text": "A Cicada? Free Gray Dye...",
"order": 64
}
]
},
"mythicmetals:independence_day": {
"priority": {
"priority": 1000,
"override": 100
},
"condition": {
"type": "cicada:date",
"month": 5,
"day": 17
},
"lines": [
{
"order": 0,
"text": "Gratulerer med dagen!"
}
]
},
"cicada:good_old_days": {
"lines": [
{
"text": "Stop babbling!... need to mine more Unobtainium.",
"order": 64
}
]
},
"cicada:christmas": {
"lines": [
{
"text": "Happy holidays!",
"order": 64
}
]
},
"cicada:new_year": {
"lines": [
{
"text": "\uD83C\uDF86\uD83C\uDF86\uD83C\uDF86",
"order": 39
}
]
}
}
}
3 changes: 3 additions & 0 deletions src/main/resources/fabric.mod.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@
],
"cardinal-components-entity": [
"nourl.mythicmetals.MythicMetals"
],
"cicada": [
"nourl.mythicmetals.compat.CicadaInit"
]
},
"mixins": [
Expand Down

0 comments on commit 40c99e7

Please sign in to comment.