mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-13 08:03:43 +01:00
Bullets can now also miss, even after entering the same tile.
This means that aiming for the head with a gun only makes sense from a short distance or when the target is restrained. Otherwise, you're likely to miss unless aiming for the chest.
This commit is contained in:
@@ -113,9 +113,10 @@ emp_act
|
||||
/mob/living/carbon/human/proc/attacked_by(var/obj/item/I, var/mob/living/user, var/def_zone)
|
||||
if(!I || !user) return 0
|
||||
|
||||
var/target_zone = get_zone_with_miss_chance(user.zone_sel.selecting)
|
||||
var/target_zone = get_zone_with_miss_chance(user.zone_sel.selecting, src)
|
||||
if(!target_zone)
|
||||
visible_message("\red <B>[user] misses [src] with \the [I]!")
|
||||
return
|
||||
|
||||
var/datum/organ/external/affecting = get_organ(target_zone)
|
||||
if (!affecting)
|
||||
|
||||
@@ -165,12 +165,12 @@ proc/hasorgans(A)
|
||||
|
||||
// Emulates targetting a specific body part, and miss chances
|
||||
// May return null if missed
|
||||
/proc/get_zone_with_miss_chance(zone, var/mob/target)
|
||||
/proc/get_zone_with_miss_chance(zone, var/mob/target, var/miss_chance_mod = 0)
|
||||
zone = check_zone(zone)
|
||||
|
||||
// you can only miss if your target is standing and not restrained
|
||||
if(!target.buckled && !target.lying)
|
||||
var/miss_chance = 10
|
||||
var/miss_chance = 10 + miss_chance_mod
|
||||
switch(zone)
|
||||
if("head")
|
||||
miss_chance = 40
|
||||
|
||||
@@ -12,7 +12,7 @@ var/global/list/special_roles = list( //keep synced with the defines BE_* in set
|
||||
"pAI candidate" = 1, // -- TLE // 7
|
||||
"cultist" = IS_MODE_COMPILED("cult"), // 8
|
||||
"infested monkey" = IS_MODE_COMPILED("monkey"), // 9
|
||||
"space ninja" = "true", // 9
|
||||
"space ninja" = "true", // 10
|
||||
)
|
||||
|
||||
var/global/list/underwear_m = list("White", "Grey", "Green", "Blue", "Black", "Mankini", "Love-Hearts", "Black2", "Grey2", "Stripey", "Kinky", "None") //Curse whoever made male/female underwear diffrent colours
|
||||
|
||||
Reference in New Issue
Block a user