[kovarex] [1.1.34] Upgrading underground belt twice does not upgrade other side

This subforum contains all the issues which we already resolved.
Post Reply
AjayGhale
Burner Inserter
Burner Inserter
Posts: 5
Joined: Thu Nov 16, 2017 2:44 pm
Contact:

[kovarex] [1.1.34] Upgrading underground belt twice does not upgrade other side

Post by AjayGhale »

So, i think this is a bug. Actually I play Space Ex+ K2 , but I think its a core mechanism so...
I have an upgrade planner for belt. Everything yellow to red, then every red to blue (splitters, undergrounds too).
All the color upgrades in one planner.
The problem is, if I select a pair of underground yellow belt, to make it red, and before the bots upgrade it, I select only 1 side of the underground belt, to upgrade it again to blue, it will be then marked for upgrade, the bots do it, but only 1 selected side of the pair. After this the pair will be not a pair anymore. If I select the other side to be upgraded too, they make it, and it will connect up again.

Question: Isnt it better to mark both sides to upgrade instead of one? Also if I have belt braiding it can mix up everything.

Xoriun
Inserter
Inserter
Posts: 48
Joined: Wed Apr 01, 2020 11:31 am
Contact:

Re: Underground Belt Upgrade

Post by Xoriun »

I'm really interested what the answer will be here as there is a similar behavior when deleting the upgrade on only one of the sides. One side will be upgraded, the other one stays and they are disconnected.
There were bugreports about that (96480, 95772, 70011) which were flagged as 'works as intended'. But I (and others) really don't see any cases where this would be desired.
Last edited by Xoriun on Mon Jun 14, 2021 7:51 pm, edited 1 time in total.

AjayGhale
Burner Inserter
Burner Inserter
Posts: 5
Joined: Thu Nov 16, 2017 2:44 pm
Contact:

Re: Underground Belt Upgrade

Post by AjayGhale »

Yeah, I read that, but this is not cancelled upgrade. This is a double upgrade. Or If u play modded, u have 4-5-6 different belt speeds, so......

kovarex
Factorio Staff
Factorio Staff
Posts: 8058
Joined: Wed Feb 06, 2013 12:00 am
Contact:

Re: [kovarex] [1.1.34] Upgrading underground belt twice does not upgrade other side

Post by kovarex »

Thanks for the report, it is now fixed for the next release.

Xoriun
Inserter
Inserter
Posts: 48
Joined: Wed Apr 01, 2020 11:31 am
Contact:

Re: [kovarex] [1.1.34] Upgrading underground belt twice does not upgrade other side

Post by Xoriun »

Just curious: Was only the additional-upgrade-bug fixed or was the 'cancel-bug/feature/inconsistency/however you want to call it' changed as well?

AjayGhale
Burner Inserter
Burner Inserter
Posts: 5
Joined: Thu Nov 16, 2017 2:44 pm
Contact:

Re: [kovarex] [1.1.34] Upgrading underground belt twice does not upgrade other side

Post by AjayGhale »

Hell yeah brother, Im the best. I found a bug in this world'sbest game :D:D

ps. I think the cancelling thing is intended, so only the real upgrade will be fixed.

kovarex
Factorio Staff
Factorio Staff
Posts: 8058
Joined: Wed Feb 06, 2013 12:00 am
Contact:

Re: [kovarex] [1.1.34] Upgrading underground belt twice does not upgrade other side

Post by kovarex »

All combination of ghost/non-ghost on left/right upgrade/downgrade side should work, and it always takes the final upgrade into consideration when deciding whether it is connected or not for the sake of this logic.

For those who might be curious, I tend to do these kind of tests when fixing bugs like this.

