03-22-2018, 05:13 PM
Hey there folks. Well, as I mentioned back in my dice rework thread, I have time to start working on some small projects. Yesterday I took a look at the docking module plugin, and I think I have a few suspicions as to why it was causing issues.
Docking Module Rewrite
I intend on keeping this thread updated with the progress that I make with the plugin. Yesterday I managed to get a large chunk of work done, so later today I should be able to see some results of testing. I make no promises that this approach to organizing the plugin will work, although we won't know until it's attempted I suppose.
I've noticed that there was a lot of extra code in the plugin. Some seeing to be intended for potential features. The backbone behind the plugin itself, is writing data to your ships save file. This information includes data on if you're docked to another ship or not, and data regarding if you're a carrier holding other ships. (Docking and undocking is handled by proxy bases, and the undock Hook)
While this has been proven to work with the event plugin (which uses this same method for some of its cases) - I've decided to replace that method of saving and and writing. Instead using separate file operations instead. (Much like how player bases are saved)
Because of this change, I've designed it so that files are actually saved and loaded a lot less frequently than they were previously, although rest assured, I'll do some extensive testing to make sure that saving less isn't causing bugs or problems
FLHook has never really had issues maintaining lists and maps internally. Will this approach work? Maybe? Maybe not. A lot of the extra features have been removed from the plugin, as I'll make sure it works barebones, before building on top of it.
I am still using some old code which I figure wouldn't cause any problems overall, so I can't be taking terribly much credit. A big thanks to Alley/Any of the other devs who worked on this previously.
I'll keep this thread updated as I work. Again, hopefully I'll be able to get some test results back later today. I'm concerned on how I'll be able to test this in a more populated enviroment. Sounds like something I'll be talking to the Admin team about provided things go well locally.
Docking Module Rewrite
I intend on keeping this thread updated with the progress that I make with the plugin. Yesterday I managed to get a large chunk of work done, so later today I should be able to see some results of testing. I make no promises that this approach to organizing the plugin will work, although we won't know until it's attempted I suppose.
I've noticed that there was a lot of extra code in the plugin. Some seeing to be intended for potential features. The backbone behind the plugin itself, is writing data to your ships save file. This information includes data on if you're docked to another ship or not, and data regarding if you're a carrier holding other ships. (Docking and undocking is handled by proxy bases, and the undock Hook)
While this has been proven to work with the event plugin (which uses this same method for some of its cases) - I've decided to replace that method of saving and and writing. Instead using separate file operations instead. (Much like how player bases are saved)
Because of this change, I've designed it so that files are actually saved and loaded a lot less frequently than they were previously, although rest assured, I'll do some extensive testing to make sure that saving less isn't causing bugs or problems
FLHook has never really had issues maintaining lists and maps internally. Will this approach work? Maybe? Maybe not. A lot of the extra features have been removed from the plugin, as I'll make sure it works barebones, before building on top of it.
I am still using some old code which I figure wouldn't cause any problems overall, so I can't be taking terribly much credit. A big thanks to Alley/Any of the other devs who worked on this previously.
I'll keep this thread updated as I work. Again, hopefully I'll be able to get some test results back later today. I'm concerned on how I'll be able to test this in a more populated enviroment. Sounds like something I'll be talking to the Admin team about provided things go well locally.