Skip to content

Commit 1ed8dde

Browse files
authored
skill tweaks (#1111)
1 parent 9e6f4bc commit 1ed8dde

25 files changed

+40
-50
lines changed

code/datums/components/embedded.dm

+3-2
Original file line numberDiff line numberDiff line change
@@ -238,15 +238,16 @@
238238
if(harmful && user.stats.cooldown_finished("ripout_embed_check"))
239239
user.stats.set_cooldown("ripout_embed_check", INFINITY)
240240
var/datum/roll_result/result = user.stat_roll(12, /datum/rpg_skill/handicraft)
241+
result.do_skill_sound(user)
241242
switch(result.outcome)
242243
if(CRIT_SUCCESS)
243244
harmful = FALSE
244245
time_taken = 0
245-
to_chat(user, result.create_tooltip("Many hours spent on delicate projects has prepared you for this moment. (Instant and harmless removal)"))
246+
to_chat(user, result.create_tooltip("Many hours spent on delicate projects has prepared you for this moment."))
246247

247248
if(SUCCESS)
248249
time_taken = time_taken * 0.2
249-
to_chat(user, result.create_tooltip("Your hands are more than accustomed to careful tasks. (Accelerated removal)"))
250+
to_chat(user, result.create_tooltip("Your hands are more than accustomed to careful tasks."))
250251

251252
if(CRIT_FAILURE)
252253
to_chat(user, result.create_tooltip("At a crucial moment, you second guess yourself, pressing the object deeper into your flesh."))

code/game/objects/items.dm

+4-2
Original file line numberDiff line numberDiff line change
@@ -1338,10 +1338,12 @@ DEFINE_INTERACTABLE(/obj/item)
13381338
var/datum/roll_result/result = user.stat_roll(7, /datum/rpg_skill/handicraft)
13391339
switch(result.outcome)
13401340
if(CRIT_SUCCESS)
1341-
to_chat(user, result.create_tooltip("A swift execution. A job well done. (Tool usage time reduced)"))
1341+
result.do_skill_sound(user)
1342+
to_chat(user, result.create_tooltip("A swift execution. A job well done."))
13421343
delay = delay * 0.25
13431344

1344-
user.stats.set_cooldown("use_tool", max(delay, 5 SECONDS))
1345+
1346+
user.stats.set_cooldown("use_tool", max(delay, 10 SECONDS))
13451347

13461348
// Play tool sound at the beginning of tool usage.
13471349
play_tool_sound(target, volume)

code/modules/detectivework/detective_work.dm

+1
Original file line numberDiff line numberDiff line change
@@ -237,6 +237,7 @@
237237
stats.set_cooldown("examine_forensic_analysis", 15 SECONDS)
238238
return
239239

240+
result.do_skill_sound(src)
240241
stats.examined_object_weakrefs[WEAKREF(examined)] = TRUE
241242
stats.set_cooldown("examine_forensic_analysis", 15 MINUTES)
242243

code/modules/mob/living/carbon/carbon_defense.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -250,7 +250,7 @@
250250

251251
var/list/holding = list(target.get_active_held_item() = 60, target.get_inactive_held_item() = 30)
252252

253-
var/roll = stat_roll(10, /datum/rpg_skill/skirmish).outcome
253+
var/roll = stat_roll(14, /datum/rpg_skill/skirmish, defender = target).outcome
254254

255255
//Handle unintended consequences
256256
for(var/obj/item/I in holding)

code/modules/mob/living/carbon/human/death.dm

-10
Original file line numberDiff line numberDiff line change
@@ -49,16 +49,6 @@ GLOBAL_LIST_EMPTY(dead_players_during_shift)
4949
SSblackbox.ReportDeath(src)
5050
log_message("has died (BRUTE: [src.getBruteLoss()], BURN: [src.getFireLoss()], TOX: [src.getToxLoss()], OXY: [src.getOxyLoss()], CLONE: [src.getCloneLoss()])", LOG_ATTACK)
5151

52-
for(var/mob/living/L in viewers(src, world.view) - src)
53-
if(L.is_blind() || L.stat != CONSCIOUS || !L.client)
54-
continue
55-
56-
var/datum/roll_result/result = L.stat_roll(7, /datum/rpg_skill/willpower)
57-
switch(result.outcome)
58-
if(FAILURE, CRIT_FAILURE)
59-
if(L.apply_status_effect(/datum/status_effect/skill_mod/witness_death))
60-
to_chat(L, result.create_tooltip("For but a moment, there is nothing. Nothing but the gnawing realisation of what you have just witnessed."))
61-
6252
/mob/living/carbon/human/proc/makeSkeleton()
6353
ADD_TRAIT(src, TRAIT_DISFIGURED, TRAIT_GENERIC)
6454
set_species(/datum/species/skeleton)

code/modules/mob/living/carbon/human/examine.dm

+2-1
Original file line numberDiff line numberDiff line change
@@ -374,11 +374,12 @@
374374

375375
var/possible_invisible_damage = getToxLoss() > 20 || getBrainLoss()
376376

377-
if((possible_invisible_damage || length(fucked_reasons) || visible_bodyparts >= 3))
377+
if(!length(get_missing_limbs()) && (possible_invisible_damage || length(fucked_reasons) || visible_bodyparts >= 3))
378378
var/datum/roll_result/result = living_user.stat_roll(15, /datum/rpg_skill/anatomia)
379379
switch(result.outcome)
380380
if(SUCCESS, CRIT_SUCCESS)
381381
spawn(0)
382+
result.do_skill_sound(living_user)
382383
if(possible_invisible_damage && living_user.stats.cooldown_finished("found_invisible_damage_[REF(src)]"))
383384
to_chat(living_user, result.create_tooltip("Something is not right, this person is not well. You can feel it in your very core."))
384385
living_user.stats.set_cooldown("found_invisible_damage_[REF(src)]", INFINITY) // Never again

code/modules/mob/living/carbon/human/human.dm

+4-4
Original file line numberDiff line numberDiff line change
@@ -530,6 +530,10 @@
530530
if (!do_after(src, target, 3 SECONDS, DO_PUBLIC, extra_checks = CALLBACK(src, PROC_REF(can_perform_cpr), target)))
531531
break
532532

533+
visible_message(
534+
span_notice("[src] pushes down on [target.name]'s chest!"),
535+
)
536+
533537
var/datum/roll_result/result = stat_roll(6, /datum/rpg_skill/skirmish)
534538
switch(result.outcome)
535539
if(CRIT_SUCCESS)
@@ -547,10 +551,6 @@
547551
if(chest.break_bones(TRUE))
548552
to_chat(src, result.create_tooltip("Your strength betrays you as you shatter [target.name]'s [chest.encased]."))
549553

550-
visible_message(
551-
span_notice("[src] pushes down on [target.name]'s chest!"),
552-
)
553-
554554
log_combat(src, target, "CPRed")
555555

556556
if(target.breathe(TRUE) == BREATH_OKAY)

code/modules/mob/living/carbon/human/human_defense.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@
185185
if(HAS_TRAIT(user, TRAIT_PERFECT_ATTACKER))
186186
roll = SUCCESS
187187
else
188-
roll = user.stat_roll(10, /datum/rpg_skill/skirmish, bodyzone_modifier, -7).outcome
188+
roll = user.stat_roll(10, /datum/rpg_skill/skirmish, bodyzone_modifier, -7, src).outcome
189189

190190
var/hit_zone
191191
switch(roll)

code/modules/mob/living/carbon/human/species.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -1050,7 +1050,7 @@ GLOBAL_LIST_EMPTY(features_by_species)
10501050
// Set damage and find hit bodypart using weighted rng
10511051
var/target_zone = deprecise_zone(user.zone_selected)
10521052
var/bodyzone_modifier = GLOB.bodyzone_gurps_mods[target_zone]
1053-
var/roll = !HAS_TRAIT(user, TRAIT_PERFECT_ATTACKER) ? user.stat_roll(10, /datum/rpg_skill/skirmish, bodyzone_modifier, -7).outcome : SUCCESS
1053+
var/roll = !HAS_TRAIT(user, TRAIT_PERFECT_ATTACKER) ? user.stat_roll(10, /datum/rpg_skill/skirmish, bodyzone_modifier, -7, target).outcome : SUCCESS
10541054
// If we succeeded, hit the target area.
10551055
var/attacking_zone = (roll >= SUCCESS) ? target_zone : target.get_random_valid_zone()
10561056
var/obj/item/bodypart/affecting

code/modules/mob/living/carbon/human/status_procs.dm

-12
Original file line numberDiff line numberDiff line change
@@ -38,15 +38,3 @@
3838
. = ..()
3939
if(.)
4040
update_body_parts()
41-
42-
/mob/living/carbon/human/fakedeath(source, silent)
43-
. = ..()
44-
for(var/mob/living/L in viewers(src, world.view) - src)
45-
if(L.is_blind() || L.stat != CONSCIOUS || !L.client)
46-
continue
47-
48-
var/datum/roll_result/result = L.stat_roll(6, /datum/rpg_skill/willpower)
49-
switch(result.outcome)
50-
if(FAILURE, CRIT_FAILURE)
51-
if(L.apply_status_effect(/datum/status_effect/skill_mod/witness_death))
52-
to_chat(L, result.create_tooltip("For but a moment, there is nothing. Nothing but the gnawing realisation of what you have just witnessed."))

code/modules/mob/living/carbon/pain.dm

+3-4
Original file line numberDiff line numberDiff line change
@@ -186,15 +186,14 @@
186186
var/datum/roll_result/result = stat_roll(12, /datum/rpg_skill/willpower)
187187
switch(result.outcome)
188188
if(CRIT_SUCCESS)
189-
190-
to_chat(src, result.create_tooltip("Pain is temporary, I will not die on this day! (Shock reduced)"))
189+
to_chat(src, result.create_tooltip("Pain is temporary, I will not die on this day!"))
191190
shock_stage = max(shock_stage - 15, 0)
192191
stats.set_cooldown("shrug_off_pain", 180 SECONDS)
193192
return
194193

195194
if(SUCCESS)
196195
shock_stage = max(shock_stage - 5, 0)
197-
to_chat(src, result.create_tooltip("Not here, not now. (Pain shrugged off)"))
196+
to_chat(src, result.create_tooltip("Not here, not now."))
198197
stats.set_cooldown("shrug_off_pain", 180 SECONDS)
199198
return
200199

@@ -204,7 +203,7 @@
204203

205204
if(CRIT_FAILURE)
206205
shock_stage = min(shock_stage + 1, SHOCK_MAXIMUM)
207-
to_chat(src, result.create_tooltip("I'm going to die here. (Shock increased)"))
206+
to_chat(src, result.create_tooltip("I'm going to die here."))
208207
stats.set_cooldown("shrug_off_pain", 60 SECONDS)
209208
// Do not return
210209

code/modules/surgery/new_surgery/_surgery_step.dm

+1
Original file line numberDiff line numberDiff line change
@@ -395,6 +395,7 @@ GLOBAL_LIST_INIT(surgery_tool_exceptions, typecacheof(list(
395395
can_loop = TRUE
396396
else
397397
step.fail_step(user, target, zone, src)
398+
result.do_skill_sound(user)
398399

399400
else if(!(QDELING(user) || QDELING(target) || QDELING(src)))
400401
step.fail_step(user, target, zone, src)

code/modules/three_dsix/roll.dm

+9-6
Original file line numberDiff line numberDiff line change
@@ -152,19 +152,22 @@ GLOBAL_DATUM_INIT(success_roll, /datum/roll_result/success, new)
152152

153153
return "[prefix] <span data-component=\"Tooltip\" data-innerhtml=\"[tooltip_html]\" class=\"tooltip\">[finished_prob_string]</span>[seperator][body]"
154154

155+
/// Play
156+
/datum/roll_result/proc/do_skill_sound(mob/user)
157+
if(isnull(skill_type_used))
158+
return
159+
160+
var/datum/rpg_stat/stat_path = initial(skill_type_used.parent_stat_type)
161+
var/sound_path = initial(stat_path.sound)
162+
SEND_SOUND(user, sound(sound_path))
163+
155164
/datum/roll_result/success
156165
outcome = SUCCESS
157166
success_prob = 100
158167
crit_success_prob = 0
159168
roll = 18
160169
requirement = 3
161170

162-
/mob/living/verb/testroll()
163-
name = "testroll"
164-
165-
var/datum/roll_result/result = stat_roll(11, /datum/rpg_skill/skirmish)
166-
to_chat(usr, result.create_tooltip("This message is a test, and not indicative of the final product."))
167-
168171
/// Returns a number between 0 and 100 to roll the desired value when rolling the given dice.
169172
/proc/dice_probability(num, sides, desired)
170173
var/static/list/outcomes_cache = new /list(0, 0)

code/modules/three_dsix/skills/coordination.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
name = "Handicraft"
33
desc = "Control and manipulate, with style."
44

5-
parent_stat_type = /datum/rpg_stat/motorics
5+
parent_stat_type = /datum/rpg_stat/kinesis
66

77
/datum/rpg_skill/handicraft/get(mob/living/user)
88
. = ..()

code/modules/three_dsix/stats/_stat.dm

+2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@
66
var/value = STATS_BASELINE_VALUE
77
var/list/modifiers
88

9+
var/sound
10+
911
/datum/rpg_stat/proc/get(mob/living/user)
1012
return value - STATS_BASELINE_VALUE
1113

code/modules/three_dsix/stats/motorics.dm code/modules/three_dsix/stats/kinesis.dm

+4-3
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
1-
/datum/rpg_stat/motorics
2-
name = "Motorics"
1+
/datum/rpg_stat/kinesis
2+
name = "kinesis"
33
desc = ""
44

55
value = STATS_BASELINE_VALUE
6+
sound = 'sound/three_dsix/kinesis.ogg'
67

7-
/datum/rpg_stat/motorics/get(mob/living/user)
8+
/datum/rpg_stat/kinesis/get(mob/living/user)
89
. = ..()
910
if(!iscarbon(user))
1011
return

code/modules/three_dsix/stats/psyche.dm

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
desc = ""
44

55
value = STATS_BASELINE_VALUE
6-
6+
sound = 'sound/three_dsix/psyche.ogg'
77

88
/datum/rpg_stat/psyche/get(mob/living/user)
99
. = ..()

code/modules/three_dsix/stats/soma.dm

+1
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,4 @@
33
desc = ""
44

55
value = STATS_BASELINE_VALUE
6+
sound = 'sound/three_dsix/soma.ogg'

daedalus.dme

+1-1
Original file line numberDiff line numberDiff line change
@@ -4491,7 +4491,7 @@
44914491
#include "code\modules\three_dsix\skills\skirmish.dm"
44924492
#include "code\modules\three_dsix\skills\willpower.dm"
44934493
#include "code\modules\three_dsix\stats\_stat.dm"
4494-
#include "code\modules\three_dsix\stats\motorics.dm"
4494+
#include "code\modules\three_dsix\stats\kinesis.dm"
44954495
#include "code\modules\three_dsix\stats\psyche.dm"
44964496
#include "code\modules\three_dsix\stats\soma.dm"
44974497
#include "code\modules\tooltip\tooltip.dm"

sound/three_dsix/kinesis.ogg

57.5 KB
Binary file not shown.

sound/three_dsix/pneuma.ogg

99.1 KB
Binary file not shown.

sound/three_dsix/psyche.ogg

104 KB
Binary file not shown.

sound/three_dsix/roll_fail.ogg

147 KB
Binary file not shown.

sound/three_dsix/roll_success.ogg

101 KB
Binary file not shown.

sound/three_dsix/soma.ogg

119 KB
Binary file not shown.

0 commit comments

Comments
 (0)