Open AI Question

General discussions about X Rebirth.

Moderator: Moderators for English X Forum

User avatar
Sinxar
Posts: 1224
Joined: Tue, 22. Mar 11, 05:44
x4

Post by Sinxar » Wed, 12. Jul 17, 20:40

my 2 cents if it means anything.

If you give a ship a 'keep at range X' order there would have to be other safeguards in place. On its own, yeah that would be dumb.

This could be easily exploited by other AI, even unintentionally. For example, if you have a drone platform with a slightly lower speed than the attacker, will it be smart enough to realize that there is no escape and will likely die if it continues unless action is taken?

This is actually a problem with real people as well in the game Eve Online. People tend to use the orbit and keep at range options and what happens is the attacker with a ship with similar or greater speed will simply approach the target causing them to just move in a straight line away making them a very easy to hit target.

In the context of an X game, telling a long range vessel to attack a target and it wants to keep at range or orbit (assuming this will be the default behavior) would likely be just as problematic. Lets say you have a long range missile boat like an M7M. Should it attempt to move to a specific distance? If so, how will it handle an unexpected event such as the target AI moving to attack as well? What if the target does the same thing? What if a different AI moves in and attacks the M7M?

There is another case where something like this could be problematic. Imagine a repair vessel of some sort that needs to be within some range of the ships it is healing to be of any use. If it tries to keep distance, will it move away from the group? Can it heal others while running? Is there any point to running since you would presumably be in a group of friendlies?

I understand this doesn't really help in the context of your original question but just some things to consider when you guys write the AI in general. Please be careful of easily exploitable AI (by players and other AI's).

User avatar
Nikola515
Posts: 3187
Joined: Fri, 4. May 12, 07:40
x4

Post by Nikola515 » Wed, 12. Jul 17, 20:58

This sounds like perfect AI for ships like Light/Heavy Sul or Stromwork.... They don't have any heavy/long range weapons and they can deal damage with drones form safe distance. Also this would be ideal AI for X3 TM ships as well.

It would be interesting to see if specialized boarding ships could do something similar as well ;)
It's not world hunger because we can't feed poor,it's because there will never be enough to feed the rich .....

UniTrader
Moderator (Script&Mod)
Moderator (Script&Mod)
Posts: 14571
Joined: Sun, 20. Nov 05, 22:45
x4

Post by UniTrader » Wed, 12. Jul 17, 21:34

just a thought which crossed my mind: if you keep the Enemy Ship just inside Radar Range check before that its not fhe Fallback Radar, but the primary one. because if that one is destroyed the Radar Range oc them comes dangerously close to the Weapons range of most other Objects..
if not stated otherwise everything i post is licensed under WTFPL

Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter ;)

I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help ;)

RodentofDoom
Posts: 406
Joined: Sat, 27. Feb 16, 09:37
x4

Re: Open AI Question

Post by RodentofDoom » Thu, 13. Jul 17, 00:26

Lord Crc wrote:
j.harshaw wrote:How dumb would it seem if you order a ship to attack something, and your ship moves away from that thing to outside of its own turret range, and keeps the target at that range?
You just described exactly how the Balors should behave...
and any ship fitted with a HIC
j.harshaw wrote:Let's assume that:

- it has no long-ranged weaponry, so it can't shoot at the target from the range that it's trying to maintain,
- that it can affect things as long as it can see them,
- but that what it can do might not be immediately apparent.

Sorry for being vague. Not sure how much of this is going to make it in.

So you give an attack order, and what you see is that it moves away, and stops.

Thanks, everyone, for participating, by the way.
If i've given an attack order, i expect exactly that to occur
id like to be able to choose alternatives myself as, no offense intended, the auto-scripting usually struggles to perform

Huillam
Posts: 430
Joined: Fri, 16. Dec 11, 11:24
x4

Post by Huillam » Thu, 13. Jul 17, 02:18

j.harshaw wrote:Something like that.
Could we get a something like that order then?
If I issue an attack order and then my ship ends up doing something else because you were trying to guess what I meant by "attack" then the command is misleading.

Zetoss
Posts: 396
Joined: Tue, 18. Dec 07, 00:17
x4

