"
if(viable_occupant)
temp_html += "
1
"
- var/len = length(viable_occupant.dna.struc_enzymes)
- for(var/i=1, i<=len, i++)
- temp_html += "
[copytext(viable_occupant.dna.struc_enzymes,i,i+1)]"
- if ((i % max_line_len) == 0)
+ var/char = ""
+ var/se_text = viable_occupant.dna.struc_enzymes
+ var/len_byte = length(se_text)
+ var/char_it = 0
+ for(var/byte_it = 1, byte_it <= len_byte, byte_it += length(char))
+ char_it++
+ char = se_text[byte_it]
+ temp_html += "
[char]"
+ if((char_it % max_line_len) == 0)
temp_html += "
"
- if((i % DNA_BLOCK_SIZE) == 0 && i < len)
- temp_html += "
[(i / DNA_BLOCK_SIZE) + 1]
"
+ if((char_it % DNA_BLOCK_SIZE) == 0 && byte_it < len_byte)
+ temp_html += "
[(char_it / DNA_BLOCK_SIZE) + 1]
"
else
temp_html += "----"
temp_html += "