mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-07-20 20:37:34 +01:00
Additional Pylons (#1870)
This PR adds a new utility mechanic for the cult. Pylons can now be upgraded into arcane defensive turrets, which fire bolts of demonic energy. These turrets are entirely automated, somewhat-rapid firing, extremely accurate and quite long ranged, but their damage is very low, and thus their total DPS, even with the fire rate, is still far lower than most real ranged weapons.
This commit is contained in:
@@ -18,6 +18,7 @@ var/list/holder_mob_icon_cache = list()
|
||||
var/last_loc_specific//This stores specific extra information about the location, pocket, hand, worn on head, etc. Only relevant to mobs
|
||||
|
||||
/obj/item/weapon/holder/New()
|
||||
tag = rand(0,9999)
|
||||
if (!item_state)
|
||||
item_state = icon_state
|
||||
|
||||
@@ -91,6 +92,8 @@ var/list/holder_mob_icon_cache = list()
|
||||
|
||||
//Releases all mobs inside the holder, then deletes it.
|
||||
//is_unsafe_container should be checked before calling this
|
||||
//This function releases mobs into wherever the holder currently is. Its not safe to call from a lot of places
|
||||
//Use release_to_floor for a simple, safe release
|
||||
/obj/item/weapon/holder/proc/release_mob()
|
||||
for(var/mob/M in contents)
|
||||
var/atom/movable/mob_container
|
||||
@@ -99,6 +102,7 @@ var/list/holder_mob_icon_cache = list()
|
||||
M.reset_view()
|
||||
M.Released()
|
||||
|
||||
|
||||
contained = null
|
||||
var/mob/L = get_holding_mob()
|
||||
if (L)
|
||||
@@ -107,6 +111,21 @@ var/list/holder_mob_icon_cache = list()
|
||||
qdel(src)
|
||||
|
||||
|
||||
//Similar to above function, but will not deposit things in any container, only directly on a turf.
|
||||
//Can be called safely anywhere. Notably on holders held or worn on a mob
|
||||
/obj/item/weapon/holder/proc/release_to_floor()
|
||||
var/turf/T = get_turf(src)
|
||||
var/mob/L = get_holding_mob()
|
||||
if (L)
|
||||
L.drop_from_inventory(src)
|
||||
|
||||
for(var/mob/M in contents)
|
||||
M.forceMove(T) //if the holder was placed into a disposal, this should place the animal in the disposal
|
||||
M.reset_view()
|
||||
M.Released()
|
||||
|
||||
qdel(src)
|
||||
|
||||
/obj/item/weapon/holder/attackby(obj/item/weapon/W as obj, mob/user as mob)
|
||||
for(var/mob/M in src.contents)
|
||||
M.attackby(W,user)
|
||||
|
||||
@@ -35,6 +35,7 @@
|
||||
mob_push_flags = ALLMOBS
|
||||
hunger_enabled = 0
|
||||
var/list/construct_spells = list()
|
||||
var/can_repair = 0
|
||||
|
||||
/mob/living/simple_animal/construct/cultify()
|
||||
return
|
||||
@@ -58,16 +59,19 @@
|
||||
|
||||
/mob/living/simple_animal/construct/attack_generic(var/mob/user)
|
||||
user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN)
|
||||
if(istype(user, /mob/living/simple_animal/construct/builder))
|
||||
if(getBruteLoss() > 0)
|
||||
adjustBruteLoss(-5)
|
||||
user.visible_message("<span class='notice'>\The [user] mends some of \the [src]'s wounds.</span>")
|
||||
else
|
||||
if (health < maxHealth)
|
||||
user << "<span class='notice'>Healing \the [src] any further is beyond your abilities.</span>"
|
||||
if(istype(user, /mob/living/simple_animal/construct))
|
||||
var/mob/living/simple_animal/construct/C = user
|
||||
if (C.can_repair)
|
||||
if(getBruteLoss() > 0)
|
||||
adjustBruteLoss(-5)
|
||||
adjustFireLoss(-5)
|
||||
user.visible_message("<span class='notice'>\The [user] mends some of \the [src]'s wounds.</span>")
|
||||
else
|
||||
user << "<span class='notice'>\The [src] is undamaged.</span>"
|
||||
return
|
||||
if (health < maxHealth)
|
||||
user << "<span class='notice'>Healing \the [src] any further is beyond your abilities.</span>"
|
||||
else
|
||||
user << "<span class='notice'>\The [src] is undamaged.</span>"
|
||||
return
|
||||
return ..()
|
||||
|
||||
/mob/living/simple_animal/construct/examine(mob/user)
|
||||
@@ -188,6 +192,7 @@
|
||||
speed = 0
|
||||
environment_smash = 1
|
||||
attack_sound = 'sound/weapons/rapidslice.ogg'
|
||||
can_repair = 1
|
||||
construct_spells = list(/spell/aoe_turf/conjure/construct/lesser,
|
||||
/spell/aoe_turf/conjure/wall,
|
||||
/spell/aoe_turf/conjure/floor,
|
||||
@@ -242,13 +247,19 @@
|
||||
environment_smash = 1
|
||||
see_in_dark = 7
|
||||
attack_sound = 'sound/weapons/pierce.ogg'
|
||||
|
||||
can_repair = 1
|
||||
construct_spells = list(
|
||||
/spell/targeted/harvest,
|
||||
/spell/aoe_turf/knock/harvester,
|
||||
/spell/rune_write
|
||||
/spell/rune_write,
|
||||
/spell/aoe_turf/conjure/construct/lesser,
|
||||
/spell/aoe_turf/conjure/wall,
|
||||
/spell/aoe_turf/conjure/floor,
|
||||
/spell/aoe_turf/conjure/soulstone,
|
||||
/spell/aoe_turf/conjure/pylon,
|
||||
/spell/aoe_turf/conjure/forcewall/lesser
|
||||
)
|
||||
|
||||
//Harvesters are endgame stuff, no harm giving them construct spells
|
||||
|
||||
////////////////Glow//////////////////
|
||||
/mob/living/simple_animal/construct/proc/add_glow()
|
||||
|
||||
@@ -153,3 +153,29 @@
|
||||
//----------------------------
|
||||
/obj/effect/projectile/pulse_bullet/muzzle
|
||||
icon_state = "muzzle_pulse"
|
||||
|
||||
|
||||
//----------------------------
|
||||
// Demonic Beam
|
||||
//----------------------------
|
||||
/obj/effect/projectile/cult/tracer
|
||||
icon_state = "cult"
|
||||
|
||||
/obj/effect/projectile/cult/muzzle
|
||||
icon_state = "muzzle_cult"
|
||||
|
||||
/obj/effect/projectile/cult/impact
|
||||
icon_state = "impact_cult"
|
||||
|
||||
|
||||
//----------------------------
|
||||
// Empowered Demonic Beam
|
||||
//----------------------------
|
||||
/obj/effect/projectile/cult/heavy/tracer
|
||||
icon_state = "hcult"
|
||||
|
||||
/obj/effect/projectile/cult/heavy/muzzle
|
||||
icon_state = "muzzle_hcult"
|
||||
|
||||
/obj/effect/projectile/cult/heavy/impact
|
||||
icon_state = "impact_hcult"
|
||||
@@ -259,3 +259,39 @@
|
||||
var/mob/living/M = A
|
||||
M.apply_effect(1, INCINERATE, 0)
|
||||
..()
|
||||
|
||||
|
||||
|
||||
//Beams of magical veil energy fired by empowered pylons. Some inbuilt armor penetration cuz magic.
|
||||
//Ablative armor is still overwhelmingly useful
|
||||
//These beams are very weak but rapid firing, ~twice per second.
|
||||
/obj/item/projectile/beam/cult
|
||||
name = "energy bolt"
|
||||
//For projectiles name is only shown in onhit messages, so its more of a layman's description
|
||||
//of what the projectile looks like
|
||||
damage = 4 //Very weak
|
||||
armor_penetration = 10
|
||||
accuracy = 4 //Guided by magic, unlikely to miss
|
||||
var/mob/living/ignore
|
||||
|
||||
muzzle_type = /obj/effect/projectile/cult/muzzle
|
||||
tracer_type = /obj/effect/projectile/cult/tracer
|
||||
impact_type = /obj/effect/projectile/cult/impact
|
||||
|
||||
/obj/item/projectile/beam/cult/attack_mob(var/mob/living/target_mob, var/distance, var/miss_modifier=0)
|
||||
//Harmlessly passes through cultists and constructs
|
||||
if (target_mob == ignore)
|
||||
return 0
|
||||
if (iscult(target_mob))
|
||||
return 0
|
||||
|
||||
return ..()
|
||||
|
||||
/obj/item/projectile/beam/cult/heavy
|
||||
name = "glowing energy bolt"
|
||||
damage = 12 //Stronger and better armor penetration, though still much weaker than a typical laser
|
||||
armor_penetration = 15
|
||||
|
||||
muzzle_type = /obj/effect/projectile/cult/heavy/muzzle
|
||||
tracer_type = /obj/effect/projectile/cult/heavy/tracer
|
||||
impact_type = /obj/effect/projectile/cult/heavy/impact
|
||||
Reference in New Issue
Block a user