Login  Register
 



Post new topicReply to topic Go to page 1, 2  Next
 
Author Message
 PostPosted: 24 Nov, 2007 
 
User avatar

Joined: 13 Mar, 2007
Posts: 7882
Location: Australia
Offline
Hiya, here's the last of the UI mod trilogy I wrote for myself.

Get it at the mod vault! (search for my name under Created By)

It probably wont work on vanilla, so use at your own risk there.

UPDATE! New in V3:
- When no units are selected, it will display your economy efficiency.
- Added anti-Mass Wasteage Upgrade Helper

From the readme:

***************************************
| ADMIRALZEECH'S ECONOMY TOOLS MOD - FA
***************************************

----------------
|Overview

Semicolon (;) key displays EcoInfo panel.
[Shift + ;] activates energy saver Autopause on selected units.
[Ctrl + ;] activates anti-mass wasteage Upgrade Helper on units.
[Ctrl+Shift+;] Toggles AutoMassfabs.


-----------------
| EcoInfo Display

Pressing semicolon [;], will open a panel with the following info:

BASED ON YOUR CURRENTLY SELECTED UNITS:

* M Use: ( 50% ) 10000
- How much mass the units are currently using.
In brackets is percentage of total INCOME.


* M Req: ( 50% ) 10000
- How much mass the unit is requesting.
In brackets is the percentage of total SPENDING.


* E Use: ( 50% ) 10000
- How much energy the units are currently using.
In brackets is percentage of total INCOME.


* E Req: ( 50% ) 10000
- How much energy the unit is requesting.
In brackets is the percentage of total SPENDING.


INFORMATION ON ALL YOUR MASSFABS:
* Fabs ( 10 / 100 ) [AUTO]
- In brackets is how many massfabs are active out of the total
number. Both types are counted as 1 here.
[AUTO] is displayed when the Auto Massfab Manager is active. See below.

* E Use: ( 50% ) 10000
- How much energy your activated massfabs are using.
In brackets is the percentage of total energy income.


RESOURCE PRODUCTION:

If your selected units DO NOT CONSUME mass or energy, then the
display will show how much they're producing instead.

Can be useful if you have a hotkey mapped to Select All Mexes.


ECONOMY EFFICENCY:

If you have NO units selected, then it will display a percentage
showing how efficiently you are supplying your resource needs.

The formula is (Income / Usage)%

So, if the percentage is 200%, then you have twice the income than
you're actually using. So you should use more, or else you will waste
resources when your storage is full.


--------------
| AUTO PAUSER

Sometimes in the game you want to build something that eats up a lot
of resources. You're happy to let things go into negative mass, but you
dont want to bottom out your energy since everything will shut down.

The Auto Pauser will pause construction when your energy is low, and
restart it when your energy is full. So you can get the thing built
in bursts. Of course your energy will yo-yo during this time, so
it's only recommended for special projects.

To use it:
- Select your units
Eg. A nuke silo and all SCUs assisting it.

- FIRST START THE CONSTRUCTION
The Auto Pauser will only work when there is some Progress occuring.

- Press [Shift + ;]
A label "AUTOPAUSE" will appear beneath the units.

- When the item is complete, the auto pauser will deactivate
automatically.
The "AUTOPAUSE" label will dissappear.


----------------
| UPGRADE HELPER

The Upgrade Helper is essentially a reverse AutoPauser for Mass.
This tool is designed to help prevent mass wastage.

Start a unimportant project (eg. upgrading a mex), and then activate
the Upgrade Helper. It will pause the upgrade. When your mass
storage is about to max out, the UpgradeHelper will unpause the
project to try to use up the mass.


To use it:
- Select your units
Eg. One or two mass extractors.

- FIRST START THE CONSTRUCTION
The Upgrade Helper will only work when there is some Progress occuring.

- Press [Ctrl + ;]
A label "UPGHELPER" will appear beneath the units.

- When the item is complete, the upgrade helper will deactivate
automatically.
The "UPGHELPER" label will dissappear.



----------------------
| AUTO MASSFAB MANAGER

Automatically turns mass fabricators on and off based on how much
energy you have.

The algorithm I use is pretty basic and slow, but does the job. You
may want to use other peoples' mods for this, so this feature DEFAULTS
TO OFF.

Activate it by pressing [Ctrl + Shift + ;] You need to do this at the
start of every game.

The manager scans for new massfabs when you press [;] to open the
EcoInfo panel. So when you're building new massfabs, YOU NEED TO
TOGGLE THE ECOINFO PANEL TO REGISTER THE NEW MASSFABS.

