Jump to content

Recommended Posts

7 minutes ago, 0modskilzs said:

Isn't this just the Weight Gain mod? I don't really see any differences? Unless I am just missing the point here

 

By "the weight gain mod" which one do you mean? I'm aware of three others for Fallout 4, but the only visual body alterations they perform are either to the "triangle" or they require a special body replacer with its own specific clothing conversions.

 

The initial goal with this mod was to have something similar to existing weight gain mods but able to work with LooksMenu morphs for CBBE, FG, TWB... whatever body replacer you prefer.

Link to comment
19 hours ago, vaultbait said:

 

By "the weight gain mod" which one do you mean? I'm aware of three others for Fallout 4, but the only visual body alterations they perform are either to the "triangle" or they require a special body replacer with its own specific clothing conversions.

 

The initial goal with this mod was to have something similar to existing weight gain mods but able to work with LooksMenu morphs for CBBE, FG, TWB... whatever body replacer you prefer.

I was talking about this one, this is really the only weight gain mod I know https://www.deviantart.com/coldsteelj/art/Fallout-4-WeightGain-mod-ssbbw-730902010 you gain with food and some weird nutrino gun

Link to comment
13 hours ago, 0modskilzs said:

I was talking about this one, this is really the only weight gain mod I know https://www.deviantart.com/coldsteelj/art/Fallout-4-WeightGain-mod-ssbbw-730902010 you gain with food and some weird nutrino gun

 

That's one of the three I know of, but last I looked it requires a body replacer made by the author and I actually asked them whether they'd consider making it body-agnostic but they weren't interested. It's a very nice body, excellent work, but also means that clothing has to be converted for use with it specifically, and it didn't support pregnancy morphs back when I looked into it (though maybe that's been improved since).

 

The other two I'm aware of are Gain Some Weight and Workout Through the Fallout (deleted by its author, not sure if it moved somewhere else), but those lack LooksMenu slider integration entirely. I want to be able to use Fusion Girl's BodyFat slider implementation, but that's just my personal preference.

 

Rad Morphing Redux on the other hand is a framework to let you set up arbitrary body morph conditions and effects for any body with LooksMenu support, so Unhealthy Craving takes advantage of that to implement its gain/loss appearance allowing users to decide for themselves what body replacer and outfits they prefer and what "skinny" or "fat" looks like in their Fallout 4 universe. I'd rather spend time playing with mods other people have put a lot of time into than making them myself, so trust me when I say that I looked really hard to find one which did what I want before giving in and coding this one.

 

