mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-30 08:37:43 +01:00
Fixes turrets being invisible (#79377)
They're invisible by default apparently, not visible. When I was going over invisibility var sets I assumed the wrong default. fixes #79181 🆑 ninjanomnom fix: Fixes turrets being invisible when they shouldn't be /🆑
This commit is contained in:
@@ -64,7 +64,8 @@
|
||||
// INVISIBILITY PRIORITIES
|
||||
|
||||
#define INVISIBILITY_PRIORITY_ADMIN 100
|
||||
#define INVISIBILITY_PRIORITY_BASIC_ANTI_INVISIBILITY 1
|
||||
#define INVISIBILITY_PRIORITY_TURRET_COVER 20
|
||||
#define INVISIBILITY_PRIORITY_BASIC_ANTI_INVISIBILITY 10
|
||||
#define INVISIBILITY_PRIORITY_NONE 0
|
||||
|
||||
//------------------------
|
||||
|
||||
+3
-3
@@ -2271,12 +2271,12 @@
|
||||
RecalculateInvisibility()
|
||||
|
||||
/// Removes the specified invisibility source from the tracker
|
||||
/atom/proc/RemoveInvisibility(source_id)
|
||||
/atom/proc/RemoveInvisibility(id)
|
||||
if(!invisibility_sources)
|
||||
return
|
||||
|
||||
var/list/priority_data = invisibility_sources[source_id]
|
||||
invisibility_sources -= source_id
|
||||
var/list/priority_data = invisibility_sources[id]
|
||||
invisibility_sources -= id
|
||||
|
||||
if(length(invisibility_sources) == 0)
|
||||
invisibility_sources = null
|
||||
|
||||
@@ -326,7 +326,7 @@ DEFINE_BITFIELD(turret_flags, list(
|
||||
//This code handles moving the turret around. After all, it's a portable turret!
|
||||
if(!anchored && !isinspace())
|
||||
set_anchored(TRUE)
|
||||
SetInvisibility(INVISIBILITY_MAXIMUM, id=type)
|
||||
RemoveInvisibility(id=type)
|
||||
update_appearance()
|
||||
to_chat(user, span_notice("You secure the exterior bolts on the turret."))
|
||||
if(has_cover)
|
||||
@@ -336,7 +336,7 @@ DEFINE_BITFIELD(turret_flags, list(
|
||||
set_anchored(FALSE)
|
||||
to_chat(user, span_notice("You unsecure the exterior bolts on the turret."))
|
||||
power_change()
|
||||
RemoveInvisibility(type)
|
||||
SetInvisibility(INVISIBILITY_NONE, id=type)
|
||||
qdel(cover) //deletes the cover, and the turret instance itself becomes its own cover.
|
||||
|
||||
else if(I.GetID())
|
||||
@@ -407,7 +407,7 @@ DEFINE_BITFIELD(turret_flags, list(
|
||||
. = ..()
|
||||
if(.)
|
||||
power_change()
|
||||
RemoveInvisibility(type)
|
||||
SetInvisibility(INVISIBILITY_NONE, id=type)
|
||||
spark_system.start() //creates some sparks because they look cool
|
||||
qdel(cover) //deletes the cover - no need on keeping it there!
|
||||
|
||||
@@ -514,7 +514,7 @@ DEFINE_BITFIELD(turret_flags, list(
|
||||
return
|
||||
if(machine_stat & BROKEN)
|
||||
return
|
||||
RemoveInvisibility(type)
|
||||
SetInvisibility(INVISIBILITY_NONE, id=type)
|
||||
raising = 1
|
||||
if(cover)
|
||||
flick("popup", cover)
|
||||
|
||||
@@ -43,12 +43,12 @@
|
||||
if(!parent_turret.anchored)
|
||||
parent_turret.set_anchored(TRUE)
|
||||
to_chat(user, span_notice("You secure the exterior bolts on the turret."))
|
||||
parent_turret.RemoveInvisibility(type)
|
||||
parent_turret.SetInvisibility(INVISIBILITY_NONE, id=type, priority=INVISIBILITY_PRIORITY_TURRET_COVER)
|
||||
parent_turret.update_appearance()
|
||||
else
|
||||
parent_turret.set_anchored(FALSE)
|
||||
to_chat(user, span_notice("You unsecure the exterior bolts on the turret."))
|
||||
parent_turret.SetInvisibility(INVISIBILITY_MAXIMUM, id=type)
|
||||
parent_turret.SetInvisibility(INVISIBILITY_MAXIMUM, id=type, priority=INVISIBILITY_PRIORITY_TURRET_COVER)
|
||||
parent_turret.update_appearance()
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user