Make shortcut bar more resilient to mod loading and unloading
Moderator: ickputzdirwech
Make shortcut bar more resilient to mod loading and unloading
EDIT: Tips & Tricks are fixed in 1.1.62. Shortcuts are not.
Consider this common scenario:
You start playing a modded save with a mod that adds tips (such as Rate Calculator), and a variety of mods that add shortcuts.
The Rate Calculator tips pop up and you go through them, marking them as read (or you just type `/unlock-tips` to dismiss them all).
You look through the list of shortcuts, enabling some, disabling others, and reordering them to your liking.
You happily play several more hours and finish your play session.
Next time you open the game, you switch to a different set of mods (maybe to join a friend on a multiplayer server, or for some mod development).
Then you go back to your original modded save, sync mods, and now all the tip notifications have reappeared, and your carefully curated shortcut bar is messed up!
---------
This is because all tips and shortcut data is stored in player-data.json. When you load the game, it goes through and deletes all entries that reference a tip or shortcut not found in the currently loaded data, removing all stored information about that tip/shortcut.
I'd like to suggest that this behaviour be changed. This problem was solved for the blueprint library because it used to behave similarly. It was changed so that unknown entities were not deleted, and when that mod was reloaded the unknown entities in the blueprint would reappear.
Tips:
I think these should just not be deleted, leave them in player-data.json.
Shortcuts:
The above solution would work, although personally I'd prefer these to be stored in each save, the same as the quickbar. For me the shortcut ordering and visibility depends on all of the mods in use, as with lots of mods I'd hide shortcuts that I'd otherwise have visible with fewer mods.
Consider this common scenario:
You start playing a modded save with a mod that adds tips (such as Rate Calculator), and a variety of mods that add shortcuts.
The Rate Calculator tips pop up and you go through them, marking them as read (or you just type `/unlock-tips` to dismiss them all).
You look through the list of shortcuts, enabling some, disabling others, and reordering them to your liking.
You happily play several more hours and finish your play session.
Next time you open the game, you switch to a different set of mods (maybe to join a friend on a multiplayer server, or for some mod development).
Then you go back to your original modded save, sync mods, and now all the tip notifications have reappeared, and your carefully curated shortcut bar is messed up!
---------
This is because all tips and shortcut data is stored in player-data.json. When you load the game, it goes through and deletes all entries that reference a tip or shortcut not found in the currently loaded data, removing all stored information about that tip/shortcut.
I'd like to suggest that this behaviour be changed. This problem was solved for the blueprint library because it used to behave similarly. It was changed so that unknown entities were not deleted, and when that mod was reloaded the unknown entities in the blueprint would reappear.
Tips:
I think these should just not be deleted, leave them in player-data.json.
Shortcuts:
The above solution would work, although personally I'd prefer these to be stored in each save, the same as the quickbar. For me the shortcut ordering and visibility depends on all of the mods in use, as with lots of mods I'd hide shortcuts that I'd otherwise have visible with fewer mods.
Last edited by Xorimuth on Mon Dec 12, 2022 12:37 pm, edited 3 times in total.
My mods
Content: Lunar Landings | Freight Forwarding | Spidertron Patrols | Spidertron Enhancements | Power Overload
QoL: Factory Search | Module Inserter Simplified | Wire Shortcuts X | Ghost Warnings
Content: Lunar Landings | Freight Forwarding | Spidertron Patrols | Spidertron Enhancements | Power Overload
QoL: Factory Search | Module Inserter Simplified | Wire Shortcuts X | Ghost Warnings
Re: Make tips&tricks and shortcut bar more resilient to mod loading and unloading
I second this request.
Re: Make tips&tricks and shortcut bar more resilient to mod loading and unloading
A different approach that mostly removes this annoyance would be to save the state of `/unlock-tips` within a save, so that as long as I've typed it once in a save no more tips will appear.
My mods
Content: Lunar Landings | Freight Forwarding | Spidertron Patrols | Spidertron Enhancements | Power Overload
QoL: Factory Search | Module Inserter Simplified | Wire Shortcuts X | Ghost Warnings
Content: Lunar Landings | Freight Forwarding | Spidertron Patrols | Spidertron Enhancements | Power Overload
QoL: Factory Search | Module Inserter Simplified | Wire Shortcuts X | Ghost Warnings
Re: Make tips&tricks and shortcut bar more resilient to mod loading and unloading
Just discovered that this is already solved for mod achievements! How many mods add achievements vs shortcuts or tips...? 64884
My mods
Content: Lunar Landings | Freight Forwarding | Spidertron Patrols | Spidertron Enhancements | Power Overload
QoL: Factory Search | Module Inserter Simplified | Wire Shortcuts X | Ghost Warnings
Content: Lunar Landings | Freight Forwarding | Spidertron Patrols | Spidertron Enhancements | Power Overload
QoL: Factory Search | Module Inserter Simplified | Wire Shortcuts X | Ghost Warnings
Re: Make tips&tricks and shortcut bar more resilient to mod loading and unloading
I totally agree with this for shortcuts. It's so annoying having to constantly disable the ones that show up by default but I never use.
My mods: Multiple Unit Train Control, Smart Artillery Wagons
Maintainer of Vehicle Wagon 2, Cargo Ships, Honk
Maintainer of Vehicle Wagon 2, Cargo Ships, Honk
Re: Make tips&tricks and shortcut bar more resilient to mod loading and unloading
Well now that Oxyd is gone we might get this bug fixed. I reported it a long time ago. I still want it. It still makes no sense to not save which buttons are enabled in the savefile, it's just a handful of bits!!!
My mods: Capsule Ammo | HandyHands - Automatic handcrafting | ChunkyChunks - Configurable Gridlines
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser
Re: Make tips&tricks and shortcut bar more resilient to mod loading and unloading
The importance of fixing this can not be overstated.
-
- Smart Inserter
- Posts: 2768
- Joined: Tue Apr 25, 2017 2:01 pm
- Contact:
Re: Make tips&tricks and shortcut bar more resilient to mod loading and unloading
I would agree with this as well. +1
My Mods: Classic Factorio Basic Oil Processing | Sulfur Production from Oils | Wood to Oil Processing | Infinite Resources - Normal Yield | Tree Saplings (Redux) | Alien Biomes Tweaked | Restrictions on Artificial Tiles | New Gear Girl & HR Graphics
- Stringweasel
- Filter Inserter
- Posts: 416
- Joined: Thu Apr 27, 2017 8:22 pm
- Contact:
Re: Make tips&tricks and shortcut bar more resilient to mod loading and unloading
+1
Alt-F4 Author | Factorio Modder
My Mods: Hall of Fame | Better Victory Screen | Fluidic Power | Biter Power | Space Spidertron | Spidertron Dock |Weasel's Demolition Derby
Official Contributor to Space Exploration
My Mods: Hall of Fame | Better Victory Screen | Fluidic Power | Biter Power | Space Spidertron | Spidertron Dock |
Official Contributor to Space Exploration
Re: Make tips&tricks and shortcut bar more resilient to mod loading and unloading
I concur with this suggestion. Just found out the inconvenience of having shortcut bars reset on changing mod sets.
Re: Make tips&tricks and shortcut bar more resilient to mod loading and unloading
I hope it shows the special importance, when I leave a +1 here.
Re: Make tips&tricks and shortcut bar more resilient to mod loading and unloading
+1 as well. We already have a game setting to "use different mod settings per save", why not allow the use to choose to "use different hotbar and shortcut per save"?
My mods: Multiple Unit Train Control, Smart Artillery Wagons
Maintainer of Vehicle Wagon 2, Cargo Ships, Honk
Maintainer of Vehicle Wagon 2, Cargo Ships, Honk
-
- Burner Inserter
- Posts: 19
- Joined: Sat Jul 02, 2016 7:37 am
- Contact:
Re: Make tips&tricks and shortcut bar more resilient to mod loading and unloading
+1
Could we not just have the ability to directly drag the icons around in the shortcut panel, like you can in the quick bars, and use the current dragable list as just a way of enabling/disabling whatshows in the panel?
At least then you could very quickly sort out the order you prefer.
Cheers,
pine
Could we not just have the ability to directly drag the icons around in the shortcut panel, like you can in the quick bars, and use the current dragable list as just a way of enabling/disabling whatshows in the panel?
At least then you could very quickly sort out the order you prefer.
Cheers,
pine
Re: Make tips&tricks and shortcut bar more resilient to mod loading and unloading
+1 this. Seems perfectly reasonable and seems like logic that should already be in the game.
Re: Make shortcut bar more resilient to mod loading and unloading
I must switch back and forth between mod groups a lot because i work on YARM and it is extremely frustrating that everytime i do, my shortcut bar is just trashd and randomized.
Re: Make shortcut bar more resilient to mod loading and unloading
I use a separate standalone installation for each modpack and don't have this problem.
But, it's merely a workaround
But, it's merely a workaround
Re: Make shortcut bar more resilient to mod loading and unloading
+1
I was about to post same suggestion myself, because I can hardly express how frustrating this is.
When shortcut count passes certain point it becomes impossible to find button you are looking for without introducing some degree of organization in how they are ordered. And as someone who periodically has to switch between heavily modded and pure vanilla playthroughs, I had to create some sort of reference for myself, and then painstakingly rearrange everything each time game decides to show buttons in whichever order mods a getting loaded.
And to be honest every time I get an urge to go implement some new idea in my vanilla megabase, I have to consider if it's really worth it.
---
Thoughts on how to potentially solve this problem and give shortcut bar some kind of memory:
Not sure if shortcut buttons, as UI element, have some sort of unique ID or any way to distinguish them besides icon/text and origin(mod name). If they do, then following algorithm should work:
We have A-B-C-D-E.
We remove C, D and E. Then install F, G and H, which are related to each other(buttons from a single mod for example).
At first everything would be fine and list will looks like A-B-C*-D*-E*-F-G-H.
But if player decides to put G right above F, then since game would pick B as "anchor point" (top-to-bottom), list will turn into A-B-G-C*-D*-E*-F-H.
So when we introduce C,D,E back, thematically related G and F will get separated.
I was about to post same suggestion myself, because I can hardly express how frustrating this is.
When shortcut count passes certain point it becomes impossible to find button you are looking for without introducing some degree of organization in how they are ordered. And as someone who periodically has to switch between heavily modded and pure vanilla playthroughs, I had to create some sort of reference for myself, and then painstakingly rearrange everything each time game decides to show buttons in whichever order mods a getting loaded.
And to be honest every time I get an urge to go implement some new idea in my vanilla megabase, I have to consider if it's really worth it.
---
Thoughts on how to potentially solve this problem and give shortcut bar some kind of memory:
Not sure if shortcut buttons, as UI element, have some sort of unique ID or any way to distinguish them besides icon/text and origin(mod name). If they do, then following algorithm should work:
- Game keeps a list of every shortcut button ever encountered by player, including their enabled/disabled state, mod_ID they are created by and order player arranged them in.
Let's say we initially have a list of three buttons:- A(vanilla)
- B(mod-B)
- C(mod-C)
- When game loads it compares this list to whatever buttons it has to work with currently, and if list includes buttons from mods not currently present, they are ignored but stay where they were in the list. So if we remove mod-B from our example above, game would still remember A-B-C order.
- A(vanilla)
- C(mod-C)
- Adding new buttons would work as usual and they get added to the end of this list. If we install mod-D it should result in A-B-C-D list, while user sees the following:
- A(vanilla)
- C(mod-C)
- D(mod-D)
- But what if player decides to rearrange them in A-D-C order? At this point we have to decide what to do about button from mod-B, that player can't see but game still keeps track of. And any option should probably be valid as long as it's consistently followed. If we choose Bottom-To-Top principle, game picks C as "anchor point" and moves D to first position above C in the list. So what game thinks: A-B-D-C. What player sees:
- A(vanilla)
- D(mod-D)
- C(mod-C)
- This way if we install mod-B back, internal list and shortcut bar presented to user should come to full agreement on what goes where:
- A(vanilla)
- B(mod-B)
- D(mod-D)
- C(mod-C)
We have A-B-C-D-E.
We remove C, D and E. Then install F, G and H, which are related to each other(buttons from a single mod for example).
At first everything would be fine and list will looks like A-B-C*-D*-E*-F-G-H.
But if player decides to put G right above F, then since game would pick B as "anchor point" (top-to-bottom), list will turn into A-B-G-C*-D*-E*-F-H.
So when we introduce C,D,E back, thematically related G and F will get separated.
There is no such thing as unarmed spaceship © Isaac Arthur
-
- Inserter
- Posts: 25
- Joined: Tue Mar 26, 2019 6:13 pm
- Contact:
-
- Long Handed Inserter
- Posts: 62
- Joined: Mon Oct 24, 2022 8:01 pm
- Contact:
Re: Make shortcut bar more resilient to mod loading and unloading
god please fix this. i can't stand having to pick and choose my shortcut bar buttons over and over