[Train GUI] Circuit condition progress bar

Post your ideas and suggestions how to improve the game.

Moderator: ickputzdirwech

ManaUser
Fast Inserter
Fast Inserter
Posts: 225
Joined: Sat Aug 12, 2017 9:41 pm
Contact:

Re: [Train GUI] Circuit condition progress bar

Post by ManaUser »

First let me say that I understand why the developers chose not to implement this, because there is significant ambiguity about what the range should be in various situations.

However, in the specific case of DrParanoia's example I think the range is reasonably clear. I would define that specific case as one where the operator is >= or > and the second operand is a positive constant, X. In this case, I think it's reasonable to assume the range is 0 to X (Or X+1 for >). In case the signal is actually less then zero, it would need handling for that, probably by simply treating it as zero for this purpose.

Nonetheless this still involves guesswork, and might raise questions about why other, less clear, cases aren't also handled. So I can see the argument for leaving it out rather than implementing a less-than-perfect solution like the above.

DrParanoia
Inserter
Inserter
Posts: 37
Joined: Tue Mar 19, 2019 6:25 pm
Contact:

Re: [Train GUI] Circuit condition progress bar

Post by DrParanoia »

Pi-C wrote:
Wed Mar 20, 2019 3:19 pm
Is that what you've actually been looking for?
I look for the exact same behaviour (like the highlighted Item count in your quote) but for the Circuit network parameter. And I actually wait for the boxes to be filled by the unloading train (8 boxes equal to 19200 total ore), also I don't use a comparitor for this, I simply have all the boxes connected directly to the station and I have the "Circuit condition: <Iron ore> >= 19200" set on the train.

Basically this means, that if the train arrives and the boxes are already full, the train moves on, but I also expect for the progress bar on the "Circuit condition: <Iron ore> >= 19200" rule to display to what extent the boxes are filled if the condition is not yet met.

User avatar
Ranakastrasz
Smart Inserter
Smart Inserter
Posts: 2124
Joined: Thu Jun 12, 2014 3:05 am
Contact:

Re: [Train GUI] Circuit condition progress bar

Post by Ranakastrasz »

Here is the list of existing conditions, from the wiki.

Time passed
Inventory full – All inventories of the train are full.
Inventory empty – Same as above, but empty.
Item count – The train (all cargoes summed) contains a specific amount of a certain item.
Circuit condition – The train stop is connectable to the Circuit network, so the signals can used for wait conditions.
Inactivity – No items were added or removed for the specified amount of seconds.
Fluid count – The train (all fluid wagons summed) contains a specific amount of a certain fluid.
Passenger present - At least one player is inside any part of the train.
Passenger not present -

The rule I am using is, the difference between starting value and desired value to trip the condition.

-Time passed. From zero to <Time set>. So 30 seconds would say 50% at 15 seconds.
-Inventory full (or 96% I think?) goes from starting fraction filled to entirely filled. So from 0 slots to 40 slots used, at 20 would be 50%. But if you started with 8 of those slots filled, it would still start at 0%, reach 50% at 24 slots filled, and hit 100% at 40 slots filled.
-Inventory empty. Same as above. 0% at starting value, 50% after half unloading whatever was there, and 100% when it is empty.
-Item Count. Same as Inventory full, or empty, depending on if it is more or less. If it goes in the wrong direction however, just recalculate from the new point after it starts approaching the goal again. So if you set it for 1000 coal, it starts with 550 coal, and 50 is removed, it goes from 0% to 0%. But adding back 50 would give you a full 10% progress.
-Circuit Condition. As Item count. Whatever the comparison, use the difference between current and resultant. This means you can, as a player, setup a progress bar however you want by sending it a conditional with 0-100, with continuation at 100+.
-Inactivity. Just as Time Passed, but resets every time something happens.
-Fluid count. As Item Count.
-Passenger Present/not Present. This is a boolean, so just have an empty/filled box, or a checkbox, or something. This one is literally a boolean and you can't do anything about it. Although replacing it with a Passenger count, with zero being not present, >= 1 being Passenger Present, and allowing a set number of reuquired passengers. Doubt it would add much, but would combine the two easily. Or have "Player Entity" as a cargo type or something.


It can all follow a simple ruleset, be consistent, and still support circuit conditions.
My Mods:
Modular Armor Revamp - V16
Large Chests - V16
Agent Orange - V16
Flare - V16
Easy Refineries - V16

DrParanoia
Inserter
Inserter
Posts: 37
Joined: Tue Mar 19, 2019 6:25 pm
Contact:

Re: [Train GUI] Circuit condition progress bar

Post by DrParanoia »

Okay, I will try to explain what I mean with an image. Please look at the following situation:

Image

