tgstation/tgstation#39287 - Makes rapid fire mobs more configurable (#7549)
This commit is contained in:
@@ -48,7 +48,7 @@
|
||||
icon_living = "ranged"
|
||||
icon_dead = "ranged"
|
||||
ranged = 1
|
||||
rapid = 1
|
||||
rapid = 3
|
||||
retreat_distance = 5
|
||||
minimum_distance = 5
|
||||
|
||||
|
||||
@@ -5,7 +5,8 @@
|
||||
environment_smash = ENVIRONMENT_SMASH_STRUCTURES //Bitflags. Set to ENVIRONMENT_SMASH_STRUCTURES to break closets,tables,racks, etc; ENVIRONMENT_SMASH_WALLS for walls; ENVIRONMENT_SMASH_RWALLS for rwalls
|
||||
var/atom/target
|
||||
var/ranged = 0
|
||||
var/rapid = 0
|
||||
var/rapid = 0 //How many shots per volley.
|
||||
var/rapid_fire_delay = 2 //Time between rapid fire shots
|
||||
var/projectiletype //set ONLY it and NULLIFY casingtype var, if we have ONLY projectile
|
||||
var/projectilesound
|
||||
var/casingtype //set ONLY it and NULLIFY projectiletype, if we have projectile IN CASING
|
||||
@@ -330,11 +331,10 @@
|
||||
return
|
||||
visible_message("<span class='danger'><b>[src]</b> [ranged_message] at [A]!</span>")
|
||||
|
||||
if(rapid)
|
||||
if(rapid > 1)
|
||||
var/datum/callback/cb = CALLBACK(src, .proc/Shoot, A)
|
||||
addtimer(cb, 1)
|
||||
addtimer(cb, 4)
|
||||
addtimer(cb, 6)
|
||||
for(var/i in 1 to rapid)
|
||||
addtimer(cb, (i - 1)*rapid_fire_delay)
|
||||
else
|
||||
Shoot(A)
|
||||
ranged_cooldown = world.time + ranged_cooldown_time
|
||||
|
||||
@@ -53,7 +53,7 @@
|
||||
/mob/living/simple_animal/hostile/nanotrasen/ranged/smg
|
||||
icon_state = "nanotrasenrangedsmg"
|
||||
icon_living = "nanotrasenrangedsmg"
|
||||
rapid = 1
|
||||
rapid = 3
|
||||
casingtype = /obj/item/ammo_casing/c46x30mm
|
||||
projectilesound = 'sound/weapons/gunshot_smg.ogg'
|
||||
loot = list(/obj/item/gun/ballistic/automatic/wt550,
|
||||
|
||||
@@ -47,7 +47,7 @@
|
||||
icon_dead = "piratemelee_dead"
|
||||
projectilesound = 'sound/weapons/laser.ogg'
|
||||
ranged = 1
|
||||
rapid = 1
|
||||
rapid = 3
|
||||
retreat_distance = 5
|
||||
minimum_distance = 5
|
||||
projectiletype = /obj/item/projectile/beam/laser
|
||||
@@ -72,7 +72,7 @@
|
||||
icon_living = "piratespaceranged"
|
||||
projectilesound = 'sound/weapons/laser.ogg'
|
||||
ranged = 1
|
||||
rapid = 1
|
||||
rapid = 3
|
||||
retreat_distance = 5
|
||||
minimum_distance = 5
|
||||
projectiletype = /obj/item/projectile/beam/laser
|
||||
|
||||
@@ -64,7 +64,7 @@
|
||||
icon_state = "nanotrasenrangedsmg"
|
||||
icon_living = "nanotrasenrangedsmg"
|
||||
vision_range = 9
|
||||
rapid = 1
|
||||
rapid = 3
|
||||
ranged = 1
|
||||
retreat_distance = 3
|
||||
minimum_distance = 5
|
||||
|
||||
@@ -62,7 +62,7 @@
|
||||
icon_living = "russianofficer"
|
||||
maxHealth = 65
|
||||
health = 65
|
||||
rapid = 1
|
||||
rapid = 3
|
||||
casingtype = /obj/item/ammo_casing/c9mm
|
||||
loot = list(/obj/effect/mob_spawn/human/corpse/russian/ranged/officer,
|
||||
/obj/item/gun/ballistic/automatic/pistol/APS)
|
||||
|
||||
@@ -109,7 +109,7 @@
|
||||
|
||||
/mob/living/simple_animal/hostile/syndicate/ranged
|
||||
ranged = 1
|
||||
rapid = 1
|
||||
rapid = 3
|
||||
retreat_distance = 5
|
||||
minimum_distance = 5
|
||||
icon_state = "syndicateranged"
|
||||
|
||||
Reference in New Issue
Block a user