Merge pull request #1243 from Citadel-Station-13/upstream-merge-27725
[MIRROR] Changes incorporeal movement to use defines
This commit is contained in:
@@ -124,3 +124,8 @@
|
||||
#define MAX_CHICKENS 50
|
||||
|
||||
#define UNHEALING_EAR_DAMAGE 100
|
||||
|
||||
|
||||
#define INCORPOREAL_MOVE_BASIC 1
|
||||
#define INCORPOREAL_MOVE_SHADOW 2 // leaves a trail of shadows
|
||||
#define INCORPOREAL_MOVE_JAUNT 3 // is blocked by holy water/salt
|
||||
@@ -15,7 +15,7 @@
|
||||
var/icon_stun = "revenant_stun"
|
||||
var/icon_drain = "revenant_draining"
|
||||
var/stasis = FALSE
|
||||
incorporeal_move = 3
|
||||
incorporeal_move = INCORPOREAL_MOVE_JAUNT
|
||||
invisibility = INVISIBILITY_REVENANT
|
||||
health = INFINITY //Revenants don't use health, they use essence instead
|
||||
maxHealth = INFINITY
|
||||
@@ -102,7 +102,7 @@
|
||||
if(unreveal_time && world.time >= unreveal_time)
|
||||
unreveal_time = 0
|
||||
revealed = FALSE
|
||||
incorporeal_move = 3
|
||||
incorporeal_move = INCORPOREAL_MOVE_JAUNT
|
||||
invisibility = INVISIBILITY_REVENANT
|
||||
to_chat(src, "<span class='revenboldnotice'>You are once more concealed.</span>")
|
||||
if(unstun_time && world.time >= unstun_time)
|
||||
@@ -222,7 +222,7 @@
|
||||
R.essence = max(reforming_essence - 15 * perfectsouls, 75) //minus any perfect souls
|
||||
R.client_to_revive = client //If the essence reforms, the old revenant is put back in the body
|
||||
R.revenant = src
|
||||
invisibility = INVISIBILITY_ABSTRACT
|
||||
invisibility = INVISIBILITY_ABSTRACT
|
||||
revealed = FALSE
|
||||
ghostize(0)//Don't re-enter invisible corpse
|
||||
return
|
||||
@@ -236,7 +236,7 @@
|
||||
return
|
||||
revealed = TRUE
|
||||
invisibility = 0
|
||||
incorporeal_move = 0
|
||||
incorporeal_move = FALSE
|
||||
if(!unreveal_time)
|
||||
to_chat(src, "<span class='revendanger'>You have been revealed!</span>")
|
||||
unreveal_time = world.time + time
|
||||
@@ -309,12 +309,12 @@
|
||||
|
||||
/mob/living/simple_animal/revenant/proc/death_reset()
|
||||
revealed = FALSE
|
||||
unreveal_time = 0
|
||||
unreveal_time = 0
|
||||
notransform = 0
|
||||
unstun_time = 0
|
||||
inhibited = FALSE
|
||||
draining = FALSE
|
||||
incorporeal_move = 3
|
||||
incorporeal_move = INCORPOREAL_MOVE_JAUNT
|
||||
invisibility = INVISIBILITY_REVENANT
|
||||
alpha=255
|
||||
stasis = FALSE
|
||||
|
||||
@@ -541,5 +541,5 @@
|
||||
name = "spooky ghost"
|
||||
desc = "this is obviously just a bedsheet, but maybe try it on?"
|
||||
icon_state = "bedsheet"
|
||||
user_vars_to_edit = list("name" = "Spooky Ghost", "real_name" = "Spooky Ghost" , "incorporeal_move" = 1, "appearance_flags" = KEEP_TOGETHER|TILE_BOUND, "alpha" = 150)
|
||||
user_vars_to_edit = list("name" = "Spooky Ghost", "real_name" = "Spooky Ghost" , "incorporeal_move" = INCORPOREAL_MOVE_BASIC, "appearance_flags" = KEEP_TOGETHER|TILE_BOUND, "alpha" = 150)
|
||||
alternate_worn_layer = ABOVE_BODY_FRONT_LAYER //so the bedsheet goes over everything but fire
|
||||
|
||||
@@ -24,7 +24,8 @@
|
||||
var/last_special = 0 //Used by the resist verb, likely used to prevent players from bypassing next_move by logging in/out.
|
||||
|
||||
//Allows mobs to move through dense areas without restriction. For instance, in space or out of holder objects.
|
||||
var/incorporeal_move = 0 //0 is off, 1 is normal, 2 is for ninjas.
|
||||
var/incorporeal_move = FALSE //FALSE is off, INCORPOREAL_MOVE_BASIC is normal, INCORPOREAL_MOVE_SHADOW is for ninjas
|
||||
//and INCORPOREAL_MOVE_JAUNT is blocked by holy water/salt
|
||||
|
||||
var/list/surgeries = list() //a list of surgery datums. generally empty, they're added when the player wants them.
|
||||
|
||||
|
||||
@@ -37,7 +37,7 @@
|
||||
environment_smash = initial(environment_smash)
|
||||
alpha = 255
|
||||
range = initial(range)
|
||||
incorporeal_move = 0
|
||||
incorporeal_move = FALSE
|
||||
to_chat(src, "<span class='danger'><B>You switch to combat mode.</span></B>")
|
||||
toggle = FALSE
|
||||
else
|
||||
@@ -48,7 +48,7 @@
|
||||
environment_smash = ENVIRONMENT_SMASH_NONE
|
||||
alpha = 45
|
||||
range = 255
|
||||
incorporeal_move = 1
|
||||
incorporeal_move = INCORPOREAL_MOVE_BASIC
|
||||
to_chat(src, "<span class='danger'><B>You switch to scout mode.</span></B>")
|
||||
toggle = TRUE
|
||||
else
|
||||
|
||||
@@ -948,7 +948,7 @@
|
||||
color = "#FFFFFF77"
|
||||
speak_chance = 20
|
||||
status_flags = GODMODE
|
||||
incorporeal_move = 1
|
||||
incorporeal_move = INCORPOREAL_MOVE_BASIC
|
||||
butcher_results = list(/obj/item/weapon/ectoplasm = 1)
|
||||
|
||||
/mob/living/simple_animal/parrot/Poly/ghost/Initialize()
|
||||
|
||||
@@ -209,10 +209,10 @@
|
||||
return
|
||||
var/mob/living/L = mob
|
||||
switch(L.incorporeal_move)
|
||||
if(1)
|
||||
if(INCORPOREAL_MOVE_BASIC)
|
||||
L.loc = get_step(L, direct)
|
||||
L.setDir(direct)
|
||||
if(2)
|
||||
if(INCORPOREAL_MOVE_SHADOW)
|
||||
if(prob(50))
|
||||
var/locx
|
||||
var/locy
|
||||
@@ -250,7 +250,7 @@
|
||||
new /obj/effect/temp_visual/dir_setting/ninja/shadow(mobloc, L.dir)
|
||||
L.loc = get_step(L, direct)
|
||||
L.setDir(direct)
|
||||
if(3) //Incorporeal move, but blocked by holy-watered tiles and salt piles.
|
||||
if(INCORPOREAL_MOVE_JAUNT) //Incorporeal move, but blocked by holy-watered tiles and salt piles.
|
||||
var/turf/open/floor/stepTurf = get_step(L, direct)
|
||||
for(var/obj/effect/decal/cleanable/salt/S in stepTurf)
|
||||
to_chat(L, "<span class='warning'>[S] bars your passage!</span>")
|
||||
|
||||
Reference in New Issue
Block a user