Loading...
  OR  Zero-K Name:    Password:   

project start

8 posts, 364 views
Post comment
Filter:    Player:  
sort
im starting a two part project to track the high water mark on the numbers total produced of each unit made during battles.

possibly using something like Spring.GetTeamUnitsCounts

my aim will be to then translate this into a mod that reduces costs based on how infrequently the unit is made.. so if a unit is made 1% of all units 50% of games then it will be 1%/50% = 0.5% of original price

ill also factor in the original cost so that if the unit costs allot it is affected less since expencive units are typicaly produced less

along the way im going to need help so i concider this an open project

i hope it may also help as a feedback for balance patches
+6 / -0


26 days ago
It's a neat idea. We've only avoided doing it for theoretical reasons. Might you want to try tracking the total number built, rather than the high point?
+2 / -0
yes the total built makes much better sense thanks =)

just sorting out some irl stuff. then ill have more time.
+0 / -0
21 days ago
It's better to track the metal invested into a unit rather than the number built. Then you have already considered the different costs.
+0 / -0
yes i agree so long as the metal spent is tracked per unit so that the unit type is also tracked =) this is a good idea thanks as it will reflect players choices to spend metal on said units.

https://springrts.com/wiki/Lua_SyncedRead

now to find some code that can track this..

i think know how to create and store local data too
+0 / -0
18 days ago
new problem: how to persistently save a varable between games?

its possible to save a varable in game and keep it updated but when the game ends the value is lost.

im aware planet wars uses persistent data. anyone know any information on this?

thanks
+0 / -0


17 days ago
Depending on the desired lifetime of the variable, you can save it to two places:
  • Send it to the chobby lua state. Grep luamenu in LuaUI widgets (probably) and look in chobby for the way to send it back.
  • Save it to a file and read it later. See how chobby saves the campaign.
+1 / -0
8 days ago
thank you! sorry for the late reply i have been away. i do not yet fully understand whats involved but i will do as you say and look into this
+0 / -0