# Morale mod feasible via json only?

**URL:** <https://discourse.cataclysmdda.org/t/morale-mod-feasible-via-json-only/16436>\
**Category:** The Toolbox\
**Created:** [August 30, 2018, 4:21pm UTC](https://discourse.cataclysmdda.org/t/morale-mod-feasible-via-json-only/16436 "2018-08-30T16:21:03Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![dpwb](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/dpwb/32/2609_2.png) [@dpwb](https://discourse.cataclysmdda.org/u/dpwb)\
**Post date:** [August 30, 2018, 4:21pm UTC](https://discourse.cataclysmdda.org/t/morale-mod-feasible-via-json-only/16436/1 "2018-08-30T16:21:03Z")

</div>

I want to make a mod that makes morale far more important, essentially making joy activities an essential part of every day, or making friends with NPCs/pets.  
The idea being that if the mental wellbeing of your survivor is neglected for too long it has significant drawbacks.  
For some people this would be an annoying debuff chasing them, for others it might be an added challenge.  
I wonder if such a system, or simplified portions of it, are possible via json modding only?  
I look at other mods that affect morale, such as filthy clothing, and they appear to be partially hardcoded?  
Maybe a simple system to start off with, with two player traits “loner” or “social”  
“loner” has no morale debuff from not having pets or NPCs, and infact may have debuffs from having NPCs around  
“social” has morale debuff ( growing with time? ) for not having NPCs or pets, but will gain more joy from interacting with them.

Is any of this possible via json?

---

<div class="post-metadata">

**Author:** ![TheMurderUnicorn](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/themurderunicorn/32/5706_2.png) [@TheMurderUnicorn](https://discourse.cataclysmdda.org/u/TheMurderUnicorn)\
**Post date:** [August 30, 2018, 9:48pm UTC](https://discourse.cataclysmdda.org/t/morale-mod-feasible-via-json-only/16436/2 "2018-08-30T21:48:28Z")

</div>

I’m a baby coder – I don’t know nearly enough, so don’t take this as gospel but I do have a healthy bit of experience with the JSON at this point.

But no, I don’t think it’s doable in JSON. You’re talking about tracking player interactions with NPCs, proximity to NPCs, or at the very least a counter for how long it’s been since they last saw another human. These are things that, to my knowledge, would require code.

You can do other things with morale in JSON, with food or items, but I think what you’re talking about would require a compile. Again, I can’t say that 100%, but I’m pretty sure.

---

<div class="post-metadata">

**Author:** ![dpwb](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/dpwb/32/2609_2.png) [@dpwb](https://discourse.cataclysmdda.org/u/dpwb)\
**Post date:** [August 30, 2018, 10:24pm UTC](https://discourse.cataclysmdda.org/t/morale-mod-feasible-via-json-only/16436/3 "2018-08-30T22:24:12Z")

</div>

I thought that might be the case, items that have morale effects I can see in existing JSON, but checks for other game code - yeah.  
Well I was gonna have to learn C++ at some point anyway lol

---

<div class="post-metadata">

**Author:** ![dpwb](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/dpwb/32/2609_2.png) [@dpwb](https://discourse.cataclysmdda.org/u/dpwb)\
**Post date:** [August 31, 2018, 5:52pm UTC](https://discourse.cataclysmdda.org/t/morale-mod-feasible-via-json-only/16436/4 "2018-08-31T17:52:51Z")

</div>

> **[r/cataclysmdda - Whaleys Imaginary Friends](https://old.reddit.com/r/cataclysmdda/comments/9br7a7/whaleys_imaginary_friends/)**
>
> 39 votes and 7 comments so far on Reddit

ideas…ideas…
