generated from FabricMC/fabric-example-mod
-
Notifications
You must be signed in to change notification settings - Fork 43
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
1 parent
530e2ce
commit ce21876
Showing
6 changed files
with
84 additions
and
7 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
15 changes: 15 additions & 0 deletions
15
src/main/java/one/oktw/mixin/hack/ServerLoginNetworkHandler_SkipKeyPacket.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,15 @@ | ||
package one.oktw.mixin.hack; | ||
|
||
import net.minecraft.server.MinecraftServer; | ||
import net.minecraft.server.network.ServerLoginNetworkHandler; | ||
import org.spongepowered.asm.mixin.Mixin; | ||
import org.spongepowered.asm.mixin.injection.At; | ||
import org.spongepowered.asm.mixin.injection.Redirect; | ||
|
||
@Mixin(ServerLoginNetworkHandler.class) | ||
public class ServerLoginNetworkHandler_SkipKeyPacket { | ||
@Redirect(method = "onHello", at = @At(value = "INVOKE", target = "Lnet/minecraft/server/MinecraftServer;isOnlineMode()Z")) | ||
private boolean skipKeyPacket(MinecraftServer minecraftServer) { | ||
return false; | ||
} | ||
} |
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 |
---|---|---|
|
@@ -22,7 +22,8 @@ | |
] | ||
}, | ||
"mixins": [ | ||
"core.mixins.json" | ||
"core.mixins.json", | ||
"hack.mixins.json" | ||
], | ||
|
||
"depends": { | ||
|
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,13 @@ | ||
{ | ||
"required": true, | ||
"minVersion": "0.8", | ||
"package": "one.oktw.mixin.hack", | ||
"plugin": "one.oktw.FabricProxyLite", | ||
"compatibilityLevel": "JAVA_8", | ||
"mixins": [ | ||
"ServerLoginNetworkHandler_SkipKeyPacket" | ||
], | ||
"injectors": { | ||
"defaultRequire": 1 | ||
} | ||
} |