aliens

Author Topic: Brutal-OXCE 9.1.4  (Read 58092 times)

Offline Alpha Centauri Bear

  • Colonel
  • ****
  • Posts: 466
    • View Profile
Re: Brutal-OXCE 7.13.1
« Reply #45 on: December 22, 2023, 05:50:39 pm »
You are right. In multi-story-houses it can get confusing. I noticed this in my own play-testing.

The z-axis always gets set to the current one when drawing the arrow. I'll experiment what happens if I don't do this.

The problem with yellow arrow is to understand what level they point at even if you don't reset their z-axis. Since it is two-dimensional screen we have, you can easily mistaken its position to the one level above but closer to you. Maybe drawing some kind of cube shape like the battlefield cursor but different color. Then player can understand the position exactly by aligning cursor with the marker.

I am not proficient with the "yellow arrow" mechanics. I may be wrong. See what works best for you.

Another idea could be to color it differently from the one generated by the scanner. Probably makes sense too since they are different mod mechanics and can evolve differently too.
« Last Edit: December 22, 2023, 05:58:24 pm by Alpha Centauri Bear »

Offline Alpha Centauri Bear

  • Colonel
  • ****
  • Posts: 466
    • View Profile
Re: Brutal-OXCE 7.13.1
« Reply #46 on: December 22, 2023, 05:56:00 pm »
The problem occurs in combination with your last remark. The scanner-information is more up-to-date but lacks the information of the z-coordinate. If I make sure to show the right z-corrdinate for the spotted unit, then overriding it with the scanner will ruin that information. So I need to think about a better solution.

That is what I was asking. I don't understand what is to override. These are two pieces of completely independent information. They depict LOCATION not the unit. Player spotted a location where shot came from. Then player spotted a location where there is a movement. They could be created by the same unit - nobody cares. They may coincide on the map and look like a single mark - that is fine too. You should NOT remove a marker for the shot just because the unit moved and later was detected by scanner. This is just a helper for the player to remember things. It is not like player forgets where shot came from just because they used the scanner.
🤔

Offline Alpha Centauri Bear

  • Colonel
  • ****
  • Posts: 466
    • View Profile
Re: Brutal-OXCE 7.13.1
« Reply #47 on: December 22, 2023, 08:10:50 pm »
Folks, who is interested, please help me to figure out best UI.
The topic: https://openxcom.org/forum/index.php/topic,11659.0.html

Notification pops when continuous undetected alien activity in area reaches threshold. This is a player helper that allows not to watch graphs on a regular basis.
The question is how to handle countries (the second tab in graphs).

Countries do not cover whole globe. They also can intersect with multiple areas. So it seems to be helpful information to pinpoint location.
The problem is UFO usually resides slightly longer in area than in country. So if we would show them separately, the country popup would almost immediately follow up the area one. Is it annoying? Does it make sense to show them together? Does it make sense to just list all areas and countries in the list, etc.
What do you think?

Offline Alpha Centauri Bear

  • Colonel
  • ****
  • Posts: 466
    • View Profile
Re: Brutal-OXCE 7.13.1
« Reply #48 on: December 22, 2023, 09:53:13 pm »
Do I understand correctly that AI marks not only dropped items but also picked up ones? I.e. something was laying on the floor and now it is not.

Offline Xilmi

  • Moderator
  • Commander
  • ***
  • Posts: 642
    • View Profile
Re: Brutal-OXCE 7.13.1
« Reply #49 on: December 22, 2023, 11:21:24 pm »
Do I understand correctly that AI marks not only dropped items but also picked up ones? I.e. something was laying on the floor and now it is not.
I'm actually not sure about that. I think there may be a bug/unintended marking, which I wasn't aware of until I played with the new Alt-feature and sometimes could see a mark when I don't think I should have seen it. I have yet to find a way to reproduce it and figure out the reason in order to fix it.

Also in regards to your other point about how exactly it should be displayed. You suggested to use something other than the arrow. That's a lot trickier to implement. For the arrow I just had to hijack the respective existing method and make some adjustments. To draw something different instead would be more difficult.

Also the way it's implemented iterates through the units, that's why it makes only one arrow per unit if both scan and spotted is the case. So what I hope I can maybe accomplish would be a separate different color-arrow that is also only shown on the level the unit was seen.

Edit: I tested it and also checked the code again: Picking up items doesn't mark. Something I had forgotten that also marks and might be the explanation for the unexplained markings is getting hit. For example by friendly fire or by blind-shooting. It still doesn't really explain it because I'm got one right inside the UFO, where there is no reason for anyone to have been affected by friendly-fire.

But I can't reproduce it. So I'll just have to keep going and observing.

Oh, I think I get it now. It's because I used Autoplay. And autoplay runs the AI-routine that guesses for a new location when they see the location they guessed is vacant. So he probably was seen at the door. Then someone looked there and he wasn't there anymore, so they guessed he must have gone into the UFO. I think I'll go with that hypothesis. In this case stuff like that shouldn't happen when I play myself.
« Last Edit: December 23, 2023, 12:40:35 am by Xilmi »

