Jump to content

SteelShrike

Members
  • Posts

    6
  • Joined

  • Last visited

Nexus Mods Profile

About SteelShrike

SteelShrike's Achievements

Newbie

Newbie (1/14)

  • First Post
  • Week One Done
  • One Month Later
  • One Year In

Recent Badges

0

Reputation

  1. Okay, so. I managed to sorta stumble into the scenario described above, unmodded. I was in the mission where you have to escort Thorne, the rogue politician, to the Skyranger. One of my soldiers got critically wounded early on. If you stabilize the squad member and Thorne makes it to the Skyranger, and you kill all the rest of the aliens, the soldier can be recovered. If Thorne dies, and you stabilize the soldier, you're given the chance to reach the extraction point (the mission doesn't end with Thorne's death.) The squad member, even though stabilized, is left behind. If Thorne dies, and you stabilize the soldier, but clear the map, the soldier survives. If Thorne survives, and you stabilize the soldier, but abort the mission without killing the rest of the aliens, the soldier is left behind. I wasn't able to test without stabilizing the soldier, because I didn't have enough turns to finish the mission. But going off these results, my assumption is that the results will be the same. The most interesting is the third result, which proves that, while the original code checks if the mission is a failure AND if the soldier is critically wounded, that the soldier dies. Yet the mission was a failure, and the soldier survived. Stabilizing him may be the difference here. I saved the mission so maybe I'll go back and see if I can get another soldier critically wounded near the end and test to see if not stabilizing him makes a difference.
  2. I wonder, too, if stabilizing a soldier means that he's no longer critically wounded, which would make setting up the exact scenario in which to test the behavior even that much harder to reproduce. You'd essentially only have 3 turns after a soldier goes down to clear the map of aliens then. Looks like I'm going to have to start a pre-modded XCOM campaign afterall and see if I can set up just such a scenario. :D
  3. Nevermind! I'm an idiot. It's been so long since I've played through a whole game of XCOM, I forgot how terror and council missions worked. You're right, that'd be bad. Right now, I'm wondering if we can somehow maybe repurpose the different mission result returns. Such as that: 1 = Victory 2 = Defeat or Abandoned 3 and 4 would be special conditionals that apply to the Terror/Council missions. Thus, in my code, instead of if(m_iResult != 1), we could check if(m_iResult = 2). And then, so long as losing all civilians or losing the VIP returned a 3 or 4 perhaps, everything would work. I'll have to look more closely into how m_iResult is assigned and used now. Thanks for the direction and letting me bounce ideas off you! EDIT: Still, I'm confused. The original code states: if((m_iResult != 1) && kSoldier.IsCriticallyWounded()) { iHP = 0; kTransferSoldier.CauseOfDeathString = XComGameReplicationInfo(class'Engine'.static.GetCurrentWorldInfo().GRI).m_kGameCore.UnknownCauseOfDeathString; } So if that's the case... shouldn't soldiers who are bleeding out in a Terror Mission when all civilians are dead be lost anyways? Not saying that's a good thing, but, if that isn't the current behavior, then we're missing something that's already preventing them from dying. Are we sure that clearing the map of aliens in a Terror Mission after all civilians are dead doesn't produce a m_iResult of 1 regardless?
  4. Right, right, I get what you're saying. My point is, I think that'd actually be acceptable. And it may even happen already. I'll have to test, but I think in this situations, the game assumes that the area is overrun and XCOM retreats, leaving wounded soldiers behind.
  5. Oof. I totally didn't think about that. But wait... the code already checks if m_iResult != 1 and if the soldier is criticially wounded, then kill him off. So if that's the case, shouldn't the game be killing off critically wounded soldiers under those conditions already? The only difference is my code would also mark him as MIA and thus delete his gear, too. Well, besides the obvious fact that I'm throwing dead soldiers and the check for Left Behind in there, too. And actually... those conditions -might- make sense for losing a critically wounded soldier, too. And like I said, it may even already happen. For losing the VIP, I think the assumption is that the area is overrun and XCOM has to flee and leave everything behind. Same with all civilians lost in a terror mission. XCOM isn't going to stick around to reclaim the bodies and put themselves in any further danger if the mission is a bust (apparently they're not marines with "No man left behind" mentality"). Now, if the mission could somehow continue after a defeat and not end until you aborted the mission, AND you could pick up critically wounded soldiers and drag them back to the Skyranger, that'd be ideal. Sadly, though, I don't think that's going to happen.
  6. So, with Enemy Within released, I've decided to take up modding myself as well. One of my favorite changes was this modlet here. Unfortunately, with Enemy Within... the behavior of Enemy Unknown hasn't changed in that equipment is still recovered from a squad that has wiped. So, after going through the files, attempting to figure out how soldiers are tagged as LeftBehind, I came up with this idea. Essentially, when aborting a mission, any squad member outside of the extraction zone is marked as Left Behind according to the ExitLevel function in XGUnit. Then, in BuildReturningDropshipSoldier in XGBattle_SP, left behind soldiers are officially marked as "bLeftBehind," which the Barracks then destroys that squad member's equipment. Here's my idea. Rather than rewriting the entire IsDefeat function like Amineri did originally, how about we rewrite a section of BuildReturningDropshipSoldier to mark anyone critically wounded or dead to be marked as left behind as well? Essentially, the code would go from this: if((m_iResult != 1) && kSoldier.IsCriticallyWounded()) { iHP = 0; kTransferSoldier.CauseOfDeathString = XComGameReplicationInfo(class'Engine'.static.GetCurrentWorldInfo().GRI).m_kGameCore.UnknownCauseOfDeathString; } // End:0x344 if(kSoldier.m_bLeftBehind) { iHP = 0; kTransferSoldier.bLeftBehind = true; kTransferSoldier.CauseOfDeathString = XComGameReplicationInfo(class'Engine'.static.GetCurrentWorldInfo().GRI).m_kGameCore.UnknownCauseOfDeathString; } To this: if((m_iResult != 1) && (kSoldier.IsCriticallyWounded() || kSoldier.IsDeadOrDying() || kSoldier.m_bLeftBehind())) { iHP = 0; kTransferSoldier.bLeftBehind = true; kTransferSoldier.CauseOfDeathString = XComGameReplicationInfo(class'Engine'.static.GetCurrentWorldInfo().GRI).m_kGameCore.UnknownCauseOfDeathString; } Now, my knowledge of Unreal Script isn't superb, so I don't know if such a complex 'if' condition is valid. But presumably, this would check that the mission has not succeeded, and then check if the soldier is bleeding out, dead, or simply left behind from an aborted mission, and tag all the above as being bLeftBehind. If that actually works, it should also prevent the need to have such a complex rewrite of the IsDefeat function, too. Hopefully Amineri will see this and doublecheck my idea to see if I'm not totally crazy.
×
×
  • Create New...