Skip to content

Commit

Permalink
JSONize size mutations, remove barefeet penalty, Ceph Gills fix (cata…
Browse files Browse the repository at this point in the history
…clysmbnteam#1486)

* Move behavior of more mutations to flags

* Whoops, forgot a flag

* astylin'

* Reversions per feedback

* Fix couple things I forgot earlier

* Suggestions per feedback

* Mod and doc update

* Update enchantment_test.cpp

* Start work on defining resize enum

* Update mutation.h

* Update mutation.h

* And finally get the enum actually compiling

Still unsure how to actually use it.

* Commit current WIP for now

* And commit current WIP

* Commit latest changes for feedback

Currently trying to load game will print the "Invalid m_size" error after a successful compile test.

* And now it all actually works

* Stylin' and other updoots

* Further fixes

* Update character.cpp

* Update monster.cpp

* Begone, lack of defaults

Fucking switch/cases

* I said begone

* Further fixes per feedback

* Suggestions per feedback

* Fix from Coolthulhu's findings
  • Loading branch information
chaosvolt authored Jun 7, 2022
1 parent b2083d2 commit c3ba2da
Show file tree
Hide file tree
Showing 29 changed files with 179 additions and 300 deletions.
4 changes: 4 additions & 0 deletions data/json/mutations/mutation_type.json
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,10 @@
"type": "mutation_type",
"id": "WINGS"
},
{
"type": "mutation_type",
"id": "SIZE"
},
{
"type": "mutation_type",
"id": "skin_tone"
Expand Down
51 changes: 25 additions & 26 deletions data/json/mutations/mutations.json
Original file line number Diff line number Diff line change
Expand Up @@ -238,16 +238,6 @@
"valid": false,
"cancels": [ "ILLITERATE", "SLOWREADER" ]
},
{
"type": "mutation",
"id": "TOUGH_FEET",
"name": { "str": "Tough Feet" },
"points": 1,
"description": "The bottoms of your feet are tough, and you are accustomed to going barefoot. You receive no movement penalty for not wearing shoes, and your feet are more resistant to damage.",
"armor": [ { "parts": [ "foot_l", "foot_r" ], "physical": 2, "acid": 2 } ],
"starting_trait": true,
"valid": false
},
{
"type": "mutation",
"id": "BOVINE_BULK",
Expand Down Expand Up @@ -2680,7 +2670,7 @@
"name": { "str": "Padded Feet" },
"points": 1,
"visibility": 1,
"description": "The bottoms of your feet are strongly padded. You receive no movement penalty for not wearing shoes, and even receive a 10% bonus when moving barefoot.",
"description": "The bottoms of your feet are strongly padded. If you're not wearing footwear, you'll receive a 10% bonus to movement speed.",
"types": [ "LEGS" ],
"category": [ "BEAST", "URSINE", "FELINE", "LUPINE" ]
},
Expand Down Expand Up @@ -2724,7 +2714,7 @@
"visibility": 2,
"ugliness": 2,
"mixed_effect": true,
"description": "Your feet have fused into hooves. This allows kicking attacks to do much more damage, provides natural armor, and removes the need to wear shoes; however, you cannot wear shoes of any kind. Reduces wet effects.",
"description": "Your feet have fused into hooves. This allows kicking attacks to do much more damage and provides natural armor; however, you cannot wear shoes of any kind. Reduces wet effects.",
"types": [ "LEGS" ],
"category": [ "CATTLE", "CHIMERA" ],
"wet_protection": [ { "part": "foot_l", "neutral": 10 }, { "part": "foot_r", "neutral": 10 } ],
Expand Down Expand Up @@ -3730,12 +3720,13 @@
"mixed_effect": true,
"encumbrance_always": [ [ "torso", 10 ], [ "arm_l", 10 ], [ "arm_r", 10 ] ],
"description": "You have grown noticeably taller and broader. Much of it is useful muscle mass (Strength +2), but you find it throws off your balance and you get in your own way (+10 torso and arm encumbrance).",
"types": [ "SIZE" ],
"prereqs": [ "STR_UP", "STR_UP_2", "STR_UP_3", "STR_UP_4" ],
"cancels": [ "SMALL", "SMALL2" ],
"changes_to": [ "LARGE_OK", "HUGE" ],
"category": [ "URSINE", "CATTLE", "LIZARD", "CHIMERA" ],
"passive_mods": { "str_mod": 2 },
"weight_capacity_modifier": 1.05
"weight_capacity_modifier": 1.05,
"body_size": "LARGE"
},
{
"type": "mutation",
Expand All @@ -3744,15 +3735,16 @@
"points": 2,
"visibility": 1,
"description": "You carry your rugged body with the dignity you deserve. Strength +2.",
"types": [ "SIZE" ],
"prereqs": [ "LARGE" ],
"prereqs2": [ "STR_UP", "STR_UP_2", "STR_UP_3", "STR_UP_4" ],
"cancels": [ "SMALL", "SMALL2" ],
"threshreq": [ "THRESH_URSINE", "THRESH_CATTLE", "THRESH_LIZARD", "THRESH_CHIMERA" ],
"changes_to": [ "HUGE" ],
"leads_to": [ "MUT_TOUGH" ],
"category": [ "URSINE", "CATTLE", "LIZARD", "CHIMERA" ],
"passive_mods": { "str_mod": 2 },
"weight_capacity_modifier": 1.05
"weight_capacity_modifier": 1.05,
"body_size": "LARGE"
},
{
"type": "mutation",
Expand All @@ -3763,16 +3755,17 @@
"ugliness": 4,
"mixed_effect": true,
"description": "You have grown even more massive, to the point where you cannot usefully fit into human-sized clothing or vehicles. Much of it is powerful muscle mass (Strength +4), but it's a real pain to haul around.",
"types": [ "SIZE" ],
"prereqs": [ "LARGE", "LARGE_OK" ],
"prereqs2": [ "STR_UP_3", "STR_UP_4" ],
"cancels": [ "SMALL", "SMALL2" ],
"changes_to": [ "HUGE_OK" ],
"category": [ "URSINE", "CATTLE" ],
"passive_mods": { "str_mod": 4 },
"hp_adjustment": -6,
"fatigue_modifier": 0.15,
"restricts_gear": [ "torso", "leg_l", "leg_r", "arm_l", "arm_r", "hand_l", "hand_r", "head", "foot_l", "foot_r" ],
"weight_capacity_modifier": 1.1
"weight_capacity_modifier": 1.1,
"body_size": "HUGE"
},
{
"type": "mutation",
Expand All @@ -3783,15 +3776,16 @@
"ugliness": 3,
"mixed_effect": true,
"description": "Your cardiovascular system has caught up with your muscular physique, so who needs pathetic human cars? Strength +4.",
"types": [ "SIZE" ],
"prereqs": [ "HUGE" ],
"prereqs2": [ "STR_UP_3", "STR_UP_4" ],
"cancels": [ "SMALL", "SMALL2" ],
"threshreq": [ "THRESH_URSINE", "THRESH_CATTLE" ],
"leads_to": [ "MUT_TOUGH" ],
"category": [ "URSINE", "CATTLE" ],
"passive_mods": { "str_mod": 4 },
"restricts_gear": [ "torso", "leg_l", "leg_r", "arm_l", "arm_r", "hand_l", "hand_r", "head", "foot_l", "foot_r" ],
"weight_capacity_modifier": 1.1
"weight_capacity_modifier": 1.1,
"body_size": "HUGE"
},
{
"type": "mutation",
Expand Down Expand Up @@ -4080,12 +4074,13 @@
"visibility": 5,
"mixed_effect": true,
"description": "You've noticeably shrunk in size. You're able to move with increased litheness, but your smaller stature prevents you from carrying as much.",
"cancels": [ "LARGE", "LARGE_OK", "HUGE", "HUGE_OK" ],
"types": [ "SIZE" ],
"changes_to": [ "SMALL2" ],
"category": [ "MOUSE" ],
"hp_modifier": -0.05,
"dodge_modifier": 1,
"weight_capacity_modifier": 0.8
"weight_capacity_modifier": 0.8,
"body_size": "SMALL"
},
{
"type": "mutation",
Expand All @@ -4095,14 +4090,16 @@
"visibility": 8,
"mixed_effect": true,
"description": "You're only half as tall as you used to be! The weight of things you once found easy to carry is now unbearable, clothes are now twice as encumbering for you unless you refit them (since you're half their size), and your hit points are heavily reduced. However, your movement is silent, and your dodge skill is a little higher.",
"types": [ "SIZE" ],
"prereqs": [ "SMALL" ],
"cancels": [ "LARGE", "LARGE_OK", "HUGE", "HUGE_OK", "LIGHTSTEP", "CLUMSY" ],
"cancels": [ "LIGHTSTEP", "CLUMSY" ],
"changes_to": [ "SMALL_OK" ],
"category": [ "MOUSE" ],
"hp_modifier": -0.3,
"dodge_modifier": 2,
"weight_capacity_modifier": 0.5,
"noise_modifier": 0.0
"noise_modifier": 0.0,
"body_size": "TINY"
},
{
"type": "mutation",
Expand All @@ -4111,16 +4108,18 @@
"points": 3,
"mixed_effect": true,
"description": "You've mastered your tiny form! Item encumbrance and carry weight penalties are reduced, and you've learned to use your increased nimbleness to offset your reduced capacity to absorb damage.",
"types": [ "SIZE" ],
"prereqs": [ "SMALL2" ],
"cancels": [ "LARGE", "LARGE_OK", "HUGE", "HUGE_OK", "LIGHTSTEP", "CLUMSY" ],
"cancels": [ "LIGHTSTEP", "CLUMSY" ],
"valid": false,
"purifiable": false,
"threshreq": [ "THRESH_MOUSE" ],
"category": [ "MOUSE" ],
"hp_modifier": -0.25,
"dodge_modifier": 2,
"weight_capacity_modifier": 0.7,
"noise_modifier": 0.0
"noise_modifier": 0.0,
"body_size": "TINY"
},
{
"type": "mutation",
Expand Down
1 change: 0 additions & 1 deletion data/json/npcs/starting_traits.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@
{ "trait": "SPIRITUAL", "prob": 10 },
{ "trait": "STYLISH", "prob": 10 },
{ "trait": "TERRIFYING", "prob": 10 },
{ "trait": "TOUGH_FEET", "prob": 10 },
{ "trait": "ALBINO", "prob": 1 },
{ "trait": "ASTHMA", "prob": 10 },
{ "trait": "CHEMIMBALANCE", "prob": 10 },
Expand Down
8 changes: 8 additions & 0 deletions data/json/obsoletion/mutations.json
Original file line number Diff line number Diff line change
Expand Up @@ -245,5 +245,13 @@
"active": true,
"starts_active": true,
"night_vision_range": 4.5
},
{
"type": "mutation",
"id": "TOUGH_FEET",
"name": { "str": "Tough Feet" },
"points": 1,
"description": "This mutation has been obsoleted due to the hidden movement speed penalty being removed. If you see this on a profession or mutate this trait, this is a bug.",
"valid": false
}
]
6 changes: 0 additions & 6 deletions data/mods/Aftershock/mutations/mutations.json
Original file line number Diff line number Diff line change
Expand Up @@ -327,12 +327,6 @@
{ "part": "torso", "neutral": 14 }
]
},
{
"type": "mutation",
"id": "TOUGH_FEET",
"copy-from": "TOUGH_FEET",
"extend": { "category": [ "MASTODON" ] }
},
{
"type": "mutation",
"id": "THICKSKIN",
Expand Down
Loading

0 comments on commit c3ba2da

Please sign in to comment.