Combat AI

For test results, bug reports, announcements of new builds etc.

Moderators: winston, another_commander, Getafix

User avatar
JensAyton
Grand Admiral Emeritus
Grand Admiral Emeritus
Posts: 6657
Joined: Sat Apr 02, 2005 2:43 pm
Location: Sweden
Contact:

Combat AI

Post by JensAyton »

So, has anyone else noticed that combat AI has got (even) worse in 1.70? I’ve had five Griff Kraits circling me for over five minutes (no, really) without a single shot fired. I wonder what I’ve gone and broken now. :-/
User avatar
matt634
Deadly
Deadly
Posts: 206
Joined: Tue Mar 21, 2006 6:32 pm
Location: Colorado, USA

Post by matt634 »

I've noticed that station defenders from my SecCom stations are not only less aggressive during play-testing , but many times will launch and then perform an immediate 180 and re-dock. I just upgraded from 1.65 so I wasn't sure if this was new to 1.70 or an older bug.
User avatar
Ark
---- E L I T E ----
---- E L I T E ----
Posts: 664
Joined: Sun Dec 09, 2007 8:22 am
Location: Athens Greece

Post by Ark »

Yes indeed.
In a new game today I attacked a Galgop viper just outside laves’s station. It only fired me for one second. Then nothing.. only some evading maneuvers and a missile (for about 1 -2 minutes). I almost destroyed it with my pulse laser (!!!!!!). When it was about to explode it ran away using fuel injectors. It was like fighting a supercobra (buggy AI)

Also when I fired the station itself there were no new vipers exiting the station in order to intercept (this seems to be general).

In 1.65 I would be dead meat if I have done this with no equipment (only a pulse laser)
User avatar
JensAyton
Grand Admiral Emeritus
Grand Admiral Emeritus
Posts: 6657
Joined: Sat Apr 02, 2005 2:43 pm
Location: Sweden
Contact:

Post by JensAyton »

Ark wrote:
Yes indeed.
In a new game today I attacked a Galgop viper just outside laves’s station. It only fired me for one second. Then nothing.. only some evading maneuvers and a missile (for about 1 -2 minutes). I almost destroyed it with my pulse laser (!!!!!!).
Nothing !!!!!! about that. Launching a new Jameson from Lave and attacking the cops is something I’ve done often, and typically I can kill about 4. It may be more now if 1.70’s AI really is buggy, I haven’t tried it recently.
Trexate
Average
Average
Posts: 11
Joined: Sun Dec 09, 2007 8:58 pm

Post by Trexate »

Ahruman wrote:
Nothing !!!!!! about that. Launching a new Jameson from Lave and attacking the cops is something I’ve done often, and typically I can kill about 4. It may be more now if 1.70’s AI really is buggy, I haven’t tried it recently.
If there is only one cop out there, you'd only kill one because the station doesn't send him reinforcements.

I just tested it on 1.65 and 1.70

1.70 - many OXPs active, one cop vs. a "virgin" Jameson. The cop turned on the witchspace injectors and ran away.

1.70 - strict mode. The cop wasn't aggressive - mostly he tried to fly away from me in a straight line. He didn't turn even when I was pouring much damage on him. Then he died. He got no reinforcements.

1.65 - strict mode. The cop flew aggressively and he quickly had back-up vipers pouring out of the station to shoot me down.
User avatar
Ark
---- E L I T E ----
---- E L I T E ----
Posts: 664
Joined: Sun Dec 09, 2007 8:22 am
Location: Athens Greece

Post by Ark »

I do not know if the aggressive AI of 1.70 is buggy, but definitely something is wrong with main station defenses. I did the same thing with a hoopy casino and instantly there were 2 or 3 defenders (sidewinders I think) trying to intercept me.

By the way is it possible to have both 1,65 and 1,70 (in a different directory) installed in me hard disk? I want to be able to test similar situations with both versions or do i have to install uninstall all the time.
another_commander
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 6682
Joined: Wed Feb 28, 2007 7:54 am

Post by another_commander »

Ark wrote:
By the way is it possible to have both 1,65 and 1,70 (in a different directory) installed in me hard disk? I want to be able to test similar situations with both versions or do i have to install uninstall all the time.
Yes it is definitely possible, and I do it all the time. Just be aware that the Start Menu shortcuts (assuming you are on a Windows machine) always point to the version that was installed last. You can always create your own shortcuts on the desktop for different versions and each of these should point to the equivalent RunOolite.bat file.

As you said, the most important detail is to have the two versions in completely different, independent folders.
User avatar
Ark
---- E L I T E ----
---- E L I T E ----
Posts: 664
Joined: Sun Dec 09, 2007 8:22 am
Location: Athens Greece

Post by Ark »

Thanks a lot another_commander
Having both versions is vital if you want to do serious testing to 1.70
User avatar
Eric Walch
Slightly Grand Rear Admiral
Slightly Grand Rear Admiral
Posts: 5536
Joined: Sat Jun 16, 2007 3:48 pm
Location: Netherlands

Post by Eric Walch »

Defenders not launching can only be caused by problems in the internal function: "broadcastHitByLaserFrom". This function sends the "OFFENCE_COMMITTED" to the main station AI when a ship is attacked near the station.

