Map info to file deprecated


Easy output map info to a file, for you to use in your streaming overlay.

Utilities
5 years ago
0.16
6

g The in-game information is needing a bit of review

5 years ago

First of all, it shows as homepage /mod/ForceFields2 (as instructed by your github.../MapInfoToFile/info.json) ... At least i could use that to access your user page, where it shows all the mods you've authored. :)

Then the description is a bit too short. Doesn't say what kind of information, where it outputs it, or how often. Or if i can use a hotkey or a console command to force an update without waiting the full minute.

And this one is not about the in-game information that is visible in the mod page, but about the actual code: the "aftherDecimalPoint" ( which should REALLY be "afterDecimalPoint" ^^ ) will probably drop leading zeroes, so that 42.0092% will be shown as 42.92%... won't it?

5 years ago

PS I just found a fix for the last point above in one of Tarrke's mods : string.format("%04d", afterDecimalPoint). Actually, make that string.format("%0" .. precision .. "d", afterDecimalPoint), to support having precision as a configurable setting! ;)

And i haven't mentioned this earlier, because i don't know if it's possible, but i really hate that second = tick/60 thing. Though, i consistently see that "60 UPS" assumption everywhere i check, but i really think there should be something more robust than an assumption. :-\

5 years ago
(updated 5 years ago)

Yes, thats just what I did, was about to upload a new version ;)
local evoFactor = "" .. beforeDecimalPoint .. "." .. string.format("%0"..precision.."d", afterDecimalPoint) .. " %"

EDIT: I can take game speed into account to get the actual ups... If I do that, but when your pc runs slower (single player) there is no fix for that... So thats why the 60 ups assumption, nothing to do about that...

5 years ago

So,

I changed the typo (afther -> after) and now the display will show evolution factor 42.0092 as "42.0091 %" But thats a rounding error becose of how it calculates the power, not a big deal tbh...

In the ingame description I linked to the mod portal and I fixed the link to forcefield mod to this mod.

I leave the 60 tick assumption in there, I might fix this later, keep track of time by updating according to the game speed...

I was also thinking of adding extra outputs, for example power consumption, but if you have any other requests, feel free to ask.

Kind regards
lovely_santa

New response