Post Tue Feb 04, 2025 9:08 pm

Player Drones - pushed to main server

requirements, expectations and logic for player drones.
i am writing this to offer insights into how drones will work in Alasiya-EvE
this is what i remember playing live, how i'm coding drones, and a few things that just make sense, from a pilots pov.


Drone Control Distance
the drone is autonomous as long as it has a valid command and valid target, regardless of the distance from it's home ship, as long as home ship and drone are in same local space. (for now)
the control distance comes into play when you are sending commands or targets to the drone.
when issuing a command to the drone, the first check is if it's within the control distance.
if so, it will run thru the other command checks before proceeding.
if not, then you will receive a message stating the drone is too far away.
at this point, the drone will continue with it's task until completed or a stop point is reached.
if the drone's target is destroyed or leaves local space and the drone is outside control range, it will leisurely (and passively) make it's way back to it's home ship.
you wont be able to command it, nor will it acquire a new target and engage until it is back inside the control range. this goes for all drone modes.
the exception to this is for mining drones who's target is depleted. they will return and drop off the ore collected so far.
after that, they will hover around home ship within control distance until new command is given.

Default control distance is 20km and can be modified by skills, modules and ship.


Drone Targeting Distance
the drone is just an extension of your ship, with a few caveats.
If the drone is within control distance, the ship will use it's target computer to provide the drone with targeting information.
depending on your ship, this can be from tens to hundreds of km. (think sniping with sentry drones @150km...surprise!)
outside control distance, the drone will retain it's target until the target is goes away (popped, cloak, warp, dock, jump, etc.) [yes, i put 'cloak' in there...idea for later]
once that target is invalid, the drone will rely on home ship for commands and target information. see above for control distance.


Drone Grouping
there are a multitude of checks in the drone system.
one of these is to verify a command is valid for all drones in a group...
i.e. you have a flight of 5 and command them to mine. oh, damn, one is an acolyte....that's not gonna work.
goes the other way too...commanded to rep a ship that cant keep up...woops, one's an ewar and the other is a miner.
however, because drones are grouped by group, you can use shield and armor reps in same flight.
i dont remember how it worked on live, but here the flight will run thru the command, verify everything, and those drones that accept the command will execute it, while the others will return to idle.
this goes for all commands and all drone types.
you will also get a message if any check fails when issuing commands.


Drone Mining
i was indy more than anything else, so im kinda keen on it (and that's why i get those systems working first)
so, drone mining.
if you can target it and command the drone to start, the drone can handle the rest.
it will fly to the asteroid, mine it, fly back to home ship, drop off ore and start the cycle again, if so commanded. (mine vs mine repeatedly)
it dont matter if the asteroid is 45km away....if you can target it, the drone will accept the command. it'll just take the drone a while to get there and back.
just remember, drones will be vulnerable while they're traveling, especially miners. they will put on the blinders and go about their task.
now, there are a few things to consider....a typical miner I only mines 15m3/cycle. (mutable with skills)
this means that it cannot mine high-end ores without high skills. i.e. Bistot is 16m3. dont even think about trying Mercoxit (even with skills)
also, there are no drone miners that can mine ice (which is 1000m3 per block)


Drone Modes and Commands
Aggressive Mode:
drone will attack anything within its sight range (which varies with drone type)
(note this deals with proximity distance, which i havent finished yet)

Passive Mode:
drone will lazily fly around without caring if it's targeted or being attacked. wont retaliate.

Focus Fire:
all drones in the flight will direct their undivided attention to your current or identified target

NOTE: drones set to autoattack, aggressive, and focus fire will rely on the first drone to identify a target, then gang up on it.
this is only for combat drones. they do communicate with each other, which makes them an effective team (yes, Tet, we are an effective team)

Attack and Follow:
this is for fighter/bombers. follow here means this bitch will chase your into warp around the solar system, until you dock, jump, or park in a tower's field.
i have not done much to these besides the basics...nothing particular for them yet.

Mine:
discussed above, drones make great mining buddies, but dont expect too much from them

Delegate:
this will assign the flight to another pilot. the pilot is required to have the bandwidth and skills for the drones in the flight.
if the pilot is outside control range, the flight will fly to him/her and try to link with their ship before determining if the skills and bandwidth are sufficient
if any checks fail, the drones with failing checks will return to home ship
if the pilot is inside control range, all checks will be made before transfer.
NOTE: i dont have this working. pilot being given the drones refuses to connect to them....havent spent much time on it and dont care right now.


all of the following commands require the drone/flight to be within control distance.
Engage:
this command will instruct the drone to just that, ofc, it depends on the drone type. this works on all types of drones and all combinations of flights.
boosters will boost, reppers will repair, fighters, sentrys, and ? will attack.
this will happen until the drone or target is popped, or the drone is given a new command.

Guard:
puts drone in passive mode. drone will hover around target until it is threatened. drone will engage all threats in the order of first targeted assigned ship.
**still working on these...may not get them working right until i rewrite npcai code (which is next)**

Assist:
depending on the drone, it will engage whatever it's target is actively doing. kinda like a dog wants to be all in your business, but better.

Return:
this will recall the drone (or entire flight) back to home ship, as long as they are in control range.
this will trump all other commands...even in the middle of mining.
the one thing you can always do is recall your active drones back to the mothership


new player command
`.autoattack`
this will instruct drones to automatically engage anything that is targeting its assigned ship, starting with the weakest.
this includes other drones.

that's all i got working so far.
have ideas and improvements for later.

~me

p.s. here's a bug thats kinda fun to exploit...
log in, fly to belt, launch drones, abandon drones, launch more drones, abandon drones, reconnect to drones....
right now, i dont have reconnect coded to check for max drones you can command in space. its crazy to see a belt with a single hulk, 5 angel rats, and 20 drones just tearing up some angel rat ass. LOL

p.p.s...
another bug i caused last nite....updated some number data types, but not all casting operations, so ship variables are a bit off.
my hulk will enter warp in 1.8 seconds now.....woot!!!!