The station AI itself was not altered but I see a flaw that is present in the old AI. It is constantly switching between the "IDLE" and "CHECK_FOR_DEBRIS" state. The "OFFENCE_COMMITTED" message is only evaluated in the "IDLE" state. when you happen to shoot a ship while the station AI is in the other state the message will not be noticed. But this is a flaw that was already there in the old situation. But it could also be intentional to let some offences go by undetected. (Like scanForHostiles" that is programmed to skip some ships in a scan)

EDIT: Wrong analyse of me. When stations also do not react on a direct attack, the problem must be somewhere else.

I tried to shoot at the main station directly. The AI comes in the defense state, but it is not launching defenders. Thus the command "launchDefenseShip" is not working properly. Shooting a Behemoth does launch defenseShips. But those are selected by the defense-role key.
User avatar
Eric Walch
Slightly Grand Rear Admiral
Slightly Grand Rear Admiral
Posts: 5536
Joined: Sat Jun 16, 2007 3:48 pm
Location: Netherlands

Post by Eric Walch »

deployEscorts is not working well. I just shot two escorted ships (a fuelTanker and a executive liner) and they didn't send their escorts. Looking at their AI they called the fightOrFleeHostiles command. This routine must deploy the escorts. I found the main ship in fleeing mode and according the target-dump they also had escorts.

Somehow here is also something broken. It probably happens to other escorts also but did not test it yet.
User avatar
matt634
Deadly
Deadly
Posts: 206
Joined: Tue Mar 21, 2006 6:32 pm
Location: Colorado, USA

Post by matt634 »

This may or mostly may not be helpful. After I upgraded from 1.65 to 1.70 I had to change my SecCom's scanclass from Station to Police. Under 1.70 the scanclass station did not seem to be reading OFFENSE_COMMITTED, but changing the scanclass to police fixed the problem. Of course, I know very little about how all this works, so I could be completely off on what's happening with the AI. All I know is changing the SecCom to scanclass police gave me a responsive, defense ship launching, station.
User avatar
Eric Walch
Slightly Grand Rear Admiral
Slightly Grand Rear Admiral
Posts: 5536
Joined: Sat Jun 16, 2007 3:48 pm
Location: Netherlands

Post by Eric Walch »

Matt wrote:
After I upgraded from 1.65 to 1.70 I had to change my SecCom's scanclass from Station to Police. Under 1.70 the scanclass station did not seem to be reading OFFENSE_COMMITTED, but changing the scanclass to police fixed the problem.
In the code it is programmed that ships with scanclass Police and ships of type stations get an OFFENSE_COMMITTED message. There could be something wrong now.
User avatar
LittleBear
---- E L I T E ----
---- E L I T E ----
Posts: 2882
Joined: Tue Apr 04, 2006 7:02 pm
Location: On a survey mission for GalCop. Ship: Cobra Corvette: Hidden Dragon Rated: Deadly.

Post by LittleBear »

Think Oolite expects:

"OFFENCE_COMMITTED" (British Spelling!) :wink: rather than "OFFENSE_COMMITTED" (US Spelling) , which maybe why it didn't work. The SpaceBar in Random Hits (nearly finished honest) has SCAN_CLASS ROCK (as its a big hollowed out rock), but seems to be launching bounty hunters in response to nearby crimes.
OXPS : The Assassins Guild, Asteroid Storm, The Bank of the Black Monks, Random Hits, The Galactic Almanac, Renegade Pirates can be downloaded from the Elite Wiki here.
User avatar
Commander McLane
---- E L I T E ----
---- E L I T E ----
Posts: 9520
Joined: Thu Dec 14, 2006 9:08 am
Location: a Hacker Outpost in a moderately remote area
Contact:

Post by Commander McLane »

According to the wiki, yes! (Although it's launchDefenseShip, quite confusing ! :? )
User avatar
Eric Walch
Slightly Grand Rear Admiral
Slightly Grand Rear Admiral
Posts: 5536
Joined: Sat Jun 16, 2007 3:48 pm
Location: Netherlands

Post by Eric Walch »

LittleBear wrote:
"OFFENCE_COMMITTED" (British Spelling!) rather than "OFFENSE_COMMITTED" (US Spelling) , which maybe why it didn't work. The SpaceBar in Random Hits (nearly finished honest) has SCAN_CLASS ROCK (as its a big hollowed out rock), but seems to be launching bounty hunters in response to nearby crimes.
Although Matt used the wrong US spelling in his message, he used the right spelling in his OXP. So when it works under 1.69 and not under 1.70 than is 1.70 to blame.

It is hard-coded that when a clean ship is hit by a laserbeam, oolite sends a OFFENCE_COMMITTED message to all ships with SCAN_CLASS POLICE and to all ships that are station or carrier. It does not look at SCAN_CLASS STATION but at the "station" role or the "isCarrier" key to determine if something is a station.

But US/UK spelling is sometimes confusing. We in the Netherlands only learn the UK spelling at school, but a lot of spell-checkers that came with English software used to be US. (Now I can select between US, UK, Canadian or Australian spelling on the Mac). This does not help in using a consistent spelling, although I try. When I wrote my thesis, I started in UK English, but only because my spell-checker at that time was US, I switched to US spelling.
Post Reply