diff --git a/TODO b/TODO index 24ecf60..85171a5 100644 --- a/TODO +++ b/TODO @@ -1,7 +1,7 @@ ToDo for JSDSH: - Implement FrontEnd (Add Player, etc) ? - Background and Wall Editing/Importing - - Basic Modifiers + * Basic Modifiers - on-the-fly-adding of characters - traps etc. - JSON instead of JavaScript importing diff --git a/assets/style.css b/assets/style.css index 72d3070..5c49eca 100644 --- a/assets/style.css +++ b/assets/style.css @@ -22,7 +22,7 @@ h1 { position:relative; } -#ui { +#uibon, #uiatt { right: 30px; } diff --git a/index.html b/index.html index 3881e76..bccd338 100644 --- a/index.html +++ b/index.html @@ -10,7 +10,8 @@
";
- outstr += "Boni?
";
- outstr += "Waffenbonus Nahkampf:
";
- outstr += "Waffenbonus Fernkampf:
";
- outstr += "Panzerungsbonus:
";
- outstr += "Zauberbonus:
";
outstr += "Angriffstyp?
";
outstr += "
";
-
+
outstr += "Abwehrbar? ";
outstr += "
";
+ outstr += "Boni?
";
+ outstr += "Waffenbonus Nahkampf:
";
+ outstr += "Waffenbonus Fernkampf:
";
+ outstr += "Panzerungsbonus:
";
+ outstr += "Zauberbonus:
";
+ $('#uibon').html(outstr);
+ $('#wbn').attr("value", cur_sel.extern.weapon_near+"")
+ .bind("change",
+ function() {cur_sel.extern.weapon_near = this.value*1;
+ cur_sel.recalc_battle();
+ cur_sel.printoutput();
+ }
+ );
+ $('#wbf').attr("value", cur_sel.extern.weapon_far)
+ .bind("change",
+ function() {cur_sel.extern.weapon_far = this.value*1;
+ cur_sel.recalc_battle();
+ cur_sel.printoutput();
+ }
+ );
+ $('#pb').attr("value",cur_sel.extern.armor)
+ .bind("change",
+ function() {cur_sel.extern.armor = this.value*1;
+ cur_sel.recalc_battle();
+ cur_sel.printoutput();
+ }
+ );
+ $('#zb').attr("value",cur_sel.extern.chant)
+ .bind("change",
+ function() {cur_sel.extern.chant = this.value*1;
+ cur_sel.recalc_battle();
+ cur_sel.printoutput();
+ }
+ );
+ },
printoutput: function() {
outstr = "
";
outstr += this.info.cname + " (gespielt von "+this.info.pname +")
";
outstr += "Greift derzeit durch " + this.att + " mit einer Stärke von "
- + this.battle[this.att] + " an. (WB: "+ this.extern.defense +"
";
+ + this.battle[this.att] + " an.
";
outstr += "Verteidigungsstärke: " + this.battle.defense + "
";
outstr += "Kraftpunkte: " + this.life;
outstr += "