No problem, glad it worked and helped :)
Config for custom monument not applying after server restartSolved
CaroleenjeI think I finally figured it out. It's quite confusing as there is not much information about how to make the plugin work correctly with the custom monuments. The most confusing part is that once you put a custom monument in your map, next to the regular data file in oxide/data you get another file in oxide/data/CustomVendingSetup that contains the data for the map itself. These two don't seem to understand each other in what order they need to be loaded to the server. I erased the data in the main folder and changed the settings of the vending machines with the edit buttons. They now keep the info over the restart.
After looking into this some more, I'm pretty sure what happened is that you saved the vending machine using a Map data provider before setting up Monument Finder (that's the only way the data/CustomVendingSetup/ folder would have been created). What was supposed to happen in that case is that CVS should have found the Map data provider and used it, before checking whether there's a corresponding monument, thus at least preserving your customizations. However, I found a bug where map data does not load correctly on server boot because it tries to load too early before being able to correctly identify the map name. Since no map data was found, CVS went ahead and assigned a Monument data provider to your VM since it was found to be within a monument as per your MF configuration. Since there was no data associated with the monument, the VM showed vanilla settings.
I have made multiple changes to address this use case which will be in the next revision.
- Fixed the bug where map data doesn't load on server boot. If this was already fixed, it would have produced the result you saw after reloading CVS, which is that the customizations are working, but only for the current map.
- Made it so that when resetting a VM, it re-determines the data provider. This way, once you realize that the VM has a Map data provider when you know you actually want a Monument data provider, you can click Reset and it should automatically switch to a Monument data provider (but with your settings lost), allowing you to subsequently reconfigure it as you intend.
- Improved documentation around setting up custom monuments. Please note that the situation you ran into isn't so much a documentation issue as it is the result of bugs due to insufficient testing because Map data providers are a new feature and the people who requested it didn't respond to my request to beta test it.
There are further improvements that can be made, such as adding an option to migrate a VM from using Map data provider to a Monument data provider without having to Reset the settings, but not prioritizing that right now.
Thank you so much! This makes way more sense now.
I appreciate your input and help, and I'm glad this helped you understand what was going on, and you can now polish it further. I'll be using the custom monument in the future, too, so if there are any other issues, I can always let you know. It's an awesome feature and saves lots of grey hair!
After the changes I did now as last, there have been no more issues over the restarts.
Thanks again :)
Just wanted to report that it works half of the times for me haha.
Quick explanation, I have 2 daily resets scheduled at 03 and 15. After the 03 restart the defualt values are always loaded, and after the 15 restart the values configured by me are lodaded in. No idea whats causing this though.
But an update to alter the time it loads in the plugin as mentioned earlier might fix this :)
If what you are seeing is related to the OP's issue, then that means you have some map data associated with those VMs and that you are relying on that. To test this theory, you can simply click the Edit button to see what data provider is applied. If it says Monument when it doesn't work, then Map when it does work, then you are having the same issue. If you are having that issue, you should remove the map data and reconfigure under the Monument data provider.
You can try the latest version from GitHub here which includes the improvements I talked about above.
https://github.com/WheteThunger/CustomVendingSetup
Yeah this was indeed the case. I apperently had some vending machines saved to map, and some to monuments.
Have set all machines to monuments and hopefully they will be correct after restart now, thanks for your help! :)
Locked automatically
- 1
- 2