But my plans for Unhealthy Craving go far beyond body morphing, and I intend to use it to explore the darker depths of food addiction, albeit with a sexual/fetish approach. For example, there's already integration with AAF (to detect sexual activity as a form of exercise), and with 1.3.0 which I'm in the final stages of playtesting now adds some integration with the Sex Attributes mod (spirit decrease and arousal increase when feeding your addiction to junk food, plus a random chance you fall to the floor in a noisy foodgasm fit, alerting nearby hostiles, can all be entirely disabled in MCM though for players who aren't interested in the addiction aspect).

Link to comment
4 hours ago, stillgar said:

this is what i was looking for as soon as RMR added the custom trigger,  thank you :D

 

Thanks, me too! I created it within about a day of RMR v2 becoming available, but had been thinking about the idea ever since the first v2 drawing board discussions.

Link to comment

1.3.0 (2022-12-16)

  • Unhealthy Craving junk food addiction now subsides if you abstain from  junk food for a while, but takes longer the fatter you are
  • MCM option to toggle the Unhealthy Craving junk food addiction on and off
  • Pop up a message box when junk food addiction effect is acquired or lost
  • Eating junk food while addicted can trigger a foodgasm, knocking down the  player and alerting nearby hostiles
  • Eating junk food while addicted increases arousal and decreases spirit if  using Sex Attributes mod
  • Pink food paste is just a fat gain item, not junk food
  • Vanilla game alcoholic beverages are just fat gain items, not junk food
  • MCM option to still treat alcoholic beverages as junk food instead
  • Cereal Killer: find random toys and prizes in boxes of breakfast cereal
  • MCM option to toggle the Cereal Killer feature on and off
  • Associated vanilla game Flash graphics to Pip-Boy views of Body Fat and  Unhealthy Craving in the perks list
  • Once obese increasingly disable fast travel and sprinting, then sneaking  and running when morbidly, finally jumping and fighting at obscenely
  • MCM option to disable activity blocking
  • Suffer additional falling damage, up to double damage at max body fat
  • MCM toggle to turn off extra falling damage

 

Edit: I've updated the Frequently Asked Questions (post #2) and Known Bugs (post  #3) to be current with the state of 1.3.0 now.

Edited by vaultbait
Link to comment
1 hour ago, vaultbait said:

1.3.0 (2022-12-16)

  • Unhealthy Craving junk food addiction now subsides if you abstain from  junk food for a while, but takes longer the fatter you are
  • MCM option to toggle the Unhealthy Craving junk food addiction on and off
  • Pop up a message box when junk food addiction effect is acquired or lost
  • Eating junk food while addicted can trigger a foodgasm, knocking down the  player and alerting nearby hostiles
  • Eating junk food while addicted increases arousal and decreases spirit if  using Sex Attributes mod
  • Pink food paste is just a fat gain item, not junk food
  • Vanilla game alcoholic beverages are just fat gain items, not junk food
  • MCM option to still treat alcoholic beverages as junk food instead
  • Cereal Killer: find random toys and prizes in boxes of breakfast cereal
  • MCM option to toggle the Cereal Killer feature on and off
  • Associated vanilla game Flash graphics to Pip-Boy views of Body Fat and  Unhealthy Craving in the perks list
  • Once obese increasingly disable fast travel and sprinting, then sneaking  and running when morbidly, finally jumping and fighting at obscenely
  • MCM option to disable activity blocking
  • Suffer additional falling damage, up to double damage at max body fat
  • MCM toggle to turn off extra falling damage

 

Edit: I've updated the Frequently Asked Questions (post #2) and Known Bugs (post  #3) to be current with the state of 1.3.0 now.

 

YES!!! FINALLY! Can't wait to check this out!

 

By the way, my current character has Unhealthy Craving - would that be a problem if I update? Also, is it possible (this time) to cure the addiction?

Link to comment
29 minutes ago, rubber_duck said:

my current character has Unhealthy Craving - would that be a problem if I update?

 

It should be fine. You won't see it listed in your Pip-Boy at first once you upgrade, due to some tricks I had to pull in order to make it possible to undo the effects (you can't easily cancel a specific magic effect on an actor, so instead the effect is conditionally applied based on an internal flag which gets set the next time you meet the requirements for getting addicted and unset if the addiction subsides). All that means is you'll basically need to get addicted again, not that it's hard to do.

 

29 minutes ago, rubber_duck said:

Also, is it possible (this time) to cure the addiction?

 

Yes, see the FAQ (post #2) answer about the craving effects, but in short it will eventually go away if you stop consuming junk food, though how long that takes will depend on how fat you are. If you're in a hurry, you can spam enough Psycho to get emaciated, and then sit in a chair for 24 game hours and you should get the message that it has subsided. At least I think that would work, but so far I've only playtested losing it more naturally after about a week in game with a fit body fat level. This is roughly what it looks like in the script, and the code comments should give you some idea of the basic result:

 

; After abstaining at least a day, test to see if craving subsides
; Chance it ends is inversely proportional to body fat, but increases with longer abstinence
; Scale by the update delay so that the chance is consistent regardless of how fast this is checked
; At 0.01 BF it's a 100% chance after one day
; At 0.25 BF it's a 4.0% chance after one day and guaranteed after 25 days
; At 0.75 BF it's a 1.3% chance after one day and guaranteed after 75 days
; At 1.00 BF it's a 0.1% chance after one day and guaranteed after 100 days
; But we'll try to make sure they lapse long before that!
Float Chance = (UpdateDelay / 24.0) * (DaysAbstained / 100) / EffectiveBodyFat
If DaysAbstained > 1.0 && Utility.RandomFloat() < Chance
    AddictionActive.SetValue(0.0)
EndIf

 

Link to comment
1 hour ago, vaultbait said:

 

It should be fine. You won't see it listed in your Pip-Boy at first once you upgrade, due to some tricks I had to pull in order to make it possible to undo the effects (you can't easily cancel a specific magic effect on an actor, so instead the effect is conditionally applied based on an internal flag which gets set the next time you meet the requirements for getting addicted and unset if the addiction subsides). All that means is you'll basically need to get addicted again, not that it's hard to do.

 

 

