Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New GUI/Menu system #87

Open
mrwonko opened this issue Apr 11, 2013 · 24 comments
Open

New GUI/Menu system #87

mrwonko opened this issue Apr 11, 2013 · 24 comments

Comments

@mrwonko
Copy link
Contributor

mrwonko commented Apr 11, 2013

The current menu system has a couple of drawbacks, including:

  • Defining looks and data in the same file - Model View Controller could help?
  • Only knowing relative coordinates - having both absolute and relative coordinates would help support different aspect ratios and would add the option to have constant-sized (in pixels) elements, i.e. HUD is smaller on higher resolutions. (Keep high DPI screens in mind though (Retina or whatever apple calls theirs?) - maybe make the Virtual Menu Resolution configurable in the options.
  • Not being very extensible - if two mods want to add to the HUD, they'll conflict.
  • Not being easily customizable - an MMO-like interface that users can rearrange would be nice?

I can look into this at some point, though that's some time off still.

@ghost ghost assigned mrwonko Apr 11, 2013
@eezstreet
Copy link
Contributor

I'd like to comment that a new parser template class would be very useful for SP. The rest of what you described sounds slightly touching on the gameplay.

@mrwonko
Copy link
Contributor Author

mrwonko commented Apr 12, 2013

Well, it'd require a custom uix86.dll, but it doesn't really touch gameplay itself. It would have its place in the modbase and I'm all for having an official "Jedi Academy Enhanced Base" mod at some point.

@cadika-orade
Copy link

What if the entire interface could be defined using XML?

@ensiform
Copy link
Member

XML please go.

@cadika-orade
Copy link

@ensiform I'm sorry. What?

@deepy
Copy link
Contributor

deepy commented Apr 23, 2013

I will raise my opinion against XML, there are better ways to do this.

@cadika-orade
Copy link

Fair enough. I've been taking a class on Android development this semester and have been doing a lot of UI design in XML.

Just thought I'd put it out there.

@eezstreet
Copy link
Contributor

Unfortunately there's no one good solution to UI. XML is probably the worst solution tbh.
Tbh, the current system wouldn't be so bad if it had more extendability, a scripting system, and more simplicity, especially in regards to buttons/hoverovers and text. Its also the easiest solution to implement while maintaining cross platform and joystick support.

Sent from my Windows Phone


From: cadika-orademailto:[email protected]
Sent: ‎4/‎23/‎2013 8:03 PM
To: Razish/OpenJKmailto:[email protected]
Cc: eezstreetmailto:[email protected]
Subject: Re: [OpenJK] New GUI/Menu system (#87)

Fair enough. I've been taking a class on Android development this semester and have been doing a lot of UI design in XML.

Just thought I'd put it out there.


Reply to this email directly or view it on GitHub:
#87 (comment)

@Razish
Copy link
Member

Razish commented Apr 24, 2013

I think comparing JA's usage of the .menu scripting system to the potential use of the .menu scripting system, is unfair.

Fun fact: You can do all sorts of preprocessor hacks; double macro expansion, x-macros, $evalint, etc. That's all in botlib code.
The game-code should really be using ownerdraw for HUD elements too, but Raven decided to hardcode elements and search by name.
Look at some Q3TA HUDs and you'll get an idea of what's possible.
You can also define constants from gamecode (e.g. aspectratio) before processing the .menu script

@aisouard
Copy link
Contributor

Just port CEGUI and the issue is closed !

@eezstreet
Copy link
Contributor

How about...

...

No.

Sent from my Windows Phone


From: Axel Isouardmailto:[email protected]
Sent: ‎10/‎30/‎2013 4:13 AM
To: JACoders/OpenJKmailto:[email protected]
Cc: eezstreetmailto:[email protected]
Subject: Re: [OpenJK] New GUI/Menu system (#87)

Just port CEGUI and the issue is closed !


Reply to this email directly or view it on GitHub:
#87 (comment)

@ensiform
Copy link
Member

ensiform commented Jan 6, 2014

@xycaleth is working on some new menu code that works as a translator to the existing menu code for ease of use.

@Razish
Copy link
Member

Razish commented Jun 17, 2016

Close as out of scope?
There are so many ways to handle this problem even if we were to pursue it.

@clawoflight
Copy link

Just wondering, what do you guys have against XML? A defined subset of XML is a very good and proven way to design structured user interfaces. Do you just not like the syntax?

@ensiform
Copy link
Member

The libraries to support XML are bloated pigs even the light versions.

@mrwonko
Copy link
Contributor Author

mrwonko commented Jun 18, 2016

Which is fitting, since the format is a bloated pig itself. 👅

@ensiform
Copy link
Member

I assume claw is referring to the likes of xaml?

@clawoflight
Copy link

Not specifically, no. A lot of things use a subset of or close to XML:

  • Android
  • JavaFX
  • JSF (Java Server Faces)
  • XAML
  • HTML (of course)
  • etc...

There's also QML which is more like JSON. But JSON and XML share most
principles, they mostly just look different.

XML is great whenever a clear structure exists, which is always the case
in menus.

On 06/18/2016 10:18 PM, Ensiform wrote:

I assume claw is referring to the likes of xaml?

GPG fingerprint: 871F 1047 7DB3 DDED 5FC4 47B2 26C7 E577 EF96 7808

@ensiform
Copy link
Member

ensiform commented Jun 18, 2016

So bloated pile still. And HTML isn't XML its HTML. XHTML is different.

@leilei-
Copy link

leilei- commented Jun 18, 2016

I have trouble reading XML files and even specialized XML editors are quite unintuitive to use (like a toolkit-bloated regedit.exe and gratuitous web access in some cases). I'd rather use the TA script system than XML lol. tags tags everywhere

next, someone will be preaching for data exclusively called through jsons, and then drop tga/jpg/bmp/pcx support in favor of only crushed PNGs because it's "the standard". and then move the entire ui/cgame interface system to GTK so some debian maintainers can be happy of keeping security updates up

@ghost
Copy link

ghost commented Jun 19, 2016

I move that we should use json exclusively, drop tga/jpg/bmp/pcx in favor of crushed PNGs because it's the standard, and move the entire ui/cgame interface system to GTK.

@aisouard
Copy link
Contributor

aisouard commented Jun 19, 2016

If that idea wasn't mentionned before, we can still embed Chromium with CEF to make HTML5 and JS user interfaces.

https://twitter.com/aisouard/status/729595212721467392

How much bloated does that sound for you ? :p

Well, this crashes the sound system and locks the mouse while being ingame under Linux.

@mrwonko
Copy link
Contributor Author

mrwonko commented Jun 19, 2016

Something like QML sounds fine to me. Actually an argument could be made for QML/QtQuick itself, if we ignore that it increases our binary size by an order of magnitude.

@Razish
Copy link
Member

Razish commented Jun 19, 2016

Format aside, the other points in the issue are specifically related to cgame/ui.
It would almost certainly require a fairly large rewrite breaking any notion of compatibility. This puts it out of scope of OpenJK IMO, as nice as it would be to have everything fixed.

AlexCS1337 pushed a commit to AlexCS1337/smUJK that referenced this issue Aug 4, 2022
TomArrow pushed a commit to TomArrow/jaPRO that referenced this issue Jan 19, 2024
* superheavy damage nerf, superheavy knockback reduce, class based knockback scale, class based push scale

also half energy gained by pills if you are using protect

(cherry picked from commit 5e5476b)

* tribes class detection tweak

(cherry picked from commit 1fa4036)

* tribes respawn delay

discjump nerf
light items fix
bowcaster flag punt

(cherry picked from commit 2231ab1)

* no respawntimer in tffa

(cherry picked from commit b716ff8)

* nugget gives items, integer mins/maxs

(cherry picked from commit 46de6d0)

* Move some functions being declared across the game module multiple times to the game module local header file

* Move previously added tribes long sabers down a block

---------

Co-authored-by: videoP <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

9 participants