Page 1 of 1

Another noob with question regarding AI behavior

Posted: Thu Nov 05, 2009 12:27 am
by Commander Kizz
So now i finally caught the constrictor (i was even able to capture the pilot in his escape capsule), boosting my rating to "dangerous", i thought i took this opportunity to say "hello" to the board and "thank you" to the creator(s) of this game.

I have to say in gameplay (and graphics, obviously) it is by far the best version of elite i´ve ever played. Although i liked the newton style combat of JFFE, the ability to interact with the gameworld (pirate victims shouting for help etc) makes Oolite an even better game, overall.

I started out trading down to a Cobra Mk I, and since this ship is very slow and has only two shields i thought the combat was quite difficult as soon as more than 4 enemies showed up and no E-bomb was available. Eventually, however, i found out how to snipe enemies from a distance of up to 25 km before they even could fire their lasers at me, then switching to rear lasers to take out the next ones, and in combination with switching to an Ophidian Yacht, a ship that could outrun most other ships in the game, combat immediatly switched from "very difficult" to "ridiculously easy".

This is mainly because enemy ships dont stop running up to you even when shot at until they are nearly destroyed. It is almost always too late for them to turn away at this point. Also, they dont bother shooting back until they are very close (like within 12 km range or so).

Is there a way to improve the AI in this regard, making them do evasive maneuvers when shot at, and shooting back earlier, by either:

-adding an oxp that makes them harder
-changing some parameters in the source code?

I´d rather not add an oxp that adds uber ships to the game. I like the feeling of the original elite with its simple designs and aesthetics, and only have the following oxps installed:

Asteroid Storm, Deep Space Pirates, Sun Skimmers, Old Ships, Pirate Coves, Aegidian Special, and X-ships (love them all).

If this has been asked before, I am also grateful for a useful link in this regard!

Posted: Thu Nov 05, 2009 12:44 am
by Micha
Presumably you have military lasers installed - they have a much longer range than beam lasers, which is probably what the average pirate has installed, hence why your 'sniping' trick works. The enemy ships -should- shoot at you as soon as you are in their firing range.

Adding a bit more evasion to their repertoire would probably be a good thing - but I defer here to the AI specialists of which I am not one.

Oh, and Welcome to the Friendliest Board this Side of Riedquat(tm) :)

Posted: Thu Nov 05, 2009 12:59 am
by Commander Kizz
In this case, giving military lasers to more pirates might also be a good solution.

It might also be that the Ophidian Yacht is exceptionally hard to hit. I´m sitting there carefully aiming (i´m using mouse control), not moving at all, and even when shot at the AI usually can´t hit me unless they are very close.

Posted: Thu Nov 05, 2009 5:29 am
by Chrisfs
Add Black Monks oxp. even if you never use the bank itself, it adds stuff you say you like.
More ships calling out for help as the loan enforcers from the bank come after them and tough ships to fight.

Posted: Thu Nov 05, 2009 8:30 am
by Kaks
All the ships' behaviour is coded within ai.plists so you could definitely make all ships smarter & sneakier with the right OXP, one that overwrites the standard AIs with new improved ones. Unfortunately, it's also fairly easy to make ships dumber by mistake...

Anyway, if you want a bit more of a challenge, deep space pirates and hotrods add a few extra pirates to the game, with hotrods adding a bit more spice to a few anarchy systems.

Posted: Thu Nov 05, 2009 8:39 am
by Commander McLane
Kaks wrote:
All the ships' behaviour is coded within ai.plists so you could definitely make all ships smarter & sneakier with the right OXP...
However, what they actually do after receiving the performAttack command, is completely coded within the engine, and no smart & sneaky AI coding can prevent them from stupidly remaining in BEHAVIOUR_ATTACK_FLY_TO_TARGET_SIX or BEHAVIOUR_ATTACK_FLY_TO_TARGET_TWELVE forever (or until they have been shot to smithereens). :(

Posted: Thu Nov 05, 2009 8:59 am
by Screet
Commander Kizz wrote:
In this case, giving military lasers to more pirates might also be a good solution.

It might also be that the Ophidian Yacht is exceptionally hard to hit. I´m sitting there carefully aiming (i´m using mouse control), not moving at all, and even when shot at the AI usually can´t hit me unless they are very close.
The laser range is a big part of the problem. IIRC the O.Y. is long, but very slim thus a ship approaching it from front really does have more trouble.

Should you ever fly a Merlin, you will notice the biggest of this effect: It's so tiny that it can fly between the laser beams of enemies and usually is not being hit!

There is one easy thing you can do, though: Switch to neolite ships. Those are usually much more difficult to hit and thus might provide a better opponent for you ;)