You should develop an intuitive reaction - build a bunch of massfabs,
your energy plummets, you go "WTF!?!?" and open the EcoInfo panel to
see what's going on, and magically everything's alright again :P



-----------------------
| Key and Function List

[;] (Semicolon key)
- Toggles the EcoInfo panel
- When the panel is OPENING, it will scan for new massfabs to register
into the massfab manager.

[Shift + ;]
- Activates Energy Saver Autopause on selected units.
- The only way to turn off Autopause is to either let the unit
complete its task, or give it the STOP command.

[Ctrl + ;]
- Activates Mass Upgrade Helper on selected units.
- The only way to turn off the Upgrade Helper is to either let the unit
complete its task, or give it the STOP command.

[Ctrl+Shift+;]
- Toggles AutoMassfab Manager.
- This defaults to off, so you need to activate it when you want to
use it.



-----------------------
| Tips and notes

You might be curious about exactly how the algorithms I use work.

*** AutoMassfab Manager ***
It's tuned to use up any energy that would be wasted. So when your
energy storage is full, it will activate massfabs until your net
energy income is just above zero.

If your energy storage goes below 90%, it will turn off all massfabs
and let your energy refill.

Since T2 fabs are more efficient in FA, whenever it can replace a T3
fab with T2 fabs that use the same amount of energy, it will shut down
the T3 Fab in favour of the T2 ones. Your mass income should
increase.

Although you shouldnt build T3 Fabs in the first place in FA :P


*** Auto Pauser ***
When your energy storage is below 70%, it will pause construction (as
if you pressed the Z key) on the affected units. When your energy is
above 90%, it will unpause the construction.

The AutoPauser will remove itself from the unit when the unit's has
completed its current item.


*** Upgrade Helper ***
The Upgrade Helper starts with a paused project(s). If your mass storage
reaches 99%, all the units will unpause. They will pause again if
your mass OR energy storage goes below 70%.

Sadly the Upgrade Helper isnt intelligent enough to only unpause
enough units to use up your excess income. So dont set too many
projects at the same time, because they will all build slower. You
want to set enough projects to soak up all your excess mass, though.


------------------
| The End

This mod is mainly for my own comfort and use, so it's provided "As
is". However, if you have a feature request and have a good reason
for it, tell me and I'll think about it.

Of course, Bug Reports are always welcome.


This mod was written using EmacsW32, together with lua-mode.el

Bye-Be!
-AdmiralZeech

