OpenXcom Forum
Modding => Work In Progress => Topic started by: The Reaver of Darkness on July 15, 2017, 05:47:57 am
-
Currently, if a Chryssalid makes an attack against one of your soldiers, it deals damage based on the Chryssalid's strength. If the soldier is killed, a zombie spawns in its place. The Chryssalid may then cease the attack and go for a different soldier. But if the Chryssalid runs out of time units and still has not depleted the soldier's hit points, it will stop attacking and the soldier is killed anyway.
This can be tested with a soldier that has 250 armor, as the Chryssalid will be unable to cause any damage to the soldier. If you set the Chryssalid's attack to 1 TU cost, it will make a very large number of attacks, completely draining its remaining TUs to attack because it consistently fails. However at the end of its turn, the soldier is turned into a zombie anyway.
How do I turn off this function, so that the Chryssalid is required to actually kill the soldier in order to turn them into a zombie?
-
reduce their melee accuracy, they impregnate if they hit, damage is merely a side effect.
-
reduce their melee accuracy, they impregnate if they hit, damage is merely a side effect.
I thought it only works if the Chryssalid does damage? (Meaning no zombification it the armour has stopped the attack completely.) Or am I just plain wrong?
-
My impression as well. I know this attack over attack behavior. But at the end, if the armor was thick enough, nothing happens. So AFAIK, it's not guaranteed for Chryssalids to succeed.
-
see for yourself, in this function:
https://github.com/SupSuper/OpenXcom/blob/master/src/Battlescape/MeleeAttackBState.cpp#L215-L275
line 220: determine if the attack hits
line 239: impregnation
line 244: begin calculating damage
line 271: inflict damage
-
They definitely always succeed, regardless of whether or not they deal any damage. They are just willing to use up extra time units if they haven't killed the soldier yet.
reduce their melee accuracy, they impregnate if they hit, damage is merely a side effect.
That doesn't work for me. I want armor to make a difference against chryssalids. Currently, all it does is possibly cost them more time units before they inevitably succeed in the attack. If I lower their melee accuracy, they'll be less potent against unarmored soldiers as well.
-
this is why they have their reputation
-
OXCE can reduce chance to success of special attack.
-
Thanks for the explanation, Warboy.
...but isn't it kinda stupid? How do they insert the larva (or whatever) through the armour? :P
-
this is why they have their reputation
I don't think that's true. If their attack could be stopped by armor, they would still very easily take your troops down until at least the time when you get power suits, and even then they could still rip through your armor. Sometimes they would fail but their damage is high enough to succeed in one hit using UFO damage model, no matter how tough your soldier is. Their time units are so high they would still catch players unaware if they didn't take precautions to prevent chryssalids from ambushing them. Failure wouldn't be the norm, rather it would just be a thing that happened sometimes. One wouldn't find themselves truly dominating chryssalids until they really learned to prevent them having a chance to attack soldiers in the first place.
...but isn't it kinda stupid? How do they insert the larva (or whatever) through the armour? :P
They probably have an ovipositor that is capable of ripping through your strongest armor. But when the hit glances off or fails to break the armor, the eggs should fail to get in.
-
no, it's true, they got a reputation for being incredibly deadly by... being incredibly deadly.
i'd just like to point out this is a video game, it doesn't have to make sense. it doesn't impregnate your soldiers using real world biology or physics, it impregnates your soldiers by means of "the GM says so"
-
My point is that the change I'm asking for wouldn't significantly affect how deadly they are, especially in the early game when you first meet up with them.
I'm not trying to get realism. I'm trying to get gameplay. Researching armor and paying time, money, and resources to make it in order to have it better protect your soldiers is gameplay. Having an enemy ignore that armor with no explanation other than "this is a scary enemy" is not gameplay, it's fake difficulty. I can balance the attributes of the armor and chryssalid however I want after I get the feature to make it as easy or hard as I like, but not having that option takes away my power as a designer to deliver the game experience I want to give people.
-
fair enough, i was simply explaining why it is the way it is.
currently it's not possible to do what you're describing. if you're using OXCE+ i'd say your best bet would be to pester Meridian to add an armour resistance value specifically for impregnation and work off that.
(as an aside: xcom is full of fake difficulty, it's kinda notorious for it, even)
-
(as an aside: xcom is full of fake difficulty, it's kinda notorious for it, even)
Very true, one of my biggest reasons for wanting to mod it.
-
Yeah, I guess I will pester someone to modify this code of the zombification to only work if some damage was dealt...
The present "touch and you're dead" mechanics would be fine in a more abstract system, say in Space Hulk or Templar Batttleforce. But X-Com is more complex and more simulationist than that; such an abstract rule just looks like bad (or should I say lazy) design, not matching the rest.
-
Actually this is only true for melee attacks.
If you use a ranged zombification attack, it actually only converts if you actually hit.
-
Actually this is only true for melee attacks.
If you use a ranged zombification attack, it actually only converts if you actually hit.
So what's different...? In melee, the Chryssalid also has to hit.
-
Yeah, I guess I will pester someone to modify this code of the zombification to only work if some damage was dealt...
The present "touch and you're dead" mechanics would be fine in a more abstract system, say in Space Hulk or Templar Batttleforce. But X-Com is more complex and more simulationist than that; such an abstract rule just looks like bad (or should I say lazy) design, not matching the rest.
doable, even more, I will probably do it today.
-
doable, even more, I will probably do it today.
Great! Another improvement! :)
-
I foresee a possible problem if you try to implement zombification on death only: if the soldier falls unconscious they would fail to become a zombie even if the Chryssalid had time units remaining to continue attacking.
Possible solutions:
1.) zombification on neutralization
2.) prevent unconscious state from attack
3.) zombification if any damage has been dealt
4.) chance-based zombification based on what percentage of the soldier's health was lost to the combined attacks
5.) chance-based zombification based on what percentage of the soldier's health remains at the end of the attacks
-
I foresee a possible problem if you try to implement zombification on death only
Nobody ever has suggested this.
-
This is be done (in OXCE 4.0) by scripts, you get percentage chance to transform and you can reduce or increase it.
This mean that if you want it only work on killing hit then you check for current damage to health is greater than current health and you leave it unchanged otherwise you set to 0 disabling it. You can made this proportional to damage done (scratch is safe :)).
-
Actually this is only true for melee attacks.
If you use a ranged zombification attack, it actually only converts if you actually hit.
meaning it's identical for both.
-
This is be done (in OXCE 4.0) by scripts, you get percentage chance to transform and you can reduce or increase it.
This mean that if you want it only work on killing hit then you check for current damage to health is greater than current health and you leave it unchanged otherwise you set to 0 disabling it. You can made this proportional to damage done (scratch is safe :)).
Thanks!
I've never used OXCE before but I'm going to try it for the first time. Maybe I am ready now!
Nobody ever has suggested this.
I suggested it in the first post.
-
Let them be totally evel and succeed in their hits.
Once you get flight suits you will become THEIR horror as
you hover out of range and blast them with pistols
-
In my mod, power suits have more armor than flying suits, and power suits give more strength while flying suits give more firing accuracy. I like giving the player choices, and letting armor defend against chryssalids is part of that choice. Of course, flying suits can make you immune to chryssalids, but there are other considerations, such as killing the chryssalids before they get to civilians, or dealing with all of the snakemen. Because of that, I like power suits to offer protection from chryssalids as well, so that there's still a choice in armor rather than one obvious best option for all cases.
-
I like power suits to offer protection from chryssalids as well, so that there's still a choice in armor rather than one obvious best option for all cases.
In some other forums or threads some did complain about the flying suits giving that advantage over the chryssis:
Its always nice to have choices, maybe I myself would not mod the chryssis, no, but to have another creature to do a similar effect but be limited by armor could be nice to have.
In some ways it's like my experiment spawning civilians from dead civilians that automatically turned hostile, which is undesirable for what I had in mind. Maybe the civilian spawn as described is a bad idea, however, the effect to have an allied tank crew spawn from a blown up vehicle would be useful, that is if the game could spawn units that way that did not spawn hostile.
The demo that was released around the time the game came out, I must have played it about 18 times, could not beat it once, came close , but always a CHRYSSALID inconveniently appeared, zombified someone and the game went south from there.
-
This is be done (in OXCE 4.0) by scripts, you get percentage chance to transform and you can reduce or increase it.
This mean that if you want it only work on killing hit then you check for current damage to health is greater than current health and you leave it unchanged otherwise you set to 0 disabling it. You can made this proportional to damage done (scratch is safe :)).
Can someone explain how to use this feature? I'm lost here.
-
Can someone explain how to use this feature? I'm lost here.
Yankes or Ohartenstein can write a script for you if you tell them how exactly should it work.
For the rest of us, it's black magic.
-
OXCE 4.0 isn't out yet, so I can't do any black magic for you.
-
Yankes or Ohartenstein can write a script for you
Oh, I thought it was already done.
Simple: the chance of success is checked per attack, and is identical to the soldier's %remaining health. So it's possible for the attack to do no damage and turn them into a zombie, if they had already taken damage before. Probably they have a hole in their armor now...
I guess I'll hop back on the hype train then.
-
I also noticed in stats for nerds, armor has an attribute: Can be Zombified: true. How do I set this false for an armor?
-
zombiImmune: true
-
I also noticed in stats for nerds, armor has an attribute: Can be Zombified: true. How do I set this false for an armor?
If you click on DEBUG button, you get the ruleset names of the attributes, in this case:
zombiImmune: true
-
Oh, I thought it was already done.
Simple: the chance of success is checked per attack, and is identical to the soldier's %remaining health. So it's possible for the attack to do no damage and turn them into a zombie, if they had already taken damage before. Probably they have a hole in their armor now...
I guess I'll hop back on the hype train then.
Is done in my code but not released. For functionality itself. You get number in range `1` to `100` then you can get value of attack (another number) and some stats of attacker and victim. With all this values you can do any basic arithmetic operations (like `+`, `-`, `/`, `*`, `%`) to get result in range of `0` to `100` and this number will be used by game engine to determine if this victim will change to zombi or not (`0` -> no zombi, `100` -> always zombi).
-
Oh? I just shoot rookies and civilians when I know chryssalids are near.
-
I don't really understand what these calculations are for, but I can confirm in armor with "zombiImmune: true" soldiers never become zombies. In the armor without this parameter, from turning into a zombie saves a "melee Dodge:" when Chryssalid stupidly misses the target. However if he not misses, the trouble can not be avoided, but it's as lucky. In General, the instruments to combat Chryssalid and Tentaculat full.
-
Pasting a sample script here, just in case people are still interested.
extended:
scripts:
damageUnit:
# Global fix to Transformation attacks like Chryssalid zombification
# Requires at least 1 hit point of damage before zombification triggers
# This applies to *every* weapon that zombifies. It *has* to get through armor to work.
- offset: 4
code: |
if gt to_transform 0;
if eq to_health 0;
set to_transform 0;
end;
end;
return;
-
Pasting a sample script here, just in case people are still interested.
I'm weak in scripts ... If set "if eq to_health 10" in this script, then the damage for transformation will have to be more than 10 points?
-
I'm weak in scripts ... If set "if eq to_health 10" in this script, then the damage for transformation will have to be more than 10 points?
eq stands for "equal"
you can use gt which stands for "greater than" and lt which stands for "less than"
so "if lt to_health 11" is what you're looking for... meaning "if to_health is less than 11, don't transform"
-
Meridian, does it work at you? Maybe not compatible with the vampirism script?
-
Pasting a sample script here, just in case people are still interested.
extended:
scripts:
damageUnit:
# Global fix to Transformation attacks like Chryssalid zombification
# Requires at least 1 hit point of damage before zombification triggers
# This applies to *every* weapon that zombifies. It *has* to get through armor to work.
- offset: 4
code: |
if gt to_transform 0;
if eq to_health 0;
set to_transform 0;
end;
end;
return;
I wanted this, thanks!
-
Meridian, does it work at you? Maybe not compatible with the vampirism script?
I just copied it from piratez, I didn't test it... I'll test it later.
-
I just copied it from piratez, I didn't test it... I'll test it later.
Oh, exactly! Found! I have a file with scripts from there. Thanks, figured it out.