I need help with this character simulator.
Here's the code i'm working with. I can't seem to get it to start working
Code:
<html>
<title>Character Simulator</title>
<head>
<SCRIPT LANGUAGE="javascript" type="text/javascript">
Function Simulate_Char(){
Var Vit_Base = 5
Var Int_Base = 6
Var Dex_Base = 10
Var Str_Base = 4
Var Race1 = "Wood Elf"
}
If (race.Value == 1){
Var Vit_Base = 6
Var Str_Base = 7
Var Int_Base = 6
Var Dex_Base = 6
Var Race1 = "Human"
}
If (Class.Value == 1){
Var Dex_add = 9
Var Str_add = 3
Var Vit_add = -2
Var Int_add = 0
Var HP_Vit = 12
Var MP_Int = 10
Var Ddg_Dex = 7
Var Acc_Dex = 10
Var Def_Vit = 3
Var Dmg_Dex = 3
Var Dmg_Int = 0
Var Dmg_Str = 0.5
Var Crit_Dex = 0.02
Var Crit_Str = 0
Var Crit_Int = 0
Var Base_Crit= 5
Var Base_HP = 36
Var Base_MP = 30
Var Class1 = "Archer"
}
Var HP = (Base_HP+((Vit_Base+Vit_add+Vit)*HP_Vit)+((HP_Vit*2)*level))
Var MP = (Base_MP+((Int_Base+Int_add+Int)*MP_Int)+((MP_Int*2)*level))
Var Acc = ((Acc_Dex*3)+((Dex_Base+Dex_add+Dex+Dex)*Acc_Dex)+((Acc_Dex*1.2)*level))
Var Def = ((Def_Vit*2)+((Vit_Base+Vit_add+Vit)*Def_Vit)+((Vit_Def*1.1)*level))
Var Dmg = ((Dmg_Dex*2)+(Dmg_Str*2)+(Dmg_Int*2)+((Int_add+Int_Base+Int)* 
(Dmg_Int))+((Dex_add+Dex_Base+Dex)*(Dmg_Dex))+((Str_add+Str_Base)* 
(Dmg_Str))+(((Dmg_Str+Dmg_Int+Dmg_Dex)*1.1)*level))
Var Ddg = ((Dex_Base+Dex_add+Dex)*Ddg_Dex)+(Ddg_Dex*3)+((Ddg_Dex*1.1)*level))
Var Crit = (((Dex_Base+Dex_add+Dex)*Crit_Dex)+((Int_Base+Int_add+Int) 
*Crit_Int)+((Str_add+Str_Base+Str)*Crit_Str))
document.texts.sim.value= 'Race:'
+Race1.value
+'level:'
+level.value
+'Class:'
+Class1.value 
+'/n'
+'HP:'
+HP.value 
+'/n'
+'MP:'
+MP.value
+'Accuracy:'
+Acc.value
+'/n'
+'Dodge:'
+Ddg.value
+'/n'
+'Damage:'
+Dmg.value
+'/n'
+'Critical Hit Chance:'
+Crit.value
+'/n'
}
</script>
</head>
<body>
<FORM ACTION="#">
Race:
<SELECT NAME="race">
<option selected>race</option>
<option Value= '1'>Human</option>
</SELECT>
</FORM>
<FORM ACTION="#">
Class:
<SELECT NAME="Class">
<option selected>Class</option>
<option Value= '1'>Archer</option>
</select>
</form>
<FORM ACTION="#" NAME="stats">
level:
<INPUT TYPE=TEXT NAME="level" SIZE=3>
Dex:
<INPUT TYPE=TEXT NAME="Dex" SIZE=3>
Str:
<INPUT TYPE=TEXT NAME="Str" SIZE=3>
Int:
<INPUT TYPE=TEXT NAME="Int" SIZE=3>
Vit:
<INPUT TYPE=TEXT NAME="vit" SIZE=3>
</form>
<BR><BR>
<INPUT type="button" Value="Simulate Character" name="button1"  onClick="Simulate_Char();">
<BR><BR>
<TEXTAREA NAME="sim" COL=30 ROW=100></TEXTAREA>
</body>
</html>
I've been working on this thing for the past 2 days but i can't seem to find anything wrong with it. And also neither can my friend who i had look over it who's also a pretty good javascript coder. I say i'm pretty good since i can do somethings but if anyone can help me fix this so that it'd work that'd be GREATLY appreciated.