Post by Zetoss » Thu, 13. Jul 17, 03:54

Just gonna throw a relevant comment in here: Frankly a BIG part of the problem with XR is that some things are automated and beyond our control to manipulate in detail, it has been pointed out in this thread to some extent already but any system that removes our exact control must both perform its function very well AND be either painfully obvious or spelled out in text. Failing to do either of these elements results in extreme player annoyance, since even rather unimpressive human brains are far better at grasping 3D systems and "big picture" scenarios than even very advanced AI can accomplish (without devoting unreasonable processing power) it will immediately become apparent when the AI does something far from clever and unless we understand what it's trying to do it will simply look dumb.

Circling back to the main topic we'd immediately understand if a carrier tries to keep a fair distance but if a seemingly near pristine destroyer flies off for a very unclear reason but is in fact repairing its damaged jumpdrive for future emergency retreat it would at a glance look very stupid until it tells us about that plan. So far XR can tell many details if one opens up 500 menus and knows what to look for but it would be far more helpful to be informed of not a choice between "main objective" OR "sub objective" for a ship by selecting it; expanding the info window to show both at the same time would help a lot. Example using a variation of the original topic; "Attacking Xenon: Maintaining distance to launch drones" or something like that would immediately tell us that the ship is following an order in a clever way instead of seemingly going on a random pleasure cruise. Unowned ships need not provide any such info though, more fun to be in the dark and make a guess based on observation of owned assets.

TL;DR Perfectly fine to be vague on the forums and with news regarding future features and/or games... but never be vague about a finished feature inside a released game and never remove our control without replacing it with robust and powerful AI that lets us know what it's doing. Also I'm sorry for always being overly wordy.

User avatar
Sam L.R. Griffiths
Posts: 10522
Joined: Fri, 12. Mar 04, 19:47
x4

Re: Open AI Question

Post by Sam L.R. Griffiths » Thu, 13. Jul 17, 12:13

j.harshaw wrote:Please keep in mind that this will primarily benefit X4, and that it's quite possible that nothing will come of this, so please don't expect anything to.

How dumb would it seem if you order a ship to attack something, and your ship moves away from that thing to outside of its own turret range, and keeps the target at that range?
It would depend on the ship and whether the turrets were considered offensive or defensive weapons.

Providing the default behaviour makes sense relating to ship capabilities then it does not sound that dumb. I would however expect to be able to override the default behaviour.
Lenna (aka [SRK] The_Rabbit)

"Understanding is a three edged sword... your side, their side... and the Truth!" - J.J. Sheriden, Babylon 5 S4E6 T28:55

"May god stand between you and harm in all the dark places you must walk." - Ancient Egyption Proverb

"When eating an elephant take one bite at a time" - Creighton Abrams

User avatar
Santi
Moderator (DevNet)
Moderator (DevNet)
Posts: 4046
Joined: Tue, 13. Feb 07, 21:06
x4

Post by Santi » Thu, 13. Jul 17, 23:11

I will prefer to have that behaviour as a setting rather than linked to the attack order. It could work very well for carriers or torpedo boats, also as bait for ambushes if some kind of waypoint system is going to be in place.

In fleet engagements if ships are going to operate with the current range, it could be problematic as they are quite close to each other and the ship could get away of the target to fall within range of another enemy ship.
A por ellos que son pocos y cobardes

User avatar
ezra-r
Posts: 3420
Joined: Fri, 14. Oct 05, 21:04
x4

Post by ezra-r » Sat, 15. Jul 17, 00:33

* If it moves away from target without a specific tactic -> stupid

* If it moves away because shields < X% and there is certainty ship needs stock up more shields to resist a confrontation -> Good!

* If it stays away from target's range and its own shooting range to lure target where other friendly ships await to crush it. Very good!

In any case and generally, ships should do, and without much wait, everything the player says, because player is going to be always infinetly smarter than game AI (at least for the following 10 years), so the best for player enjoyment is to see that ships do exactly as player says. So:

* Ships should have two main things, a prefered range/method, and a preference to stick in formation or close to other friendlies which can give an edge in battle against other ships.

