mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-22 04:22:39 +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()
|
||||
|
||||
Reference in New Issue
Block a user