You are perfectly right when you talk about NPCs often being dumb (it also was in Elite, I often cut whole pirate groups to pieces before they would begin to hit me, especially ship types like Mamba and Krait) and they really should have more often better equipment so that they both can take more hits and shoot from a bigger distance.

I think you also might like to add Random Hits (good for bounty hunting missions, providing some nice enemy groups) and the Navy/Thargoid oxp's. Those will make the Thargoids tougher and also allow to get missions from the navy.

Screet

Posted: Thu Nov 05, 2009 3:24 pm
by Commander Kizz
Thanks for all the answers!

I have now upgraded all laser types in shipdata.plist to military lasers.

I don´t have time for extensive testing right now, but i did a run to a feudal system and, funny enough, promptly got in a very difficult situation and got destroyed. Here is what happened for those that are interested:

I spotted a rock hermit from a distance and got ready to dock for some trading. Once i was close to it, i see an extra large bunch of pirates approaching from the edge of my scanner. I take out two of them, but the third opponent turned out to be a Mussurana and shot ecm hardened missilies at me forcing me to run on injectors. He was fast enough to keep approaching and burn my back with military lasers, ripping large holes into my shields. At the same time, my rear laser got overheated, so i turned around to face the Mussurana with front Lasers as he was shooting at me anyway.

Meanwhile, the Rock Hermit had obviously turned out to be a Pirate cove, so i found myself surrounded/chased by about 10 AI ships, all equipped with military lasers. There was quite a lot of red lines on the screen.

Didnt matter, though, b/c the Mussurana had already another ecm-proof missile launched which i didn´t react quickly enough to evade: press space, commander. :roll:

Ironically, the ship that killed me (The Mussurana) had a military laser installed from the start, without me editing the game. This situation was exceptionally tricky, and i hope i can get some more testing done this evening with normal situations (i.e. the standard wave of 6 - 7 pirates approaching). Also, i was too eager to fight, where i usually would have just run away on injectors, because i wanted to test how the changes effect the game.

If this upgrade on the AI´s weaponry doesn´t make for a significant change of difficulty (but it should imo), i´m probably gonna try what others have suggested:
Add oxps that make the game tougher. The reason i´m hesitant to do so is my (maybe foolish) conservativism regarding ship and station types.

Sooner or later i will probably add some of them anyway since i fully realize how much good work has been done there.

EDIT to add:

I think the reason the AI performs worse in Oolite than in, for example, flight simulators, is because of the availability of unlimited ammo and recharging shields on both sides, and the possibility of using injectors to singl out opponents. Most WW1/WW2 simulators i have played dont really allow to battle more than 4 enemies at once, because you just cant afford to waste shots, or get hit which might result in severe reduction of maneuverability. So the effects of being outnumbered are much more severe in those games, and its not so much a problem of AI than the classical elite gameplay/space scenario if this makes sense.

Posted: Fri Nov 06, 2009 2:42 am
by CptnEcho
Commander Kizz wrote:

EDIT to add:

I think the reason the AI performs worse in Oolite than in, for example, flight simulators, is because of the availability of unlimited ammo and recharging shields on both sides, and the possibility of using injectors to singl out opponents. Most WW1/WW2 simulators i have played dont really allow to battle more than 4 enemies at once, because you just cant afford to waste shots, or get hit which might result in severe reduction of maneuverability. So the effects of being outnumbered are much more severe in those games, and its not so much a problem of AI than the classical elite gameplay/space scenario if this makes sense.
I've played a few combat flight simulators, especially WWII versions. The A.I.'s are different. Also, the flight environment is different. In Elite/Oolite, there's no need to worry about stalling out or crashing into the ground.
Flight-simulator aircraft have to utilize their flight energy (airspeed, altitude and momentum) to best advantage.

The Elite/Oolite flight model is probably not as sophisticated as flight-simulator enviromental modeling. Elite broke ground when computer resources were minimal and precious. Modern flight-simulators take advantage of today's abundance of computing resources.

Elite/Oolite damage to A.I. ships is measured with the value of their energy. Damage doesn't affect a ships flight performance until it is nearly destroyed.
Flight-simulators have more complicated damage models and factor in the effects of damaged engines, control surfaces and parts of the fuselage which may have broken away from the airframe.

Sometimes you feel like drinking coffee, sometimes you feel like drinking tea. Either can provide you with a nice jolt of caffine. 8)