From ecd057f10df41a5e50ce615ee82720b0111fa8ce Mon Sep 17 00:00:00 2001 From: "quartz235@gmail.com" Date: Mon, 2 Jul 2012 11:09:02 +0000 Subject: [PATCH] Fixes Issue 502 - Absorbing someone with the same real_name as a prior victim now properly adds to your genome count for end-round report - Done via new changeling datum var (ugh) called absorbcount that is just a number that increases on any successful absorb (also increases properly in the event of absorbing another changeling,) couldn't see a better way about this without overhauling the entire changeling datum layout, objective checks, etc. Removed direct narrate (not global) rank check, since everyone gets subtlemessage and the like it didn't make sense to restrict this Readded timestamps on fingerprints_hidden which I guess were removed during a revert? git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3968 316c924e-a436-60f5-8080-3fe189b3f50e --- code/game/atom_procs.dm | 6 +++--- code/game/gamemodes/changeling/changeling.dm | 5 ++--- code/game/gamemodes/changeling/changeling_powers.dm | 3 +++ code/game/gamemodes/objective.dm | 2 +- code/modules/admin/admin.dm | 8 ++------ 5 files changed, 11 insertions(+), 13 deletions(-) diff --git a/code/game/atom_procs.dm b/code/game/atom_procs.dm index d056b7d8fae..58eebf67064 100644 --- a/code/game/atom_procs.dm +++ b/code/game/atom_procs.dm @@ -114,7 +114,7 @@ //Now, deal with gloves. if (H.gloves && H.gloves != src) if(fingerprintslast != H.key) - fingerprintshidden += text("(Wearing gloves). Real name: [], Key: []",H.real_name, H.key) + fingerprintshidden += text("\[[]\](Wearing gloves). Real name: [], Key: []",time_stamp(), H.real_name, H.key) fingerprintslast = H.key H.gloves.add_fingerprint(M) //Deal with gloves the pass finger/palm prints. @@ -125,7 +125,7 @@ return 0 //More adminstuffz if(fingerprintslast != H.key) - fingerprintshidden += text("Real name: [], Key: []",H.real_name, H.key) + fingerprintshidden += text("\[[]\]Real name: [], Key: []",time_stamp(), H.real_name, H.key) fingerprintslast = H.key //Make the list if it does not exist. if(!fingerprints) @@ -158,7 +158,7 @@ else fingerprints[P] = test_print if(fingerprintslast != M.key) - fingerprintshidden += text("Real name: [], Key: []",M.real_name, M.key) + fingerprintshidden += text("\[[]\]Real name: [], Key: []",time_stamp(), M.real_name, M.key) fingerprintslast = M.key //Cleaning up shit. if(fingerprints && !fingerprints.len) diff --git a/code/game/gamemodes/changeling/changeling.dm b/code/game/gamemodes/changeling/changeling.dm index 0f9f45482df..26b47c38f44 100644 --- a/code/game/gamemodes/changeling/changeling.dm +++ b/code/game/gamemodes/changeling/changeling.dm @@ -159,13 +159,11 @@ for(var/datum/mind/changeling in changelings) var/changelingwin = 1 var/changeling_name - var/totalabsorbed = 0 if((changeling.current) && (changeling.current.changeling)) - totalabsorbed = ((changeling.current.changeling.absorbed_dna.len) - 1) changeling_name = "[changeling.current.real_name] (played by [changeling.key])" world << "The changeling was [changeling_name]." world << "[changeling.current.gender=="male"?"His":"Her"] changeling ID was [changeling.current.gender=="male"?"Mr.":"Mrs."] [changeling.current.changeling.changelingID]." - world << "Genomes absorbed: [totalabsorbed]" + world << "Genomes absorbed: [changeling.current.changeling.absorbedcount]" var/count = 1 for(var/datum/objective/objective in changeling.objectives) @@ -204,6 +202,7 @@ var/isabsorbing = 0 var/geneticpoints = 5 var/purchasedpowers = list() + var/absorbedcount = 0 diff --git a/code/game/gamemodes/changeling/changeling_powers.dm b/code/game/gamemodes/changeling/changeling_powers.dm index c614290a2ba..f2168e8a3b3 100644 --- a/code/game/gamemodes/changeling/changeling_powers.dm +++ b/code/game/gamemodes/changeling/changeling_powers.dm @@ -156,6 +156,7 @@ if(T.changeling) if(T.changeling.absorbed_dna) usr.changeling.absorbed_dna |= T.changeling.absorbed_dna //steal all their loot + usr.changeling.absorbedcount += T.changeling.absorbedcount T.changeling.absorbed_dna = list() T.changeling.absorbed_dna[T.real_name] = T.dna @@ -179,9 +180,11 @@ + usr.changeling.chem_charges += T.changeling.chem_charges usr.changeling.geneticpoints += T.changeling.geneticpoints T.changeling.chem_charges = 0 + usr.changeling.absorbedcount++ usr.changeling.isabsorbing = 0 T.death(0) diff --git a/code/game/gamemodes/objective.dm b/code/game/gamemodes/objective.dm index a9cbcab9092..16011a9b5cc 100644 --- a/code/game/gamemodes/objective.dm +++ b/code/game/gamemodes/objective.dm @@ -484,7 +484,7 @@ datum/objective/absorb return target_amount check_completion() - if(owner && owner.current && owner.current.changeling && owner.current.changeling.absorbed_dna && ((owner.current.changeling.absorbed_dna.len - 1) >= target_amount)) + if(owner && owner.current && owner.current.changeling && owner.current.changeling.absorbed_dna && ((owner.current.changeling.absorbedcount) >= target_amount)) return 1 else return 0 diff --git a/code/modules/admin/admin.dm b/code/modules/admin/admin.dm index 5071362c094..969f9b96c3b 100644 --- a/code/modules/admin/admin.dm +++ b/code/modules/admin/admin.dm @@ -1313,12 +1313,8 @@ var/global/BSACooldown = 0 return if (href_list["narrateto"]) - if(rank in list("Game Admin", "Game Master")) - var/mob/M = locate(href_list["narrateto"]) - usr.client.cmd_admin_direct_narrate(M) - else - alert("You cannot perform this action. You must be of a higher administrative rank!") - return + var/mob/M = locate(href_list["narrateto"]) + usr.client.cmd_admin_direct_narrate(M) if (href_list["subtlemessage"]) var/mob/M = locate(href_list["subtlemessage"])