Updates to fingerprints/bugfixes.

This commit is contained in:
SkyMarshal
2012-02-02 12:22:46 -07:00
parent 16ac8ba8e0
commit 3b9efc849e
2 changed files with 35 additions and 33 deletions
+17 -23
View File
@@ -93,7 +93,7 @@
src.fingerprintshidden += text("(Wearing gloves). Real name: [], Key: []",H.real_name, H.key)
src.fingerprintslast = H.key
return 0
else
if (H.dna.uni_identity || (H.gloves && prob(25) && istype(H.gloves, /obj/item/clothing/gloves/latex)))
if(src.fingerprintslast != H.key)
src.fingerprintshidden += text("Real name: [], Key: []",H.real_name, H.key)
src.fingerprintslast = H.key
@@ -101,31 +101,25 @@
var/prints
for(var/i = 1, i < (src.fingerprints.len + 1), i++)
var/list/L = params2list(src.fingerprints[i])
if(L.len > 1)
if(L[num2text(1)] == md5(H.dna.uni_identity))
new_prints = i
prints = L[num2text(2)]
break
else
var/test_print = stars(L[num2text(2)], rand(80,90))
if(stringpercent(test_print) == 32)
if(src.fingerprints.len == 1)
src.fingerprints = list()
else
for(var/j = (i + 1), j < (src.fingerprints.len), j++)
src.fingerprints[j-1] = src.fingerprints[j]
src.fingerprints.len--
else
src.fingerprints[i] = "1=" + L[num2text(1)] + "&2=" + test_print
if(L[num2text(1)] == md5(H.dna.uni_identity))
new_prints = i
prints = L[num2text(2)]
break
else
var/turf/T = get_turf(src)
for (var/mob/N in world)
if (N.client && N.client.holder)
N << "<span class=\"gfartadmin\"><span class=\"prefix\">ERROR:</span><span class=\"message\">Fingerprint application failed! Important data: [src.name] at [T.x], [T.y], [T.z] with the print string [L[1]]</span></span>"
var/test_print = stars(L[num2text(2)], rand(80,90))
if(stringpercent(test_print) == 32)
if(src.fingerprints.len == 1)
src.fingerprints = list()
else
for(var/j = (i + 1), j < (src.fingerprints.len), j++)
src.fingerprints[j-1] = src.fingerprints[j]
src.fingerprints.len--
else
src.fingerprints[i] = "1=" + L[num2text(1)] + "&2=" + test_print
if(new_prints)
src.fingerprints[new_prints] = text("1=[]&2=[]", md5(H.dna.uni_identity), stringmerge(prints,stars(md5(H.dna.uni_identity), rand(15,30))))
src.fingerprints[new_prints] = text("1=[]&2=[]", md5(H.dna.uni_identity), stringmerge(prints,stars(md5(H.dna.uni_identity), H.gloves ? rand(10,20) : rand(25,40))))
else if(new_prints == 0)
src.fingerprints += text("1=[]&2=[]", md5(H.dna.uni_identity), stars(md5(H.dna.uni_identity), rand(15,30)))
src.fingerprints += text("1=[]&2=[]", md5(H.dna.uni_identity), stars(md5(H.dna.uni_identity), H.gloves ? rand(10,20) : rand(25,40)))
return 1
else
if(src.fingerprintslast != M.key)