Red UI widgets

Red UI widgets

Discuss Lua based Spring scripts (LuaUI widgets, mission scripts, gaia scripts, mod-rules scripts, scripted keybindings, etc...)

Moderator: Moderators

Regret
Posts: 2086
Joined: 18 Aug 2007, 19:04

Red UI widgets

Post by Regret »

eat shit
Last edited by Regret on 05 Aug 2011, 02:40, edited 17 times in total.
Regret
Posts: 2086
Joined: 18 Aug 2007, 19:04

Re: Red UI widgets

Post by Regret »

.
Last edited by Regret on 28 Aug 2009, 22:05, edited 4 times in total.
Regret
Posts: 2086
Joined: 18 Aug 2007, 19:04

Re: Red UI widgets

Post by Regret »

.
Last edited by Regret on 28 Aug 2009, 22:06, edited 8 times in total.
User avatar
Beherith
Posts: 5145
Joined: 26 Oct 2007, 16:21

Re: Red UI widgets

Post by Beherith »

Thanks, I plan to use the orders and build menu framework. Is there a perf penalty compared to normal ones?
Regret
Posts: 2086
Joined: 18 Aug 2007, 19:04

Re: Red UI widgets

Post by Regret »

Beherith wrote:Thanks, I plan to use the orders and build menu framework. Is there a perf penalty compared to normal ones?
Tested by making them show exact amount of info:

Default Spring menu: ~103 fps
Red build menu full of icons: ~96 fps
ZellSF
Posts: 1187
Joined: 08 Jul 2006, 19:07

Re: Red UI widgets

Post by ZellSF »

Is there an easy way to hide buttons you don't want from the orders menu?
Regret
Posts: 2086
Joined: 18 Aug 2007, 19:04

Re: Red UI widgets

Post by Regret »

ZellSF wrote:Is there an easy way to hide buttons you don't want from the orders menu?
In "local function GetCommands()" inside the .lua you have a list of hidden commands.

I'm not sure where to get the whole list of all commands.
You could change line #285 and line #243 in the menu lua file to

Code: Select all

icon.caption = g.ctext..cmd.name.." ID="..cmd.id
to see all displayed ids
Regret
Posts: 2086
Joined: 18 Aug 2007, 19:04

Re: Red UI widgets

Post by Regret »

.
Last edited by Regret on 28 Aug 2009, 22:06, edited 3 times in total.
User avatar
Caydr
Omnidouche
Posts: 7179
Joined: 16 Oct 2004, 19:40

Re: Red UI widgets

Post by Caydr »

Nice and minimalist, I like it.
User avatar
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

Re: Red UI widgets

Post by smoth »

Neat, minor request:

can you make the build and order pictures scale relative to resolution? They are supposed to be squares.(see gundam rts 1.21 for what I mean by square bps)
Regret
Posts: 2086
Joined: 18 Aug 2007, 19:04

Re: Red UI widgets

Post by Regret »

smoth wrote:Neat, minor request:

can you make the build and order pictures scale relative to resolution? They are supposed to be squares.(see gundam rts 1.21 for what I mean by square bps)
When you open up the.lua file of the menu, you'll see a very easy to read config table. Mess with that to get square icons.

I'm guessing by resolution you meant the texture resolution, since games generally have fixed resolution for all icons, I leave it for the game devs/players to mess with the icon sizes as it would be useless to autoadjust.
User avatar
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

Re: Red UI widgets

Post by smoth »

The icons in the current spring can be adjusted to be square in say the old 1024X768 but will look odd in a more modern 1440X990 screen as they will be squashed to meet that aspect ratio.
Regret
Posts: 2086
Joined: 18 Aug 2007, 19:04

Re: Red UI widgets

Post by Regret »

smoth wrote:The icons in the current spring can be adjusted to be square in say the old 1024X768 but will look odd in a more modern 1440X990 screen as they will be squashed to meet that aspect ratio.
?

You want the build menu to display always square icons correct?
To do that set the isx and isy in buildmenu config to same numbers.

This does not use the spring default menu, so there is no random icon squashing afaik.
User avatar
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

Re: Red UI widgets

Post by smoth »

OH! Kick ass!
Regret
Posts: 2086
Joined: 18 Aug 2007, 19:04

Re: Red UI widgets

Post by Regret »

Update: added autoresizing/repositioning according to resolution changes
User avatar
manolo_
Posts: 1370
Joined: 01 Jul 2008, 00:08

Re: Red UI widgets

Post by manolo_ »

edit: could u send me a changelog and the old data, so i could i upload it to springdownloader?
Regret
Posts: 2086
Joined: 18 Aug 2007, 19:04

Re: Red UI widgets

Post by Regret »

manolo_ wrote:edit: could u send me a changelog and the old data, so i could i upload it to springdownloader?
There is no changelog for these widgets. And why the hell would you want older versions?
User avatar
manolo_
Posts: 1370
Joined: 01 Jul 2008, 00:08

Re: Red UI widgets

Post by manolo_ »

Regret wrote:
manolo_ wrote:edit: could u send me a changelog and the old data, so i could i upload it to springdownloader?
There is no changelog for these widgets. And why the hell would you want older versions?
so people with the older widget see that they could to update (yellow), if i dont have the older version they will see this blue circle in the spring downloader for unknown version
Regret
Posts: 2086
Joined: 18 Aug 2007, 19:04

Re: Red UI widgets

Post by Regret »

manolo_ wrote:so people with the older widget see that they could to update (yellow), if i dont have the older version they will see this blue circle in the spring downloader for unknown version
Just add random data into a .lua file and say that is the older version.
User avatar
manolo_
Posts: 1370
Joined: 01 Jul 2008, 00:08

Re: Red UI widgets

Post by manolo_ »

Regret wrote:
manolo_ wrote:so people with the older widget see that they could to update (yellow), if i dont have the older version they will see this blue circle in the spring downloader for unknown version
Just add random data into a .lua file and say that is the older version.
tbh i dont care, but its some kind of service :D and also the downloader will check the luas (i think the checksum of the data) and compare them to the installed one
Post Reply

Return to “Lua Scripts”