Hmm
This commit is contained in:
@@ -1,299 +1,299 @@
|
|||||||
#define MINER_DASH_RANGE 4
|
#define MINER_DASH_RANGE 4
|
||||||
|
|
||||||
/*
|
/*
|
||||||
BLOOD-DRUNK MINER
|
BLOOD-DRUNK MINER
|
||||||
Effectively a highly aggressive miner, the blood-drunk miner has very few attacks but compensates by being highly aggressive.
|
Effectively a highly aggressive miner, the blood-drunk miner has very few attacks but compensates by being highly aggressive.
|
||||||
The blood-drunk miner's attacks are as follows
|
The blood-drunk miner's attacks are as follows
|
||||||
- If not in KA range, it will rapidly dash at its target
|
- If not in KA range, it will rapidly dash at its target
|
||||||
- If in KA range, it will fire its kinetic accelerator
|
- If in KA range, it will fire its kinetic accelerator
|
||||||
- If in melee range, will rapidly attack, akin to an actual player
|
- If in melee range, will rapidly attack, akin to an actual player
|
||||||
- After any of these attacks, may transform its cleaving saw:
|
- After any of these attacks, may transform its cleaving saw:
|
||||||
Untransformed, it attacks very rapidly for smaller amounts of damage
|
Untransformed, it attacks very rapidly for smaller amounts of damage
|
||||||
Transformed, it attacks at normal speed for higher damage and cleaves enemies hit
|
Transformed, it attacks at normal speed for higher damage and cleaves enemies hit
|
||||||
When the blood-drunk miner dies, it leaves behind the cleaving saw it was using and its kinetic accelerator.
|
When the blood-drunk miner dies, it leaves behind the cleaving saw it was using and its kinetic accelerator.
|
||||||
Difficulty: Medium
|
Difficulty: Medium
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner
|
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner
|
||||||
name = "blood-drunk miner"
|
name = "blood-drunk miner"
|
||||||
desc = "A miner destined to wander forever, engaged in an endless hunt."
|
desc = "A miner destined to wander forever, engaged in an endless hunt."
|
||||||
health = 900
|
health = 900
|
||||||
maxHealth = 900
|
maxHealth = 900
|
||||||
icon_state = "miner"
|
icon_state = "miner"
|
||||||
icon_living = "miner"
|
icon_living = "miner"
|
||||||
icon = 'icons/mob/broadMobs.dmi'
|
icon = 'icons/mob/broadMobs.dmi'
|
||||||
health_doll_icon = "miner"
|
health_doll_icon = "miner"
|
||||||
mob_biotypes = list(MOB_ORGANIC, MOB_HUMANOID)
|
mob_biotypes = list(MOB_ORGANIC, MOB_HUMANOID)
|
||||||
light_color = "#E4C7C5"
|
light_color = "#E4C7C5"
|
||||||
movement_type = GROUND
|
movement_type = GROUND
|
||||||
speak_emote = list("roars")
|
speak_emote = list("roars")
|
||||||
speed = 1
|
speed = 1
|
||||||
move_to_delay = 2
|
move_to_delay = 2
|
||||||
projectiletype = /obj/item/projectile/kinetic/miner
|
projectiletype = /obj/item/projectile/kinetic/miner
|
||||||
projectilesound = 'sound/weapons/kenetic_accel.ogg'
|
projectilesound = 'sound/weapons/kenetic_accel.ogg'
|
||||||
ranged = TRUE
|
ranged = TRUE
|
||||||
ranged_cooldown_time = 16
|
ranged_cooldown_time = 16
|
||||||
pixel_x = -16
|
pixel_x = -16
|
||||||
crusher_loot = list(/obj/item/melee/transforming/cleaving_saw, /obj/item/gun/energy/kinetic_accelerator/premiumka, /obj/item/crusher_trophy/miner_eye, /obj/item/disk/design_disk/modkit_disc/mob_and_turf_aoe,
|
crusher_loot = list(/obj/item/melee/transforming/cleaving_saw, /obj/item/gun/energy/kinetic_accelerator/premiumka, /obj/item/crusher_trophy/miner_eye, /obj/item/disk/design_disk/modkit_disc/mob_and_turf_aoe,
|
||||||
/obj/item/disk/design_disk/modkit_disc/bounty,/obj/item/disk/design_disk/modkit_disc/resonator_blast,/obj/item/disk/design_disk/modkit_disc/rapid_repeater)
|
/obj/item/disk/design_disk/modkit_disc/bounty,/obj/item/disk/design_disk/modkit_disc/resonator_blast,/obj/item/disk/design_disk/modkit_disc/rapid_repeater)
|
||||||
loot = list(/obj/item/melee/transforming/cleaving_saw, /obj/item/gun/energy/kinetic_accelerator/premiumka,/obj/item/disk/design_disk/modkit_disc/mob_and_turf_aoe,
|
loot = list(/obj/item/melee/transforming/cleaving_saw, /obj/item/gun/energy/kinetic_accelerator/premiumka,/obj/item/disk/design_disk/modkit_disc/mob_and_turf_aoe,
|
||||||
/obj/item/disk/design_disk/modkit_disc/bounty,/obj/item/disk/design_disk/modkit_disc/resonator_blast,/obj/item/disk/design_disk/modkit_disc/rapid_repeater)
|
/obj/item/disk/design_disk/modkit_disc/bounty,/obj/item/disk/design_disk/modkit_disc/resonator_blast,/obj/item/disk/design_disk/modkit_disc/rapid_repeater)
|
||||||
wander = FALSE
|
wander = FALSE
|
||||||
del_on_death = TRUE
|
del_on_death = TRUE
|
||||||
blood_volume = BLOOD_VOLUME_NORMAL
|
blood_volume = BLOOD_VOLUME_NORMAL
|
||||||
achievement_type = /datum/award/achievement/boss/blood_miner_kill
|
achievement_type = /datum/award/achievement/boss/blood_miner_kill
|
||||||
crusher_achievement_type = /datum/award/achievement/boss/blood_miner_crusher
|
crusher_achievement_type = /datum/award/achievement/boss/blood_miner_crusher
|
||||||
score_achievement_type = /datum/award/score/blood_miner_score
|
score_achievement_type = /datum/award/score/blood_miner_score
|
||||||
var/obj/item/melee/transforming/cleaving_saw/miner/miner_saw
|
var/obj/item/melee/transforming/cleaving_saw/miner/miner_saw
|
||||||
var/time_until_next_transform = 0
|
var/time_until_next_transform = 0
|
||||||
var/dashing = FALSE
|
var/dashing = FALSE
|
||||||
var/dash_cooldown = 15
|
var/dash_cooldown = 15
|
||||||
var/guidance = FALSE
|
var/guidance = FALSE
|
||||||
var/transform_stop_attack = FALSE // stops the blood drunk miner from attacking after transforming his weapon until the next attack chain
|
var/transform_stop_attack = FALSE // stops the blood drunk miner from attacking after transforming his weapon until the next attack chain
|
||||||
deathmessage = "falls to the ground, decaying into glowing particles."
|
deathmessage = "falls to the ground, decaying into glowing particles."
|
||||||
deathsound = "bodyfall"
|
deathsound = "bodyfall"
|
||||||
footstep_type = FOOTSTEP_MOB_HEAVY
|
footstep_type = FOOTSTEP_MOB_HEAVY
|
||||||
attack_action_types = list(/datum/action/innate/megafauna_attack/dash,
|
attack_action_types = list(/datum/action/innate/megafauna_attack/dash,
|
||||||
/datum/action/innate/megafauna_attack/kinetic_accelerator,
|
/datum/action/innate/megafauna_attack/kinetic_accelerator,
|
||||||
/datum/action/innate/megafauna_attack/transform_weapon)
|
/datum/action/innate/megafauna_attack/transform_weapon)
|
||||||
|
|
||||||
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/Initialize()
|
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/Initialize()
|
||||||
. = ..()
|
. = ..()
|
||||||
miner_saw = new(src)
|
miner_saw = new(src)
|
||||||
|
|
||||||
/datum/action/innate/megafauna_attack/dash
|
/datum/action/innate/megafauna_attack/dash
|
||||||
name = "Dash To Target"
|
name = "Dash To Target"
|
||||||
icon_icon = 'icons/mob/actions/actions_items.dmi'
|
icon_icon = 'icons/mob/actions/actions_items.dmi'
|
||||||
button_icon_state = "sniper_zoom"
|
button_icon_state = "sniper_zoom"
|
||||||
chosen_message = "<span class='colossus'>You are now dashing to your target.</span>"
|
chosen_message = "<span class='colossus'>You are now dashing to your target.</span>"
|
||||||
chosen_attack_num = 1
|
chosen_attack_num = 1
|
||||||
|
|
||||||
/datum/action/innate/megafauna_attack/kinetic_accelerator
|
/datum/action/innate/megafauna_attack/kinetic_accelerator
|
||||||
name = "Fire Kinetic Accelerator"
|
name = "Fire Kinetic Accelerator"
|
||||||
icon_icon = 'icons/obj/guns/energy.dmi'
|
icon_icon = 'icons/obj/guns/energy.dmi'
|
||||||
button_icon_state = "kineticgun"
|
button_icon_state = "kineticgun"
|
||||||
chosen_message = "<span class='colossus'>You are now shooting your kinetic accelerator.</span>"
|
chosen_message = "<span class='colossus'>You are now shooting your kinetic accelerator.</span>"
|
||||||
chosen_attack_num = 2
|
chosen_attack_num = 2
|
||||||
|
|
||||||
/datum/action/innate/megafauna_attack/transform_weapon
|
/datum/action/innate/megafauna_attack/transform_weapon
|
||||||
name = "Transform Weapon"
|
name = "Transform Weapon"
|
||||||
icon_icon = 'icons/obj/lavaland/artefacts.dmi'
|
icon_icon = 'icons/obj/lavaland/artefacts.dmi'
|
||||||
button_icon_state = "cleaving_saw"
|
button_icon_state = "cleaving_saw"
|
||||||
chosen_message = "<span class='colossus'>You are now transforming your weapon.</span>"
|
chosen_message = "<span class='colossus'>You are now transforming your weapon.</span>"
|
||||||
chosen_attack_num = 3
|
chosen_attack_num = 3
|
||||||
|
|
||||||
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/OpenFire()
|
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/OpenFire()
|
||||||
if(client)
|
if(client)
|
||||||
switch(chosen_attack)
|
switch(chosen_attack)
|
||||||
if(1)
|
if(1)
|
||||||
dash(target)
|
dash(target)
|
||||||
if(2)
|
if(2)
|
||||||
shoot_ka()
|
shoot_ka()
|
||||||
if(3)
|
if(3)
|
||||||
transform_weapon()
|
transform_weapon()
|
||||||
return
|
return
|
||||||
|
|
||||||
Goto(target, move_to_delay, minimum_distance)
|
Goto(target, move_to_delay, minimum_distance)
|
||||||
if(get_dist(src, target) > MINER_DASH_RANGE && dash_cooldown <= world.time)
|
if(get_dist(src, target) > MINER_DASH_RANGE && dash_cooldown <= world.time)
|
||||||
dash_attack()
|
dash_attack()
|
||||||
else
|
else
|
||||||
shoot_ka()
|
shoot_ka()
|
||||||
transform_weapon()
|
transform_weapon()
|
||||||
|
|
||||||
/obj/item/melee/transforming/cleaving_saw/miner //nerfed saw because it is very murdery
|
/obj/item/melee/transforming/cleaving_saw/miner //nerfed saw because it is very murdery
|
||||||
force = 6
|
force = 6
|
||||||
force_on = 10
|
force_on = 10
|
||||||
|
|
||||||
/obj/item/melee/transforming/cleaving_saw/miner/attack(mob/living/target, mob/living/carbon/human/user)
|
/obj/item/melee/transforming/cleaving_saw/miner/attack(mob/living/target, mob/living/carbon/human/user)
|
||||||
target.add_stun_absorption("miner", 10, INFINITY)
|
target.add_stun_absorption("miner", 10, INFINITY)
|
||||||
..()
|
..()
|
||||||
target.stun_absorption -= "miner"
|
target.stun_absorption -= "miner"
|
||||||
|
|
||||||
/obj/item/projectile/kinetic/miner
|
/obj/item/projectile/kinetic/miner
|
||||||
damage = 40
|
damage = 40
|
||||||
pixels_per_second = TILES_TO_PIXELS(11.111)
|
pixels_per_second = TILES_TO_PIXELS(11.111)
|
||||||
icon_state = "ka_tracer"
|
icon_state = "ka_tracer"
|
||||||
range = MINER_DASH_RANGE
|
range = MINER_DASH_RANGE
|
||||||
|
|
||||||
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/adjustHealth(amount, updating_health = TRUE, forced = FALSE)
|
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/adjustHealth(amount, updating_health = TRUE, forced = FALSE)
|
||||||
var/adjustment_amount = amount * 0.1
|
var/adjustment_amount = amount * 0.1
|
||||||
if(world.time + adjustment_amount > next_action)
|
if(world.time + adjustment_amount > next_action)
|
||||||
DelayNextAction(adjustment_amount) //attacking it interrupts it attacking, but only briefly
|
DelayNextAction(adjustment_amount) //attacking it interrupts it attacking, but only briefly
|
||||||
. = ..()
|
. = ..()
|
||||||
|
|
||||||
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/death()
|
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/death()
|
||||||
. = ..()
|
. = ..()
|
||||||
if(.)
|
if(.)
|
||||||
new /obj/effect/temp_visual/dir_setting/miner_death(loc, dir)
|
new /obj/effect/temp_visual/dir_setting/miner_death(loc, dir)
|
||||||
|
|
||||||
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/Move(atom/newloc)
|
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/Move(atom/newloc)
|
||||||
if(dashing || (newloc && newloc.z == z && (islava(newloc) || ischasm(newloc)))) //we're not stupid!
|
if(dashing || (newloc && newloc.z == z && (islava(newloc) || ischasm(newloc)))) //we're not stupid!
|
||||||
return FALSE
|
return FALSE
|
||||||
return ..()
|
return ..()
|
||||||
|
|
||||||
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/ex_act(severity, target)
|
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/ex_act(severity, target)
|
||||||
if(dash())
|
if(dash())
|
||||||
return
|
return
|
||||||
return ..()
|
return ..()
|
||||||
|
|
||||||
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/MeleeAction(patience = TRUE)
|
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/MeleeAction(patience = TRUE)
|
||||||
transform_stop_attack = FALSE
|
transform_stop_attack = FALSE
|
||||||
return ..()
|
return ..()
|
||||||
|
|
||||||
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/AttackingTarget()
|
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/AttackingTarget()
|
||||||
if(client)
|
if(client)
|
||||||
transform_stop_attack = FALSE
|
transform_stop_attack = FALSE
|
||||||
if(QDELETED(target) || transform_stop_attack)
|
if(QDELETED(target) || transform_stop_attack)
|
||||||
return
|
return
|
||||||
face_atom(target)
|
face_atom(target)
|
||||||
if(isliving(target))
|
if(isliving(target))
|
||||||
var/mob/living/L = target
|
var/mob/living/L = target
|
||||||
if(L.stat == DEAD)
|
if(L.stat == DEAD)
|
||||||
visible_message("<span class='danger'>[src] butchers [L]!</span>",
|
visible_message("<span class='danger'>[src] butchers [L]!</span>",
|
||||||
"<span class='userdanger'>You butcher [L], restoring your health!</span>")
|
"<span class='userdanger'>You butcher [L], restoring your health!</span>")
|
||||||
if(!is_station_level(z) || client) //NPC monsters won't heal while on station
|
if(!is_station_level(z) || client) //NPC monsters won't heal while on station
|
||||||
if(guidance)
|
if(guidance)
|
||||||
adjustHealth(-L.maxHealth)
|
adjustHealth(-L.maxHealth)
|
||||||
else
|
else
|
||||||
adjustHealth(-(L.maxHealth * 0.5))
|
adjustHealth(-(L.maxHealth * 0.5))
|
||||||
L.gib()
|
L.gib()
|
||||||
return TRUE
|
return TRUE
|
||||||
DelayNextAction(CLICK_CD_MELEE)
|
DelayNextAction(CLICK_CD_MELEE)
|
||||||
miner_saw.melee_attack_chain(src, target)
|
miner_saw.melee_attack_chain(src, target)
|
||||||
if(guidance)
|
if(guidance)
|
||||||
adjustHealth(-2)
|
adjustHealth(-2)
|
||||||
return TRUE
|
return TRUE
|
||||||
|
|
||||||
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/do_attack_animation(atom/A, visual_effect_icon, obj/item/used_item, no_effect)
|
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/do_attack_animation(atom/A, visual_effect_icon, obj/item/used_item, no_effect)
|
||||||
if(!used_item && !isturf(A))
|
if(!used_item && !isturf(A))
|
||||||
used_item = miner_saw
|
used_item = miner_saw
|
||||||
..()
|
..()
|
||||||
|
|
||||||
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/GiveTarget(new_target)
|
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/GiveTarget(new_target)
|
||||||
var/targets_the_same = (new_target == target)
|
var/targets_the_same = (new_target == target)
|
||||||
. = ..()
|
. = ..()
|
||||||
if(. && target && !targets_the_same)
|
if(. && target && !targets_the_same)
|
||||||
wander = TRUE
|
wander = TRUE
|
||||||
|
|
||||||
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/proc/dash_attack()
|
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/proc/dash_attack()
|
||||||
INVOKE_ASYNC(src, .proc/dash, target)
|
INVOKE_ASYNC(src, .proc/dash, target)
|
||||||
shoot_ka()
|
shoot_ka()
|
||||||
|
|
||||||
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/proc/shoot_ka()
|
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/proc/shoot_ka()
|
||||||
if(ranged_cooldown <= world.time && get_dist(src, target) <= MINER_DASH_RANGE && !Adjacent(target))
|
if(ranged_cooldown <= world.time && get_dist(src, target) <= MINER_DASH_RANGE && !Adjacent(target))
|
||||||
ranged_cooldown = world.time + ranged_cooldown_time
|
ranged_cooldown = world.time + ranged_cooldown_time
|
||||||
visible_message("<span class='danger'>[src] fires the proto-kinetic accelerator!</span>")
|
visible_message("<span class='danger'>[src] fires the proto-kinetic accelerator!</span>")
|
||||||
face_atom(target)
|
face_atom(target)
|
||||||
new /obj/effect/temp_visual/dir_setting/firing_effect(loc, dir)
|
new /obj/effect/temp_visual/dir_setting/firing_effect(loc, dir)
|
||||||
Shoot(target)
|
Shoot(target)
|
||||||
DelayNextAction(CLICK_CD_RANGE)
|
DelayNextAction(CLICK_CD_RANGE)
|
||||||
|
|
||||||
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/proc/dash(atom/dash_target)
|
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/proc/dash(atom/dash_target)
|
||||||
if(world.time < dash_cooldown)
|
if(world.time < dash_cooldown)
|
||||||
return
|
return
|
||||||
var/list/accessable_turfs = list()
|
var/list/accessable_turfs = list()
|
||||||
var/self_dist_to_target = 0
|
var/self_dist_to_target = 0
|
||||||
var/turf/own_turf = get_turf(src)
|
var/turf/own_turf = get_turf(src)
|
||||||
if(!QDELETED(dash_target))
|
if(!QDELETED(dash_target))
|
||||||
self_dist_to_target += get_dist(dash_target, own_turf)
|
self_dist_to_target += get_dist(dash_target, own_turf)
|
||||||
for(var/turf/open/O in RANGE_TURFS(MINER_DASH_RANGE, own_turf))
|
for(var/turf/open/O in RANGE_TURFS(MINER_DASH_RANGE, own_turf))
|
||||||
var/turf_dist_to_target = 0
|
var/turf_dist_to_target = 0
|
||||||
if(!QDELETED(dash_target))
|
if(!QDELETED(dash_target))
|
||||||
turf_dist_to_target += get_dist(dash_target, O)
|
turf_dist_to_target += get_dist(dash_target, O)
|
||||||
if(get_dist(src, O) >= MINER_DASH_RANGE && turf_dist_to_target <= self_dist_to_target && !islava(O) && !ischasm(O))
|
if(get_dist(src, O) >= MINER_DASH_RANGE && turf_dist_to_target <= self_dist_to_target && !islava(O) && !ischasm(O))
|
||||||
var/valid = TRUE
|
var/valid = TRUE
|
||||||
for(var/turf/T in getline(own_turf, O))
|
for(var/turf/T in getline(own_turf, O))
|
||||||
if(is_blocked_turf(T, TRUE))
|
if(is_blocked_turf(T, TRUE))
|
||||||
valid = FALSE
|
valid = FALSE
|
||||||
continue
|
continue
|
||||||
if(valid)
|
if(valid)
|
||||||
accessable_turfs[O] = turf_dist_to_target
|
accessable_turfs[O] = turf_dist_to_target
|
||||||
var/turf/target_turf
|
var/turf/target_turf
|
||||||
if(!QDELETED(dash_target))
|
if(!QDELETED(dash_target))
|
||||||
var/closest_dist = MINER_DASH_RANGE
|
var/closest_dist = MINER_DASH_RANGE
|
||||||
for(var/t in accessable_turfs)
|
for(var/t in accessable_turfs)
|
||||||
if(accessable_turfs[t] < closest_dist)
|
if(accessable_turfs[t] < closest_dist)
|
||||||
closest_dist = accessable_turfs[t]
|
closest_dist = accessable_turfs[t]
|
||||||
for(var/t in accessable_turfs)
|
for(var/t in accessable_turfs)
|
||||||
if(accessable_turfs[t] != closest_dist)
|
if(accessable_turfs[t] != closest_dist)
|
||||||
accessable_turfs -= t
|
accessable_turfs -= t
|
||||||
if(!LAZYLEN(accessable_turfs))
|
if(!LAZYLEN(accessable_turfs))
|
||||||
return
|
return
|
||||||
dash_cooldown = world.time + initial(dash_cooldown)
|
dash_cooldown = world.time + initial(dash_cooldown)
|
||||||
target_turf = pick(accessable_turfs)
|
target_turf = pick(accessable_turfs)
|
||||||
var/turf/step_back_turf = get_step(target_turf, get_cardinal_dir(target_turf, own_turf))
|
var/turf/step_back_turf = get_step(target_turf, get_cardinal_dir(target_turf, own_turf))
|
||||||
var/turf/step_forward_turf = get_step(own_turf, get_cardinal_dir(own_turf, target_turf))
|
var/turf/step_forward_turf = get_step(own_turf, get_cardinal_dir(own_turf, target_turf))
|
||||||
new /obj/effect/temp_visual/small_smoke/halfsecond(step_back_turf)
|
new /obj/effect/temp_visual/small_smoke/halfsecond(step_back_turf)
|
||||||
new /obj/effect/temp_visual/small_smoke/halfsecond(step_forward_turf)
|
new /obj/effect/temp_visual/small_smoke/halfsecond(step_forward_turf)
|
||||||
var/obj/effect/temp_visual/decoy/fading/halfsecond/D = new (own_turf, src)
|
var/obj/effect/temp_visual/decoy/fading/halfsecond/D = new (own_turf, src)
|
||||||
forceMove(step_back_turf)
|
forceMove(step_back_turf)
|
||||||
playsound(own_turf, 'sound/weapons/punchmiss.ogg', 40, 1, -1)
|
playsound(own_turf, 'sound/weapons/punchmiss.ogg', 40, 1, -1)
|
||||||
dashing = TRUE
|
dashing = TRUE
|
||||||
alpha = 0
|
alpha = 0
|
||||||
animate(src, alpha = 255, time = 5)
|
animate(src, alpha = 255, time = 5)
|
||||||
SLEEP_CHECK_DEATH(2)
|
SLEEP_CHECK_DEATH(2)
|
||||||
D.forceMove(step_forward_turf)
|
D.forceMove(step_forward_turf)
|
||||||
forceMove(target_turf)
|
forceMove(target_turf)
|
||||||
playsound(target_turf, 'sound/weapons/punchmiss.ogg', 40, 1, -1)
|
playsound(target_turf, 'sound/weapons/punchmiss.ogg', 40, 1, -1)
|
||||||
SLEEP_CHECK_DEATH(1)
|
SLEEP_CHECK_DEATH(1)
|
||||||
dashing = FALSE
|
dashing = FALSE
|
||||||
return TRUE
|
return TRUE
|
||||||
|
|
||||||
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/proc/transform_weapon()
|
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/proc/transform_weapon()
|
||||||
if(time_until_next_transform <= world.time)
|
if(time_until_next_transform <= world.time)
|
||||||
miner_saw.transform_cooldown = 0
|
miner_saw.transform_cooldown = 0
|
||||||
miner_saw.transform_weapon(src, TRUE)
|
miner_saw.transform_weapon(src, TRUE)
|
||||||
if(!miner_saw.active)
|
if(!miner_saw.active)
|
||||||
rapid_melee = 5 // 4 deci cooldown before changes, npcpool subsystem wait is 20, 20/4 = 5
|
rapid_melee = 5 // 4 deci cooldown before changes, npcpool subsystem wait is 20, 20/4 = 5
|
||||||
else
|
else
|
||||||
rapid_melee = 3 // same thing but halved (slightly rounded up)
|
rapid_melee = 3 // same thing but halved (slightly rounded up)
|
||||||
transform_stop_attack = TRUE
|
transform_stop_attack = TRUE
|
||||||
icon_state = "miner[miner_saw.active ? "_transformed":""]"
|
icon_state = "miner[miner_saw.active ? "_transformed":""]"
|
||||||
icon_living = "miner[miner_saw.active ? "_transformed":""]"
|
icon_living = "miner[miner_saw.active ? "_transformed":""]"
|
||||||
time_until_next_transform = world.time + rand(50, 100)
|
time_until_next_transform = world.time + rand(50, 100)
|
||||||
|
|
||||||
/obj/effect/temp_visual/dir_setting/miner_death
|
/obj/effect/temp_visual/dir_setting/miner_death
|
||||||
icon_state = "miner_death"
|
icon_state = "miner_death"
|
||||||
duration = 15
|
duration = 15
|
||||||
|
|
||||||
/obj/effect/temp_visual/dir_setting/miner_death/Initialize(mapload, set_dir)
|
/obj/effect/temp_visual/dir_setting/miner_death/Initialize(mapload, set_dir)
|
||||||
. = ..()
|
. = ..()
|
||||||
INVOKE_ASYNC(src, .proc/fade_out)
|
INVOKE_ASYNC(src, .proc/fade_out)
|
||||||
|
|
||||||
/obj/effect/temp_visual/dir_setting/miner_death/proc/fade_out()
|
/obj/effect/temp_visual/dir_setting/miner_death/proc/fade_out()
|
||||||
var/matrix/M = new
|
var/matrix/M = new
|
||||||
M.Turn(pick(90, 270))
|
M.Turn(pick(90, 270))
|
||||||
var/final_dir = dir
|
var/final_dir = dir
|
||||||
if(dir & (EAST|WEST)) //Facing east or west
|
if(dir & (EAST|WEST)) //Facing east or west
|
||||||
final_dir = pick(NORTH, SOUTH) //So you fall on your side rather than your face or ass
|
final_dir = pick(NORTH, SOUTH) //So you fall on your side rather than your face or ass
|
||||||
|
|
||||||
animate(src, transform = M, pixel_y = -6, dir = final_dir, time = 2, easing = EASE_IN|EASE_OUT)
|
animate(src, transform = M, pixel_y = -6, dir = final_dir, time = 2, easing = EASE_IN|EASE_OUT)
|
||||||
sleep(5)
|
sleep(5)
|
||||||
animate(src, color = list("#A7A19E", "#A7A19E", "#A7A19E", list(0, 0, 0)), time = 10, easing = EASE_IN, flags = ANIMATION_PARALLEL)
|
animate(src, color = list("#A7A19E", "#A7A19E", "#A7A19E", list(0, 0, 0)), time = 10, easing = EASE_IN, flags = ANIMATION_PARALLEL)
|
||||||
sleep(4)
|
sleep(4)
|
||||||
animate(src, alpha = 0, time = 6, easing = EASE_OUT, flags = ANIMATION_PARALLEL)
|
animate(src, alpha = 0, time = 6, easing = EASE_OUT, flags = ANIMATION_PARALLEL)
|
||||||
|
|
||||||
/obj/item/gps/internal/miner
|
/obj/item/gps/internal/miner
|
||||||
icon_state = null
|
icon_state = null
|
||||||
gpstag = "Resonant Signal"
|
gpstag = "Resonant Signal"
|
||||||
desc = "The sweet blood, oh, it sings to me."
|
desc = "The sweet blood, oh, it sings to me."
|
||||||
invisibility = 100
|
invisibility = 100
|
||||||
|
|
||||||
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/guidance
|
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/guidance
|
||||||
guidance = TRUE
|
guidance = TRUE
|
||||||
|
|
||||||
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/hunter/AttackingTarget()
|
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/hunter/AttackingTarget()
|
||||||
. = ..()
|
. = ..()
|
||||||
if(. && prob(12))
|
if(. && prob(12))
|
||||||
INVOKE_ASYNC(src, .proc/dash)
|
INVOKE_ASYNC(src, .proc/dash)
|
||||||
|
|
||||||
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/doom
|
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/doom
|
||||||
name = "hostile-environment miner"
|
name = "hostile-environment miner"
|
||||||
desc = "A miner destined to hop across dimensions for all eternity, hunting anomalous creatures."
|
desc = "A miner destined to hop across dimensions for all eternity, hunting anomalous creatures."
|
||||||
speed = 8
|
speed = 8
|
||||||
move_to_delay = 8
|
move_to_delay = 8
|
||||||
ranged_cooldown_time = 8
|
ranged_cooldown_time = 8
|
||||||
dash_cooldown = 8
|
dash_cooldown = 8
|
||||||
|
|
||||||
|
|
||||||
#undef MINER_DASH_RANGE
|
#undef MINER_DASH_RANGE
|
||||||
|
|||||||
Reference in New Issue
Block a user