Custom GUI (Work in Progress)

Forum for alternative clients, mods & discussions on the same.

Moderator: Phades

User avatar
olgeigracexD
Posts: 76
Joined: Wed Sep 08, 2010 7:40 pm

Custom GUI (Work in Progress)

Post by olgeigracexD »

Image

Includes:
• window background
• window borders
• window caption
• button
• inventory grid
• blank minimap background
• simple paginae actions (Icons made by lorc)

Known Issues:
• too big toolbar windows
• plus icon on the minimap overlaps window caption

Download
Last edited by olgeigracexD on Sat Feb 15, 2014 3:45 pm, edited 1 time in total.
User avatar
borka
Posts: 9965
Joined: Thu Feb 03, 2011 7:47 pm
Location: World of Sprucecap

Re: Custom GUI (Work in Progress)

Post by borka »

Will give it a try - ty

Not putting in listing yet as it's WIP
User avatar
Arcanist
Posts: 2664
Joined: Mon Mar 19, 2012 2:01 pm

Re: Custom GUI (Work in Progress)

Post by Arcanist »

Is it possible to just get that FEP bar?
User avatar
olgeigracexD
Posts: 76
Joined: Wed Sep 08, 2010 7:40 pm

Re: Custom GUI (Work in Progress)

Post by olgeigracexD »

@Arcanist:

Code: Select all

MapView.java:
+    public FoodMeter foodm;

...

+    public void ToggleFepBar() {
+        if (foodm == null) {
+            foodm = new FoodMeter(new Coord(300, 10), this.parent);
+        }
+ 
+        if (Config.floating_fep) {
+            foodm.show();
+            foodm.update();
+            }
+        else
+            foodm.hide();
+    }

------------------------------------------------

CharWnd.java:
    public void uimsg(String msg, Object... args) {
	    ...
        } else if (msg == "food") {
            foodm.update(args);
+           if (Config.floating_fep)
+               ui.mainview.foodm.update(args);
	
------------------------------------------------

Config.java:
+   public static boolean floating_fep;

...

    private static void loadOptions() {
        ...
+       floating_fep = options.getProperty("floating_fep", "true" ).equals("true");

...

    public static void saveOptions() {
        ...
+       options.setProperty("floating_fep", floating_fep ? "true" : "false");

------------------------------------------------

OptWnd.java:
    public OptWnd(Coord c, Widget parent) {
	     ...
+       (new CheckBox(new Coord(410, y+=35 ), tab, "Floating FEP") {
+           public void changed(boolean val) {
+               Config.floating_fep = val;
+               Config.saveOptions();
+               
+               ui.mainview.ToggleFepBar();
+           }
+       }).a = Config.floating_fep;

------------------------------------------------

FoodMeter.java:
static Object[] argsLast;

...

    public void update(Object... args) {
+       argsLast = args;

...
    
+   public void update()
+   {
+       if( argsLast != null )
+           update( argsLast );
+   }
User avatar
Arcanist
Posts: 2664
Joined: Mon Mar 19, 2012 2:01 pm

Re: Custom GUI (Work in Progress)

Post by Arcanist »

I have no idea what to do with that, but thanks!
User avatar
borka
Posts: 9965
Joined: Thu Feb 03, 2011 7:47 pm
Location: World of Sprucecap

Re: Custom GUI (Work in Progress)

Post by borka »

it's an example how you'd edit different .java files in source code (which means you would have to compile from source then)

btw. latest version is 2013-08-03 - you'll find at sourceforge url given in OP SIG
Last edited by borka on Tue Nov 12, 2013 12:40 am, edited 1 time in total.
Reason: edited
Avatar by SacreDoom
Java 8 - manually downloads - good to check for actual versions url here:
viewtopic.php?f=42&t=40331
Remember what the dormouse said: Feed your head Feed your head

Return to “The Wizards' Tower”