XCOM: Enemy Unknown
0 of 0

File information

Last updated

Original upload

Created by

kawyua

Uploaded by

kawyua

Virus scan

Safe to use

10 comments

  1. Marcsward
    Marcsward
    • supporter
    • 5 kudos
    The description of the mod is a bit too vague. Even the suppression explanation is opaque.
    1. kawyua
      kawyua
      • member
      • 0 kudos
      Hi Marcsward this was really just meant to be a reddit post over here:
      https://www.reddit.com/r/Xcom/comments/4xltc4/xcomew_long_war_small_hex_edits/

      yeah its a mess here. A lot of these are "fixes" to the oddities with the ai and hard to say everything it affects.

      I made a video of the suppression fix anyways,
      VIDEO1: WITH this mod. https://drive.google.com/open?id=0B93kc9CaEJz1T3pUWjNLUU4zbUk Good job sectoid on killing my soldier.

      VIDEO2: WITHOUT this mod https://drive.google.com/open?id=0B93kc9CaEJz1ZXU5MXJRNl85VWM they always shoot the suppressor despite others being flanked and in the open

      Couldn't link a google drive video on this file

      The other suppression parts are all just deleting references the ai makes explicitly for whenever they are suppressed. I don't know what these exactly affect, but it should stop any limitation placed on the aliens for being suppressed.
      - sorry for the little clarity in regards to this part, but it should be helpful to the ai, nor should it break anything, so I put it on here anyways

      I don't see explicit references to suppression in the ai as vaguely as they put in the functions to be any good. I have observed the perform better moves when defaulting to an ai without these references to suppression.

      I do need a lot more proof, and videos to exemplify the changes, but its quite hard
    2. xxxSYNNxxxx
      xxxSYNNxxxx
      • member
      • 0 kudos
      is valid enemy targets txt just so enemy are more likely to target someone alrdy supressed to finish them off, or only soldiers at low hp? thx
  2. kdm2k6
    kdm2k6
    • member
    • 0 kudos
    Very interesting mod. Do you think it might be possible to create a simple function which looks at the suppressed enemies hit-points and compares it to the suppressors damage potential (and determines if it will ignore suppression based on this, utilizing some kind of simple function)?

    I might look into this myself - although hex editing looks like a nightmare at the beginning.

    Thanks

    1. kawyua
      kawyua
      • member
      • 0 kudos
      mmm what you are saying is stiill hard, there is a reason why long war didn't mess with any of the ai functions:
      getting the damage potential has many many variables involved and stuff like hitpoints is pretty situational, that it probably is a lot work than it is worth. There's also a ton of other variables to consider that makes this not a clear cut improvement.

      What I wrote is just disabling a function that is already there, so ... I still need to read more of the tutorial on how to hex edit more than just a single value! But, from I understand at looking the code, it won't be a simple single function. The references to suppression are numerous and has multiple hard coded spots to just suppress that - you might have to search a lot to insert your function into all these cases.

      At least this is my interpretation of what I've seen from the code

      And its not that bad looking at the code through the Unreal engine editor thing, the way everything is laid out is pretty simple, its just a lot of variables that are hard to tell what it is referencing and hard coded or seemingly redundant stuff that can make you go ???

      I should come back and look at the code once i'm in my break, I'm sure there are things to try out

    2. kdm2k6
      kdm2k6
      • member
      • 0 kudos
      Thanks for the response. After more thought, the main thing I am interested in is having Cyberdiscs act a little more randomly when suppressed (they love to sit there and overwatch). I had a look at UEExplorer (with the help of your files - to determine what to look for), but couldn't determine exactly where the problem lies. I noticed changing the idealAttackRange (can't remember the exact name of the variable/function) of the Cyberdisc manipulates which state it will go in - do you know if this change alone will cause the Cyberdisc to choose to move sometimes? Basically I would like it (the Cyberdisc) to look at the whetherIShouldMove type variables - so it doesn't run into 5 overwatches - , but not have suppression be an absolute stopping factor.
    3. kawyua
      kawyua
      • member
      • 0 kudos
      hmmm the cyberdisc "reasonable attack range" fix to visual range just makes it so cyberdiscs consider attacks at a farther distance(I explained to Ucross below).
      But that's pretty much it. At least cyberdiscs won't be overwatching so much since they'll just start shooting on sight

      The moving thing is a lot more complicated.

      I don't think its connected so much with the cyberdisc - its an entirely seperate function that every single alien use. I don't remember the cyberdisc having a special case concerning movement.

      And in a couple of these "ShouldAvoidMovement" functions (you might have muck around to see that its quite the... interconnected web) that there is some like "overwatch danger zone" functions that somehow only counts if there is 2 or more...

      That's not quite the end of it though.

      Special actions like suppression and overwatch causes special cases that causes the aliens to do totally different things. Which is then referenced to other functions that I just kind of stopped.

      To sum it up, most of the time they use a point metric for deciding actions like that, but some special things can override this with some weird hardcoded stuff. For a visual, remember how in terror missions, the aliens like to attack the civilians seemingly above all else - its one of those cases. Now kind of imagine that cooky way of operating to make the aliens devolve with other special scenarios, like suppression.

      I believe its one of these that makes ai ignore overwatches and stuff

      Sometimes though the aliens are actually quite clever in positioning to come into vision without activating the overwatches, its one of the smart ai functions that's available to them. But then sometimes they just don't use it which makes me abit sad

      The last thing you said about making aliens stop not moving when in suppression is something I've been trying to do in the experimental files of this mod. Like I said before, references to suppression is everywhere. I'm pretty sure many of these are supposed to be an inhibitor, so that if an alien is suppressed, they disable an "action" (like firing, moving, doing special moves) as a possibility. And since its everywhere, its tedious to tell what are the effects of any specific change
      -Honestly I've kind of given up on this idea - way to many repercussions in touching what I don't know.

      I'm been playing a campaign of my own to see if I did it with the files I created, but I still can't tell if what I'm seeing is working. I really can't make a distinction from the original ai anymore, its hard to tell what to look for. The only obvious change I have is that suppressed aliens are able to shoot people other than the suppressor

      Sometimes I feel like there is a hidden dice function in the code that decides how they work.

      I commend you for having gotten this far to look through the code, anyways!
    4. kdm2k6
      kdm2k6
      • member
      • 0 kudos
      Thanks again for the response. I might take another look through the code in the not to distant future and let you know if I find anything. I looked through the Xcom 2 files a while back and it's similar in terms of code all over the place (oftentimes not commented very much) which makes it quite challenging to figure out what exactly is going on.

  3. Ucross
    Ucross
    • premium
    • 53 kudos
    Can you elaborate further on what effect the cyber disc and drone changes have?

    Did cyberdiscs never fire from full range?Will they always now?What about drones?
    1. kawyua
      kawyua
      • member
      • 0 kudos
      Sorry for the vague description, I'm not quite sure how to phrase it

      They don't fire past the "reasonable attack range" of 12 for cyberdisc and 16 for drone. When out of that "reasonable attack range" they will overwatch or move closer instead(in most cases). The actual attack range of the disc and drone is still 27.

      The mod changes the number to reasonable attack range to 27 (visual range). So if the drone or cyberdiscs has any good attacks up to 27 tiles away, they will shoot.

      The ai doesn't know what to do when they are farther than the reasonable attack range sometimes, like drones doing nothing or cyberdiscs constantly overwatching These are the only two aliens with this special "reasonable attack range" that is lower than their visual range.