Fixed a bug where texts were not updated after loading a different sheet.

This commit is contained in:
Yord 2015-10-19 17:50:06 +02:00
parent 3de4febe45
commit 84b63ce498
5 changed files with 402 additions and 83 deletions

View file

@ -221,13 +221,13 @@ var ikrpg = ikrpg || {};
ikrpg.cards.updateData = function() {
var data = ikrpg.cards.data;
for (var key in data) {
for(var key in data) {
var value = data[key];
if (key == "hero-name") {
if(key == "hero-name") {
var currentData = $(".hero-name").val();
ikrpg.cards.data["hero-name"] = currentData;
} else if (typeof value === "object") {
} else if(typeof value === "object") {
for (var subkey in value) {
var subvalue = value[subkey];
var currentData = $("#"+key+" ."+subkey).val();