mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-17 22:45:09 +00:00
Implemented the ability to get the screen size from server
This commit is contained in:
1 parent
03aa9c2e9a
commit
c3b134b5ae
6 files changed
+67
-3
No files matched your search
@@ -18,6 +18,7 @@ import noppes.npcs.entity.data.DataSkinOverlays;
|
||||
import noppes.npcs.entity.data.DataTimers;
|
||||
import noppes.npcs.roles.RoleCompanion;
|
||||
import noppes.npcs.scripted.NpcAPI;
|
||||
import noppes.npcs.scripted.ScreenSize;
|
||||
import noppes.npcs.util.CustomNPCsThreader;
|
||||
import noppes.npcs.util.NBTJsonUtil;
|
||||
|
||||
@@ -52,6 +53,8 @@ public class PlayerData implements IExtendedEntityProperties, IPlayerData {
|
||||
|
||||
public boolean isGUIOpen = false;
|
||||
|
||||
public ScreenSize screenSize = new ScreenSize(-1,-1);
|
||||
|
||||
@Override
|
||||
public void saveNBTData(NBTTagCompound nbtTagCompound) {
|
||||
}
|
||||
@@ -136,6 +139,14 @@ public class PlayerData implements IExtendedEntityProperties, IPlayerData {
|
||||
return this.isGUIOpen;
|
||||
}
|
||||
|
||||
public ScreenSize getScreenSize(){
|
||||
return screenSize;
|
||||
}
|
||||
|
||||
public void setScreenSize(ScreenSize size){
|
||||
screenSize = size;
|
||||
}
|
||||
|
||||
public boolean hasCompanion(){
|
||||
return activeCompanion != null && !activeCompanion.isDead;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user