• Home
  • Index
  • Search
  • Download
  • Server Rules
  • House Roleplay Laws
  • Player Utilities
  • Player Help
  • Forum Utilities
  • Returning Player?
  • Toggle Sidebar
Interactive Nav-Map
Tutorials
New Wiki
ID reference
Restart reference
Players Online
Player Activity
Faction Activity
Player Base Status
Discord Help Channel
DarkStat
Server public configs
POB Administration
Missing Powerplant
Stuck in Connecticut
Account Banned
Lost Ship/Account
POB Restoration
Disconnected
Member List
Forum Stats
Show Team
View New Posts
View Today's Posts
Calendar
Help
Archive Mode




Hi there Guest,  
Existing user?   Sign in    Create account
Login
Username:
Password: Lost Password?
 
  Discovery Gaming Community Discovery Development Discovery Developers Forum Discovery Unofficial Development Discovery Mod FLHook Projects
1 2 Next »
[FLHook] Docking Modules Rewrite

Server Time (24h)

Players Online

Active Events - Scoreboard

Latest activity

Pages (6): 1 2 3 4 5 6 Next »
[FLHook] Docking Modules Rewrite
Offline Remnant
03-22-2018, 05:13 PM, (This post was last modified: 03-22-2018, 05:15 PM by Remnant.)
#1
Member
Posts: 2,206
Threads: 248
Joined: Apr 2012

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.
Reply  
Offline Epo
03-22-2018, 05:27 PM,
#2
Member
Posts: 1,706
Threads: 109
Joined: Jul 2014

Good luck! And you've got my full support as I'd love to see them working again. Again, thanks a lot man!
Reply  
Offline Sand-Viper
03-22-2018, 05:36 PM,
#3
Member
Posts: 1,937
Threads: 102
Joined: Nov 2007

I salute you for your dedication, @Remnant! I would absolutely love to be able to hide a snub onboard my Bison. Docking modules are something I never got to play with, and they have good potential for smuggling people through areas that might otherwise be hostile to them. I wish you warm winds and highest luck in this endeavor!

The Gaelic Wyvern Inn
If you've interacted with us recently, please consider checking out our in-character Public Guest Reviews thread!
Reply  
Offline Vexykin
03-22-2018, 05:46 PM, (This post was last modified: 03-22-2018, 06:26 PM by Vexykin.)
#4
Member
Posts: 2,069
Threads: 194
Joined: Jan 2010

Good luck, would be awesome to have Docking Modules back really, since they would open up many new possibilities strategy-wise

Tutorial Database
Liberty Rogues Official Discord:
https://discord.gg/Wt2RqVJ

Feel free to PM this account if you have any questions, I'm here to help!

Reply  
Offline Sciamach
03-22-2018, 06:23 PM,
#5
Member
Posts: 1,643
Threads: 114
Joined: Jul 2013

A large number of my ships that survived activity wipes have docking mods on them- so this working would be a great boon to my wallet

Kidding aside: docking mods were a great inclusion to the game and when they worked, made rapid strike deployment useful through the use of shared accounts. Best of luck in getting it working mate~<3

[ sci·am·ach ]
/sīˈamək/
A simple, angry man casually working his way through life on a personal quest to acquire copious amounts of street cred.
Reply  
Offline Remnant
03-23-2018, 12:51 AM, (This post was last modified: 03-23-2018, 06:33 AM by Remnant.)
#6
Member
Posts: 2,206
Threads: 248
Joined: Apr 2012