Offline Alpha Centauri Bear

  • Colonel
  • ****
  • Posts: 466
    • View Profile
Re: Brutal-OXCE 7.13.1
« Reply #50 on: December 23, 2023, 12:10:25 am »
Also in regards to your other point about how exactly it should be displayed. You suggested to use something other than the arrow. That's a lot trickier to implement. For the arrow I just had to hijack the respective existing method and make some adjustments. To draw something different instead would be more difficult.

Also the way it's implemented iterates through the units, that's why it makes only one arrow per unit if both scan and spotted is the case. So what I hope I can maybe accomplish would be a separate different color-arrow that is also only shown on the level the unit was seen.

That is the exact reason I think you should not reuse scan spotted routine. You don't want to hook on its future modifications in OXCE. I still think the cleaner solution would be to draw your own as they they have conceptually different marking mechanics, not even mentioning they are originated in different forks.

I sure may help you if you are interested.


Offline Alpha Centauri Bear

  • Colonel
  • ****
  • Posts: 466
    • View Profile
Re: Brutal-OXCE 7.13.1
« Reply #51 on: December 23, 2023, 12:23:30 am »
Now the puzzle starts coming together. It is still hard but, at least, I know why am I getting hit out of nowhere.

The tactics differences summary:
- Priming and throwing at the same turn is a NO-NO. Even more relay throwing. Pre-prime, throw, then run for your life the hell out of this location. At least at the sonic pulser explosion radius.
- Same for shooting. Reserve time for get out of cover, shoot, fall back.
- No dropping stuff on the ground. Ugh. If had to - run away.
- Move in a relative compact group to retaliate against jump shooters. This is no different from vanilla except here it is much more difficult to shoot them back from far away due to them taking cover much better. It may require some amount of maneuvering to get into retaliation position.
- Move groups in sweeping fashion trying to keep uncleared locations just by one side of the squad. Moving toward the center in between unknown locations is mighty dangerous.

I also found some bearable disembarking tactics. Let tanks slightly out of the bay so they do not interfere with soldiers internal transport movement. Soldiers preprime grenades (regular or smore or whatever), run out of the transport, throw, run inside. Few turns like that to cover area with smoke or as long as needed to throw grenades at everyone in vicinity. Then disembark and spread. Meanwhile, use scanners to spot enemy nearby and use tanks to kill them at close range. Tanks may be banged up pretty badly and even destroyed but this seems to be least evil comparing to losing whole squad.

Offline Abyss

  • Colonel
  • ****
  • Posts: 355
    • View Profile
Re: Brutal-OXCE 7.13.1
« Reply #52 on: December 23, 2023, 12:37:11 am »
Quote
The old one led to the AI being severely nerfed and playing a lot worse.
Well, it would have been comparable to vanilla AI on 40% random on the battle output, if not grenades.
60, 80, 100% randomness were completely useless options, in this regard.
I found it quite challenging to play SH/Ironman vs 20% random, which I switched to after some adaptation. And 100% intel is unbeatable in long term.

I would play vs 100% BAI on a map  with unit ratio 1:2 - 1:2,5, but when it comes to 1:4 it is getting too troublesome. So dismission of this option solely affects SH players, while other difficulties are affected much less.
So,
- I would still leave it, but marked as *only 100% BAI reports accepted*
make randomness quantity more narrow, from 0 to 40, with increment 10. 
- 20% means that 80 out of 100 still kill you, while 20 do things.
 BTW, battle vs human fractions ends when ~20% enemies are left and leaders are killed.
 - And while initial number of 100 enemies with even 40% randomness gives the significant push, further AI power dissipates quite rapidly. This is what I disliked, despite the good effect of few first turns.
A couple of options to maintain the combat potential of BAI in case of randomness stays:
- hard binding of random units (mean they are useless dummies until the endo of the battle)
- or decrement of randomness upon battle goes on: 40% in the beginning - 30% turn 3, 20% turn 5, 10% turn 7, min cap is selected by player.

Offline Xilmi

  • Moderator
  • Commander
  • ***
  • Posts: 642
    • View Profile
Re: Brutal-OXCE 7.13.1
« Reply #53 on: December 23, 2023, 12:57:49 am »
Now the puzzle starts coming together. It is still hard but, at least, I know why am I getting hit out of nowhere.
Yup, your conclusions about how to tactically adapt are spot on.

Something that used to work pretty well was flanking. Once the AI has a grasp where your units are, go a long way around and attack them from the backside.
However, I implemented counter-measures by adding different ways of peeking. Before the AI would always only peek towards the direction they'd expect the enemy coming from. Now they also like to peek at any location that haven't been revealed this turn.
While this makes flanking a lot more difficult, it's still kinda valid. The AI will usually end their turn in positions from where they hope to ambush the player based on where they think the player is. So appearing suddenly at a position they are not expecting you to come from can work well.

But yeah, disembarking is difficult. Especially with no cover or only alien-infested cover nearby.

