• 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 Content Submissions
« Previous 1 … 3 4 5 6 7 … 28 Next »
Request: /autorepair

Server Time (24h)

Players Online

Active Events - Scoreboard

Latest activity

Pages (2): 1 2 Next »
Request: /autorepair
Offline Vexykin
03-30-2018, 06:54 PM,
#1
Member
Posts: 2,069
Threads: 194
Joined: Jan 2010

Similar to /autobuy, only that it repairs your ship automatically, without you needed to visit Equipment Vendor page.

/autorepair on

plz ?

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 Sand-Viper
03-30-2018, 06:57 PM,
#2
Member
Posts: 1,954
Threads: 104
Joined: Nov 2007

Do want. Do very much want! Especially since I've been having to deal with radiation damage so frequently as of late. T'would be handy to have, but is it possible via FLHook?

The Gaelic Wyvern Inn
If you've interacted with us recently, please consider checking out our in-character Public Guest Reviews thread!
Reply  
Offline Remnant
03-30-2018, 07:05 PM, (This post was last modified: 03-30-2018, 07:07 PM by Remnant.)
#3
Member
Posts: 2,206
Threads: 248
Joined: Apr 2012

I'll have to look into this. I know repairing a ship hull is definitely possible (without much difficulty).
Although querying for each piece of equipment attached, and checking the HP for whatever equipped object compared to its maximum is something I'm less sure of. (I assuming the repair cost value is a simple algebra equation.)

There's probably some method. When I get back from campus I'll look through the FLHook SDK and see what's there to work with.
Reply  
Offline Remnant
03-31-2018, 01:28 AM,
#4
Member
Posts: 2,206
Threads: 248
Joined: Apr 2012

Alright. So I've done some experimentation with the subject.

The problem with this feature, is that FLHook needs to repair the ship while it's in space. Not when it docks on a station. When a vessel docks, the ship object disappears, meaning that the values cannot be manipulated. I've tried to put the repair (and credit deduction) logic as early as I could under the BaseEnter hook, although the hook doesn't fire soon enough, as the ship is already docked at that point. (Meaning you're kicked from the server instead, since the server doesn't know what to do)

The only solution which I can think of currently, is to hook into when users press the dock button in order to land on a base. If it detects that you're within a certain range of the base you're landing on, it can perform the operations while you're in space, before running a Force-Dock function, landing you on the base shortly after the autorepair does it's work.
The downside to this, the Force-Dock skips the docking animation. I'm not sure how the developers would feel about that.

If the plugin didn't force a user to dock, people could abuse the autorepair, by asking to dock from a close range to the station, and quickly go back to free-flight after being repaired. (Meaning they wouldn't actually dock) - So a no bueno there.

Thoughts?
Reply  
Offline Vexykin
03-31-2018, 01:45 AM,
#5
Member
Posts: 2,069
Threads: 194
Joined: Jan 2010

Uhm...
My only thought is...That i remember this function briefly from a HHC server...i might remember wrong of course, but i'm pretty sure they had that implemented to FLHook somehow.

Maybe nosing around the HHC plugins could help us find the answer?

But yeah tbh, that's not that important of a plugin anyway, it was more like a flash of a thought, that what if we could save 10 seconds of our lives with each dock that needed repairs Big Grin

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 Remnant
03-31-2018, 05:16 AM, (This post was last modified: 03-31-2018, 05:16 AM by Remnant.)
#6
Member
Posts: 2,206
Threads: 248
Joined: Apr 2012

If you could point me to some references, I'd be more than happy to look into what sort of operations they did to accomplish the task. (If it is the same task) - I'm afraid I don't really know where I'd look for what you're talking about myself.

There are a few approaches to this feature request, but none of them that I'm seeing, is as seamless as it probably should be.
Reply  
Offline SnakThree
03-31-2018, 06:55 AM,
#7
Member
Posts: 9,091
Threads: 337
Joined: Mar 2010

How about repairing during undocking then?

[Image: rTrJole.png][Image: LJ88XSk.png]
[Image: ka0AQa5.png][Image: QwWqCS8.png]
  Reply  
Offline Alex.
03-31-2018, 02:54 PM,
#8
Developer
Posts: 3,910
Threads: 145
Joined: Aug 2009
Staff roles: Server Manager
Coding Dev
Moderator

If I recall correctly, Eagle Utopia had this when they were running, but they had FLAC instead of FLHook. I thought it happened just after you dock. I never managed to figure out how to do it. Maybe some client-side hooking wizard can figure it out.

FLHook suggestions
All other dev queries
Please only PM me through the forums for things that need to be private like anticheat etc.
[Image: dI8iG0a.png]
Reply  
Offline Alex.
03-31-2018, 03:06 PM,
#9
Developer
Posts: 3,910
Threads: 145
Joined: Aug 2009
Staff roles: Server Manager
Coding Dev
Moderator

I have reason to believe that the ReqEquipment/ReqHullStatus hooks may be called when people attempt to repair their ships manually. Maybe we can use that along with BaseData::get_ship_repair_cost

FLHook suggestions
All other dev queries
Please only PM me through the forums for things that need to be private like anticheat etc.
[Image: dI8iG0a.png]
Reply  
Offline Remnant
03-31-2018, 03:19 PM, (This post was last modified: 03-31-2018, 03:26 PM by Remnant.)
#10
Member
Posts: 2,206
Threads: 248
Joined: Apr 2012

(03-31-2018, 03:06 PM)Alex. Wrote: I have reason to believe that the ReqEquipment/ReqHullStatus hooks may be called when people attempt to repair their ships manually. Maybe we can use that along with BaseData::get_ship_repair_cost

I definitely think that's a safe assumption, given I dunno how else the system would figure out how to calculate repair costs. (Unless it uses an unhooked function, which I doubt) - ill experiment with that later. Let's assume you're right, that ReqEquipment functions solve the issue of getting the cost for the equipment mounted on your vessel. (And a function to set its health). Maybe the repair operation can be done as @SnakThree suggested, on undock? Perhaps just a Boolean flag set on dock, which is checked once the player launches to space again?
The idea is that players don't have to do anything manually.

I discarded the idea at first, because it wouldn't hide the repair operation on the base, but on second thought, it's not that bad of an option, as it'll do it for you, if the user doesn't.

Ps. What kind of garbage values does GetRelativeHealth give you. Those numbers are far too large to match the current or max HP, nor does it seem to be a percentage.
Reply  
Pages (2): 1 2 Next »


  • View a Printable Version
  • Subscribe to this thread


Users browsing this thread:
1 Guest(s)



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