Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Kzer-Za

Pages: 1 2 [3] 4 5 ... 10
31
Released Mods / Re: Wounds proportional to damage [OXCE]
« on: August 28, 2019, 03:41:54 pm »

Yeah, ammo. :v


I attached the new version and updated the description.

32
Released Mods / Re: Accuracy penalty when flying [OXCE]
« on: August 28, 2019, 11:23:36 am »
I uploaded a new version with the required feature. See the updated description. You need the "Plus" version, and give the armor you need to be affected by the penalty a tag ACC_PENALTY equal to 1 (well, not 0) in your mod. Vanilla flying suit is already specified in my mod itself.

33
OXCE Support Y-scripts / Re: Scripting basics
« on: August 28, 2019, 10:51:35 am »
Oh, it does. I probably tried using "getArmor" before. Thanks!

34
Released Mods / Re: Accuracy penalty when flying [OXCE]
« on: August 27, 2019, 09:21:32 pm »
Actually, I just thought that it may not be necessary to check for which armor is used. If the unit is not supposed to be flying without the armor, then, if it is flying (and the script checks exactly for that: if it is flying), it can be safely assumed that it is due to armor. Unless there will be different kinds of flying armors, some of which will have stabilizers or some kind of autopilot, in which case they wouldn't have this penalty. But unless there are such armors, per unit basis will be enough.

35
OXCE Support Y-scripts / Re: Scripting basics
« on: August 27, 2019, 09:08:58 pm »
Sorry to bother you again, but is there a way to get RuleArmor from BattleUnit? I'm interested in getting the unit's armor from "accuracyMultiplierBonusStats" hook, it is needed for this: https://openxcom.org/forum/index.php/topic,7326.msg116055.html#msg116055

36
Released Mods / Re: Accuracy penalty when flying [OXCE]
« on: August 27, 2019, 09:01:45 pm »
On a per unit basis, definitely doable; on a per armor basis, I'm doubtful. I don't see a way to get RuleArmor from BattleUnit, but I'll ask Yankes.

37
Released Mods / Re: Recovery time revamped [OXCE]
« on: August 27, 2019, 05:26:08 pm »
For fun :) I just like tweaking such things.

38
Released Mods / Recovery time revamped [OXCE]
« on: August 27, 2019, 04:48:31 pm »
This mod addresses in several ways the time that your wounded soldiers take to heal up.

TL;DR:
1. Recovery time depends on the total amount of health the soldier lost.
2. Percentage of the max health plays a role.
3. No random involved.
4. Shorter average recovery times.

Details:

1. In vanilla the recovery time depends on the health the soldier has in the end of the mission. This makes you pospone ending the mission if you have wounded soldiers and if it's safe for you to postpone ending it until you heal them with medi-kits, because the difference in recovery time will be great. And if the mission ends (due to reaction fire from one of your soldiers, for example) before you have the chance to heal the wounded soldier, it makes you grit your teeth. I think it's excessive micromanagement, which just adds routine, uninteresting actions. Besides, the commander with a wounded soldier would want to finish the battle more quickly, not to prolong it.

Making the recovery time dependent on the total amount of health the soldier lost during the battle takes care of that: if you heal a soldier, it's not gonna reduce the recovery time. Thus, you have no reason not to end the battle when you can. At the same time, the need to heal your soldiers during the battle is not any less: you still don't want them to have low HP, and also the HP they lose when they bleed are also added to the total amount of HP lost. So you still can't neglect your soldiers, but you are not stimulated artificially to prolong the battle until everyone is treated.