Now

* If player says attack, ship chooses its prefered range & method if possible and tries to stick to it QUICK to pound enemy ship (we do not want to see ships spending minutes in reaction).

* If player says escape, ship should do its utmost to choose the quickest path out (not parking like a granny manuvering for too long until it gets destroyed), and if the human order came too late (because humans err too), Warn about it and go arms blazing against enemy like kamikaze.

So, basically and briefly, ships should have a favourite method/range (guns, missiles, phallic gun, short range, long range), go like hell for it and quickly follow orders, so human player can play his/her own favourite tactic and enjoy it.


Enemy AI should have tricks (specific warefare manuvers) and be evil to crush human player. Example, human has alsmot finally crushed all enemies and when relax starts to sink in, two enemy capitals warp in on top. Be evil!



PS: Sometimes smartness is not as important as a quick well made reaction, and the latter is much easier to do than programming smart AI.

User avatar
Killjaeden
Posts: 5366
Joined: Sun, 3. Sep 06, 18:19
x3tc

Post by Killjaeden » Sun, 16. Jul 17, 00:05

SO if i understand this right, you consider scrapping an AI feature because the communication AI - player is questionable?

Wouldnt it be more logical to solve the AI - player communication issue instead of designing AI features around the lack of it? This is not the only case where AI can do things that might not be immediately apparent to the player.

Solution for AI communcation:
Create a way to communicate what the AI is doing properly. Have a ship action status "Combat status: engaging ; Movement status: entering combat range" in the interface, or something like that. This displaying of status makes sense for other situations as well. Situations of AI hiccups can be more logical this way. Situations like: "Combat status: Engaging; Movement status: Avoiding Collision".

In addition this would be usefull for OOS situations, where its not as easily visible what the ship is up to.
______________________________________________________

As for the engagement from long range - i have a better suggestion:

Have the player toggle the preferred range of a ship, in general. This makes sense for any AI capital ship in fact, and even is desirable for fighters. Have the selectable range options be dependant on maximum range of it's weapons/ other "gimmicks", and/or scanner range. If the player wants to use "kiting" tactics with a ship that has special long range "effect" - he sets maximum range of this weapon. If he thinks this is bad for some reason (say, he wants it to stay close to his other ships, so he can protect it better) then he sets the preferred range shorter. Set up sensibel default values for players who dont want to tamper with it.

If you need an example, look for Battlefleet Gothic: Armada (RTS capital ship game). You can set preferred engagement range, and preferred engagement direction (frontal attack, broadside left and broadside right) and let the AI do it's thing - or override it manually with regular RTS controll.

I would go and say that setting up both minimum and maximum combat range would be even better. Because this would be multipurpose. It works for ships using frontal attack (fighters and other stuff) - maximum range is the range they start shooting at, minimum range is when they start to break off from the attack. Then they fly away until they reached maximum range, turn around and engage again. This can be very usefull to be able to change, when the default behaviour isnt fitting ones needs.
And for ships using broadsides as engagement mode, the two ranges define the area around the target, where they should stay. It is better to define the area instead of a set range, because with the area you influence the "tolerance" of the range to target. Higher tolerance means less extreme maneuvers required to keep the preferred range. The ship only needs to start maneuvering drastically once the target is not inside this allowed area anymore.

ezra-r wrote: Enemy AI should have tricks (specific warefare manuvers) and be evil to crush human player. Example, human has alsmot finally crushed all enemies and when relax starts to sink in, two enemy capitals warp in on top. Be evil!
What you describe as "warfare maneuver" has nothing to do with actions of a single ship.
[ external image ]
X-Tended TC Mod Team Veteran.
Modeller of X3AP Split Acinonyx, Split Drake, Argon Lotan, Teladi Tern. My current work:
Image

UniTrader
Moderator (Script&Mod)
Moderator (Script&Mod)
Posts: 14571
Joined: Sun, 20. Nov 05, 22:45
x4

Post by UniTrader » Sun, 16. Jul 17, 00:49

hmm, maybe the question should be rephrased. because "make it an option" is often not an option* (and i think in this case its not the answer desired, as so often when this is suggested).

