This commit is contained in:
SandPoot
2022-07-23 18:42:24 -03:00
40 changed files with 669 additions and 374 deletions
+2 -2
View File
@@ -660,7 +660,7 @@
"goat" = 'icons/mob/animal.dmi',
"cat" = 'icons/mob/pets.dmi',
"cat2" = 'icons/mob/pets.dmi',
"poly" = 'icons/mob/animal.dmi',
"polly" = 'icons/mob/animal.dmi',
"pug" = 'icons/mob/pets.dmi',
"spider" = 'icons/mob/animal.dmi'
)
@@ -669,7 +669,7 @@
if(input)
qdel(holo_icon)
switch(input)
if("poly")
if("polly")
holo_icon = getHologramIcon(icon(icon_list[input],"parrot_fly"))
if("chicken")
holo_icon = getHologramIcon(icon(icon_list[input],"chicken_brown"))
@@ -19,6 +19,7 @@
path_image_color = "#993299"
weather_immunities = list("lava","ash")
var/base_icon = "cleanbot"
var/clean_time = 50 //How long do we take to clean?
var/upgrades = 0
@@ -126,13 +127,21 @@
/mob/living/simple_animal/bot/cleanbot/turn_on()
..()
icon_state = "cleanbot[on]"
bot_core.updateUsrDialog()
update_icon()
/mob/living/simple_animal/bot/cleanbot/turn_off()
..()
icon_state = "cleanbot[on]"
bot_core.updateUsrDialog()
update_icon()
/mob/living/simple_animal/bot/cleanbot/update_icon_state()
. = ..()
switch(mode)
if(BOT_CLEANING)
icon_state = "[base_icon]-c"
else
icon_state = "[base_icon][on]"
/mob/living/simple_animal/bot/cleanbot/bot_reset()
..()
+20 -20
View File
@@ -84,7 +84,7 @@
var/speech_shuffle_rate = 20
var/list/available_channels = list()
//Headset for Poly to yell at engineers :)
//Headset for Polly to yell at engineers :)
var/obj/item/radio/headset/ears = null
/// spawns with headset
var/spawns_with_headset = FALSE
@@ -349,7 +349,7 @@ GLOBAL_LIST_INIT(strippable_parrot_items, create_strippable_list(list(
parrot_state |= PARROT_FLEE
icon_state = icon_living
drop_held_item(0)
else if(istype(O, /obj/item/reagent_containers/food/snacks/cracker)) //Poly wants a cracker.
else if(istype(O, /obj/item/reagent_containers/food/snacks/cracker)) //Polly wants a cracker.
qdel(O)
if(health < maxHealth)
adjustBruteLoss(-10)
@@ -894,10 +894,10 @@ GLOBAL_LIST_INIT(strippable_parrot_items, create_strippable_list(list(
/*
* Sub-types
*/
/mob/living/simple_animal/parrot/Poly
name = "Poly"
desc = "Poly the Parrot. An expert on quantum cracker theory."
speak = list("Poly wanna cracker!", ":e Check the crystal, you chucklefucks!",":e Wire the solars, you lazy bums!",":e WHO TOOK THE DAMN HARDSUITS?",":e OH GOD ITS ABOUT TO DELAMINATE CALL THE SHUTTLE")
/mob/living/simple_animal/parrot/Polly
name = "Polly"
desc = "Polly the Parrot. An expert on quantum cracker theory."
speak = list("Polly wanna cracker!", ":e Check the crystal, you chucklefucks!",":e Wire the solars, you lazy bums!",":e WHO TOOK THE DAMN HARDSUITS?",":e OH GOD ITS ABOUT TO DELAMINATE CALL THE SHUTTLE")
gold_core_spawnable = NO_SPAWN
speak_chance = 3
spawns_with_headset = TRUE
@@ -906,7 +906,7 @@ GLOBAL_LIST_INIT(strippable_parrot_items, create_strippable_list(list(
var/longest_survival = 0
var/longest_deathstreak = 0
/mob/living/simple_animal/parrot/Poly/Initialize(mapload)
/mob/living/simple_animal/parrot/Polly/Initialize(mapload)
ears = new /obj/item/radio/headset/headset_eng(src)
available_channels = list(":e")
Read_Memory()
@@ -929,30 +929,30 @@ GLOBAL_LIST_INIT(strippable_parrot_items, create_strippable_list(list(
. = ..()
/mob/living/simple_animal/parrot/Poly/say(message, bubble_type,var/list/spans = list(), sanitize = TRUE, datum/language/language = null, ignore_spam = FALSE, forced = null)
/mob/living/simple_animal/parrot/Polly/say(message, bubble_type,var/list/spans = list(), sanitize = TRUE, datum/language/language = null, ignore_spam = FALSE, forced = null)
. = ..()
if(. && !client && prob(1) && prob(1) && CONFIG_GET(string/chat_squawk_tag)) //Only the one true bird may speak across dimensions.
send2chat("A stray squawk is heard... \"[message]\"", CONFIG_GET(string/chat_squawk_tag))
/mob/living/simple_animal/parrot/Poly/BiologicalLife(delta_time, times_fired)
/mob/living/simple_animal/parrot/Polly/BiologicalLife(delta_time, times_fired)
if(!(. = ..()))
return
if(!stat && SSticker.current_state == GAME_STATE_FINISHED && !memory_saved)
Write_Memory(FALSE)
memory_saved = TRUE
/mob/living/simple_animal/parrot/Poly/death(gibbed)
/mob/living/simple_animal/parrot/Polly/death(gibbed)
if(!memory_saved)
Write_Memory(TRUE)
if(rounds_survived == longest_survival || rounds_survived == longest_deathstreak || prob(0.666))
var/mob/living/simple_animal/parrot/Poly/ghost/G = new(loc)
var/mob/living/simple_animal/parrot/Polly/ghost/G = new(loc)
if(mind)
mind.transfer_to(G)
else
transfer_ckey(G)
..(gibbed)
/mob/living/simple_animal/parrot/Poly/proc/Read_Memory()
/mob/living/simple_animal/parrot/Polly/proc/Read_Memory()
var/saved_color
if(fexists("data/npc_saves/Poly.sav")) //legacy compatability to convert old format to new
var/savefile/S = new /savefile("data/npc_saves/Poly.sav")
@@ -976,7 +976,7 @@ GLOBAL_LIST_INIT(strippable_parrot_items, create_strippable_list(list(
if(!isnull(saved_color))
add_atom_colour(json_decode(saved_color), FIXED_COLOUR_PRIORITY)
/mob/living/simple_animal/parrot/Poly/proc/Write_Memory(dead)
/mob/living/simple_animal/parrot/Polly/proc/Write_Memory(dead)
var/json_file = file("data/npc_saves/Poly.json")
var/list/file_data = list()
if(islist(speech_buffer))
@@ -1003,14 +1003,14 @@ GLOBAL_LIST_INIT(strippable_parrot_items, create_strippable_list(list(
fdel(json_file)
WRITE_FILE(json_file, json_encode(file_data))
/mob/living/simple_animal/parrot/Poly/ratvar_act()
/mob/living/simple_animal/parrot/Polly/ratvar_act()
playsound(src, 'sound/magic/clockwork/fellowship_armory.ogg', 75, TRUE)
var/mob/living/simple_animal/parrot/clock_hawk/H = new(loc)
H.setDir(dir)
qdel(src)
/mob/living/simple_animal/parrot/Poly/ghost
name = "The Ghost of Poly"
/mob/living/simple_animal/parrot/Polly/ghost
name = "The Ghost of Polly"
desc = "Doomed to squawk the Earth."
color = "#FFFFFF"
alpha = 77
@@ -1019,16 +1019,16 @@ GLOBAL_LIST_INIT(strippable_parrot_items, create_strippable_list(list(
incorporeal_move = INCORPOREAL_MOVE_BASIC
butcher_results = list(/obj/item/ectoplasm = 1)
/mob/living/simple_animal/parrot/Poly/ghost/Initialize(mapload)
/mob/living/simple_animal/parrot/Polly/ghost/Initialize(mapload)
memory_saved = TRUE //At this point nothing is saved
. = ..()
/mob/living/simple_animal/parrot/Poly/ghost/handle_automated_speech()
/mob/living/simple_animal/parrot/Polly/ghost/handle_automated_speech()
if(ismob(loc))
return
..()
/mob/living/simple_animal/parrot/Poly/ghost/handle_automated_movement()
/mob/living/simple_animal/parrot/Polly/ghost/handle_automated_movement()
if(isliving(parrot_interest))
if(!ishuman(parrot_interest))
parrot_interest = null
@@ -1037,7 +1037,7 @@ GLOBAL_LIST_INIT(strippable_parrot_items, create_strippable_list(list(
Possess(parrot_interest)
..()
/mob/living/simple_animal/parrot/Poly/ghost/proc/Possess(mob/living/carbon/human/H)
/mob/living/simple_animal/parrot/Polly/ghost/proc/Possess(mob/living/carbon/human/H)
if(!ishuman(H))
return
var/datum/disease/parrot_possession/P = new
@@ -225,7 +225,7 @@
length += emote_see.len
var/randomValue = rand(1,length)
if(randomValue <= speak.len)
say(pick(speak), forced = "poly")
say(pick(speak), forced = "polly")
else
randomValue -= speak.len
if(emote_see && randomValue <= emote_see.len)
@@ -233,7 +233,7 @@
else
emote("me [pick(emote_hear)]", 2)
else
say(pick(speak), forced = "poly")
say(pick(speak), forced = "polly")
else
if(!(emote_hear && emote_hear.len) && (emote_see && emote_see.len))
emote("me", EMOTE_VISIBLE, pick(emote_see))