Skip to content

Commit

Permalink
Unhardcode and limbify attack vectors take two: Electric boogaloo (#7…
Browse files Browse the repository at this point in the history
…3064)

* WIP attack vector

* Version Two

* Getting there

* oop

* Deprecate, dewippify

* Aight clang, lemme have it

* Getting there

* Limb type restrictions

* BB

* Actually working substitutions

* Tests

* Tests, clang, magiclysm oopsies

* Tests

* ntegrated is def a word, shutup

* Mandatorify

* Fine, no mandatory

You get verified for that, mister
  • Loading branch information
Venera3 authored May 9, 2024
1 parent bf0f684 commit 8b49c2c
Show file tree
Hide file tree
Showing 41 changed files with 1,402 additions and 941 deletions.
123 changes: 123 additions & 0 deletions data/json/attack_vectors.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,123 @@
[
{
"type": "attack_vector",
"id": "vector_null",
"//": "Fallback weapon vector, unarmed attacks always go through techs",
"weapon": true
},
{
"type": "attack_vector",
"id": "test_test",
"limbs": [ "debug_tail" ],
"encumbrance_limit": 33,
"bp_hp_limit": 75
},
{
"type": "attack_vector",
"id": "vector_headbutt",
"limbs": [ "head" ],
"contact_area": [ "head_forehead" ],
"bp_hp_limit": 50
},
{
"type": "attack_vector",
"id": "vector_bite",
"limbs": [ "mouth" ],
"contact_area": [ "mouth_lips" ],
"encumbrance_limit": 1
},
{
"type": "attack_vector",
"id": "vector_punch",
"limbs": [ "hand_l", "hand_r" ],
"contact_area": [ "hand_fingers_l", "hand_fingers_r" ]
},
{
"type": "attack_vector",
"id": "vector_wrist",
"limbs": [ "hand_l", "hand_r" ],
"contact_area": [ "hand_wrist_l", "hand_wrist_r" ]
},
{
"type": "attack_vector",
"id": "vector_palm",
"limbs": [ "hand_l", "hand_r" ],
"contact_area": [ "hand_palm_l", "hand_palm_r" ]
},
{
"type": "attack_vector",
"id": "vector_grasp",
"limbs": [ "hand_l", "hand_r" ],
"contact_area": [ "hand_palm_l", "hand_palm_r" ],
"limb_req": [ [ "arm", 2 ] ],
"armor_bonus": false
},
{
"type": "attack_vector",
"id": "vector_backhand",
"limbs": [ "hand_l", "hand_r" ],
"contact_area": [ "hand_back_l", "hand_back_r" ]
},
{
"type": "attack_vector",
"id": "vector_shoulder",
"limbs": [ "arm_l", "arm_r" ],
"contact_area": [ "arm_shoulder_l", "arm_shoulder_r" ]
},
{
"type": "attack_vector",
"id": "vector_arm",
"limbs": [ "arm_l", "arm_r" ],
"contact_area": [ "arm_upper_r", "arm_elbow_r", "arm_lower_r", "arm_upper_l", "arm_elbow_l", "arm_lower_l" ]
},
{
"type": "attack_vector",
"id": "vector_arm_grapple",
"limbs": [ "arm_l", "arm_r" ],
"contact_area": [ "arm_upper_r", "arm_elbow_r", "arm_lower_r", "arm_upper_l", "arm_elbow_l", "arm_lower_l" ],
"armor_bonus": false,
"limb_req": [ [ "arm", 2 ] ]
},
{
"type": "attack_vector",
"id": "vector_elbow",
"limbs": [ "arm_l", "arm_r" ],
"contact_area": [ "arm_elbow_l", "arm_elbow_r" ]
},
{
"type": "attack_vector",
"id": "vector_foot_toes",
"limbs": [ "foot_l", "foot_r" ],
"contact_area": [ "foot_toes_l", "foot_toes_r" ],
"limb_req": [ [ "leg", 2 ] ]
},
{
"type": "attack_vector",
"id": "vector_foot_sole",
"limbs": [ "foot_l", "foot_r" ],
"contact_area": [ "foot_sole_l", "foot_sole_r" ],
"limb_req": [ [ "leg", 2 ] ]
},
{
"type": "attack_vector",
"id": "vector_foot_heel",
"limbs": [ "foot_l", "foot_r" ],
"contact_area": [ "foot_heel_l", "foot_heel_r" ],
"limb_req": [ [ "leg", 2 ] ]
},
{
"type": "attack_vector",
"id": "vector_knee",
"limbs": [ "leg_l", "leg_r" ],
"contact_area": [ "leg_knee_l", "leg_knee_r" ],
"limb_req": [ [ "leg", 2 ] ]
},
{
"type": "attack_vector",
"id": "vector_shin",
"limbs": [ "leg_l", "leg_r" ],
"contact_area": [ "leg_lower_l", "leg_lower_r" ],
"bp_hp_limit": 50,
"limb_req": [ [ "leg", 2 ] ]
}
]
3 changes: 2 additions & 1 deletion data/json/bionics.json
Original file line number Diff line number Diff line change
Expand Up @@ -1417,7 +1417,8 @@
"description": "You possess razor-sharp claws underneath your fingernails that do a small amount of unarmed slashing damage whenever your fingertips are uncovered.",
"occupied_bodyparts": [ [ "hand_l", 1 ], [ "hand_r", 1 ] ],
"passive_pseudo_items": [ "fake_razor" ],
"flags": [ "BIONIC_NPC_USABLE" ]
"flags": [ "BIONIC_NPC_USABLE" ],
"enchantments": [ { "condition": { "not": "u_has_weapon" }, "values": [ { "value": "ITEM_DAMAGE_STAB", "add": 2 } ] } ]
},
{
"id": "bio_recycler",
Expand Down
7 changes: 7 additions & 0 deletions data/json/body_parts.json
Original file line number Diff line number Diff line change
Expand Up @@ -228,6 +228,7 @@
"base_hp": 60,
"drench_capacity": 700,
"smash_message": "You smash the %s with a firm headbutt.",
"techniques": [ "tech_base_headbutt" ],
"smash_efficiency": 0.25,
"bionic_slots": 18,
"flags": [ "LIMB_UPPER" ],
Expand Down Expand Up @@ -550,6 +551,7 @@
"limb_scores": [ [ "grip", 0.5 ], [ "manip", 0.5, 1.0 ], [ "swim", 0.15 ] ],
"side": "left",
"legacy_id": "HAND_L",
"techniques": [ "tech_base_punch" ],
"stylish_bonus": 0.5,
"hot_morale_mod": 0.5,
"cold_morale_mod": 0.5,
Expand Down Expand Up @@ -581,6 +583,7 @@
"limb_scores": [ [ "grip", 0.5 ], [ "manip", 0.5, 1.0 ], [ "swim", 0.15 ] ],
"side": "right",
"legacy_id": "HAND_R",
"techniques": [ "tech_base_punch" ],
"stylish_bonus": 0.5,
"hot_morale_mod": 0.5,
"cold_morale_mod": 0.5,
Expand Down Expand Up @@ -809,6 +812,7 @@
"base_hp": 60,
"drench_capacity": 300,
"smash_message": "You kick down the %s, smashing it.",
"techniques": [ "tech_base_kick" ],
"bionic_slots": 7,
"sub_parts": [ "foot_sole_l", "foot_arch_l", "foot_toes_l", "foot_ankle_l", "foot_heel_l" ],
"flags": [ "LIMB_LOWER" ],
Expand Down Expand Up @@ -842,6 +846,8 @@
"base_hp": 60,
"drench_capacity": 300,
"smash_message": "You kick down the %s, smashing it.",
"technique_encumbrance_limit": 40,
"techniques": [ "tech_base_kick" ],
"bionic_slots": 7,
"sub_parts": [ "foot_sole_r", "foot_arch_r", "foot_toes_r", "foot_ankle_r", "foot_heel_r" ],
"flags": [ "LIMB_LOWER" ],
Expand Down Expand Up @@ -870,6 +876,7 @@
"accusative": { "ctxt": "bodypart_accusative", "str": "debug tail" },
"hp_bar_ui_text": "DBG TAIL",
"base_hp": 20,
"health_limit": 5,
"flags": [ "ALWAYS_BLOCK", "NONSTANDARD_BLOCK", "MEND_LIMB", "WALL_CLING" ],
"armor": { "bash": 10 },
"unarmed_damage": [ { "damage_type": "acid", "amount": 10 }, { "damage_type": "bullet", "amount": 5, "armor_penetration": 100 } ],
Expand Down
36 changes: 14 additions & 22 deletions data/json/items/armor/integrated.json
Original file line number Diff line number Diff line change
Expand Up @@ -1531,10 +1531,7 @@
"encumbrance": 1
}
],
"melee_damage": { "cut": 9 },
"relic_data": {
"passive_effects": [ { "has": "WORN", "condition": { "not": "u_has_weapon" }, "values": [ { "value": "ATTACK_SPEED", "add": -20 } ] } ]
}
"melee_damage": { "cut": 9 }
},
{
"id": "integrated_claws_rat",
Expand All @@ -1560,10 +1557,7 @@
"encumbrance": 3
}
],
"melee_damage": { "cut": 10 },
"relic_data": {
"passive_effects": [ { "has": "WORN", "condition": { "not": "u_has_weapon" }, "values": [ { "value": "ATTACK_SPEED", "add": -20 } ] } ]
}
"melee_damage": { "cut": 10 }
},
{
"id": "integrated_claws_st",
Expand All @@ -1589,10 +1583,7 @@
"encumbrance": 5
}
],
"melee_damage": { "cut": 11 },
"relic_data": {
"passive_effects": [ { "has": "WORN", "condition": { "not": "u_has_weapon" }, "values": [ { "value": "ATTACK_SPEED", "add": -20 } ] } ]
}
"melee_damage": { "cut": 11 }
},
{
"id": "integrated_talons",
Expand All @@ -1618,10 +1609,7 @@
"encumbrance": 7
}
],
"melee_damage": { "cut": 16 },
"relic_data": {
"passive_effects": [ { "has": "WORN", "condition": { "not": "u_has_weapon" }, "values": [ { "value": "ATTACK_SPEED", "add": -20 } ] } ]
}
"melee_damage": { "cut": 16 }
},
{
"id": "integrated_fangs",
Expand All @@ -1638,16 +1626,18 @@
"color": "white",
"warmth": 5,
"qualities": [ [ "CUT", 2 ], [ "BUTCHER", 4 ] ],
"techniques": [ "FANGS_BITE", "FANGS_BITE_NATURAL" ],
"techniques": [ "FANGS_BITE", "FANGS_BITE_NATURAL", "FANGS_BITE_CRIT" ],
"flags": [ "INTEGRATED", "ALLOWS_NATURAL_ATTACKS", "UNBREAKABLE", "PERSONAL", "PADDED", "PROVIDES_TECHNIQUES" ],
"armor": [
{
"material": [ { "type": "bone", "covered_by_mat": 100, "thickness": 3.2 } ],
"covers": [ "mouth" ],
"coverage": 0,
"specifically_covers": [ "mouth_lips" ],
"coverage": 100,
"encumbrance": 0
}
]
],
"melee_damage": { "stab": 9 }
},
{
"id": "integrated_vampire_fangs",
Expand All @@ -1664,15 +1654,17 @@
"color": "white",
"warmth": 5,
"qualities": [ [ "CUT", 2 ], [ "BUTCHER", 4 ] ],
"techniques": [ "VAMPIRE_BITE", "VAMPIRE_BITE_NATURAL" ],
"techniques": [ "VAMPIRE_BITE", "VAMPIRE_BITE_NATURAL", "VAMPIRE_BITE_CRIT" ],
"flags": [ "INTEGRATED", "ALLOWS_NATURAL_ATTACKS", "UNBREAKABLE", "PERSONAL", "PADDED", "PROVIDES_TECHNIQUES" ],
"armor": [
{
"material": [ { "type": "bone", "covered_by_mat": 100, "thickness": 3.2 } ],
"covers": [ "mouth" ],
"coverage": 0,
"specifically_covers": [ "mouth_lips" ],
"coverage": 100,
"encumbrance": 0
}
]
],
"melee_damage": { "stab": 15 }
}
]
Loading

0 comments on commit 8b49c2c

Please sign in to comment.