Alright, I've worked on and off for a few hours and have made some headway. Currently the plugin is functioning again with the following features
  • Can request dock on a vessel with docking modules
  • Carrier ships get a notification, and can approve said ship, docking the snub aboard
  • Carriers can dock as many ships, as the number of modules they have mounted.
  • Snubs can now undock and appear outside of the carrier (This was causing crashes for a while. Thank god that's fixed)

You might say that these are features which existed previously! - You're absolutely right. That's the core behind the plugin, more or less. I'm simply making some of the internal operations work differently, in hopes that the server bugs won't come up with this version.



Todo list
  • /jettisonship command - Allowing user to eject docked ships
  • If the carrier is currently docked, the nested ship should undock outside of the base the carrier is in.
  • If the carrier is blown up, all of the docked ships should be ejected out into space
  • Write saving/loading commands. (Handling if players disconnect, reconnect, or if the server restarts) -- I expect this to take the longest

That, and obviously porting over some of the anti-exploit functions of the old plugin.

This so far is still a re-write. Not an upgrade. Maybe some shiny features will appear on the list if the plugin is restored to the same functionality that it had previously, and is proven not to cause problems.



I've got some work for Uni' I've gotta deal with. I'll get back to this tomorrow.



Edit: Time to get to bed for real. Finished a few more features.
  • /jettisonship now works. - You may not use this command while docked. (Although this is probably gonna change)
  • If a carrier is docked, if you undock as a nested ship, you're automatically docked with the planet/station the carrier is on.
Reply  
Offline Remnant
03-24-2018, 01:04 AM,
#7
Member
Posts: 2,206
Threads: 248
Joined: Apr 2012

This is going a little more smoothly than I was expecting it to. All of the planned core features are now implemented, besides persistence between disconnects, reconnects, and restarts. - The framework for the remaining part is already in place, so I should have everything completed by tomorrow or the following day.

Afterwards, there'll be a small period of testing (quite literally me doing everything possible in an attempt to break the plugin) - Provided that things go well, I'll wrap things up and call this rework ready for implementation!

I'll consider additional features afterwards.
Reply  
Offline Mephistoles
03-24-2018, 02:19 AM,
#8
Gas Miners Guild
Posts: 2,346
Threads: 91
Joined: Jun 2013

Properly functioning docking modules is a plugin in high demand. I'm really looking forward to being able to utilise them as intended. Let me know if you need help testing.

Sigma & GMG Discord Chat: https://discord.gg/d4j3W4v

[Image: stDvDRX.jpg]
Reply  
Offline Durandal
03-24-2018, 03:06 AM,
#9
Member
Posts: 5,106
Threads: 264
Joined: Apr 2009

The issue with docking modules is that they were causing the infinite jump bug. Do you have any idea which piece of the code was causing this and why, and whether or not it can actually be replicated in singleplayer?
Reply  
Offline Remnant
03-24-2018, 03:29 AM, (This post was last modified: 03-24-2018, 03:35 AM by Remnant.)
#10
Member
Posts: 2,206
Threads: 248
Joined: Apr 2012

No. It cannot actually be replicated in singleplayer. Although you can't properly test/run the docking module plugin from singleplayer anyways. You kinda need FLHook running in the background.
Testing is being done on a local server with the plugin loaded. Regarding it being in a live setting, we'll simply have to try it. It takes 10 seconds to disable/remove the plugin if it still causes a server-wide bug.

Regarding the infinite jump bug in general, while I cannot say with 100% certainty that I know exactly what was causing it. However that being said, I did have a few ideas.

Yes. This is a stab in the dark (An educated one). Although I guarantee that enough of the internal fundamentals of the plugin have been changed enough, where I'd be rather surprised if the bug persisted. It may still happen, and if it does, we'll simply disable this rework as well.

The biggest difference between this version, and the old version, is ships save files are no longer being saved to. Instead, data is being stored to a directory in the filesystem much like how playerbases are saved currently. - The rate at which things are saved and loaded, is also drastically reduced. (I'll make sure that it's happening often enough, though. It comes down to figuring out which triggers are needed, and which are not)

FLHook has never had problems maintaining maps and lists before. I'm forcing the plugin to rely more on the standard FLHook functions, without constantly having it read the save files of each individual ship on the list.



@Mephistoles - I'll throw you a compiled plugin once I'm confident that things are all set. I'd really appreciate someone else looking around to see if I missed any bugs. - If you don't think you can do it easily on your own, I'll see about hosting a temporary server somewhere with it running.



[+]StillNotEnoughScreensForThisCrap.jpg
[Image: image.jpg]
Reply  
Pages (6): 1 2 3 4 5 6 Next »


  • View a Printable Version
  • Subscribe to this thread


Users browsing this thread:
1 Guest(s)



Powered By MyBB, © 2002-2025 MyBB Group. Theme © 2014 iAndrew & DiscoveryGC
  • Contact Us
  •  Lite mode
Linear Mode
Threaded Mode