[RELEASE] Skilled NPCs (1.77 only)

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

Moderators: another_commander, winston

User avatar
cim
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 4018
Joined: Fri Nov 11, 2011 6:19 pm

[RELEASE] Skilled NPCs (1.77 only)

Post by cim »

This is a very simple OXP. Oolite 1.77 allows pilots to be significantly more skilled than they were in 1.76 - this OXP means that some of them actually are. If you find combat in Oolite tough enough as it is, you probably don't want this OXP. If you can fight through an Anarchy without scratching the paintwork, on the other hand, this might make it a fairer fight.

Skilled NPCs 1.1
It can be configured with OXPConfig to increase the challenge further, should you need to.

For 1.79 and onwards there's now Skilled NPCs 1.2 (OXZ), which works better with the new ship roles and populator, and also checks auto_weapons before changing the accuracy (which is the right thing to do, but in the short term will probably lead to it only touching the core game ships)
Last edited by cim on Sat Apr 12, 2014 2:37 pm, edited 3 times in total.

UK_Eliter
---- E L I T E ----
---- E L I T E ----
Posts: 1127
Joined: Sat Sep 12, 2009 11:58 pm
Location: Essex (mainly industrial and occasionally anarchic)

Re: [RELEASE] Skilled NPCs (1.77 only)

Post by UK_Eliter »

cim

This is really good - and it is good it is configurable via the oxpconfig oxp. However, I couldn't work out how to do more than toggle boosting of particular types of ship, as against change how much their abilities were boosted by. Also: does 'boost aliens' really apply only to thargoids? Just checking. Thanks.

User avatar
cim
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 4018
Joined: Fri Nov 11, 2011 6:19 pm

Re: [RELEASE] Skilled NPCs (1.77 only)

Post by cim »

UK_Eliter wrote:This is really good - and it is good it is configurable via the oxpconfig oxp. However, I couldn't work out how to do more than toggle boosting of particular types of ship, as against change how much their abilities were boosted by.
To change the amount they're boosted by independently of the general level, you'll need to edit the script itself.
UK_Eliter wrote:Also: does 'boost aliens' really apply only to thargoids?
Those with primary role "thargoid" only.

User avatar
Shipbuilder
---- E L I T E ----
---- E L I T E ----
Posts: 877
Joined: Thu May 10, 2012 9:41 pm
Location: Derby

Re: [RELEASE] Skilled NPCs (1.77 only)

Post by Shipbuilder »

I like the sound of this OXP.
The GalTech Industries Corporation - Building ships to populate the galaxies.

Increase the variety of ships within your Ooniverse by downloading my OXPs

Flying the [wiki]Serpent_Class_Cruiser[/wiki] "Thargoid's Bane"

UK_Eliter
---- E L I T E ----
---- E L I T E ----
Posts: 1127
Joined: Sat Sep 12, 2009 11:58 pm
Location: Essex (mainly industrial and occasionally anarchic)

Re: [RELEASE] Skilled NPCs (1.77 only)

Post by UK_Eliter »

cim wrote:
UK_Eliter wrote:This is really good - and it is good it is configurable via the oxpconfig oxp. However, I couldn't work out how to do more than toggle boosting of particular types of ship, as against change how much their abilities were boosted by.
To change the amount they're boosted by independently of the general level, you'll need to edit the script itself.
UK_Eliter wrote:Also: does 'boost aliens' really apply only to thargoids?
Those with primary role "thargoid" only.
Right. Ta muchly for the information.

User avatar
CaptSolo
---- E L I T E ----
---- E L I T E ----
Posts: 893
Joined: Wed Feb 23, 2011 10:08 pm
Location: Preying Manta
Contact:

Re: [RELEASE] Skilled NPCs (1.77 only)

Post by CaptSolo »

Well done, Cim. I like it with difficulty level set to maximum. Makes one think twice about visiting so called unstable worlds.

User avatar
CaptSolo
---- E L I T E ----
---- E L I T E ----
Posts: 893
Joined: Wed Feb 23, 2011 10:08 pm
Location: Preying Manta
Contact:

Re: [RELEASE] Skilled NPCs (1.77 only)

Post by CaptSolo »

Cim, I have logged about 500 game hours since adding your excellent OXP and adjusting the difficulty level to maximum. NPC's really are skillful pilots with it. A few blasts of laser fire cause them to take evasive action. Sniping is much more difficult now. I was surprised to learn how adjusting the accuracy effected NPC's combat AI. Your OXP has made a big difference on how I play the game.

User avatar
Disembodied
Jedi Spam Assassin
Jedi Spam Assassin
Posts: 6513
Joined: Thu Jul 12, 2007 10:54 pm
Location: Carter's Snort

Re: [RELEASE] Skilled NPCs (1.77 only)

Post by Disembodied »