Yes, see the FAQ (post #2) answer about the craving effects, but in short it will eventually go away if you stop consuming junk food, though how long that takes will depend on how fat you are. If you're in a hurry, you can spam enough Psycho to get emaciated, and then sit in a chair for 24 game hours and you should get the message that it has subsided. At least I think that would work, but so far I've only playtested losing it more naturally after about a week in game with a fit body fat level. This is roughly what it looks like in the script, and the code comments should give you some idea of the basic result:

 

; After abstaining at least a day, test to see if craving subsides
; Chance it ends is inversely proportional to body fat, but increases with longer abstinence
; Scale by the update delay so that the chance is consistent regardless of how fast this is checked
; At 0.01 BF it's a 100% chance after one day
; At 0.25 BF it's a 4.0% chance after one day and guaranteed after 25 days
; At 0.75 BF it's a 1.3% chance after one day and guaranteed after 75 days
; At 1.00 BF it's a 0.1% chance after one day and guaranteed after 100 days
; But we'll try to make sure they lapse long before that!
Float Chance = (UpdateDelay / 24.0) * (DaysAbstained / 100) / EffectiveBodyFat
If DaysAbstained > 1.0 && Utility.RandomFloat() < Chance
    AddictionActive.SetValue(0.0)
EndIf

 

 

Got it! I'll try to get addicted again, but so far everything's been working properly. I just had to ask as I'm afraid of breaking something and getting stuck with permanent morphs (happened to me once when I messed with wrong settings in old RMR).

 

Anyways, looks like I'll be exercising a lot this weekend! I installed a few weapon mods and had to wait a few days for them to appear in LL, and as a result my character got obese (due to eating only Deathclaw steak). Who would've thought it's so easy to gain weight just by eating a giant lizard.

 

Keep up the great work, this is amazing! Thanks for replying and take care!

 

Link to comment
16 hours ago, rubber_duck said:

I'll try to get addicted again

 

Currently, the odds of addiction are 25% of your body fat, so for example if you're "chubby" (maybe BF=0.45) then you have a roughly 11% chance of getting addicted each time you consume junk food, or would probably be addicted after eating/drinking approximately 9 junk food items. If you're obese (let's say BF=0.75) then you'll probably be addicted after eating or drinking 5 junk food items. If you're thin (e.g. BF=0.15) then you'd probably need a lot more, like around 27.

 

Of course, this is all stuff I'm happy to adjust the base constants and formulae around, if people find it too easy or too hard. I've been trying to playtest as thoroughly as possible, but long-term use is not trivial to recreate any other way than actually spending a while running it. In the future, I also plan to add multipliers in MCM to allow for personal fine-tuning of the mod's behaviors, but I'd like to be sure I've got playable defaults based on feedback from users first.

 

16 hours ago, rubber_duck said:

I just had to ask as I'm afraid of breaking something and getting stuck with permanent morphs (happened to me once when I messed with wrong settings in old RMR).

 

Hopefully that shouldn't be possible with RMR 2.x, but also all UC does to drive morphs is tell RMR "my fat value is 0.25... okay it's at 0.27... now 0.26" and so on. If the trigger is unregistered by shutting down the mod then everything should just go back to normal. All the actual morphing is left up to RMR to take care of.

 

16 hours ago, rubber_duck said:

Anyways, looks like I'll be exercising a lot this weekend! I installed a few weapon mods and had to wait a few days for them to appear in LL, and as a result my character got obese (due to eating only Deathclaw steak). Who would've thought it's so easy to gain weight just by eating a giant lizard.

 

Like I said above, I'm happy to make adjustments. Right now for normal food (not junk food) the formula is that you gain 0.0005 fat multiplied by the item's weight and its base value in caps. So for example if a cooked food item weighs 1.0 and has a value of 50 caps then that's a fat increase of 0.025. For comparison, junk food items have a fixed fat gain of 0.02 and gain chems like Buffout or Stimpaks (or booze by default now) are +0.03 fat, while loss chems like Jet or purified water are -0.01 fat.

Edited by vaultbait
Link to comment
2 hours ago, vaultbait said:

Like I said above, I'm happy to make adjustments. Right now for normal food (not junk food) the formula is that you gain 0.0005 fat multiplied by the item's weight and its base value in caps. So for example if a cooked food item weighs 1.0 and has a value of 50 caps then that's a fat increase of 0.025. For comparison, junk food items have a fixed fat gain of 0.02 and gain chems like Buffout or Stimpaks (or booze by default now) are +0.03 fat, while loss chems like Jet or purified water are -0.01 fat.

 

Thanks for detailed info! I haven't managed to gain addiction (again) just yet, but I'm working on it.

 

That being said, I do have only one complaint so far - Jet. Personally, I think Jet would be better off as weight gain chem instead of weight burn chem. Just personal preference (and absolutely not a huge deal!).

 

Also, and this is more complicated... Say I want to add other chems to alter the weight - how would I do that (if possible)?

 

I'm asking as I play with MAIM 2 which adds a bunch of medical stuff (such as Ibuprofen, First Aid Kits, various Autoinjectors, etc.). MAIM 2 also modifies every single chem in the game. UC works pretty well with MAIM 2, but those chems that are added by MAIM 2 don't have any gain/burn effect. Is there a way to make UC recognize MAIM 2 chems? If so, would I need to modify the original script or could that be done in xEdit?

 

Keep up the great work!

 

Link to comment
1 hour ago, rubber_duck said:

That being said, I do have only one complaint so far - Jet. Personally, I think Jet would be better off as weight gain chem instead of weight burn chem. Just personal preference (and absolutely not a huge deal!).

 

I made it burn fat because it speeds you up and that seems like it should consume additional energy, but also because there are a variety of references likening Jet abusers to crackheads (who are stereotypically skinny). The De Luca twins in Vault 81 are a prime example. However, you could pretty easily patch the plugin to change up those choices since it's all done with formlists (UC_FatGainItems=0x806 and UC_FatLossItems=0x805 specifically).

 

1 hour ago, rubber_duck said:

Also, and this is more complicated... Say I want to add other chems to alter the weight - how would I do that (if possible)?

 

I'm asking as I play with MAIM 2 which adds a bunch of medical stuff (such as Ibuprofen, First Aid Kits, various Autoinjectors, etc.). MAIM 2 also modifies every single chem in the game. UC works pretty well with MAIM 2, but those chems that are added by MAIM 2 don't have any gain/burn effect. Is there a way to make UC recognize MAIM 2 chems? If so, would I need to modify the original script or could that be done in xEdit?

 

You could patch the item formlists with a plugin as mentioned above, but when it comes to strictly adding things to a formlist there's also the option of using a script to extend a formlist without patching the records in the plugin. I also put in keywords for fat gain/loss items and junk food which you could add to specific forms to have them recognized, and added corresponding keyword formlists in case you have other keywords you want to cause items to be recognized as those things.

 

Anyway, if you let me know the plugin name and potion or keyword or effect form IDs, I could just add them to the RedoIntegrations() function (you'll find it near the end of UC\Main.psc if you want to see examples).

Link to comment
1 hour ago, vaultbait said:

 

I made it burn fat because it speeds you up and that seems like it should consume additional energy, but also because there are a variety of references likening Jet abusers to crackheads (who are stereotypically skinny). The De Luca twins in Vault 81 are a prime example. However, you could pretty easily patch the plugin to change up those choices since it's all done with formlists (UC_FatGainItems=0x806 and UC_FatLossItems=0x805 specifically).

 

 

You could patch the item formlists with a plugin as mentioned above, but when it comes to strictly adding things to a formlist there's also the option of using a script to extend a formlist without patching the records in the plugin. I also put in keywords for fat gain/loss items and junk food which you could add to specific forms to have them recognized, and added corresponding keyword formlists in case you have other keywords you want to cause items to be recognized as those things.

 

Anyway, if you let me know the plugin name and potion or keyword or effect form IDs, I could just add them to the RedoIntegrations() function (you'll find it near the end of UC\Main.psc if you want to see examples).

 

I appreciate it, thanks!

 

For some reason, I cannot add MAIM's items to formlists... I copy both formlists as override into new ESLified plugin (I don't want to modify the original plugin), add MAIM 2 as a master, and when I add new item field to any of the 2 copied formlists - it cannot find MAIM's items. I have no clue what's going on here, but it doesn't work. I had similar issue a few months back when I wanted to add a few MAIM items to some mod-added containers, and I also couldn't do it. I'll see if I can get some help from MAIM discord server.

 

As for the second part (potion/kw/effect ID)... I don't really understand - what exactly would you like me to send?

 

Thanks for replying!

 

Link to comment
2 hours ago, rubber_duck said:

For some reason, I cannot add MAIM's items to formlists... I copy both formlists as override into new ESLified plugin (I don't want to modify the original plugin), add MAIM 2 as a master, and when I add new item field to any of the 2 copied formlists - it cannot find MAIM's items. I have no clue what's going on here, but it doesn't work. I had similar issue a few months back when I wanted to add a few MAIM items to some mod-added containers, and I also couldn't do it. I'll see if I can get some help from MAIM discord server.

 

Sounds like you're using FO4Edit... You might try saving your new plugin after adding the MAIM master, and then close and reopen your plugin with FO4Edit again (if everything is correct, it should automatically load the masters along with it). Also make sure the forms you're trying to add from MAIM are consumables, in case that's not obvious.

 

2 hours ago, rubber_duck said:

As for the second part (potion/kw/effect ID)... I don't really understand - what exactly would you like me to send?

 

The filename for the MAIM plugin and the hex form IDs of the consumables you're trying to add (and which lists you want them in). I'll patch them into the script and compile it and you can test. If it works and makes sense I'll include it in the next version so you don't need to carry a patch.

Link to comment
16 hours ago, vaultbait said:

The filename for the MAIM plugin and the hex form IDs of the consumables you're trying to add (and which lists you want them in). I'll patch them into the script and compile it and you can test. If it works and makes sense I'll include it in the next version so you don't need to carry a patch.

 

No promises, but I'll try that xEdit trick shortly.

 

As for the plugin data... Here. Hope it helps.

 

PLUGIN: 'MAIM 2.esp'

 

Ibuprofen: 'FE001029'

Atropine: 'FE00102E'

TXA Autoinjector: 'FE001100'

Mannitol Autoinjector: 'FE00162F'

First Aid Kit: 'FE001010'

 

If it was up to me, I'd put the following items to weight gain formlist:

Ibuprofen (heals all body parts), Atropine (poison resist) and Mannitol (heals only head)

 

I'd put the other items to weight loss formlist:

First Aid Kit (heals crippled limbs and stops heavy bleeding) and TXA (stops light bleeding, reduces heavy bleeds to light and slowly heals body parts).

 

Look mate, I'm not a doctor in real life so I have no idea if this makes sense. Heck, I don't think whether it'd make more sense to add all these to only one formlist or not. The way I'd put these items is to make it even easier to gain weight (and, automatically, makes it more difficult to lose weight).

 

That being said, there are more ingestibles in MAIM 2! However, I didn't include them since that seriously wouldn't make sense (losing/gaining weight by consuming bandages, really?).

 

Also, regarding other, vanilla, items (don't know if you've included those in UC already).

Radaway - loses weight (-2% or whatever)

Rad-X - +1%

Bloodpack - same as Mex-X (+3%)

Glowing Bloodpack - -3% (or similar)

Refreshing Beverage - it'd make most sense for it to burn fat, but just for fun I'd add it to weight gain (heal your health, rads and addictions, but get some weight just to make things more interesting!)

Curie's Healthpak - same as Stimpak (+3%)

 

Hopefully this mess helps you in some way. Take care and keep up the great work!

 

Link to comment
On 12/18/2022 at 4:34 PM, rubber_duck said:

As for the plugin data... Here. Hope it helps.

 

PLUGIN: 'MAIM 2.esp'

 

Ibuprofen: 'FE001029'

Atropine: 'FE00102E'

TXA Autoinjector: 'FE001100'

Mannitol Autoinjector: 'FE00162F'

First Aid Kit: 'FE001010'

 

If it was up to me, I'd put the following items to weight gain formlist:

Ibuprofen (heals all body parts), Atropine (poison resist) and Mannitol (heals only head)

 

I'd put the other items to weight loss formlist:

First Aid Kit (heals crippled limbs and stops heavy bleeding) and TXA (stops light bleeding, reduces heavy bleeds to light and slowly heals body parts).

 

Look mate, I'm not a doctor in real life so I have no idea if this makes sense. Heck, I don't think whether it'd make more sense to add all these to only one formlist or not. The way I'd put these items is to make it even easier to gain weight (and, automatically, makes it more difficult to lose weight).

 

I'll admit I didn't put a ton of thought into what vanilla game and DLC items I did or didn't make influence body fat. Here's what it looks like in the script source (I'll include this in the next release):

 

    If Game.IsPluginInstalled("MAIM 2.esp")
        FatGainItems.AddForm(Game.GetFormFromFile(0x001029, "MAIM 2.esp") as Potion) ; Ibuprofen
        FatGainItems.AddForm(Game.GetFormFromFile(0x00102E, "MAIM 2.esp") as Potion) ; Atropine
        FatGainItems.AddForm(Game.GetFormFromFile(0x00162F, "MAIM 2.esp") as Potion) ; Mannitol Autoinjector

        FatLossItems.AddForm(Game.GetFormFromFile(0x001010, "MAIM 2.esp") as Potion) ; First Aid Kit
        FatLossItems.AddForm(Game.GetFormFromFile(0x001100, "MAIM 2.esp") as Potion) ; TXA Autoinjector
    EndIf

 

Here's the patched script recompiled, bundled as an installable mod so you can just drop it into your mod manager. Give it a try and let me know if it's working the way you want: (removed as it's obsoleted by 1.4.0 which makes this directly configurable)

 

On 12/18/2022 at 4:34 PM, rubber_duck said:

That being said, there are more ingestibles in MAIM 2! However, I didn't include them since that seriously wouldn't make sense (losing/gaining weight by consuming bandages, really?).

 

Right, it wasn't a goal to make all consumables influence body fat anyway, I just included some of what I thought of as likely to create some challenging situations from a gameplay standpoint.

 

On 12/18/2022 at 4:34 PM, rubber_duck said:

Also, regarding other, vanilla, items (don't know if you've included those in UC already).

Radaway - loses weight (-2% or whatever)

Rad-X - +1%

Bloodpack - same as Mex-X (+3%)

Glowing Bloodpack - -3% (or similar)

Refreshing Beverage - it'd make most sense for it to burn fat, but just for fun I'd add it to weight gain (heal your health, rads and addictions, but get some weight just to make things more interesting!)

Curie's Healthpak - same as Stimpak (+3%)

 

These are the current vanilla game formlist items for direct fat gain and loss...

 

FatGainItems: Buffjet, Buffout, Bufftats, Calmex, CurieHealthpak, DayTripper, FoodPaste, MedX, Psychobuff, radscorpionVenom, Stimpak, XCell

 

FatLossItems: BerryMentats, BrainFungus, Bubblegum, CaveFungus, DaddyO, Fury, GlowingFungus, GrapeMentats, Herbal_Stimulant, Jet, JetFuel, Mentats, OrangeMentats, Overdrive, Psycho, PsychoJet, Psychotats, UltraJet, WaterPurified

 

I also soft-integrate inclusion of items from DLCs and some mods by adding them via script every time the game is loaded (in order to handle changes to mod lists), and long-running gain/loss effects from some mods like smoking, contraceptives, pregnancy, etc which just alter your metabolism in one direction or the other rather than directly adding or removing fat.

 

I remember deciding not to include rad meds and blood packs early on, but I don't exactly recall what my reasoning was now. I'll reconsider.

 

Thanks for the ideas!

Edited by vaultbait
Link to comment
2 hours ago, kazeha9 said:

some wierd stuff .. delete all saves from all foulder start new game all work perfecto but this poo up keep to bother me every 30 min in game time (base mod settings ) and im start with already body fat perk

 

A very interesting bug! And confusing. That message should only appear if the addiction is "active" and the function which is displaying it directly deactivates the addiction, so it shouldn't ever repeat unless you get a message about getting addicted again first.

 

Press the ~ key to open the game console and enter this command: help uc_addictionactive 3

 

Let me know if it reports a value of 0.0 or a value of 1.0 (unless I'm misreading my code, you should only see the "no longer driven" message when it's 1.0, and the script sets it to 0.0 when it shows that to you).

 

Also, until I can find the bug causing that, you should be able to silence it by turning off the junk food addiction feature in MCM.

 

Edit: Oh, also, if you have Papyrus logging enabled, check your papyrus0.log for any lines containing "uc_" or "uc:" since if there are errors they should include the script namespace and/or reference names.

 

Moar edit: I see the problem! It's a basic logic error, I used a && where I should have had a || instead (total noob mistake, no excuse). *sigh* It's fixed in 1.3.1 available on the file page now. Sorry everybody!

Edited by vaultbait
Link to comment
5 hours ago, vaultbait said:

 

I'll admit I didn't put a ton of thought into what vanilla game and DLC items I did or didn't make influence body fat. Here's what it looks like in the script source (I'll include this in the next release):

 

    If Game.IsPluginInstalled("MAIM 2.esp")
        FatGainItems.AddForm(Game.GetFormFromFile(0x001029, "MAIM 2.esp") as Potion) ; Ibuprofen
        FatGainItems.AddForm(Game.GetFormFromFile(0x00102E, "MAIM 2.esp") as Potion) ; Atropine
        FatGainItems.AddForm(Game.GetFormFromFile(0x00162F, "MAIM 2.esp") as Potion) ; Mannitol Autoinjector

        FatLossItems.AddForm(Game.GetFormFromFile(0x001010, "MAIM 2.esp") as Potion) ; First Aid Kit
        FatLossItems.AddForm(Game.GetFormFromFile(0x001100, "MAIM 2.esp") as Potion) ; TXA Autoinjector
    EndIf

 

Here's the patched script recompiled, bundled as an installable mod so you can just drop it into your mod manager. Give it a try and let me know if it's working the way you want: Unhealthy Craving 1.3.1 MAIM 2 patch.7z (updated to patch 1.3.1 since I missed including it in that hasty release)

 

 

Right, it wasn't a goal to make all consumables influence body fat anyway, I just included some of what I thought of as likely to create some challenging situations from a gameplay standpoint.

 

 

These are the current vanilla game formlist items for direct fat gain and loss...

 

FatGainItems: Buffjet, Buffout, Bufftats, Calmex, CurieHealthpak, DayTripper, FoodPaste, MedX, Psychobuff, radscorpionVenom, Stimpak, XCell

 

FatLossItems: BerryMentats, BrainFungus, Bubblegum, CaveFungus, DaddyO, Fury, GlowingFungus, GrapeMentats, Herbal_Stimulant, Jet, JetFuel, Mentats, OrangeMentats, Overdrive, Psycho, PsychoJet, Psychotats, UltraJet, WaterPurified

 

I also soft-integrate inclusion of items from DLCs and some mods by adding them via script every time the game is loaded (in order to handle changes to mod lists), and long-running gain/loss effects from some mods like smoking, contraceptives, pregnancy, etc which just alter your metabolism in one direction or the other rather than directly adding or removing fat.

 

I remember deciding not to include rad meds and blood packs early on, but I don't exactly recall what my reasoning was now. I'll reconsider.

 

Thanks for the ideas!

 

(Sorry for long quote)

 

That's what I'm talking about! Thanks!

 

I've tested it thoroughly and can confirm it works as intended, no issues whatsoever! That being said, I found a pretty big problem (not related to UC though) - those IDs that I sent earlier are working for me because I ESLified MAIM 2. By default, MAIM 2 is ESP plugin, and I had to flag it as ESL due to heavy load order.

 

Other than that, this patch makes the game more challenging! When I first installed the patch, my character was Fat. Then, I got ambushed by a bunch of Gunners and at the end of pretty intense gunfight, my character was Morbidly Obese. I wouldn't necessarily call this immersive, but it is interesting and makes combat more high-risk (which I love).

 

That brings up the question - the patch (as well as UC) are currently v1.3.1; what about future releases? I wouldn't expect you to create the same patch for every new version of UC you release; there has to be a different approach to all this.

 

What would happen if you include all those MAIM 2 (ESL) IDs that I sent earlier in the script for the main version? Like, what would happen if you tell the script to search for those IDs that might not even exist in other players' load orders? Would that cause some issues or would it simply be ignored? Asking since I have 0 experience with Papyrus (keep telling myself to learn it but I just can't find the time to invest in learning it).

 

Once again, thanks for creating a patch and being lightspeed-fast for replying! Keep up the great work, your stuff is amazing!

 

Link to comment
4 hours ago, rubber_duck said:

those IDs that I sent earlier are working for me because I ESLified MAIM 2. By default, MAIM 2 is ESP plugin, and I had to flag it as ESL due to heavy load order.

 

Yes, that's going to be a problem. The IDs in the normal plugin for MAIM 2 will likely be different depending on how you compacted it. If it was done the way the CK handles it and those items were already within the allowed range for an ESL then it might still work since they'd still be the same, but it seems fairly unlikely that was the case. I can switch it up for whatever the IDs are in the non-ESLified, but if you're going to continue compacting that plugin then you'll need to patch and compile the script yourself in the future.

 

This also almost certainly explains why you were having trouble making a patch plugin... I'm fairly sure that an ESL or ESL-flagged ESP can't be a master.

Link to comment
4 hours ago, vaultbait said:

 

Yes, that's going to be a problem. The IDs in the normal plugin for MAIM 2 will likely be different depending on how you compacted it. If it was done the way the CK handles it and those items were already within the allowed range for an ESL then it might still work since they'd still be the same, but it seems fairly unlikely that was the case. I can switch it up for whatever the IDs are in the non-ESLified, but if you're going to continue compacting that plugin then you'll need to patch and compile the script yourself in the future.

 

This also almost certainly explains why you were having trouble making a patch plugin... I'm fairly sure that an ESL or ESL-flagged ESP can't be a master.

 

A way around this, and maybe even opening up the whole categorization of consumables to the user would be to read the form lists from a text file instead of defining them in CK or xEdit.

 

SUP F4SE has a function ReadFormArrayFromFile(string sFilePath,string sDelim)

-(form array)ReadFormArrayFromFile(string sFilePath,string sDelim)
populates array with forms from a file.
File is aaTest.txt and located in fallout 4 root folder File contents are:

Fallout4.esm:4822,Fallout4.esm:8E736,Fallout4.esm:59B27

Reference should be written this way "[MasterPlugin:FormID]"
Delimeters can be any symbol

Example
        form_Ar = ReadFormArrayFromFile("aaTest.txt",",")

form_Ar contents will be:
[0] - 10MM
[1] - Baseball bat
[2]  - Alarm clock

 

 

Link to comment
3 hours ago, LenAnderson said:

 

A way around this, and maybe even opening up the whole categorization of consumables to the user would be to read the form lists from a text file instead of defining them in CK or xEdit.

 

SUP F4SE has a function ReadFormArrayFromFile(string sFilePath,string sDelim)

-(form array)ReadFormArrayFromFile(string sFilePath,string sDelim)
populates array with forms from a file.
File is aaTest.txt and located in fallout 4 root folder File contents are:

Fallout4.esm:4822,Fallout4.esm:8E736,Fallout4.esm:59B27

Reference should be written this way "[MasterPlugin:FormID]"
Delimeters can be any symbol

Example
        form_Ar = ReadFormArrayFromFile("aaTest.txt",",")

form_Ar contents will be:
[0] - 10MM
[1] - Baseball bat
[2]  - Alarm clock

 

 

 

8 hours ago, vaultbait said:

 

Yes, that's going to be a problem. The IDs in the normal plugin for MAIM 2 will likely be different depending on how you compacted it. If it was done the way the CK handles it and those items were already within the allowed range for an ESL then it might still work since they'd still be the same, but it seems fairly unlikely that was the case. I can switch it up for whatever the IDs are in the non-ESLified, but if you're going to continue compacting that plugin then you'll need to patch and compile the script yourself in the future.

 

This also almost certainly explains why you were having trouble making a patch plugin... I'm fairly sure that an ESL or ESL-flagged ESP can't be a master.

 

I'm with @LenAnderson, implementing the mentioned SUP F4SE function (if possible) would be the best - I can then make my own file with required data (plugin and my FormID), that'd be pretty neat!

 

Regarding the ESL-flagged ESPs as masters... I'm pretty sure they can be masters. I have a mod that adds a few containers to Sanctuary and I've added some clothes to them (clothing mods are ESL-flagged ESPs in my load order) and they work with no issues. I event went as far as added a weapon (also ESL-flagged ESP) to one of them. This all means that I had to add those ESLified plugins as masters, and it works! MAIM 2, for some reason, does not. I can add it as master, but when I wanted to add some ingestibles added by it to one of the containers... I couldn't even find those ingestibles.

 

Now about recompiling the script - do I need CK or are there alternative ways? I've already installed VS Code extension that supports Papyrus and, if I'm not mistaken, allows me to compile the script.

 

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more information, see our Privacy Policy & Terms of Use