Skip to content

Commit

Permalink
Merge pull request #3496 from Irarara/readresolve
Browse files Browse the repository at this point in the history
Fix for errors when loading certain campaign files
  • Loading branch information
Phergus authored Jul 17, 2022
2 parents de5db06 + 9ab13ad commit d8be06a
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/main/java/net/rptools/maptool/model/LightSource.java
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,9 @@ private Object readResolve() {
if (type == null) {
type = Type.NORMAL;
}
if (lightList == null) {
lightList = new LinkedList<>();
}
return this;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1105,6 +1105,8 @@ public Object readResolve() {
if (compareApplyToSelectedTokens == null) compareApplyToSelectedTokens = true;
if (allowPlayerEdits == null)
allowPlayerEdits = AppPreferences.getAllowPlayerMacroEditsDefault();
if (macroUUID == null) macroUUID = getMacroUUID();
if (displayHotKey == null) displayHotKey = true;
return this;
}

Expand Down
4 changes: 4 additions & 0 deletions src/main/java/net/rptools/maptool/model/Zone.java
Original file line number Diff line number Diff line change
Expand Up @@ -2110,6 +2110,10 @@ protected Object readResolve() {
if (aStarRounding == null) {
aStarRounding = AStarRoundingOptions.NONE;
}

if (tokenSelection == null) {
tokenSelection = TokenSelection.ALL;
}
return this;
}

Expand Down

0 comments on commit d8be06a

Please sign in to comment.