mirror of
https://github.com/vgstation-coders/vgstation13.git
synced 2025-12-10 10:21:11 +00:00
NEW BOO SYSTEM!
This commit is contained in:
@@ -899,6 +899,7 @@
|
||||
#include "code\modules\mob\dead\observer\logout.dm"
|
||||
#include "code\modules\mob\dead\observer\observer.dm"
|
||||
#include "code\modules\mob\dead\observer\say.dm"
|
||||
#include "code\modules\mob\dead\observer\spells.dm"
|
||||
#include "code\modules\mob\living\damage_procs.dm"
|
||||
#include "code\modules\mob\living\living.dm"
|
||||
#include "code\modules\mob\living\living_defense.dm"
|
||||
|
||||
@@ -19,6 +19,7 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
|
||||
var/holder_var_type = "bruteloss" //only used if charge_type equals to "holder_var"
|
||||
var/holder_var_amount = 20 //same. The amount adjusted with the mob's var when the spell is used
|
||||
|
||||
var/ghost = 0 // Skip life check.
|
||||
var/clothes_req = 1 //see if it requires clothes
|
||||
var/stat_allowed = 0 //see if it requires being conscious/alive, need to set to 1 for ghostpells
|
||||
var/invocation = "HURP DURP" //what is uttered when the wizard casts the spell
|
||||
@@ -59,15 +60,15 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
|
||||
if(!charge_counter)
|
||||
usr << "[name] has no charges left."
|
||||
return 0
|
||||
|
||||
if(usr.stat && !stat_allowed)
|
||||
usr << "Not when you're incapacitated."
|
||||
return 0
|
||||
|
||||
if(ishuman(usr) || ismonkey(usr))
|
||||
if(istype(usr.wear_mask, /obj/item/clothing/mask/muzzle))
|
||||
usr << "Mmmf mrrfff!"
|
||||
if(!ghost)
|
||||
if(usr.stat && !stat_allowed)
|
||||
usr << "Not when you're incapacitated."
|
||||
return 0
|
||||
|
||||
if(ishuman(usr) || ismonkey(usr))
|
||||
if(istype(usr.wear_mask, /obj/item/clothing/mask/muzzle))
|
||||
usr << "Mmmf mrrfff!"
|
||||
return 0
|
||||
var/obj/effect/proc_holder/spell/noclothes/spell = locate() in user.spell_list
|
||||
if(clothes_req && !(spell && istype(spell)))//clothes check
|
||||
if(!istype(usr, /mob/living/carbon/human))
|
||||
|
||||
@@ -36,6 +36,8 @@
|
||||
|
||||
var/friendc = 0 // track if Friend Computer mode
|
||||
|
||||
var/spookymode=0 // Ghosts.
|
||||
|
||||
maptext_height = 26
|
||||
maptext_width = 32
|
||||
|
||||
@@ -49,11 +51,14 @@
|
||||
|
||||
|
||||
// timed process
|
||||
|
||||
process()
|
||||
if(stat & NOPOWER)
|
||||
remove_display()
|
||||
return
|
||||
if(spookymode)
|
||||
spookymode = 0
|
||||
remove_display()
|
||||
return
|
||||
update()
|
||||
|
||||
emp_act(severity)
|
||||
@@ -206,6 +211,8 @@
|
||||
anchored = 1
|
||||
density = 0
|
||||
|
||||
var/spookymode=0 // Ghosts
|
||||
|
||||
var/mode = 0 // 0 = Blank
|
||||
// 1 = AI emoticon
|
||||
// 2 = Blue screen of death
|
||||
@@ -219,6 +226,10 @@
|
||||
if(stat & NOPOWER)
|
||||
overlays.Cut()
|
||||
return
|
||||
if(spookymode)
|
||||
spookymode = 0
|
||||
overlays.Cut()
|
||||
return
|
||||
|
||||
update()
|
||||
|
||||
|
||||
@@ -36,6 +36,9 @@
|
||||
see_in_dark = 100
|
||||
verbs += /mob/dead/observer/proc/dead_tele
|
||||
|
||||
// Our new boo spell.
|
||||
spell_list += new /obj/effect/proc_holder/spell/aoe_turf/boo(src)
|
||||
|
||||
can_reenter_corpse = flags & GHOST_CAN_REENTER
|
||||
started_as_observer = flags & GHOST_IS_OBSERVER
|
||||
|
||||
@@ -441,19 +444,20 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
else
|
||||
A << "This mob is not located in the game world."
|
||||
|
||||
/* Now a spell. See spells.dm
|
||||
/mob/dead/observer/verb/boo()
|
||||
set category = "Ghost"
|
||||
set name = "Boo!"
|
||||
set desc= "Scare your crew members because of boredom!"
|
||||
|
||||
if(bootime > world.time) return
|
||||
bootime = world.time + 600
|
||||
var/obj/machinery/light/L = locate(/obj/machinery/light) in view(1, src)
|
||||
if(L)
|
||||
L.flicker()
|
||||
bootime = world.time + 600
|
||||
return
|
||||
//Maybe in the future we can add more <i>spooky</i> code here!
|
||||
return
|
||||
*/
|
||||
|
||||
/mob/dead/observer/memory()
|
||||
set hidden = 1
|
||||
@@ -466,9 +470,9 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
/mob/dead/observer/verb/analyze_air()
|
||||
set name = "Analyze Air"
|
||||
set category = "Ghost"
|
||||
|
||||
|
||||
if(!istype(usr, /mob/dead/observer)) return
|
||||
|
||||
|
||||
// Shamelessly copied from the Gas Analyzers
|
||||
if (!( istype(usr.loc, /turf) ))
|
||||
return
|
||||
|
||||
@@ -24,6 +24,7 @@
|
||||
anchored = 1
|
||||
use_power = 0
|
||||
req_access = list(access_engine_equip)
|
||||
var/spooky=0
|
||||
var/area/area
|
||||
var/areastring = null
|
||||
var/obj/item/weapon/cell/cell
|
||||
@@ -165,7 +166,7 @@
|
||||
icon_state = "[basestate]-nocover"
|
||||
else if (stat & BROKEN)
|
||||
icon_state = "apc-b"
|
||||
else if(emagged || malfai)
|
||||
else if(emagged || malfai || spooky)
|
||||
icon_state = "apcemag"
|
||||
else if(wiresexposed)
|
||||
icon_state = "apcewires"
|
||||
@@ -187,8 +188,15 @@
|
||||
update_icon()
|
||||
updating_icon = 0
|
||||
|
||||
//attack with an item - open/close cover, insert cell, or (un)lock interface
|
||||
/obj/machinery/power/apc/proc/spookify()
|
||||
if(spooky) return // Fuck you we're already spooky
|
||||
spooky=1
|
||||
update_icon()
|
||||
spawn(10)
|
||||
spooky=0
|
||||
update_icon()
|
||||
|
||||
//attack with an item - open/close cover, insert cell, or (un)lock interface
|
||||
/obj/machinery/power/apc/attackby(obj/item/W, mob/user)
|
||||
|
||||
if (istype(user, /mob/living/silicon) && get_dist(src,user)>1)
|
||||
@@ -846,7 +854,6 @@
|
||||
if(!area.requires_power)
|
||||
return
|
||||
|
||||
|
||||
/*
|
||||
if (equipment > 1) // off=0, off auto=1, on=2, on auto=3
|
||||
use_power(src.equip_consumption, EQUIP)
|
||||
@@ -995,7 +1002,6 @@
|
||||
area.poweralert(0, src)
|
||||
|
||||
// update icon & area power if anything changed
|
||||
|
||||
if(last_lt != lighting || last_eq != equipment || last_en != environ)
|
||||
queue_icon_update()
|
||||
update()
|
||||
|
||||
@@ -451,8 +451,13 @@
|
||||
update(0)
|
||||
flickering = 0
|
||||
|
||||
// ai attack - make lights flicker, because why not
|
||||
/obj/machinery/light/attack_ghost(mob/user)
|
||||
if(blessed) return
|
||||
src.add_hiddenprint(user)
|
||||
src.flicker(1)
|
||||
return
|
||||
|
||||
// ai attack - make lights flicker, because why not
|
||||
/obj/machinery/light/attack_ai(mob/user)
|
||||
// attack_robot is flaky.
|
||||
if(isMoMMI(user))
|
||||
|
||||
Reference in New Issue
Block a user