_________________
MY UI MODS (for FA):
- GAZ_UI Mod (formerly Goom's UI mod, aka GUI)
- Tiered Grouping and Cascade Fire
- Economy Info, Auto Pauser and Auto Massfabs

http://forums.gaspowered.com/viewtopic.php?p=320240


Last edited by AdmiralZeech on 19 Apr, 2008, edited 2 times in total.

Top
 Profile  
 PostPosted: 24 Nov, 2007 
 
User avatar

Joined: 15 Feb, 2007
Posts: 2737
Location: Germany
Offline
Very cool. (though using Emacs ist a WTF of its own...)


Speaking of the Mod: What are the keys in German Supcom? Look at the layout... there's no Semicolon/Shift-Semicolon, as Semicolon is Shift-Comma.

Image

_________________
Forged Alliance Forever
The Community Driven Supreme Commander Lobby - public beta!
Image


Top
 Profile  
 PostPosted: 24 Nov, 2007 
 
User avatar

Joined: 13 Mar, 2007
Posts: 7882
Location: Australia
Offline
Hmm, I have no idea. Have a look at
N:\#GameDirs\ForgedAlliance\extracted_gamedata\lua\keymap\

keynames.lua and properkeynames.lua

You might need to do some hacking and experimenting to figure it out.


PS. Emacs is teh win.

_________________
MY UI MODS (for FA):
- GAZ_UI Mod (formerly Goom's UI mod, aka GUI)
- Tiered Grouping and Cascade Fire
- Economy Info, Auto Pauser and Auto Massfabs

http://forums.gaspowered.com/viewtopic.php?p=320240


Top
 Profile  
 PostPosted: 20 Dec, 2007 
 

Joined: 19 Nov, 2007
Posts: 25
Offline
Is there any particular reason you decided to have it pause at 70%? Is there an easy way to set this to stop at a lower percentage? (I'll probably dig into the code tonight and probably find it, but there are sometimes interconnection issues)

Is there any way to autopause assist a factory for more than 1 unit?

This isn't an issue with your mod but I just noticed last night that assisting units continue to build a unit/upgrade when the building has paused production, strange... maybe useful, but annoying at the same time.


Top
 Profile  
 PostPosted: 20 Dec, 2007 
 
User avatar

Joined: 08 Jun, 2007
Posts: 3549
Location: Fast as a cobra. Daring as a human cannonball. Bold as a mid-afternoon streaker. It's LURKILY!
Offline
realityflaw wrote:
This isn't an issue with your mod but I just noticed last night that assisting units continue to build a unit/upgrade when the building has paused production, strange... maybe useful, but annoying at the same time.


That's because this is what the game does when you assist a paused project.

Use auto-pause on the units assisting the upgrade, and the assisting units will auto-pause. Use auto-pause on the upgrade alone, and the upgrade alone will auto-pause. Funny how that works.

_________________
Image
No one gives advice with more enthusiasm and less knowledge than an ignorant person. Too often an educated person is one who knows how to be ignorant intelligently.~J.Rayoa


Top
 Profile  
 PostPosted: 03 Jan, 2008 
 

Joined: 09 Oct, 2007
Posts: 392
Offline
GREAT mod. i'd suggest making the delay between massfab activations a lot smaller, though- it takes a long time for 10+ massfabs to reactivate. that is my only complaint. speed it up and it is perfect!


Top
 Profile  
 PostPosted: 04 Jan, 2008 
 
User avatar

Joined: 13 Mar, 2007
Posts: 7882
Location: Australia
Offline
Yeah, I deliberately made the activation very gradual for two reasons that came up during testing:

- When a massfab turns on, the extra mass sometimes causes a project to consume more energy. So I want a bit of a delay before the manager checks again to see if it can turn another fab on.

- I wanted to avoid rapid energy fluctuations caused by lots of fabs turning on and off because it interacts badly with the AutoPause feature.


Since I mostly use fabs just as a little bonus to suck up spare energy, I dont find the slow activation a big deal.

_________________
MY UI MODS (for FA):
- GAZ_UI Mod (formerly Goom's UI mod, aka GUI)
- Tiered Grouping and Cascade Fire
- Economy Info, Auto Pauser and Auto Massfabs

http://forums.gaspowered.com/viewtopic.php?p=320240


Top
 Profile  
 PostPosted: 04 Jan, 2008 
 
User avatar

Joined: 08 Jun, 2007
Posts: 3549
Location: Fast as a cobra. Daring as a human cannonball. Bold as a mid-afternoon streaker. It's LURKILY!
Offline
TNT104 wrote:
GREAT mod. i'd suggest making the delay between massfab activations a lot smaller, though- it takes a long time for 10+ massfabs to reactivate. that is my only complaint. speed it up and it is perfect!
Impossible. That would result in wild fluctuations at high levels of usage without a large storage buffer, and repeated shield/intel drops.

This is a UI only mod. UI-only means it cannot be responsive. If you want a responsive massfab manager, get a sim side mod, and ask everybody to make sure they're using it, or play the AI.

_________________
Image
No one gives advice with more enthusiasm and less knowledge than an ignorant person. Too often an educated person is one who knows how to be ignorant intelligently.~J.Rayoa


Top
 Profile  
 PostPosted: 04 Jan, 2008 
 
User avatar

Joined: 13 Mar, 2007
Posts: 7882
Location: Australia
Offline
Well, to be fair, my mod's algorithm is:

Every second, if there is enough energy for 1 additional fab, turn on the fab.

So it -is- slower than is possible. But I explained my reasons.

_________________
MY UI MODS (for FA):
- GAZ_UI Mod (formerly Goom's UI mod, aka GUI)
- Tiered Grouping and Cascade Fire
- Economy Info, Auto Pauser and Auto Massfabs

http://forums.gaspowered.com/viewtopic.php?p=320240


Top
 Profile  
 PostPosted: 04 Jan, 2008 
 
User avatar

Joined: 08 Jun, 2007
Posts: 3549
Location: Fast as a cobra. Daring as a human cannonball. Bold as a mid-afternoon streaker. It's LURKILY!
Offline
I hit reply . . . and started typing. Then left to eat dinner. So . . . your post wasn't up at that time. :) My bad.

_________________
Image
No one gives advice with more enthusiasm and less knowledge than an ignorant person. Too often an educated person is one who knows how to be ignorant intelligently.~J.Rayoa


Top
 Profile  
 PostPosted: 05 Jan, 2008 
 
User avatar

Joined: 13 Mar, 2007
Posts: 7882
Location: Australia
Offline
You are naughty. Didnt your mother ever teach you not to hit reply and then type your message and then walk away and not post till you come back when posting onto Mod Talk on SupCom forums?

My mom did.

_________________
MY UI MODS (for FA):
- GAZ_UI Mod (formerly Goom's UI mod, aka GUI)
- Tiered Grouping and Cascade Fire
- Economy Info, Auto Pauser and Auto Massfabs

http://forums.gaspowered.com/viewtopic.php?p=320240


Top
 Profile  
 PostPosted: 05 Jan, 2008 
 
User avatar

Joined: 08 Jun, 2007
Posts: 3549
Location: Fast as a cobra. Daring as a human cannonball. Bold as a mid-afternoon streaker. It's LURKILY!
Offline
AdmiralZeech wrote:
You are naughty. Didnt your mother ever teach you not to hit reply and then type your message and then walk away and not post till you come back when posting onto Mod Talk on SupCom forums?

My mom did.
Your mother is a prude.

_________________
Image
No one gives advice with more enthusiasm and less knowledge than an ignorant person. Too often an educated person is one who knows how to be ignorant intelligently.~J.Rayoa


Top
 Profile  
 PostPosted: 31 Jan, 2008 
 

Joined: 12 Nov, 2007
Posts: 63
Offline
Great mod Zeech! Question -- would it be possible to give the user greater control over the 'auto-pause' feature? Like the thresholds for triggering on/off? Maybe even let us yo-yo mass as well? :) :) :) Thanks!


Top
 Profile  
 PostPosted: 31 Jan, 2008 
 
User avatar

Joined: 13 Mar, 2007
Posts: 7882
Location: Australia
Offline
HorizonX wrote:
Great mod Zeech! Question -- would it be possible to give the user greater control over the 'auto-pause' feature? Like the thresholds for triggering on/off? Maybe even let us yo-yo mass as well? :) :) :) Thanks!


