Skip to content

Commit

Permalink
Merge pull request #3467 from thelsing/resolve
Browse files Browse the repository at this point in the history
Fix dragging default top-down token to map
  • Loading branch information
Phergus authored Jul 9, 2022
2 parents 1a4ebf1 + d20dd45 commit a8c4a5c
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 9 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -50,3 +50,4 @@ build-resources/rptools-keystore
/report.html
/output.xml
/lib/jide/
/local.properties
13 changes: 5 additions & 8 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ plugins {
id "com.diffplug.spotless" version "5.14.3"
id 'org.openjfx.javafxplugin' version '0.0.10'
id 'org.beryx.runtime' version '1.12.7'
id "com.google.protobuf" version "0.8.17"
id "com.google.protobuf" version "0.8.19"
}

// Apply the java plugin to add support for Java
Expand All @@ -34,9 +34,6 @@ apply plugin: 'com.google.protobuf'
defaultTasks 'clean', 'build'
sourceCompatibility = 17
targetCompatibility = 17
def grpcVersion = '1.39.0'
def protobufVersion = '3.20.0'
def protocVersion = protobufVersion


// Used by gradle assemble & run tasks
Expand Down Expand Up @@ -129,7 +126,7 @@ javafx {
}

protobuf {
protoc { artifact = "com.google.protobuf:protoc:${protocVersion}" }
protoc { artifact = "com.google.protobuf:protoc:3.20.0" }
}

// Inform IDEs like IntelliJ IDEA, Eclipse or NetBeans about the generated code.
Expand Down Expand Up @@ -401,7 +398,7 @@ dependencies {
// testimplementation dependency to testimplementation 'org.testng:testng:6.8.1' and add
// 'test.useTestNG()' to your build script.
//testCompile 'junit:junit:4.12'
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.7.2'
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.8.2'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.8.2'

// For mocking features during unit tests
Expand All @@ -427,8 +424,8 @@ dependencies {
implementation 'dev.onvoid.webrtc:webrtc-java:0.5.0:linux-x86_64'

// protobuf
implementation "io.grpc:grpc-protobuf:${grpcVersion}"
implementation "com.google.protobuf:protobuf-java-util:${protobufVersion}"
implementation "io.grpc:grpc-protobuf:1.47.0"
implementation "com.google.protobuf:protobuf-java-util:3.20.0"

// Java Tuples
implementation 'com.flipkart.utils:javatuples:3.0'
Expand Down
9 changes: 8 additions & 1 deletion src/main/java/net/rptools/maptool/model/Token.java
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,7 @@ public String toString() {
// Jamz: modifies A* cost of other tokens
private double terrainModifier = 0.0d;
private TerrainModifierOperation terrainModifierOperation = TerrainModifierOperation.NONE;
private final Set<TerrainModifierOperation> terrainModifiersIgnored =
private Set<TerrainModifierOperation> terrainModifiersIgnored =
new HashSet<>(Collections.singletonList(TerrainModifierOperation.NONE));

private boolean isFlippedX;
Expand Down Expand Up @@ -2465,6 +2465,13 @@ protected Object readResolve() {
if (speechName == null) {
speechName = "";
}
if (terrainModifiersIgnored == null) {
terrainModifiersIgnored =
new HashSet<>(Collections.singletonList(TerrainModifierOperation.NONE));
}
if (terrainModifierOperation == null) {
terrainModifierOperation = TerrainModifierOperation.NONE;
}

return this;
}
Expand Down

0 comments on commit a8c4a5c

Please sign in to comment.