mirror of
https://github.com/GTNewHorizons/Opis.git
synced 2026-11-19 19:59:37 +00:00
Set the default tab for the Nexus FakePlayer
This commit is contained in:
1 parent
93cf3172a8
commit
e3aa9a4788
2 files changed
+3
-1
No files matched your search
@@ -32,7 +32,7 @@ public class NetDataValue extends PacketBase {
|
||||
|
||||
@Override
|
||||
public void decode(ByteArrayDataInput input) {
|
||||
this.msg = Message.values()[input.readInt()];
|
||||
this.msg = Message.values()[input.readInt()];
|
||||
this.clazz = DataType.getForOrdinal(input.readInt());
|
||||
this.value = dataRead(this.clazz, input);
|
||||
|
||||
|
||||
@@ -20,6 +20,7 @@ import mcp.mobius.opis.network.enums.Message;
|
||||
import mcp.mobius.opis.network.packets.server.NetDataValue;
|
||||
import mcp.mobius.opis.network.rcon.RConHandler;
|
||||
import mcp.mobius.opis.network.rcon.server.RConServer;
|
||||
import mcp.mobius.opis.swing.SelectedTab;
|
||||
import io.netty.buffer.ByteBuf;
|
||||
import io.netty.channel.ChannelHandlerContext;
|
||||
import io.netty.channel.ChannelInboundHandlerAdapter;
|
||||
@@ -35,6 +36,7 @@ public class NexusInboundHandler extends ChannelInboundHandlerAdapter {
|
||||
RConHandler.fakePlayers.put(fakePlayer, ctx);
|
||||
|
||||
PlayerTracker.INSTANCE.playersSwing.add(fakePlayer);
|
||||
PlayerTracker.INSTANCE.playerTab.put(fakePlayer, SelectedTab.SUMMARY);
|
||||
PacketManager.validateAndSend(new NetDataValue(Message.STATUS_CURRENT_TIME, new SerialLong(System.currentTimeMillis())), fakePlayer);
|
||||
StringCache.INSTANCE.syncCache(fakePlayer);
|
||||
|
||||
|
||||
Reference in new issue
Block a user