Code: Select all

  TestScenario scenario(CreatePlayer::Yes);
    setupUpgradePlanner(scenario);
    MapPosition leftPosition(-2.5, 0.5);
    MapPosition rightPosition(2.5, 0.5);
    for (GhostMode leftMode : {GhostMode::False, GhostMode::True})
      for (GhostMode rightMode : {GhostMode::False, GhostMode::True})
        for (bool upgradeLeft : {false, true})
        {
          auto checkBoth = [&](const char* name)
          {
            CHECK_EQUAL(scenario.getEntity(leftPosition)->getUsefulEntity()->getUpgradeTargetIDWithFallback()->name, name);
            CHECK_EQUAL(scenario.getEntity(rightPosition)->getUsefulEntity()->getUpgradeTargetIDWithFallback()->name, name);
          };

          scenario.addEntity("underground-belt", leftPosition, leftMode, Direction::East);
          scenario.addEntity("underground-belt", rightPosition, rightMode, Direction::West);
          scenario.perform(InputAction::Upgrade, ActionData::SelectUpgradeData(BoundingBox(upgradeLeft ? leftPosition : rightPosition, 1)));
          checkBoth("fast-underground-belt");
          scenario.perform(InputAction::Upgrade, ActionData::SelectUpgradeData(BoundingBox(upgradeLeft ? leftPosition : rightPosition, 1)));
          checkBoth("express-underground-belt");
          scenario.perform(InputAction::Upgrade, ActionData::SelectUpgradeData(BoundingBox(upgradeLeft ? leftPosition : rightPosition, 1), UpgradeMode::Downgrade));
          checkBoth("fast-underground-belt");
          scenario.perform(InputAction::Upgrade, ActionData::SelectUpgradeData(BoundingBox(upgradeLeft ? leftPosition : rightPosition, 1), UpgradeMode::Downgrade));
          checkBoth("underground-belt");
          scenario.clearEntities();
        }
Edit: But ... right, I considered upgrade and downgrade, but not cancel upgrade, which is still broken. Omg this game is complicated :)

Xoriun
Inserter
Inserter
Posts: 48
Joined: Wed Apr 01, 2020 11:31 am
Contact:

Re: [kovarex] [1.1.34] Upgrading underground belt twice does not upgrade other side

Post by Xoriun »

@kovarex Just to clarify: is the current cancle upgrade behavior intended or not?
In the above mentioned bugreports it was always marked a 'works as intended' but you just said it was unintended/bug.
I'd be glad to file this as a new bugreport.

kovarex
Factorio Staff
Factorio Staff
Posts: 8058
Joined: Wed Feb 06, 2013 12:00 am
Contact:

Re: [kovarex] [1.1.34] Upgrading underground belt twice does not upgrade other side

Post by kovarex »

Xoriun wrote:
Tue Jun 15, 2021 10:47 pm
@kovarex Just to clarify: is the current cancle upgrade behavior intended or not?
In the above mentioned bugreports it was always marked a 'works as intended' but you just said it was unintended/bug.
I'd be glad to file this as a new bugreport.
It was marked as working as intended, but I disagree. Since the fix is not really complicated, it just makes sense for the bost ends to "stay together" when possible.
No need to file another bug report, the fix is going to happen.

Xoriun
Inserter
Inserter
Posts: 48
Joined: Wed Apr 01, 2020 11:31 am
Contact:

Re: [kovarex] [1.1.34] Upgrading underground belt twice does not upgrade other side

Post by Xoriun »

I just checked the behavior in 1.1.35:
The reported bug is fixed but the cancel bug is still in the game.
Also, upgrading a pair of ug-belt by only selecting one of them doesn't work at all in editor mode (is this intentional or new report?).

kovarex
Factorio Staff
Factorio Staff
Posts: 8058
Joined: Wed Feb 06, 2013 12:00 am
Contact:

Re: [kovarex] [1.1.34] Upgrading underground belt twice does not upgrade other side

Post by kovarex »

The cancel part is now fixed for 1.1.35

Xoriun
Inserter
Inserter
Posts: 48
Joined: Wed Apr 01, 2020 11:31 am
Contact:

Re: [kovarex] [1.1.34] Upgrading underground belt twice does not upgrade other side

Post by Xoriun »

Awesome, thanks!!

Post Reply

Return to “Resolved Problems and Bugs”