Offline Alpha Centauri Bear

  • Colonel
  • ****
  • Posts: 466
    • View Profile
Re: Brutal-OXCE 7.13.1
« Reply #54 on: December 23, 2023, 01:09:56 am »
At which point AI receives a clue an item dropped on the ground? Immediately or at their turn? Do they notice if I drop and pick in same turn?

Offline Xilmi

  • Moderator
  • Commander
  • ***
  • Posts: 642
    • View Profile
Re: Brutal-OXCE 7.13.1
« Reply #55 on: December 23, 2023, 01:19:28 am »
@Abyss:

My issue was that in XCF, there is this sniper-meta. Player builds a line of units that cover a huge amount of the map. Due to the combination of high sight-range and these units having awesome reactions and accuracy, the best way to play against that is to stay inside and wait until they move in range in order to ambush them.

A random chance to deviate from this behavior and run outside means it's just a lot of pressing end turn while a small amount of units will make the suicide roll and walk out of their cover into the reaction-fire of the snipers.

The change to how intelligence works is basically a shift from low intelligence causing occasional massive blunders to low intelligence causing inaccuracies. It's akin to how this is also resolved in modern chess-engines. Earlier their lower difficulty levels would also blunder from time to time. Nowadays they calculate the best move among some others and then pick a move that is closest to the average inaccuracy of a player of the ELO it tries to emulate.

In order to truly do something similar in my AI, instead of randomizing the result of each move but still picking the best score, I'd have to put all scores in a map, so I could then pick the score that is closest to the desired percentage of the best move.

I could do an experiment where I reverse it and look at what it looks like when the AI picks the worst move of the ones it considered for a certain purpose.

Offline Xilmi

  • Moderator
  • Commander
  • ***
  • Posts: 642
    • View Profile
Re: Brutal-OXCE 7.13.1
« Reply #56 on: December 23, 2023, 01:26:19 am »
At which point AI receives a clue an item dropped on the ground? Immediately or at their turn? Do they notice if I drop and pick in same turn?
Unfortunately it's immediately. Simply because it was easier to make the call when it happens rather than checking the before and after state of all tiles. And to be honest I'd rather remove that capability alltogether instead of implementing it in a way where it's only at the end of the turn. It's not important enough for the overall play of the AI to put in that effort.

I think the greatest potential is within the "guessing where the enemy might have gone"-method of the AI. The potential of further improvements in that regard can be seen by enabling "Bug hunt mode for brutal AI".

Edit: Except it isn't. I just tested it and the AI doesn't work properly with bug-hunt-mode enabled. I guess that's something I can fix. It seems to both not consider attackable targets attackable and also not want to peek at all. It used to work along time ago but currently doesn't.
« Last Edit: December 23, 2023, 01:36:14 am by Xilmi »

Offline Alpha Centauri Bear

  • Colonel
  • ****
  • Posts: 466
    • View Profile
Re: Brutal-OXCE 7.13.1
« Reply #57 on: December 23, 2023, 01:29:30 am »
I second that. The ability to notice where on the battlefield someone dropped a used ice-cream cap is kind of cheesy. I never used it as a player and I doubt anyone does this on a regular basis. So this should preserve fairness.

Also, as I mentioned before, this would just doom unconscious soldier right there. That seriously impair the "healing" mini game.

Offline Alpha Centauri Bear

  • Colonel
  • ****
  • Posts: 466
    • View Profile
Re: Brutal-OXCE 7.13.1
« Reply #58 on: December 23, 2023, 01:38:01 am »
Note on the spotting mechanics. Can open separate thread if needed.

I checked your code and it seems that you attach "last spotted" property to the unit. This does not seem right since spotting action outside of visibility does not reveal the unit itself, only action.
Meaning, you have a location where shot originated from. Which unit did it remains unknown. Moreover, game does not indicate whether multiple actions were conducted by same unit or multiple. Of course, one can infer that actions from opposite corners cannot be done by same unit but this is up to human/AI to decide. The point is game engine should provide the information, not conclusion. In this regard, action locations are self informational data not related to any unit. If unit is invisible it is not even possible to tell whether it is still at location or moved away.

This is, actually, another strong reason not to mix it with scanner indicators because it spots actual units, not action locations.

Offline Xilmi

  • Moderator
  • Commander
  • ***
  • Posts: 642
    • View Profile
Re: Brutal-OXCE 7.13.1
« Reply #59 on: December 23, 2023, 02:34:07 am »
I just tested it and the AI doesn't work properly with bug-hunt-mode enabled.
I fixed it and it now works as intended.
The AI usually loses most of it's units in that mode once it becomes very confident that it is winning and starts pushing forward, exposing it's units.
So while it would achieve better kill:death-ratios if it didn't do that and stay at low aggressiveness, there is a purpose in that:

Trauson used to just manually loot the corpses of the areas of the map he controlled, even if he didn't see a chance to win the mission. That's partly why scaling aggressiveness was introduced. Low aggression would lead to stalemates, which is not desirable.