Files
kiwistation/code/datums/components/stationloving.dm
T
nicbn 44a07d712d BoH bombing rework II (#45174)
Ever since the big BoH nerf, BoH bombing is kind of a joke. The damage it does is not really huge, and it's lame for traitors - it lacks emotion and their target may not even die, as they can use the ladders to get away.

So, what this does is add back some soul into BoH bombing, while not making it too round-ending and adding some degree of damage control for admins in case of griefing.
When BoH bombing, a stationary singulo with custom sprite will spawn. Its gravitational pull is REALLY strong, so people near it are probably going to get eaten, and there will be some real damage to the hull. The singulo will cease existing after 5 seconds.

For antags, I think this becomes much more interesting than the current BoH bombing. In the case of griefers, the damage to the station isn't too big because the singulo is stationary and fades away after some seconds. And then, admins can click a button in their chat to bring back everything the singulo ate into the game (the button expires in 10 minutes, however, but this can be changed if you think it is needed).

Settings like gravitational pull can be tweaked if yall find it to be too strong or something.
Changelog

cl
tweak: BoH bombing changed again. Now it's more violent.
/cl
2019-07-25 21:18:01 +12:00

91 lines
3.5 KiB
Plaintext

/datum/component/stationloving
dupe_mode = COMPONENT_DUPE_UNIQUE_PASSARGS
var/inform_admins = FALSE
var/disallow_soul_imbue = TRUE
var/allow_death = FALSE
/datum/component/stationloving/Initialize(inform_admins = FALSE, allow_death = FALSE)
if(!ismovableatom(parent))
return COMPONENT_INCOMPATIBLE
RegisterSignal(parent, list(COMSIG_MOVABLE_Z_CHANGED), .proc/check_in_bounds)
RegisterSignal(parent, list(COMSIG_MOVABLE_SECLUDED_LOCATION), .proc/relocate)
RegisterSignal(parent, list(COMSIG_PARENT_PREQDELETED), .proc/check_deletion)
RegisterSignal(parent, list(COMSIG_ITEM_IMBUE_SOUL), .proc/check_soul_imbue)
RegisterSignal(parent, list(COMSIG_ITEM_MARK_RETRIEVAL), .proc/check_mark_retrieval)
src.inform_admins = inform_admins
src.allow_death = allow_death
check_in_bounds() // Just in case something is being created outside of station/centcom
/datum/component/stationloving/InheritComponent(datum/component/stationloving/newc, original, list/arguments)
if (original)
if (istype(newc))
inform_admins = newc.inform_admins
allow_death = newc.allow_death
else if (LAZYLEN(arguments))
inform_admins = arguments[1]
/datum/component/stationloving/proc/relocate()
var/targetturf = find_safe_turf()
if(!targetturf)
if(GLOB.blobstart.len > 0)
targetturf = get_turf(pick(GLOB.blobstart))
else
CRASH("Unable to find a blobstart landmark")
var/atom/movable/AM = parent
AM.forceMove(targetturf)
to_chat(get(parent, /mob), "<span class='danger'>You can't help but feel that you just lost something back there...</span>")
// move the disc, so ghosts remain orbiting it even if it's "destroyed"
return targetturf
/datum/component/stationloving/proc/check_in_bounds()
if(in_bounds())
return
else
var/turf/currentturf = get_turf(src)
var/turf/targetturf = relocate()
log_game("[parent] has been moved out of bounds in [loc_name(currentturf)]. Moving it to [loc_name(targetturf)].")
if(inform_admins)
message_admins("[parent] has been moved out of bounds in [ADMIN_VERBOSEJMP(currentturf)]. Moving it to [ADMIN_VERBOSEJMP(targetturf)].")
/datum/component/stationloving/proc/check_soul_imbue()
return disallow_soul_imbue
/datum/component/stationloving/proc/check_mark_retrieval()
return COMPONENT_BLOCK_MARK_RETRIEVAL
/datum/component/stationloving/proc/in_bounds()
var/static/list/allowed_shuttles = typecacheof(list(/area/shuttle/syndicate, /area/shuttle/escape, /area/shuttle/pod_1, /area/shuttle/pod_2, /area/shuttle/pod_3, /area/shuttle/pod_4))
var/static/list/disallowed_centcom_areas = typecacheof(list(/area/abductor_ship, /area/awaymission/errorroom))
var/turf/T = get_turf(parent)
if (!T)
return FALSE
var/area/A = T.loc
if (is_station_level(T.z))
return TRUE
if (is_centcom_level(T.z))
if (is_type_in_typecache(A, disallowed_centcom_areas))
return FALSE
return TRUE
if (is_reserved_level(T.z))
if (is_type_in_typecache(A, allowed_shuttles))
return TRUE
return FALSE
/datum/component/stationloving/proc/check_deletion(datum/source, force) // TRUE = interrupt deletion, FALSE = proceed with deletion
var/turf/T = get_turf(parent)
if(inform_admins && force)
message_admins("[parent] has been !!force deleted!! in [ADMIN_VERBOSEJMP(T)].")
log_game("[parent] has been !!force deleted!! in [loc_name(T)].")
if(!force && !allow_death)
var/turf/targetturf = relocate()
log_game("[parent] has been destroyed in [loc_name(T)]. Moving it to [loc_name(targetturf)].")
if(inform_admins)
message_admins("[parent] has been destroyed in [ADMIN_VERBOSEJMP(T)]. Moving it to [ADMIN_VERBOSEJMP(targetturf)].")
return TRUE
return FALSE