Files
Aurora.3/code/defines/mutable_appearance.dm
Fluffy 9acce89e2a Weapons Racks (#19338)
Added weapons racks, can be locked/unlocked with an ID card.
Added weapons racks sprites, from Wezzy.
Refactored some circuitboard code, moved the defines, applied the
defines, DMDocs.
Moved mutable appearance appearance flag set to the mutable appearance
file.
Reorganized the Horizon armory with the weapons racks, moved things
around, put down markers on lockers depending on the danger level of
their content, reorganized content of the remaining lockers.
Made weapons racks constructable with circuitboards.


![image](https://github.com/Aurorastation/Aurora.3/assets/65877598/8b4ec7ae-40c4-4cd7-b338-76120d468b90)

![image](https://github.com/Aurorastation/Aurora.3/assets/65877598/a69d1f85-c4b2-4643-af2b-6832e3ea2c43)

![image](https://github.com/Aurorastation/Aurora.3/assets/65877598/11c1afe4-0fa1-4708-8eb4-64e1f5594913)

sound/items/metal_shutter.ogg -
https://freesound.org/people/bruno.auzet/sounds/524695/ (CC0, sound was
edited)
2024-06-09 17:07:52 +00:00

26 lines
1020 B
Plaintext

// Mutable appearances are an inbuilt byond datastructure. Read the documentation on them by hitting F1 in DM.
// Basically use them instead of images for overlays/underlays and when changing an object's appearance if you're doing so with any regularity.
// Unless you need the overlay/underlay to have a different direction than the base object. Then you have to use an image due to a bug.
// Mutable appearances are children of images, just so you know.
/mutable_appearance
appearance_flags = DEFAULT_APPEARANCE_FLAGS //Bay shit
/mutable_appearance/New(mutable_appearance/to_copy)
..()
if(!to_copy)
plane = FLOAT_PLANE
// Helper similar to image()
/proc/mutable_appearance(icon, icon_state, color, flags = DEFAULT_APPEARANCE_FLAGS | RESET_COLOR | RESET_ALPHA, plane = FLOAT_PLANE, layer = FLOAT_LAYER)
RETURN_TYPE(/mutable_appearance)
var/mutable_appearance/MA = new()
MA.icon = icon
MA.icon_state = icon_state
MA.color = color
MA.appearance_flags = flags
MA.plane = plane
MA.layer = layer
return MA