so lets phrase it more like "How Should non-player Ships (NPC Ships) in battle behave per default? what distance should they keep to Enemies"
Or maybe "if we turn the Distance Ships ry to keep from their Enemies into an Option what should be the default value?"
because thats basically the question which was really asked.. not wheter the Menus should be cluttered with ever-more options or not.

i cannot speak for w.evans but i am pretty sure he agrees.





* Problems with Options:
=> not feasible for non-player stuff
=> too many interacting Options cause far more test cases (basically all settings or reasonable intervals of them have to be tested, and this in any combination witth other more or less related options. 2 related options with 4 settings each may not sound much, but this are 16 possible combinations/settings already)
=> too many options clutter the Menus
=> if the default behavior is really bad (and thats the one the NPCS usually use!!!) it might not be noticed because its immediately changed by players
=>
if not stated otherwise everything i post is licensed under WTFPL

Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter ;)

I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help ;)

User avatar
Killjaeden
Posts: 5366
Joined: Sun, 3. Sep 06, 18:19
x3tc

Post by Killjaeden » Sun, 16. Jul 17, 01:15

not feasible for non-player stuff
use predefined default values. And this question was related to player stuff.
too many interacting Options cause far more test cases
In general yes, but this is very specific. The AI already uses preset ranges for it's code. By giving those options you are exposing the numbers and ability to vary them in a certain range.
Suggesting that this creates too many test cases is ridiculous. You have to test default ranges to "hardcode" anyway. So you might as well loosen up and allow to change it.

If the default behaviour is bad, regardless of having options or not - you failed at your job eitherway. In this case, having the option to change it is more desirable, because the player can mitigate the issue, or situations that you as developer did not consider. In X3 there where plenty of such issues with ships engaging (frontally) from too long distance, breaking of too late/early. No way to change it without dirty model hacks.
A rework of the AI combat and controll mechanics is long overdue. This is the time to do something about it. Adding more bandaids again (X3 style) is not the way to go with a "fresh" engine.
too many options clutter the Menus
I wasn't under the impression that X4 will be designed for mobile devices? RTS games somehow manage to convey a lot of information and options of many units efficiently. I dont see why this would not be achievable by a X game, or why Egosoft would be incapable of doing it. And options that you generally set up once together with the weapon/turret setup and only change when weapons/turrets change, do not have to be in a map overview. They can remain in the weapon setup screens.
what should be the default value?
Middle ground between two possible extremes. Since the middleground is always a compromise and rarely suits player needs, options are needed.
[ external image ]
X-Tended TC Mod Team Veteran.
Modeller of X3AP Split Acinonyx, Split Drake, Argon Lotan, Teladi Tern. My current work:
Image

UniTrader
Moderator (Script&Mod)
Moderator (Script&Mod)
Posts: 14571
Joined: Sun, 20. Nov 05, 22:45
x4

Post by UniTrader » Sun, 16. Jul 17, 06:48

my reply was more meant in general against this "all-soving" magic"solution" to turn literally everything into an Option. when im am asking what NPC behavior makes sense or how the NPCs should behave/decide for my Script Project this is usually the first answer which pops up, and its getting quite annoying. not only is the original question circumvented without answer, but my impression is that most giving this answer feel really smart for giving this answer which is not helping me at all.



and in reply to you post more specifically:
what should be the default value?
Middle ground between two possible extremes. Since the middleground is always a compromise and rarely suits player needs, options are needed.
which middle gound? some distance wher the enemy Ship can hit the current Ship but we can not hit the Enemy because the Enemy has a far longer Range?




and you again dodged the question asked with options. :roll:[/quote]
if not stated otherwise everything i post is licensed under WTFPL

Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter ;)

I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help ;)

j.harshaw
EGOSOFT
EGOSOFT
Posts: 1879
Joined: Mon, 23. Nov 15, 18:02

Post by j.harshaw » Sun, 16. Jul 17, 10:16

Thanks, all, for taking the time to air your views. Think i got my answer, that answer being "it's fine, if/but" which i'm interpreting as "it does look dumb, but please implement it if it makes sense anyway."

