-
Notifications
You must be signed in to change notification settings - Fork 37
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
5 changed files
with
39 additions
and
0 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
23 changes: 23 additions & 0 deletions
23
...od/acgaming/universaltweaks/tweaks/entities/armorstand/mixin/UTArmedArmorStandsMixin.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,23 @@ | ||
package mod.acgaming.universaltweaks.tweaks.entities.armorstand.mixin; | ||
|
||
import net.minecraft.entity.item.EntityArmorStand; | ||
|
||
import mod.acgaming.universaltweaks.config.UTConfigTweaks; | ||
import org.spongepowered.asm.mixin.Mixin; | ||
import org.spongepowered.asm.mixin.Shadow; | ||
import org.spongepowered.asm.mixin.injection.At; | ||
import org.spongepowered.asm.mixin.injection.Inject; | ||
import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; | ||
|
||
@Mixin(EntityArmorStand.class) | ||
public abstract class UTArmedArmorStandsMixin | ||
{ | ||
@Shadow | ||
protected abstract void setShowArms(boolean showArms); | ||
|
||
@Inject(method = "getShowArms", at = @At("HEAD")) | ||
public void utArmedArmorStands(CallbackInfoReturnable<Boolean> cir) | ||
{ | ||
if (UTConfigTweaks.ENTITIES.utArmedArmorStandsToggle) this.setShowArms(true); | ||
} | ||
} |
7 changes: 7 additions & 0 deletions
7
src/main/resources/mixins.tweaks.entities.armedarmorstands.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,7 @@ | ||
{ | ||
"package": "mod.acgaming.universaltweaks.tweaks.entities.armorstand.mixin", | ||
"refmap": "universaltweaks.refmap.json", | ||
"minVersion": "0.8", | ||
"compatibilityLevel": "JAVA_8", | ||
"mixins": ["UTArmedArmorStandsMixin"] | ||
} |