mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-22 20:48:56 +01:00
[MIRROR] [READY] Refactor icon smoothing to use 8-bit bitmasking (#1053)
* Merge pull request #53906 from Rohesie/smoothing [READY] Refactor icon smoothing to use 8-bit bitmasking * [READY] Refactor icon smoothing to use 8-bit bitmasking Co-authored-by: nemvar <47324920+nemvar@users.noreply.github.com>
This commit is contained in:
@@ -53,11 +53,12 @@
|
||||
name = "resin"
|
||||
desc = "Looks like some kind of thick resin."
|
||||
icon = 'icons/obj/smooth_structures/alien/resin_wall.dmi'
|
||||
icon_state = "smooth"
|
||||
icon_state = "resin_wall-0"
|
||||
base_icon_state = "resin_wall"
|
||||
density = TRUE
|
||||
opacity = TRUE
|
||||
anchored = TRUE
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_ALIEN_RESIN)
|
||||
canSmoothWith = list(SMOOTH_GROUP_ALIEN_RESIN)
|
||||
max_integrity = 200
|
||||
@@ -78,7 +79,8 @@
|
||||
name = "resin wall"
|
||||
desc = "Thick resin solidified into a wall."
|
||||
icon = 'icons/obj/smooth_structures/alien/resin_wall.dmi'
|
||||
icon_state = "smooth" //same as resin, but consistency ho!
|
||||
icon_state = "resin_wall-0"
|
||||
base_icon_state = "resin_wall"
|
||||
resintype = "wall"
|
||||
smoothing_groups = list(SMOOTH_GROUP_ALIEN_RESIN, SMOOTH_GROUP_ALIEN_WALLS)
|
||||
canSmoothWith = list(SMOOTH_GROUP_ALIEN_WALLS)
|
||||
@@ -90,7 +92,8 @@
|
||||
name = "resin membrane"
|
||||
desc = "Resin just thin enough to let light pass through."
|
||||
icon = 'icons/obj/smooth_structures/alien/resin_membrane.dmi'
|
||||
icon_state = "smooth"
|
||||
icon_state = "resin_membrane-0"
|
||||
base_icon_state = "resin_membrane"
|
||||
opacity = FALSE
|
||||
max_integrity = 160
|
||||
resintype = "membrane"
|
||||
@@ -114,9 +117,11 @@
|
||||
density = FALSE
|
||||
layer = TURF_LAYER
|
||||
plane = FLOOR_PLANE
|
||||
icon_state = "weeds"
|
||||
icon = 'icons/obj/smooth_structures/alien/weeds1.dmi'
|
||||
icon_state = "weeds1-0"
|
||||
base_icon_state = "weeds1"
|
||||
max_integrity = 15
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_ALIEN_RESIN, SMOOTH_GROUP_ALIEN_WEEDS)
|
||||
canSmoothWith = list(SMOOTH_GROUP_ALIEN_WEEDS, SMOOTH_GROUP_WALLS)
|
||||
var/last_expand = 0 //last world.time this weed expanded
|
||||
@@ -124,9 +129,11 @@
|
||||
var/growth_cooldown_high = 200
|
||||
var/static/list/blacklisted_turfs
|
||||
|
||||
|
||||
/obj/structure/alien/weeds/Initialize()
|
||||
pixel_x = -4
|
||||
pixel_y = -4 //so the sprites line up right in the map editor
|
||||
|
||||
. = ..()
|
||||
|
||||
if(!blacklisted_turfs)
|
||||
@@ -135,16 +142,26 @@
|
||||
/turf/open/chasm,
|
||||
/turf/open/lava))
|
||||
|
||||
set_base_icon()
|
||||
|
||||
last_expand = world.time + rand(growth_cooldown_low, growth_cooldown_high)
|
||||
if(icon == initial(icon))
|
||||
switch(rand(1,3))
|
||||
if(1)
|
||||
icon = 'icons/obj/smooth_structures/alien/weeds1.dmi'
|
||||
if(2)
|
||||
icon = 'icons/obj/smooth_structures/alien/weeds2.dmi'
|
||||
if(3)
|
||||
icon = 'icons/obj/smooth_structures/alien/weeds3.dmi'
|
||||
|
||||
|
||||
///Randomizes the weeds' starting icon, gets redefined by children for them not to share the behavior.
|
||||
/obj/structure/alien/weeds/proc/set_base_icon()
|
||||
. = base_icon_state
|
||||
switch(rand(1,3))
|
||||
if(1)
|
||||
icon = 'icons/obj/smooth_structures/alien/weeds1.dmi'
|
||||
base_icon_state = "weeds1"
|
||||
if(2)
|
||||
icon = 'icons/obj/smooth_structures/alien/weeds2.dmi'
|
||||
base_icon_state = "weeds2"
|
||||
if(3)
|
||||
icon = 'icons/obj/smooth_structures/alien/weeds3.dmi'
|
||||
base_icon_state = "weeds3"
|
||||
set_smoothed_icon_state(smoothing_junction)
|
||||
|
||||
|
||||
/obj/structure/alien/weeds/proc/expand()
|
||||
var/turf/U = get_turf(src)
|
||||
@@ -170,14 +187,16 @@
|
||||
/obj/structure/alien/weeds/node
|
||||
name = "glowing resin"
|
||||
desc = "Blue bioluminescence shines from beneath the surface."
|
||||
icon_state = "weednode"
|
||||
icon = 'icons/obj/smooth_structures/alien/weednode.dmi'
|
||||
icon_state = "weednode-0"
|
||||
base_icon_state = "weednode"
|
||||
light_color = LIGHT_COLOR_BLUE
|
||||
light_power = 0.5
|
||||
var/lon_range = 4
|
||||
var/node_range = NODERANGE
|
||||
|
||||
|
||||
/obj/structure/alien/weeds/node/Initialize()
|
||||
icon = 'icons/obj/smooth_structures/alien/weednode.dmi'
|
||||
. = ..()
|
||||
set_light(lon_range)
|
||||
var/obj/structure/alien/weeds/W = locate(/obj/structure/alien/weeds) in loc
|
||||
@@ -185,16 +204,23 @@
|
||||
qdel(W)
|
||||
START_PROCESSING(SSobj, src)
|
||||
|
||||
|
||||
/obj/structure/alien/weeds/node/Destroy()
|
||||
STOP_PROCESSING(SSobj, src)
|
||||
return ..()
|
||||
|
||||
|
||||
/obj/structure/alien/weeds/node/process()
|
||||
for(var/obj/structure/alien/weeds/W in range(node_range, src))
|
||||
if(W.last_expand <= world.time)
|
||||
if(W.expand())
|
||||
W.last_expand = world.time + rand(growth_cooldown_low, growth_cooldown_high)
|
||||
|
||||
|
||||
/obj/structure/alien/weeds/node/set_base_icon()
|
||||
return //No icon randomization at init. The node's icon is already well defined.
|
||||
|
||||
|
||||
#undef NODERANGE
|
||||
|
||||
|
||||
|
||||
@@ -4,11 +4,13 @@
|
||||
name = "alien nest"
|
||||
desc = "It's a gruesome pile of thick, sticky resin shaped like a nest."
|
||||
icon = 'icons/obj/smooth_structures/alien/nest.dmi'
|
||||
icon_state = "nest"
|
||||
icon_state = "nest-0"
|
||||
base_icon_state = "nest"
|
||||
max_integrity = 120
|
||||
can_be_unanchored = FALSE
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
canSmoothWith = null
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_ALIEN_NEST)
|
||||
canSmoothWith = list(SMOOTH_GROUP_ALIEN_NEST)
|
||||
buildstacktype = null
|
||||
flags_1 = NODECONSTRUCT_1
|
||||
bolts = FALSE
|
||||
|
||||
@@ -6,12 +6,13 @@
|
||||
desc = "A huge chunk of metal used to separate rooms."
|
||||
anchored = TRUE
|
||||
icon = 'icons/turf/walls/wall.dmi'
|
||||
icon_state = "wall"
|
||||
icon_state = "wall-0"
|
||||
base_icon_state = "wall"
|
||||
layer = LOW_OBJ_LAYER
|
||||
density = TRUE
|
||||
opacity = TRUE
|
||||
max_integrity = 100
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_CLOSED_TURFS, SMOOTH_GROUP_WALLS)
|
||||
canSmoothWith = list(SMOOTH_GROUP_WALLS)
|
||||
can_be_unanchored = FALSE
|
||||
@@ -63,8 +64,8 @@
|
||||
icon_state = "fwall_closing"
|
||||
else
|
||||
if(density)
|
||||
icon_state = initial(icon_state)
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
icon_state = "[base_icon_state]-[smoothing_junction]"
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
QUEUE_SMOOTH(src)
|
||||
else
|
||||
icon_state = "fwall_open"
|
||||
@@ -133,9 +134,11 @@
|
||||
name = "reinforced wall"
|
||||
desc = "A huge chunk of reinforced metal used to separate rooms."
|
||||
icon = 'icons/turf/walls/reinforced_wall.dmi'
|
||||
icon_state = "r_wall"
|
||||
icon_state = "reinforced_wall-0"
|
||||
base_icon_state = "reinforced_wall"
|
||||
walltype = /turf/closed/wall/r_wall
|
||||
mineral = /obj/item/stack/sheet/plasteel
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
|
||||
/obj/structure/falsewall/reinforced/examine_status(mob/user)
|
||||
to_chat(user, "<span class='notice'>The outer <b>grille</b> is fully intact.</span>")
|
||||
@@ -154,9 +157,11 @@
|
||||
name = "uranium wall"
|
||||
desc = "A wall with uranium plating. This is probably a bad idea."
|
||||
icon = 'icons/turf/walls/uranium_wall.dmi'
|
||||
icon_state = "uranium"
|
||||
icon_state = "uranium_wall-0"
|
||||
base_icon_state = "uranium_wall"
|
||||
mineral = /obj/item/stack/sheet/mineral/uranium
|
||||
walltype = /turf/closed/wall/mineral/uranium
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_WALLS, SMOOTH_GROUP_URANIUM_WALLS)
|
||||
canSmoothWith = list(SMOOTH_GROUP_URANIUM_WALLS)
|
||||
var/active = null
|
||||
@@ -189,9 +194,11 @@
|
||||
name = "gold wall"
|
||||
desc = "A wall with gold plating. Swag!"
|
||||
icon = 'icons/turf/walls/gold_wall.dmi'
|
||||
icon_state = "gold"
|
||||
icon_state = "gold_wall-0"
|
||||
base_icon_state = "gold_wall"
|
||||
mineral = /obj/item/stack/sheet/mineral/gold
|
||||
walltype = /turf/closed/wall/mineral/gold
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_WALLS, SMOOTH_GROUP_GOLD_WALLS)
|
||||
canSmoothWith = list(SMOOTH_GROUP_GOLD_WALLS)
|
||||
|
||||
@@ -199,9 +206,11 @@
|
||||
name = "silver wall"
|
||||
desc = "A wall with silver plating. Shiny."
|
||||
icon = 'icons/turf/walls/silver_wall.dmi'
|
||||
icon_state = "silver"
|
||||
icon_state = "silver_wall-0"
|
||||
base_icon_state = "silver_wall"
|
||||
mineral = /obj/item/stack/sheet/mineral/silver
|
||||
walltype = /turf/closed/wall/mineral/silver
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_WALLS, SMOOTH_GROUP_SILVER_WALLS)
|
||||
canSmoothWith = list(SMOOTH_GROUP_SILVER_WALLS)
|
||||
|
||||
@@ -209,9 +218,11 @@
|
||||
name = "diamond wall"
|
||||
desc = "A wall with diamond plating. You monster."
|
||||
icon = 'icons/turf/walls/diamond_wall.dmi'
|
||||
icon_state = "diamond"
|
||||
icon_state = "diamond_wall-0"
|
||||
base_icon_state = "diamond_wall"
|
||||
mineral = /obj/item/stack/sheet/mineral/diamond
|
||||
walltype = /turf/closed/wall/mineral/diamond
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_WALLS, SMOOTH_GROUP_DIAMOND_WALLS)
|
||||
canSmoothWith = list(SMOOTH_GROUP_DIAMOND_WALLS)
|
||||
max_integrity = 800
|
||||
@@ -220,9 +231,11 @@
|
||||
name = "plasma wall"
|
||||
desc = "A wall with plasma plating. This is definitely a bad idea."
|
||||
icon = 'icons/turf/walls/plasma_wall.dmi'
|
||||
icon_state = "plasma"
|
||||
icon_state = "plasma_wall-0"
|
||||
base_icon_state = "plasma_wall"
|
||||
mineral = /obj/item/stack/sheet/mineral/plasma
|
||||
walltype = /turf/closed/wall/mineral/plasma
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_WALLS, SMOOTH_GROUP_PLASMA_WALLS)
|
||||
canSmoothWith = list(SMOOTH_GROUP_PLASMA_WALLS)
|
||||
|
||||
@@ -249,9 +262,11 @@
|
||||
name = "bananium wall"
|
||||
desc = "A wall with bananium plating. Honk!"
|
||||
icon = 'icons/turf/walls/bananium_wall.dmi'
|
||||
icon_state = "bananium"
|
||||
icon_state = "bananium_wall-0"
|
||||
base_icon_state = "bananium_wall"
|
||||
mineral = /obj/item/stack/sheet/mineral/bananium
|
||||
walltype = /turf/closed/wall/mineral/bananium
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_WALLS, SMOOTH_GROUP_BANANIUM_WALLS)
|
||||
canSmoothWith = list(SMOOTH_GROUP_BANANIUM_WALLS)
|
||||
|
||||
@@ -260,9 +275,11 @@
|
||||
name = "sandstone wall"
|
||||
desc = "A wall with sandstone plating. Rough."
|
||||
icon = 'icons/turf/walls/sandstone_wall.dmi'
|
||||
icon_state = "sandstone"
|
||||
icon_state = "sandstone_wall-0"
|
||||
base_icon_state = "sandstone_wall"
|
||||
mineral = /obj/item/stack/sheet/mineral/sandstone
|
||||
walltype = /turf/closed/wall/mineral/sandstone
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_WALLS, SMOOTH_GROUP_SANDSTONE_WALLS)
|
||||
canSmoothWith = list(SMOOTH_GROUP_SANDSTONE_WALLS)
|
||||
|
||||
@@ -270,9 +287,11 @@
|
||||
name = "wooden wall"
|
||||
desc = "A wall with wooden plating. Stiff."
|
||||
icon = 'icons/turf/walls/wood_wall.dmi'
|
||||
icon_state = "wood"
|
||||
icon_state = "wood_wall-0"
|
||||
base_icon_state = "wood_wall"
|
||||
mineral = /obj/item/stack/sheet/mineral/wood
|
||||
walltype = /turf/closed/wall/mineral/wood
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_WALLS, SMOOTH_GROUP_WOOD_WALLS)
|
||||
canSmoothWith = list(SMOOTH_GROUP_WOOD_WALLS)
|
||||
|
||||
@@ -280,10 +299,13 @@
|
||||
name = "rough metal wall"
|
||||
desc = "A wall with rough metal plating."
|
||||
icon = 'icons/turf/walls/iron_wall.dmi'
|
||||
icon_state = "iron"
|
||||
icon_state = "iron_wall-0"
|
||||
base_icon_state = "iron_wall"
|
||||
mineral = /obj/item/stack/rods
|
||||
mineral_amount = 5
|
||||
walltype = /turf/closed/wall/mineral/iron
|
||||
base_icon_state = "icerock_wall"
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_WALLS, SMOOTH_GROUP_IRON_WALLS)
|
||||
canSmoothWith = list(SMOOTH_GROUP_IRON_WALLS)
|
||||
|
||||
@@ -291,9 +313,11 @@
|
||||
name = "alien wall"
|
||||
desc = "A wall with alien alloy plating."
|
||||
icon = 'icons/turf/walls/abductor_wall.dmi'
|
||||
icon_state = "abductor"
|
||||
icon_state = "abductor_wall-0"
|
||||
base_icon_state = "abductor_wall"
|
||||
mineral = /obj/item/stack/sheet/mineral/abductor
|
||||
walltype = /turf/closed/wall/mineral/abductor
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_WALLS, SMOOTH_GROUP_ABDUCTOR_WALLS)
|
||||
canSmoothWith = list(SMOOTH_GROUP_ABDUCTOR_WALLS)
|
||||
|
||||
@@ -301,10 +325,11 @@
|
||||
name = "wall"
|
||||
desc = "A light-weight titanium wall used in shuttles."
|
||||
icon = 'icons/turf/walls/shuttle_wall.dmi'
|
||||
icon_state = "shuttle"
|
||||
icon_state = "shuttle_wall-0"
|
||||
base_icon_state = "shuttle_wall"
|
||||
mineral = /obj/item/stack/sheet/mineral/titanium
|
||||
walltype = /turf/closed/wall/mineral/titanium
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_WALLS, SMOOTH_GROUP_TITANIUM_WALLS)
|
||||
canSmoothWith = list(SMOOTH_GROUP_TITANIUM_WALLS, SMOOTH_GROUP_AIRLOCK, SMOOTH_GROUP_SHUTTLE_PARTS)
|
||||
|
||||
@@ -312,9 +337,10 @@
|
||||
name = "wall"
|
||||
desc = "An evil wall of plasma and titanium."
|
||||
icon = 'icons/turf/walls/plastitanium_wall.dmi'
|
||||
icon_state = "shuttle"
|
||||
icon_state = "plastitanium_wall-0"
|
||||
base_icon_state = "plastitanium_wall"
|
||||
mineral = /obj/item/stack/sheet/mineral/plastitanium
|
||||
walltype = /turf/closed/wall/mineral/plastitanium
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_WALLS, SMOOTH_GROUP_PLASTITANIUM_WALLS)
|
||||
canSmoothWith = list(SMOOTH_GROUP_PLASTITANIUM_WALLS, SMOOTH_GROUP_AIRLOCK, SMOOTH_GROUP_SHUTTLE_PARTS)
|
||||
|
||||
@@ -252,8 +252,9 @@
|
||||
name = "hedge"
|
||||
desc = "A large bushy hedge."
|
||||
icon = 'icons/obj/smooth_structures/hedge.dmi'
|
||||
icon_state = "hedge"
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
icon_state = "hedge-0"
|
||||
base_icon_state = "hedge"
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_HEDGE_FLUFF)
|
||||
canSmoothWith = list(SMOOTH_GROUP_HEDGE_FLUFF)
|
||||
density = TRUE
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
var/ratio = obj_integrity / max_integrity
|
||||
ratio = CEILING(ratio*4, 1) * 25
|
||||
|
||||
if(smoothing_flags)
|
||||
if(smoothing_flags & (SMOOTH_CORNERS|SMOOTH_BITMASK))
|
||||
QUEUE_SMOOTH(src)
|
||||
|
||||
if(ratio > 50)
|
||||
|
||||
@@ -135,16 +135,17 @@ GLOBAL_LIST_EMPTY(lifts)
|
||||
name = "lift platform"
|
||||
desc = "A lightweight lift platform. It moves up and down."
|
||||
icon = 'icons/obj/smooth_structures/catwalk.dmi'
|
||||
icon_state = "catwalk"
|
||||
icon_state = "catwalk-0"
|
||||
base_icon_state = "catwalk"
|
||||
density = FALSE
|
||||
anchored = TRUE
|
||||
armor = list(MELEE = 50, BULLET = 0, LASER = 0, ENERGY = 0, BOMB = 0, BIO = 0, RAD = 0, FIRE = 80, ACID = 50)
|
||||
max_integrity = 50
|
||||
layer = LATTICE_LAYER //under pipes
|
||||
plane = FLOOR_PLANE
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_INDUSTRIAL_LIFT)
|
||||
canSmoothWith = null
|
||||
canSmoothWith = list(SMOOTH_GROUP_INDUSTRIAL_LIFT)
|
||||
obj_flags = CAN_BE_HIT | BLOCK_Z_OUT_DOWN
|
||||
|
||||
var/id = null //ONLY SET THIS TO ONE OF THE LIFT'S PARTS. THEY'RE CONNECTED! ONLY ONE NEEDS THE SIGNAL!
|
||||
|
||||
@@ -2,7 +2,8 @@
|
||||
name = "lattice"
|
||||
desc = "A lightweight support lattice. These hold our station together."
|
||||
icon = 'icons/obj/smooth_structures/lattice.dmi'
|
||||
icon_state = "lattice"
|
||||
icon_state = "lattice-255"
|
||||
base_icon_state = "lattice"
|
||||
density = FALSE
|
||||
anchored = TRUE
|
||||
armor = list(MELEE = 50, BULLET = 0, LASER = 0, ENERGY = 0, BOMB = 0, BIO = 0, RAD = 0, FIRE = 80, ACID = 50)
|
||||
@@ -10,7 +11,7 @@
|
||||
layer = LATTICE_LAYER //under pipes
|
||||
plane = FLOOR_PLANE
|
||||
obj_flags = CAN_BE_HIT | BLOCK_Z_OUT_DOWN
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_LATTICE)
|
||||
canSmoothWith = list(SMOOTH_GROUP_LATTICE, SMOOTH_GROUP_OPEN_FLOOR, SMOOTH_GROUP_WALLS)
|
||||
var/number_of_mats = 1
|
||||
@@ -72,11 +73,12 @@
|
||||
name = "catwalk"
|
||||
desc = "A catwalk for easier EVA maneuvering and cable placement."
|
||||
icon = 'icons/obj/smooth_structures/catwalk.dmi'
|
||||
icon_state = "catwalk"
|
||||
icon_state = "catwalk-0"
|
||||
base_icon_state = "catwalk"
|
||||
number_of_mats = 2
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_LATTICE, SMOOTH_GROUP_OPEN_FLOOR)
|
||||
canSmoothWith = null
|
||||
canSmoothWith = list(SMOOTH_GROUP_LATTICE)
|
||||
obj_flags = CAN_BE_HIT | BLOCK_Z_OUT_DOWN | BLOCK_Z_IN_UP
|
||||
|
||||
/obj/structure/lattice/catwalk/deconstruction_hints(mob/user)
|
||||
@@ -98,12 +100,13 @@
|
||||
name = "heatproof support lattice"
|
||||
desc = "A specialized support beam for building across lava. Watch your step."
|
||||
icon = 'icons/obj/smooth_structures/catwalk.dmi'
|
||||
icon_state = "catwalk"
|
||||
icon_state = "catwalk-0"
|
||||
base_icon_state = "catwalk"
|
||||
number_of_mats = 1
|
||||
color = "#5286b9ff"
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
smoothing_groups = null
|
||||
canSmoothWith = null
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_LATTICE, SMOOTH_GROUP_OPEN_FLOOR)
|
||||
canSmoothWith = list(SMOOTH_GROUP_LATTICE)
|
||||
obj_flags = CAN_BE_HIT | BLOCK_Z_OUT_DOWN | BLOCK_Z_IN_UP
|
||||
resistance_flags = FIRE_PROOF | LAVA_PROOF
|
||||
|
||||
|
||||
@@ -311,7 +311,8 @@
|
||||
|
||||
/obj/structure/mineral_door/paperframe/Initialize()
|
||||
. = ..()
|
||||
QUEUE_SMOOTH_NEIGHBORS(src)
|
||||
if(smoothing_flags & (SMOOTH_CORNERS|SMOOTH_BITMASK))
|
||||
QUEUE_SMOOTH_NEIGHBORS(src)
|
||||
|
||||
/obj/structure/mineral_door/paperframe/examine(mob/user)
|
||||
. = ..()
|
||||
@@ -346,5 +347,6 @@
|
||||
return
|
||||
|
||||
/obj/structure/mineral_door/paperframe/Destroy()
|
||||
QUEUE_SMOOTH_NEIGHBORS(src)
|
||||
if(smoothing_flags & (SMOOTH_CORNERS|SMOOTH_BITMASK))
|
||||
QUEUE_SMOOTH_NEIGHBORS(src)
|
||||
return ..()
|
||||
|
||||
@@ -16,7 +16,8 @@
|
||||
name = "table"
|
||||
desc = "A square piece of metal standing on four metal legs. It can not move."
|
||||
icon = 'icons/obj/smooth_structures/table.dmi'
|
||||
icon_state = "table"
|
||||
icon_state = "table-0"
|
||||
base_icon_state = "table"
|
||||
density = TRUE
|
||||
anchored = TRUE
|
||||
layer = TABLE_LAYER
|
||||
@@ -32,7 +33,7 @@
|
||||
custom_materials = list(/datum/material/iron = 2000)
|
||||
max_integrity = 100
|
||||
integrity_failure = 0.33
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_TABLES)
|
||||
canSmoothWith = list(SMOOTH_GROUP_TABLES)
|
||||
|
||||
@@ -44,7 +45,7 @@
|
||||
return "<span class='notice'>The top is <b>screwed</b> on, but the main <b>bolts</b> are also visible.</span>"
|
||||
|
||||
/obj/structure/table/update_icon()
|
||||
if(smoothing_flags)
|
||||
if(smoothing_flags & (SMOOTH_CORNERS|SMOOTH_BITMASK))
|
||||
QUEUE_SMOOTH(src)
|
||||
QUEUE_SMOOTH_NEIGHBORS(src)
|
||||
|
||||
@@ -257,7 +258,8 @@
|
||||
|
||||
/obj/structure/table/greyscale
|
||||
icon = 'icons/obj/smooth_structures/table_greyscale.dmi'
|
||||
icon_state = "table"
|
||||
icon_state = "table_greyscale-0"
|
||||
base_icon_state = "table_greyscale"
|
||||
material_flags = MATERIAL_ADD_PREFIX | MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS
|
||||
buildstack = null //No buildstack, so generate from mat datums
|
||||
|
||||
@@ -302,10 +304,11 @@
|
||||
name = "glass table"
|
||||
desc = "What did I say about leaning on the glass tables? Now you need surgery."
|
||||
icon = 'icons/obj/smooth_structures/glass_table.dmi'
|
||||
icon_state = "glass_table"
|
||||
icon_state = "glass_table-0"
|
||||
base_icon_state = "glass_table"
|
||||
buildstack = /obj/item/stack/sheet/glass
|
||||
smoothing_groups = null
|
||||
canSmoothWith = null
|
||||
smoothing_groups = list(SMOOTH_GROUP_GLASS_TABLES)
|
||||
canSmoothWith = list(SMOOTH_GROUP_GLASS_TABLES)
|
||||
max_integrity = 70
|
||||
resistance_flags = ACID_PROOF
|
||||
armor = list(MELEE = 0, BULLET = 0, LASER = 0, ENERGY = 0, BOMB = 0, BIO = 0, RAD = 0, FIRE = 80, ACID = 100)
|
||||
@@ -381,7 +384,8 @@
|
||||
name = "wooden table"
|
||||
desc = "Do not apply fire to this. Rumour says it burns easily."
|
||||
icon = 'icons/obj/smooth_structures/wood_table.dmi'
|
||||
icon_state = "wood_table"
|
||||
icon_state = "wood_table-0"
|
||||
base_icon_state = "wood_table"
|
||||
frame = /obj/structure/table_frame/wood
|
||||
framestack = /obj/item/stack/sheet/mineral/wood
|
||||
buildstack = /obj/item/stack/sheet/mineral/wood
|
||||
@@ -398,7 +402,8 @@
|
||||
name = "gambling table"
|
||||
desc = "A seedy table for seedy dealings in seedy places."
|
||||
icon = 'icons/obj/smooth_structures/poker_table.dmi'
|
||||
icon_state = "poker_table"
|
||||
icon_state = "poker_table-0"
|
||||
base_icon_state = "poker_table"
|
||||
buildstack = /obj/item/stack/tile/carpet
|
||||
|
||||
/obj/structure/table/wood/poker/narsie_act()
|
||||
@@ -409,6 +414,7 @@
|
||||
desc = "A standard metal table frame covered with an amazingly fancy, patterned cloth."
|
||||
icon = 'icons/obj/structures.dmi'
|
||||
icon_state = "fancy_table"
|
||||
base_icon_state = "fancy_table"
|
||||
frame = /obj/structure/table_frame
|
||||
framestack = /obj/item/stack/rods
|
||||
buildstack = /obj/item/stack/tile/carpet
|
||||
@@ -426,46 +432,55 @@
|
||||
|
||||
/obj/structure/table/wood/fancy/black
|
||||
icon_state = "fancy_table_black"
|
||||
base_icon_state = "fancy_table_black"
|
||||
buildstack = /obj/item/stack/tile/carpet/black
|
||||
smooth_icon = 'icons/obj/smooth_structures/fancy_table_black.dmi'
|
||||
|
||||
/obj/structure/table/wood/fancy/blue
|
||||
icon_state = "fancy_table_blue"
|
||||
base_icon_state = "fancy_table_blue"
|
||||
buildstack = /obj/item/stack/tile/carpet/blue
|
||||
smooth_icon = 'icons/obj/smooth_structures/fancy_table_blue.dmi'
|
||||
|
||||
/obj/structure/table/wood/fancy/cyan
|
||||
icon_state = "fancy_table_cyan"
|
||||
base_icon_state = "fancy_table_cyan"
|
||||
buildstack = /obj/item/stack/tile/carpet/cyan
|
||||
smooth_icon = 'icons/obj/smooth_structures/fancy_table_cyan.dmi'
|
||||
|
||||
/obj/structure/table/wood/fancy/green
|
||||
icon_state = "fancy_table_green"
|
||||
base_icon_state = "fancy_table_green"
|
||||
buildstack = /obj/item/stack/tile/carpet/green
|
||||
smooth_icon = 'icons/obj/smooth_structures/fancy_table_green.dmi'
|
||||
|
||||
/obj/structure/table/wood/fancy/orange
|
||||
icon_state = "fancy_table_orange"
|
||||
base_icon_state = "fancy_table_orange"
|
||||
buildstack = /obj/item/stack/tile/carpet/orange
|
||||
smooth_icon = 'icons/obj/smooth_structures/fancy_table_orange.dmi'
|
||||
|
||||
/obj/structure/table/wood/fancy/purple
|
||||
icon_state = "fancy_table_purple"
|
||||
base_icon_state = "fancy_table_purple"
|
||||
buildstack = /obj/item/stack/tile/carpet/purple
|
||||
smooth_icon = 'icons/obj/smooth_structures/fancy_table_purple.dmi'
|
||||
|
||||
/obj/structure/table/wood/fancy/red
|
||||
icon_state = "fancy_table_red"
|
||||
base_icon_state = "fancy_table_red"
|
||||
buildstack = /obj/item/stack/tile/carpet/red
|
||||
smooth_icon = 'icons/obj/smooth_structures/fancy_table_red.dmi'
|
||||
|
||||
/obj/structure/table/wood/fancy/royalblack
|
||||
icon_state = "fancy_table_royalblack"
|
||||
base_icon_state = "fancy_table_royalblack"
|
||||
buildstack = /obj/item/stack/tile/carpet/royalblack
|
||||
smooth_icon = 'icons/obj/smooth_structures/fancy_table_royalblack.dmi'
|
||||
|
||||
/obj/structure/table/wood/fancy/royalblue
|
||||
icon_state = "fancy_table_royalblue"
|
||||
base_icon_state = "fancy_table_royalblue"
|
||||
buildstack = /obj/item/stack/tile/carpet/royalblue
|
||||
smooth_icon = 'icons/obj/smooth_structures/fancy_table_royalblue.dmi'
|
||||
|
||||
@@ -476,7 +491,8 @@
|
||||
name = "reinforced table"
|
||||
desc = "A reinforced version of the four legged table."
|
||||
icon = 'icons/obj/smooth_structures/reinforced_table.dmi'
|
||||
icon_state = "r_table"
|
||||
icon_state = "reinforced_table-0"
|
||||
base_icon_state = "reinforced_table"
|
||||
deconstruction_ready = 0
|
||||
buildstack = /obj/item/stack/sheet/plasteel
|
||||
max_integrity = 200
|
||||
@@ -511,7 +527,8 @@
|
||||
name = "bronze table"
|
||||
desc = "A solid table made out of bronze."
|
||||
icon = 'icons/obj/smooth_structures/brass_table.dmi'
|
||||
icon_state = "brass_table"
|
||||
icon_state = "brass_table-0"
|
||||
base_icon_state = "brass_table"
|
||||
resistance_flags = FIRE_PROOF | ACID_PROOF
|
||||
buildstack = /obj/item/stack/tile/bronze
|
||||
smoothing_groups = list(SMOOTH_GROUP_BRONZE_TABLES) //Don't smooth with SMOOTH_GROUP_TABLES
|
||||
|
||||
@@ -317,7 +317,7 @@
|
||||
//This proc is used to update the icons of nearby windows.
|
||||
/obj/structure/window/proc/update_nearby_icons()
|
||||
update_icon()
|
||||
if(smoothing_flags)
|
||||
if(smoothing_flags & (SMOOTH_CORNERS|SMOOTH_BITMASK))
|
||||
QUEUE_SMOOTH_NEIGHBORS(src)
|
||||
|
||||
//merges adjacent full-tile windows into one
|
||||
@@ -330,7 +330,7 @@
|
||||
var/ratio = obj_integrity / max_integrity
|
||||
ratio = CEILING(ratio*4, 1) * 25
|
||||
|
||||
if(smoothing_flags)
|
||||
if(smoothing_flags & (SMOOTH_CORNERS|SMOOTH_BITMASK))
|
||||
QUEUE_SMOOTH(src)
|
||||
|
||||
cut_overlay(crack_overlay)
|
||||
@@ -598,12 +598,13 @@
|
||||
|
||||
/obj/structure/window/fulltile
|
||||
icon = 'icons/obj/smooth_structures/window.dmi'
|
||||
icon_state = "window"
|
||||
icon_state = "window-0"
|
||||
base_icon_state = "window"
|
||||
dir = FULLTILE_WINDOW_DIR
|
||||
max_integrity = 50
|
||||
fulltile = TRUE
|
||||
flags_1 = PREVENT_CLICK_UNDER_1
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_WINDOW_FULLTILE)
|
||||
canSmoothWith = list(SMOOTH_GROUP_WINDOW_FULLTILE)
|
||||
glass_amount = 2
|
||||
@@ -613,12 +614,13 @@
|
||||
|
||||
/obj/structure/window/plasma/fulltile
|
||||
icon = 'icons/obj/smooth_structures/plasma_window.dmi'
|
||||
icon_state = "plasmawindow"
|
||||
icon_state = "plasma_window-0"
|
||||
base_icon_state = "plasma_window"
|
||||
dir = FULLTILE_WINDOW_DIR
|
||||
max_integrity = 300
|
||||
fulltile = TRUE
|
||||
flags_1 = PREVENT_CLICK_UNDER_1
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_WINDOW_FULLTILE)
|
||||
canSmoothWith = list(SMOOTH_GROUP_WINDOW_FULLTILE)
|
||||
glass_amount = 2
|
||||
@@ -628,13 +630,14 @@
|
||||
|
||||
/obj/structure/window/plasma/reinforced/fulltile
|
||||
icon = 'icons/obj/smooth_structures/rplasma_window.dmi'
|
||||
icon_state = "rplasmawindow"
|
||||
icon_state = "rplasma_window-0"
|
||||
base_icon_state = "rplasma_window"
|
||||
dir = FULLTILE_WINDOW_DIR
|
||||
state = RWINDOW_SECURE
|
||||
max_integrity = 1000
|
||||
fulltile = TRUE
|
||||
flags_1 = PREVENT_CLICK_UNDER_1
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_WINDOW_FULLTILE)
|
||||
canSmoothWith = list(SMOOTH_GROUP_WINDOW_FULLTILE)
|
||||
glass_amount = 2
|
||||
@@ -645,13 +648,14 @@
|
||||
|
||||
/obj/structure/window/reinforced/fulltile
|
||||
icon = 'icons/obj/smooth_structures/reinforced_window.dmi'
|
||||
icon_state = "r_window"
|
||||
icon_state = "reinforced_window-0"
|
||||
base_icon_state = "reinforced_window"
|
||||
dir = FULLTILE_WINDOW_DIR
|
||||
max_integrity = 150
|
||||
fulltile = TRUE
|
||||
flags_1 = PREVENT_CLICK_UNDER_1
|
||||
state = RWINDOW_SECURE
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_WINDOW_FULLTILE)
|
||||
canSmoothWith = list(SMOOTH_GROUP_WINDOW_FULLTILE)
|
||||
glass_amount = 2
|
||||
@@ -662,18 +666,20 @@
|
||||
|
||||
/obj/structure/window/reinforced/tinted/fulltile
|
||||
icon = 'icons/obj/smooth_structures/tinted_window.dmi'
|
||||
icon_state = "tinted_window"
|
||||
icon_state = "tinted_window-0"
|
||||
base_icon_state = "tinted_window"
|
||||
dir = FULLTILE_WINDOW_DIR
|
||||
fulltile = TRUE
|
||||
flags_1 = PREVENT_CLICK_UNDER_1
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_WINDOW_FULLTILE)
|
||||
canSmoothWith = list(SMOOTH_GROUP_WINDOW_FULLTILE)
|
||||
glass_amount = 2
|
||||
|
||||
/obj/structure/window/reinforced/fulltile/ice
|
||||
icon = 'icons/obj/smooth_structures/rice_window.dmi'
|
||||
icon_state = "ice_window"
|
||||
icon_state = "rice_window-0"
|
||||
base_icon_state = "rice_window"
|
||||
max_integrity = 150
|
||||
glass_amount = 2
|
||||
|
||||
@@ -681,7 +687,8 @@
|
||||
name = "shuttle window"
|
||||
desc = "A reinforced, air-locked pod window."
|
||||
icon = 'icons/obj/smooth_structures/shuttle_window.dmi'
|
||||
icon_state = "shuttle_window"
|
||||
icon_state = "shuttle_window-0"
|
||||
base_icon_state = "shuttle_window"
|
||||
dir = FULLTILE_WINDOW_DIR
|
||||
max_integrity = 150
|
||||
wtype = "shuttle"
|
||||
@@ -690,9 +697,9 @@
|
||||
reinf = TRUE
|
||||
heat_resistance = 1600
|
||||
armor = list(MELEE = 90, BULLET = 0, LASER = 0, ENERGY = 0, BOMB = 50, BIO = 100, RAD = 100, FIRE = 80, ACID = 100)
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
smoothing_groups = list(SMOOTH_GROUP_SHUTTLE_PARTS)
|
||||
canSmoothWith = null
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_SHUTTLE_PARTS, SMOOTH_GROUP_WINDOW_FULLTILE_SHUTTLE)
|
||||
canSmoothWith = list(SMOOTH_GROUP_WINDOW_FULLTILE_SHUTTLE)
|
||||
explosion_block = 3
|
||||
glass_type = /obj/item/stack/sheet/titaniumglass
|
||||
glass_amount = 2
|
||||
@@ -711,7 +718,8 @@
|
||||
name = "plastitanium window"
|
||||
desc = "A durable looking window made of an alloy of of plasma and titanium."
|
||||
icon = 'icons/obj/smooth_structures/plastitanium_window.dmi'
|
||||
icon_state = "plastitanium_window"
|
||||
icon_state = "plastitanium_window-0"
|
||||
base_icon_state = "plastitanium_window"
|
||||
dir = FULLTILE_WINDOW_DIR
|
||||
max_integrity = 1200
|
||||
wtype = "shuttle"
|
||||
@@ -719,9 +727,9 @@
|
||||
flags_1 = PREVENT_CLICK_UNDER_1
|
||||
heat_resistance = 1600
|
||||
armor = list(MELEE = 95, BULLET = 0, LASER = 0, ENERGY = 0, BOMB = 50, BIO = 100, RAD = 100, FIRE = 80, ACID = 100)
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
smoothing_groups = list(SMOOTH_GROUP_SHUTTLE_PARTS)
|
||||
canSmoothWith = null
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_SHUTTLE_PARTS, SMOOTH_GROUP_WINDOW_FULLTILE_PLASTITANIUM)
|
||||
canSmoothWith = list(SMOOTH_GROUP_WINDOW_FULLTILE_PLASTITANIUM)
|
||||
explosion_block = 3
|
||||
damage_deflection = 21 //The same as reinforced plasma windows.3
|
||||
glass_type = /obj/item/stack/sheet/plastitaniumglass
|
||||
@@ -736,13 +744,14 @@
|
||||
name = "paper frame"
|
||||
desc = "A fragile separator made of thin wood and paper."
|
||||
icon = 'icons/obj/smooth_structures/paperframes.dmi'
|
||||
icon_state = "frame"
|
||||
icon_state = "paperframes-0"
|
||||
base_icon_state = "paperframes"
|
||||
dir = FULLTILE_WINDOW_DIR
|
||||
opacity = TRUE
|
||||
max_integrity = 15
|
||||
fulltile = TRUE
|
||||
flags_1 = PREVENT_CLICK_UNDER_1
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_PAPERFRAME)
|
||||
canSmoothWith = list(SMOOTH_GROUP_PAPERFRAME)
|
||||
glass_amount = 2
|
||||
@@ -791,7 +800,8 @@
|
||||
cut_overlay(torn)
|
||||
add_overlay(paper)
|
||||
set_opacity(TRUE)
|
||||
QUEUE_SMOOTH(src)
|
||||
if(smoothing_flags & (SMOOTH_CORNERS|SMOOTH_BITMASK))
|
||||
QUEUE_SMOOTH(src)
|
||||
|
||||
|
||||
/obj/structure/window/paperframe/attackby(obj/item/W, mob/user)
|
||||
@@ -823,10 +833,11 @@
|
||||
anchored = FALSE
|
||||
|
||||
/obj/structure/window/bronze/fulltile
|
||||
icon_state = "clockwork_window"
|
||||
smoothing_flags = SMOOTH_CORNERS
|
||||
smoothing_groups = list(SMOOTH_GROUP_WINDOW_FULLTILE)
|
||||
canSmoothWith = null
|
||||
icon_state = "clockwork_window-0"
|
||||
base_icon_state = "clockwork_window"
|
||||
smoothing_flags = SMOOTH_BITMASK
|
||||
smoothing_groups = list(SMOOTH_GROUP_WINDOW_FULLTILE, SMOOTH_GROUP_WINDOW_FULLTILE_BRONZE)
|
||||
canSmoothWith = list(SMOOTH_GROUP_WINDOW_FULLTILE_BRONZE)
|
||||
fulltile = TRUE
|
||||
flags_1 = PREVENT_CLICK_UNDER_1
|
||||
dir = FULLTILE_WINDOW_DIR
|
||||
|
||||
Reference in New Issue
Block a user