As to the intentions, no, cutting the behavior out is not an option since the ships i am designing this behavior for cannot function properly without this behavior, and these particular ships themselves will require a not-insubstantial investment in time and money (both in-game, of course) to set-up. (Aside: that time and money is necessary due to the variability of the various set-ups).

Anyway, it's in, but can still be radically changed since the game isn't out yet. But please feel free to continue this discussion. Think it's healthy.

Yes, there are a lot of options for every behavior that you can define if you're inclined to, but plan is that you should be able to play the game without having to. Yes, you can override certain aspects of these behaviors by playing with those options. No, we are not implementing overrides as alternate behaviors for every behavior in the game.

@Sinxar, i'm afraid that exploits are inevitable. AI, whether simply scripted, fairly complex, or even heuristic, necessarily works with a limited logical palette and, once you understand everything in that palette, you can figure out a way to act against an AI in such a way that a response simply isn't in that palette. Unless that AI can actually write new stuff into their palette, but, yeah, probably a while before we (the human race) get there in a form that you can consume in a home computer yet. That said, we do try to prevent or circumvent the exploits we come across, and do take the time to try and figure out what exploits would be possible before implementing a behavior. We are also conscious, however, that for every interaction of behaviors we deal with, there are very many cases of interaction we haven't thought of, and many more once you put a player in the equation.

User avatar
arragon0815
Posts: 16722
Joined: Mon, 21. Aug 06, 13:17
x4

Post by arragon0815 » Sun, 16. Jul 17, 10:35

j.harshaw wrote: ./but" which i'm interpreting as "it does look dumb, but please implement it if it makes sense anyway."
Is this for big ships and the player sitting next the pilot: Make a monitor where the behavior is written on it. Or let the pilot say what he doing.

For the other ships: in XR you have a monitor to and when you mark the ship...

i hope you unterstand what i mean :oops:
AMD Ryzen 9™ 7900X3D // PNY GeForce RTX™ 4070 12GB Verto // Kingston FURY DIMM 32 GB DDR5-5200 Kit // GIGABYTE B650E AORUS MASTER // Enermax ETS-T50 AXE Silent Edition // SAMSUNG 980 PRO 1 TB SSD + Seagate ST2000DM008 2 TB // Thermaltake Toughpower GF3 1000W // Microsoft Windows 11 OEM // 65" Sony 4K Gaming TV, 120 Hz.
X4 rennt wie Sau in 4K :eg:

RAVEN.myst
Posts: 2585
Joined: Mon, 20. Jun 11, 13:16
x3tc

Post by RAVEN.myst » Sun, 16. Jul 17, 11:29

j.harshaw wrote:... that time and money is necessary due to the variability of the various set-ups).
This sounds very tantalizing indeed! Best luck with it - I very much look forward to seeing it when it's done. :)
j.harshaw wrote:there are a lot of options for every behavior that you can define if you're inclined to, but plan is that you should be able to play the game without having to.
I think this is a key aspect - playable without fiddling, but the fine-tuning allows playing well. This paradigm should satisfy both the serious player who wants to keep "taking things to the next level", and the more casual player who just wants it to work intuitively - some people like to tune their car engines and what-not (well, less so with modern engines and fuel-injection and what-not...), while others are happy driving an automatic.


Again, best wishes!
-
Boron passenger: "You must hurry - my testicles are drying out!"
-
Born on Lave, raised on Freeport 7...
-
The Write Stuff

User avatar
Killjaeden
Posts: 5366
Joined: Sun, 3. Sep 06, 18:19
x3tc

Post by Killjaeden » Sun, 16. Jul 17, 11:52

UniTrader wrote:my reply was more meant in general against this "all-soving" magic"solution" to turn literally everything into an Option.
I understand that. But if we react on principle for every situation, the game would be without options and called X: the cookie clicker. If the option provides very meaningfull positive impact to the game then the necessary "evil" of interface space and additional tests will be worth the additional functionality. Especially in an area that is most requested for better features (AI behaviour and controll possibilities).
and you again dodged the question asked with options
A vague question can only be vaguely answered, because the details are what makes all the difference. Garbage input -> garbage output.
This "magic" ship beeing told to engage and flying away from target - if the function is not clear to the player then yes it certainly 1ooks stupid the first times the player uses it. If the function is very clear and properly communicated then no, it will appear working as explained, or if the player figured out himself how it works (that would be bad design i might add). However does it make sense for the ship to move away, and would the player have reason to not have it act like this? Again, details. But most assuredly, yes there will be reasons to not have it fly away in uncontrolled manners. Especially in chaotic multi target environments where enemies could come in from every direction

