more fixes + fixes the last fixes.

This commit is contained in:
Seris02
2019-11-10 15:09:17 +08:00
parent 7dc22e3ae0
commit 99ea3f9b71
3 changed files with 29 additions and 36 deletions
+15 -19
View File
@@ -45,24 +45,18 @@
playsound(get_turf(A), 'sound/weapons/thudswoosh.ogg', 50, 1, -1)
D.apply_damage(5, BRUTE, BODY_ZONE_CHEST)
D.Knockdown(60)
if (H)
D.Move(H, get_dir(D,H))
var/L = H
for(var/obj/i in H.contents)
if(!istype(i,/mob) && i.density == 1)
L = D.loc
D.forceMove(L)
log_combat(A, D, "side kicked (Rising Bass)")
return 1
return basic_hit(A,D)
/datum/martial_art/the_rising_bass/proc/shoulderFlip(mob/living/carbon/human/A, mob/living/carbon/human/D)
if(!D.IsKnockdown() || !D.lying)
var/turf/H
switch(A.dir)
if(NORTH)
H = get_step(A,SOUTH)
if(EAST)
H = get_step(A,WEST)
if(SOUTH)
H = get_step(A,NORTH)
if(WEST)
H = get_step(A,EAST)
var/turf/H = get_step(A, get_dir(D,A))
var/L = H
for(var/obj/i in H.contents)
if(!istype(i,/mob) && i.density == 1)//(i.anchored == 1 && i.density == 1) || istype(i,/obj/structure) || istype(i,/turf/closed)
@@ -74,7 +68,7 @@
D.emote("scream")
D.apply_damage(10, BRUTE, BODY_ZONE_CHEST)
D.apply_damage(30, BRUTE, BODY_ZONE_HEAD)
D.SetSleeping(60)
D.Sleeping(60)
D.Knockdown(300)
D.forceMove(L)
log_combat(A, D, "shoulder flipped (Rising Bass)")
@@ -111,12 +105,14 @@
if(!D.IsKnockdown() || !D.lying)
if (D.get_active_held_item())
var/obj/item/G = D.get_active_held_item()
D.visible_message("<span class='warning'>[A] slaps [D]'s hands, taking [G] from them!</span>", \
"<span class='userdanger'>[A] slaps you, taking [G] from you!</span>")
D.temporarilyRemoveItemFromInventory(G, TRUE)
A.put_in_hands(G)
log_combat(A, D, "deft switched (Rising Bass)")
return 1
if (G && !(G.item_flags & (ABSTRACT|DROPDEL)) && D.temporarilyRemoveItemFromInventory(G))
A.put_in_hands(G)
D.visible_message("<span class='warning'>[A] slaps [D]'s hands, taking [G] from them!</span>", \
"<span class='userdanger'>[A] slaps you, taking [G] from you!</span>")
log_combat(A, D, "deft switched (Rising Bass)")
return 1
else
to_chat(A, "<i>[G] can't be taken out of [D]'s hands!<i>")
return 0
/datum/martial_art/the_rising_bass/disarm_act(mob/living/carbon/human/A, mob/living/carbon/human/D)
@@ -50,6 +50,9 @@
/mob/living/carbon/proc/can_catch_item(skip_throw_mode_check)
. = FALSE
if(mind)
if(mind.martial_art && mind.martial_art.dodge_chance == 100)
return TRUE
if(!skip_throw_mode_check && !in_throw_mode)
return
if(get_active_held_item())
@@ -63,6 +66,13 @@
if(can_catch_item())
if(istype(AM, /obj/item))
var/obj/item/I = AM
if (mind)
if (mind.martial_art && mind.martial_art.dodge_chance == 100) //autocatch for rising bass
if (get_active_held_item())
visible_message("<span class='warning'>[I] falls to the ground as [src] chops it out of the air!</span>")
return 1
if(!in_throw_mode)
throw_mode_on()
if(isturf(I.loc))
I.attack_hand(src)
if(get_active_held_item() == I) //if our attack_hand() picks up the item...
@@ -147,22 +147,7 @@
skipcatch = TRUE
blocked = TRUE
else if(I)
if (mind)
if (mind.martial_art && mind.martial_art.dodge_chance == 100) //autocatch for rising bass
if (get_active_held_item())
visible_message("<span class='warning'>[I] falls to the ground as [src] chops it out of the air!</span>")
return 1
else
if(!in_throw_mode)
throw_mode_on()
if(istype(AM, /obj/item))
if(isturf(I.loc))
I.attack_hand(src)
if(get_active_held_item() == I)
visible_message("<span class='warning'>[src] catches [I]!</span>")
throw_mode_off()
return 1
if(I.throw_speed >= EMBED_THROWSPEED_THRESHOLD)
if(I.throw_speed >= EMBED_THROWSPEED_THRESHOLD && !(mind.martial_art && mind.martial_art.dodge_chance == 100))
if(can_embed(I))
if(prob(I.embedding.embed_chance) && !HAS_TRAIT(src, TRAIT_PIERCEIMMUNE))
throw_alert("embeddedobject", /obj/screen/alert/embeddedobject)
@@ -175,7 +160,9 @@
SEND_SIGNAL(src, COMSIG_ADD_MOOD_EVENT, "embedded", /datum/mood_event/embedded)
hitpush = FALSE
skipcatch = TRUE //can't catch the now embedded item
if (mind)
if (mind.martial_art && mind.martial_art.dodge_chance == 100)
skipcatch = FALSE
return ..()
/mob/living/carbon/human/grabbedby(mob/living/carbon/user, supress_message = 0)