Permalink
Browse files

Updating load if statement

  • Loading branch information...
1 parent 464c585 commit 133d60c5425d61f30bf0f4acfa900f2a6c0515eb @someguy1984 committed Jul 4, 2012
Showing with 4 additions and 5 deletions.
  1. BIN bin-debug/SWL.swf
  2. +1 −1 justsword.xml
  3. +3 −4 src/includes/saveLoadState.as
View
BIN bin-debug/SWL.swf
Binary file not shown.
View
2 justsword.xml
@@ -4,7 +4,7 @@
<secondryWeapon doNotHide="true" listIndex="true">0</secondryWeapon>
<classSelect doNotHide="true" listIndex="true">4</classSelect>
<compareSelection doNotHide="true" listIndex="true">1</compareSelection>
- <compareWeapon doNotHide="true" data="primaryWeaponList" listIndex="true">15</compareWeapon>
+ <compareWeapon doNotHide="true" data="primaryWeaponList" listIndex="true">1</compareWeapon>
<charSkillOne data="barbarianSkillList" listIndex="true">0</charSkillOne>
<charSkillTwo data="barbarianSkillList" listIndex="true">0</charSkillTwo>
<charSkillThree data="barbarianSkillList" listIndex="true">0</charSkillThree>
View
7 src/includes/saveLoadState.as
@@ -40,15 +40,14 @@ public function loadXML():void {
if (xmlStr.children()[i].@["listIndex"] == "true") {
//if the element has something to select then ensure it is displayed
- if (xmlStr.children()[i].@["doNotHide"] != 'true' || xmlStr.children()[i] > 0) {
+ if (xmlStr.children()[i].@["doNotHide"] == 'true') {
+ showAllElem(objRef);
+ } else if (xmlStr.children()[i] == 0) {
hideElemObj(objRef);
} else {
showAllElem(objRef);
}
- if (xmlStr.children()[i] > 0) {
- showAllElem(objRef);
- }
//Set the value of the data attribute so we can test against it
var isData:String = xmlStr.children()[i].@["data"];

0 comments on commit 133d60c

Please sign in to comment.