-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
yeah no nevermind "finished" was a lie
- Loading branch information
Showing
11 changed files
with
113 additions
and
9 deletions.
There are no files selected for viewing
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
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
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
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
60 changes: 60 additions & 0 deletions
60
src/main/kotlin/org/polyfrost/crashpatch/mixins/MixinPlugin.kt
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,60 @@ | ||
package org.polyfrost.crashpatch.mixins | ||
|
||
//#if MC >= 1.16.5 || FABRIC | ||
//$$ import org.objectweb.asm.tree.ClassNode | ||
//#endif | ||
|
||
import org.spongepowered.asm.mixin.extensibility.IMixinConfigPlugin | ||
import org.spongepowered.asm.mixin.extensibility.IMixinInfo | ||
|
||
class MixinPlugin : IMixinConfigPlugin { | ||
|
||
override fun getMixins(): MutableList<String> { | ||
val result = mutableListOf<String>() | ||
|
||
//#if FORGE | ||
result.add("MixinGuiDupesFound") | ||
result.add("MixinTileEntityRendererDispatcher") | ||
//#endif | ||
|
||
return result | ||
} | ||
|
||
override fun getRefMapperConfig(): String? = null | ||
override fun shouldApplyMixin(targetClassName: String, mixinClassName: String): Boolean = true | ||
|
||
override fun onLoad(mixinPackage: String) { | ||
// no-op | ||
} | ||
|
||
override fun acceptTargets(myTargets: MutableSet<String>, otherTargets: MutableSet<String>) { | ||
// no-op | ||
} | ||
|
||
override fun preApply( | ||
targetClassName: String, | ||
//#if MC >= 1.16.5 || FABRIC | ||
//$$ targetClass: ClassNode, | ||
//#else | ||
targetClass: org.spongepowered.asm.lib.tree.ClassNode, | ||
//#endif | ||
mixinClassName: String, | ||
mixinInfo: IMixinInfo | ||
) { | ||
// no-op | ||
} | ||
|
||
override fun postApply( | ||
targetClassName: String, | ||
//#if MC >= 1.16.5 || FABRIC | ||
//$$ targetClass: ClassNode, | ||
//#else | ||
targetClass: org.spongepowered.asm.lib.tree.ClassNode, | ||
//#endif | ||
mixinClassName: String, | ||
mixinInfo: IMixinInfo | ||
) { | ||
// no-op | ||
} | ||
|
||
} |
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": "${mod_id}", | ||
"version": "${mod_version}", | ||
"name": "${mod_name}", | ||
"authors": [ | ||
"Polyfrost", | ||
"SkyClient" | ||
], | ||
"contact": { | ||
"issues": "https://github.com/Polyfrost/${mod_name}/issues", | ||
"sources": "https://github.com/Polyfrost/${mod_name}" | ||
}, | ||
"license": "GPL-3.0-or-later", | ||
"environment": "*", | ||
"entrypoints": { | ||
"client": [ | ||
{ | ||
"adapter": "kotlin", | ||
"value": "org.polyfrost.crashpatch.CrashPatch" | ||
} | ||
] | ||
}, | ||
"mixins": [ | ||
"mixins.${mod_id}.json" | ||
], | ||
"depends": { | ||
"fabricloader": ">=0.15.11", | ||
"fabric-language-kotlin": "*" | ||
} | ||
} |
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