mirror of
https://github.com/eaglerforge/EaglerForgeInjector
synced 2025-07-26 15:29:26 -09:00
fix bug 156
This commit is contained in:
parent
4d69375e35
commit
d4a9919cd8
@ -40,7 +40,6 @@
|
|||||||
|
|
||||||
// Get the EntityPlayerMP class to spawn the fake player
|
// Get the EntityPlayerMP class to spawn the fake player
|
||||||
killFS = true;
|
killFS = true;
|
||||||
AsyncSink.startDebuggingFS();
|
|
||||||
const EntityPlayerMPClass = ModAPI.reflect.getClassById("net.minecraft.entity.player.EntityPlayerMP");
|
const EntityPlayerMPClass = ModAPI.reflect.getClassById("net.minecraft.entity.player.EntityPlayerMP");
|
||||||
var worldNameProp = ModAPI.util.getNearestProperty(ModAPI.server.getRef(), "$worldName");
|
var worldNameProp = ModAPI.util.getNearestProperty(ModAPI.server.getRef(), "$worldName");
|
||||||
var worldName = ModAPI.server.getRef()[worldNameProp];
|
var worldName = ModAPI.server.getRef()[worldNameProp];
|
||||||
@ -55,7 +54,7 @@
|
|||||||
fakePlayer.setPosition(senderPos.getX(), senderPos.getY(), senderPos.getZ());
|
fakePlayer.setPosition(senderPos.getX(), senderPos.getY(), senderPos.getZ());
|
||||||
|
|
||||||
// Add the fake player to the world
|
// Add the fake player to the world
|
||||||
world.addEntityToWorld(fakePlayer.getEntityId(), fakePlayer.getRef());
|
world.spawnEntityInWorld(fakePlayer.getRef());
|
||||||
|
|
||||||
// Notify the player that the fake player has been spawned
|
// Notify the player that the fake player has been spawned
|
||||||
const ChatComponentTextClass = ModAPI.reflect.getClassById("net.minecraft.util.ChatComponentText");
|
const ChatComponentTextClass = ModAPI.reflect.getClassById("net.minecraft.util.ChatComponentText");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user