mirror of
https://github.com/KabKebab/GS13.git
synced 2026-07-14 09:28:26 +01:00
Merge remote-tracking branch 'upstream/master' into eventchanges
This commit is contained in:
@@ -12,7 +12,8 @@
|
||||
turns_per_move = 5
|
||||
move_to_delay = 1
|
||||
speed = 0
|
||||
see_in_dark = 6
|
||||
see_in_dark = 8
|
||||
lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_INVISIBLE
|
||||
pass_flags = PASSTABLE
|
||||
butcher_results = list(/obj/item/reagent_containers/food/snacks/meat/slab/xeno = 2)
|
||||
response_help = "prods"
|
||||
@@ -20,8 +21,8 @@
|
||||
response_harm = "smacks"
|
||||
melee_damage_lower = 8
|
||||
melee_damage_upper = 12
|
||||
attacktext = "slams"
|
||||
attack_sound = 'sound/weapons/punch1.ogg'
|
||||
attacktext = "glomps"
|
||||
attack_sound = 'sound/effects/blobattack.ogg'
|
||||
atmos_requirements = list("min_oxy" = 0, "max_oxy" = 0, "min_tox" = 0, "max_tox" = 0, "min_co2" = 0, "max_co2" = 0, "min_n2" = 0, "max_n2" = 0)
|
||||
ventcrawler = VENTCRAWLER_ALWAYS
|
||||
blood_volume = 0
|
||||
@@ -33,12 +34,19 @@
|
||||
minbodytemp = 250 //weak to cold
|
||||
maxbodytemp = 1500
|
||||
pressure_resistance = 600
|
||||
sight = SEE_MOBS
|
||||
var/unstealth = FALSE
|
||||
var/knockdown_people = 1
|
||||
var/playerTransformCD = 50
|
||||
var/playerTfTime
|
||||
var/static/mimic_blacklisted_transform_items = typecacheof(list(
|
||||
/obj/item/projectile,
|
||||
/obj/item/radio/intercom))
|
||||
var/turns_since_notarget
|
||||
var/warned
|
||||
var/playstyle_string = "<span class='boldannounce'>You are a mimic,</span></b> a tricky creature that can take the form of \
|
||||
almost any items nearby by shift-clicking it. While morphed, you move slowly and do less damage. \
|
||||
Finally, you can restore yourself to your original form while morphed by shift-clicking yourself. \
|
||||
Attacking carbon lifeforms will heal you at the cost of destructuring their DNA.</b>"
|
||||
|
||||
/mob/living/simple_animal/hostile/hs13mimic/Initialize()
|
||||
. = ..()
|
||||
@@ -52,20 +60,29 @@
|
||||
|
||||
/mob/living/simple_animal/hostile/hs13mimic/Life()
|
||||
. = ..()
|
||||
turns_since_notarget++
|
||||
if(turns_since_notarget >= 5)
|
||||
turns_since_notarget = 0
|
||||
if(unstealth && (!target || isdead(target)))
|
||||
target = null
|
||||
trytftorandomobject()
|
||||
if(src.mind && !warned)
|
||||
SEND_SOUND(src, sound('sound/ambience/antag/ling_aler.ogg'))
|
||||
to_chat(src, src.playstyle_string)
|
||||
warned = TRUE
|
||||
|
||||
/mob/living/simple_animal/hostile/hs13mimic/AttackingTarget()
|
||||
. = ..()
|
||||
if(knockdown_people && . && prob(15) && iscarbon(target))
|
||||
if(iscarbon(target))
|
||||
var/mob/living/carbon/C = target
|
||||
C.Knockdown(40)
|
||||
C.visible_message("<span class='danger'>\The [src] knocks down \the [C]!</span>", \
|
||||
if(unstealth == FALSE && knockdown_people && .) //Guaranteed knockdown if we get the first hit while disguised. Typically, only players can do this since NPC mimics transform first before attacking.
|
||||
unstealth = TRUE
|
||||
restore()
|
||||
C.Knockdown(40)
|
||||
C.visible_message("<span class='danger'>\The [src] knocks down \the [C]!</span>", \
|
||||
"<span class='userdanger'>\The [src] knocks you down!</span>")
|
||||
else if(knockdown_people && . && prob(15))
|
||||
C.Knockdown(40)
|
||||
C.visible_message("<span class='danger'>\The [src] knocks down \the [C]!</span>", \
|
||||
"<span class='userdanger'>\The [src] knocks you down!</span>")
|
||||
if(C.nutrition >= 15)
|
||||
C.nutrition -= (rand(7,15)) //They lose 7-15 nutrition
|
||||
adjustBruteLoss(-3) //We heal 3 damage
|
||||
C.adjustCloneLoss(rand(2,4)) //They also take a bit of cellular damage.
|
||||
|
||||
/mob/living/simple_animal/hostile/hs13mimic/adjustHealth(amount, updating_health = TRUE, forced = FALSE)
|
||||
trigger()
|
||||
@@ -175,11 +192,12 @@
|
||||
icon = 'hyperstation/icons/mobs/mimic.dmi'
|
||||
icon_state = "mimic"
|
||||
desc = initial(desc)
|
||||
speed = initial(speed)
|
||||
wander = TRUE
|
||||
vision_range = 9
|
||||
|
||||
/mob/living/simple_animal/hostile/hs13mimic/proc/trigger()
|
||||
if(unstealth == FALSE)
|
||||
if(unstealth == FALSE && !stat)
|
||||
unstealth = TRUE
|
||||
visible_message("<span class='danger'>The [src] Reveals itself to be a Mimic!</span>")
|
||||
Mimictransform()
|
||||
@@ -197,7 +215,7 @@
|
||||
medhudupdate()
|
||||
var/list/obj/item/listItems = list()
|
||||
for(var/obj/item/I in oview(9,src.loc))
|
||||
if(!(is_type_in_typecache(I, mimic_blacklisted_transform_items)))
|
||||
if(allowed(I))
|
||||
listItems += I
|
||||
if(LAZYLEN(listItems))
|
||||
var/obj/item/changedReference = pick(listItems)
|
||||
@@ -210,6 +228,26 @@
|
||||
else
|
||||
Mimictransform()
|
||||
|
||||
/mob/living/simple_animal/hostile/hs13mimic/proc/allowed(atom/movable/A)
|
||||
return !is_type_in_typecache(A, mimic_blacklisted_transform_items) && (isitem(A))
|
||||
|
||||
/mob/living/simple_animal/hostile/hs13mimic/ShiftClickOn(atom/movable/A) //if by any chance a player takes control of them
|
||||
if(playerTfTime <= world.time && !stat)
|
||||
if(A == src)
|
||||
restore()
|
||||
playerTfTime = world.time + playerTransformCD
|
||||
return
|
||||
if(istype(A) && allowed(A))
|
||||
unstealth = FALSE
|
||||
name = A.name
|
||||
icon = A.icon
|
||||
icon_state = A.icon_state
|
||||
desc = A.desc
|
||||
speed = 5
|
||||
playerTfTime = world.time + playerTransformCD
|
||||
else
|
||||
to_chat(src, "<span class='warning'>You need to wait a little longer before you can shift into something else!</span>")
|
||||
..()
|
||||
|
||||
//Event control
|
||||
|
||||
|
||||
@@ -14,6 +14,7 @@
|
||||
|
||||
/datum/round_event/crystalline_reentry
|
||||
announceWhen = 0
|
||||
startWhen = 10
|
||||
fakeable = FALSE
|
||||
|
||||
/datum/round_event/crystalline_reentry/announce(fake)
|
||||
@@ -177,7 +178,6 @@
|
||||
if(asteroidhealth <= 0)
|
||||
collision_effect()
|
||||
atmos_spawn_air("water_vapor=1000;TEMP=0") //brr
|
||||
make_debris()
|
||||
switch(rand(1,100))
|
||||
if(1 to 20)
|
||||
var/obj/structure/spawner/crystalline/M = new(src.loc)
|
||||
@@ -205,6 +205,7 @@
|
||||
new thing_to_spawn(get_turf(src))
|
||||
|
||||
/obj/effect/crystalline_reentry/proc/collision_effect()
|
||||
make_debris()
|
||||
explosion(src.loc, 0, 0, 5, 3, 1, 0, 0, 0, 0)
|
||||
var/sound/meteor_sound = sound(meteorsound)
|
||||
var/random_frequency = get_rand_frequency()
|
||||
@@ -267,8 +268,8 @@
|
||||
/obj/structure/spawner/crystalline/proc/delayedInitialize()
|
||||
//Why is this needed? Simple, because apparently explosion is so slow that it triggers after the spawner spawns and kills it on the spot. This just makes it killable.
|
||||
resistance_flags = FIRE_PROOF | LAVA_PROOF
|
||||
max_integrity = 250
|
||||
obj_integrity = 250
|
||||
max_integrity = 225
|
||||
obj_integrity = 225
|
||||
|
||||
/obj/effect/light_emitter/crystalline
|
||||
set_luminosity = 4
|
||||
|
||||
Reference in New Issue
Block a user