Likewise for me! It adds whole new layers to combat technique and tactics: you can really tell when you're up against a good opponent and I get a real sense of satisfaction when I finally nail a troublesome foe ...

User avatar
Svengali
---- E L I T E ----
---- E L I T E ----
Posts: 2370
Joined: Sat Oct 20, 2007 2:52 pm

Re: [RELEASE] Skilled NPCs (1.77 only)

Post by Svengali »

// drop the entire "sub-Harmless" end entirely, including for custom roles
Ouch. Does it mean that I have to check the settings of my own stuff now? :?

User avatar
cim
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 4018
Joined: Fri Nov 11, 2011 6:19 pm

Re: [RELEASE] Skilled NPCs (1.77 only)

Post by cim »

Svengali wrote:Ouch. Does it mean that I have to check the settings of my own stuff now?
Maybe. In Oolite 1.76, the accuracy variable was randomly assigned between -5 and +10, but apart from a barely-noticeable effect on the range the ship opened fire at, this didn't do a lot. However, there was also a check on entityPersonality - those with an odd number for that got some bad AI, those with an even number got a slightly better AI (I think it was that way round, anyway)

In 1.77 entityPersonality is not used for that any more. Instead, the accuracy range -5 to -0 corresponds to the bad AI, and the range from 0 to 5 corresponds to the slightly better AI. The random assignment is now between -5 and +5.

So your ships should behave the same as they did in 1.76, on average, if you've made no custom accuracy settings. If you would like them to behave with better skill, then you should be setting better accuracy explicitly - which is possible now and just wasn't before. The Constrictor, for instance, always has an accuracy >= 0

[wiki]OXP_NPC_Combat_AI[/wiki] has more details of what the accuracy thresholds mean.

User avatar
Svengali
---- E L I T E ----
---- E L I T E ----
Posts: 2370
Joined: Sat Oct 20, 2007 2:52 pm

Re: [RELEASE] Skilled NPCs (1.77 only)

Post by Svengali »

cim wrote:Maybe.
Hmm. Wouldn't it make more sense to leave custom roles untouched? In my eyes these entities shouldn't be touched at all if they don't state it explicitely. Using a 'include me' approach (e.g. via script_info key) means that these OXPs are prepared and (hopefully) tested to work with the mechanisms they are using...

User avatar
cim
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 4018
Joined: Fri Nov 11, 2011 6:19 pm

Re: [RELEASE] Skilled NPCs (1.77 only)

Post by cim »

Svengali wrote:
cim wrote:Maybe.
Hmm. Wouldn't it make more sense to leave custom roles untouched? In my eyes these entities shouldn't be touched at all if they don't state it explicitely. Using a 'include me' approach (e.g. via script_info key) means that these OXPs are prepared and (hopefully) tested to work with the mechanisms they are using...
Possibly. But the only change made to custom roles (and indeed non-custom roles not listed, such as "miner") is to increase their accuracy into the +0 to +4.99 range if it was previously negative. In 1.76, they would have had a 50% chance of having that set of AI behaviours anyway (with nothing you could do about it in script). All having this OXP installed does is increase that chance from 50% to 100% per ship (which may make certain fights marginally tougher, but people installing this OXP presumably want that)

And, looking at the 1.76 code, I was slightly incorrect above: anything non-missile with an accuracy < 1.0 (or missile with accuracy < 0.0) would have its accuracy increased to that level anyway. So the only thing an OXP-based negative accuracy setting in shipdata.plist would have done in 1.76 code is marginally worsened their aim (very marginally - I could never tell the difference in actual fights between -5 and +10, in 1.76)

I could introduce a script_info setting for those cases where it's important to the plot that a ship has an incompetent pilot, but that's a pretty rare case.

Switeck
---- E L I T E ----
---- E L I T E ----
Posts: 1998
Joined: Mon May 31, 2010 11:11 pm

Re: [RELEASE] Skilled NPCs (1.77 only)

Post by Switeck »

How is Skilled NPCs related to whether NPCs have rear and side mounted Beam or Military Lasers?
...Or is there any correlation at all?

User avatar
CaptSolo
---- E L I T E ----
---- E L I T E ----
Posts: 893
Joined: Wed Feb 23, 2011 10:08 pm
Location: Preying Manta
Contact:

Re: [RELEASE] Skilled NPCs (1.77 only)

Post by CaptSolo »

Switeck wrote:How is Skilled NPCs related to whether NPCs have rear and side mounted Beam or Military Lasers?
...Or is there any correlation at all?
If they have them they use them, and much more efficiently on a whole versus 1.76 behaviour.

User avatar
cim
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 4018
Joined: Fri Nov 11, 2011 6:19 pm

Re: [RELEASE] Skilled NPCs (1.77 only)

Post by cim »

It doesn't change weapon load at all, and it doesn't consider weapons when adjusting accuracy.

Post Reply