So, the question is: Why there is a progress bar for Iron plates and there is no (or even can't be) a progress bar for Copper plates? I perceive it as a bug :(
Last edited by DrParanoia on Sat Mar 23, 2019 10:34 am, edited 2 times in total.

Trebor
Filter Inserter
Filter Inserter
Posts: 288
Joined: Sun Apr 30, 2017 1:39 pm
Contact:

Re: [Train GUI] Circuit condition progress bar

Post by Trebor »

The copper progress bar is correctly showing 0 of 1K loaded in the cargo wagon.

DrParanoia
Inserter
Inserter
Posts: 37
Joined: Tue Mar 19, 2019 6:25 pm
Contact:

Re: [Train GUI] Circuit condition progress bar

Post by DrParanoia »

Trebor wrote:
Thu Mar 21, 2019 9:32 pm
The copper progress bar is correctly showing 0 of 1K loaded in the cargo wagon.
Please explain. Why showing copper as 0 is correct while the iron is showing 50% progress? Conditions are exactly the same.

Trebor
Filter Inserter
Filter Inserter
Posts: 288
Joined: Sun Apr 30, 2017 1:39 pm
Contact:

Re: [Train GUI] Circuit condition progress bar

Post by Trebor »

DrParanoia wrote:
Thu Mar 21, 2019 9:45 pm
Trebor wrote:
Thu Mar 21, 2019 9:32 pm
The copper progress bar is correctly showing 0 of 1K loaded in the cargo wagon.
Please explain. Why showing copper as 0 is correct while the iron is showing 50% progress? Conditions are exactly the same.
There is no copper in the cargo wagon. Add a stack of copper and see what happens.

Pi-C
Smart Inserter
Smart Inserter
Posts: 1645
Joined: Sun Oct 14, 2018 8:13 am
Contact:

Re: [Train GUI] Circuit condition progress bar

Post by Pi-C »

Trebor wrote:
Thu Mar 21, 2019 9:49 pm
DrParanoia wrote:
Thu Mar 21, 2019 9:45 pm
Trebor wrote:
Thu Mar 21, 2019 9:32 pm
The copper progress bar is correctly showing 0 of 1K loaded in the cargo wagon.
Please explain. Why showing copper as 0 is correct while the iron is showing 50% progress? Conditions are exactly the same.
There is no copper in the cargo wagon. Add a stack of copper and see what happens.
Actually, DrParanoia has a point: The station has two inputs. It can read from the train (ID + inventory) and from everything connected by wire, so the station should see 500 iron and 500 copper plates. Nevertheless, the setup shouldn't work because the station will see the two inputs combined. So if the box is empty and a train with 1k copper + 1k iron plates arrives, the train should leave immediately because the station can't know that everything is on the train and nothing in the box. For this, train contents and box contents would have to be isolated -- and that would require some kind of combinator setup again that sends a virtual signal to the station once the box contains >= 1k copper plates.
A good mod deserves a good changelog. Here's a tutorial (WIP) about Factorio's way too strict changelog syntax!

DrParanoia
Inserter
Inserter
Posts: 37
Joined: Tue Mar 19, 2019 6:25 pm
Contact:

Re: [Train GUI] Circuit condition progress bar

Post by DrParanoia »

Please look at the image carefully.

1) The Iron plates are read from the cargo. Condition is "Cargo: <Iron plates> => 1000"; cargo wagon has 500 plates; 500/1000 = 0.5 = 50% progress;

2) The coper plates signal is read from the circuit. Condition is "Circuit signal: <Copper plates> => 1000"; chest has has 500 plates = 500 copper plates circuit signal; 500/1000 = 0.5 = 50% progress, but the progress is not displayed; If you put 1000 copper plates inside that chest though, the progress instantly jumps to 100%;

jim lee
Long Handed Inserter
Long Handed Inserter
Posts: 57
Joined: Wed Feb 13, 2019 6:25 am
Contact:

Re: [Train GUI] Circuit condition progress bar

Post by jim lee »

Show us what the train-stop is set to. Also, if that's correct, try placing a power pole in the box/trainstop circuit. Lets have a look at what's being sent on the network.

-jim lee

DrParanoia
Inserter
Inserter
Posts: 37
Joined: Tue Mar 19, 2019 6:25 pm
Contact:

Re: [Train GUI] Circuit condition progress bar

Post by DrParanoia »

jim lee wrote:
Fri Mar 22, 2019 7:51 pm
Show us what the train-stop is set to. Also, if that's correct, try placing a power pole in the box/trainstop circuit. Lets have a look at what's being sent on the network.

-jim lee
Here is the updated image. I've also added some more conditions to the train to illustrate the problem better.

Image

Post Reply

Return to “Ideas and Suggestions”