Files
Aurora.3/code/game/objects/structures/alien/node.dm
Alberyk 76b743a986 Adds the Aut'akh unathi (#5919)
* Base work for the unathi robot subspecies.

* Adds metabolism species, kidney vars, and the robot unathi organs.

* Moves some action buttons to organs, pretty much a bay port right now. Todo: the unathi and alien stuff should also go here.

* First autakh implant power.

* Fixes the organs action button this time.

* Finishes more implants, and interactions with flashs and vaurca.

* Prepare for great changes.

* Drops the real bomb, boss.

* He who fights with monsters.

* Far more work into augments and limb removing powers.

* Limb verbs should be good now.

* A LOT of work into the assited organ, allowing it to bleed and etc, as well adding a new chem that will stop bleeding in their case.

* Probably the last work on implants.

* Some extra touches.

* Some tweaks to the species.

* More fixes and adds kyre's sprites.

* More runtime fixes.

* Fixes the species name too.

* Fixes travis.

* Updates this file too to work with the new tools procs.

* Adds changelog

* Fixed changelog.

* Unathi hair and lore description.

* Some tweaks to this too.

* Locks away them for now, they will be released after we got all the events and etc done.

* Changes this chemical.

* Fixes an airlock runtime.

* Adds the non scan flag to the autakh, mostly due to some bizzare interactions with changelings and cloning.

* Organs removal changes; can't take out the organ if it is too damage.

* Restricts them back again.

* Robotic organs now have the proper icons and names.

* Adds sprites for their organs and some extra tweaks.

* Fixes this missing icon.

* emp should also now hurt assited organs.

* Tweaks more organ related things.

* Fixes the head not being properly set as well.

* Fixes their flags.

* fixes the flag for real this time.

* Poze's review.

* Changes the au'takh organ buttons to don't be animated.

* Helps with adminbus or something.

* Fowl's requested changes.

* Fixes a typo.

* Robotic limb's brute and burn mods are now controlled by the limb model.

* Fowl's changes once more.

* Stops some spam.

* More grammar.

* No eal.

* Skull's review.
2019-01-23 19:27:44 +01:00

105 lines
2.3 KiB
Plaintext

#define NODERANGE 3
/obj/structure/alien/weeds
name = "weeds"
desc = "Weird purple weeds."
icon_state = "weeds"
anchored = 1
density = 0
health = 15
var/obj/structure/alien/weeds/node/linked_node = null
var/list/dirs_left
/obj/structure/alien/weeds/node
icon_state = "weednode"
name = "purple sac"
desc = "Weird purple octopus-like thing."
light_range = NODERANGE
var/node_range = NODERANGE
/obj/structure/alien/weeds/Destroy()
STOP_PROCESSING(SSprocessing, src)
return ..()
/obj/structure/alien/weeds/Initialize(pos, node)
. = ..()
if(istype(loc, /turf/space))
return INITIALIZE_HINT_QDEL
linked_node = node
if(icon_state == "weeds")icon_state = pick("weeds", "weeds1", "weeds2")
START_PROCESSING(SSprocessing, src)
dirs_left = cardinal.Copy()
/obj/structure/alien/weeds/process()
var/turf/U = get_turf(src)
if (istype(U, /turf/space))
qdel(src)
return PROCESS_KILL
if (!dirs_left.len || !linked_node || get_dist(linked_node, src) > linked_node.node_range)
return PROCESS_KILL
for (var/D in dirs_left)
var/turf/T = get_step(src, D)
if (!isturf(T) || T.is_hole || T.is_space() || locate(/obj/structure/alien/weeds, T))
dirs_left -= D
continue
if (T.density)
continue
var/spawn_new = TRUE
for (var/aa in T)
var/atom/A = aa
if (istype(/obj/structure/alien/weeds, A))
dirs_left -= D
spawn_new = FALSE
break
else if (A.density)
spawn_new = FALSE
if (spawn_new)
new /obj/structure/alien/weeds(T, linked_node)
/obj/structure/alien/weeds/ex_act(severity)
switch(severity)
if(1.0)
qdel(src)
if(2.0)
if (prob(50))
qdel(src)
if(3.0)
if (prob(5))
qdel(src)
return
/obj/structure/alien/weeds/attackby(var/obj/item/weapon/W, var/mob/user)
user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN)
visible_message("<span class='danger'>\The [src] have been attacked with \the [W][(user ? " by [user]." : ".")]</span>")
var/damage = W.force / 4.0
if(W.iswelder())
var/obj/item/weapon/weldingtool/WT = W
if(WT.remove_fuel(0, user))
damage = 15
playsound(loc, 'sound/items/Welder.ogg', 100, 1)
health -= damage
healthcheck()
/obj/structure/alien/weeds/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume)
if(exposed_temperature > 300 + T0C)
health -= 5
healthcheck()
#undef NODERANGE