Overhauls Resin ability, deletes unused xeno sprites, fixes few things.

This commit is contained in:
Sym
2021-08-28 17:31:01 -04:00
parent 177691c515
commit 0e45d5ddea
9 changed files with 92 additions and 159 deletions
-134
View File
@@ -1,7 +1,6 @@
/* Alien Effects!
* Contains:
* effect/alien
* Resin
* Weeds
* Acid
*/
@@ -14,139 +13,6 @@
desc = "theres something alien about this"
icon = 'icons/mob/alien.dmi'
/*
* Resin
*/
/obj/effect/alien/resin
name = "resin"
desc = "Looks like some kind of slimy growth."
icon_state = "resin"
density = TRUE
opacity = 1
anchored = TRUE
can_atmos_pass = ATMOS_PASS_NO
var/health = 200
//var/mob/living/affecting = null
/obj/effect/alien/resin/wall
name = "resin wall"
desc = "Purple slime solidified into a wall."
icon_state = "resinwall" //same as resin, but consistency ho!
/obj/effect/alien/resin/membrane
name = "resin membrane"
desc = "Purple slime just thin enough to let light pass through."
icon_state = "resinmembrane"
opacity = 0
health = 120
/obj/effect/alien/resin/New()
..()
var/turf/T = get_turf(src)
T.thermal_conductivity = WALL_HEAT_TRANSFER_COEFFICIENT
/obj/effect/alien/resin/Destroy()
var/turf/T = get_turf(src)
T.thermal_conductivity = initial(T.thermal_conductivity)
..()
/obj/effect/alien/resin/proc/healthcheck()
if(health <=0)
density = FALSE
qdel(src)
return
/obj/effect/alien/resin/bullet_act(var/obj/item/projectile/Proj)
health -= Proj.damage
..()
healthcheck()
return
/obj/effect/alien/resin/attack_generic(var/mob/user, var/damage, var/attack_verb)
visible_message("<span class='danger'>[user] [attack_verb] the [src]!</span>")
playsound(src, 'sound/effects/attackblob.ogg', 100, 1)
user.do_attack_animation(src)
health -= damage
healthcheck()
return
/obj/effect/alien/resin/take_damage(var/damage)
health -= damage
healthcheck()
return
/obj/effect/alien/resin/ex_act(severity)
switch(severity)
if(1.0)
health-=50
if(2.0)
health-=50
if(3.0)
if (prob(50))
health-=50
else
health-=25
healthcheck()
return
/obj/effect/alien/resin/hitby(AM as mob|obj)
..()
for(var/mob/O in viewers(src, null))
O.show_message("<span class='danger'>[src] was hit by [AM].</span>", 1)
var/tforce = 0
if(ismob(AM))
tforce = 10
else
tforce = AM:throwforce
playsound(src, 'sound/effects/attackblob.ogg', 100, 1)
health = max(0, health - tforce)
healthcheck()
..()
return
/obj/effect/alien/resin/attack_hand()
usr.setClickCooldown(DEFAULT_ATTACK_COOLDOWN)
if (HULK in usr.mutations)
to_chat(usr, "<span class='notice'>You easily destroy the [name].</span>")
for(var/mob/O in oviewers(src))
O.show_message("<span class='warning'>[usr] destroys the [name]!</span>", 1)
health = 0
else
// Aliens can get straight through these.
if(istype(usr,/mob/living/carbon))
var/mob/living/carbon/M = usr
if(locate(/obj/item/organ/internal/xenos/hivenode) in M.internal_organs)
for(var/mob/O in oviewers(src))
O.show_message("<span class='warning'>[usr] strokes the [name] and it melts away!</span>", 1)
health = 0
healthcheck()
return
to_chat(usr, "<span class='notice'>You claw at the [name].</span>")
for(var/mob/O in oviewers(src))
O.show_message("<span class='warning'>[usr] claws at the [name]!</span>", 1)
health -= rand(5,10)
healthcheck()
return
/obj/effect/alien/resin/attackby(obj/item/weapon/W as obj, mob/user as mob)
user.setClickCooldown(user.get_attack_speed(W))
var/aforce = W.force
health = max(0, health - aforce)
playsound(src, 'sound/effects/attackblob.ogg', 100, 1)
healthcheck()
..()
return
/obj/effect/alien/resin/CanPass(atom/movable/mover, turf/target)
if(istype(mover) && mover.checkpass(PASSGLASS))
return !opacity
return !density
/*
* Weeds
*/
@@ -4,8 +4,7 @@
desc = "It looks like a weird egg."
name = "egg"
icon_state = "egg_growing"
density = 0
anchored = 1
density = FALSE
var/progress = 0
/obj/structure/alien/egg/Initialize()
+37 -7
View File
@@ -1,10 +1,11 @@
/obj/structure/alien //Gurg Addition, framework for alien eggs.
/obj/structure/alien //Gurg Addition, framework for alien eggs and structures.
name = "alien thing"
desc = "There's something alien about this."
icon = 'icons/mob/alien.dmi'
layer = ABOVE_JUNK_LAYER
var/health = 50
unacidable = TRUE
anchored = TRUE
/obj/structure/alien/proc/healthcheck()
if(health <=0)
@@ -40,22 +41,51 @@
tforce = 10
else
tforce = AM:throwforce
playsound(loc, 'sound/effects/attackblob.ogg', 100, 1)
playsound(src, 'sound/effects/attackblob.ogg', 100, 1)
health = max(0, health - tforce)
healthcheck()
..()
return
/obj/structure/alien/attack_generic()
attack_hand(usr)
/obj/structure/alien/attack_generic(var/mob/user, var/damage, var/attack_verb)
visible_message("<span class='danger'>[user] [attack_verb] the [src]!</span>")
playsound(src, 'sound/effects/attackblob.ogg', 100, 1)
user.do_attack_animation(src)
health -= damage
healthcheck()
return
/obj/structure/alien/attackby(var/obj/item/weapon/W, var/mob/user)
health = max(0, health - W.force)
playsound(loc, 'sound/effects/attackblob.ogg', 100, 1)
/obj/structure/alien/attackby(obj/item/weapon/W as obj, mob/user as mob)
user.setClickCooldown(user.get_attack_speed(W))
var/aforce = W.force
health = max(0, health - aforce)
playsound(src, 'sound/effects/attackblob.ogg', 100, 1)
visible_message("<span class='danger'>[user] attacks the [src]!</span>")
healthcheck()
..()
return
/obj/structure/alien/attack_hand()
usr.setClickCooldown(DEFAULT_ATTACK_COOLDOWN)
if (HULK in usr.mutations)
visible_message("<span class='warning'>[usr] destroys the [name]!</span>")
health = 0
else
// Aliens can get straight through these.
if(istype(usr,/mob/living/carbon))
var/mob/living/carbon/M = usr
if(locate(/obj/item/organ/internal/xenos/hivenode) in M.internal_organs)
visible_message ("<span class='warning'>[usr] strokes the [name] and it melts away!</span>", 1)
health = 0
healthcheck()
return
visible_message("<span class='warning'>[usr] claws at the [name]!</span>")
health -= rand(5,10)
healthcheck()
return
/obj/structure/alien/CanPass(atom/movable/mover, turf/target, height=0, air_group=0)
if(air_group) return 0
if(istype(mover) && mover.checkpass(PASSGLASS))
@@ -0,0 +1,17 @@
/obj/structure/alien/wall
name = "resin wall"
desc = "A disgusting mass of purple slime solidified into a wall."
icon_state = "resin wall"
health = 200
opacity = 1
density = TRUE
can_atmos_pass = ATMOS_PASS_NO
/obj/structure/alien/membrane
name = "resin membrane"
desc = "A revolting mass of purple slime, it appears to be stretched enough to be transparent."
icon_state = "resin membrane"
opacity = 0
health = 120
density = TRUE
can_atmos_pass = ATMOS_PASS_NO
@@ -35,11 +35,11 @@
/datum/material/resin/generate_recipes()
recipes = list(
new /datum/stack_recipe("[display_name] door", /obj/structure/simple_door/resin, 10, one_per_turf = 1, on_floor = 1, supplied_material = "[name]", pass_stack_color = TRUE),
new /datum/stack_recipe("[display_name] barricade", /obj/effect/alien/resin/wall, 5, time = 5 SECONDS, one_per_turf = 1, on_floor = 1, pass_stack_color = TRUE, recycle_material = "[name]"),
new /datum/stack_recipe("[display_name] barricade", /obj/structure/alien/wall, 5, time = 5 SECONDS, one_per_turf = 1, on_floor = 1, pass_stack_color = TRUE, recycle_material = "[name]"),
new /datum/stack_recipe("[display_name] nest", /obj/structure/bed/nest, 2, one_per_turf = 1, on_floor = 1, supplied_material = "[name]", pass_stack_color = TRUE),
new /datum/stack_recipe("[display_name] wall girders", /obj/structure/girder/resin, 2, time = 5 SECONDS, one_per_turf = 1, on_floor = 1, supplied_material = "[name]", pass_stack_color = TRUE),
new /datum/stack_recipe("crude [display_name] bandage", /obj/item/stack/medical/crude_pack, 1, time = 2 SECONDS, pass_stack_color = TRUE, recycle_material = "[name]"),
new /datum/stack_recipe("[display_name] net", /obj/item/weapon/material/fishing_net, 10, time = 5 SECONDS, supplied_material = "[name]", pass_stack_color = TRUE),
new /datum/stack_recipe("[display_name] membrane", /obj/effect/alien/resin/membrane, 1, time = 2 SECONDS, pass_stack_color = TRUE, recycle_material = "[name]"),
new /datum/stack_recipe("[display_name] membrane", /obj/structure/alien/membrane, 1, time = 2 SECONDS, pass_stack_color = TRUE, recycle_material = "[name]"),
new /datum/stack_recipe("[display_name] node", /obj/effect/alien/weeds/node, 1, time = 4 SECONDS, recycle_material = "[name]")
)
@@ -415,7 +415,10 @@
if(istype(thing, /obj/structure/blob)) // blobs are uncomfortable things
fear_amount += 3
if(istype(thing, /obj/effect/alien/resin)) // Resin's a bit slimy according to its own description.
if(istype(thing, /obj/structure/alien)) // Pretty much anything made by xenos are slimey in some way.
fear_amount += 1
if(istype(thing, /obj/effect/alien/weeds)) // Disgusting slimey carpet.
fear_amount += 1
if(istype(thing, /obj/item/weed_extract))
@@ -225,36 +225,53 @@
spit_name = "acid"
to_chat(src, "<span class='alium'>You prepare to spit acid.</span>")
/mob/living/carbon/human/proc/resin() // -- TLE
/mob/living/carbon/human/proc/resin() //Gurgs : Refactored resin ability, big thanks to Jon.
set name = "Secrete Resin (75)"
set desc = "Secrete tough malleable resin."
set category = "Abilities"
var/choice = tgui_input_list(usr, "Choose what you wish to shape.","Resin building", list("resin door","resin wall","resin membrane","resin nest","resin blob")) //would do it through typesof but then the player choice would have the type path and we don't want the internal workings to be exposed ICly - Urist
if(!choice)
return
var/list/options = list("resin door","resin wall","resin membrane","nest","resin blob")
for(var/option in options)
LAZYSET(options, option, new /image('icons/mob/alien.dmi', option)) // based off 'icons/effects/thinktank_labels.dmi'
if(!check_alien_ability(75,1,O_RESIN))
return
var/choice = show_radial_menu(src, src, options, radius = 42, require_near = TRUE)
visible_message("<span class='warning'><B>[src] vomits up a thick purple substance and begins to shape it!</B></span>", "<span class='alium'>You shape a [choice].</span>")
if(!choice || QDELETED(src) || src.incapacitated())
return FALSE
var/targetLoc = get_step(src, dir)
if(iswall(targetLoc))
targetLoc = get_turf(src)
var/obj/O
switch(choice)
if("resin door")
O = new /obj/structure/simple_door/resin(loc)
if(!check_alien_ability(75,1,O_RESIN))
return
else O = new /obj/structure/simple_door/resin(targetLoc)
if("resin wall")
O = new /obj/effect/alien/resin/wall(loc)
if(!check_alien_ability(75,1,O_RESIN))
return
else O = new /obj/structure/alien/wall(targetLoc)
if("resin membrane")
O = new /obj/effect/alien/resin/membrane(loc)
if("resin nest")
O = new /obj/structure/bed/nest(loc)
if(!check_alien_ability(75,1,O_RESIN))
return
else O = new /obj/structure/alien/membrane(targetLoc)
if("nest")
if(!check_alien_ability(75,1,O_RESIN))
return
else O = new /obj/structure/bed/nest(targetLoc)
if("resin blob")
O = new /obj/item/stack/material/resin(loc)
if(!check_alien_ability(75,1,O_RESIN))
return
else O = new /obj/item/stack/material/resin(targetLoc)
if(O)
visible_message("<span class='warning'><B>[src] vomits up a thick purple substance and begins to shape it!</B></span>", "<span class='alium'>You shape a [choice].</span>")
O.color = "#321D37"
playsound(src, 'sound/effects/blobattack.ogg', 40, 1)
return
Binary file not shown.

Before

Width:  |  Height:  |  Size: 108 KiB

After

Width:  |  Height:  |  Size: 93 KiB

+1
View File
@@ -1498,6 +1498,7 @@
#include "code\game\objects\structures\window_vr.dm"
#include "code\game\objects\structures\alien\alien egg.dm"
#include "code\game\objects\structures\alien\alien.dm"
#include "code\game\objects\structures\alien\resin structures.dm"
#include "code\game\objects\structures\crates_lockers\__closets.dm"
#include "code\game\objects\structures\crates_lockers\_closets_appearance_definitions.dm"
#include "code\game\objects\structures\crates_lockers\_closets_appearance_definitions_vr.dm"