mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 10:12:45 +00:00
[MIRROR] rework appearance changer (#9588)
Co-authored-by: Heroman3003 <31296024+Heroman3003@users.noreply.github.com> Co-authored-by: Kashargul <144968721+Kashargul@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
d3976b78a3
commit
983664d462
@@ -457,3 +457,6 @@
|
|||||||
#define VISIBLE_GENDER_FORCE_PLURAL 1 // Used by get_visible_gender to return PLURAL
|
#define VISIBLE_GENDER_FORCE_PLURAL 1 // Used by get_visible_gender to return PLURAL
|
||||||
#define VISIBLE_GENDER_FORCE_IDENTIFYING 2 // Used by get_visible_gender to return the mob's identifying gender
|
#define VISIBLE_GENDER_FORCE_IDENTIFYING 2 // Used by get_visible_gender to return the mob's identifying gender
|
||||||
#define VISIBLE_GENDER_FORCE_BIOLOGICAL 3 // Used by get_visible_gender to return the mob's biological gender
|
#define VISIBLE_GENDER_FORCE_BIOLOGICAL 3 // Used by get_visible_gender to return the mob's biological gender
|
||||||
|
|
||||||
|
// Default name for accesories
|
||||||
|
#define DEVELOPER_WARNING_NAME "you should not see this..."
|
||||||
|
|||||||
@@ -813,7 +813,7 @@
|
|||||||
apply_danger_level(0)
|
apply_danger_level(0)
|
||||||
update_icon()
|
update_icon()
|
||||||
|
|
||||||
/obj/machinery/alarm/attackby(obj/item/W as obj, mob/user as mob)
|
/obj/machinery/alarm/attackby(obj/item/W as obj, mob/user)
|
||||||
add_fingerprint(user)
|
add_fingerprint(user)
|
||||||
if(alarm_deconstruction_screwdriver(user, W))
|
if(alarm_deconstruction_screwdriver(user, W))
|
||||||
return
|
return
|
||||||
@@ -821,10 +821,10 @@
|
|||||||
return
|
return
|
||||||
|
|
||||||
if(istype(W, /obj/item/card/id) || istype(W, /obj/item/pda))// trying to unlock the interface with an ID card
|
if(istype(W, /obj/item/card/id) || istype(W, /obj/item/pda))// trying to unlock the interface with an ID card
|
||||||
togglelock()
|
togglelock(user)
|
||||||
return ..()
|
return ..()
|
||||||
|
|
||||||
/obj/machinery/alarm/verb/togglelock(mob/user as mob)
|
/obj/machinery/alarm/proc/togglelock(mob/user)
|
||||||
if(stat & (NOPOWER|BROKEN))
|
if(stat & (NOPOWER|BROKEN))
|
||||||
to_chat(user, "It does nothing.")
|
to_chat(user, "It does nothing.")
|
||||||
return
|
return
|
||||||
@@ -836,9 +836,9 @@
|
|||||||
to_chat(user, span_warning("Access denied."))
|
to_chat(user, span_warning("Access denied."))
|
||||||
return
|
return
|
||||||
|
|
||||||
/obj/machinery/alarm/AltClick()
|
/obj/machinery/alarm/AltClick(mob/user)
|
||||||
..()
|
..()
|
||||||
togglelock()
|
togglelock(user)
|
||||||
|
|
||||||
/obj/machinery/alarm/power_change()
|
/obj/machinery/alarm/power_change()
|
||||||
..()
|
..()
|
||||||
|
|||||||
@@ -542,7 +542,7 @@
|
|||||||
//Misc belts. Admin-spawn only atm.
|
//Misc belts. Admin-spawn only atm.
|
||||||
|
|
||||||
/obj/item/personal_shield_generator/belt/adminbus
|
/obj/item/personal_shield_generator/belt/adminbus
|
||||||
desc = "You should not see this. You REALLY should not see this. If you do, you have either been blessed or are about to be the target of some sick prank."
|
desc = DEVELOPER_WARNING_NAME + " You REALLY should not see this. If you do, you have either been blessed or are about to be the target of some sick prank."
|
||||||
modifier_type = /datum/modifier/shield_projection/admin
|
modifier_type = /datum/modifier/shield_projection/admin
|
||||||
generator_hit_cost = 0
|
generator_hit_cost = 0
|
||||||
generator_active_cost = 0
|
generator_active_cost = 0
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/obj/effect/falling_effect
|
/obj/effect/falling_effect
|
||||||
name = "you should not see this"
|
name = DEVELOPER_WARNING_NAME
|
||||||
desc = "no data"
|
desc = "no data"
|
||||||
invisibility = 101
|
invisibility = 101
|
||||||
anchored = TRUE
|
anchored = TRUE
|
||||||
|
|||||||
@@ -26,6 +26,14 @@
|
|||||||
toggle()
|
toggle()
|
||||||
..()
|
..()
|
||||||
|
|
||||||
|
/obj/structure/curtain/attack_ai(mob/user)
|
||||||
|
if(!Adjacent(user))
|
||||||
|
return
|
||||||
|
if(!isrobot((user)))
|
||||||
|
return
|
||||||
|
playsound(src, "rustle", 15, 1, -5)
|
||||||
|
toggle()
|
||||||
|
|
||||||
/obj/structure/curtain/proc/toggle()
|
/obj/structure/curtain/proc/toggle()
|
||||||
set_opacity(!opacity)
|
set_opacity(!opacity)
|
||||||
if(opacity)
|
if(opacity)
|
||||||
|
|||||||
@@ -11,7 +11,7 @@
|
|||||||
var/glass = 1
|
var/glass = 1
|
||||||
var/datum/tgui_module/appearance_changer/mirror/M
|
var/datum/tgui_module/appearance_changer/mirror/M
|
||||||
|
|
||||||
/obj/structure/mirror/Initialize(mapload, var/dir, var/building = 0, mob/user as mob)
|
/obj/structure/mirror/Initialize(mapload, var/dir, var/building = 0)
|
||||||
M = new(src, null)
|
M = new(src, null)
|
||||||
if(building)
|
if(building)
|
||||||
glass = 0
|
glass = 0
|
||||||
@@ -24,12 +24,18 @@
|
|||||||
QDEL_NULL(M)
|
QDEL_NULL(M)
|
||||||
. = ..()
|
. = ..()
|
||||||
|
|
||||||
/obj/structure/mirror/attack_hand(mob/user as mob)
|
/obj/structure/mirror/attack_hand(mob/user)
|
||||||
if(!glass) return
|
if(!glass) return
|
||||||
if(shattered) return
|
if(shattered) return
|
||||||
|
|
||||||
if(ishuman(user))
|
M.tgui_interact(user)
|
||||||
M.tgui_interact(user)
|
|
||||||
|
/obj/structure/mirror/attack_ai(mob/user)
|
||||||
|
if(!glass) return
|
||||||
|
if(shattered) return
|
||||||
|
if(!Adjacent(user)) return
|
||||||
|
|
||||||
|
M.tgui_interact(user)
|
||||||
|
|
||||||
/obj/structure/mirror/proc/shatter()
|
/obj/structure/mirror/proc/shatter()
|
||||||
if(!glass) return
|
if(!glass) return
|
||||||
|
|||||||
@@ -92,6 +92,13 @@
|
|||||||
toggle_open(user)
|
toggle_open(user)
|
||||||
return 0
|
return 0
|
||||||
|
|
||||||
|
/turf/simulated/wall/attack_ai(var/mob/user)
|
||||||
|
if(!Adjacent(user))
|
||||||
|
return
|
||||||
|
if(!isrobot((user)))
|
||||||
|
return
|
||||||
|
var/rotting = (locate(/obj/effect/overlay/wallrot) in src)
|
||||||
|
try_touch(user, rotting)
|
||||||
|
|
||||||
/turf/simulated/wall/attack_hand(var/mob/user)
|
/turf/simulated/wall/attack_hand(var/mob/user)
|
||||||
|
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ var/global/list/env_messages = list()
|
|||||||
mouse_opacity = TRUE
|
mouse_opacity = TRUE
|
||||||
anchored = TRUE
|
anchored = TRUE
|
||||||
var/list/message_list = list()
|
var/list/message_list = list()
|
||||||
var/combined_message = "You should not see this"
|
var/combined_message = DEVELOPER_WARNING_NAME
|
||||||
|
|
||||||
/obj/effect/env_message/Initialize(mapload)
|
/obj/effect/env_message/Initialize(mapload)
|
||||||
.=..()
|
.=..()
|
||||||
|
|||||||
@@ -6,14 +6,14 @@
|
|||||||
////////////////////////////
|
////////////////////////////
|
||||||
*/
|
*/
|
||||||
/datum/sprite_accessory/ears
|
/datum/sprite_accessory/ears
|
||||||
name = "You should not see this..."
|
name = DEVELOPER_WARNING_NAME
|
||||||
icon = 'icons/mob/human_races/sprite_accessories/ears.dmi'
|
icon = 'icons/mob/human_races/sprite_accessories/ears.dmi'
|
||||||
do_colouration = 0 // Set to 1 to blend (ICON_ADD) hair color
|
do_colouration = 0 // Set to 1 to blend (ICON_ADD) hair color
|
||||||
|
|
||||||
color_blend_mode = ICON_ADD // Only appliciable if do_coloration = 1
|
color_blend_mode = ICON_ADD // Only appliciable if do_coloration = 1
|
||||||
var/extra_overlay // Icon state of an additional overlay to blend in.
|
var/extra_overlay // Icon state of an additional overlay to blend in.
|
||||||
var/extra_overlay2
|
var/extra_overlay2
|
||||||
var/desc = "You should not see this..."
|
var/desc = DEVELOPER_WARNING_NAME
|
||||||
em_block = TRUE
|
em_block = TRUE
|
||||||
|
|
||||||
//species_allowed = list(SPECIES_EVENT1, SPECIES_EVENT2, SPECIES_EVENT3) //Removing Polaris whitelits, ones we need are defined in our files
|
//species_allowed = list(SPECIES_EVENT1, SPECIES_EVENT2, SPECIES_EVENT3) //Removing Polaris whitelits, ones we need are defined in our files
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
////////////////////////////
|
////////////////////////////
|
||||||
*/
|
*/
|
||||||
/datum/sprite_accessory/ears
|
/datum/sprite_accessory/ears
|
||||||
name = "You should not see this..."
|
name = DEVELOPER_WARNING_NAME
|
||||||
icon = 'icons/mob/vore/ears_vr.dmi'
|
icon = 'icons/mob/vore/ears_vr.dmi'
|
||||||
do_colouration = 0 // Set to 1 to blend (ICON_ADD) hair color
|
do_colouration = 0 // Set to 1 to blend (ICON_ADD) hair color
|
||||||
species_allowed = list(SPECIES_HUMAN, SPECIES_SKRELL, SPECIES_UNATHI, SPECIES_TAJ, SPECIES_TESHARI, SPECIES_NEVREAN, SPECIES_AKULA, SPECIES_SERGAL, SPECIES_FENNEC, SPECIES_ZORREN_HIGH, SPECIES_VULPKANIN, SPECIES_XENOCHIMERA, SPECIES_XENOHYBRID, SPECIES_VASILISSAN, SPECIES_RAPALA, SPECIES_PROTEAN, SPECIES_ALRAUNE, SPECIES_WEREBEAST, SPECIES_SHADEKIN, SPECIES_SHADEKIN_CREW, SPECIES_ALTEVIAN, SPECIES_LLEILL, SPECIES_HANNER) //This lets all races use
|
species_allowed = list(SPECIES_HUMAN, SPECIES_SKRELL, SPECIES_UNATHI, SPECIES_TAJ, SPECIES_TESHARI, SPECIES_NEVREAN, SPECIES_AKULA, SPECIES_SERGAL, SPECIES_FENNEC, SPECIES_ZORREN_HIGH, SPECIES_VULPKANIN, SPECIES_XENOCHIMERA, SPECIES_XENOHYBRID, SPECIES_VASILISSAN, SPECIES_RAPALA, SPECIES_PROTEAN, SPECIES_ALRAUNE, SPECIES_WEREBEAST, SPECIES_SHADEKIN, SPECIES_SHADEKIN_CREW, SPECIES_ALTEVIAN, SPECIES_LLEILL, SPECIES_HANNER) //This lets all races use
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
////////////////////////////
|
////////////////////////////
|
||||||
*/
|
*/
|
||||||
/datum/sprite_accessory/tail
|
/datum/sprite_accessory/tail
|
||||||
name = "You should not see this..."
|
name = DEVELOPER_WARNING_NAME
|
||||||
icon = 'icons/mob/human_races/sprite_accessories/tails.dmi'
|
icon = 'icons/mob/human_races/sprite_accessories/tails.dmi'
|
||||||
do_colouration = 0 //Set to 1 to enable coloration using the tail color.
|
do_colouration = 0 //Set to 1 to enable coloration using the tail color.
|
||||||
|
|
||||||
@@ -16,7 +16,7 @@
|
|||||||
var/extra_overlay2 //Tertiary.
|
var/extra_overlay2 //Tertiary.
|
||||||
var/show_species_tail = 0 // If false, do not render species' tail.
|
var/show_species_tail = 0 // If false, do not render species' tail.
|
||||||
var/clothing_can_hide = 1 // If true, clothing with HIDETAIL hides it
|
var/clothing_can_hide = 1 // If true, clothing with HIDETAIL hides it
|
||||||
var/desc = "You should not see this..."
|
var/desc = DEVELOPER_WARNING_NAME
|
||||||
var/ani_state // State when wagging/animated
|
var/ani_state // State when wagging/animated
|
||||||
var/extra_overlay_w // Wagging state for extra overlay
|
var/extra_overlay_w // Wagging state for extra overlay
|
||||||
var/extra_overlay2_w // Tertiary wagging.
|
var/extra_overlay2_w // Tertiary wagging.
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
////////////////////////////
|
////////////////////////////
|
||||||
*/
|
*/
|
||||||
/datum/sprite_accessory/tail
|
/datum/sprite_accessory/tail
|
||||||
name = "You should not see this..."
|
name = DEVELOPER_WARNING_NAME
|
||||||
icon = 'icons/mob/vore/tails_vr.dmi'
|
icon = 'icons/mob/vore/tails_vr.dmi'
|
||||||
var/offset_x = 0
|
var/offset_x = 0
|
||||||
var/offset_y = 0
|
var/offset_y = 0
|
||||||
@@ -1449,7 +1449,7 @@
|
|||||||
|
|
||||||
//LONG TAILS ARE NOT TAUR BUTTS >:O
|
//LONG TAILS ARE NOT TAUR BUTTS >:O
|
||||||
/datum/sprite_accessory/tail/longtail
|
/datum/sprite_accessory/tail/longtail
|
||||||
name = "You should not see this..."
|
name = DEVELOPER_WARNING_NAME
|
||||||
icon = 'icons/mob/vore/taurs_vr.dmi'
|
icon = 'icons/mob/vore/taurs_vr.dmi'
|
||||||
offset_x = -16
|
offset_x = -16
|
||||||
do_colouration = 1 // Yes color, using tail color
|
do_colouration = 1 // Yes color, using tail color
|
||||||
|
|||||||
@@ -128,7 +128,7 @@
|
|||||||
// Taur sprites are now a subtype of tail since they are mutually exclusive anyway.
|
// Taur sprites are now a subtype of tail since they are mutually exclusive anyway.
|
||||||
|
|
||||||
/datum/sprite_accessory/tail/taur
|
/datum/sprite_accessory/tail/taur
|
||||||
name = "You should not see this..."
|
name = DEVELOPER_WARNING_NAME
|
||||||
icon = 'icons/mob/human_races/sprite_accessories/taurs.dmi'
|
icon = 'icons/mob/human_races/sprite_accessories/taurs.dmi'
|
||||||
do_colouration = 1 // Yes color, using tail color
|
do_colouration = 1 // Yes color, using tail color
|
||||||
color_blend_mode = ICON_MULTIPLY // The sprites for taurs are designed for ICON_MULTIPLY
|
color_blend_mode = ICON_MULTIPLY // The sprites for taurs are designed for ICON_MULTIPLY
|
||||||
|
|||||||
@@ -9,7 +9,7 @@
|
|||||||
// Taur sprites are now a subtype of tail since they are mutually exclusive anyway.
|
// Taur sprites are now a subtype of tail since they are mutually exclusive anyway.
|
||||||
|
|
||||||
/datum/sprite_accessory/tail/taur
|
/datum/sprite_accessory/tail/taur
|
||||||
name = "You should not see this..."
|
name = DEVELOPER_WARNING_NAME
|
||||||
icon = 'icons/mob/vore/taurs_vr.dmi'
|
icon = 'icons/mob/vore/taurs_vr.dmi'
|
||||||
do_colouration = 1 // Yes color, using tail color
|
do_colouration = 1 // Yes color, using tail color
|
||||||
color_blend_mode = ICON_MULTIPLY // The sprites for taurs are designed for ICON_MULTIPLY
|
color_blend_mode = ICON_MULTIPLY // The sprites for taurs are designed for ICON_MULTIPLY
|
||||||
|
|||||||
@@ -576,13 +576,13 @@
|
|||||||
// No, this isn't a character creation option, but... I guess in the future it could be, if anyone wants that?
|
// No, this isn't a character creation option, but... I guess in the future it could be, if anyone wants that?
|
||||||
|
|
||||||
/datum/sprite_accessory/hair_accessory
|
/datum/sprite_accessory/hair_accessory
|
||||||
name = "You should not see this..."
|
name = DEVELOPER_WARNING_NAME
|
||||||
icon = 'icons/mob/vore/hair_accessories_vr.dmi'
|
icon = 'icons/mob/vore/hair_accessories_vr.dmi'
|
||||||
do_colouration = 0 // Set to 1 to blend (ICON_ADD) hair color
|
do_colouration = 0 // Set to 1 to blend (ICON_ADD) hair color
|
||||||
|
|
||||||
var/ignores_lighting = 0 // Whether or not this hair accessory will ignore lighting and glow in the dark.
|
var/ignores_lighting = 0 // Whether or not this hair accessory will ignore lighting and glow in the dark.
|
||||||
color_blend_mode = ICON_ADD // Only appliciable if do_coloration = 1
|
color_blend_mode = ICON_ADD // Only appliciable if do_coloration = 1
|
||||||
var/desc = "You should not see this..."
|
var/desc = DEVELOPER_WARNING_NAME
|
||||||
/* //Chomp REMOVE - No ckeys_allowed allowed
|
/* //Chomp REMOVE - No ckeys_allowed allowed
|
||||||
/datum/sprite_accessory/hair_accessory/verie_hair_glow
|
/datum/sprite_accessory/hair_accessory/verie_hair_glow
|
||||||
name = "veries hair glow"
|
name = "veries hair glow"
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
////////////////////////////
|
////////////////////////////
|
||||||
*/
|
*/
|
||||||
/datum/sprite_accessory/wing
|
/datum/sprite_accessory/wing
|
||||||
name = "You should not see this..."
|
name = DEVELOPER_WARNING_NAME
|
||||||
icon = 'icons/mob/human_races/sprite_accessories/wings.dmi'
|
icon = 'icons/mob/human_races/sprite_accessories/wings.dmi'
|
||||||
do_colouration = 0 //Set to 1 to enable coloration using the tail color.
|
do_colouration = 0 //Set to 1 to enable coloration using the tail color.
|
||||||
|
|
||||||
@@ -16,7 +16,7 @@
|
|||||||
var/extra_overlay2 //Tertiary.
|
var/extra_overlay2 //Tertiary.
|
||||||
var/clothing_can_hide = 1 // If true, clothing with HIDETAIL hides it. If the clothing is bulky enough to hide a tail, it should also hide wings.
|
var/clothing_can_hide = 1 // If true, clothing with HIDETAIL hides it. If the clothing is bulky enough to hide a tail, it should also hide wings.
|
||||||
// var/show_species_tail = 1 // Just so // TODO - Seems not needed ~Leshana
|
// var/show_species_tail = 1 // Just so // TODO - Seems not needed ~Leshana
|
||||||
var/desc = "You should not see this..."
|
var/desc = DEVELOPER_WARNING_NAME
|
||||||
var/ani_state // State when flapping/animated
|
var/ani_state // State when flapping/animated
|
||||||
var/extra_overlay_w // Flapping state for extra overlay
|
var/extra_overlay_w // Flapping state for extra overlay
|
||||||
var/extra_overlay2_w
|
var/extra_overlay2_w
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
|
|
||||||
/datum/sprite_accessory/wing/large
|
/datum/sprite_accessory/wing/large
|
||||||
name = "You should not see this..."
|
name = DEVELOPER_WARNING_NAME
|
||||||
icon = 'icons/mob/vore/wings96_vr.dmi'
|
icon = 'icons/mob/vore/wings96_vr.dmi'
|
||||||
wing_offset = 32
|
wing_offset = 32
|
||||||
|
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
////////////////////////////
|
////////////////////////////
|
||||||
*/
|
*/
|
||||||
/datum/sprite_accessory/wing
|
/datum/sprite_accessory/wing
|
||||||
name = "You should not see this..."
|
name = DEVELOPER_WARNING_NAME
|
||||||
icon = 'icons/mob/vore/wings_vr.dmi'
|
icon = 'icons/mob/vore/wings_vr.dmi'
|
||||||
do_colouration = 0 //Set to 1 to enable coloration using the tail color.
|
do_colouration = 0 //Set to 1 to enable coloration using the tail color.
|
||||||
species_allowed = list(SPECIES_HUMAN, SPECIES_SKRELL, SPECIES_UNATHI, SPECIES_TAJ, SPECIES_TESHARI, SPECIES_NEVREAN, SPECIES_AKULA, SPECIES_SERGAL, SPECIES_FENNEC, SPECIES_ZORREN_HIGH, SPECIES_VULPKANIN, SPECIES_XENOCHIMERA, SPECIES_XENOHYBRID, SPECIES_VASILISSAN, SPECIES_RAPALA, SPECIES_PROTEAN, SPECIES_ALRAUNE, SPECIES_WEREBEAST, SPECIES_SHADEKIN, SPECIES_SHADEKIN_CREW, SPECIES_ALTEVIAN, SPECIES_LLEILL, SPECIES_HANNER) //This lets all races use
|
species_allowed = list(SPECIES_HUMAN, SPECIES_SKRELL, SPECIES_UNATHI, SPECIES_TAJ, SPECIES_TESHARI, SPECIES_NEVREAN, SPECIES_AKULA, SPECIES_SERGAL, SPECIES_FENNEC, SPECIES_ZORREN_HIGH, SPECIES_VULPKANIN, SPECIES_XENOCHIMERA, SPECIES_XENOHYBRID, SPECIES_VASILISSAN, SPECIES_RAPALA, SPECIES_PROTEAN, SPECIES_ALRAUNE, SPECIES_WEREBEAST, SPECIES_SHADEKIN, SPECIES_SHADEKIN_CREW, SPECIES_ALTEVIAN, SPECIES_LLEILL, SPECIES_HANNER) //This lets all races use
|
||||||
|
|||||||
@@ -684,7 +684,8 @@ GLOBAL_LIST_EMPTY(apcs)
|
|||||||
to_chat(user, span_notice("The [name] looks too sturdy to bash open with \the [W.name]."))
|
to_chat(user, span_notice("The [name] looks too sturdy to bash open with \the [W.name]."))
|
||||||
|
|
||||||
// attack with hand - remove cell (if cover open) or interact with the APC
|
// attack with hand - remove cell (if cover open) or interact with the APC
|
||||||
/obj/machinery/power/apc/verb/togglelock(mob/user as mob)
|
|
||||||
|
/obj/machinery/power/apc/proc/togglelock(mob/user)
|
||||||
if(emagged)
|
if(emagged)
|
||||||
to_chat(user, "The panel is unresponsive.")
|
to_chat(user, "The panel is unresponsive.")
|
||||||
else if(opened)
|
else if(opened)
|
||||||
@@ -872,7 +873,7 @@ GLOBAL_LIST_EMPTY(apcs)
|
|||||||
// to_world("[area.power_equip]")
|
// to_world("[area.power_equip]")
|
||||||
area.power_change()
|
area.power_change()
|
||||||
|
|
||||||
/obj/machinery/power/apc/proc/can_use(mob/user as mob, var/loud = 0) //used by attack_hand() and Topic()
|
/obj/machinery/power/apc/proc/can_use(mob/user, var/loud = 0) //used by attack_hand() and Topic()
|
||||||
if(!user.client)
|
if(!user.client)
|
||||||
return 0
|
return 0
|
||||||
if(isobserver(user) && is_admin(user)) //This is to allow nanoUI interaction by ghost admins.
|
if(isobserver(user) && is_admin(user)) //This is to allow nanoUI interaction by ghost admins.
|
||||||
|
|||||||
@@ -83,6 +83,7 @@
|
|||||||
H.b_skin = 255 // CHOMP Edit
|
H.b_skin = 255 // CHOMP Edit
|
||||||
H.dna.ResetUIFrom(H)
|
H.dna.ResetUIFrom(H)
|
||||||
|
|
||||||
|
H.allow_spontaneous_tf = TRUE // Allows vore customization of synthmorphs
|
||||||
H.real_name = "Synthmorph #[rand(100,999)]"
|
H.real_name = "Synthmorph #[rand(100,999)]"
|
||||||
H.name = H.real_name
|
H.name = H.real_name
|
||||||
H.dir = 2
|
H.dir = 2
|
||||||
|
|||||||
@@ -28,7 +28,7 @@
|
|||||||
var/list/markings = null
|
var/list/markings = null
|
||||||
|
|
||||||
/datum/tgui_module/appearance_changer/New(
|
/datum/tgui_module/appearance_changer/New(
|
||||||
var/host,
|
host,
|
||||||
mob/living/carbon/human/H,
|
mob/living/carbon/human/H,
|
||||||
check_species_whitelist = 1,
|
check_species_whitelist = 1,
|
||||||
list/species_whitelist = list(),
|
list/species_whitelist = list(),
|
||||||
@@ -57,309 +57,323 @@
|
|||||||
local_skybox.screen_loc = "[map_name]:CENTER,CENTER"
|
local_skybox.screen_loc = "[map_name]:CENTER,CENTER"
|
||||||
cam_plane_masters += local_skybox
|
cam_plane_masters += local_skybox
|
||||||
|
|
||||||
|
owner = H
|
||||||
cam_background = new
|
cam_background = new
|
||||||
cam_background.assigned_map = map_name
|
cam_background.assigned_map = map_name
|
||||||
cam_background.del_on_map_removal = FALSE
|
cam_background.del_on_map_removal = FALSE
|
||||||
update_active_camera_screen()
|
|
||||||
|
|
||||||
if(customize_usr)
|
|
||||||
if(ishuman(usr))
|
|
||||||
H = usr
|
|
||||||
owner = H
|
|
||||||
if(owner)
|
|
||||||
owner.AddComponent(/datum/component/recursive_move)
|
|
||||||
RegisterSignal(owner, COMSIG_OBSERVER_MOVED, PROC_REF(update_active_camera_screen))
|
|
||||||
check_whitelist = check_species_whitelist
|
check_whitelist = check_species_whitelist
|
||||||
whitelist = species_whitelist
|
whitelist = species_whitelist
|
||||||
blacklist = species_blacklist
|
blacklist = species_blacklist
|
||||||
|
|
||||||
|
/datum/tgui_module/appearance_changer/tgui_close(mob/user)
|
||||||
|
. = ..()
|
||||||
|
if(owner == user || !customize_usr)
|
||||||
|
close_ui()
|
||||||
|
UnregisterSignal(owner, COMSIG_OBSERVER_MOVED)
|
||||||
|
owner = null
|
||||||
|
last_camera_turf = null
|
||||||
|
cut_data()
|
||||||
|
|
||||||
/datum/tgui_module/appearance_changer/Destroy()
|
/datum/tgui_module/appearance_changer/Destroy()
|
||||||
UnregisterSignal(owner, COMSIG_OBSERVER_MOVED)
|
|
||||||
last_camera_turf = null
|
|
||||||
qdel(cam_screen)
|
qdel(cam_screen)
|
||||||
QDEL_LIST(cam_plane_masters)
|
QDEL_LIST(cam_plane_masters)
|
||||||
qdel(cam_background)
|
qdel(cam_background)
|
||||||
cut_data()
|
|
||||||
return ..()
|
return ..()
|
||||||
|
|
||||||
/datum/tgui_module/appearance_changer/tgui_act(action, list/params, datum/tgui/ui, datum/tgui_state/state)
|
/datum/tgui_module/appearance_changer/tgui_act(action, list/params, datum/tgui/ui, datum/tgui_state/state)
|
||||||
if(..())
|
if(..())
|
||||||
return TRUE
|
return TRUE
|
||||||
|
|
||||||
var/mob/living/carbon/human/target = owner
|
|
||||||
if(customize_usr)
|
|
||||||
if(!ishuman(ui.user))
|
|
||||||
return TRUE
|
|
||||||
target = ui.user
|
|
||||||
|
|
||||||
switch(action)
|
switch(action)
|
||||||
if("race")
|
if("race")
|
||||||
if(can_change(target, APPEARANCE_RACE) && (params["race"] in valid_species))
|
if(can_change(owner, APPEARANCE_RACE) && (params["race"] in valid_species))
|
||||||
if(target.change_species(params["race"]))
|
if(owner.change_species(params["race"]))
|
||||||
if(params["race"] == "Custom Species")
|
if(params["race"] == "Custom Species")
|
||||||
target.custom_species = sanitize(tgui_input_text(target, "Input custom species name:",
|
owner.custom_species = sanitize(tgui_input_text(ui.user, "Input custom species name:",
|
||||||
"Custom Species Name", null, MAX_NAME_LEN), MAX_NAME_LEN)
|
"Custom Species Name", null, MAX_NAME_LEN), MAX_NAME_LEN)
|
||||||
cut_data()
|
cut_data()
|
||||||
generate_data(target)
|
generate_data(ui.user, owner)
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_RACE)
|
changed_hook(APPEARANCECHANGER_CHANGED_RACE)
|
||||||
return 1
|
return 1
|
||||||
if("gender")
|
if("gender")
|
||||||
if(can_change(target, APPEARANCE_GENDER) && (params["gender"] in get_genders(target)))
|
if(can_change(owner, APPEARANCE_GENDER) && (params["gender"] in get_genders(owner)))
|
||||||
if(target.change_gender(params["gender"]))
|
if(owner.change_gender(params["gender"]))
|
||||||
cut_data()
|
cut_data()
|
||||||
generate_data(target)
|
generate_data(ui.user, owner)
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_GENDER)
|
changed_hook(APPEARANCECHANGER_CHANGED_GENDER)
|
||||||
return 1
|
return 1
|
||||||
if("gender_id")
|
if("gender_id")
|
||||||
if(can_change(target, APPEARANCE_GENDER) && (params["gender_id"] in all_genders_define_list))
|
if(can_change(owner, APPEARANCE_GENDER) && (params["gender_id"] in all_genders_define_list))
|
||||||
target.identifying_gender = params["gender_id"]
|
owner.identifying_gender = params["gender_id"]
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_GENDER_ID)
|
changed_hook(APPEARANCECHANGER_CHANGED_GENDER_ID)
|
||||||
return 1
|
return 1
|
||||||
if("skin_tone")
|
if("skin_tone")
|
||||||
if(can_change_skin_tone(target))
|
if(can_change_skin_tone(owner))
|
||||||
var/new_s_tone = tgui_input_number(target, "Choose your character's skin-tone:\n(Light 1 - 220 Dark)", "Skin Tone", -target.s_tone + 35, 220, 1)
|
var/new_s_tone = tgui_input_number(ui.user, "Choose your character's skin-tone:\n(Light 1 - 220 Dark)", "Skin Tone", -owner.s_tone + 35, 220, 1)
|
||||||
if(isnum(new_s_tone) && can_still_topic(target, state))
|
if(isnum(new_s_tone) && can_still_topic(owner, state))
|
||||||
new_s_tone = 35 - max(min( round(new_s_tone), 220),1)
|
new_s_tone = 35 - max(min( round(new_s_tone), 220),1)
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_SKINTONE)
|
changed_hook(APPEARANCECHANGER_CHANGED_SKINTONE)
|
||||||
return target.change_skin_tone(new_s_tone)
|
return owner.change_skin_tone(new_s_tone)
|
||||||
if("skin_color")
|
if("skin_color")
|
||||||
if(can_change_skin_color(target))
|
if(can_change_skin_color(owner))
|
||||||
var/new_skin = input(target, "Choose your character's skin colour: ", "Skin Color", rgb(target.r_skin, target.g_skin, target.b_skin)) as color|null
|
var/new_skin = input(ui.user, "Choose your character's skin colour: ", "Skin Color", rgb(owner.r_skin, owner.g_skin, owner.b_skin)) as color|null
|
||||||
if(new_skin && can_still_topic(target, state))
|
if(new_skin && can_still_topic(owner, state))
|
||||||
var/r_skin = hex2num(copytext(new_skin, 2, 4))
|
var/r_skin = hex2num(copytext(new_skin, 2, 4))
|
||||||
var/g_skin = hex2num(copytext(new_skin, 4, 6))
|
var/g_skin = hex2num(copytext(new_skin, 4, 6))
|
||||||
var/b_skin = hex2num(copytext(new_skin, 6, 8))
|
var/b_skin = hex2num(copytext(new_skin, 6, 8))
|
||||||
if(target.change_skin_color(r_skin, g_skin, b_skin))
|
if(owner.change_skin_color(r_skin, g_skin, b_skin))
|
||||||
update_dna(target)
|
update_dna(owner)
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_SKINCOLOR)
|
changed_hook(APPEARANCECHANGER_CHANGED_SKINCOLOR)
|
||||||
return 1
|
return 1
|
||||||
if("hair")
|
if("hair")
|
||||||
if(can_change(target, APPEARANCE_HAIR) && (params["hair"] in valid_hairstyles))
|
if(can_change(owner, APPEARANCE_HAIR) && (params["hair"] in valid_hairstyles))
|
||||||
if(target.change_hair(params["hair"]))
|
if(owner.change_hair(params["hair"]))
|
||||||
update_dna(target)
|
update_dna(owner)
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_HAIRSTYLE)
|
changed_hook(APPEARANCECHANGER_CHANGED_HAIRSTYLE)
|
||||||
return 1
|
return 1
|
||||||
if("hair_color")
|
if("hair_color")
|
||||||
if(can_change(target, APPEARANCE_HAIR_COLOR))
|
if(can_change(owner, APPEARANCE_HAIR_COLOR))
|
||||||
var/new_hair = input(target, "Please select hair color.", "Hair Color", rgb(target.r_hair, target.g_hair, target.b_hair)) as color|null
|
var/new_hair = input(ui.user, "Please select hair color.", "Hair Color", rgb(owner.r_hair, owner.g_hair, owner.b_hair)) as color|null
|
||||||
if(new_hair && can_still_topic(target, state))
|
if(new_hair && can_still_topic(owner, state))
|
||||||
var/r_hair = hex2num(copytext(new_hair, 2, 4))
|
var/r_hair = hex2num(copytext(new_hair, 2, 4))
|
||||||
var/g_hair = hex2num(copytext(new_hair, 4, 6))
|
var/g_hair = hex2num(copytext(new_hair, 4, 6))
|
||||||
var/b_hair = hex2num(copytext(new_hair, 6, 8))
|
var/b_hair = hex2num(copytext(new_hair, 6, 8))
|
||||||
if(target.change_hair_color(r_hair, g_hair, b_hair))
|
if(owner.change_hair_color(r_hair, g_hair, b_hair))
|
||||||
update_dna(target)
|
update_dna(owner)
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_HAIRCOLOR)
|
changed_hook(APPEARANCECHANGER_CHANGED_HAIRCOLOR)
|
||||||
return 1
|
return 1
|
||||||
if("facial_hair")
|
if("facial_hair")
|
||||||
if(can_change(target, APPEARANCE_FACIAL_HAIR) && (params["facial_hair"] in valid_facial_hairstyles))
|
if(can_change(owner, APPEARANCE_FACIAL_HAIR) && (params["facial_hair"] in valid_facial_hairstyles))
|
||||||
if(target.change_facial_hair(params["facial_hair"]))
|
if(owner.change_facial_hair(params["facial_hair"]))
|
||||||
update_dna(target)
|
update_dna(owner)
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_F_HAIRSTYLE)
|
changed_hook(APPEARANCECHANGER_CHANGED_F_HAIRSTYLE)
|
||||||
return 1
|
return 1
|
||||||
if("facial_hair_color")
|
if("facial_hair_color")
|
||||||
if(can_change(target, APPEARANCE_FACIAL_HAIR_COLOR))
|
if(can_change(owner, APPEARANCE_FACIAL_HAIR_COLOR))
|
||||||
var/new_facial = input(target, "Please select facial hair color.", "Facial Hair Color", rgb(target.r_facial, target.g_facial, target.b_facial)) as color|null
|
var/new_facial = input(ui.user, "Please select facial hair color.", "Facial Hair Color", rgb(owner.r_facial, owner.g_facial, owner.b_facial)) as color|null
|
||||||
if(new_facial && can_still_topic(target, state))
|
if(new_facial && can_still_topic(owner, state))
|
||||||
var/r_facial = hex2num(copytext(new_facial, 2, 4))
|
var/r_facial = hex2num(copytext(new_facial, 2, 4))
|
||||||
var/g_facial = hex2num(copytext(new_facial, 4, 6))
|
var/g_facial = hex2num(copytext(new_facial, 4, 6))
|
||||||
var/b_facial = hex2num(copytext(new_facial, 6, 8))
|
var/b_facial = hex2num(copytext(new_facial, 6, 8))
|
||||||
if(target.change_facial_hair_color(r_facial, g_facial, b_facial))
|
if(owner.change_facial_hair_color(r_facial, g_facial, b_facial))
|
||||||
update_dna(target)
|
update_dna(owner)
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_F_HAIRCOLOR)
|
changed_hook(APPEARANCECHANGER_CHANGED_F_HAIRCOLOR)
|
||||||
return 1
|
return 1
|
||||||
if("eye_color")
|
if("eye_color")
|
||||||
if(can_change(target, APPEARANCE_EYE_COLOR))
|
if(can_change(owner, APPEARANCE_EYE_COLOR))
|
||||||
var/new_eyes = input(target, "Please select eye color.", "Eye Color", rgb(target.r_eyes, target.g_eyes, target.b_eyes)) as color|null
|
var/new_eyes = input(ui.user, "Please select eye color.", "Eye Color", rgb(owner.r_eyes, owner.g_eyes, owner.b_eyes)) as color|null
|
||||||
if(new_eyes && can_still_topic(target, state))
|
if(new_eyes && can_still_topic(owner, state))
|
||||||
var/r_eyes = hex2num(copytext(new_eyes, 2, 4))
|
var/r_eyes = hex2num(copytext(new_eyes, 2, 4))
|
||||||
var/g_eyes = hex2num(copytext(new_eyes, 4, 6))
|
var/g_eyes = hex2num(copytext(new_eyes, 4, 6))
|
||||||
var/b_eyes = hex2num(copytext(new_eyes, 6, 8))
|
var/b_eyes = hex2num(copytext(new_eyes, 6, 8))
|
||||||
if(target.change_eye_color(r_eyes, g_eyes, b_eyes))
|
if(owner.change_eye_color(r_eyes, g_eyes, b_eyes))
|
||||||
update_dna(target)
|
update_dna(owner)
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_EYES)
|
changed_hook(APPEARANCECHANGER_CHANGED_EYES)
|
||||||
return 1
|
return 1
|
||||||
// VOREStation Add - Ears/Tails/Wings/Markings
|
// VOREStation Add - Ears/Tails/Wings/Markings
|
||||||
if("ear")
|
if("ear")
|
||||||
if(can_change(target, APPEARANCE_ALL_HAIR))
|
if(can_change(owner, APPEARANCE_ALL_HAIR))
|
||||||
var/datum/sprite_accessory/ears/instance = locate(params["ref"])
|
var/datum/sprite_accessory/ears/instance = locate(params["ref"])
|
||||||
if(params["clear"])
|
if(params["clear"])
|
||||||
instance = null
|
instance = null
|
||||||
if(!istype(instance) && !params["clear"])
|
if(!istype(instance) && !params["clear"])
|
||||||
return FALSE
|
return FALSE
|
||||||
target.ear_style = instance
|
owner.ear_style = instance
|
||||||
target.update_hair()
|
owner.update_hair()
|
||||||
update_dna(target)
|
update_dna(owner)
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_HAIRSTYLE)
|
changed_hook(APPEARANCECHANGER_CHANGED_HAIRSTYLE)
|
||||||
return TRUE
|
return TRUE
|
||||||
if("ear_secondary")
|
if("ear_secondary")
|
||||||
if(can_change(target, APPEARANCE_ALL_HAIR))
|
if(can_change(owner, APPEARANCE_ALL_HAIR))
|
||||||
var/datum/sprite_accessory/ears/instance = locate(params["ref"])
|
var/datum/sprite_accessory/ears/instance = locate(params["ref"])
|
||||||
if(params["clear"])
|
if(params["clear"])
|
||||||
instance = null
|
instance = null
|
||||||
if(!istype(instance) && !params["clear"])
|
if(!istype(instance) && !params["clear"])
|
||||||
return FALSE
|
return FALSE
|
||||||
target.ear_secondary_style = instance
|
owner.ear_secondary_style = instance
|
||||||
if(!islist(target.ear_secondary_colors))
|
if(!islist(owner.ear_secondary_colors))
|
||||||
target.ear_secondary_colors = list()
|
owner.ear_secondary_colors = list()
|
||||||
if(length(target.ear_secondary_colors) < instance.get_color_channel_count())
|
if(instance && length(owner.ear_secondary_colors) < instance.get_color_channel_count())
|
||||||
target.ear_secondary_colors.len = instance.get_color_channel_count()
|
owner.ear_secondary_colors.len = instance.get_color_channel_count()
|
||||||
target.update_hair()
|
owner.update_hair()
|
||||||
update_dna(target)
|
update_dna(owner)
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_HAIRSTYLE)
|
changed_hook(APPEARANCECHANGER_CHANGED_HAIRSTYLE)
|
||||||
return TRUE
|
return TRUE
|
||||||
if("ears_color")
|
if("ears_color")
|
||||||
if(can_change(target, APPEARANCE_HAIR_COLOR))
|
if(can_change(owner, APPEARANCE_HAIR_COLOR))
|
||||||
var/new_hair = input(target, "Please select ear color.", "Ear Color", rgb(target.r_ears, target.g_ears, target.b_ears)) as color|null
|
var/new_hair = input(ui.user, "Please select ear color.", "Ear Color", rgb(owner.r_ears, owner.g_ears, owner.b_ears)) as color|null
|
||||||
if(new_hair && can_still_topic(target, state))
|
if(new_hair && can_still_topic(owner, state))
|
||||||
target.r_ears = hex2num(copytext(new_hair, 2, 4))
|
owner.r_ears = hex2num(copytext(new_hair, 2, 4))
|
||||||
target.g_ears = hex2num(copytext(new_hair, 4, 6))
|
owner.g_ears = hex2num(copytext(new_hair, 4, 6))
|
||||||
target.b_ears = hex2num(copytext(new_hair, 6, 8))
|
owner.b_ears = hex2num(copytext(new_hair, 6, 8))
|
||||||
update_dna(target)
|
update_dna(owner)
|
||||||
target.update_hair()
|
owner.update_hair()
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_HAIRCOLOR)
|
changed_hook(APPEARANCECHANGER_CHANGED_HAIRCOLOR)
|
||||||
return 1
|
return 1
|
||||||
if("ears2_color")
|
if("ears2_color")
|
||||||
if(can_change(target, APPEARANCE_HAIR_COLOR))
|
if(can_change(owner, APPEARANCE_HAIR_COLOR))
|
||||||
var/new_hair = input(target, "Please select secondary ear color.", "2nd Ear Color", rgb(target.r_ears2, target.g_ears2, target.b_ears2)) as color|null
|
var/new_hair = input(ui.user, "Please select secondary ear color.", "2nd Ear Color", rgb(owner.r_ears2, owner.g_ears2, owner.b_ears2)) as color|null
|
||||||
if(new_hair && can_still_topic(target, state))
|
if(new_hair && can_still_topic(owner, state))
|
||||||
target.r_ears2 = hex2num(copytext(new_hair, 2, 4))
|
owner.r_ears2 = hex2num(copytext(new_hair, 2, 4))
|
||||||
target.g_ears2 = hex2num(copytext(new_hair, 4, 6))
|
owner.g_ears2 = hex2num(copytext(new_hair, 4, 6))
|
||||||
target.b_ears2 = hex2num(copytext(new_hair, 6, 8))
|
owner.b_ears2 = hex2num(copytext(new_hair, 6, 8))
|
||||||
update_dna(target)
|
update_dna(owner)
|
||||||
target.update_hair()
|
owner.update_hair()
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_HAIRCOLOR)
|
changed_hook(APPEARANCECHANGER_CHANGED_HAIRCOLOR)
|
||||||
return 1
|
return 1
|
||||||
if("ears_secondary_color")
|
if("ears_secondary_color")
|
||||||
if(can_change(target, APPEARANCE_HAIR_COLOR))
|
if(can_change(owner, APPEARANCE_HAIR_COLOR))
|
||||||
var/channel = params["channel"]
|
var/channel = params["channel"]
|
||||||
if(channel > length(target.ear_secondary_colors))
|
if(channel > length(owner.ear_secondary_colors))
|
||||||
return TRUE
|
return TRUE
|
||||||
var/existing = LAZYACCESS(target.ear_secondary_colors, channel) || "#ffffff"
|
var/existing = LAZYACCESS(owner.ear_secondary_colors, channel) || "#ffffff"
|
||||||
var/new_color = input(target, "Please select ear color.", "2nd Ear Color", existing) as color|null
|
var/new_color = input(ui.user, "Please select ear color.", "2nd Ear Color", existing) as color|null
|
||||||
if(new_color && can_still_topic(target, state))
|
if(new_color && can_still_topic(owner, state))
|
||||||
target.ear_secondary_colors[channel] = new_color
|
owner.ear_secondary_colors[channel] = new_color
|
||||||
update_dna(target)
|
update_dna(owner)
|
||||||
target.update_hair()
|
owner.update_hair()
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_HAIRCOLOR)
|
changed_hook(APPEARANCECHANGER_CHANGED_HAIRCOLOR)
|
||||||
return TRUE
|
return TRUE
|
||||||
if("tail")
|
if("tail")
|
||||||
if(can_change(target, APPEARANCE_ALL_HAIR))
|
if(can_change(owner, APPEARANCE_ALL_HAIR))
|
||||||
var/datum/sprite_accessory/tail/instance = locate(params["ref"])
|
var/datum/sprite_accessory/tail/instance = locate(params["ref"])
|
||||||
if(params["clear"])
|
if(params["clear"])
|
||||||
instance = null
|
instance = null
|
||||||
if(!istype(instance) && !params["clear"])
|
if(!istype(instance) && !params["clear"])
|
||||||
return FALSE
|
return FALSE
|
||||||
target.tail_style = instance
|
owner.tail_style = instance
|
||||||
target.update_tail_showing()
|
owner.update_tail_showing()
|
||||||
update_dna(target)
|
update_dna(owner)
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_HAIRSTYLE)
|
changed_hook(APPEARANCECHANGER_CHANGED_HAIRSTYLE)
|
||||||
return TRUE
|
return TRUE
|
||||||
if("tail_color")
|
if("tail_color")
|
||||||
if(can_change(target, APPEARANCE_HAIR_COLOR))
|
if(can_change(owner, APPEARANCE_HAIR_COLOR))
|
||||||
var/new_hair = input(target, "Please select tail color.", "Tail Color", rgb(target.r_tail, target.g_tail, target.b_tail)) as color|null
|
var/new_hair = input(ui.user, "Please select tail color.", "Tail Color", rgb(owner.r_tail, owner.g_tail, owner.b_tail)) as color|null
|
||||||
if(new_hair && can_still_topic(target, state))
|
if(new_hair && can_still_topic(owner, state))
|
||||||
target.r_tail = hex2num(copytext(new_hair, 2, 4))
|
owner.r_tail = hex2num(copytext(new_hair, 2, 4))
|
||||||
target.g_tail = hex2num(copytext(new_hair, 4, 6))
|
owner.g_tail = hex2num(copytext(new_hair, 4, 6))
|
||||||
target.b_tail = hex2num(copytext(new_hair, 6, 8))
|
owner.b_tail = hex2num(copytext(new_hair, 6, 8))
|
||||||
update_dna(target)
|
update_dna(owner)
|
||||||
target.update_tail_showing()
|
owner.update_tail_showing()
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_HAIRCOLOR)
|
changed_hook(APPEARANCECHANGER_CHANGED_HAIRCOLOR)
|
||||||
return 1
|
return 1
|
||||||
if("tail2_color")
|
if("tail2_color")
|
||||||
if(can_change(target, APPEARANCE_HAIR_COLOR))
|
if(can_change(owner, APPEARANCE_HAIR_COLOR))
|
||||||
var/new_hair = input(target, "Please select secondary tail color.", "2nd Tail Color", rgb(target.r_tail2, target.g_tail2, target.b_tail2)) as color|null
|
var/new_hair = input(ui.user, "Please select secondary tail color.", "2nd Tail Color", rgb(owner.r_tail2, owner.g_tail2, owner.b_tail2)) as color|null
|
||||||
if(new_hair && can_still_topic(target, state))
|
if(new_hair && can_still_topic(owner, state))
|
||||||
target.r_tail2 = hex2num(copytext(new_hair, 2, 4))
|
owner.r_tail2 = hex2num(copytext(new_hair, 2, 4))
|
||||||
target.g_tail2 = hex2num(copytext(new_hair, 4, 6))
|
owner.g_tail2 = hex2num(copytext(new_hair, 4, 6))
|
||||||
target.b_tail2 = hex2num(copytext(new_hair, 6, 8))
|
owner.b_tail2 = hex2num(copytext(new_hair, 6, 8))
|
||||||
update_dna(target)
|
update_dna(owner)
|
||||||
target.update_tail_showing()
|
owner.update_tail_showing()
|
||||||
|
changed_hook(APPEARANCECHANGER_CHANGED_HAIRCOLOR)
|
||||||
|
return 1
|
||||||
|
if("tail3_color")
|
||||||
|
if(can_change(owner, APPEARANCE_HAIR_COLOR))
|
||||||
|
var/new_hair = input(ui.user, "Please select secondary tail color.", "3rd Tail Color", rgb(owner.r_tail3, owner.g_tail3, owner.b_tail3)) as color|null
|
||||||
|
if(new_hair && can_still_topic(owner, state))
|
||||||
|
owner.r_tail3 = hex2num(copytext(new_hair, 2, 4))
|
||||||
|
owner.g_tail3 = hex2num(copytext(new_hair, 4, 6))
|
||||||
|
owner.b_tail3 = hex2num(copytext(new_hair, 6, 8))
|
||||||
|
update_dna(owner)
|
||||||
|
owner.update_tail_showing()
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_HAIRCOLOR)
|
changed_hook(APPEARANCECHANGER_CHANGED_HAIRCOLOR)
|
||||||
return 1
|
return 1
|
||||||
if("wing")
|
if("wing")
|
||||||
if(can_change(target, APPEARANCE_ALL_HAIR))
|
if(can_change(owner, APPEARANCE_ALL_HAIR))
|
||||||
var/datum/sprite_accessory/wing/instance = locate(params["ref"])
|
var/datum/sprite_accessory/wing/instance = locate(params["ref"])
|
||||||
if(params["clear"])
|
if(params["clear"])
|
||||||
instance = null
|
instance = null
|
||||||
if(!istype(instance) && !params["clear"])
|
if(!istype(instance) && !params["clear"])
|
||||||
return FALSE
|
return FALSE
|
||||||
target.wing_style = instance
|
owner.wing_style = instance
|
||||||
target.update_wing_showing()
|
owner.update_wing_showing()
|
||||||
update_dna(target)
|
update_dna(owner)
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_HAIRSTYLE)
|
changed_hook(APPEARANCECHANGER_CHANGED_HAIRSTYLE)
|
||||||
return TRUE
|
return TRUE
|
||||||
if("wing_color")
|
if("wing_color")
|
||||||
if(can_change(target, APPEARANCE_HAIR_COLOR))
|
if(can_change(owner, APPEARANCE_HAIR_COLOR))
|
||||||
var/new_hair = input(target, "Please select wing color.", "Wing Color", rgb(target.r_wing, target.g_wing, target.b_wing)) as color|null
|
var/new_hair = input(ui.user, "Please select wing color.", "Wing Color", rgb(owner.r_wing, owner.g_wing, owner.b_wing)) as color|null
|
||||||
if(new_hair && can_still_topic(target, state))
|
if(new_hair && can_still_topic(owner, state))
|
||||||
target.r_wing = hex2num(copytext(new_hair, 2, 4))
|
owner.r_wing = hex2num(copytext(new_hair, 2, 4))
|
||||||
target.g_wing = hex2num(copytext(new_hair, 4, 6))
|
owner.g_wing = hex2num(copytext(new_hair, 4, 6))
|
||||||
target.b_wing = hex2num(copytext(new_hair, 6, 8))
|
owner.b_wing = hex2num(copytext(new_hair, 6, 8))
|
||||||
update_dna(target)
|
update_dna(owner)
|
||||||
target.update_wing_showing()
|
owner.update_wing_showing()
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_HAIRCOLOR)
|
changed_hook(APPEARANCECHANGER_CHANGED_HAIRCOLOR)
|
||||||
return 1
|
return 1
|
||||||
if("wing2_color")
|
if("wing2_color")
|
||||||
if(can_change(target, APPEARANCE_HAIR_COLOR))
|
if(can_change(owner, APPEARANCE_HAIR_COLOR))
|
||||||
var/new_hair = input(target, "Please select secondary wing color.", "2nd Wing Color", rgb(target.r_wing2, target.g_wing2, target.b_wing2)) as color|null
|
var/new_hair = input(ui.user, "Please select secondary wing color.", "2nd Wing Color", rgb(owner.r_wing2, owner.g_wing2, owner.b_wing2)) as color|null
|
||||||
if(new_hair && can_still_topic(target, state))
|
if(new_hair && can_still_topic(owner, state))
|
||||||
target.r_wing2 = hex2num(copytext(new_hair, 2, 4))
|
owner.r_wing2 = hex2num(copytext(new_hair, 2, 4))
|
||||||
target.g_wing2 = hex2num(copytext(new_hair, 4, 6))
|
owner.g_wing2 = hex2num(copytext(new_hair, 4, 6))
|
||||||
target.b_wing2 = hex2num(copytext(new_hair, 6, 8))
|
owner.b_wing2 = hex2num(copytext(new_hair, 6, 8))
|
||||||
update_dna(target)
|
update_dna(owner)
|
||||||
target.update_wing_showing()
|
owner.update_wing_showing()
|
||||||
|
changed_hook(APPEARANCECHANGER_CHANGED_HAIRCOLOR)
|
||||||
|
return 1
|
||||||
|
if("wing3_color")
|
||||||
|
if(can_change(owner, APPEARANCE_HAIR_COLOR))
|
||||||
|
var/new_hair = input(ui.user, "Please select secondary wing color.", "3rd Wing Color", rgb(owner.r_wing3, owner.g_wing3, owner.b_wing3)) as color|null
|
||||||
|
if(new_hair && can_still_topic(owner, state))
|
||||||
|
owner.r_wing3 = hex2num(copytext(new_hair, 2, 4))
|
||||||
|
owner.g_wing3 = hex2num(copytext(new_hair, 4, 6))
|
||||||
|
owner.b_wing3 = hex2num(copytext(new_hair, 6, 8))
|
||||||
|
update_dna(owner)
|
||||||
|
owner.update_wing_showing()
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_HAIRCOLOR)
|
changed_hook(APPEARANCECHANGER_CHANGED_HAIRCOLOR)
|
||||||
return 1
|
return 1
|
||||||
if("marking")
|
if("marking")
|
||||||
if(can_change(target, APPEARANCE_ALL_HAIR))
|
if(can_change(owner, APPEARANCE_ALL_HAIR))
|
||||||
var/todo = params["todo"]
|
var/todo = params["todo"]
|
||||||
var/name_marking = params["name"]
|
var/name_marking = params["name"]
|
||||||
switch (todo)
|
switch (todo)
|
||||||
if (0) //delete
|
if (0) //delete
|
||||||
if (name_marking)
|
if (name_marking)
|
||||||
var/datum/sprite_accessory/marking/mark_datum = body_marking_styles_list[name_marking]
|
var/datum/sprite_accessory/marking/mark_datum = body_marking_styles_list[name_marking]
|
||||||
if (target.remove_marking(mark_datum))
|
if (owner.remove_marking(mark_datum))
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_HAIRSTYLE)
|
changed_hook(APPEARANCECHANGER_CHANGED_HAIRSTYLE)
|
||||||
return TRUE
|
return TRUE
|
||||||
if (1) //add
|
if (1) //add
|
||||||
var/list/usable_markings = markings.Copy() ^ body_marking_styles_list.Copy()
|
var/list/usable_markings = markings.Copy() ^ body_marking_styles_list.Copy()
|
||||||
var/new_marking = tgui_input_list(target, "Choose a body marking:", "New Body Marking", usable_markings)
|
var/new_marking = tgui_input_list(ui.user, "Choose a body marking:", "New Body Marking", usable_markings)
|
||||||
if(new_marking && can_still_topic(target, state))
|
if(new_marking && can_still_topic(owner, state))
|
||||||
var/datum/sprite_accessory/marking/mark_datum = body_marking_styles_list[new_marking]
|
var/datum/sprite_accessory/marking/mark_datum = body_marking_styles_list[new_marking]
|
||||||
if (target.add_marking(mark_datum))
|
if (owner.add_marking(mark_datum))
|
||||||
changed_hook(APPEARANCECHANGER_CHANGED_HAIRSTYLE)
|
changed_hook(APPEARANCECHANGER_CHANGED_HAIRSTYLE)
|
||||||
return TRUE
|
return TRUE
|
||||||
if (2) //move up
|
if (2) //move up
|
||||||
var/datum/sprite_accessory/marking/mark_datum = body_marking_styles_list[name_marking]
|
var/datum/sprite_accessory/marking/mark_datum = body_marking_styles_list[name_marking]
|
||||||
if (target.change_priority_of_marking(mark_datum, FALSE))
|
if (owner.change_priority_of_marking(mark_datum, FALSE))
|
||||||
return TRUE
|
return TRUE
|
||||||
if (3) //move down
|
if (3) //move down
|
||||||
var/datum/sprite_accessory/marking/mark_datum = body_marking_styles_list[name_marking]
|
var/datum/sprite_accessory/marking/mark_datum = body_marking_styles_list[name_marking]
|
||||||
if (target.change_priority_of_marking(mark_datum, TRUE))
|
if (owner.change_priority_of_marking(mark_datum, TRUE))
|
||||||
return TRUE
|
return TRUE
|
||||||
if (4) //color
|
if (4) //color
|
||||||
var/current = markings[name_marking] ? markings[name_marking] : "#000000"
|
var/current = markings[name_marking] ? markings[name_marking] : "#000000"
|
||||||
var/marking_color = input(target, "Please select marking color", "Marking color", current) as color|null
|
var/marking_color = input(ui.user, "Please select marking color", "Marking color", current) as color|null
|
||||||
if(marking_color && can_still_topic(target, state))
|
if(marking_color && can_still_topic(owner, state))
|
||||||
var/datum/sprite_accessory/marking/mark_datum = body_marking_styles_list[name_marking]
|
var/datum/sprite_accessory/marking/mark_datum = body_marking_styles_list[name_marking]
|
||||||
if (target.change_marking_color(mark_datum, marking_color))
|
if (owner.change_marking_color(mark_datum, marking_color))
|
||||||
return TRUE
|
return TRUE
|
||||||
// VOREStation Add End
|
// VOREStation Add End
|
||||||
return FALSE
|
return FALSE
|
||||||
|
|
||||||
/datum/tgui_module/appearance_changer/tgui_interact(mob/user, datum/tgui/ui = null, datum/tgui/parent_ui = null, datum/tgui_state/custom_state)
|
/datum/tgui_module/appearance_changer/tgui_interact(mob/user, datum/tgui/ui = null, datum/tgui/parent_ui = null, datum/tgui_state/custom_state)
|
||||||
var/mob/living/carbon/human/target = owner
|
if(customize_usr && !owner)
|
||||||
if(customize_usr)
|
|
||||||
if(!ishuman(user))
|
if(!ishuman(user))
|
||||||
return TRUE
|
return TRUE
|
||||||
target = user
|
owner = user
|
||||||
|
|
||||||
if(!target || !target.species)
|
if(!owner || !owner.species)
|
||||||
return
|
return
|
||||||
|
|
||||||
ui = SStgui.try_update_ui(user, src, ui)
|
ui = SStgui.try_update_ui(user, src, ui)
|
||||||
update_active_camera_screen()
|
|
||||||
if(!ui)
|
if(!ui)
|
||||||
|
owner.AddComponent(/datum/component/recursive_move)
|
||||||
|
RegisterSignal(owner, COMSIG_OBSERVER_MOVED, PROC_REF(update_active_camera_screen))
|
||||||
// Register map objects
|
// Register map objects
|
||||||
user.client.register_map_obj(cam_screen)
|
user.client.register_map_obj(cam_screen)
|
||||||
for(var/plane in cam_plane_masters)
|
for(var/plane in cam_plane_masters)
|
||||||
@@ -370,19 +384,20 @@
|
|||||||
ui.open()
|
ui.open()
|
||||||
if(custom_state)
|
if(custom_state)
|
||||||
ui.set_state(custom_state)
|
ui.set_state(custom_state)
|
||||||
|
update_active_camera_screen()
|
||||||
|
|
||||||
/datum/tgui_module/appearance_changer/tgui_static_data(mob/user)
|
/datum/tgui_module/appearance_changer/tgui_static_data(mob/user)
|
||||||
var/list/data = ..()
|
var/list/data = ..()
|
||||||
|
|
||||||
generate_data(user)
|
generate_data(user, owner)
|
||||||
|
|
||||||
if(can_change(user, APPEARANCE_RACE))
|
if(can_change(owner, APPEARANCE_RACE))
|
||||||
var/species[0]
|
var/species[0]
|
||||||
for(var/specimen in valid_species)
|
for(var/specimen in valid_species)
|
||||||
species[++species.len] = list("specimen" = specimen)
|
species[++species.len] = list("specimen" = specimen)
|
||||||
data["species"] = species
|
data["species"] = species
|
||||||
|
|
||||||
if(can_change(user, APPEARANCE_HAIR))
|
if(can_change(owner, APPEARANCE_HAIR))
|
||||||
var/hair_styles[0]
|
var/hair_styles[0]
|
||||||
for(var/hair_style in valid_hairstyles)
|
for(var/hair_style in valid_hairstyles)
|
||||||
hair_styles[++hair_styles.len] = list("hairstyle" = hair_style)
|
hair_styles[++hair_styles.len] = list("hairstyle" = hair_style)
|
||||||
@@ -393,7 +408,7 @@
|
|||||||
data["wing_styles"] = valid_wingstyles
|
data["wing_styles"] = valid_wingstyles
|
||||||
// VOREStation Add End
|
// VOREStation Add End
|
||||||
|
|
||||||
if(can_change(user, APPEARANCE_FACIAL_HAIR))
|
if(can_change(owner, APPEARANCE_FACIAL_HAIR))
|
||||||
var/facial_hair_styles[0]
|
var/facial_hair_styles[0]
|
||||||
for(var/facial_hair_style in valid_facial_hairstyles)
|
for(var/facial_hair_style in valid_facial_hairstyles)
|
||||||
facial_hair_styles[++facial_hair_styles.len] = list("facialhairstyle" = facial_hair_style)
|
facial_hair_styles[++facial_hair_styles.len] = list("facialhairstyle" = facial_hair_style)
|
||||||
@@ -404,24 +419,18 @@
|
|||||||
/datum/tgui_module/appearance_changer/tgui_data(mob/user, datum/tgui/ui, datum/tgui_state/state)
|
/datum/tgui_module/appearance_changer/tgui_data(mob/user, datum/tgui/ui, datum/tgui_state/state)
|
||||||
var/list/data = ..()
|
var/list/data = ..()
|
||||||
|
|
||||||
generate_data(user)
|
generate_data(user, owner)
|
||||||
|
|
||||||
var/mob/living/carbon/human/target = owner
|
data["name"] = owner.name
|
||||||
if(customize_usr)
|
data["specimen"] = owner.species.name
|
||||||
if(!ishuman(ui.user))
|
data["gender"] = owner.gender
|
||||||
return TRUE
|
data["gender_id"] = owner.identifying_gender
|
||||||
target = ui.user
|
data["change_race"] = can_change(owner, APPEARANCE_RACE)
|
||||||
|
|
||||||
data["name"] = target.name
|
data["change_gender"] = can_change(owner, APPEARANCE_GENDER)
|
||||||
data["specimen"] = target.species.name
|
|
||||||
data["gender"] = target.gender
|
|
||||||
data["gender_id"] = target.identifying_gender
|
|
||||||
data["change_race"] = can_change(target, APPEARANCE_RACE)
|
|
||||||
|
|
||||||
data["change_gender"] = can_change(target, APPEARANCE_GENDER)
|
|
||||||
if(data["change_gender"])
|
if(data["change_gender"])
|
||||||
var/genders[0]
|
var/genders[0]
|
||||||
for(var/gender in get_genders(target))
|
for(var/gender in get_genders(owner))
|
||||||
genders[++genders.len] = list("gender_name" = gender2text(gender), "gender_key" = gender)
|
genders[++genders.len] = list("gender_name" = gender2text(gender), "gender_key" = gender)
|
||||||
data["genders"] = genders
|
data["genders"] = genders
|
||||||
var/id_genders[0]
|
var/id_genders[0]
|
||||||
@@ -429,56 +438,58 @@
|
|||||||
id_genders[++id_genders.len] = list("gender_name" = gender2text(gender), "gender_key" = gender)
|
id_genders[++id_genders.len] = list("gender_name" = gender2text(gender), "gender_key" = gender)
|
||||||
data["id_genders"] = id_genders
|
data["id_genders"] = id_genders
|
||||||
|
|
||||||
data["change_hair"] = can_change(target, APPEARANCE_HAIR)
|
data["change_hair"] = can_change(owner, APPEARANCE_HAIR)
|
||||||
if(data["change_hair"])
|
if(data["change_hair"])
|
||||||
data["hair_style"] = target.h_style
|
data["hair_style"] = owner.h_style
|
||||||
|
|
||||||
// VOREStation Add - Ears/Tails/Wings
|
// VOREStation Add - Ears/Tails/Wings
|
||||||
data["ear_style"] = target.ear_style
|
data["ear_style"] = owner.ear_style
|
||||||
data["ear_secondary_style"] = target.ear_secondary_style?.name
|
data["ear_secondary_style"] = owner.ear_secondary_style?.name
|
||||||
data["tail_style"] = target.tail_style
|
data["tail_style"] = owner.tail_style
|
||||||
data["wing_style"] = target.wing_style
|
data["wing_style"] = owner.wing_style
|
||||||
var/list/markings_data[0]
|
var/list/markings_data[0]
|
||||||
markings = target.get_prioritised_markings()
|
markings = owner.get_prioritised_markings()
|
||||||
for (var/marking in markings)
|
for (var/marking in markings)
|
||||||
markings_data[++markings_data.len] = list("marking_name" = marking, "marking_color" = markings[marking]["color"] ? markings[marking]["color"] : "#000000") //too tired to add in another submenu for bodyparts here
|
markings_data[++markings_data.len] = list("marking_name" = marking, "marking_color" = markings[marking]["color"] ? markings[marking]["color"] : "#000000") //too tired to add in another submenu for bodyparts here
|
||||||
data["markings"] = markings_data
|
data["markings"] = markings_data
|
||||||
// VOREStation Add End
|
// VOREStation Add End
|
||||||
|
|
||||||
data["change_facial_hair"] = can_change(target, APPEARANCE_FACIAL_HAIR)
|
data["change_facial_hair"] = can_change(owner, APPEARANCE_FACIAL_HAIR)
|
||||||
if(data["change_facial_hair"])
|
if(data["change_facial_hair"])
|
||||||
data["facial_hair_style"] = target.f_style
|
data["facial_hair_style"] = owner.f_style
|
||||||
|
|
||||||
data["change_skin_tone"] = can_change_skin_tone(target)
|
data["change_skin_tone"] = can_change_skin_tone(owner)
|
||||||
data["change_skin_color"] = can_change_skin_color(target)
|
data["change_skin_color"] = can_change_skin_color(owner)
|
||||||
if(data["change_skin_color"])
|
if(data["change_skin_color"])
|
||||||
data["skin_color"] = rgb(target.r_skin, target.g_skin, target.b_skin)
|
data["skin_color"] = rgb(owner.r_skin, owner.g_skin, owner.b_skin)
|
||||||
|
|
||||||
data["change_eye_color"] = can_change(target, APPEARANCE_EYE_COLOR)
|
data["change_eye_color"] = can_change(owner, APPEARANCE_EYE_COLOR)
|
||||||
if(data["change_eye_color"])
|
if(data["change_eye_color"])
|
||||||
data["eye_color"] = rgb(target.r_eyes, target.g_eyes, target.b_eyes)
|
data["eye_color"] = rgb(owner.r_eyes, owner.g_eyes, owner.b_eyes)
|
||||||
|
|
||||||
data["change_hair_color"] = can_change(target, APPEARANCE_HAIR_COLOR)
|
data["change_hair_color"] = can_change(owner, APPEARANCE_HAIR_COLOR)
|
||||||
if(data["change_hair_color"])
|
if(data["change_hair_color"])
|
||||||
data["hair_color"] = rgb(target.r_hair, target.g_hair, target.b_hair)
|
data["hair_color"] = rgb(owner.r_hair, owner.g_hair, owner.b_hair)
|
||||||
// VOREStation Add - Ears/Tails/Wings
|
// VOREStation Add - Ears/Tails/Wings
|
||||||
data["ears_color"] = rgb(target.r_ears, target.g_ears, target.b_ears)
|
data["ears_color"] = rgb(owner.r_ears, owner.g_ears, owner.b_ears)
|
||||||
data["ears2_color"] = rgb(target.r_ears2, target.g_ears2, target.b_ears2)
|
data["ears2_color"] = rgb(owner.r_ears2, owner.g_ears2, owner.b_ears2)
|
||||||
|
|
||||||
// secondary ear colors
|
// secondary ear colors
|
||||||
var/list/ear_secondary_color_channels = target.ear_secondary_colors || list()
|
var/list/ear_secondary_color_channels = owner.ear_secondary_colors || list()
|
||||||
ear_secondary_color_channels.len = target.ear_secondary_style?.get_color_channel_count() || 0
|
ear_secondary_color_channels.len = owner.ear_secondary_style?.get_color_channel_count() || 0
|
||||||
data["ear_secondary_colors"] = ear_secondary_color_channels
|
data["ear_secondary_colors"] = ear_secondary_color_channels
|
||||||
|
|
||||||
data["tail_color"] = rgb(target.r_tail, target.g_tail, target.b_tail)
|
data["tail_color"] = rgb(owner.r_tail, owner.g_tail, owner.b_tail)
|
||||||
data["tail2_color"] = rgb(target.r_tail2, target.g_tail2, target.b_tail2)
|
data["tail2_color"] = rgb(owner.r_tail2, owner.g_tail2, owner.b_tail2)
|
||||||
data["wing_color"] = rgb(target.r_wing, target.g_wing, target.b_wing)
|
data["tail3_color"] = rgb(owner.r_tail3, owner.g_tail3, owner.b_tail3)
|
||||||
data["wing2_color"] = rgb(target.r_wing2, target.g_wing2, target.b_wing2)
|
data["wing_color"] = rgb(owner.r_wing, owner.g_wing, owner.b_wing)
|
||||||
|
data["wing2_color"] = rgb(owner.r_wing2, owner.g_wing2, owner.b_wing2)
|
||||||
|
data["wing3_color"] = rgb(owner.r_wing3, owner.g_wing3, owner.b_wing3)
|
||||||
// VOREStation Add End
|
// VOREStation Add End
|
||||||
|
|
||||||
data["change_facial_hair_color"] = can_change(target, APPEARANCE_FACIAL_HAIR_COLOR)
|
data["change_facial_hair_color"] = can_change(owner, APPEARANCE_FACIAL_HAIR_COLOR)
|
||||||
if(data["change_facial_hair_color"])
|
if(data["change_facial_hair_color"])
|
||||||
data["facial_hair_color"] = rgb(target.r_facial, target.g_facial, target.b_facial)
|
data["facial_hair_color"] = rgb(owner.r_facial, owner.g_facial, owner.b_facial)
|
||||||
return data
|
return data
|
||||||
|
|
||||||
/datum/tgui_module/appearance_changer/tgui_static_data(mob/user)
|
/datum/tgui_module/appearance_changer/tgui_static_data(mob/user)
|
||||||
@@ -512,30 +523,18 @@
|
|||||||
local_skybox.set_position("CENTER", "CENTER", (world.maxx>>1) - newturf.x, (world.maxy>>1) - newturf.y)
|
local_skybox.set_position("CENTER", "CENTER", (world.maxx>>1) - newturf.x, (world.maxy>>1) - newturf.y)
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/datum/tgui_module/appearance_changer/proc/update_dna(mob/target)
|
/datum/tgui_module/appearance_changer/proc/update_dna(mob/living/carbon/human/target)
|
||||||
if(customize_usr && !ishuman(target))
|
if(target && (flags & APPEARANCE_UPDATE_DNA))
|
||||||
return TRUE
|
target.update_dna()
|
||||||
var/mob/living/carbon/human/H = target
|
|
||||||
if(H && (flags & APPEARANCE_UPDATE_DNA))
|
|
||||||
H.update_dna()
|
|
||||||
|
|
||||||
/datum/tgui_module/appearance_changer/proc/can_change(mob/target, var/flag)
|
/datum/tgui_module/appearance_changer/proc/can_change(mob/living/carbon/human/target, var/flag)
|
||||||
if(customize_usr && !ishuman(target))
|
return target && (flags & flag)
|
||||||
return TRUE
|
|
||||||
var/mob/living/carbon/human/H = target
|
|
||||||
return H && (flags & flag)
|
|
||||||
|
|
||||||
/datum/tgui_module/appearance_changer/proc/can_change_skin_tone(mob/target)
|
/datum/tgui_module/appearance_changer/proc/can_change_skin_tone(mob/living/carbon/human/target)
|
||||||
if(customize_usr && !ishuman(target))
|
return target && (flags & APPEARANCE_SKIN) &&target.species.appearance_flags & HAS_SKIN_TONE
|
||||||
return TRUE
|
|
||||||
var/mob/living/carbon/human/H = target
|
|
||||||
return H && (flags & APPEARANCE_SKIN) && H.species.appearance_flags & HAS_SKIN_TONE
|
|
||||||
|
|
||||||
/datum/tgui_module/appearance_changer/proc/can_change_skin_color(mob/target)
|
/datum/tgui_module/appearance_changer/proc/can_change_skin_color(mob/living/carbon/human/target)
|
||||||
if(customize_usr && !ishuman(target))
|
return target && (flags & APPEARANCE_SKIN) && target.species.appearance_flags & HAS_SKIN_COLOR
|
||||||
return TRUE
|
|
||||||
var/mob/living/carbon/human/H = target
|
|
||||||
return H && (flags & APPEARANCE_SKIN) && H.species.appearance_flags & HAS_SKIN_COLOR
|
|
||||||
|
|
||||||
/datum/tgui_module/appearance_changer/proc/cut_data()
|
/datum/tgui_module/appearance_changer/proc/cut_data()
|
||||||
// Making the assumption that the available species remain constant
|
// Making the assumption that the available species remain constant
|
||||||
@@ -547,14 +546,9 @@
|
|||||||
valid_wingstyles.Cut()
|
valid_wingstyles.Cut()
|
||||||
// VOREStation Add End
|
// VOREStation Add End
|
||||||
|
|
||||||
/datum/tgui_module/appearance_changer/proc/generate_data(mob/user)
|
/datum/tgui_module/appearance_changer/proc/generate_data(mob/user, mob/living/carbon/human/target)
|
||||||
var/mob/living/carbon/human/target = owner
|
if(!ishuman(target))
|
||||||
if(customize_usr)
|
return TRUE
|
||||||
if(!ishuman(user))
|
|
||||||
return TRUE
|
|
||||||
target = user
|
|
||||||
if(!target)
|
|
||||||
return
|
|
||||||
|
|
||||||
if(!LAZYLEN(valid_species))
|
if(!LAZYLEN(valid_species))
|
||||||
valid_species = target.generate_valid_species(check_whitelist, whitelist, blacklist)
|
valid_species = target.generate_valid_species(check_whitelist, whitelist, blacklist)
|
||||||
@@ -598,13 +592,10 @@
|
|||||||
)))
|
)))
|
||||||
// VOREStation Add End
|
// VOREStation Add End
|
||||||
|
|
||||||
/datum/tgui_module/appearance_changer/proc/get_genders(mob/target)
|
/datum/tgui_module/appearance_changer/proc/get_genders(mob/living/carbon/human/target)
|
||||||
if(customize_usr && !ishuman(target))
|
var/datum/species/S = target.species
|
||||||
return TRUE
|
|
||||||
var/mob/living/carbon/human/H = target
|
|
||||||
var/datum/species/S = H.species
|
|
||||||
var/list/possible_genders = S.genders
|
var/list/possible_genders = S.genders
|
||||||
if(!H.internal_organs_by_name["cell"])
|
if(!target.internal_organs_by_name["cell"])
|
||||||
return possible_genders
|
return possible_genders
|
||||||
possible_genders = possible_genders.Copy()
|
possible_genders = possible_genders.Copy()
|
||||||
possible_genders |= NEUTER
|
possible_genders |= NEUTER
|
||||||
@@ -616,6 +607,8 @@
|
|||||||
|
|
||||||
// VOREStation Add - Ears/Tails/Wings
|
// VOREStation Add - Ears/Tails/Wings
|
||||||
/datum/tgui_module/appearance_changer/proc/can_use_sprite(datum/sprite_accessory/X, mob/living/carbon/human/target, mob/user)
|
/datum/tgui_module/appearance_changer/proc/can_use_sprite(datum/sprite_accessory/X, mob/living/carbon/human/target, mob/user)
|
||||||
|
if(X.name == DEVELOPER_WARNING_NAME)
|
||||||
|
return FALSE
|
||||||
if(!isnull(X.species_allowed) && !(target.species.name in X.species_allowed) && (!istype(target.species, /datum/species/custom))) // Letting custom species access wings/ears/tails.
|
if(!isnull(X.species_allowed) && !(target.species.name in X.species_allowed) && (!istype(target.species, /datum/species/custom))) // Letting custom species access wings/ears/tails.
|
||||||
return FALSE
|
return FALSE
|
||||||
|
|
||||||
|
|||||||
@@ -1457,6 +1457,9 @@ var/global/list/belly_colorable_only_fullscreens = list("a_synth_flesh_mono",
|
|||||||
if(!istype(H))
|
if(!istype(H))
|
||||||
return
|
return
|
||||||
|
|
||||||
|
if(!H.allow_spontaneous_tf)
|
||||||
|
return
|
||||||
|
|
||||||
var/datum/tgui_module/appearance_changer/vore/V = new(host, H)
|
var/datum/tgui_module/appearance_changer/vore/V = new(host, H)
|
||||||
V.tgui_interact(user)
|
V.tgui_interact(user)
|
||||||
return TRUE
|
return TRUE
|
||||||
|
|||||||
@@ -130,7 +130,7 @@ export function toTitleCase(str: string): string {
|
|||||||
return currentStr;
|
return currentStr;
|
||||||
}
|
}
|
||||||
|
|
||||||
const TRANSLATE_REGEX = /&(nbsp|amp|quot|lt|gt|apos);/g;
|
const TRANSLATE_REGEX = /&(nbsp|amp|quot|lt|gt|apos|trade);/g;
|
||||||
const TRANSLATIONS = {
|
const TRANSLATIONS = {
|
||||||
amp: '&',
|
amp: '&',
|
||||||
apos: "'",
|
apos: "'",
|
||||||
@@ -138,6 +138,7 @@ const TRANSLATIONS = {
|
|||||||
lt: '<',
|
lt: '<',
|
||||||
nbsp: ' ',
|
nbsp: ' ',
|
||||||
quot: '"',
|
quot: '"',
|
||||||
|
trade: '™',
|
||||||
} as const;
|
} as const;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -19,8 +19,11 @@ export const AppearanceChangerColors = (props) => {
|
|||||||
ears2_color,
|
ears2_color,
|
||||||
tail_color,
|
tail_color,
|
||||||
tail2_color,
|
tail2_color,
|
||||||
|
tail3_color,
|
||||||
wing_color,
|
wing_color,
|
||||||
wing2_color,
|
wing2_color,
|
||||||
|
wing3_color,
|
||||||
|
ear_secondary_colors,
|
||||||
} = data;
|
} = data;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
@@ -67,13 +70,17 @@ export const AppearanceChangerColors = (props) => {
|
|||||||
</Button>
|
</Button>
|
||||||
</Box>
|
</Box>
|
||||||
{data.ear_secondary_colors.map((color, index) => (
|
{data.ear_secondary_colors.map((color, index) => (
|
||||||
<Button
|
<Box key={index}>
|
||||||
key={`${index}`}
|
<ColorBox color={color} mr={1} />
|
||||||
onClick={() => act('ears_secondary_color', { channel: index })}
|
<Button
|
||||||
>
|
onClick={() =>
|
||||||
Change Secondary Ears Color (
|
act('ears_secondary_color', { channel: index + 1 })
|
||||||
{SPRITE_ACCESSORY_COLOR_CHANNEL_NAMES.at(index)})
|
}
|
||||||
</Button>
|
>
|
||||||
|
Change Secondary Ears Color (
|
||||||
|
{SPRITE_ACCESSORY_COLOR_CHANNEL_NAMES[index]})
|
||||||
|
</Button>
|
||||||
|
</Box>
|
||||||
))}
|
))}
|
||||||
<Box>
|
<Box>
|
||||||
<ColorBox color={tail_color} mr={1} />
|
<ColorBox color={tail_color} mr={1} />
|
||||||
@@ -85,6 +92,12 @@ export const AppearanceChangerColors = (props) => {
|
|||||||
Change Secondary Tail Color
|
Change Secondary Tail Color
|
||||||
</Button>
|
</Button>
|
||||||
</Box>
|
</Box>
|
||||||
|
<Box>
|
||||||
|
<ColorBox color={tail3_color} mr={1} />
|
||||||
|
<Button onClick={() => act('tail3_color')}>
|
||||||
|
Change Tertiary Tail Color
|
||||||
|
</Button>
|
||||||
|
</Box>
|
||||||
<Box>
|
<Box>
|
||||||
<ColorBox color={wing_color} mr={1} />
|
<ColorBox color={wing_color} mr={1} />
|
||||||
<Button onClick={() => act('wing_color')}>Change Wing Color</Button>
|
<Button onClick={() => act('wing_color')}>Change Wing Color</Button>
|
||||||
@@ -95,6 +108,12 @@ export const AppearanceChangerColors = (props) => {
|
|||||||
Change Secondary Wing Color
|
Change Secondary Wing Color
|
||||||
</Button>
|
</Button>
|
||||||
</Box>
|
</Box>
|
||||||
|
<Box>
|
||||||
|
<ColorBox color={wing3_color} mr={1} />
|
||||||
|
<Button onClick={() => act('wing3_color')}>
|
||||||
|
Change Tertiary Wing Color
|
||||||
|
</Button>
|
||||||
|
</Box>
|
||||||
</>
|
</>
|
||||||
) : null}
|
) : null}
|
||||||
{change_facial_hair_color ? (
|
{change_facial_hair_color ? (
|
||||||
|
|||||||
@@ -42,8 +42,10 @@ export type Data = {
|
|||||||
ears2_color: string;
|
ears2_color: string;
|
||||||
tail_color: string;
|
tail_color: string;
|
||||||
tail2_color: string;
|
tail2_color: string;
|
||||||
|
tail3_color: string;
|
||||||
wing_color: string;
|
wing_color: string;
|
||||||
wing2_color: string;
|
wing2_color: string;
|
||||||
|
wing3_color: string;
|
||||||
facial_hair_styles: { facialhairstyle: string }[];
|
facial_hair_styles: { facialhairstyle: string }[];
|
||||||
hair_styles: { hairstyle: string }[];
|
hair_styles: { hairstyle: string }[];
|
||||||
ear_secondary_style: string;
|
ear_secondary_style: string;
|
||||||
|
|||||||
Reference in New Issue
Block a user