EnglishGermanFrenchRussianItalianSpanish
Log inRegister
 
Odd production time remaining text
Post new topic Reply to topic
View previous topic :: View next topic
Author Message
MegaJohnny





Joined: 04 Jun 2008
Posts: 1766 on topic
Location: Manchester, UK
Thank you for registering your game
PostPosted: Sat, 6. Jan 18, 22:31    Post subject: Odd production time remaining text Reply with quote Print

So, this is mostly out of curiosity - but I've been perusing the code for the object detail menu, and found some strange logic for getting the production time left on a production module:
Code:
local remainingtime = "4.2 " .. ReadText(1001, 112)
if proddata.state == "producing" and proddata.remainingtime == 0 then
    local clustermacro = GetComponentData(GetComponentData(menu.object, "clusterid"), "macro")
    if clustermacro == "cluster_a_macro" then
        -- Maelstrom
        remainingtime = "0.9 " .. ReadText(1001, 112)
    elseif clustermacro == "cluster_b_macro" then
        -- Albion
        remainingtime = "4.2 " .. ReadText(1001, 112)
    elseif clustermacro == "cluster_c_macro" then
        -- Omycron Lyrae
        remainingtime = "3.7 " .. ReadText(1001, 112)
    elseif clustermacro == "cluster_d_macro" then
        -- DeVries
        remainingtime = "11.4 " .. ReadText(1001, 112)
    end
else
    remainingtime = ConvertTimeString(proddata.remainingtime , "%h" .. ReadText(1001, 102) .. " %M" .. ReadText(1001, 103) .. " %S" .. ReadText(1001, 100))
end

Where text {1001, 112} is "Ga", with a comment saying it's giga-years. So if a production module is producing, but the remaining time is zero, I suppose this means it produces indefinitely. But every vanillla cluster gets a different fixed "very long time" - is this a funny way of saying it'll stop when the local star dies?!

I'm sure most others have observed this in-game, but I haven't properly played in a while, so this is all unfamiliar to me.


_________________
My Steam profile
Back to top
View user's profile Send private message
UniTrader
Moderator (Script&Mod)
Moderator (Script&Mod)

MEDAL

Joined: 20 Nov 2005
Posts: 13529 on topic

Thank you for registering your game
PostPosted: Sun, 7. Jan 18, 14:39    Post subject: Reply with quote Print

yep, thats the Display Logic for Solar Power Plants or "a funny way of saying it'll stop when the local star dies".


_________________
if not stated otherwise everything i post is licensed under WTFPL

Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter Wink

I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help Wink
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic Reply to topic
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum
Control Panel
Login Data
The time now is Sat, 20. Jan 18, 11:20

All times are GMT + 2 Hours


Board Security

Copyright © EGOSOFT 1989-2018
Powered by phpBB © 2001, 2005 phpBB Group
Template created by Avatar & BurnIt!
Debug: page generation = 0.05095 seconds, sql queries = 16