Fix player controlled range hostiles mobs being unable to fire (#2928)

Pretty much fixes hostiles mobs that had a ranged attack being unable to use it if they are controlled by a player, so, we can have human controlled cavern dwellers and combat drones(in case of adminbus).

Also, fixes a broken design that needed mutagen and being able to transfer reagens to species without blood using an iv.
This commit is contained in:
Alberyk
2017-07-03 12:05:42 +03:00
committed by skull132
parent 13ceff816c
commit 6a26b8c1f3
3 changed files with 24 additions and 13 deletions
@@ -172,7 +172,7 @@
/mob/living/simple_animal/hostile/proc/OpenFire(target_mob)
var/target = target_mob
visible_message("<span class='warning'> <b>[src]</b> fires at [target]!</span>", 1)
visible_message("<span class='warning'> <b>[src]</b> fires at [target]!</span>")
if(rapid)
var/datum/callback/shoot_cb = CALLBACK(src, .proc/shoot_wrapper, target, loc, src)
@@ -217,6 +217,13 @@
return 1
return 0
/mob/living/simple_animal/hostile/RangedAttack(atom/A, params) //Player firing
if(ranged)
setClickCooldown(attack_delay)
target = A
OpenFire(A)
..()
/mob/living/simple_animal/hostile/proc/check_horde()
return 0
+1 -1
View File
@@ -535,7 +535,7 @@ datum/design/circuit/telepad
/datum/design/item/weapon/decloner
id = "decloner"
req_tech = list(TECH_COMBAT = 7, TECH_MATERIAL = 7, TECH_BIO = 5, TECH_POWER = 6)
materials = list("gold" = 5000,"uranium" = 10000, "mutagen" = 40)
materials = list("gold" = 5000,"uranium" = 10000)
build_path = /obj/item/weapon/gun/energy/decloner
sort_string = "TAAAE"