Home » MODDING HQ 1.13 » Flugente's Magika Workshop » New Feature: Disease
Re: New Feature: Disease[message #358369 is a reply to message #358359]
|
Fri, 25 October 2019 21:28
|
|
Kitty |
|
Messages:473
Registered:October 2017 Location: Germany |
|
|
Flugente wrote on Fri, 25 October 2019 00:22As to the abovementioned sex (with a chance of STDs) thing, it is triggered by ACTION_ITEM_SEX in PerformItemAction in the script ExplosionControl.lua (yes, sex is initiated in a script originally intended for explosions. Where else? ). That part is ultimately called by the activation of an action item (#item 234) with the action ACTIONITEM_TOGGLE_DOOR (14, see the location of the aforementioned ACTION_ITEM_SEX ) set on the entrance tile of the hooker's room. As a result the sex is only initiated if you enter the room via the door.
I recall that this caused a problem when a random civilian wandered into the brothel at some point, because not properly initialized sex can crash the game.
However, worse is that the sex only works properly if the tiles of the action items are as expected in ModSettings.ini (see DOOR_TO_BAMBIS_ROOM etc.), otherwise proper sex won't happen. More than the three canonical hookers are not intended (amusingly though, the rooms are thus set, the hookers themselves aren't. The game considers any miniskirt-wearing woman a hooker.).
If you were to move the room to Brenda's house... hmm. That would work, but as Brenda would enter the room first... I guess she'd just try to fuck herself and close the door in front of you.
Hmm. As having the svn revision message Externalised whores sounds like the kind of thing I'd like to be remembered for, maybe I can tweak this.
What I did for Brenda-having-sex is:
Using the NPC-action #122 "NPC has Sex" in her npc-script. After the porn-shop sequence is finished and she is at home (Brenda at home) when a female is speaking to her (female speaking) and a certain item is given to her (I added another video-tape, named after one of those she mentioned to Hans) she moves to a tile (seemingly a certain tile is nescessary for this) in her bedroom and says a phrase hinting to follow her (took existing words/lines and tried to edit some useful stuff with audacity). When female player speaking friendly to her after she arrived at the tile the conditions for #122 (NPC has sex) are set fullfilled in the npc-record and the smiley is popping up.
So far everything went as planned, but then I saw that there is no morale-boost for sex and no chlamydia-infection happening.
If i understand your answer correct, for triggering sexual transmitted diseases the action-item is nescessary and since I used npc-script instead of the said action-item it won't trigger diseases. That's kinda sad, but at least I now know why it didn't happen, thanks.
The whole idea is inspired by/stolen from the character Svetja in Renegade Republic by Scorpion in whose npc-scripts I looked after I gave her a certain item. I found this way cool and thought about using this for Brenda to have an oportunity to make Madames words about her true. Whenever I think I might by ready for uploading stuff, I first have to ask Scorpion if he is ok with this.
As for the brothel: if the same roomnumbers are used, all rooms are connected and the grid-no for the girls doors are the same and action-items placed correctly behind doors it is possible to have another brothel in a different sector (plus san mona, not instead). I added another brothel in AR-city Estoni (bordertwon close to miltary town, there realy should be a brothel) and it seems to be working. I cloned and renamed Madame and Bill for testing, but if I realy end up using this I rather should do new voice-recordings, but it was allready difficult to find someone for other characters I had in mind (w.i.p. so far). In my test-runs, morale and disease worked this way.
If you ever find time/interest for "Externalized Whores" I'd be happy to try it out, for the sake of this name alone
[Updated on: Fri, 25 October 2019 21:32]
How to get: latest 1.13, 7609 and more | 7609 SCI (eng) | Compiling+SVN
I need more details. (Didi Hallervorden) Report message to a moderator
|
|
|
|
Re: New Feature: Disease[message #359627 is a reply to message #334916]
|
Sat, 18 April 2020 17:12
|
|
3-Spades |
|
Messages:9
Registered:April 2020 |
|
|
Hey guys,
Rookie here new to the forums. I have a few questions hoping I won't annoy anybody as I am new to JA2 and 1.13.
I have done a playthrough of 1.13, but on the very latest release 8776, which to my understanding is not the stable release. Was a fun playthrough for a first timer.
I then found out 7609 was the stable version and there was something called Arulco Revisted which sounded very nice. So I did a uninstall and then a clean installation ofboth 1.13 (from the 7609 modpack) which includes Arulco Revisted (1.4).
Now when I played 8776, all of Flugente's new developments were able for me to tweak via the JAoptions.ini. But I was wondering whether I could activate your new mods on a version that allows me to play Arulco Revisted? Does the new unstable versions (say 8776) allow me to play this AR mod? Or can I upgrade my current version (7609) to something higher but not so recent so that it still works with AR?
Ya dig what I'm sayin boys?
Edit - So yes, after posting this message I decided to try it out for myself. So I reapplied the 8776 installation I previously had and found that I could urn AR. There were a few bugs with merc voices during AIM purchase. When the first area Omerta loaded, some mercs were invisible even when moving around. Decided to now go back to the 7609 version to see whats up. May be because of the unstable versions. Dang I really wanted to implement disease and all the other bells and whistles.
Edit v2 - You're gonna think I'm some moron, but I went through the JAoptions.ini and found the disease section. Maybe it's supposed to be there for 7609, maybe not. Turned it on anyhow and now will try some stuffs.
[Updated on: Sat, 18 April 2020 19:05] Report message to a moderator
|
Private
|
|
|
|
|
Re: New Feature: Disease[message #359631 is a reply to message #359627]
|
Sat, 18 April 2020 19:14
|
|
Kitty |
|
Messages:473
Registered:October 2017 Location: Germany |
|
|
According AR for recent builds (unstable, not-7609, latest SCI - whatever you call it), it can be done, is not that complicated, but a lot of work and time.
Quote:Dang I really wanted to implement disease and all the other bells and whistles.
That's exactly my thoughts
Many of the new features require changes in the xml and lua files, as well as some work with maps.
Therefore, when using AR with latest builds, some things are missing, some feature don't work and other things are just odd. For example, when a spy wants to hack a pc to get intel,
there are a few definitions in lua, xml needed, as well as correct placement of pc at map. Or for disease-feature, the related xml files as well as needed items in items.xml are missing (surgical gloves, etc. (resulting in shortage of ppe, which apparently is bad).
Since that is true for most new features, it takes time to first find and then apply changes. Plus, the most recent builds have seen updates to some files in game-dir as well, which then also have to be checked if relevant.
But, I'm working on this for some while now. I'd say I'm close to at least upload a w.i.p.-version for playtesting soon. Due to RL, I have less time now then I would like to, but check the link seven posted above for news.
How to get: latest 1.13, 7609 and more | 7609 SCI (eng) | Compiling+SVN
I need more details. (Didi Hallervorden) Report message to a moderator
|
|
|
|
|
Re: New Feature: Disease[message #360410 is a reply to message #359634]
|
Sat, 20 June 2020 18:56
|
|
Flugente |
|
Messages:3507
Registered:April 2009 Location: Germany |
|
|
As of r8826 and GameDir r2551, we can have multiple personalities at the same time (up to 32 to be precise). But how do we get them?
For this I added a new tag to Diseases.xml, <fSpecialFlagContractDisability>. Every time we are infected with a disease having this tag, a new disability we don't have yet is added.
Toggle Spoiler
<DISEASE>
<uiIndex>11</uiIndex>
<szName>PTSD</szName>
<szFatName>|P|T|S|D</szFatName>
<szDescription>|Post|traumatic |stress |disorder may develop after a person is exposed to one or more traumatic events, such as sexual assault,
warfare, serious injury, or threats of imminent death that result in feelings of intense fear, horror, and powerlessness.</szDescription>
<sInfectionPtsInitial>100</sInfectionPtsInitial>
<sInfectionPtsOutbreak>20</sInfectionPtsOutbreak>
<sInfectionPtsFull>100</sInfectionPtsFull>
<sInfectionPtsGainPerHour>0</sInfectionPtsGainPerHour>
...
<InfectionChance_WOUND_WIS>50</InfectionChance_WOUND_WIS>
<InfectionChance_WOUND_TRAUMATIC>40</InfectionChance_WOUND_TRAUMATIC>
...
<fCanBeCured>0</fCanBeCured>
<fReverseOnFull>0</fReverseOnFull>
<fCanReInfect>1</fCanReInfect>
<fHideSymbol>1</fHideSymbol>
<fDisgusting>0</fDisgusting>
<fSpecialFlagPTSDBuns>1</fSpecialFlagPTSDBuns>
<fSpecialFlagContractDisability>1</fSpecialFlagContractDisability>
...
<moralemodifier>0.9</moralemodifier>
</DISEASE>
So if our merc has a colourful stay in Arulco, things might get interesting. Provided it is so colourful that they get PTSD several times, that is.
I know now that it could never work between us, as much as we wanted to, it could never be! Not because you're a rabbit, but because you're black.
If you want, you can donate to me. This will not affect how and what I code, and I will not code specific features in return. I will be thankful though.Report message to a moderator
|
|
|
|
Re: New Feature: Disease[message #360451 is a reply to message #360410]
|
Fri, 26 June 2020 01:31
|
|
Flugente |
|
Messages:3507
Registered:April 2009 Location: Germany |
|
|
As of r8828 & GameDir r2553, we've got a few nasty surprises to torment our mercs with. Also, before y'all ignore it, the new GameDir is required with that exe, as we get a new cursor.
First of all, the code now differentiate between fire damage and non-fire-based gas damages (mustard gas, creature gas, white phosphor, but not molotovs). This is put to good use, as we have two new diseases that we are guaranteed to receive (with stock settings) if we take damage from these sources:
Burns & Corroded Lungs
<DISEASE>
<!-- Skin burns from taking fire damage -->
<uiIndex>18</uiIndex>
<szName>Burns</szName>
<szFatName>|B|u|r|n|s</szFatName>
<szDescription>A large injury of the skin caused by fire, this is a quite painful condition and will severely affect your dexterity.</szDescription>
<sInfectionPtsInitial>100</sInfectionPtsInitial>
<sInfectionPtsOutbreak>80</sInfectionPtsOutbreak>
<sInfectionPtsFull>500</sInfectionPtsFull>
<sInfectionPtsGainPerHour>-4</sInfectionPtsGainPerHour>
...
<InfectionChance_WOUND_FIRE>100</InfectionChance_WOUND_FIRE>
...
<fCanBeCured>0</fCanBeCured>
<fReverseOnFull>0</fReverseOnFull>
<fCanReInfect>1</fCanReInfect>
<fHideSymbol>1</fHideSymbol>
<fDisgusting>1</fDisgusting>
...
<sEffStatDEX>-40</sEffStatDEX>
...
<sEffAP>-10</sEffAP>
<sLifeRegenHundreds>-150</sLifeRegenHundreds>
<moralemodifier>0.8</moralemodifier>
</DISEASE>
<DISEASE>
<!-- Our lung is damaged after taking damage from mustard/creature gas -->
<uiIndex>19</uiIndex>
<szName>Corroded lung</szName>
<szFatName>|C|o|r|r|o|d|e|d |l|u|n|g</szFatName>
<szDescription>Due to exposure to chemical warfare agents, your lungs are severely damaged. This will obviously affect your stamina.</szDescription>
<sInfectionPtsInitial>120</sInfectionPtsInitial>
<sInfectionPtsOutbreak>100</sInfectionPtsOutbreak>
<sInfectionPtsFull>480</sInfectionPtsFull>
<sInfectionPtsGainPerHour>-5</sInfectionPtsGainPerHour>
...
<InfectionChance_WOUND_GAS>100</InfectionChance_WOUND_GAS>
...
<fCanBeCured>0</fCanBeCured>
<fReverseOnFull>0</fReverseOnFull>
<fCanReInfect>1</fCanReInfect>
<fHideSymbol>1</fHideSymbol>
<fDisgusting>0</fDisgusting>
...
<sEffAP>-30</sEffAP>
<usMaxBreath>60</usMaxBreath>
<sLifeRegenHundreds>-200</sLifeRegenHundreds>
<moralemodifier>0.9</moralemodifier>
</DISEASE>
A single hit of these isn't too bad, but notice this gets worse every time you get hit with this. Granted, after taking 5 hits from fire you're likely dead anyway, but still, quite nasty.
Note that armour can nowadays have fire resistance, which lowers fire damage. This also applies to projectiles from the flamethrower (item #63), even if those are technically bullets. As a result, 100% fire resistance means no fire damage, which means you don't get Burns.
So far, so good. Now to the evil stuff.
Important disclaimer: As the following changes are likely controversial, they have a separate option, and are off by default. They have significant consequences. you have been warned.
The switch is a new setting in JA2_Options.ini:
; Unlocks more severe effects on some diseases. The possibilities include:
; - getting additional permanent disabilities
; - only one hand can be used for the duration of the disease
; - damage to the legs precludes kicking, running, and drastically increases travel times
; See Disease.xml for more details.
DISEASE_SEVERE_LIMITATIONS = FALSE
This also covers <fSpecialFlagContractDisability> from the previous post. Only by setting this to TRUE will the following things happen:
I've added two new tags which are used for Broken leg and Broken arm:
Broken leg & Broken arm
<DISEASE>
<uiIndex>12</uiIndex>
<szName>Broken leg</szName>
<sInfectionPtsInitial>200</sInfectionPtsInitial>
<sInfectionPtsOutbreak>100</sInfectionPtsOutbreak>
<sInfectionPtsFull>200</sInfectionPtsFull>
<sInfectionPtsGainPerHour>-2</sInfectionPtsGainPerHour>
...
<InfectionChance_WOUND_AGI>75</InfectionChance_WOUND_AGI>
<fCanBeCured>0</fCanBeCured>
<fSpecialFlagLimitedUseLegs>1</fSpecialFlagLimitedUseLegs>
<sEffStatAGI>-50</sEffStatAGI>
<sEffCarryStrength>-20</sEffCarryStrength>
<sLifeRegenHundreds>-10</sLifeRegenHundreds>
</DISEASE>
<DISEASE>
<uiIndex>13</uiIndex>
<szName>Broken arm</szName>
<sInfectionPtsInitial>200</sInfectionPtsInitial>
<sInfectionPtsOutbreak>100</sInfectionPtsOutbreak>
<sInfectionPtsFull>200</sInfectionPtsFull>
<sInfectionPtsGainPerHour>-2</sInfectionPtsGainPerHour>
<InfectionChance_WOUND_DEX>75</InfectionChance_WOUND_DEX>
<fCanBeCured>0</fCanBeCured>
<fSpecialFlagLimitedUseArms>1</fSpecialFlagLimitedUseArms>
<sEffStatDEX>-50</sEffStatDEX>
<sEffStatSTR>-20</sEffStatSTR>
<sLifeRegenHundreds>-10</sLifeRegenHundreds>
</DISEASE>
If a disease your merc has has <fSpecialFlagLimitedUseLegs> set to 1, they cannot use their leg fully. This means:
- they move visibly slower
- the travel a lot slower in strategic
- they can't use kicks in melee. This includes not being able to do the martial art spinkick, obviously
- they cannot run. No matter how hard you press that [r] button, they will always walk. Slowly.
The justification being... your leg is broken. Fancy moves aren't happening until it is healed.
Different but equally bad is the <fSpecialFlagLimitedUseArms> tag. Mercs with that can only use one arm. You can actually see that in the first image of this post - Shepard can't put the Glock in her second hand. It is greyed out. This also prohibits her from equipping a twohanded weapon in her hands. And no, swapping weapons via portrait rightclick does not work here .
Since most of the weapons are twohanded... this will pose something of a problem I presume.
Again you can't doctor this, this needs to heal on its own. Luckily you can at least speed this process up: With a medical splint.
Medical splint
<ITEM>
<uiIndex>1758</uiIndex>
<szItemName>Splint</szItemName>
<szLongItemName>Medical splint</szLongItemName>
<szItemDesc>This splint can be used to stabilize strained extremities, which can fasten the healing process.</szItemDesc>
<szBRName>Medical splint</szBRName>
<szBRDesc>This universal medical splint fits any arm and leg, and will help you heal that much faster.</szBRDesc>
<usItemClass>268435456</usItemClass>
<nasLayoutClass>1</nasLayoutClass>
<ubGraphicType>1</ubGraphicType>
<ubGraphicNum>611</ubGraphicNum>
<ubWeight>6</ubWeight>
<ubPerPocket>4</ubPerPocket>
<ItemSize>16</ItemSize>
<usPrice>80</usPrice>
<ubCoolness>1</ubCoolness>
<Medical>1</Medical>
<BR_NewInventory>6</BR_NewInventory>
<medicalsplint>1</medicalsplint>
</ITEM>
This item can be applied by certified personnel (paramedics and doctors with new traits, anyone with MED > 50 with old traits) by applying the item (comes with it's own cursor):
Once applied, it will either 'latch on' to the broken arm or the broken leg and double the regeneration rate. You can see which one it is healing in the first image.
As you can likely imagine, this can throw you off. A merc with one or both of these afflictions is likely to become a liability in combat.
Have fun
[Updated on: Fri, 26 June 2020 01:45]
I know now that it could never work between us, as much as we wanted to, it could never be! Not because you're a rabbit, but because you're black.
If you want, you can donate to me. This will not affect how and what I code, and I will not code specific features in return. I will be thankful though.Report message to a moderator
|
|
|
|
|
Re: New Feature: Disease[message #360478 is a reply to message #360456]
|
Tue, 30 June 2020 01:11
|
|
Flugente |
|
Messages:3507
Registered:April 2009 Location: Germany |
|
|
I imagine that would be darkly hilarious to see, the poor merc constantly stumbling around. Good thing we can nowadays drag them around.
But full blindness would be extremely limiting. Perhaps the effect of having one eye damaged for the duration would result in, say, very serious tunnel vision. But that's not that neat either, as minimum tunnelvison has to be 45 degree, and that is quite useful.
Hmm.
I like the idea, but can't see a good way to make it work.
I know now that it could never work between us, as much as we wanted to, it could never be! Not because you're a rabbit, but because you're black.
If you want, you can donate to me. This will not affect how and what I code, and I will not code specific features in return. I will be thankful though.Report message to a moderator
|
|
|
|
|
|
Re: New Feature: Disease[message #366306 is a reply to message #362820]
|
Thu, 07 November 2024 16:57
|
|
Kitty |
|
Messages:473
Registered:October 2017 Location: Germany |
|
|
Some QOL change for disease feature:
As is widely known, when using the disease feature it's very helpfull to carry surgical mask and surgical gloves inside the inventory since those items do grant a certain amount of protection (details see Flugentes former posts above).
Thing is, that's two items and therefore two inventory slots and that's meh. What if there were a way to combine those? Hmm, let's make a PPE Bag ...
Details:
- added item "Empty PPE Bag"
- when attaching both, the surgical mask and surgical gloves, to that, it'll transform into a now filled "PPE Bag"
- this "PPE Bag" will hold both disease protection variations (one from mask, another from gloves) in one item
- compared to mask and gloves, this item is also more robust (damage resistant, waterproof)
- the "Empty PPE Bag" is for sale at BR (same as the mask and gloves)
- for the filled "PPE Bag" we either have to fill it ourself (by attaching mask and gloves to an empty one) or rely on local merchants
- a few filled "PPE Bag" can be bought from Rebel-Quartermaster and at Cambria Pharmacy, if ALLOW_EXTRA_CIVILIANS and ALLOW_EXTRA_MERCHANTS are TRUE
- also sold by Tina in Grumm (if Disease feature is used)
- replaced mask and gloves in Fox's Starting Gear sets with "PPE Bag", added one to a starting gear set of Stella (Doctor) and Hurl (Hypochondriac)
- thanks to rftr for code changes regarding the item-tags of disease-protection, wouldn't be possible without that
- has been added to gitHub and is part of release since 2024-11-07
Pictures:
Transforming
-
-
Shopping
-
-
[Updated on: Fri, 08 November 2024 04:02]
How to get: latest 1.13, 7609 and more | 7609 SCI (eng) | Compiling+SVN
I need more details. (Didi Hallervorden) Report message to a moderator
|
|
|
|
Goto Forum:
Current Time: Thu Dec 12 03:11:24 GMT+2 2024
Total time taken to generate the page: 0.02202 seconds
|