mirror of
https://github.com/Thorfusion/Mekanism-Community-Edition.git
synced 2026-11-27 23:33:08 +00:00
More missing UUID changes
This commit is contained in:
1 parent
f493221381
commit
035ddfc801
4 files changed
+7
-7
No files matched your search
@@ -21,7 +21,7 @@ import net.minecraftforge.common.MinecraftForge;
|
||||
|
||||
public class MekanismClient extends Mekanism
|
||||
{
|
||||
public static Map<String, SecurityData> clientSecurityMap = new HashMap<String, SecurityData>();
|
||||
public static Map<UUID, SecurityData> clientSecurityMap = new HashMap<UUID, SecurityData>();
|
||||
public static Map<UUID, String> clientUUIDMap = new HashMap<UUID, String>();
|
||||
|
||||
public static VoiceClient voiceClient;
|
||||
|
||||
@@ -74,7 +74,7 @@ public class GuiSecurityTab extends GuiElement
|
||||
|
||||
int renderX = 26 + (18*mode.ordinal());
|
||||
|
||||
if(getOwner() != null && getOwner().equals(mc.player.getName()) && (data == null || !data.override))
|
||||
if(getOwner() != null && getOwner().equals(mc.player.getUniqueID()) && (data == null || !data.override))
|
||||
{
|
||||
if(xAxis >= 179 && xAxis <= 197 && yAxis >= 36 && yAxis <= 54)
|
||||
{
|
||||
@@ -201,7 +201,7 @@ public class GuiSecurityTab extends GuiElement
|
||||
{
|
||||
if(button == 0 && general.allowProtection)
|
||||
{
|
||||
if(getOwner() != null && mc.player.getName().equals(getOwner()))
|
||||
if(getOwner() != null && mc.player.getUniqueID().equals(getOwner()))
|
||||
{
|
||||
if(xAxis >= 179 && xAxis <= 197 && yAxis >= 36 && yAxis <= 54)
|
||||
{
|
||||
|
||||
@@ -27,7 +27,7 @@ public class PacketSecurityUpdate implements IMessageHandler<SecurityUpdateMessa
|
||||
{
|
||||
if(message.securityData != null)
|
||||
{
|
||||
MekanismClient.clientSecurityMap.put(message.playerUsername, message.securityData);
|
||||
MekanismClient.clientSecurityMap.put(message.playerUUID, message.securityData);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -125,7 +125,7 @@ public class PacketSecurityUpdate implements IMessageHandler<SecurityUpdateMessa
|
||||
{
|
||||
UUID uuid = UUID.fromString(PacketHandler.readString(dataStream));
|
||||
String username = PacketHandler.readString(dataStream);
|
||||
MekanismClient.clientSecurityMap.put(username, SecurityData.read(dataStream));
|
||||
MekanismClient.clientSecurityMap.put(uuid, SecurityData.read(dataStream));
|
||||
MekanismClient.clientUUIDMap.put(uuid, username);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -199,7 +199,7 @@ public final class SecurityUtils
|
||||
}
|
||||
else if(side == Side.CLIENT)
|
||||
{
|
||||
SecurityData data = MekanismClient.clientSecurityMap.get(security.getSecurity().getClientOwner());
|
||||
SecurityData data = MekanismClient.clientSecurityMap.get(security.getSecurity().getOwnerUUID());
|
||||
|
||||
if(data != null && data.override)
|
||||
{
|
||||
@@ -249,7 +249,7 @@ public final class SecurityUtils
|
||||
return freq != null && freq.override;
|
||||
}
|
||||
else {
|
||||
SecurityData data = MekanismClient.clientSecurityMap.get(security.getSecurity().getClientOwner());
|
||||
SecurityData data = MekanismClient.clientSecurityMap.get(security.getSecurity().getOwnerUUID());
|
||||
|
||||
return data != null && data.override;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user