Periodic Table / Element Table

By ^Neptune on Apr 19, 2009

Image
Image

I was bored.

Load in remotes and type /elements. If there is no periodic table image the first time round, close and reopen it, and it should work - just a little niggle that I can't figure out.

Also, the original image can be found here. I've just edited it with my mad mspaint skillz so that Unununium and Ununillium have been renamed to Darmstadtium and Roentgenius respectively (they have been renamed since). Also have filled in the weird and wonderful bottow row of Uu's.

If you are wondering why Uus (Ununseptium) is there (click it, you'll find out), it's because it is listed in the periodic table and recognised as an element. However, it has not actually been discovered, and is presumed to exist.

Imrac's img_download alias and FordLawnMower's getpic alias have been used in this script - I am not going into specifics as to why, it was an odd situation.

on *:LOAD: { 
  mkdir elements 
  img_download -ok http://www.dark-purple.comuv.com/scripts/resources/periodic_table_of_elements.jpg $qt($mircdir $+ elements\)
  img_download -ok http://www.dark-purple.comuv.com/scripts/resources/noimage.png $qt($mircdir $+ elements\)
}
dialog elements {
  title "Element Table"
  size -1 -1 420 249
  option dbu
  icon 1, 0 0 420 249
}
alias img_download {
  if ($regex($1,/^-[asokmr]+$/i)) {
    if (a isin $1) { var %a = $2, %1 = $3, %2- = $4- }
    if (a !isin $1) { var %1 = $2, %2- = $3- }
    var %flgs = $1
  }
  else { var %1 = $1, %2- = $2- }
  if ($regex(img,%1,/^((?:https?://)((?:www.)?[^/]*)(.*/([^/]*\.(jpg|gif|bmp|png))))$/i)) && (%2-) {
    var %f = $qt(%2-)    
    if (k isin %flgs) {
      if ($nofile(%f) == $noqt(%f)) { var %f = $qt($noqt(%f) $+ $regml(img,4)) }
      else { echo -qeag 2 * /imgfile: Invalid Directory Name. | return }
    }
    if ($exists(%f)) && (o !isin %flgs) { echo -eqag 2 * /imgfile: %f Already Exists. | return }
    if (!$exists($nofile(%f))) && (m !isin %flgs) { echo -eqag 2 * /imgfile: $qt($nofile(%f)) Directory Does Not Exist. | return }
    if ($right($noqt(%f),3) != $regml(img,5)) { echo -qeag 2 * /imgfile: Invalid File Name. | return }
    else {
      var %x = imgdl_ $+ $regml(img,1), %h = hadd %x
      hadd -m %x full $regml(img,1)
      %h host $regml(img,2)
      %h get $regml(img,3)
      %h dlfile $regml(img,4)
      %h file %f
      %h time $ticks
      if (%flgs) { hadd %x flgs %flgs }
      if (%a) hadd %x alias %a
      if ($sock(%x)) { sockclose %x }
      sockopen %x $hget(%x,host) 80
    }
  }
  else echo -qeag 2 * /imgfile: Invalid Parameters.
}
on *:sockopen:imgdl_*:{
  var %s = $sockname, %w = sockwrite -n %s
  if ($sockerr) { img_fail %s | return }
  %w GET $hget(%s,get) HTTP/1.1 
  %w Host: $hget(%s,host)
  %w
}
on *:sockread:imgdl_*:{
  var %s = $sockname
  if ($sockerr) { img_fail %s }
  if (!$sock(%s).mark) { 
    var %x = $true  
    while (%x) { 
      sockread %x
      if ($regex(%x,/^Content-Length: (\d+)$/i)) { hadd %s size $regml(1) }
      if ($regex(%x,/^Content-Type: (.*)$/i)) { if (!$regex($regml(1),/^image/.*$/)) { img_fail %s | return } } 
      sockmark %s $true 
    }
  }
  else {
    while ($sock(%s).rq) {
      sockread &img
      noop $hget(%s,bvar,&temp)      
      bcopy &temp $calc($bvar(&temp,0) + 1) &img 1 -1
      hadd -b %s bvar &temp
      if ($bvar(&temp,0) == $hget(%s,size)) img_close %s
    }  
  }
} 
alias img_close {
  var %s = $1
  if (o isin $hget(%s,flgs))  .remove $hget(%s,file)
  if (m isin $hget(%s,flgs)) .mkdir $nofile($hget(%s,file)) 
  bwrite $hget(%s,file) -1 -1 &temp    
  if (s isin $hget(%s,flgs)) { 
    var %s = $calc(($ticks - $hget(%s,time)) / 1000), %sz = $calc($bvar(&temp,0) / 1024) 
    echo -eag Downloaded $hget(%s,file) ( $+ $round(%sz,2) kb $+ ) Took %s Seconds at $round($calc(%sz / %s ),2) kbps 
  }
  if (r isin $hget(%s,flgs)) { run $hget(%s,file) }
  if ($hget(%s,alias)) { $v1 $hget(%s,full) $hget(%s,file) }
  hfree %s
  sockclose %s
}
alias -l img_fail {
  var %1 = $1
  if ($sock(%1)) sockclose %1
  if ($hget(%1,alias)) { $v1 }
  hfree %1
}
alias elements { dialog $iif($dialog(elements),-v,-m) elements elements }
on *:dialog:elements:init:0: { did -g elements 1 $qt(elements\periodic_table_of_elements.jpg) }
on *:DIALOG:elements:SCLICK:1: {
  if (!$returnelement($mouse.x,$mouse.y)) { halt }
  elseif ($gettok($returnelement($mouse.x,$mouse.y),1,124) == Uus) {
    noop $input(Element Uus $+ $chr(44) Ununseptium $+ $chr(44) has not yet been discovered.,uio,Information)
    halt
  }
  elseif ($istok(Ds|Rg|Uut|Uuq|Uup|Uuh|Uuo,$gettok($returnelement($mouse.x,$mouse.y),1,124),124)) { e.load $gettok($returnelement($mouse.x,$mouse.y),2,124) }
  else {
    set %element $returnelement($mouse.x,$mouse.y)
    if ($sock(element)) { sockclose element }
    sockopen element www.chemicalelements.com 80
  }
}
alias e.load {
  if ($dialog(edisplay)) { dialog -x edisplay edisplay }
  dialog -m edisplay edisplay
  dialog -t edisplay $1
  did -a edisplay 2 $1
  did -a edisplay 4 $gettok($element. [ $+ [ $1 ] ],1,124)
  did -a edisplay 6 $gettok($element. [ $+ [ $1 ] ],2,124)
  did -a edisplay 8 $gettok($element. [ $+ [ $1 ] ],3,124)
  did -a edisplay 10 $gettok($element. [ $+ [ $1 ] ],4,124)
  did -a edisplay 12 $gettok($element. [ $+ [ $1 ] ],5,124)
  did -a edisplay 14 $gettok($element. [ $+ [ $1 ] ],2,124)
  did -a edisplay 16 $iif($1 == Ununseptium,Unknown,$calc($remove($gettok($element. [ $+ [ $1 ] ],3,124),$chr(91),$chr(93)) - $gettok($element. [ $+ [ $1 ] ],2,124)))
  did -a edisplay 18 $gettok($element. [ $+ [ $1 ] ],6,124)
  did -a edisplay 20 $gettok($element. [ $+ [ $1 ] ],7,124)
  did -a edisplay 22 $gettok($element. [ $+ [ $1 ] ],8,124)
  did -a edisplay 26 $gettok($element. [ $+ [ $1 ] ],9,124)
  did -a edisplay 28 $gettok($element. [ $+ [ $1 ] ],10,124)
  did -a edisplay 29 $gettok($element. [ $+ [ $1 ] ],11,124)
  did -a edisplay 31 $gettok($element. [ $+ [ $1 ] ],12,124)
  did -a edisplay 33 $gettok($element. [ $+ [ $1 ] ],13,124)
  did -g edisplay 24 $qt(elements\noimage.png)
}
;symbol|atomic number|atomic mass|melt point|boiling point|classification|crystal structure|color|date of discovery|discovered by|name origin|uses|obtained via
alias element.darmstadtium { return Ds|110|[281]|Unknown|Unknown|Metallic|Unknown|Unknown|2004|GSI|After place of discovery, Darmstadt, Germany|None|Man-made }
alias element.roentgenium { return Rg|111|272|Unknown|Unknown|Metallic|Unknown|Unknown|1994|GSI|After Wilhelm Conrad Roentgen, who discovered X-rays|None|Man-made }
alias element.ununbium { return Uub|112|[285]|Unknown|Unknown|Metallic|Unknown|Unknown|1996|GSI|Temporary name|None|Man-made }
alias element.ununtrium { return Uut|113|[284]|Unknown|Unknown|Metallic|Unknown|Unknown|2004|GSI|Temporary name|None|Man-made }
alias element.ununquadium { return Uuq|114|[289]|Unknown|Unknown|Metallic|Unknown|Unknown|1999|GSI|Temporary name|None|Man-made }
alias element.ununpentium { return Uup|115|[288]|Unknown|Unknown|Metallic|Unknown|Unknown|2004|GSI|Temporary name|None|Man-made }
alias element.ununhexium { return Uuh|116|[293]|Unknown|Unknown|Metallic|Unknown|Unknown|2000|GSI|Temporary name|None|Man-made }
alias element.ununoctium { return Uuo|118|[294]|Unknown|Unknown|Non-metallic|Unknown|Unknown|2002|GSI|Temporary name|None|Man-made }
alias -l htmlfree { var %x, %i = $regsub($1-,/(^[^<]*>|<[^>]*>|<[^>]*$)/g,$null,%x), %x = $remove(%x,&nbsp;,$chr(9)) | return $replace(%x,&quot;,",&lt;,<,&gt;,>,$cr,$chr(32),$lf,$chr(32),&amp;,&) }
on *:SOCKOPEN:element: {
  sockwrite -n $sockname GET /elements/ $+ $lower($gettok(%element,1,124)) $+ .html HTTP/1.0
  sockwrite -n $sockname Host: www.chemicalelements.com $+ $crlf $+ $crlf
}
alias epicload { if ($dialog(edisplay)) { did -g edisplay 24 $6- } }
on *:SOCKREAD:element: {
  sockread %e
  if (<strong>Name:</strong> isin %e) { set %element.name $gettok($htmlfree(%e),2,32) }
  if (<br><strong>Symbol:</strong> isin %e) { set %element.symbol $gettok($htmlfree(%e),2,32) }
  if (<br><strong>Atomic Number:</strong> isin %e) { set %element.anumber $gettok($htmlfree(%e),3,32) }
  if (<br><strong>Atomic Mass:</strong> isin %e) { set %element.amass $remove($gettok($htmlfree(%e),3,32),$chr(40),$chr(41)) }
  if (<br><strong>Melting Point:</strong> isin %e) { set %element.mpoint $gettok($htmlfree(%e),3,32) }
  if (<br><strong>Boiling Point:</strong> isin %e) { set %element.bpoint $gettok($htmlfree(%e),3,32) }
  if (<br><strong>Number of Protons/Electrons:</strong> isin %e) { set %element.penum $gettok($htmlfree(%e),4,32) }
  if (<br><strong>Number of Neutrons:</strong> isin %e) { set %element.nnum $gettok($htmlfree(%e),4,32) }
  if (<br><strong>Classification:</strong> isin %e) { set %element.type $gettok($htmlfree(%e),2-,32) }
  if (<br><strong>Crystal Structure:</strong> isin %e) { set %element.crystal $gettok($htmlfree(%e),3-,32) }
  if (<br><strong>Color:</strong> isin %e) { set %element.color $gettok($htmlfree(%e),2-,32) }
  if (<br><strong>Date of Discovery:</strong> isin %e) { set %element.disc $gettok($htmlfree(%e),4-,32) }
  if (<br><strong>Discoverer:</strong> isin %e) { set %element.dby $gettok($htmlfree(%e),2-,32) }
  if (<br><strong>Name Origin:</strong> isin %e) { set %element.origin $gettok($htmlfree(%e),3-,32) }
  if (<br><strong>Uses:</strong> isin %e) { set %element.uses $gettok($htmlfree(%e),2-,32) }
  if (<br><strong>Obtained From:</strong> isin %e) { set %element.obt $gettok($htmlfree(%e),3-,32) }
  if (<TD><IMG SRC=" isin %e) {
    var %wrl = http://www.chemicalelements.com/bohr/b0 $+ $threedigit(%element.anumber) $+ .gif
    getpic %wrl
  }
}
Alias GetPic {
  sockclose GetPic
  set %GetPic.Site $gettok($remove($1,http://),1,47)
  set %GetPic.URL $remove($1,$gettok($1,1,47),$gettok($1,2,47),//)
  set %GetPic.PicName $gettok($1,$gettok($1,0,47),47)
  if (!$isfile($mircdir $+ %getpic.picname)) { sockopen GetPic %getpic.site 80 }
  else { echo -a That picture already exists | unset %GetPic.* | halt }
}
on 1:sockopen:GetPic:{
  sockwrite -nt $sockname GET %getpic.url HTTP/1.1
  sockwrite $sockname Host: %getpic.site $+ $crlf $+ $crlf
}
on 1:sockread:GetPic:{
  if (!$sock($sockname).mark) {
    var %GetPic.var | sockread %GetPic.var
    if (%GetPic.var == $null) { sockmark $sockname 1 }
  }
  else {
    sockread &picture 
    bwrite $qt(elements\ $+ %getpic.picname) -1 -1 &picture
    set %elementpiccy %getpic.picname
  }
}
on *:dialog:elements:close:0: { noop $findfile(elements\,*.gif,0,0,.remove $1-) }
alias between { 
  noop $regex($1,/\Q $+ $2 $+ \E(.*?)\Q $+ $3 $+ \E/gi)
  return $regml($4)
}
on *:SOCKCLOSE:element: { addelements }
alias addelements {
  if ($dialog(edisplay)) { dialog -x edisplay edisplay }
  dialog -m edisplay edisplay
  did -a edisplay 2 %element.name
  did -a edisplay 4 %element.symbol
  did -a edisplay 6 %element.anumber
  did -a edisplay 8 %element.amass
  did -a edisplay 10 %element.mpoint
  did -a edisplay 12 %element.bpoint
  did -a edisplay 14 %element.penum
  did -a edisplay 16 %element.nnum
  did -a edisplay 18 %element.type
  did -a edisplay 20 %element.crystal
  did -a edisplay 22 %element.color
  did -a edisplay 26 %element.disc
  did -a edisplay 28 %element.dby
  did -a edisplay 29 %element.origin
  did -a edisplay 31 %element.uses
  did -a edisplay 33 %element.obt
  dialog -t edisplay %element.name
  did -g edisplay 24 $qt(elements\ $+ %elementpiccy)
  unset %element.*
}
alias returnelement {
  if ($1 isnum 3-46) && ($2 isnum 3-54) { return H|Hydrogen }
  if ($1 isnum 3-46) && ($2 isnum 55-104) { return Li|Lithium }
  if ($1 isnum 3-46) && ($2 isnum 105-153) { return Na|Sodium }
  if ($1 isnum 3-46) && ($2 isnum 154-204) { return K|Potassium }
  if ($1 isnum 3-46) && ($2 isnum 205-253) { return Rb|Rubidium }
  if ($1 isnum 3-46) && ($2 isnum 254-302) { return Cs|Caesium }
  if ($1 isnum 3-46) && ($2 isnum 303-352) { return Fr|Francium }
  if ($1 isnum 48-90) && ($2 isnum 55-104) { return Be|Beryllium }
  if ($1 isnum 48-90) && ($2 isnum 105-153) { return Mg|Magnesium }
  if ($1 isnum 48-90) && ($2 isnum 154-204) { return Ca|Calcium }
  if ($1 isnum 48-90) && ($2 isnum 205-253) { return Sr|Strontium }
  if ($1 isnum 48-90) && ($2 isnum 254-302) { return Ba|Barium }
  if ($1 isnum 48-90) && ($2 isnum 303-352) { return Ra|Radium }
  if ($1 isnum 135-178) && ($2 isnum 154-204) { return Sc|Scandium }
  if ($1 isnum 135-178) && ($2 isnum 205-253) { return Y|Yttrium }
  if ($1 isnum 135-178) && ($2 isnum 254-302) { return Lu|Lutelium }
  if ($1 isnum 135-178) && ($2 isnum 303-352) { return Lr|Lawrencium }
  if ($1 isnum 179-222) && ($2 isnum 154-204) { return Ti|Titanium }
  if ($1 isnum 179-222) && ($2 isnum 205-253) { return Zr|Zirconium }
  if ($1 isnum 179-222) && ($2 isnum 254-302) { return Hf|Hafnium }
  if ($1 isnum 179-222) && ($2 isnum 303-352) { return Rf|Rutherfordium }
  if ($1 isnum 223-266) && ($2 isnum 154-204) { return V|Vanadium }
  if ($1 isnum 223-266) && ($2 isnum 205-253) { return Nb|Niobium }
  if ($1 isnum 223-266) && ($2 isnum 254-302) { return Ta|Tantalum }
  if ($1 isnum 223-266) && ($2 isnum 303-352) { return Db|Dubnium }
  if ($1 isnum 267-309) && ($2 isnum 154-204) { return Cr|Chromium }
  if ($1 isnum 267-309) && ($2 isnum 205-253) { return Mo|Molybendum }
  if ($1 isnum 267-309) && ($2 isnum 254-302) { return W|Tungsten }
  if ($1 isnum 267-309) && ($2 isnum 303-352) { return Sg|Seaborgium }
  if ($1 isnum 310-352) && ($2 isnum 154-204) { return Mn|Manganese }
  if ($1 isnum 310-352) && ($2 isnum 205-253) { return Tc|Technetium }
  if ($1 isnum 310-352) && ($2 isnum 254-302) { return Re|Rhenium }
  if ($1 isnum 310-352) && ($2 isnum 303-352) { return Bh|Bohrium }
  if ($1 isnum 353-397) && ($2 isnum 154-204) { return Fe|Iron }
  if ($1 isnum 353-397) && ($2 isnum 205-253) { return Ru|Ruthenium }
  if ($1 isnum 353-397) && ($2 isnum 254-302) { return Os|Osmium }
  if ($1 isnum 353-397) && ($2 isnum 303-352) { return Hs|Hassium }
  if ($1 isnum 398-441) && ($2 isnum 154-204) { return Co|Cobalt }
  if ($1 isnum 398-441) && ($2 isnum 205-253) { return Rh|Rhodium }
  if ($1 isnum 398-441) && ($2 isnum 254-302) { return Ir|Iridium }
  if ($1 isnum 398-441) && ($2 isnum 303-352) { return Mt|Meitnerium }
  if ($1 isnum 442-485) && ($2 isnum 154-204) { return Ni|Nickel }
  if ($1 isnum 442-485) && ($2 isnum 205-253) { return Pd|Palladium }
  if ($1 isnum 442-485) && ($2 isnum 254-302) { return Pt|Platinum }
  if ($1 isnum 442-485) && ($2 isnum 303-352) { return Ds|Darmstadtium }
  if ($1 isnum 486-528) && ($2 isnum 154-204) { return Cu|Copper }
  if ($1 isnum 486-528) && ($2 isnum 205-253) { return Ag|Silver }
  if ($1 isnum 486-528) && ($2 isnum 254-302) { return Au|Gold }
  if ($1 isnum 486-528) && ($2 isnum 303-352) { return Rg|Roentgenium }
  if ($1 isnum 529-572) && ($2 isnum 154-204) { return Zn|Zinc }
  if ($1 isnum 529-572) && ($2 isnum 205-253) { return Cd|Cadmium }
  if ($1 isnum 528-572) && ($2 isnum 254-302) { return Hg|Mercury }
  if ($1 isnum 528-572) && ($2 isnum 303-352) { return Uub|Ununbium }
  if ($1 isnum 136-178) && ($2 isnum 392-440) { return La|Lanthanum }
  if ($1 isnum 136-178) && ($2 isnum 441-490) { return Ac|Actinium }
  if ($1 isnum 179-222) && ($2 isnum 392-440) { return Ce|Cerium }
  if ($1 isnum 179-222) && ($2 isnum 441-490) { return Th|Thorium }
  if ($1 isnum 223-266) && ($2 isnum 392-440) { return Pr|Praseodymium }
  if ($1 isnum 223-266) && ($2 isnum 441-490) { return Pa|Protactinum }
  if ($1 isnum 267-309) && ($2 isnum 392-440) { return Nd|Neodymium }
  if ($1 isnum 267-309) && ($2 isnum 441-490) { return U|Uranium }
  if ($1 isnum 310-354) && ($2 isnum 392-440) { return Pm|Promethium }
  if ($1 isnum 310-354) && ($2 isnum 441-490) { return Np|Neptunium }
  if ($1 isnum 355-398) && ($2 isnum 392-440) { return Sm|Samarium }
  if ($1 isnum 355-398) && ($2 isnum 441-490) { return Pu|Plutonium }
  if ($1 isnum 399-442) && ($2 isnum 392-440) { return Eu|Europium }
  if ($1 isnum 399-442) && ($2 isnum 441-490) { return Am|Americium }
  if ($1 isnum 443-485) && ($2 isnum 392-440) { return Gd|Gadolinium }
  if ($1 isnum 443-485) && ($2 isnum 441-490) { return Cm|Curium }
  if ($1 isnum 486-529) && ($2 isnum 392-440) { return Tb|Terbium }
  if ($1 isnum 486-529) && ($2 isnum 441-490) { return Bk|Berkelium }
  if ($1 isnum 530-573) && ($2 isnum 392-440) { return Dy|Dysprosium }
  if ($1 isnum 530-573) && ($2 isnum 441-490) { return Cf|Californium }
  if ($1 isnum 574-617) && ($2 isnum 392-440) { return Ho|Holmium }
  if ($1 isnum 574-617) && ($2 isnum 441-490) { return Es|Einsteinium }
  if ($1 isnum 618-661) && ($2 isnum 392-440) { return Er|Erbium }
  if ($1 isnum 618-661) && ($2 isnum 441-490) { return Fm|Fermium }
  if ($1 isnum 662-705) && ($2 isnum 392-440) { return Tm|Thulium }
  if ($1 isnum 662-705) && ($2 isnum 441-490) { return Md|Mendelevium }
  if ($1 isnum 706-748) && ($2 isnum 392-440) { return Yb|Ytterbium }
  if ($1 isnum 706-748) && ($2 isnum 441-490) { return No|Nobelium }
  if ($1 isnum 573-616) && ($2 isnum 55-103) { return B|Boron }
  if ($1 isnum 573-616) && ($2 isnum 104-154) { return Al|Aluminium }
  if ($1 isnum 573-616) && ($2 isnum 155-204) { return Ga|Gallium }
  if ($1 isnum 573-616) && ($2 isnum 205-254) { return In|Indium }
  if ($1 isnum 573-616) && ($2 isnum 255-302) { return Tl|Thallium }
  if ($1 isnum 573-616) && ($2 isnum 303-352) { return Uut|Ununtrium }
  if ($1 isnum 617-661) && ($2 isnum 55-103) { return C|Carbon }
  if ($1 isnum 617-661) && ($2 isnum 104-154) { return Si|Silicon }
  if ($1 isnum 617-661) && ($2 isnum 155-204) { return Ge|Germanium }
  if ($1 isnum 617-661) && ($2 isnum 205-254) { return Sn|Tin }
  if ($1 isnum 617-661) && ($2 isnum 255-302) { return Pb|Lead }
  if ($1 isnum 617-661) && ($2 isnum 303-352) { return Uuq|Ununquandium }
  if ($1 isnum 662-703) && ($2 isnum 55-103) { return N|Nitrogen }
  if ($1 isnum 662-703) && ($2 isnum 104-154) { return P|Phosphorous }
  if ($1 isnum 662-703) && ($2 isnum 155-204) { return As|Arsenic }
  if ($1 isnum 662-703) && ($2 isnum 205-254) { return Sb|Antimony }
  if ($1 isnum 662-703) && ($2 isnum 255-302) { return Bi|Bismuth }
  if ($1 isnum 662-703) && ($2 isnum 303-352) { return Uup|Ununpentium }
  if ($1 isnum 704-749) && ($2 isnum 55-103) { return O|Oxygen }
  if ($1 isnum 704-749) && ($2 isnum 104-154) { return S|Sulfur }
  if ($1 isnum 704-749) && ($2 isnum 155-204) { return Se|Selenium }
  if ($1 isnum 704-749) && ($2 isnum 205-254) { return Te|Tellurium }
  if ($1 isnum 704-749) && ($2 isnum 255-302) { return Po|Polonium }
  if ($1 isnum 704-749) && ($2 isnum 303-352) { return Uuh|Ununhexium }
  if ($1 isnum 750-791) && ($2 isnum 55-103) { return F|Flourine }
  if ($1 isnum 750-791) && ($2 isnum 104-154) { return Cl|Chlorine }
  if ($1 isnum 750-791) && ($2 isnum 155-204) { return Br|Bromine }
  if ($1 isnum 750-791) && ($2 isnum 205-254) { return I|Iodine }
  if ($1 isnum 750-791) && ($2 isnum 255-302) { return At|Astatine }
  if ($1 isnum 750-791) && ($2 isnum 303-352) { return Uus|Ununseptium }
  if ($1 isnum 792-835) && ($2 isnum 55-103) { return Ne|Neon }
  if ($1 isnum 792-835) && ($2 isnum 104-154) { return Ar|Argon }
  if ($1 isnum 792-835) && ($2 isnum 155-204) { return Kr|Krypton }
  if ($1 isnum 792-835) && ($2 isnum 205-254) { return Xe|Xenon }
  if ($1 isnum 792-835) && ($2 isnum 255-302) { return Rn|Radon }
  if ($1 isnum 792-835) && ($2 isnum 303-352) { return Uuo|Ununoctium }
  if ($1 isnum 792-835) && ($2 isnum 4-54) { return He|Helium } 
}
dialog edisplay {
  title "Element"
  size -1 -1 368 124
  option dbu
  text "Name:", 1, 4 10 32 8
  edit "", 2, 49 9 50 10, read center
  text "Symbol:", 3, 4 20 32 8
  edit "", 4, 49 19 50 10, read center
  text "Atomic number:", 5, 4 30 39 8
  edit "", 6, 49 29 50 10, read center
  text "Atomic mass:", 7, 4 40 37 8
  edit "", 8, 49 39 50 10, read center
  text "Melting point:", 9, 4 50 37 8
  edit "", 10, 49 49 50 10, read center
  text "Boiling point:", 11, 4 60 37 8
  edit "", 12, 49 59 50 10, read center
  text "Protons/Electrons:", 13, 4 70 44 8
  edit "", 14, 49 69 50 10, read center
  text "Neutrons:", 15, 4 80 44 8
  edit "", 16, 49 79 50 10, read center
  text "Classification:", 17, 4 90 44 8
  edit "", 18, 49 89 50 10, read center
  text "Crystal structure:", 19, 4 100 44 8
  edit "", 20, 49 99 50 10, read center
  text "Color:", 21, 4 110 44 8
  edit "", 22, 49 109 50 10, read center
  box "Basic Information:", 23, 2 1 100 121
  icon 24, 105 4 150 118
  text "Discovered:", 25, 260 9 35 8
  edit "", 26, 299 8 65 10, read center
  text "Discovered by:", 27, 260 21 36 8
  edit "", 28, 299 20 65 16, multi read vsbar center
  edit "", 29, 299 38 65 30, read multi vsbar
  text "Name origin:", 30, 260 39 36 8
  edit "", 31, 299 70 65 25, read multi vsbar
  text "Uses:", 32, 260 71 36 8
  edit "", 33, 298 97 65 22, read multi vsbar
  text "Obtained from:", 34, 260 98 37 8
  box "Facts:", 35, 257 1 109 121
}
alias threedigit {
  if ($1 !isnum) return
  return $iif($len($1) < 3,$right($+(00,$1),3),$1)
}

Comments

Sign in to comment.
asakura   -  Sep 28, 2009

where Ununpentium and Ununhexium and Ununseptium? nah im just being picky now ): i wanted to make this well it wouldnt be nowere near as good but mehh :P

nice script 8/10

 Respond  
Atr   -  Sep 28, 2009

Sg is a little bit of a wild element, but don't worry :P

And, yeah nice script! I love the kick ass returnelement alias x)

 Respond  
asakura   -  Sep 28, 2009

i was told at school the shells were 2,8,8 max ): this one has 18 on the 3rd shell ? (picture)

 Respond  
PATX   -  Apr 21, 2009

lmao Aucun50

rating; 7 (useful)
reason: very cool. kudos on making this all by urself too jeje. the code is pretty good and is a useful script all in all. keep up the good work.

patxbot definition for "jeje":

~jeje see ~jaja ~jaja the mexican version of "haha" basicly it uses the mexican way of making 'j's sound like 'h's. USE IT PASS IT AROUND. its the new internet sensation (kinda)
 Respond  
Aucun50   -  Apr 19, 2009

The wrecks, destroys and makes fun of my elements script all at the same time, i love it!. Great script 8/10 from me like the paint shop work.

 Respond  
Prelude   -  Apr 19, 2009

ROFL, don't be touchy kirbz, and you don't need to stick up for him (himz a big boi), anyways i liked this script ;p, works and it's neat, but is it useful?, not to me but to someone maybe so it gets 7/10 from me.

 Respond  
Kirby   -  Apr 19, 2009

Firstmate said:

Sorry, but I feel like you should've added some of your own coding into it.
He actually coded this himself this time, although he asked me many times how to fix something in my home channel. The only thing he didn't code himself is the img_download alias, created by TheImrac.

 Respond  
Blitzjager   -  Apr 19, 2009

He's got a socket to get all of the info.
Looks good to me.

 Respond  
Firstmate   -  Apr 19, 2009

So what, you can make dialogs? :D
Sorry, but I feel like you should've added some of your own coding into it.

 Respond  
FordLawnmower   -  Apr 19, 2009

Looks good :)

 Respond  
Kirby   -  Apr 19, 2009

/me likes your mad paint skillz

 Respond  
^Neptune   -  Apr 19, 2009

Edit: screenshots have been fixed.

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.