Do NPCs use primable equipment?

Discussion and information relevant to creating special missions, new ships, skins etc.

Moderators: another_commander, winston

Post Reply
QCS
Dangerous
Dangerous
Posts: 112
Joined: Sun Feb 22, 2015 6:52 pm

Do NPCs use primable equipment?

Post by QCS »

Hi,

NPCs seem to buy equipment "available_to_NPCs", that's at least what I get from reading.
But somehow I can't get my head around NPCs and primable equipment. What do NPCs do with it?

I would guess that they buy it but if the equipment needs priming to work at all, they can not use it. Right?

If so, how should equipment be made available to all? Should something be built that if the equipment script detects that it is an NPC ship using it, do some guesswork using roles etc. on how the equipment would be used in a typical case?

I did not find anything related to this topic in general, although I would expect something regarding that in the Wiki.

Thanks!
User avatar
MCO
Poor
Poor
Posts: 7
Joined: Fri Jan 20, 2017 11:23 pm

Re: Do NPCs use primable equipment?

Post by MCO »

i'm pretty sure you would have to implement all the functions two times: once for the player and once for NPCs. because every primable equipment we use refers to variables such as player.ship (which ofc isnt accesible on an entity ship) or display options, which would most likely not work at all.
so, for example, if you want to implement a scanner that displays the enemys kill count (bad example, but, whatever), you would need to add a function that detects if it's an NPC ship, followed by some code preventing it from attacking higher-ranked players. so you would end up with two completely different functions for the NPC and the player.
but those are just the thoughts of a beginning coder.
Honorable Trader/Pirate Hunter.
Current Kill Count: 544
User avatar
Smivs
Retired Assassin
Retired Assassin
Posts: 8408
Joined: Tue Feb 09, 2010 11:31 am
Location: Lost in space
Contact:

Re: Do NPCs use primable equipment?

Post by Smivs »

Just out of interest, what primable equipment might NPCs use (in a way that the player could notice)?
Commander Smivs, the friendliest Gourd this side of Riedquat.
User avatar
Norby
---- E L I T E ----
---- E L I T E ----
Posts: 2577
Joined: Mon May 20, 2013 9:53 pm
Location: Budapest, Hungary (Mainly Agricultural Democracy, TL10)
Contact:

Re: Do NPCs use primable equipment?

Post by Norby »

Perhaps Manifest Scanner. If player install this oxp then priates could attack more often when player hold valuable cargo, while receive a message like: Hey, I see 10000kg gold in your cargo, eject it and I will leave you alone!

In this case players will think before install it: whether want or not want to play in a galaxy where all doors of cargo bays are made from glass, including your own ship. ;)
QCS
Dangerous
Dangerous
Posts: 112
Joined: Sun Feb 22, 2015 6:52 pm

Re: Do NPCs use primable equipment?

Post by QCS »

Smivs wrote: Fri Feb 10, 2017 10:08 pm
Just out of interest, what primable equipment might NPCs use (in a way that the player could notice)?
I was thinking about [EliteWiki] QTHI_Auxiliary_Energy_Generators_OXP.
The light equipment variant interferes with other equipment (Witchspace drive), so does not do anything as default and needs some priming to work. But if the NPC would use it, it would probably be visible to the player (needs one more laser burst to kill, or something like that, given the efficiency of this kit :-) )

Regarding the Manifest scanner, I was already thinking about this one long time ago, and I believe the idea itself is not too bad, but the "cargo bay made of glass" issue is of course a no-go. I thought that best would be if all ships save their (official) cargo list upon leaving an official station into an official database, and usually you don't have access to this database, but of course you will probably find someone who can give you (illegal) access to it. It would then not reflect current cargo, but "cargo this ship should have", e.g. if you dump cargo, or scoop cargo, it won't be reflected in this list. And of course GalCop ships would have access to this database.
User avatar
Stormrider
Deadly
Deadly
Posts: 239
Joined: Sat Jan 25, 2014 2:35 am
Location: At work

Re: Do NPCs use primable equipment?

Post by Stormrider »

QCS wrote:
I thought that best would be if all ships save their (official) cargo list upon leaving an official station into an official database, and usually you don't have access to this database
The manifest scanner hacks your ship's computer, which updates itself as soon as you scoop a pod, check your f5f5 screen. The way I see it your ship communicates the contents of the cargo hold to the station as soon as you dock or when you exit the station. The scanner simply uses the same system to scan your cargo as the Galcop.
Norby wrote:
If player install this oxp then priates could attack more often when player hold valuable cargo, while receive a message like: Hey, I see 10000kg gold in your cargo, eject it and I will leave you alone!
Norby I would have liked to implement this sort of behavior but AI scripting is still a bit beyond my current ability and unfortunately I don't have time to learn right now. I thought about having the Galcop do scans of ships too but that would require a different illegal goods system.
Image
Post Reply