Skip to content

Commit

Permalink
Felinid Removal 2023 (#403)
Browse files Browse the repository at this point in the history
* migration

* removes felinids

* remove debug code

* tail harddel (why are you new)

* Fix pooling
  • Loading branch information
Kapu1178 committed Jul 3, 2023
1 parent 74bbbde commit 58deb54
Show file tree
Hide file tree
Showing 33 changed files with 61 additions and 417 deletions.
2 changes: 0 additions & 2 deletions code/__DEFINES/dcs/signals/signals_mob/signals_mob_living.dm
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@
// Organ signals
/// Called on the organ when it is implanted into someone (mob/living/carbon/receiver)
#define COMSIG_ORGAN_IMPLANTED "comsig_organ_implanted"
/// Called when using the *wag emote
#define COMSIG_ORGAN_WAG_TAIL "comsig_wag_tail"
/// Called on the organ when it is removed from someone (mob/living/carbon/old_owner)
#define COMSIG_ORGAN_REMOVED "comsig_organ_removed"

Expand Down
1 change: 0 additions & 1 deletion code/__DEFINES/is_helpers.dm
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@ GLOBAL_LIST_INIT(turfs_without_ground, typecacheof(list(
#define iszombie(A) (is_species(A, /datum/species/zombie))
#define isskeleton(A) (is_species(A, /datum/species/skeleton))
#define ismoth(A) (is_species(A, /datum/species/moth))
#define isfelinid(A) (is_species(A, /datum/species/human/felinid))
#define isethereal(A) (is_species(A, /datum/species/ethereal))
#define isvampire(A) (is_species(A,/datum/species/vampire))
#define isdullahan(A) (is_species(A, /datum/species/dullahan))
Expand Down
1 change: 0 additions & 1 deletion code/__DEFINES/vv.dm
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,6 @@
#define VV_HK_MOD_MUTATIONS "quirkmut"
#define VV_HK_MOD_QUIRKS "quirkmod"
#define VV_HK_SET_SPECIES "setspecies"
#define VV_HK_PURRBATION "purrbation"

// misc
#define VV_HK_SPACEVINE_PURGE "spacevine_purge"
Expand Down
4 changes: 2 additions & 2 deletions code/__HELPERS/mobs.dm
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,9 @@

/proc/random_features()
if(!GLOB.tails_list.len)
init_sprite_accessory_subtypes(/datum/sprite_accessory/tails/, GLOB.tails_list, add_blank = TRUE)
init_sprite_accessory_subtypes(/datum/sprite_accessory/tails, GLOB.tails_list, add_blank = TRUE)
if(!GLOB.tails_list_human.len)
init_sprite_accessory_subtypes(/datum/sprite_accessory/tails/human, GLOB.tails_list_human, add_blank = TRUE)
init_sprite_accessory_subtypes(/datum/sprite_accessory/tails/human, GLOB.tails_list_human)
if(!GLOB.tails_list_lizard.len)
init_sprite_accessory_subtypes(/datum/sprite_accessory/tails/lizard, GLOB.tails_list_lizard, add_blank = TRUE)
if(!GLOB.snouts_list.len)
Expand Down
1 change: 0 additions & 1 deletion code/_globalvars/phobias.dm
Original file line number Diff line number Diff line change
Expand Up @@ -487,7 +487,6 @@ GLOBAL_LIST_INIT(phobia_species, list(
/datum/species/pod,
/datum/species/shadow,
)),
"anime" = typecacheof(list(/datum/species/human/felinid)),
"conspiracies" = typecacheof(list(
/datum/species/abductor,
/datum/species/lizard,
Expand Down
4 changes: 2 additions & 2 deletions code/datums/components/tackle.dm
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@
RegisterSignal(user, COMSIG_MOVABLE_MOVED, PROC_REF(checkObstacle))
playsound(user, 'sound/weapons/thudswoosh.ogg', 40, TRUE, -1)

var/leap_word = isfelinid(user) ? "pounce" : "leap" //If cat, "pounce" instead of "leap".
var/leap_word = "leap"
if(can_see(user, A, 7))
user.visible_message(span_warning("[user] [leap_word]s at [A]!"), span_danger("You [leap_word] at [A]!"))
else
Expand Down Expand Up @@ -157,7 +157,7 @@
var/mob/living/carbon/target = hit
var/mob/living/carbon/human/T = target
var/mob/living/carbon/human/S = user
var/tackle_word = isfelinid(user) ? "pounce" : "tackle" //If cat, "pounce" instead of "tackle".
var/tackle_word = "tackle" //If cat, "pounce" instead of "tackle".

var/roll = rollTackle(target)
tackling = FALSE
Expand Down
7 changes: 0 additions & 7 deletions code/datums/mood_events/generic_negative_events.dm
Original file line number Diff line number Diff line change
Expand Up @@ -91,13 +91,6 @@
mood_change = -2
timeout = 2 MINUTES

/datum/mood_event/table/add_effects()
if(isfelinid(owner)) //Holy snowflake batman!
var/mob/living/carbon/human/H = owner
SEND_SIGNAL(H, COMSIG_ORGAN_WAG_TAIL, TRUE, 3 SECONDS)
description = "They want to play on the table!"
mood_change = 2

/datum/mood_event/table_limbsmash
description = "That fucking table, man that hurts..."
mood_change = -3
Expand Down
4 changes: 0 additions & 4 deletions code/game/machinery/scan_gate.dm
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@

#define SCANGATE_HUMAN "human"
#define SCANGATE_LIZARD "lizard"
#define SCANGATE_FELINID "felinid"
#define SCANGATE_FLY "fly"
#define SCANGATE_PLASMAMAN "plasma"
#define SCANGATE_MOTH "moth"
Expand Down Expand Up @@ -146,8 +145,6 @@
scan_species = /datum/species/lizard
if(SCANGATE_FLY)
scan_species = /datum/species/fly
if(SCANGATE_FELINID)
scan_species = /datum/species/human/felinid
if(SCANGATE_PLASMAMAN)
scan_species = /datum/species/plasmaman
if(SCANGATE_MOTH)
Expand Down Expand Up @@ -278,7 +275,6 @@

#undef SCANGATE_HUMAN
#undef SCANGATE_LIZARD
#undef SCANGATE_FELINID
#undef SCANGATE_FLY
#undef SCANGATE_PLASMAMAN
#undef SCANGATE_MOTH
Expand Down
15 changes: 0 additions & 15 deletions code/game/objects/items/devices/laserpointer.dm
Original file line number Diff line number Diff line change
Expand Up @@ -135,21 +135,6 @@
else
outmsg = span_warning("You miss the lens of [C] with [src]!")

//catpeople
for(var/mob/living/carbon/human/H in view(1,targloc))
if(!isfelinid(H) || H.incapacitated() || H.is_blind())
continue
if(user.body_position == STANDING_UP)
H.setDir(get_dir(H,targloc)) // kitty always looks at the light
if(prob(effectchance * diode.rating))
H.visible_message(span_warning("[H] makes a grab for the light!"),span_userdanger("LIGHT!"))
H.Move(targloc)
log_combat(user, H, "moved with a laser pointer",src)
else
H.visible_message(span_notice("[H] looks briefly distracted by the light."), span_warning("You're briefly tempted by the shiny light..."))
else
H.visible_message(span_notice("[H] stares at the light."), span_warning("You stare at the light..."))

//cats!
for(var/mob/living/simple_animal/pet/cat/C in view(1,targloc))
if(prob(effectchance * diode.rating))
Expand Down
3 changes: 0 additions & 3 deletions code/game/objects/items/hand_items.dm
Original file line number Diff line number Diff line change
Expand Up @@ -210,9 +210,6 @@
/obj/item/hand_item/slapper/attack(mob/living/slapped, mob/living/carbon/human/user)
SEND_SIGNAL(user, COMSIG_LIVING_SLAP_MOB, slapped)

if(ishuman(slapped))
var/mob/living/carbon/human/human_slapped = slapped
SEND_SIGNAL(human_slapped, COMSIG_ORGAN_WAG_TAIL, FALSE)
user.do_attack_animation(slapped)

var/slap_volume = 50
Expand Down
1 change: 0 additions & 1 deletion code/game/objects/items/implants/implantchair.dm
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,6 @@
if(!istype(H))
return FALSE
H.set_species(/datum/species/human, 1)//lizards go home
purrbation_remove(H)//remove cats
H.dna.remove_all_mutations()//hulks out
return TRUE

Expand Down
9 changes: 4 additions & 5 deletions code/game/objects/items/pet_carrier.dm
Original file line number Diff line number Diff line change
Expand Up @@ -88,19 +88,18 @@
if(!open)
to_chat(user, span_warning("You need to open [src]'s door!"))
return

if(target.mob_size > max_occupant_weight)
if(ishuman(target))
var/mob/living/carbon/human/H = target
if(isfelinid(H))
to_chat(user, span_warning("You'd need a lot of catnip and treats, plus maybe a laser pointer, for that to work."))
else
to_chat(user, span_warning("Humans, generally, do not fit into pet carriers."))
to_chat(user, span_warning("Humans, generally, do not fit into pet carriers."))
else
to_chat(user, span_warning("You get the feeling [target] isn't meant for a [name]."))
return

if(user == target)
to_chat(user, span_warning("Why would you ever do that?"))
return

load_occupant(user, target)

/obj/item/pet_carrier/relaymove(mob/living/user, direction)
Expand Down
14 changes: 0 additions & 14 deletions code/modules/admin/verbs/secrets.dm
Original file line number Diff line number Diff line change
Expand Up @@ -533,20 +533,6 @@ GLOBAL_DATUM(everyone_a_traitor, /datum/everyone_is_a_traitor_controller)
ADD_TRAIT(I, TRAIT_NODROP, ADMIN_TRAIT)
else
to_chat(H, span_warning("You're not kawaii enough for this!"), confidential = TRUE)
if("masspurrbation")
if(!is_funmin)
return
mass_purrbation()
message_admins("[key_name_admin(holder)] has put everyone on \
purrbation!")
log_admin("[key_name(holder)] has put everyone on purrbation.")
if("massremovepurrbation")
if(!is_funmin)
return
mass_remove_purrbation()
message_admins("[key_name_admin(holder)] has removed everyone from \
purrbation.")
log_admin("[key_name(holder)] has removed everyone from purrbation.")
if("massimmerse")
if(!is_funmin)
return
Expand Down
2 changes: 2 additions & 0 deletions code/modules/client/preferences/_preference.dm
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,8 @@ GLOBAL_LIST_INIT(all_pref_groups, init_all_pref_groups())
/// Returns TRUE for a successful preference application.
/// Returns FALSE if it is invalid.
/datum/preferences/proc/write_preference(datum/preference/preference, preference_value)
if(ispath(preference))
preference = GLOB.preference_entries[preference]
var/savefile = get_savefile_for_savefile_identifier(preference.savefile_identifier)
var/new_value = preference.deserialize(preference_value, src)
var/success = preference.write(savefile, new_value)
Expand Down
4 changes: 4 additions & 0 deletions code/modules/client/preferences/augments/augments.dm
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,14 @@
for(var/slot in value - AUGMENT_SLOT_IMPLANTS)
var/path = value[slot]
var/datum/augment_item/A = GLOB.augment_items[path]
if(!A.can_apply_to_species(S.type))
continue
A.apply_to_human(target, S)

for(var/datum/augment_item/A as anything in value[AUGMENT_SLOT_IMPLANTS])
A = GLOB.augment_items[A]
if(!A.can_apply_to_species(S))
continue
A.apply_to_human(target, S, value[AUGMENT_SLOT_IMPLANTS][A.type])

/datum/preference/blob/augments/create_default_value()
Expand Down
9 changes: 9 additions & 0 deletions code/modules/client/preferences/augments/implants/implant.dm
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,12 @@
/datum/augment_item/implant/cat_ears/get_choices()
return GLOB.ears_list

/datum/augment_item/implant/cat_tail
name = "Feline Tail"
path = /obj/item/organ/tail/cat
allowed_species = list(
SPECIES_HUMAN
)

/datum/augment_item/implant/cat_tail/get_choices()
return GLOB.tails_list_human
10 changes: 0 additions & 10 deletions code/modules/client/preferences/migrations/body_type_migration.dm

This file was deleted.

26 changes: 0 additions & 26 deletions code/modules/client/preferences/migrations/tgui_prefs_migration.dm

This file was deleted.

88 changes: 25 additions & 63 deletions code/modules/client/preferences_savefile.dm
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
//This is the lowest supported version, anything below this is completely obsolete and the entire savefile will be wiped.
#define SAVEFILE_VERSION_MIN 32
#define SAVEFILE_VERSION_MIN 42

//This is the current version, anything below this will attempt to update (if it's not obsolete)
// You do not need to raise this if you are adding new values that have sane defaults.
// Only raise this value when changing the meaning/format/name/layout of an existing value
// where you would want the updater procs below to run
#define SAVEFILE_VERSION_MAX 42
#define SAVEFILE_VERSION_MAX 43

/*
SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Carn
Expand Down Expand Up @@ -42,63 +42,28 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
//if your savefile is 3 months out of date, then 'tough shit'.

/datum/preferences/proc/update_preferences(current_version, savefile/S)
if(current_version < 33)
toggles |= SOUND_ENDOFROUND

if(current_version < 34)
write_preference(/datum/preference/toggle/auto_fit_viewport, TRUE)

if(current_version < 35) //makes old keybinds compatible with #52040, sets the new default
var/newkey = FALSE
for(var/list/key in key_bindings)
for(var/bind in key)
if(bind == "quick_equipbelt")
key -= "quick_equipbelt"
key |= "quick_equip_belt"

if(bind == "bag_equip")
key -= "bag_equip"
key |= "quick_equip_bag"

if(bind == "quick_equip_suit_storage")
newkey = TRUE
if(!newkey && !key_bindings["ShiftQ"])
key_bindings["ShiftQ"] = list("quick_equip_suit_storage")

if(current_version < 36)
if(key_bindings["ShiftQ"] == "quick_equip_suit_storage")
key_bindings["ShiftQ"] = list("quick_equip_suit_storage")

if(current_version < 37)
if(read_preference(/datum/preference/numeric/fps) == 0)
write_preference(GLOB.preference_entries[/datum/preference/numeric/fps], -1)

if (current_version < 38)
var/found_block_movement = FALSE

for (var/list/key in key_bindings)
for (var/bind in key)
if (bind == "block_movement")
found_block_movement = TRUE
break
if (found_block_movement)
break

if (!found_block_movement)
LAZYADD(key_bindings["Ctrl"], "block_movement")

if (current_version < 39)
LAZYADD(key_bindings["F"], "toggle_combat_mode")
LAZYADD(key_bindings["4"], "toggle_combat_mode")
if (current_version < 40)
LAZYADD(key_bindings["Space"], "hold_throw_mode")

if (current_version < 41)
migrate_preferences_to_tgui_prefs_menu()
return

/datum/preferences/proc/update_character(current_version, savefile/savefile)
if (current_version < 42)
migrate_body_types(savefile)
return

/// Called when reading preferences if a savefile update is detected. This proc is for
/// overriding preference datum values before they are sanitized by deserialize()
/datum/preferences/proc/early_update_character(current_version, savefile/savefile)
if(current_version < 43)
var/species
READ_FILE(savefile["species"], species)
if(species == "felinid")
write_preference(/datum/preference/choiced/species, SPECIES_HUMAN)

var/list/augs = read_preference(/datum/preference/blob/augments)
var/datum/augment_item/implant/ears = GLOB.augment_items[/datum/augment_item/implant/cat_ears]
var/datum/augment_item/implant/tail = GLOB.augment_items[/datum/augment_item/implant/cat_tail]
augs[AUGMENT_SLOT_IMPLANTS] = list(
ears.type = ears.get_choices()[1],
tail.type = tail.get_choices()[1]
)
write_preference(/datum/preference/blob/augments, augs)

/// checks through keybindings for outdated unbound keys and updates them
/datum/preferences/proc/check_keybindings()
Expand Down Expand Up @@ -288,6 +253,9 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
if(needs_update == -2) //fatal, can't load any data
return FALSE

if(needs_update >= 0)
early_update_character(needs_update, S)

// Read everything into cache
for (var/preference_type in GLOB.preference_entries)
var/datum/preference/preference = GLOB.preference_entries[preference_type]
Expand Down Expand Up @@ -337,12 +305,6 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car

WRITE_FILE(S["version"] , SAVEFILE_VERSION_MAX) //load_character will sanitize any bad data, so assume up-to-date.)

// This is the version when the random security department was removed.
// When the minimum is higher than that version, it's impossible for someone to have the "Random" department.
#if SAVEFILE_VERSION_MIN > 40
#warn The prefered_security_department check in code/modules/client/preferences/security_department.dm is no longer necessary.
#endif

//Write prefs
WRITE_FILE(S["alt_job_titles"], alt_job_titles)

Expand Down
Loading

0 comments on commit 58deb54

Please sign in to comment.