Skip to content

Commit

Permalink
Fixes changeling mutation being storable on DNA console (yogstation13…
Browse files Browse the repository at this point in the history
…#20417)

* Fixes changeling mutation being storable on DNA console

* my life be like oooh aaaah
  • Loading branch information
JohnFulpWillard authored Sep 25, 2023
1 parent d4fdbc7 commit a7e1abf
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 2 deletions.
8 changes: 7 additions & 1 deletion code/datums/mutations.dm
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
/datum/mutation/human
name = "mutation"
var/desc = "A mutation."
///Whether the mutation is locked, and therefore will not show up in
///people's genes randomly.
var/locked
var/quality
var/get_chance = 100
Expand All @@ -29,7 +31,11 @@
var/scrambled = FALSE //Wheter we can read it if it's active. To avoid cheesing with mutagen
var/class //Decides player accesibility, sorta
var/list/conflicts //any mutations that might conflict. put mutation typepath defines in here. make sure to enter it both ways (so that A conflicts with B, and B with A)
var/allow_transfer //Do we transfer upon cloning?

///Boolean on whether the mutation can be transferred through cloning
var/allow_transfer = FALSE
///Boolean on whether the mutation can be downloaded onto a DNA console and cloned.
var/allow_cloning = TRUE
//MUT_NORMAL - A mutation that can be activated and deactived by completing a sequence
//MUT_EXTRA - A mutation that is in the mutations tab, and can be given and taken away through though the DNA console. Has a 0 before it's name in the mutation section of the dna console
//MUT_OTHER Cannot be interacted with by players through normal means. I.E. wizards mutate
Expand Down
1 change: 1 addition & 0 deletions code/datums/mutations/chameleon.dm
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
/datum/mutation/human/chameleon/super // Changeling chameleon
conflicts = list(/datum/mutation/human/chameleon)
allow_transfer = FALSE
allow_cloning = FALSE
mutadone_proof = TRUE
locked = TRUE
efficiency = 50
Expand Down
5 changes: 4 additions & 1 deletion code/game/machinery/computer/dna_console.dm
Original file line number Diff line number Diff line change
Expand Up @@ -665,11 +665,14 @@
// GUARD CHECK - This should not be possible. Unexpected result
if(!HM)
return
if(!HM.allow_cloning)
say("ERROR: This mutation is anomalous, and cannot be saved.")
return

var/datum/mutation/human/A = new HM.type()
A.copy_mutation(HM)
stored_mutations += A
to_chat(usr,span_notice("Mutation successfully stored."))
to_chat(usr, span_notice("Mutation successfully stored."))
return

// Save a mutation to the diskette's storage buffer.
Expand Down

0 comments on commit a7e1abf

Please sign in to comment.