2. A soldier with max health 60 is gonna recover from losing 30 HP faster than a soldier with max health 40. The exact values in percent are: less than 20% (20% – 1 HP) lost is healed instantly. Recovery from losing between 20% and (70% – 1 HP) takes 1 day per 5 HP. Recovery from losing between 70% and (100% – 1 HP) adds 1 day per 3 HP. If you lose 100% or more (it's possible if you healed up a wounded soldier for a significant amount of HP and then he was damaged again but not killed), 2 days are added for every HP.

These intervals are additive. Say, your soldier has 50 max health, he first was damaged for 35 HP (15 HP left) and had 7 wounds. You healed all wounds and thus restored 21 HP (his health is 36 HP). Then he is damaged for 25 HP. He still has 11 HP left, so he stay alive, but the total damage taken is 35 + 25 = 60 HP, which is more than 100%. At this moment you kill the last alien and go home. Let's calculate the recovery time.

Less than 20% does not take any time to recover, so his first 9 HP (20% of 50 is 10, and 9 is the first figure less than 10) lost are not taken into account (if he lost only 9 HP, he would be ready for action immediately). Then we add 1 day for every 5 HP lost in the interval 20–70%: (35 – 10) / 5. Then we add 1 day for every 3 HP lost in the interval 70–100%: (50 – 35) / 3. Then, for each HP gone below 100% (plus 100%-th HP per se, since losing this last HP is what actually would have killed the soldier if he weren't healed) we add 2 days: ((60 – 50) + 1) * 2. This makes 5 + 5 + 22 = 32.

3. Any two soldiers with the same max health that have taken the same damage are gonna recover in the same time.

4. Vanilla recovery times always seemed absurdly high to me. This may be "realistic", but I always say that gameplay > realism. If a soldier recovery time approaches 2 months, it is simpler to fire him and hire another one. Notice that with my formula the numbers sharply go up only after taking "deadly wounds", i.e. losing more than 100% health. Until a soldier has taken deadly wounds (which, while possible, is rather unlikely: he is more likely to die), he is gonna recover much more quickly, even considering that in vanilla you can reduce the recovery time by healing him in combat, while with my approach healing, while useful during combat, has no effect on recovery time (other than by preventing loss of HP to bleeding).

39
Released Mods / Accuracy penalty when flying [OXCE]
« on: August 27, 2019, 04:37:13 pm »
This little mod introduces a 20% penalty to firing and 10% to throwing accuracy of some units when they are flying. The rationale is that they don't have a proper foothold, and these flying suits are bound to have some bobbing. Also, the recoil is gonna affect flying units to a greater extent than standing on something firm.

That was the "realism" reason for the mod. The gameplay reason was that I wanted to nerf the flying suit somewhat. It already makes your life a lot easier, putting you out of reach of Chryssalids.

This mod has two versions: "Flying accuracy penalty" per se and "Flying accuracy penalty Plus".

The first one affects only X-COM soldiers, but not any other units: massive hovertanks and cyberdisks are not gonna be affected by this, and neither are "natively" flying aliens, since they would have some adaptations in their motor coordination because flying is their natural means of locomotion. Also, this version should work with all flying armors, vanilla or added by mods (without the need for these mods' authors to provide compatibility), since it checks whether a soldier is flying at the moment, and if yes, it applies the penalty.

The second one can be made to interact with other mods to affect also enemies. The drawback is that by default it affects only vanilla flying suit. If you have a flying armor from some mod, it is not gonna be affected by this penalty, unless its author knew of this mod and included the needed tag in his armor rule (or unless you do it yourself). The upside is that mod authors can apply the penalty to enemy units as well as X-COM soldiers, since the check is made on a per armor basis. (See readme.txt).

Do not install both versions alongside each other!

One warning: with both versions the chance of success of psi attacks is handled by the engine as accuracy. So this mod also decreases the chance of success of psi attacks. At first I thought of inserting a condition that would exclude psi attacks from this decrease. But then I thought that mental attacks are gonna take a lot of concentration, and it's gonna be hard to concentrate on such things when you are dangling several meters above the ground supported by something like a jetpack. So the penalty for psi attacks stays :)

Many thanks to Yankes and Meridian for explanations of the script engine and correction of my mistakes!

---
Upd. Attached a new archive. It contains the "Plus" version of the mod in addition to the original.

40
Released Mods / Re: UFOpaedia-friendly Celatid [UNIT] [OXCE]
« on: August 27, 2019, 04:24:32 pm »
Yes, changing it to 3 did work!

Updated the attached file.

41
That's good to hear, I'll be waiting for it :)

42
Hmm, I have thought of another mechanic for overheating: store overheating level in a tag, increase it with each shot, have several levels of overheating, and for exceeding each of them add TUs required for shots. However, I don't see a hook that could be triggered at making a shot. There really does not seem to be a way of limiting the lasers' firing capacity other than giving them ordinary clips, which is dull.

43
OXCE Support Y-scripts / Re: Scripting basics
« on: August 26, 2019, 02:59:25 pm »
I just found that damageUnit is not triggered when a soldier loses health due to bleeding. So if I want to get the amount of health that he/she loses due to bleeding, I guess, I have to use "newTurnUnit" and "unit.getFatalwoundsTotal", and no shorter way for it?

44
OXCE Support Y-scripts / Re: Scripting basics
« on: August 26, 2019, 12:26:23 pm »
Aaah, the type of rule in "extended" that has this tag! Not BattleUnit but RuleSoldier. Thanks!

45
The first suggestion is, unfortunately, impossible. The second looks interesting, but I'm not sure if it is possible. There are such parameters as costAimed/costSnap/costAuto, but it seems that the cost parameters can be only characteristics of the unit holding the weapon. Just in case it worked, I tried using

Code: [Select]
    costAimed:
      ammo: 2

but to no avail. Could anyone tell if it is possible to specify spending more than 1 ammo per shot, and if yes, then how?

Pages: 1 2 [3] 4 5 ... 10