|
|
|
@@ -274,13 +274,18 @@
|
|
|
|
|
var/max_line_len = 7*DNA_BLOCK_SIZE
|
|
|
|
|
if(viable_occupant)
|
|
|
|
|
temp_html += "<div class='dnaBlockNumber'>1</div>"
|
|
|
|
|
var/len = length(viable_occupant.dna.uni_identity)
|
|
|
|
|
for(var/i=1, i<=len, i++)
|
|
|
|
|
temp_html += "<a class='dnaBlock' href='?src=[REF(src)];task=pulseui;num=[i];'>[copytext(viable_occupant.dna.uni_identity,i,i+1)]</a>"
|
|
|
|
|
if ((i % max_line_len) == 0)
|
|
|
|
|
var/char = ""
|
|
|
|
|
var/ui_text = viable_occupant.dna.uni_identity
|
|
|
|
|
var/len_byte = length(ui_text)
|
|
|
|
|
var/char_it = 0
|
|
|
|
|
for(var/byte_it = 1, byte_it <= len_byte, byte_it += length(char))
|
|
|
|
|
char_it++
|
|
|
|
|
char = ui_text[byte_it]
|
|
|
|
|
temp_html += "<a class='dnaBlock' href='?src=[REF(src)];task=pulseui;num=[char_it];'>[char]</a>"
|
|
|
|
|
if((char_it % max_line_len) == 0)
|
|
|
|
|
temp_html += "</div><div class='clearBoth'>"
|
|
|
|
|
if((i % DNA_BLOCK_SIZE) == 0 && i < len)
|
|
|
|
|
temp_html += "<div class='dnaBlockNumber'>[(i / DNA_BLOCK_SIZE) + 1]</div>"
|
|
|
|
|
if((char_it % DNA_BLOCK_SIZE) == 0 && byte_it < len_byte)
|
|
|
|
|
temp_html += "<div class='dnaBlockNumber'>[(char_it / DNA_BLOCK_SIZE) + 1]</div>"
|
|
|
|
|
else
|
|
|
|
|
temp_html += "----"
|
|
|
|
|
temp_html += "</div></div></div><br>"
|
|
|
|
@@ -288,13 +293,16 @@
|
|
|
|
|
temp_html += "<br><div class='line'><div class='statusLabel'>Structural Enzymes:</div><div class='statusValue'><div class='clearBoth'>"
|
|
|
|
|
if(viable_occupant)
|
|
|
|
|
temp_html += "<div class='dnaBlockNumber'>1</div>"
|
|
|
|
|
var/len = length(viable_occupant.dna.struc_enzymes)
|
|
|
|
|
for(var/i=1, i<=len, i++)
|
|
|
|
|
temp_html += "<a class='dnaBlock' href='?src=[REF(src)];task=pulsese;num=[i];'>[copytext(viable_occupant.dna.struc_enzymes,i,i+1)]</a>"
|
|
|
|
|
if ((i % max_line_len) == 0)
|
|
|
|
|
var/char = ""
|
|
|
|
|
var/ui_text = viable_occupant.dna.uni_identity
|
|
|
|
|
var/len_byte = length(ui_text)
|
|
|
|
|
var/char_it = 0
|
|
|
|
|
for(var/byte_it = 1, byte_it <= len_byte, byte_it += length(char))
|
|
|
|
|
temp_html += "<a class='dnaBlock' href='?src=[REF(src)];task=pulsese;num=[char_it];'>[char]</a>"
|
|
|
|
|
if((char_it % max_line_len) == 0)
|
|
|
|
|
temp_html += "</div><div class='clearBoth'>"
|
|
|
|
|
if((i % DNA_BLOCK_SIZE) == 0 && i < len)
|
|
|
|
|
temp_html += "<div class='dnaBlockNumber'>[(i / DNA_BLOCK_SIZE) + 1]</div>"
|
|
|
|
|
if((char_it % DNA_BLOCK_SIZE) == 0 && byte_it < len_byte)
|
|
|
|
|
temp_html += "<div class='dnaBlockNumber'>[(char_it / DNA_BLOCK_SIZE) + 1]</div>"
|
|
|
|
|
else
|
|
|
|
|
temp_html += "----"
|
|
|
|
|
temp_html += "</div></div></div>"
|
|
|
|
@@ -465,7 +473,7 @@
|
|
|
|
|
viable_occupant.radiation += (RADIATION_IRRADIATION_MULTIPLIER*radduration*radstrength)/(connected.damage_coeff ** 2) //Read comment in "transferbuffer" section above for explanation
|
|
|
|
|
switch(href_list["task"]) //Same thing as there but values are even lower, on best part they are about 0.0*, effectively no damage
|
|
|
|
|
if("pulseui")
|
|
|
|
|
var/len = length(viable_occupant.dna.uni_identity)
|
|
|
|
|
var/len = length_char(viable_occupant.dna.uni_identity)
|
|
|
|
|
num = WRAP(num, 1, len+1)
|
|
|
|
|
num = randomize_radiation_accuracy(num, radduration + (connected.precision_coeff ** 2), len) //Each manipulator level above 1 makes randomization as accurate as selected time + manipulator lvl^2
|
|
|
|
|
//Value is this high for the same reason as with laser - not worth the hassle of upgrading if the bonus is low
|
|
|
|
@@ -473,12 +481,12 @@
|
|
|
|
|
var/subblock = num - block*DNA_BLOCK_SIZE
|
|
|
|
|
last_change = "UI #[block]-[subblock]; "
|
|
|
|
|
|
|
|
|
|
var/hex = copytext(viable_occupant.dna.uni_identity, num, num+1)
|
|
|
|
|
var/hex = copytext_char(viable_occupant.dna.uni_identity, num, num+1)
|
|
|
|
|
last_change += "[hex]"
|
|
|
|
|
hex = scramble(hex, radstrength, radduration)
|
|
|
|
|
last_change += "->[hex]"
|
|
|
|
|
|
|
|
|
|
viable_occupant.dna.uni_identity = copytext(viable_occupant.dna.uni_identity, 1, num) + hex + copytext(viable_occupant.dna.uni_identity, num+1, 0)
|
|
|
|
|
viable_occupant.dna.uni_identity = copytext_char(viable_occupant.dna.uni_identity, 1, num) + hex + copytext_char(viable_occupant.dna.uni_identity, num + 1)
|
|
|
|
|
viable_occupant.updateappearance(mutations_overlay_update=1)
|
|
|
|
|
if("pulsese")
|
|
|
|
|
var/len = length(viable_occupant.dna.struc_enzymes)
|
|
|
|
@@ -489,12 +497,12 @@
|
|
|
|
|
var/subblock = num - block*DNA_BLOCK_SIZE
|
|
|
|
|
last_change = "SE #[block]-[subblock]; "
|
|
|
|
|
|
|
|
|
|
var/hex = copytext(viable_occupant.dna.struc_enzymes, num, num+1)
|
|
|
|
|
var/hex = copytext_char(viable_occupant.dna.struc_enzymes, num, num+1)
|
|
|
|
|
last_change += "[hex]"
|
|
|
|
|
hex = scramble(hex, radstrength, radduration)
|
|
|
|
|
last_change += "->[hex]"
|
|
|
|
|
|
|
|
|
|
viable_occupant.dna.struc_enzymes = copytext(viable_occupant.dna.struc_enzymes, 1, num) + hex + copytext(viable_occupant.dna.struc_enzymes, num+1, 0)
|
|
|
|
|
viable_occupant.dna.struc_enzymes = copytext_char(viable_occupant.dna.struc_enzymes, 1, num) + hex + copytext_char(viable_occupant.dna.struc_enzymes, num + 1)
|
|
|
|
|
viable_occupant.domutcheck()
|
|
|
|
|
else
|
|
|
|
|
current_screen = "mainmenu"
|
|
|
|
|