Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow bird wings to glide (redux) #70479

Merged
merged 58 commits into from
Jan 7, 2024
Merged
Show file tree
Hide file tree
Changes from 32 commits
Commits
Show all changes
58 commits
Select commit Hold shift + click to select a range
1260ed6
i hate github i hate github i hate github
worm-girl Dec 27, 2023
cd9f087
fixes, limb stuff
worm-girl Dec 27, 2023
629aedb
better limbs
worm-girl Dec 28, 2023
4e07323
improve limb stuff
worm-girl Dec 28, 2023
b88f127
limb balance
worm-girl Dec 28, 2023
d941d8a
fix checks for broken parts
worm-girl Jan 1, 2024
6d6477f
seat fixes
worm-girl Jan 1, 2024
89a44d2
fix stuff
worm-girl Jan 1, 2024
2ae0ace
stuff
worm-girl Jan 1, 2024
cc4bf9b
Update seats.json
worm-girl Jan 1, 2024
330f1fe
Update vehicle_parts.json
worm-girl Jan 1, 2024
e0e400a
Merge branch 'glidefix' of https://github.com/fairyarmadillo/Cataclys…
worm-girl Jan 1, 2024
fa8b6a0
fix insect wings
worm-girl Jan 1, 2024
daa8694
more stuff
worm-girl Jan 1, 2024
4030ccf
tailwind and circular distance
worm-girl Jan 1, 2024
eea7cb1
stumble
worm-girl Jan 2, 2024
479a49e
mut cleanup
worm-girl Jan 2, 2024
a833a79
lint etc
worm-girl Jan 2, 2024
00e01f0
veh_boost
worm-girl Jan 2, 2024
c190b65
Merge branch 'master' into glidefix
worm-girl Jan 2, 2024
96cd42f
astyle
worm-girl Jan 2, 2024
5012182
Merge branch 'glidefix' of https://github.com/fairyarmadillo/Cataclys…
worm-girl Jan 2, 2024
7d92547
Update data/json/mutations/mutation_limbs.json
worm-girl Jan 2, 2024
2cbb2f0
Update data/json/mutations/mutation_limbs.json
worm-girl Jan 2, 2024
c237ed0
Update data/json/mutations/mutation_limbs.json
worm-girl Jan 2, 2024
634b0a9
Update data/json/mutations/mutation_limbs.json
worm-girl Jan 2, 2024
998d515
Update mutation_limbs.json
worm-girl Jan 2, 2024
3c8c7a0
Merge branch 'glidefix' of https://github.com/fairyarmadillo/Cataclys…
worm-girl Jan 2, 2024
8e06a67
prosthetic stuff
worm-girl Jan 2, 2024
a6da2b3
Update prosthetics_eocs.json
worm-girl Jan 3, 2024
6401b93
make tests happy
worm-girl Jan 4, 2024
6f53e2e
improve combat interactions
worm-girl Jan 4, 2024
36728d1
Update src/activity_actor.cpp
worm-girl Jan 4, 2024
2c97c50
Update src/activity_actor.cpp
worm-girl Jan 4, 2024
8951513
Update src/activity_actor.cpp
worm-girl Jan 4, 2024
170fd9b
Update src/character.cpp
worm-girl Jan 4, 2024
0678c50
Update src/activity_actor.cpp
worm-girl Jan 4, 2024
af39bbf
make tests quiet
worm-girl Jan 4, 2024
04586fb
Update character.cpp
worm-girl Jan 5, 2024
1a4d82b
finishing touches
worm-girl Jan 5, 2024
65fc6d5
Update data/json/effects_on_condition/mutation_eocs/mutation_effect_e…
worm-girl Jan 5, 2024
f1fe579
Update mutation_effect_eocs.json
worm-girl Jan 5, 2024
a0a4f09
Merge branch 'glidefix' of https://github.com/fairyarmadillo/Cataclys…
worm-girl Jan 5, 2024
320635f
Update mutation_effect_eocs.json
worm-girl Jan 5, 2024
864eb24
Update iexamine.cpp
worm-girl Jan 5, 2024
2e02fb2
Merge branch 'master' into glidefix
worm-girl Jan 6, 2024
8344b36
Update player_activities.json
worm-girl Jan 6, 2024
b775f7f
Update mutations.json
worm-girl Jan 6, 2024
8fff15f
Update mutations.json
worm-girl Jan 6, 2024
c7de794
Update iexamine.cpp
worm-girl Jan 6, 2024
392c139
Update mutations.json
worm-girl Jan 6, 2024
78eda74
Update iexamine.cpp
worm-girl Jan 6, 2024
ad4ed68
Update character.cpp
worm-girl Jan 6, 2024
e305472
grab
worm-girl Jan 6, 2024
9f95b61
Update character.cpp
worm-girl Jan 6, 2024
9d48b00
fixes
worm-girl Jan 6, 2024
3bc3fe2
test fix
worm-girl Jan 7, 2024
555d5c2
add conditional flag
worm-girl Jan 7, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions data/json/effects.json
Original file line number Diff line number Diff line change
Expand Up @@ -4660,5 +4660,22 @@
"pain_max_val": [ 35 ]
},
"show_in_info": true
},
{
"type": "effect_type",
"id": "gliding",
"name": [ "Gliding" ],
"desc": [ "You are gliding through the air." ],
"flags": [ "GLIDING" ],
"rating": "good"
},
{
"type": "effect_type",
"id": "slow_descent",
"show_in_info": false,
"name": [ "Slow Descent" ],
"desc": [ "You are descending at a safe speed." ],
"flags": [ "FEATHER_FALL" ],
"max_duration": "1 s"
}
]
Original file line number Diff line number Diff line change
Expand Up @@ -685,5 +685,17 @@
"//": "will remove ink_gland_ink effect when the mutation is lost",
"condition": { "and": [ { "u_has_effect": "ink_gland_ink" }, { "compare_string": [ "INK_GLANDS", { "context_val": "trait" } ] } ] },
"effect": [ { "u_lose_effect": "ink_gland_ink" } ]
},
{
"type": "effect_on_condition",
"id": "EOC_insect_wings_shutoff",
"recurrence": [ "1 seconds", "1 seconds" ],
"condition": {
"and": [ { "compare_num": [ { "u_val": "stamina" }, "<", { "const": 3000 } ] }, { "u_has_trait": "WINGS_INSECT_active" } ]
},
worm-girl marked this conversation as resolved.
Show resolved Hide resolved
"effect": [
{ "u_activate_trait": "WINGS_INSECT_active" },
{ "u_message": "You don't have the stamina to keep buzzing.", "type": "bad" }
]
worm-girl marked this conversation as resolved.
Show resolved Hide resolved
}
]
Original file line number Diff line number Diff line change
Expand Up @@ -368,16 +368,7 @@
"and": [
{ "or": [ { "u_has_trait": "NO_LEFT_ARM" }, { "u_has_trait": "NO_RIGHT_ARM" } ] },
{
"and": [
{
"or": [
{ "u_has_trait": "INSECT_ARMS" },
{ "u_has_trait": "ARACHNID_ARMS" },
{ "u_has_trait": "AMORPHOUS" },
{ "u_has_trait": "ARM_TENTACLES" }
]
}
]
"and": [ { "or": [ { "u_has_trait": "AMORPHOUS" }, { "u_has_trait": "ARM_TENTACLES" }, { "u_has_trait": "WINGS_BIRD" } ] } ]
}
]
},
Expand Down
21 changes: 21 additions & 0 deletions data/json/enchantments.json
Original file line number Diff line number Diff line change
Expand Up @@ -195,5 +195,26 @@
"has": "WORN",
"condition": "ACTIVE",
"values": [ { "value": "FOOTSTEP_NOISE", "multiply": -0.67 } ]
},
{
"type": "enchantment",
"id": "ench_wings_bird",
"condition": "ALWAYS",
"modified_bodyparts": [
{ "lose": "arm_l" },
{ "lose": "arm_r" },
{ "lose": "hand_r" },
{ "lose": "hand_l" },
{ "gain": "wing_bird_l" },
{ "gain": "wing_bird_r" }
]
},
{
"id": "ench_wings_insect_active",
"type": "enchantment",
"name": { "str": "Insect Wings (Buzzing)" },
"description": "Your rapidly buzzing wings propel you with extra speed.",
"condition": "ALWAYS",
"values": [ { "value": "REGEN_STAMINA", "add": -110 } ]
}
]
2 changes: 1 addition & 1 deletion data/json/mutations/mutation_category.json
Original file line number Diff line number Diff line change
Expand Up @@ -281,7 +281,7 @@
"name": "Crustacean",
"threshold_mut": "THRESH_CRUSTACEAN",
"mutagen_message": "You suddenly want to burrow under some sand or find some nice rocky alcove to hide behind.",
"memorial_message": "Dreamed of walking along the sea floor",
"memorial_message": "Dreamed of walking along the sea floor.",
"vitamin": "mutagen_crustacean",
"base_removal_chance": 33,
"base_removal_cost_mul": 2.5
Expand Down
74 changes: 74 additions & 0 deletions data/json/mutations/mutation_limbs.json
Original file line number Diff line number Diff line change
Expand Up @@ -1017,5 +1017,79 @@
"sub_parts": [ "hand_wrist_l", "hand_palm_l", "hand_back_l", "hand_fingers_l" ],
"bmi_encumbrance_threshold": 0,
"bmi_encumbrance_scalar": 0
},
{
"id": "wing_bird_l",
"type": "body_part",
"name": "left wing",
"name_multiple": "left wings",
"accusative": { "ctxt": "bodypart_accusative", "str": "left wing" },
"accusative_multiple": { "ctxt": "bodypart_accusative", "str": "left wings" },
"heading": "l. wing",
"heading_multiple": "wings",
"encumbrance_text": "Melee combat is hampered.",
"hp_bar_ui_text": "L WING",
"main_part": "wing_bird_l",
"connected_to": "torso",
"opposite_part": "wing_bird_r",
"flags": [ "LIMB_UPPER" ],
"drench_capacity": 250,
"encumbrance_threshold": 20,
"hit_size": 0.9,
"hit_difficulty": 1.2,
"is_limb": true,
"limb_types": [ [ "arm", 0.7 ], [ "hand", 0.1 ] ],
"limb_scores": [
[ "grip", 0.3 ],
[ "manip", 0.38 ],
[ "lift", 0.42 ],
[ "balance", 0.2 ],
[ "block", 0.8 ],
[ "swim", 0.25 ],
[ "crawl", 0.3 ]
],
"smash_message": "You buffet the %s with your wing.",
"side": "left",
"base_hp": 45,
"sub_parts": [ "arm_shoulder_l", "arm_upper_l", "arm_elbow_l", "arm_lower_l", "hand_fingers_l", "hand_wrist_l" ],
"armor": { "cut": 3, "bash": 4 },
"unarmed_damage": [ { "damage_type": "bash", "amount": -2 } ]
},
{
"id": "wing_bird_r",
"type": "body_part",
"name": "right wing",
"name_multiple": "right wings",
"accusative": { "ctxt": "bodypart_accusative", "str": "right wing" },
"accusative_multiple": { "ctxt": "bodypart_accusative", "str": "right wings" },
"heading": "r. wing",
"heading_multiple": "wings",
"encumbrance_text": "Melee combat is hampered.",
"hp_bar_ui_text": "R WING",
"main_part": "wing_bird_r",
"connected_to": "torso",
"opposite_part": "wing_bird_l",
"flags": [ "LIMB_UPPER" ],
"drench_capacity": 250,
"encumbrance_threshold": 20,
"hit_size": 0.9,
"hit_difficulty": 1.2,
"is_limb": true,
"limb_types": [ [ "arm", 0.7 ], [ "hand", 0.1 ] ],
"limb_scores": [
[ "grip", 0.3 ],
[ "manip", 0.38 ],
[ "lift", 0.42 ],
[ "balance", 0.2 ],
[ "block", 0.8 ],
[ "swim", 0.25 ],
[ "crawl", 0.3 ]
],
"smash_message": "You buffet the %s with your wing.",
"side": "right",
"base_hp": 45,
"sub_parts": [ "arm_shoulder_r", "arm_upper_r", "arm_elbow_r", "arm_lower_r", "hand_fingers_r", "hand_wrist_r" ],
"armor": { "cut": 3, "bash": 4 },
"unarmed_damage": [ { "damage_type": "bash", "amount": -2 } ]
}
]
55 changes: 35 additions & 20 deletions data/json/mutations/mutations.json
Original file line number Diff line number Diff line change
Expand Up @@ -447,14 +447,14 @@
"allowed_items": [ "ARM_PROSTHETIC" ],
"enchantments": [ "ENCH_NO_LEFT_ARM" ],
"cancels": [
"ARM_FEATHERS",
"BARBS",
"NAILS",
"CLAWS",
"CLAWS_RAT",
"CLAWS_ST",
"CLAWS_RETRACT",
"CLAWS_TENTACLE",
"ARM_FEATHERS",
"TALONS",
"BENDY1",
"PAWS",
Expand All @@ -480,6 +480,7 @@
"allowed_items": [ "ARM_PROSTHETIC" ],
"enchantments": [ "ENCH_NO_RIGHT_ARM" ],
"cancels": [
"ARM_FEATHERS",
"CRUSTACEAN_CLAW",
"BARBS",
"NAILS",
Expand All @@ -489,7 +490,6 @@
"CLAWS_RETRACT",
"CLAWS_TENTACLE",
"TALONS",
"ARM_FEATHERS",
"BENDY1",
"PAWS",
"PAWS_LARGE",
Expand Down Expand Up @@ -5583,12 +5583,15 @@
"points": 2,
"visibility": 4,
"ugliness": 2,
"description": "You have a pair of large, feathered wings. Your body is too heavy to be able to fly, but you can use them to slow your descent during a fall, and will not take falling damage under any circumstances.",
"types": [ "WINGS" ],
"prereqs": [ "WINGS_STUB" ],
"description": "Your arms have mostly transformed into a huge pair of feathered wings. Though you retain a few fingers, your fine manipulation is greatly hampered. On the other hand, you can glide from ledges and will take less damage if you fall, provided you're healthy and unburdened.",
"types": [ "ARMS", "HANDS" ],
"enchantments": [ "ench_wings_bird" ],
"prereqs": [ "ARM_FEATHERS" ],
"prereqs2": [ "HOLLOW_BONES" ],
"threshreq": [ "THRESH_BIRD" ],
"category": [ "BIRD" ],
"flags": [ "WINGS_2" ]
"restricts_gear": [ "arm_l", "arm_r", "hand_l", "hand_r", "arm_stub_r", "arm_stub_l" ],
"flags": [ "WINGS_2", "WING_GLIDE" ]
},
{
"type": "mutation",
Expand All @@ -5597,17 +5600,26 @@
"points": 1,
"visibility": 4,
"ugliness": 4,
"description": "You have a pair of large, translucent wings. They are too small to lift you, but are powerful enough to greatly speed your movement, with some effort and noise.",
"description": "A large pair of translucent wings grow from your back. They are too small to lift you, but if you're not weighed down, they can help a bit if you fall. You can flutter them quickly to improve your move speed, but this is noisy and tires you out.",
"types": [ "WINGS" ],
"prereqs": [ "WINGS_STUB" ],
"category": [ "INSECT" ],
"restricts_gear": [ "torso" ],
"flags": [ "WINGS_1" ],
"active": true,
"cost": 3,
"time": "1 s",
"fatigue": true,
"kcal": true,
"thirst": true,
"movecost_modifier": 0.75
"transform": { "target": "WINGS_INSECT_active", "msg_transform": "You begin buzzing your wings.", "active": true, "moves": 20 }
},
{
"type": "mutation",
"id": "WINGS_INSECT_active",
"name": { "str": "Insect Wings (Buzzing)" },
"description": "You're fluttering your wings as fast as you can. This doesn't generate enough lift to move you, but it does increase your movement speed. If you're not burdened, you can fall short distances without harm.",
"copy-from": "WINGS_INSECT",
"valid": false,
"movecost_modifier": 0.75,
"flags": [ "WINGS_1", "MUSCLE_VEH_BOOST" ],
"enchantments": [ "ench_wings_insect_active" ],
"transform": { "target": "WINGS_INSECT", "msg_transform": "Your wings go still.", "active": false, "moves": 0 }
},
{
"type": "mutation",
Expand Down Expand Up @@ -6653,8 +6665,8 @@
"ugliness": 2,
"description": "You have a pair of stubby little wings projecting from your shoulderblades. They can be wiggled at will, but are useless.",
"types": [ "WINGS" ],
"changes_to": [ "WINGS_BIRD", "WINGS_BAT", "WINGS_INSECT", "WINGS_BUTTERFLY" ],
"category": [ "BIRD", "BEAST", "INSECT" ]
"changes_to": [ "WINGS_INSECT", "WINGS_BUTTERFLY", "WINGS_BAT" ],
"category": [ "INSECT", "BEAST" ]
},
{
"type": "mutation",
Expand Down Expand Up @@ -8058,19 +8070,22 @@
"type": "mutation",
"id": "ARM_FEATHERS",
"name": { "str": "Feathered Arms" },
"points": -2,
"points": 2,
"visibility": 8,
"ugliness": 2,
"description": "Your arms have grown vibrantly-colored feathers. They effectively waterproof your arms and take the edge off hits, but really get in the way. They're simply too small to help you in the air.",
"category": [ "RAPTOR" ],
"mixed_effect": true,
"description": "Your arms have sprouted feathers, and you find you can no longer fully extend your elbows. This gets in the way a bit, but the feathers offer minor protection from damage and the elements.",
"category": [ "RAPTOR", "BIRD" ],
"flags": [ "WINGS_1", "ARM_WINGS" ],
"changes_to": [ "WINGS_BIRD" ],
"wet_protection": [
{ "part": "arm_l", "neutral": 50 },
{ "part": "arm_r", "neutral": 50 },
{ "part": "hand_l", "neutral": 10 },
{ "part": "hand_r", "neutral": 10 }
],
"encumbrance_always": [ [ "arm_l", 20 ], [ "arm_r", 20 ] ],
"armor": [ { "parts": [ "arm_l", "arm_r" ], "bash": 1 } ]
"encumbrance_always": [ [ "arm_l", 8 ], [ "arm_r", 8 ] ],
"armor": [ { "parts": [ "arm_l", "arm_r" ], "bash": 1, "cut": 1 } ]
},
{
"type": "mutation",
Expand Down
11 changes: 11 additions & 0 deletions data/json/player_activities.json
Original file line number Diff line number Diff line change
Expand Up @@ -1123,5 +1123,16 @@
"interruptable": false,
"can_resume": false,
"interruptable_with_kb": false
},
{
"id": "ACT_GLIDE",
"type": "activity_type",
"activity_level": "NO_EXERCISE",
"verb": "gliding",
"based_on": "neither",
"interruptable": false,
"can_resume": false,
"refuel_fires": false,
"auto_needs": false
}
]
9 changes: 7 additions & 2 deletions doc/JSON_FLAGS.md
Original file line number Diff line number Diff line change
Expand Up @@ -360,6 +360,7 @@ Some armor flags, such as `WATCH` and `ALARMCLOCK` are compatible with other ite
- ```ACID_IMMUNE``` You are immune to acid damage.
- ```ALARMCLOCK``` You always can set alarms.
- ```ALBINO``` Cause you to have painful sunburns
- ```ARM_WINGS``` You have wings instead of regular arms
- ```BASH_IMMUNE``` You are immune to bashing damage.
- ```BG_OTHER_SURVIVORS_STORY``` Given to NPC when it has other survival story
- ```BG_SURVIVAL_STORY``` Given to NPC when it has a survival story
Expand Down Expand Up @@ -389,6 +390,8 @@ Some armor flags, such as `WATCH` and `ALARMCLOCK` are compatible with other ite
- ```FEATHER_FALL``` You are immune to fall damage.
- ```GILLS``` You can breathe underwater.
- ```GLARE_RESIST``` Protect your eyes from glare like sunglasses.
- ```GLIDE``` You can glide from ledges without the use of wings, as if by magic.
- ```GLIDING``` You are in the process of gliding.
- ```HARDTOHIT``` Whenever something attacks you, RNG gets rolled twice, and you get the better result.
- ```HEATSINK``` You are resistant to extreme heat.
- ```HEAT_IMMUNE``` Immune to very hot temperatures.
Expand All @@ -403,6 +406,7 @@ Some armor flags, such as `WATCH` and `ALARMCLOCK` are compatible with other ite
- ```INVISIBLE``` You can't be seen.
- ```LARGE``` Changes your size to `creature_size::large`. Checked third of the size category flags.
- ```MEND_ALL``` You need no splint to heal broken bones.
- ```MUSCLE_VEH_BOOST``` Something, such as buzzing insect wings, is speeding you up when you use a muscle-powered vehicle.
- ```MYCUS_IMMUNE``` Critter is immune to fungal hase field (`fd_fungal_haze`)
- ```MYOPIC_IN_LIGHT``` You are nearsighted in light, but can see normally in low-light conditions.
- ```MYOPIC``` You are nearsighted - vision range is severely reduced without glasses.
Expand Down Expand Up @@ -448,8 +452,9 @@ Some armor flags, such as `WATCH` and `ALARMCLOCK` are compatible with other ite
- ```WEBBED_FEET``` You have webbings on your feet, supporting your swimming speed if not wearing footwear.
- ```WEBBED_HANDS``` You have webbings on your hands, supporting your swimming speed.
- ```WEB_RAPPEL``` You can rappel down staircases and sheer drops of any height.
- ```WINGS_1``` You have 50% chance to ignore falling traps (including ledges).
- ```WINGS_2``` You have 100% chance to ignore falling traps (including ledges). Requires two flag instances.
- ```WINGS_1``` If you're not immobilized and have <50% burden, you reduce fall damage by 1 Z-level.
- ```WINGS_2``` If you're not immobilized and have <50% burden, you reduce fall damage by 2 Z-levels.
- ```WINGGLIDE``` You can glide using some part of your body and strenuous physical effort.
- ```mycus``` TBD


Expand Down
Loading
Loading