Should AI opponents try to stay out of weapon range? Again, no definite answer possible because details. If this a fast and maneuverable ship with incredible range then most definitely no. Base principles of unit balancing have to be remembered (scissor stone paper) and enabled in AI behaviour. When the archer is charging in with the spearman then he could get cut down from other spearmen. If he stays at range, he can be picked of by horsemen. To judge what to do you need to assess the entire situation. Numbers and positions of friendly and hostile troups. Is spearmen count vs theirs in favor of us? Are enemy horsemen more numerous? Are some enemy horsemen close to hurt me, are friendly spearman close enough to protect me? There can be no generally applicable answer what to do in this without assessing and processing all the information. If you want generally applicaple answers you would have to reduce complexity drastically (Endless space "combat"... BARF).

WITH option to define ai engagement range, you can vary it up randomly for hostile targets. Thus not every enemy of the same type will behave exactly the same. So you couldn't use a scout ship to have AI "engage" it by moving away from it in a predictable direction right into the arms of a heavy hitter of yours. This also highlights that in multi target environment, the most easy implementation of this behaviour (moving away directly from the target) will be easy to abuse. Also, what if you switch targets in different direction multiple times? The ship will constantly move distances in the magnitudes of maximum weapon range.
[ external image ]
X-Tended TC Mod Team Veteran.
Modeller of X3AP Split Acinonyx, Split Drake, Argon Lotan, Teladi Tern. My current work:
Image

Zetoss
Posts: 396
Joined: Tue, 18. Dec 07, 00:17
x4

Post by Zetoss » Fri, 21. Jul 17, 22:22

I'm certainly no expert but it looks like there are way too many suggestions in this thread that would either pile a year of extra work on X4 with little noticeable gain or end up demanding only the most extreme of computers for the game to work.

That said, there is a bare minimum of "situational awareness" needed for an AI to qualify as good: attacking its target in a way that actually works. Right this moment I'm looking at my Fulmekron circling a Xenon I, the Fulmekron has half of its weapons left but none along its edges, the XeI has almost no weapons left at all and 20% hull. They have been staring each other down for 20 minutes, my Fulmekron can take it out in seconds by going in for the kill but it refuses to get close and steers too far away for the remaining weapons to do more than halt the XeI's self repair. This isn't how a battle with only two participants should look if the AI is aware of its own capability and its enemy.

User avatar
Sandalpocalypse
Posts: 4447
Joined: Tue, 2. Dec 03, 22:28
x4

Post by Sandalpocalypse » Sat, 22. Jul 17, 05:56

i think an attack command should always be an attack command, and some other behavior should be classed as something else.
Irrational factors are clearly at work.

User avatar
mr.WHO
Posts: 8577
Joined: Thu, 12. Oct 06, 17:19
x4

Post by mr.WHO » Sat, 22. Jul 17, 08:12

j.harshaw wrote:Let's assume that:

- it has no long-ranged weaponry, so it can't shoot at the target from the range that it's trying to maintain,
- that it can affect things as long as it can see them,
- but that what it can do might not be immediately apparent.

Sorry for being vague. Not sure how much of this is going to make it in.

So you give an attack order, and what you see is that it moves away, and stops.

Thanks, everyone, for participating, by the way.
Does drones or fighter count as long range weaponry?

Because what you described fit perfectly the Carrier behaviour. I point the target (attack command). Carrier launch it's attack wing and stay away from target keping distance waiting for dammaged fighters to return from combat.
Something like that would be perfect albeit there would be the need for player to give "real attack (charge)" command too if situation require direct attack.

Post Reply

Return to “X Rebirth Universe”