Add key-driven Spacing Guild House-world passage menu
|
|
@ -1,6 +1,6 @@
|
|||
plugins { java }
|
||||
group = "com.dunerealms"
|
||||
version = "1.0.1"
|
||||
version = "1.0.2"
|
||||
repositories { mavenCentral(); maven("https://repo.papermc.io/repository/maven-public/"); maven("https://repo.opencollab.dev/main/") }
|
||||
dependencies {
|
||||
compileOnly("io.papermc.paper:paper-api:1.21.8-R0.1-SNAPSHOT")
|
||||
|
|
|
|||
|
|
@ -31,6 +31,10 @@ public final class DuneGUI extends JavaPlugin implements Listener,CommandExecuto
|
|||
private PersonalSidebar sidebar;
|
||||
private final Map<UUID,DragonController.Detached> detached=new HashMap<>();
|
||||
private final Set<UUID> dragonWarnings=new HashSet<>();
|
||||
private ExistingGuildService guild;
|
||||
private final GuildBookings bookings=new GuildBookings();
|
||||
private final Set<UUID> boarding=new HashSet<>();
|
||||
private long lastDepartureNotice=-1;
|
||||
static final int[] CENTRES={10,13,16,29,33};
|
||||
static final String[] IDS={"atreides","harkonnen","corrino","ordos","fremen"};
|
||||
private static final Set<String> HOUSE_IDS=Set.of(IDS);
|
||||
|
|
@ -43,7 +47,8 @@ public final class DuneGUI extends JavaPlugin implements Listener,CommandExecuto
|
|||
bridge=new HouseBridge(new File(getDataFolder().getParentFile(),"DuneEss/website-bridge.yml"));
|
||||
registrar=new NamespacedKey(this,"house_registrar");
|
||||
sidebar=new PersonalSidebar(this);
|
||||
for(String command:List.of("house","mentat","drgui","drscoreboard"))Objects.requireNonNull(getCommand(command)).setExecutor(this);
|
||||
for(String command:List.of("house","mentat","drgui","drscoreboard","guildtravel"))Objects.requireNonNull(getCommand(command)).setExecutor(this);
|
||||
try{guild=new ExistingGuildService((p,world)->openGuild(p,world));getLogger().info("Spacing Guild lobby entry connected to current House keys and quarter-hour boarding.");}catch(ReflectiveOperationException|RuntimeException unavailable){getLogger().warning("Spacing Guild travel consumer unavailable; no journeys can be booked.");}
|
||||
getServer().getPluginManager().registerEvents(this,this);
|
||||
departure=Bukkit.createBossBar("Spacing Guild · next Imperial departure",BarColor.YELLOW,BarStyle.SOLID);
|
||||
Bukkit.getScheduler().runTaskTimer(this,this::tick,20L,20L);
|
||||
|
|
@ -51,13 +56,48 @@ public final class DuneGUI extends JavaPlugin implements Listener,CommandExecuto
|
|||
Bukkit.getScheduler().runTaskTimer(this,()->{for(Player p:Bukkit.getOnlinePlayers())if(lobby(p)&&sidebar.enabled(p))refreshSidebar(p);},80L,600L);
|
||||
getLogger().info("House selector and Mentat screens enabled; central J.A.R.V.I.S. bridge; no Core/Lobby replacement.");
|
||||
}
|
||||
@Override public void onDisable(){requests.clear();records.clear();GuiSession.clear();if(sidebar!=null)sidebar.clear();for(var controller:detached.values())try{controller.restore();}catch(ReflectiveOperationException ignored){}detached.clear();if(departure!=null)departure.removeAll();for(Player p:Bukkit.getOnlinePlayers())if(p.getOpenInventory().getTopInventory().getHolder() instanceof Screen)p.closeInventory();}
|
||||
@Override public void onDisable(){requests.clear();records.clear();bookings.clear();boarding.clear();if(guild!=null)guild.close();GuiSession.clear();if(sidebar!=null)sidebar.clear();for(var controller:detached.values())try{controller.restore();}catch(ReflectiveOperationException ignored){}detached.clear();if(departure!=null)departure.removeAll();for(Player p:Bukkit.getOnlinePlayers())if(p.getOpenInventory().getTopInventory().getHolder() instanceof Screen)p.closeInventory();}
|
||||
private boolean lobby(Player p){return p.getWorld().getName().equals("guild_lobby");}
|
||||
@Override public boolean onCommand(CommandSender sender,Command command,String label,String[] args){
|
||||
if(!(sender instanceof Player p))return true;if(!lobby(p)){p.sendMessage("This service is available in the Spacing Guild lobby.");return true;}
|
||||
if(command.getName().equals("drscoreboard")||args.length==1&&args[0].equalsIgnoreCase("scoreboard")){toggleSidebar(p);return true;}
|
||||
if(command.getName().equals("guildtravel")||args.length==1&&args[0].equalsIgnoreCase("travel")){if(args.length==1&&args[0].equalsIgnoreCase("cancel")){cancelBooking(p);return true;}openGuild(p,null);return true;}
|
||||
fetch(p,null,0,null,data->{if(command.getName().equals("mentat")&&selection(data)!=null)mentat(p,data);else select(p,data,null);});return true;
|
||||
}
|
||||
private void openGuild(Player p,String requested){fetch(p,null,0,null,data->{String house=selection(data);if(house==null){p.sendMessage("Choose and confirm your House before Guild passage.");select(p,data,null);return;}if(requested!=null&&!GuildRoutes.allowed(house,requested))p.sendMessage("Other House worlds are unavailable through this Guild passage.");travelMenu(p,data);});}
|
||||
private static GuildBookings.Permit permit(JsonObject data){String house=selection(data);if(house==null||!data.has("keyId")||data.get("keyId").isJsonNull())return null;try{return new GuildBookings.Permit(house,UUID.fromString(data.get("keyId").getAsString()),data.get("version").getAsInt());}catch(RuntimeException invalid){return null;}}
|
||||
private void travelMenu(Player p,JsonObject data){
|
||||
String house=selection(data);var home=GuildRoutes.home(house);if(home==null){select(p,data,null);return;}
|
||||
String quote;try{quote=guild==null?"Guild service unavailable":"Guild fare: "+guild.quote(p,home.world())+" DM from your game wallet. Paid at departure.";}catch(RuntimeException unavailable){quote="Guild fare unavailable.";}
|
||||
var booked=bookings.get(p.getUniqueId());String detail=quote+"\nImperial departures every 15 minutes."+(booked==null?"":"\nYour passage is already booked.");
|
||||
if(BedrockForms.isBedrock(p)){List<BedrockForms.Choice> choices=new ArrayList<>();for(var route:GuildRoutes.ALL){boolean allowed=route.house().equals(house);choices.add(new BedrockForms.Choice((allowed?"§6":"§8")+route.name()+(allowed?" · Your House":" · Unavailable"),allowed?detail:"Another House world",allowed?()->bookPassage(p,data):()->travelMenu(p,data),"https://www.dunerealms.com/assets/gui/guild-world-"+route.world().replace('_','-')+(allowed?"":"-locked")+"-v1.png"));}choices.add(new BedrockForms.Choice("Cancel booking","No fare has been charged",()->{cancelBooking(p);travelMenu(p,data);}));choices.add(new BedrockForms.Choice("Your Mentat","Return to your House adviser",()->mentat(p,data)));BedrockForms.show(this,p,"Spacing Guild · Imperial passage",detail,choices);return;}
|
||||
int own=Arrays.asList(IDS).indexOf(house);Screen screen=screen(p,"Spacing Guild · Imperial passage",0xE330+own);
|
||||
for(int i=0;i<GuildRoutes.ALL.size();i++){var route=GuildRoutes.ALL.get(i);boolean allowed=route.house().equals(house);var item=icon(p,route.name(),allowed?detail:"Unavailable · another House world","drgui_transparent",allowed?Material.ENDER_PEARL:Material.GRAY_DYE);int centre=CENTRES[i];for(int row=i<3?-1:0;row<=1;row++)for(int col=-1;col<=1;col++){int slot=centre+row*9+col;screen.inventory.setItem(slot,item.clone());if(allowed)screen.actions.put(slot,()->bookPassage(p,data));}}
|
||||
button(screen,p,45,"Your Mentat","Return to your House adviser",Material.ARROW,()->mentat(p,data));screen.actions.put(46,screen.actions.get(45));
|
||||
button(screen,p,49,"Cancel booking","No fare is taken for a cancelled booking",Material.BARRIER,()->{cancelBooking(p);travelMenu(p,data);});for(int slot:new int[]{48,50})screen.actions.put(slot,screen.actions.get(49));
|
||||
if(guild!=null){button(screen,p,53,booked==null?"Book passage":"Review booked passage",detail,Material.EMERALD,()->bookPassage(p,data));screen.actions.put(52,screen.actions.get(53));}
|
||||
p.openInventory(screen.inventory);expire(screen);
|
||||
}
|
||||
private void cancelBooking(Player p){boolean removed=bookings.cancel(p.getUniqueId());removed=boarding.remove(p.getUniqueId())||removed;p.sendMessage(removed?"Guild passage cancelled. No fare was charged.":"You have no pending Guild booking.");}
|
||||
private void bookPassage(Player p,JsonObject shown){
|
||||
if(boarding.contains(p.getUniqueId())){p.sendMessage("Guild boarding is already being confirmed.");return;}
|
||||
var expected=permit(shown);if(expected==null){p.sendMessage("Confirm your current House key before booking passage.");select(p,shown,selection(shown));return;}
|
||||
fetch(p,null,0,null,fresh->{var current=permit(fresh);if(current==null||!current.equals(expected)){p.sendMessage("Your House key changed. Review the current passage.");travelMenu(p,fresh);return;}
|
||||
var home=GuildRoutes.home(current.house());try{if(guild==null)throw new IllegalStateException("Guild travel service unavailable.");int fare=guild.quote(p,home.world());if(!guild.affordable(p,fare))throw new IllegalStateException("Not enough Dunemarks in your game wallet for the Guild fare ("+fare+" DM).");
|
||||
var booked=bookings.book(p.getUniqueId(),current,home.world(),fare,Instant.now().getEpochSecond());p.closeInventory();p.sendMessage(Component.text("Passage booked to "+home.name()+" for the next Imperial departure. Fare "+booked.fare()+" DM is checked and collected at boarding. No fare has been charged yet.",NamedTextColor.GOLD));
|
||||
}catch(RuntimeException unavailable){p.sendMessage(Component.text(unavailable.getMessage(),NamedTextColor.RED));}
|
||||
});
|
||||
}
|
||||
private void board(GuildBookings.Booking booking){
|
||||
Player p=Bukkit.getPlayer(booking.player());if(p==null||!p.isOnline()||!lobby(p)||guild==null||!boarding.add(booking.player()))return;
|
||||
Bukkit.getScheduler().runTaskAsynchronously(this,()->{JsonObject data=null;boolean online=false;try{data=bridge.request(booking.player(),null,0,null);online=bridge.worldOnline(booking.world());}catch(Exception unavailable){}JsonObject fresh=data;boolean destinationOnline=online;if(!isEnabled())return;
|
||||
Bukkit.getScheduler().runTask(this,()->{if(!boarding.remove(booking.player()))return;if(!p.isOnline()||!lobby(p))return;
|
||||
try{var current=fresh==null?null:permit(fresh);if(current==null||!booking.matches(current,guild.quote(p,booking.world()),Instant.now().getEpochSecond())||!destinationOnline||!guild.affordable(p,booking.fare())){p.sendMessage("Guild boarding could not be confirmed: your key, fare, funds or destination changed. No fare was taken; please rebook.");return;}
|
||||
p.closeInventory();p.sendMessage(Component.text("Imperial boarding · "+GuildRoutes.home(current.house()).name(),NamedTextColor.GOLD));guild.requestDeparture(p,booking.world());
|
||||
}catch(RuntimeException unavailable){p.sendMessage("The Guild could not request your departure. Reopen the passage menu.");}
|
||||
});
|
||||
});
|
||||
}
|
||||
private void fetch(Player p,String house,int version,UUID requestId,Consumer<JsonObject> callback){
|
||||
UUID owner=p.getUniqueId();if(requests.containsKey(owner)){p.sendMessage("The House register is processing your request.");return;}
|
||||
UUID operation=UUID.randomUUID();requests.put(owner,operation);p.closeInventory();p.sendMessage(Component.text("Jarvis executing matrix",NamedTextColor.GOLD));
|
||||
|
|
@ -83,7 +123,7 @@ public final class DuneGUI extends JavaPlugin implements Listener,CommandExecuto
|
|||
private void toggleSidebar(Player p){sidebar.toggle(p);p.sendMessage(Component.text(sidebar.enabled(p)?"Personal scoreboard enabled.":"Personal scoreboard hidden.",NamedTextColor.GOLD));if(sidebar.enabled(p)){JsonObject data=records.get(p.getUniqueId());if(data!=null)updateSidebar(p,data);refreshSidebar(p);}}
|
||||
@EventHandler public void scoreboardCommand(PlayerCommandPreprocessEvent e){String command=e.getMessage().trim();if(command.equalsIgnoreCase("/scoreboard")&&lobby(e.getPlayer())){e.setCancelled(true);toggleSidebar(e.getPlayer());}}
|
||||
@EventHandler public void join(PlayerJoinEvent e){Bukkit.getScheduler().runTaskLater(this,()->{if(e.getPlayer().isOnline()&&lobby(e.getPlayer())&&sidebar.enabled(e.getPlayer()))refreshSidebar(e.getPlayer());},40L);}
|
||||
@EventHandler public void world(PlayerChangedWorldEvent e){sidebar.hide(e.getPlayer());records.remove(e.getPlayer().getUniqueId());if(lobby(e.getPlayer())&&sidebar.enabled(e.getPlayer()))refreshSidebar(e.getPlayer());}
|
||||
@EventHandler public void world(PlayerChangedWorldEvent e){bookings.cancel(e.getPlayer().getUniqueId());boarding.remove(e.getPlayer().getUniqueId());sidebar.hide(e.getPlayer());records.remove(e.getPlayer().getUniqueId());if(lobby(e.getPlayer())&&sidebar.enabled(e.getPlayer()))refreshSidebar(e.getPlayer());}
|
||||
static String selection(JsonObject data){if(!data.has("selection")||data.get("selection").isJsonNull())return null;String value=data.get("selection").getAsString();return HOUSE_IDS.contains(value)?value:null;}
|
||||
private String houseName(JsonObject data,String id){for(var entry:data.getAsJsonArray("choices")){var h=entry.getAsJsonObject();if(h.get("id").getAsString().equals(id))return h.get("name").getAsString();}throw new IllegalArgumentException("Unknown House");}
|
||||
private void select(Player p,JsonObject data,String picked){
|
||||
|
|
@ -116,11 +156,11 @@ public final class DuneGUI extends JavaPlugin implements Listener,CommandExecuto
|
|||
private void mentat(Player p,JsonObject data){
|
||||
String house=selection(data);if(house==null){select(p,data,null);return;}
|
||||
JsonObject mentor=data.getAsJsonObject("mentat");String name=mentor.get("name").getAsString();int index=Arrays.asList(IDS).indexOf(house);
|
||||
if(BedrockForms.isBedrock(p)){BedrockForms.show(this,p,"Your Mentat · "+name,houseName(data,house)+"\nYour House briefing is ready.",List.of(new BedrockForms.Choice("Open Mentat Report","Open your website mission journal",()->report(p),"https://www.dunerealms.com/assets/gui/mentat-"+house+"-v1.png"),new BedrockForms.Choice(sidebar.enabled(p)?"Hide scoreboard":"Show scoreboard","Personal briefing display",()->{toggleSidebar(p);mentat(p,data);}),new BedrockForms.Choice("Return to lobby","Continue your journey",p::closeInventory)));return;}
|
||||
if(BedrockForms.isBedrock(p)){BedrockForms.show(this,p,"Your Mentat · "+name,houseName(data,house)+"\nYour House briefing is ready.",List.of(new BedrockForms.Choice("Open Mentat Report","Open your website mission journal",()->report(p),"https://www.dunerealms.com/assets/gui/mentat-"+house+"-v1.png"),new BedrockForms.Choice(sidebar.enabled(p)?"Hide scoreboard":"Show scoreboard","Personal briefing display",()->{toggleSidebar(p);mentat(p,data);}),new BedrockForms.Choice("Spacing Guild travel","Book passage to your House world",()->openGuild(p,null))));return;}
|
||||
Screen screen=screen(p,"Your Mentat · "+name,0xE310+index);
|
||||
screen.inventory.setItem(13,icon(p,name,houseName(data,house),"drgui_transparent",Material.PLAYER_HEAD));
|
||||
button(screen,p,38,"Open Mentat Report","Personal level, Reputation and active quests",Material.WRITABLE_BOOK,()->report(p));
|
||||
button(screen,p,42,"Return to lobby","Continue your journey",Material.COMPASS,p::closeInventory);
|
||||
button(screen,p,42,"Spacing Guild travel","Book passage to your House world",Material.COMPASS,()->openGuild(p,null));
|
||||
button(screen,p,45,"Your House",houseName(data,house),Material.ARROW,()->select(p,data,house));
|
||||
button(screen,p,49,sidebar.enabled(p)?"Hide scoreboard":"Show scoreboard","Toggle your personal briefing",Material.LEVER,()->{toggleSidebar(p);mentat(p,data);});for(int slot:new int[]{48,50})screen.actions.put(slot,screen.actions.get(49));
|
||||
for(int slot:new int[]{37,39})screen.actions.put(slot,screen.actions.get(38));for(int slot:new int[]{41,43})screen.actions.put(slot,screen.actions.get(42));screen.actions.put(46,screen.actions.get(45));
|
||||
|
|
@ -138,7 +178,7 @@ public final class DuneGUI extends JavaPlugin implements Listener,CommandExecuto
|
|||
}
|
||||
@EventHandler public void drag(InventoryDragEvent e){if(e.getView().getTopInventory().getHolder() instanceof Screen)e.setCancelled(true);}
|
||||
@EventHandler public void close(InventoryCloseEvent e){if(e.getInventory().getHolder() instanceof Screen s)s.gate.expire();}
|
||||
@EventHandler public void quit(PlayerQuitEvent e){requests.remove(e.getPlayer().getUniqueId());records.remove(e.getPlayer().getUniqueId());sidebar.hide(e.getPlayer());departure.removePlayer(e.getPlayer());}
|
||||
@EventHandler public void quit(PlayerQuitEvent e){bookings.cancel(e.getPlayer().getUniqueId());boarding.remove(e.getPlayer().getUniqueId());requests.remove(e.getPlayer().getUniqueId());records.remove(e.getPlayer().getUniqueId());sidebar.hide(e.getPlayer());departure.removePlayer(e.getPlayer());}
|
||||
private void ensureRegistrar(){World world=Bukkit.getWorld("guild_lobby");if(world==null)return;Location at=world.getSpawnLocation().clone().add(2,0,0);at.getChunk().load();
|
||||
for(Entity entity:world.getEntities())if(entity.getPersistentDataContainer().has(registrar,PersistentDataType.BYTE))return;
|
||||
Villager npc=world.spawn(at,Villager.class);npc.setAI(false);npc.setInvulnerable(true);npc.setPersistent(true);npc.setSilent(true);npc.setCollidable(false);npc.setProfession(Villager.Profession.LIBRARIAN);npc.customName(Component.text("House Registrar · Choose your House",NamedTextColor.GOLD));npc.setCustomNameVisible(true);npc.getPersistentDataContainer().set(registrar,PersistentDataType.BYTE,(byte)1);
|
||||
|
|
@ -146,6 +186,8 @@ public final class DuneGUI extends JavaPlugin implements Listener,CommandExecuto
|
|||
@EventHandler public void npc(PlayerInteractEntityEvent e){if(!e.getRightClicked().getPersistentDataContainer().has(registrar,PersistentDataType.BYTE))return;e.setCancelled(true);if(e.getHand()!=EquipmentSlot.HAND||!lobby(e.getPlayer()))return;fetch(e.getPlayer(),null,0,null,data->{if(selection(data)!=null)mentat(e.getPlayer(),data);else select(e.getPlayer(),data,null);});}
|
||||
private void tick(){
|
||||
long remaining=DepartureWindow.remaining(Instant.now().getEpochSecond());departure.setTitle("Spacing Guild · Imperial departure window in "+String.format(Locale.ROOT,"%02d:%02d",remaining/60,remaining%60));departure.setProgress(remaining/900.0);
|
||||
long now=Instant.now().getEpochSecond();for(var booking:bookings.due(now))board(booking);
|
||||
if((remaining==300||remaining==60||remaining==10)&&lastDepartureNotice!=now){lastDepartureNotice=now;for(Player p:Bukkit.getOnlinePlayers())if(lobby(p))p.sendMessage(Component.text("Spacing Guild · next Imperial transport in "+(remaining>=60?remaining/60+" minute(s).":remaining+" seconds."),NamedTextColor.GOLD));}
|
||||
for(World world:Bukkit.getWorlds())if(world.getName().equals("guild_lobby")){var battle=world.getEnderDragonBattle();if(battle!=null){if(battle.getBossBar()!=null){battle.getBossBar().setVisible(false);battle.getBossBar().removeAll();}
|
||||
if(!detached.containsKey(world.getUID()))try{Object handle=world.getClass().getMethod("getHandle").invoke(world);detached.put(world.getUID(),DragonController.detach(handle));getLogger().info("Lobby dragon controller detached; native bossbar disabled.");}catch(ReflectiveOperationException|RuntimeException unsupported){if(dragonWarnings.add(world.getUID()))getLogger().warning("Lobby dragon controller could not be detached; native bossbar fallback active.");}
|
||||
}}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,28 @@
|
|||
package com.dunerealms.gui;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.command.*;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.plugin.Plugin;
|
||||
import java.lang.reflect.Method;
|
||||
import java.util.function.BiConsumer;
|
||||
/** Keep the existing fare, permission and proxy-transfer consumer; replace only lobby entry. */
|
||||
final class ExistingGuildService implements AutoCloseable {
|
||||
private final PluginCommand command;
|
||||
private final CommandExecutor original,wrapper;
|
||||
private final Plugin owner;
|
||||
private final Method fare;
|
||||
ExistingGuildService(BiConsumer<Player,String> open)throws ReflectiveOperationException {
|
||||
command=Bukkit.getPluginCommand("duneess:duneess");
|
||||
if(command==null||!command.getPlugin().getName().equals("DuneEss"))throw new IllegalStateException("DuneEss travel service unavailable");
|
||||
original=command.getExecutor();owner=command.getPlugin();fare=owner.getClass().getDeclaredMethod("travelFare",Player.class,String.class);fare.setAccessible(true);
|
||||
wrapper=(sender,cmd,label,args)->{if(sender instanceof Player p&&p.getWorld().getName().equals("guild_lobby")&&args.length>=1&&args[0].equalsIgnoreCase("travel")){open.accept(p,args.length==2?args[1].toLowerCase(java.util.Locale.ROOT):null);return true;}return original.onCommand(sender,cmd,label,args);};
|
||||
command.setExecutor(wrapper);
|
||||
}
|
||||
int quote(Player p,String world){try{if(!owner.isEnabled())throw new IllegalStateException();return Math.max(0,((Number)fare.invoke(owner,p,world)).intValue());}catch(ReflectiveOperationException error){throw new IllegalStateException("Guild fare is unavailable",error);}}
|
||||
@SuppressWarnings({"rawtypes","unchecked"}) boolean affordable(Player p,int amount){
|
||||
if(amount==0)return true;
|
||||
try{Class api=Class.forName("net.milkbowl.vault.economy.Economy");var registration=Bukkit.getServicesManager().getRegistration(api);if(registration==null)return false;return Boolean.TRUE.equals(api.getMethod("has",org.bukkit.OfflinePlayer.class,double.class).invoke(registration.getProvider(),p,(double)amount));}catch(ReflectiveOperationException error){return false;}
|
||||
}
|
||||
void requestDeparture(Player p,String world){if(!owner.isEnabled())throw new IllegalStateException("Guild service unavailable");original.onCommand(p,command,"duneess",new String[]{"travel",world});}
|
||||
@Override public void close(){if(command.getExecutor()==wrapper)command.setExecutor(original);}
|
||||
}
|
||||
|
|
@ -2,8 +2,8 @@ package com.dunerealms.gui;
|
|||
/** Four by four bounded bitmap glyphs, each <=256px, compose one crisp screen. */
|
||||
final class GuiArtwork {
|
||||
static String background(int oldGlyph){
|
||||
int index=oldGlyph>=0xE310?oldGlyph-0xE310+6:oldGlyph-0xE300;
|
||||
if(index<0||index>10)throw new IllegalArgumentException("Unknown GUI screen");
|
||||
int index=oldGlyph>=0xE330?oldGlyph-0xE330+11:oldGlyph>=0xE310?oldGlyph-0xE310+6:oldGlyph-0xE300;
|
||||
if(index<0||index>15)throw new IllegalArgumentException("Unknown GUI screen");
|
||||
StringBuilder result=new StringBuilder("\uE32F");
|
||||
for(int row=0;row<4;row++){for(int column=0;column<4;column++)result.append((char)(0xE400+index*16+row*4+column)).append('\uE32E');result.append('\uE32D');}
|
||||
return result.toString();
|
||||
|
|
|
|||
|
|
@ -0,0 +1,19 @@
|
|||
package com.dunerealms.gui;
|
||||
import java.util.*;
|
||||
/** A transient boarding request, never an entitlement or payment receipt. */
|
||||
final class GuildBookings {
|
||||
record Permit(String house,UUID keyId,int version){Permit{if(GuildRoutes.home(house)==null||keyId==null||version<1)throw new IllegalArgumentException("A current House key is required");}}
|
||||
record Booking(UUID player,Permit permit,String world,int fare,long departureAt){
|
||||
boolean matches(Permit current,int currentFare,long now){return permit.equals(current)&&fare==currentFare&&GuildRoutes.allowed(current.house(),world)&&now>=departureAt&&now-departureAt<=60;}
|
||||
}
|
||||
private final Map<UUID,Booking> bookings=new HashMap<>();
|
||||
Booking book(UUID player,Permit permit,String world,int fare,long now){
|
||||
if(!GuildRoutes.allowed(permit.house(),world)||fare<0)throw new IllegalArgumentException("This world is unavailable for your House");
|
||||
Booking old=bookings.get(player);if(old!=null){if(old.permit().equals(permit)&&old.world().equals(world)&&old.fare()==fare)return old;throw new IllegalStateException("Cancel your existing booking before changing it");}
|
||||
Booking booking=new Booking(player,permit,world,fare,now+DepartureWindow.remaining(now));bookings.put(player,booking);return booking;
|
||||
}
|
||||
Booking get(UUID player){return bookings.get(player);}
|
||||
boolean cancel(UUID player){return bookings.remove(player)!=null;}
|
||||
List<Booking> due(long now){List<Booking> due=new ArrayList<>();for(var iterator=bookings.values().iterator();iterator.hasNext();){Booking booking=iterator.next();if(booking.departureAt()<=now){due.add(booking);iterator.remove();}}return List.copyOf(due);}
|
||||
void clear(){bookings.clear();}
|
||||
}
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
package com.dunerealms.gui;
|
||||
import java.util.List;
|
||||
final class GuildRoutes {
|
||||
record Route(String house,String world,String name,String sigil){}
|
||||
static final List<Route> ALL=List.of(
|
||||
new Route("atreides","caladan","Kaladam","pelareth"),
|
||||
new Route("harkonnen","giedi_prime","Giedermark","varkesh"),
|
||||
new Route("corrino","kaitain","Kaiterhof","orivane"),
|
||||
new Route("ordos","sigma_draconis_iv","Sigmadraken IV","nivareth"),
|
||||
new Route("fremen","arrakis","Arrakduin","serevan")
|
||||
);
|
||||
static Route home(String house){return ALL.stream().filter(r->r.house().equals(house)).findFirst().orElse(null);}
|
||||
static boolean allowed(String house,String world){Route route=home(house);return route!=null&&route.world().equals(world);}
|
||||
}
|
||||
|
|
@ -14,6 +14,12 @@ final class HouseBridge {
|
|||
private final HttpClient http=HttpClient.newBuilder().connectTimeout(Duration.ofSeconds(5)).followRedirects(HttpClient.Redirect.NEVER).build();
|
||||
private final File config;
|
||||
HouseBridge(File config){this.config=config;}
|
||||
boolean worldOnline(String world)throws Exception {
|
||||
var request=HttpRequest.newBuilder(URI.create("https://cp.dunerealms.com/api/worlds")).timeout(Duration.ofSeconds(8)).GET().build();
|
||||
var response=http.send(request,HttpResponse.BodyHandlers.ofString());if(response.statusCode()!=200||response.body().length()>16384)return false;
|
||||
var data=JsonParser.parseString(response.body()).getAsJsonObject();if(!data.has("available")||!data.get("available").getAsBoolean()||!data.has("checkedAt")||data.get("checkedAt").isJsonNull()||Math.abs(System.currentTimeMillis()-data.get("checkedAt").getAsLong())>90000)return false;
|
||||
for(var row:data.getAsJsonArray("servers")){var server=row.getAsJsonObject();if(world.replace('_','-').equals(server.get("id").getAsString()))return "online".equals(server.get("state").getAsString());}return false;
|
||||
}
|
||||
JsonObject request(UUID player,String faction,int version,UUID requestId) throws Exception {
|
||||
var settings=YamlConfiguration.loadConfiguration(config);
|
||||
String origin=settings.getString("origin",""),secret=settings.getString("secret","");
|
||||
|
|
|
|||
|
|
@ -1,9 +1,11 @@
|
|||
name: DunerealmsGUI
|
||||
main: com.dunerealms.gui.DuneGUI
|
||||
version: 1.0.1
|
||||
version: 1.0.2
|
||||
api-version: '1.21.8'
|
||||
softdepend: [DuneLobby, DuneCore, DuneEss, DuneNPC, floodgate, ViaVersion]
|
||||
softdepend: [DuneLobby, DuneCore, DuneEss, DuneNPC, Vault, floodgate, ViaVersion]
|
||||
commands:
|
||||
guildtravel:
|
||||
description: Book or cancel quarter-hour Imperial passage to your House world
|
||||
drscoreboard:
|
||||
description: Toggle your private Personal XP, Reputation, bank and organisation scoreboard
|
||||
house:
|
||||
|
|
|
|||
|
|
@ -0,0 +1,21 @@
|
|||
package com.dunerealms.gui;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import static org.junit.jupiter.api.Assertions.*;
|
||||
import java.util.UUID;
|
||||
class GuildBookingsTest {
|
||||
private final GuildBookings.Permit atreides=new GuildBookings.Permit("atreides",UUID.randomUUID(),1);
|
||||
@Test void fiveCanonicalHouseRoutesNeverGrantAnotherHouseDestination(){
|
||||
assertEquals(5,GuildRoutes.ALL.size());assertEquals("caladan",GuildRoutes.home("atreides").world());assertEquals("arrakis",GuildRoutes.home("fremen").world());assertNull(GuildRoutes.home(null));
|
||||
for(var route:GuildRoutes.ALL)for(var other:GuildRoutes.ALL)assertEquals(route==other,GuildRoutes.allowed(route.house(),other.world()));
|
||||
assertThrows(IllegalArgumentException.class,()->new GuildBookings().book(UUID.randomUUID(),atreides,"arrakis",100,1));
|
||||
}
|
||||
@Test void bookingCannotLeaveInstantlyOrDuplicateAtTheQuarterHour(){
|
||||
var queue=new GuildBookings();UUID player=UUID.randomUUID();var one=queue.book(player,atreides,"caladan",100,899);
|
||||
assertEquals(900,one.departureAt());assertTrue(queue.due(899).isEmpty());assertSame(one,queue.book(player,atreides,"caladan",100,899));assertEquals(1,queue.due(900).size());assertTrue(queue.due(900).isEmpty());assertEquals(1800,queue.book(player,atreides,"caladan",100,900).departureAt());
|
||||
}
|
||||
@Test void changedKeysFaresLateRunsAndCancelledSessionsCannotDepart(){
|
||||
var queue=new GuildBookings();UUID player=UUID.randomUUID();var booking=queue.book(player,atreides,"caladan",100,0);
|
||||
assertTrue(booking.matches(atreides,100,900));assertFalse(booking.matches(new GuildBookings.Permit("atreides",UUID.randomUUID(),2),100,900));assertFalse(booking.matches(atreides,101,900));assertFalse(booking.matches(atreides,100,961));
|
||||
assertTrue(queue.cancel(player));assertTrue(queue.due(900).isEmpty());assertThrows(IllegalArgumentException.class,()->new GuildBookings.Permit("bene",UUID.randomUUID(),1));
|
||||
}
|
||||
}
|
||||
|
|
@ -1591,6 +1591,726 @@
|
|||
"chars": [
|
||||
"\ue4af"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-11-0-0.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4b0"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-11-0-1.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4b1"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-11-0-2.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4b2"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-11-0-3.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4b3"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-11-1-0.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4b4"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-11-1-1.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4b5"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-11-1-2.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4b6"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-11-1-3.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4b7"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-11-2-0.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4b8"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-11-2-1.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4b9"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-11-2-2.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4ba"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-11-2-3.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4bb"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-11-3-0.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4bc"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-11-3-1.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4bd"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-11-3-2.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4be"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-11-3-3.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4bf"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-12-0-0.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4c0"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-12-0-1.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4c1"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-12-0-2.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4c2"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-12-0-3.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4c3"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-12-1-0.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4c4"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-12-1-1.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4c5"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-12-1-2.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4c6"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-12-1-3.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4c7"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-12-2-0.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4c8"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-12-2-1.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4c9"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-12-2-2.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4ca"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-12-2-3.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4cb"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-12-3-0.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4cc"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-12-3-1.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4cd"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-12-3-2.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4ce"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-12-3-3.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4cf"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-13-0-0.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4d0"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-13-0-1.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4d1"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-13-0-2.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4d2"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-13-0-3.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4d3"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-13-1-0.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4d4"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-13-1-1.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4d5"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-13-1-2.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4d6"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-13-1-3.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4d7"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-13-2-0.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4d8"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-13-2-1.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4d9"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-13-2-2.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4da"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-13-2-3.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4db"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-13-3-0.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4dc"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-13-3-1.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4dd"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-13-3-2.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4de"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-13-3-3.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4df"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-14-0-0.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4e0"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-14-0-1.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4e1"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-14-0-2.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4e2"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-14-0-3.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4e3"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-14-1-0.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4e4"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-14-1-1.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4e5"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-14-1-2.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4e6"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-14-1-3.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4e7"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-14-2-0.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4e8"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-14-2-1.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4e9"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-14-2-2.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4ea"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-14-2-3.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4eb"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-14-3-0.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4ec"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-14-3-1.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4ed"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-14-3-2.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4ee"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-14-3-3.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4ef"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-15-0-0.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4f0"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-15-0-1.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4f1"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-15-0-2.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4f2"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-15-0-3.png",
|
||||
"ascent": 13,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4f3"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-15-1-0.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4f4"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-15-1-1.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4f5"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-15-1-2.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4f6"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-15-1-3.png",
|
||||
"ascent": -43,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4f7"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-15-2-0.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4f8"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-15-2-1.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4f9"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-15-2-2.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4fa"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-15-2-3.png",
|
||||
"ascent": -99,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4fb"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-15-3-0.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4fc"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-15-3-1.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4fd"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-15-3-2.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4fe"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "bitmap",
|
||||
"file": "dunerealms:gui/house_selector/tiles/screen-15-3-3.png",
|
||||
"ascent": -155,
|
||||
"height": 56,
|
||||
"chars": [
|
||||
"\ue4ff"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
|
Before Width: | Height: | Size: 100 KiB After Width: | Height: | Size: 101 KiB |
|
Before Width: | Height: | Size: 103 KiB After Width: | Height: | Size: 103 KiB |
|
Before Width: | Height: | Size: 106 KiB After Width: | Height: | Size: 106 KiB |
|
Before Width: | Height: | Size: 95 KiB After Width: | Height: | Size: 95 KiB |
|
Before Width: | Height: | Size: 102 KiB After Width: | Height: | Size: 102 KiB |
|
Before Width: | Height: | Size: 20 KiB After Width: | Height: | Size: 20 KiB |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 842 B |
|
After Width: | Height: | Size: 8.2 KiB |
|
After Width: | Height: | Size: 8.6 KiB |
|
After Width: | Height: | Size: 7.8 KiB |

Staff