Well, for the energy threshold you can open the mod file in notepad and set it to what you like.

I'm thinking of what to do for mass autopause, but I have quite decided what will be useful for me yet. Because there's not really much penalty to letting your mass run negative, unlike energy.

Currently I'm maybe thinking of mass "auto-unpause". Where you set some sort of optional project like upgrading some mexes, and it will unpause them if you get close to wasting mass.

_________________
MY UI MODS (for FA):
- GAZ_UI Mod (formerly Goom's UI mod, aka GUI)
- Tiered Grouping and Cascade Fire
- Economy Info, Auto Pauser and Auto Massfabs

http://forums.gaspowered.com/viewtopic.php?p=320240


Top
 Profile  
 PostPosted: 31 Jan, 2008 
 

Joined: 12 Nov, 2007
Posts: 63
Offline
Oh, look at that! Plaintext lua! You modders have it nice huh :D Thanks for the tip, looking through your code was very educational. ^_^


Top
 Profile  
 PostPosted: 12 Apr, 2008 
 
User avatar

Joined: 13 Mar, 2007
Posts: 7882
Location: Australia
Offline
New version. Now when you select resource producing units, it will display your income.

_________________
MY UI MODS (for FA):
- GAZ_UI Mod (formerly Goom's UI mod, aka GUI)
- Tiered Grouping and Cascade Fire
- Economy Info, Auto Pauser and Auto Massfabs

http://forums.gaspowered.com/viewtopic.php?p=320240


Top
 Profile  
 PostPosted: 19 Apr, 2008 
 
User avatar

Joined: 13 Mar, 2007
Posts: 7882
Location: Australia
Offline
UPDATE! New in V3:
- When no units are selected, it will display your economy efficiency.
- Added anti-Mass Wasteage Upgrade Helper

_________________
MY UI MODS (for FA):
- GAZ_UI Mod (formerly Goom's UI mod, aka GUI)
- Tiered Grouping and Cascade Fire
- Economy Info, Auto Pauser and Auto Massfabs

http://forums.gaspowered.com/viewtopic.php?p=320240


Top
 Profile  
 PostPosted: 20 Apr, 2008 
 
User avatar

Joined: 16 Jun, 2007
Posts: 296
Location: Earth
Offline
Cool mod Zeech. I'll try it as soon as i get home.
Your econ % display looks perfect. :)

_________________
Variety is the spice of the V section of the dictionary.


Top
 Profile  
 PostPosted: 21 Apr, 2008 
 

Joined: 24 Jan, 2008
Posts: 8
Offline
AdmiralZeech, this is a very high quality mod. Thanks!

The thorough documentation is greatly appreciated too. Too often modders leave too much for the user to guess but the way you've done it is perfect.


Top
 Profile  
 PostPosted: 22 Apr, 2008 
 
User avatar

Joined: 13 Mar, 2007
Posts: 7882
Location: Australia
Offline
Heheh, thanks. What I lack in pretty GUI design I make up for in documentation writing :P

_________________
MY UI MODS (for FA):
- GAZ_UI Mod (formerly Goom's UI mod, aka GUI)
- Tiered Grouping and Cascade Fire
- Economy Info, Auto Pauser and Auto Massfabs

http://forums.gaspowered.com/viewtopic.php?p=320240


Top
 Profile  
 PostPosted: 22 Apr, 2008 
 

Joined: 29 Nov, 2007
Posts: 65
Offline
For German Keymapping support

change in mods/EconomyPanel/economypanel.lua

Code:
    local replacementMap = {
    ['Semicolon']          = {action =    'UI_Lua import("/mods/economypanel/economypanel.lua").ShowEcon()'},
    ['Shift-Semicolon']    = {action =    'UI_Lua import("/mods/economypanel/economypanel.lua").AutoPause()'},
    ['Ctrl-Semicolon']    = {action =    'UI_Lua import("/mods/economypanel/economypanel.lua").UpgradeHelper()'},
    ['Shift-Ctrl-Semicolon']    = {action =    'UI_Lua import("/mods/economypanel/economypanel.lua").ToggleAutoFabs()'},
    }


to

Code:
   local replacementMap = {
    ['Y']          = {action =    'UI_Lua import("/mods/economypanel/economypanel.lua").ShowEcon()'},
    ['Shift-Y']    = {action =    'UI_Lua import("/mods/economypanel/economypanel.lua").AutoPause()'},
    ['Ctrl-Y']    = {action =    'UI_Lua import("/mods/economypanel/economypanel.lua").UpgradeHelper()'},
    ['Shift-Ctrl-Y']    = {action =    'UI_Lua import("/mods/economypanel/economypanel.lua").ToggleAutoFabs()'},
    }


maybe it works for the english version too

_________________
greetings Malarkes

:-)


Top
 Profile  
 PostPosted: 22 Apr, 2008 
 
User avatar

Joined: 13 Mar, 2007
Posts: 7882
Location: Australia
Offline
I use the Y key for one of my other mods.

Maybe I'll make Goom's UI mod a requirement for my mods, and then people can remap to whatever they want.

_________________
MY UI MODS (for FA):
- GAZ_UI Mod (formerly Goom's UI mod, aka GUI)
- Tiered Grouping and Cascade Fire
- Economy Info, Auto Pauser and Auto Massfabs

http://forums.gaspowered.com/viewtopic.php?p=320240


Top
 Profile  
 PostPosted: 23 Apr, 2008 
 

Joined: 29 Nov, 2007
Posts: 65
Offline
Ah ok

but is in the english Key layout not z and y on the other place than in german ?

I learn every day more about LUA

It is hard to learn because i have no description about the LUA Commands. have anyone a link to an command description ?

_________________
greetings Malarkes

:-)


Top
 Profile  
 PostPosted: 23 Apr, 2008 
 
User avatar

Joined: 16 Jun, 2007
Posts: 296
Location: Earth
Offline
This is actually really usefull.
I never realised how much mass i've wasted by not building massfabs to soak up my energy.
I got a Mavor in less than an hour without even thinking about it.
Thanks for the awsome mod. :)

_________________
Variety is the spice of the V section of the dictionary.


Top
 Profile  
 PostPosted: 05 May, 2008 
 
User avatar

Joined: 22 Feb, 2007
Posts: 364
Location: Tampa, FL
Offline
Thanks for the mod. Only 'slight' glitch i noticed is that the Upgrade Helper doesn't instantly activate when your mass reaches capacity. Sometimes it waits 10-30 seconds after it reaches capacity.

As for the other 2 though... way cool mods. I love how your mod activates / deacts mass fabs. Keeps everything in check for quick expansion.

_________________
Image
^^ Sig by Wankey^^


Top
 Profile  
Display posts from previous:  Sort by  
Post new topic Reply to topic Go to page 1, 2  Next



Quick Tools

Search for:
Jump to:  

© 2002-2010 Gas Powered Games Corp. All Rights Reserved. Gas Powered Games is the exclusive trademark of Gas Powered Games Corp.
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
 
Home| Games | Company | News & Press | Support
  Terms of Use   |    Copyright Information   |    Privacy Policy