Skip to content

Commit

Permalink
Merge pull request #1435 from JamzTheMan/feature-token-vbl-simplifica…
Browse files Browse the repository at this point in the history
…tion

Feature: Token VBL simplification
  • Loading branch information
Phergus authored Mar 30, 2020
2 parents 4b82c72 + 107d0f4 commit 2c2cc4a
Show file tree
Hide file tree
Showing 10 changed files with 2,706 additions and 1,166 deletions.
Binary file modified build-resources/abeille-maptool-forms.jfpr
Binary file not shown.
282 changes: 227 additions & 55 deletions src/main/java/net/rptools/maptool/client/functions/VBL_Functions.java

Large diffs are not rendered by default.

934 changes: 525 additions & 409 deletions src/main/java/net/rptools/maptool/client/ui/token/EditTokenDialog.java

Large diffs are not rendered by default.

538 changes: 439 additions & 99 deletions src/main/java/net/rptools/maptool/client/ui/token/TokenVblPanel.java

Large diffs are not rendered by default.

378 changes: 256 additions & 122 deletions src/main/java/net/rptools/maptool/client/ui/zone/vbl/TokenVBL.java

Large diffs are not rendered by default.

14 changes: 7 additions & 7 deletions src/main/java/net/rptools/maptool/model/Token.java
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ public int compare(Token o1, Token o2) {
private boolean isVisible = true;
private boolean visibleOnlyToOwner = false;

private int vblAlphaSensitivity = -1;
private int vblColorSensitivity = -1;
private int alwaysVisibleTolerance = 2; // Default for # of regions (out of 9) that must be seen
// before token is shown over FoW
private boolean isAlwaysVisible = false; // Controls whether a Token is shown over VBL
Expand Down Expand Up @@ -360,7 +360,7 @@ public Token(Token token) {
isVisible = token.isVisible;
visibleOnlyToOwner = token.visibleOnlyToOwner;

vblAlphaSensitivity = token.vblAlphaSensitivity;
vblColorSensitivity = token.vblColorSensitivity;
alwaysVisibleTolerance = token.alwaysVisibleTolerance;
isAlwaysVisible = token.isAlwaysVisible;
vbl = token.vbl;
Expand Down Expand Up @@ -1339,12 +1339,12 @@ public int getAlwaysVisibleTolerance() {
}
}

public void setAlphaSensitivity(int tolerance) {
vblAlphaSensitivity = tolerance;
public void setColorSensitivity(int tolerance) {
vblColorSensitivity = tolerance;
}

public int getAlphaSensitivity() {
return vblAlphaSensitivity;
public int getColorSensitivity() {
return vblColorSensitivity;
}

/**
Expand All @@ -1355,7 +1355,7 @@ public int getAlphaSensitivity() {
public void setVBL(Area vbl) {
this.vbl = vbl;
if (vbl == null) {
vblAlphaSensitivity = -1;
vblColorSensitivity = -1;
}
}

Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1,723 changes: 1,249 additions & 474 deletions src/main/resources/net/rptools/maptool/client/ui/forms/tokenPropertiesDialog.xml

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,9 @@ EditTokenDialog.msg.speech.colID = ID
EditTokenDialog.msg.speech.colSpeechText = Speech Text
EditTokenDialog.msg.title = Edit Token
EditTokenDialog.msg.wrap = Wrap
EditTokenDialog.vbl.label.originalPointCount = Original Point Count
EditTokenDialog.vbl.label.optimizedPointCount = Optimized Point Count
EditTokenDialog.vbl.label.working = Working...

GridlessGrid.error.notLoaded = Could not load gridless grid footprints.

Expand Down

0 comments on commit 2c2cc4a

Please sign in to comment.