MediaWiki:MechCalculator

 /* Initialize */ {	var ArmorID = document.getElementById("Armor"); ArmorID.innerHTML = MechAClass.Armor.toString; var SpeedID = document.getElementById("Speed"); SpeedID.innerHTML = MechAClass.Speed.toString; var EUID = document.getElementById("EU"); EUID.innerHTML = MechAClass.EU.toString; }

/* Mech Variables */ var MechAClass = new Object; MechAClass.Armor = 500; MechAClass.Speed = 850; MechAClass.EU = 150; var PrimaryWeapon = ""; var SecondaryWeapon = "Grenade Launcher";

/* Functions */ function DefensiveInternalSelect(Internal) {	var ArmorCalcID = document.getElementById("ArmorCalc"); var SpeedCalcID = document.getElementById("SpeedCalc"); var EUCalcID = document.getElementById("EUCalc"); switch(Internal) {		case "Armor": ArmorCalcID.innerHTML = "-3% All Damage Received"; SpeedCalcID.innerHTML = "-1.5 m/s Movement Speed"; break; case "Heat Resistant Armor": ArmorCalcID.innerHTML = "-5% Explosion Damage Received"; SpeedCalcID.innerHTML = "-1 m/s Movement Speed"; break; case "Reinforced Armor": NewAmount = MechAClass.Armor * 0.05; ArmorCalcID.innerHTML = NewAmount.toString; break; case "Repair Kit": ArmorCalcID.innerHTML = "+15/sec Repair Rate"; break; case "Brand-new Cage": NewAmount = MechAClass.Armor * 0.05; ArmorCalcID.innerHTML = NewAmount.toString; break; default: ArmorCalcID.innerHTML = "-"; } }

function UpdateAll { }

/* Coded by TurboJensen */