Merge branch 'master' of https://github.com/runelite-extended/runelite
This commit is contained in:
18
.travis.yml
18
.travis.yml
@@ -1,13 +1,17 @@
|
||||
install: gradle wrapper --gradle-version 4.2
|
||||
language: java
|
||||
sudo: false
|
||||
dist: trusty
|
||||
|
||||
language: java
|
||||
jdk: oraclejdk8
|
||||
|
||||
before_cache:
|
||||
- rm -f $HOME/.gradle/caches/modules-2/modules-2.lock
|
||||
- rm -fr $HOME/.gradle/caches/*/plugin-resolution/
|
||||
cache:
|
||||
directories:
|
||||
- $HOME/.m2
|
||||
jdk:
|
||||
- oraclejdk8
|
||||
script: ./travis/build.sh
|
||||
before_install:
|
||||
- chmod +x ./travis/build.sh
|
||||
- $HOME/.gradle/caches/
|
||||
- $HOME/.gradle/wrapper/
|
||||
|
||||
script: ./gradlew clean build -x test
|
||||
|
||||
|
||||
75
build.gradle
75
build.gradle
@@ -1,34 +1,55 @@
|
||||
allprojects {
|
||||
apply plugin: 'maven'
|
||||
apply plugin: 'checkstyle'
|
||||
plugins {
|
||||
id "com.github.ben-manes.versions" version "0.21.0"
|
||||
id "com.gradle.build-scan" version "2.3"
|
||||
}
|
||||
|
||||
group = 'net.runelite'
|
||||
version = '1.5.30-SNAPSHOT'
|
||||
allprojects {
|
||||
apply plugin: 'maven'
|
||||
apply plugin: 'checkstyle'
|
||||
|
||||
group = 'net.runelite'
|
||||
version = '1.5.30-SNAPSHOT'
|
||||
|
||||
gradle.projectsEvaluated {
|
||||
tasks.withType(JavaCompile) {
|
||||
options.compilerArgs << "-Xlint:deprecation"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
subprojects {
|
||||
apply plugin: 'java'
|
||||
sourceCompatibility = 1.8
|
||||
targetCompatibility = 1.8
|
||||
tasks.withType(JavaCompile) {
|
||||
options.encoding = 'UTF-8'
|
||||
}
|
||||
apply plugin: 'java'
|
||||
sourceCompatibility = 1.8
|
||||
targetCompatibility = 1.8
|
||||
tasks.withType(JavaCompile) {
|
||||
options.encoding = 'UTF-8'
|
||||
}
|
||||
|
||||
|
||||
repositories {
|
||||
mavenLocal()
|
||||
|
||||
maven { url "http://repo1.maven.org/maven2" }
|
||||
maven { url "http://repo.runelite.net" }
|
||||
maven { url "http://repo.maven.apache.org/maven2" }
|
||||
maven { url "https://raw.githubusercontent.com/runelite-extended/maven-repo/master" }
|
||||
}
|
||||
|
||||
checkstyle {
|
||||
toolVersion = '6.4.1'
|
||||
sourceSets = [sourceSets.main]
|
||||
configFile = rootProject.file("./checkstyle/checkstyle.xml");
|
||||
showViolations = true
|
||||
ignoreFailures = false
|
||||
}
|
||||
repositories {
|
||||
mavenLocal()
|
||||
|
||||
maven { url "http://repo1.maven.org/maven2" }
|
||||
maven { url "http://repo.runelite.net" }
|
||||
maven { url "http://repo.maven.apache.org/maven2" }
|
||||
maven { url "https://raw.githubusercontent.com/runelite-extended/maven-repo/master" }
|
||||
}
|
||||
|
||||
checkstyle {
|
||||
toolVersion = '6.4.1'
|
||||
sourceSets = [sourceSets.main]
|
||||
configFile = rootProject.file("./checkstyle/checkstyle.xml")
|
||||
showViolations = true
|
||||
ignoreFailures = false
|
||||
}
|
||||
}
|
||||
|
||||
wrapper {
|
||||
gradleVersion = '5.5.1'
|
||||
|
||||
doLast {
|
||||
def optsEnvVar = "DEFAULT_JVM_OPTS"
|
||||
scriptFile.write scriptFile.text.replace("$optsEnvVar='\"-Xmx64m\" \"-Xms64m\"'", "$optsEnvVar='\"-Xmx4g\" \"-Xms2g\" \"-Dfile.encoding=UTF-8\"'")
|
||||
batchScript.write batchScript.text.replace("set $optsEnvVar=\"-Xmx64m\" \"-Xms64m\"", "set $optsEnvVar=\"-Xmx4g\" \"-Xms2g\" \"-Dfile.encoding=UTF-8\"")
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,9 +1,8 @@
|
||||
|
||||
description = 'Cache Client'
|
||||
dependencies {
|
||||
compile project(':cache')
|
||||
compile project(':protocol')
|
||||
testCompile group: 'junit', name: 'junit', version:'4.12'
|
||||
testCompile group: 'org.slf4j', name: 'slf4j-simple', version:'1.7.26'
|
||||
testCompile project(':cache')
|
||||
compile project(':cache')
|
||||
compile project(':protocol')
|
||||
testCompile group: 'junit', name: 'junit', version: '4.12'
|
||||
testCompile group: 'org.slf4j', name: 'slf4j-simple', version: '1.7.26'
|
||||
testCompile project(':cache')
|
||||
}
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
|
||||
description = 'Cache Updater'
|
||||
dependencies {
|
||||
compile group: 'org.springframework.boot', name: 'spring-boot-starter', version:'1.5.6.RELEASE'
|
||||
compile group: 'org.springframework.boot', name: 'spring-boot-starter-jdbc', version:'1.5.6.RELEASE'
|
||||
compile group: 'org.springframework.boot', name: 'spring-boot-devtools', version:'1.5.6.RELEASE'
|
||||
compile group: 'mysql', name: 'mysql-connector-java', version:'8.0.16'
|
||||
compile project(':cache-client')
|
||||
compile group: 'org.sql2o', name: 'sql2o', version:'1.6.0'
|
||||
compile group: 'io.minio', name: 'minio', version:'3.0.6'
|
||||
compileOnly group: 'org.projectlombok', name: 'lombok', version:'1.18.8'
|
||||
compile group: 'org.springframework.boot', name: 'spring-boot-starter', version: '2.1.6.RELEASE'
|
||||
compile group: 'org.springframework.boot', name: 'spring-boot-starter-jdbc', version: '2.1.6.RELEASE'
|
||||
compile group: 'org.springframework.boot', name: 'spring-boot-devtools', version: '2.1.6.RELEASE'
|
||||
compile group: 'mysql', name: 'mysql-connector-java', version: '8.0.17'
|
||||
compile project(':cache-client')
|
||||
compile group: 'org.sql2o', name: 'sql2o', version: '1.6.0'
|
||||
compile group: 'io.minio', name: 'minio', version: '6.0.8'
|
||||
compileOnly group: 'org.projectlombok', name: 'lombok', version: '1.18.8'
|
||||
annotationProcessor group: 'org.projectlombok', name: 'lombok', version: '1.18.8'
|
||||
}
|
||||
|
||||
@@ -33,8 +33,8 @@ import java.util.Map;
|
||||
import javax.sql.DataSource;
|
||||
import org.springframework.beans.factory.annotation.Qualifier;
|
||||
import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.boot.autoconfigure.jdbc.DataSourceBuilder;
|
||||
import org.springframework.boot.context.properties.ConfigurationProperties;
|
||||
import org.springframework.boot.jdbc.DataSourceBuilder;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
import org.sql2o.Sql2o;
|
||||
|
||||
30
cache/build.gradle
vendored
30
cache/build.gradle
vendored
@@ -1,22 +1,22 @@
|
||||
|
||||
description = 'Cache'
|
||||
dependencies {
|
||||
compile project(':http-api')
|
||||
compile group: 'com.google.guava', name: 'guava', version:'28.0-jre'
|
||||
compile group: 'org.slf4j', name: 'slf4j-api', version:'1.7.25'
|
||||
compile group: 'org.apache.commons', name: 'commons-compress', version:'1.18'
|
||||
compile group: 'com.google.code.gson', name: 'gson', version:'2.8.5'
|
||||
compile group: 'io.netty', name: 'netty-buffer', version:'4.1.37.Final'
|
||||
compile group: 'org.antlr', name: 'antlr4-runtime', version:'4.6'
|
||||
compile group: 'commons-cli', name: 'commons-cli', version:'1.4'
|
||||
testCompile group: 'junit', name: 'junit', version:'4.12'
|
||||
testCompile group: 'org.slf4j', name: 'slf4j-simple', version:'1.7.26'
|
||||
testCompile group: 'net.runelite.rs', name: 'cache', version:'165'
|
||||
compileOnly group: 'org.projectlombok', name: 'lombok', version:'1.18.8'
|
||||
compile project(':http-api')
|
||||
compile group: 'com.google.guava', name: 'guava', version: '28.0-jre'
|
||||
compile group: 'org.slf4j', name: 'slf4j-api', version: '1.7.26'
|
||||
compile group: 'org.apache.commons', name: 'commons-compress', version: '1.18'
|
||||
compile group: 'com.google.code.gson', name: 'gson', version: '2.8.5'
|
||||
compile group: 'io.netty', name: 'netty-buffer', version: '4.1.37.Final'
|
||||
compile group: 'org.antlr', name: 'antlr4-runtime', version: '4.7.2'
|
||||
compile group: 'commons-cli', name: 'commons-cli', version: '1.4'
|
||||
testCompile group: 'junit', name: 'junit', version: '4.12'
|
||||
testCompile group: 'org.slf4j', name: 'slf4j-simple', version: '1.7.26'
|
||||
testCompile group: 'net.runelite.rs', name: 'cache', version: '165'
|
||||
compileOnly group: 'org.projectlombok', name: 'lombok', version: '1.18.8'
|
||||
annotationProcessor group: 'org.projectlombok', name: 'lombok', version: '1.18.8'
|
||||
}
|
||||
|
||||
task packageTests(type: Jar) {
|
||||
from sourceSets.test.output
|
||||
classifier = 'tests'
|
||||
from sourceSets.test.output
|
||||
classifier = 'tests'
|
||||
}
|
||||
artifacts.archives packageTests
|
||||
|
||||
@@ -1,22 +1,21 @@
|
||||
|
||||
description = 'Deobfuscator'
|
||||
dependencies {
|
||||
compile project(':runelite-api')
|
||||
compile project(':runescape-api')
|
||||
compile group: 'net.runelite', name: 'fernflower', version:'20171017'
|
||||
compile group: 'com.google.guava', name: 'guava', version:'28.0-jre'
|
||||
compile group: 'org.slf4j', name: 'slf4j-api', version:'1.7.25'
|
||||
compile group: 'com.google.code.gson', name: 'gson', version:'2.8.5'
|
||||
compile group: 'org.ow2.asm', name: 'asm-debug-all', version:'5.2'
|
||||
runtime group: 'org.slf4j', name: 'slf4j-simple', version:'1.7.26'
|
||||
testCompile project(':rs-client')
|
||||
testCompile group: 'net.runelite.rs', name: 'vanilla', version:'181'
|
||||
testCompile group: 'junit', name: 'junit', version:'4.12'
|
||||
testCompile group: 'org.mockito', name: 'mockito-all', version:'1.10.19'
|
||||
compile project(':runelite-api')
|
||||
compile project(':runescape-api')
|
||||
compile group: 'net.runelite', name: 'fernflower', version: '20171017'
|
||||
compile group: 'com.google.guava', name: 'guava', version: '28.0-jre'
|
||||
compile group: 'org.slf4j', name: 'slf4j-api', version: '1.7.26'
|
||||
compile group: 'com.google.code.gson', name: 'gson', version: '2.8.5'
|
||||
compile group: 'org.ow2.asm', name: 'asm-debug-all', version: '5.2'
|
||||
runtime group: 'org.slf4j', name: 'slf4j-simple', version: '1.7.26'
|
||||
testCompile project(':rs-client')
|
||||
testCompile group: 'net.runelite.rs', name: 'vanilla', version: '181'
|
||||
testCompile group: 'junit', name: 'junit', version: '4.12'
|
||||
testCompile group: 'org.mockito', name: 'mockito-all', version: '1.10.19'
|
||||
}
|
||||
|
||||
task packageTests(type: Jar) {
|
||||
from sourceSets.test.output
|
||||
classifier = 'tests'
|
||||
from sourceSets.test.output
|
||||
classifier = 'tests'
|
||||
}
|
||||
artifacts.archives packageTests
|
||||
|
||||
6
gradle.properties
Normal file
6
gradle.properties
Normal file
@@ -0,0 +1,6 @@
|
||||
org.gradle.caching=true
|
||||
org.gradle.warning.mode=all
|
||||
org.gradle.parallel=true
|
||||
org.gradle.console=rich
|
||||
org.gradle.configureondemand=true
|
||||
org.gradle.jvmargs=-Xmx4096m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
|
||||
BIN
gradle/wrapper/gradle-wrapper.jar
vendored
BIN
gradle/wrapper/gradle-wrapper.jar
vendored
Binary file not shown.
2
gradle/wrapper/gradle-wrapper.properties
vendored
2
gradle/wrapper/gradle-wrapper.properties
vendored
@@ -1,5 +1,5 @@
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-4.10.3-bin.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-5.5.1-bin.zip
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
zipStorePath=wrapper/dists
|
||||
|
||||
18
gradlew
vendored
Normal file → Executable file
18
gradlew
vendored
Normal file → Executable file
@@ -1,5 +1,21 @@
|
||||
#!/usr/bin/env sh
|
||||
|
||||
#
|
||||
# Copyright 2015 the original author or authors.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# https://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
|
||||
##############################################################################
|
||||
##
|
||||
## Gradle start up script for UN*X
|
||||
@@ -28,7 +44,7 @@ APP_NAME="Gradle"
|
||||
APP_BASE_NAME=`basename "$0"`
|
||||
|
||||
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
||||
DEFAULT_JVM_OPTS=""
|
||||
DEFAULT_JVM_OPTS='"-Xmx4g" "-Xms2g" "-Dfile.encoding=UTF-8"'
|
||||
|
||||
# Use the maximum available, or set MAX_FD != -1 to use that value.
|
||||
MAX_FD="maximum"
|
||||
|
||||
18
gradlew.bat
vendored
18
gradlew.bat
vendored
@@ -1,3 +1,19 @@
|
||||
@rem
|
||||
@rem Copyright 2015 the original author or authors.
|
||||
@rem
|
||||
@rem Licensed under the Apache License, Version 2.0 (the "License");
|
||||
@rem you may not use this file except in compliance with the License.
|
||||
@rem You may obtain a copy of the License at
|
||||
@rem
|
||||
@rem https://www.apache.org/licenses/LICENSE-2.0
|
||||
@rem
|
||||
@rem Unless required by applicable law or agreed to in writing, software
|
||||
@rem distributed under the License is distributed on an "AS IS" BASIS,
|
||||
@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
@rem See the License for the specific language governing permissions and
|
||||
@rem limitations under the License.
|
||||
@rem
|
||||
|
||||
@if "%DEBUG%" == "" @echo off
|
||||
@rem ##########################################################################
|
||||
@rem
|
||||
@@ -14,7 +30,7 @@ set APP_BASE_NAME=%~n0
|
||||
set APP_HOME=%DIRNAME%
|
||||
|
||||
@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
||||
set DEFAULT_JVM_OPTS=
|
||||
set DEFAULT_JVM_OPTS="-Xmx4g" "-Xms2g" "-Dfile.encoding=UTF-8"
|
||||
|
||||
@rem Find java.exe
|
||||
if defined JAVA_HOME goto findJavaFromJavaHome
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
|
||||
description = 'Web API'
|
||||
dependencies {
|
||||
compile group: 'com.squareup.okhttp3', name: 'okhttp', version:'3.14.0'
|
||||
compile group: 'com.google.code.gson', name: 'gson', version:'2.8.5'
|
||||
compile group: 'org.slf4j', name: 'slf4j-api', version:'1.7.25'
|
||||
compile group: 'org.apache.commons', name: 'commons-csv', version:'1.4'
|
||||
compile group: 'io.reactivex.rxjava2', name: 'rxjava', version:'2.2.10'
|
||||
testCompile group: 'junit', name: 'junit', version:'4.12'
|
||||
testCompile group: 'org.slf4j', name: 'slf4j-simple', version:'1.7.26'
|
||||
testCompile group: 'com.squareup.okhttp3', name: 'mockwebserver', version:'3.14.0'
|
||||
compileOnly group: 'org.projectlombok', name: 'lombok', version:'1.18.8'
|
||||
compile group: 'com.squareup.okhttp3', name: 'okhttp', version: '4.0.1'
|
||||
compile group: 'com.google.code.gson', name: 'gson', version: '2.8.5'
|
||||
compile group: 'org.slf4j', name: 'slf4j-api', version: '1.7.26'
|
||||
compile group: 'org.apache.commons', name: 'commons-csv', version: '1.7'
|
||||
compile group: 'io.reactivex.rxjava2', name: 'rxjava', version: '2.2.10'
|
||||
testCompile group: 'junit', name: 'junit', version: '4.12'
|
||||
testCompile group: 'org.slf4j', name: 'slf4j-simple', version: '1.7.26'
|
||||
testCompile group: 'com.squareup.okhttp3', name: 'mockwebserver', version: '4.0.1'
|
||||
compileOnly group: 'org.projectlombok', name: 'lombok', version: '1.18.8'
|
||||
annotationProcessor group: 'org.projectlombok', name: 'lombok', version: '1.18.8'
|
||||
}
|
||||
|
||||
@@ -61,6 +61,7 @@ public class DiscordEmbed
|
||||
VideoEmbed video;
|
||||
ProviderEmbed provider;
|
||||
AuthorEmbed author;
|
||||
@Builder.Default
|
||||
List<FieldEmbed> fields = new ArrayList<>();
|
||||
|
||||
public DiscordEmbed()
|
||||
|
||||
@@ -48,6 +48,7 @@ public class DiscordMessage
|
||||
String avatarUrl;
|
||||
@SerializedName("tts")
|
||||
boolean textToSpeech;
|
||||
@Builder.Default
|
||||
List<DiscordEmbed> embeds = new ArrayList<>();
|
||||
|
||||
public DiscordMessage()
|
||||
|
||||
@@ -1,28 +1,28 @@
|
||||
|
||||
apply plugin: 'war'
|
||||
|
||||
description = 'Web Service'
|
||||
dependencies {
|
||||
compile group: 'org.springframework.boot', name: 'spring-boot-starter-web', version:'1.5.6.RELEASE'
|
||||
compile group: 'org.springframework.boot', name: 'spring-boot-devtools', version:'1.5.6.RELEASE'
|
||||
compile group: 'org.springframework', name: 'spring-jdbc', version:'4.3.10.RELEASE'
|
||||
compile group: 'org.mapstruct', name: 'mapstruct-jdk8', version:'1.2.0.Final'
|
||||
compile project(':http-api')
|
||||
compile project(':cache')
|
||||
compile group: 'org.sql2o', name: 'sql2o', version:'1.6.0'
|
||||
compile group: 'com.google.guava', name: 'guava', version:'28.0-jre'
|
||||
compile group: 'org.slf4j', name: 'slf4j-api', version:'1.7.25'
|
||||
compile group: 'com.github.scribejava', name: 'scribejava-apis', version:'6.6.3'
|
||||
compile group: 'io.minio', name: 'minio', version:'3.0.6'
|
||||
compile(group: 'redis.clients', name: 'jedis', version:'3.0.1') {
|
||||
exclude(module: 'commons-pool2')
|
||||
compile group: 'org.springframework.boot', name: 'spring-boot-starter-web', version: '2.1.6.RELEASE'
|
||||
compile group: 'org.springframework.boot', name: 'spring-boot-devtools', version: '2.1.6.RELEASE'
|
||||
compile group: 'org.springframework', name: 'spring-jdbc', version: '5.1.8.RELEASE'
|
||||
compile group: 'org.mapstruct', name: 'mapstruct-jdk8', version: '1.3.0.Final'
|
||||
compile project(':http-api')
|
||||
compile project(':cache')
|
||||
compile group: 'org.sql2o', name: 'sql2o', version: '1.6.0'
|
||||
compile group: 'com.google.guava', name: 'guava', version: '28.0-jre'
|
||||
compile group: 'org.slf4j', name: 'slf4j-api', version: '1.7.26'
|
||||
compile group: 'com.github.scribejava', name: 'scribejava-apis', version: '6.7.0'
|
||||
compile group: 'io.minio', name: 'minio', version: '6.0.8'
|
||||
compile(group: 'redis.clients', name: 'jedis', version: '3.1.0') {
|
||||
exclude(module: 'commons-pool2')
|
||||
}
|
||||
testCompile(group: 'org.springframework.boot', name: 'spring-boot-starter-test', version:'1.5.6.RELEASE') {
|
||||
exclude(module: 'commons-logging')
|
||||
testCompile(group: 'org.springframework.boot', name: 'spring-boot-starter-test', version: '2.1.6.RELEASE') {
|
||||
exclude(module: 'commons-logging')
|
||||
}
|
||||
testCompile group: 'com.squareup.okhttp3', name: 'mockwebserver', version:'3.14.0'
|
||||
testCompile group: 'com.h2database', name: 'h2', version:'1.4.196'
|
||||
providedCompile group: 'org.springframework.boot', name: 'spring-boot-starter-tomcat', version:'1.5.6.RELEASE'
|
||||
providedCompile group: 'org.projectlombok', name: 'lombok', version:'1.18.8'
|
||||
providedCompile group: 'org.mariadb.jdbc', name: 'mariadb-java-client', version:'2.4.2'
|
||||
testCompile group: 'com.squareup.okhttp3', name: 'mockwebserver', version: '4.0.1'
|
||||
testCompile group: 'com.h2database', name: 'h2', version: '1.4.199'
|
||||
providedCompile group: 'org.springframework.boot', name: 'spring-boot-starter-tomcat', version: '2.1.6.RELEASE'
|
||||
providedCompile group: 'org.projectlombok', name: 'lombok', version: '1.18.8'
|
||||
annotationProcessor group: 'org.projectlombok', name: 'lombok', version: '1.18.8'
|
||||
providedCompile group: 'org.mariadb.jdbc', name: 'mariadb-java-client', version: '2.4.2'
|
||||
}
|
||||
|
||||
@@ -49,7 +49,7 @@ import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;
|
||||
import org.springframework.boot.autoconfigure.jdbc.DataSourceProperties;
|
||||
import org.springframework.boot.builder.SpringApplicationBuilder;
|
||||
import org.springframework.boot.context.properties.ConfigurationProperties;
|
||||
import org.springframework.boot.web.support.SpringBootServletInitializer;
|
||||
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.jdbc.datasource.lookup.JndiDataSourceLookup;
|
||||
import org.springframework.scheduling.annotation.EnableScheduling;
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
|
||||
description = 'Injected Client'
|
||||
dependencies {
|
||||
compile project(':rs-client')
|
||||
compile group: 'net.runelite.rs', name: 'vanilla', version:'181'
|
||||
compile project(':rs-client')
|
||||
compile group: 'net.runelite.rs', name: 'vanilla', version: '181'
|
||||
}
|
||||
|
||||
@@ -1,24 +1,45 @@
|
||||
group = 'net.runelite.rs'
|
||||
description = 'Injector'
|
||||
|
||||
def osrsRevision = 181
|
||||
def deobfuscatedJar = "${project.rootDir}/runescape-client/build/libs/rs-client-"+project.version+".jar"
|
||||
def vanillaJar = "$buildDir/vanilla-"+osrsRevision+".jar"
|
||||
def injectedJar = "${project.rootDir}/injected-client/build/libs/injected-client-"+project.version+".jar"
|
||||
|
||||
configurations {
|
||||
vanilla
|
||||
}
|
||||
|
||||
dependencies {
|
||||
compile project(':deobfuscator')
|
||||
compile project(':mixins')
|
||||
compile project(':runelite-api')
|
||||
compile project(':runescape-api')
|
||||
compile group: 'org.apache.maven', name: 'maven-plugin-api', version:'3.6.1'
|
||||
testCompile project(':deobfuscator')
|
||||
testCompile group: 'junit', name: 'junit', version:'4.12'
|
||||
testCompile group: 'org.mockito', name: 'mockito-all', version:'1.10.19'
|
||||
compileOnly group: 'org.apache.maven.plugin-tools', name: 'maven-plugin-annotations', version:'3.6.0'
|
||||
compile project(':deobfuscator')
|
||||
compile project(':mixins')
|
||||
compile project(':runelite-api')
|
||||
compile project(':runescape-api')
|
||||
compile project(':rs-client')
|
||||
compile project(':injected-client')
|
||||
compile group: 'org.apache.maven', name: 'maven-plugin-api', version: '3.6.1'
|
||||
testCompile project(':deobfuscator')
|
||||
testCompile group: 'junit', name: 'junit', version: '4.12'
|
||||
testCompile group: 'org.mockito', name: 'mockito-all', version: '1.10.19'
|
||||
compileOnly group: 'org.apache.maven.plugin-tools', name: 'maven-plugin-annotations', version: '3.6.0'
|
||||
annotationProcessor group: 'org.eclipse.sisu', name: 'org.eclipse.sisu.inject', version: '0.3.3'
|
||||
vanilla "net.runelite.rs:vanilla:"+osrsRevision
|
||||
}
|
||||
|
||||
task inject(type:JavaExec) {
|
||||
classpath = sourceSets.main.runtimeClasspath
|
||||
compileJava.outputs.upToDateWhen {false}
|
||||
|
||||
main = "net.runelite.injector.Injector"
|
||||
args('../runescape-client/build/libs/rs-client-1.5.30-SNAPSHOT.jar,./vanilla-181.jar,../injected-client/build/libs/injected-client-1.5.30-SNAPSHOT.jar'.split(','))
|
||||
}
|
||||
|
||||
compileJava.doLast {
|
||||
tasks.inject.execute()
|
||||
compileJava.doLast() {
|
||||
copy {
|
||||
from configurations.vanilla
|
||||
into "$buildDir"
|
||||
}
|
||||
def path = sourceSets.main.runtimeClasspath
|
||||
def loader = new URLClassLoader(path.collect { f -> f.toURL() } as URL[])
|
||||
def inject = loader.loadClass('net.runelite.injector.Injector')
|
||||
String[] jarPaths = [
|
||||
deobfuscatedJar,
|
||||
vanillaJar,
|
||||
injectedJar
|
||||
]
|
||||
inject.main(jarPaths)
|
||||
}
|
||||
@@ -1,9 +1,9 @@
|
||||
|
||||
description = 'Protocol API'
|
||||
dependencies {
|
||||
compile project(':runelite-api')
|
||||
compile group: 'org.slf4j', name: 'slf4j-api', version:'1.7.25'
|
||||
compile group: 'com.google.guava', name: 'guava', version:'28.0-jre'
|
||||
testCompile group: 'junit', name: 'junit', version:'4.12'
|
||||
compileOnly group: 'org.projectlombok', name: 'lombok', version:'1.18.8'
|
||||
compile project(':runelite-api')
|
||||
compile group: 'org.slf4j', name: 'slf4j-api', version: '1.7.26'
|
||||
compile group: 'com.google.guava', name: 'guava', version: '28.0-jre'
|
||||
testCompile group: 'junit', name: 'junit', version: '4.12'
|
||||
compileOnly group: 'org.projectlombok', name: 'lombok', version: '1.18.8'
|
||||
annotationProcessor group: 'org.projectlombok', name: 'lombok', version: '1.18.8'
|
||||
}
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
|
||||
description = 'Protocol'
|
||||
dependencies {
|
||||
compile project(':protocol-api')
|
||||
compile project(':cache')
|
||||
compile group: 'com.google.guava', name: 'guava', version:'28.0-jre'
|
||||
compile group: 'io.netty', name: 'netty-all', version:'4.1.37.Final'
|
||||
testCompile group: 'junit', name: 'junit', version:'4.12'
|
||||
compileOnly group: 'org.projectlombok', name: 'lombok', version:'1.18.8'
|
||||
compile project(':protocol-api')
|
||||
compile project(':cache')
|
||||
compile group: 'com.google.guava', name: 'guava', version: '28.0-jre'
|
||||
compile group: 'io.netty', name: 'netty-all', version: '4.1.37.Final'
|
||||
testCompile group: 'junit', name: 'junit', version: '4.12'
|
||||
compileOnly group: 'org.projectlombok', name: 'lombok', version: '1.18.8'
|
||||
annotationProcessor group: 'org.projectlombok', name: 'lombok', version: '1.18.8'
|
||||
}
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
|
||||
description = 'RuneLite API'
|
||||
dependencies {
|
||||
compile group: 'org.slf4j', name: 'slf4j-api', version:'1.7.25'
|
||||
compile group: 'com.google.code.findbugs', name: 'jsr305', version:'3.0.2'
|
||||
testCompile group: 'junit', name: 'junit', version:'4.12'
|
||||
compileOnly group: 'org.projectlombok', name: 'lombok', version:'1.18.8'
|
||||
compile group: 'org.slf4j', name: 'slf4j-api', version: '1.7.26'
|
||||
compile group: 'com.google.code.findbugs', name: 'jsr305', version: '3.0.2'
|
||||
testCompile group: 'junit', name: 'junit', version: '4.12'
|
||||
compileOnly group: 'org.projectlombok', name: 'lombok', version: '1.18.8'
|
||||
annotationProcessor group: 'org.projectlombok', name: 'lombok', version: '1.18.8'
|
||||
}
|
||||
|
||||
@@ -1,49 +1,72 @@
|
||||
plugins {
|
||||
id 'com.github.johnrengelman.shadow' version '5.1.0'
|
||||
id 'java'
|
||||
}
|
||||
|
||||
description = 'RuneLite Client'
|
||||
|
||||
dependencies {
|
||||
compile group: 'org.slf4j', name: 'slf4j-api', version:'1.7.25'
|
||||
compile group: 'ch.qos.logback', name: 'logback-classic', version:'1.2.3'
|
||||
compile group: 'net.sf.jopt-simple', name: 'jopt-simple', version:'5.0.1'
|
||||
compile group: 'com.google.guava', name: 'guava', version:'28.0-jre'
|
||||
compile group: 'com.google.inject', name: 'guice', version:'4.1.0', classifier:'no_aop'
|
||||
compile group: 'com.google.code.gson', name: 'gson', version:'2.8.5'
|
||||
compile group: 'net.runelite.pushingpixels', name: 'substance', version:'8.0.02'
|
||||
compile group: 'org.apache.commons', name: 'commons-text', version:'1.2'
|
||||
compile group: 'org.jogamp.jogl', name: 'jogl-all', version:'2.3.2'
|
||||
compile group: 'org.jogamp.gluegen', name: 'gluegen-rt', version:'2.3.2'
|
||||
compile(group: 'io.sigpipe', name: 'jbsdiff', version:'1.0') {
|
||||
exclude(module: 'xz')
|
||||
compile group: 'org.slf4j', name: 'slf4j-api', version: '1.7.26'
|
||||
compile group: 'ch.qos.logback', name: 'logback-classic', version: '1.2.3'
|
||||
compile group: 'net.sf.jopt-simple', name: 'jopt-simple', version: '5.0.4'
|
||||
compile group: 'com.google.guava', name: 'guava', version: '28.0-jre'
|
||||
compile group: 'com.google.inject', name: 'guice', version: '4.2.2', classifier: 'no_aop'
|
||||
compile group: 'com.google.code.gson', name: 'gson', version: '2.8.5'
|
||||
compile group: 'net.runelite.pushingpixels', name: 'substance', version: '8.0.02'
|
||||
compile group: 'org.apache.commons', name: 'commons-text', version: '1.7'
|
||||
compile group: 'org.jogamp.jogl', name: 'jogl-all', version: '2.3.2'
|
||||
compile group: 'org.jogamp.gluegen', name: 'gluegen-rt', version: '2.3.2'
|
||||
compile(group: 'io.sigpipe', name: 'jbsdiff', version: '1.0') {
|
||||
exclude(module: 'xz')
|
||||
}
|
||||
compile group: 'net.java.dev.jna', name: 'jna', version:'4.5.1'
|
||||
compile group: 'net.java.dev.jna', name: 'jna-platform', version:'4.5.1'
|
||||
compile project(':runelite-api')
|
||||
compile project(':http-api')
|
||||
compile group: 'net.runelite', name: 'discord', version:'1.1'
|
||||
compile group: 'org.javassist', name: 'javassist', version:'3.25.0-GA'
|
||||
compile group: 'org.xeustechnologies', name: 'jcl-core', version:'2.8'
|
||||
compile group: 'org.jetbrains', name: 'annotations', version:'17.0.0'
|
||||
compile group: 'com.github.joonasvali.naturalmouse', name: 'naturalmouse', version:'[1.0.0,)'
|
||||
compile group: 'org.ow2.asm', name: 'asm-all', version:'6.0_BETA'
|
||||
compile group: 'org.codehaus.plexus', name: 'plexus-utils', version:'3.2.0'
|
||||
compile group: 'org.apache.httpcomponents', name: 'httpcore', version:'4.4.11'
|
||||
compile group: 'org.apache.httpcomponents', name: 'httpmime', version:'4.5.9'
|
||||
compile group: 'io.reactivex.rxjava2', name: 'rxjava', version:'2.2.10'
|
||||
compile group: 'com.jakewharton.rxrelay2', name: 'rxrelay', version:'2.1.0'
|
||||
runtime group: 'net.runelite.pushingpixels', name: 'trident', version:'1.5.00'
|
||||
runtime group: 'org.jogamp.jogl', name: 'jogl-all', version:'2.3.2', classifier:'natives-windows-amd64'
|
||||
runtime group: 'org.jogamp.jogl', name: 'jogl-all', version:'2.3.2', classifier:'natives-windows-i586'
|
||||
runtime group: 'org.jogamp.jogl', name: 'jogl-all', version:'2.3.2', classifier:'natives-linux-amd64'
|
||||
runtime group: 'org.jogamp.jogl', name: 'jogl-all', version:'2.3.2', classifier:'natives-linux-i586'
|
||||
runtime group: 'org.jogamp.gluegen', name: 'gluegen-rt', version:'2.3.2', classifier:'natives-windows-amd64'
|
||||
runtime group: 'org.jogamp.gluegen', name: 'gluegen-rt', version:'2.3.2', classifier:'natives-windows-i586'
|
||||
runtime group: 'org.jogamp.gluegen', name: 'gluegen-rt', version:'2.3.2', classifier:'natives-linux-amd64'
|
||||
runtime group: 'org.jogamp.gluegen', name: 'gluegen-rt', version:'2.3.2', classifier:'natives-linux-i586'
|
||||
runtime project(':runescape-api')
|
||||
testCompile group: 'junit', name: 'junit', version:'4.12'
|
||||
testCompile group: 'org.hamcrest', name: 'hamcrest-library', version:'1.3'
|
||||
testCompile group: 'org.mockito', name: 'mockito-all', version:'1.10.19'
|
||||
testCompile group: 'com.google.inject.extensions', name: 'guice-testlib', version:'4.1.0'
|
||||
testCompile group: 'com.google.inject.extensions', name: 'guice-grapher', version:'4.1.0'
|
||||
compileOnly group: 'org.projectlombok', name: 'lombok', version:'1.18.8'
|
||||
compileOnly group: 'net.runelite', name: 'orange-extensions', version:'1.0'
|
||||
compile group: 'net.java.dev.jna', name: 'jna', version: '5.4.0'
|
||||
compile group: 'net.java.dev.jna', name: 'jna-platform', version: '5.4.0'
|
||||
compile project(':runelite-api')
|
||||
compile project(':http-api')
|
||||
compile group: 'net.runelite', name: 'discord', version: '1.1'
|
||||
compile group: 'org.javassist', name: 'javassist', version: '3.25.0-GA'
|
||||
compile group: 'org.xeustechnologies', name: 'jcl-core', version: '2.8'
|
||||
compile group: 'org.jetbrains', name: 'annotations', version: '17.0.0'
|
||||
compile group: 'com.github.joonasvali.naturalmouse', name: 'naturalmouse', version: '[1.0.0,)'
|
||||
compile group: 'org.ow2.asm', name: 'asm-all', version: '6.0_BETA'
|
||||
compile group: 'org.codehaus.plexus', name: 'plexus-utils', version: '3.2.1'
|
||||
compile group: 'org.apache.httpcomponents', name: 'httpcore', version: '4.4.11'
|
||||
compile group: 'org.apache.httpcomponents', name: 'httpmime', version: '4.5.9'
|
||||
compile group: 'io.reactivex.rxjava2', name: 'rxjava', version: '2.2.10'
|
||||
compile group: 'com.jakewharton.rxrelay2', name: 'rxrelay', version: '2.1.0'
|
||||
runtime group: 'net.runelite.pushingpixels', name: 'trident', version: '1.5.00'
|
||||
runtime group: 'org.jogamp.jogl', name: 'jogl-all', version: '2.3.2', classifier: 'natives-windows-amd64'
|
||||
runtime group: 'org.jogamp.jogl', name: 'jogl-all', version: '2.3.2', classifier: 'natives-windows-i586'
|
||||
runtime group: 'org.jogamp.jogl', name: 'jogl-all', version: '2.3.2', classifier: 'natives-linux-amd64'
|
||||
runtime group: 'org.jogamp.jogl', name: 'jogl-all', version: '2.3.2', classifier: 'natives-linux-i586'
|
||||
runtime group: 'org.jogamp.gluegen', name: 'gluegen-rt', version: '2.3.2', classifier: 'natives-windows-amd64'
|
||||
runtime group: 'org.jogamp.gluegen', name: 'gluegen-rt', version: '2.3.2', classifier: 'natives-windows-i586'
|
||||
runtime group: 'org.jogamp.gluegen', name: 'gluegen-rt', version: '2.3.2', classifier: 'natives-linux-amd64'
|
||||
runtime group: 'org.jogamp.gluegen', name: 'gluegen-rt', version: '2.3.2', classifier: 'natives-linux-i586'
|
||||
runtime project(':runescape-api')
|
||||
testCompile group: 'junit', name: 'junit', version: '4.12'
|
||||
testCompile group: 'org.hamcrest', name: 'hamcrest-library', version: '2.1'
|
||||
testCompile group: 'org.mockito', name: 'mockito-all', version: '1.10.19'
|
||||
testCompile group: 'com.google.inject.extensions', name: 'guice-testlib', version: '4.2.2'
|
||||
testCompile group: 'com.google.inject.extensions', name: 'guice-grapher', version: '4.2.2'
|
||||
compileOnly group: 'org.projectlombok', name: 'lombok', version: '1.18.8'
|
||||
annotationProcessor group: 'org.projectlombok', name: 'lombok', version: '1.18.8'
|
||||
compileOnly group: 'net.runelite', name: 'orange-extensions', version: '1.0'
|
||||
}
|
||||
|
||||
tasks.withType(AbstractArchiveTask) {
|
||||
preserveFileTimestamps = false
|
||||
reproducibleFileOrder = true
|
||||
}
|
||||
|
||||
jar {
|
||||
manifest {
|
||||
attributes 'Main-Class': 'net.runelite.client.RuneLite'
|
||||
}
|
||||
}
|
||||
|
||||
shadowJar {
|
||||
classifier = "shaded"
|
||||
}
|
||||
|
||||
tasks.build.dependsOn tasks.shadowJar
|
||||
@@ -26,12 +26,14 @@ package net.runelite.client.plugins.tmorph;
|
||||
import com.google.inject.Provides;
|
||||
import javax.inject.Inject;
|
||||
import javax.inject.Singleton;
|
||||
import net.runelite.api.Actor;
|
||||
import net.runelite.api.Client;
|
||||
import net.runelite.api.GameState;
|
||||
import net.runelite.api.Player;
|
||||
import net.runelite.api.events.AnimationChanged;
|
||||
import net.runelite.api.events.ConfigChanged;
|
||||
import net.runelite.api.events.GameTick;
|
||||
import net.runelite.api.events.SpotAnimationChanged;
|
||||
import net.runelite.api.kit.KitType;
|
||||
import net.runelite.api.widgets.WidgetInfo;
|
||||
import net.runelite.client.config.ConfigManager;
|
||||
@@ -61,65 +63,68 @@ public class TMorph extends Plugin
|
||||
private EventBus eventBus;
|
||||
|
||||
private boolean mageSwap;
|
||||
private boolean rangeSwap;
|
||||
private boolean meleeSwap;
|
||||
private boolean rangeSwap;
|
||||
private int animation;
|
||||
private int bodyMage;
|
||||
private int bodyMelee;
|
||||
private int bodyRange;
|
||||
private int bootsMage;
|
||||
private int bootsMelee;
|
||||
private int bootsRange;
|
||||
private int capeMage;
|
||||
private int capeMelee;
|
||||
private int capeRange;
|
||||
private int globalAnimSwap;
|
||||
private int animationSwap;
|
||||
private int animationTarget;
|
||||
private int MainhandMage;
|
||||
private int targetMainhandMage;
|
||||
private int OffhandMage;
|
||||
private int targetOffhandMage;
|
||||
private int HelmetMage;
|
||||
private int targetHelmetMage;
|
||||
private int CapeMage;
|
||||
private int targetCapeMage;
|
||||
private int NeckMage;
|
||||
private int targetNeckMage;
|
||||
private int BodyMage;
|
||||
private int globalGraphicSwap;
|
||||
private int glovesMage;
|
||||
private int glovesMelee;
|
||||
private int glovesRange;
|
||||
private int graphic;
|
||||
private int helmetMage;
|
||||
private int helmetMelee;
|
||||
private int helmetRange;
|
||||
private int legsMage;
|
||||
private int legsMelee;
|
||||
private int legsRange;
|
||||
private int mainhandMage;
|
||||
private int mainhandMelee;
|
||||
private int mainhandRange;
|
||||
private int neckMage;
|
||||
private int neckMelee;
|
||||
private int neckRange;
|
||||
private int offhandMage;
|
||||
private int offhandMelee;
|
||||
private int offhandRange;
|
||||
private int targetAnimation;
|
||||
private int targetBodyMage;
|
||||
private int LegsMage;
|
||||
private int targetLegsMage;
|
||||
private int BootsMage;
|
||||
private int targetBootsMage;
|
||||
private int GlovesMage;
|
||||
private int targetGlovesMage;
|
||||
private int MainhandRange;
|
||||
private int targetMainhandRange;
|
||||
private int OffhandRange;
|
||||
private int targetOffhandRange;
|
||||
private int HelmetRange;
|
||||
private int targetHelmetRange;
|
||||
private int CapeRange;
|
||||
private int targetCapeRange;
|
||||
private int NeckRange;
|
||||
private int targetNeckRange;
|
||||
private int BodyRange;
|
||||
private int targetBodyRange;
|
||||
private int LegsRange;
|
||||
private int targetLegsRange;
|
||||
private int BootsRange;
|
||||
private int targetBootsRange;
|
||||
private int GlovesRange;
|
||||
private int targetGlovesRange;
|
||||
private int MainhandMelee;
|
||||
private int targetMainhandMelee;
|
||||
private int OffhandMelee;
|
||||
private int targetOffhandMelee;
|
||||
private int HelmetMelee;
|
||||
private int targetHelmetMelee;
|
||||
private int CapeMelee;
|
||||
private int targetCapeMelee;
|
||||
private int NeckMelee;
|
||||
private int targetNeckMelee;
|
||||
private int BodyMelee;
|
||||
private int targetBodyMelee;
|
||||
private int LegsMelee;
|
||||
private int targetLegsMelee;
|
||||
private int BootsMelee;
|
||||
private int targetBodyRange;
|
||||
private int targetBootsMage;
|
||||
private int targetBootsMelee;
|
||||
private int GlovesMelee;
|
||||
private int targetBootsRange;
|
||||
private int targetCapeMage;
|
||||
private int targetCapeMelee;
|
||||
private int targetCapeRange;
|
||||
private int targetGlovesMage;
|
||||
private int targetGlovesMelee;
|
||||
private int targetGlovesRange;
|
||||
private int targetGraphic;
|
||||
private int targetHelmetMage;
|
||||
private int targetHelmetMelee;
|
||||
private int targetHelmetRange;
|
||||
private int targetLegsMage;
|
||||
private int targetLegsMelee;
|
||||
private int targetLegsRange;
|
||||
private int targetMainhandMage;
|
||||
private int targetMainhandMelee;
|
||||
private int targetMainhandRange;
|
||||
private int targetNeckMage;
|
||||
private int targetNeckMelee;
|
||||
private int targetNeckRange;
|
||||
private int targetOffhandMage;
|
||||
private int targetOffhandMelee;
|
||||
private int targetOffhandRange;
|
||||
|
||||
@Provides
|
||||
TMorphConfig provideConfig(ConfigManager configManager)
|
||||
@@ -145,6 +150,7 @@ public class TMorph extends Plugin
|
||||
eventBus.subscribe(ConfigChanged.class, this, this::onConfigChanged);
|
||||
eventBus.subscribe(AnimationChanged.class, this, this::onAnimationChanged);
|
||||
eventBus.subscribe(GameTick.class, this, this::onGameTick);
|
||||
eventBus.subscribe(SpotAnimationChanged.class, this, this::onSpotAnimationChanged);
|
||||
}
|
||||
|
||||
private void onConfigChanged(ConfigChanged event)
|
||||
@@ -155,20 +161,46 @@ public class TMorph extends Plugin
|
||||
}
|
||||
}
|
||||
|
||||
private void onAnimationChanged(AnimationChanged event)
|
||||
private void onSpotAnimationChanged(SpotAnimationChanged event)
|
||||
{
|
||||
if (this.animationTarget <= 0 && this.animationSwap <= 0 && this.globalAnimSwap > 0)
|
||||
final Actor actor = event.getActor();
|
||||
|
||||
if (actor.getSpotAnimation() == -1)
|
||||
{
|
||||
if (event.getActor().getAnimation() != -1)
|
||||
return;
|
||||
}
|
||||
|
||||
if (this.graphic <= 0 && this.targetGraphic <= 0 && this.globalGraphicSwap > 0)
|
||||
{
|
||||
actor.setSpotAnimation(this.globalGraphicSwap);
|
||||
}
|
||||
if (this.graphic > 0 && this.targetGraphic > 0)
|
||||
{
|
||||
if (actor.getSpotAnimation() == this.targetGraphic)
|
||||
{
|
||||
event.getActor().setAnimation(this.globalAnimSwap);
|
||||
actor.setSpotAnimation(this.graphic);
|
||||
}
|
||||
}
|
||||
if (this.animationTarget > 0 && this.animationSwap > 0)
|
||||
}
|
||||
|
||||
private void onAnimationChanged(AnimationChanged event)
|
||||
{
|
||||
final Actor actor = event.getActor();
|
||||
|
||||
if (actor.getAnimation() != -1)
|
||||
{
|
||||
if (event.getActor().getAnimation() == this.animationTarget)
|
||||
return;
|
||||
}
|
||||
|
||||
if (this.targetAnimation <= 0 && this.animation <= 0 && this.globalAnimSwap > 0)
|
||||
{
|
||||
actor.setAnimation(this.globalAnimSwap);
|
||||
}
|
||||
if (this.targetAnimation > 0 && this.animation > 0)
|
||||
{
|
||||
if (actor.getAnimation() == this.targetAnimation)
|
||||
{
|
||||
event.getActor().setAnimation(this.animationSwap);
|
||||
actor.setAnimation(this.animation);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -179,6 +211,7 @@ public class TMorph extends Plugin
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
updateEquip();
|
||||
}
|
||||
|
||||
@@ -215,279 +248,279 @@ public class TMorph extends Plugin
|
||||
|
||||
if (this.mageSwap)
|
||||
{
|
||||
if (this.MainhandMage > 0)
|
||||
if (this.mainhandMage > 0)
|
||||
{
|
||||
if (this.targetMainhandMage > 0)
|
||||
{
|
||||
if (mainhandID == this.targetMainhandMage)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.WEAPON.getIndex()] = this.MainhandMage + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.WEAPON.getIndex()] = this.mainhandMage + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.OffhandMage > 0)
|
||||
if (this.offhandMage > 0)
|
||||
{
|
||||
if (this.targetOffhandMage > 0)
|
||||
{
|
||||
if (offhandID == this.targetOffhandMage)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.SHIELD.getIndex()] = this.OffhandMage + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.SHIELD.getIndex()] = this.offhandMage + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.HelmetMage > 0)
|
||||
if (this.helmetMage > 0)
|
||||
{
|
||||
if (this.targetHelmetMage > 0)
|
||||
{
|
||||
if (helmetID == this.targetHelmetMage)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.HELMET.getIndex()] = this.HelmetMage + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.HELMET.getIndex()] = this.helmetMage + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.CapeMage > 0)
|
||||
if (this.capeMage > 0)
|
||||
{
|
||||
if (this.targetCapeMage > 0)
|
||||
{
|
||||
if (capeID == this.targetCapeMage)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.CAPE.getIndex()] = this.CapeMage + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.CAPE.getIndex()] = this.capeMage + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.NeckMage > 0)
|
||||
if (this.neckMage > 0)
|
||||
{
|
||||
if (this.targetNeckMage > 0)
|
||||
{
|
||||
if (neckID == this.targetNeckMage)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.AMULET.getIndex()] = this.NeckMage + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.AMULET.getIndex()] = this.neckMage + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.BodyMage > 0)
|
||||
if (this.bodyMage > 0)
|
||||
{
|
||||
if (this.targetBodyMage > 0)
|
||||
{
|
||||
if (bodyID == this.targetBodyMage)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.TORSO.getIndex()] = this.BodyMage + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.TORSO.getIndex()] = this.bodyMage + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.LegsMage > 0)
|
||||
if (this.legsMage > 0)
|
||||
{
|
||||
if (this.targetLegsMage > 0)
|
||||
{
|
||||
if (legsID == this.targetLegsMage)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.LEGS.getIndex()] = this.LegsMage + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.LEGS.getIndex()] = this.legsMage + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.BootsMage > 0)
|
||||
if (this.bootsMage > 0)
|
||||
{
|
||||
if (this.targetBootsMage > 0)
|
||||
{
|
||||
if (bootsID == this.targetBootsMage)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.BOOTS.getIndex()] = this.BootsMage + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.BOOTS.getIndex()] = this.bootsMage + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.GlovesMage > 0)
|
||||
if (this.glovesMage > 0)
|
||||
{
|
||||
if (this.targetGlovesMage > 0)
|
||||
{
|
||||
if (glovesID == this.targetGlovesMage)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.HANDS.getIndex()] = this.GlovesMage + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.HANDS.getIndex()] = this.glovesMage + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.rangeSwap)
|
||||
{
|
||||
if (this.MainhandRange > 0)
|
||||
if (this.mainhandRange > 0)
|
||||
{
|
||||
if (this.targetMainhandRange > 0)
|
||||
{
|
||||
if (mainhandID == this.targetMainhandRange)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.WEAPON.getIndex()] = this.MainhandRange + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.WEAPON.getIndex()] = this.mainhandRange + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.OffhandRange > 0)
|
||||
if (this.offhandRange > 0)
|
||||
{
|
||||
if (this.targetOffhandRange > 0)
|
||||
{
|
||||
if (offhandID == this.targetOffhandRange)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.SHIELD.getIndex()] = this.OffhandRange + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.SHIELD.getIndex()] = this.offhandRange + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.HelmetRange > 0)
|
||||
if (this.helmetRange > 0)
|
||||
{
|
||||
if (this.targetHelmetRange > 0)
|
||||
{
|
||||
if (helmetID == this.targetHelmetRange)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.HELMET.getIndex()] = this.HelmetRange + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.HELMET.getIndex()] = this.helmetRange + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.CapeRange > 0)
|
||||
if (this.capeRange > 0)
|
||||
{
|
||||
if (this.targetCapeRange > 0)
|
||||
{
|
||||
if (capeID == this.targetCapeRange)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.CAPE.getIndex()] = this.CapeRange + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.CAPE.getIndex()] = this.capeRange + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.NeckRange > 0)
|
||||
if (this.neckRange > 0)
|
||||
{
|
||||
if (this.targetNeckRange > 0)
|
||||
{
|
||||
if (neckID == this.targetNeckRange)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.AMULET.getIndex()] = this.NeckRange + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.AMULET.getIndex()] = this.neckRange + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.BodyRange > 0)
|
||||
if (this.bodyRange > 0)
|
||||
{
|
||||
if (this.targetBodyRange > 0)
|
||||
{
|
||||
if (bodyID == this.targetBodyRange)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.TORSO.getIndex()] = this.BodyRange + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.TORSO.getIndex()] = this.bodyRange + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.LegsRange > 0)
|
||||
if (this.legsRange > 0)
|
||||
{
|
||||
if (this.targetLegsRange > 0)
|
||||
{
|
||||
if (legsID == this.targetLegsRange)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.LEGS.getIndex()] = this.LegsRange + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.LEGS.getIndex()] = this.legsRange + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.BootsRange > 0)
|
||||
if (this.bootsRange > 0)
|
||||
{
|
||||
if (this.targetBootsRange > 0)
|
||||
{
|
||||
if (bootsID == this.targetBootsRange)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.BOOTS.getIndex()] = this.BootsRange + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.BOOTS.getIndex()] = this.bootsRange + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.GlovesRange > 0)
|
||||
if (this.glovesRange > 0)
|
||||
{
|
||||
if (this.targetGlovesRange > 0)
|
||||
{
|
||||
if (glovesID == this.targetGlovesRange)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.HANDS.getIndex()] = this.GlovesRange + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.HANDS.getIndex()] = this.glovesRange + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.meleeSwap)
|
||||
{
|
||||
if (this.MainhandMelee > 0)
|
||||
if (this.mainhandMelee > 0)
|
||||
{
|
||||
if (this.targetMainhandMelee > 0)
|
||||
{
|
||||
if (mainhandID == this.targetMainhandMelee)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.WEAPON.getIndex()] = this.MainhandMelee + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.WEAPON.getIndex()] = this.mainhandMelee + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.OffhandMelee > 0)
|
||||
if (this.offhandMelee > 0)
|
||||
{
|
||||
if (this.targetOffhandMelee > 0)
|
||||
{
|
||||
if (offhandID == this.targetOffhandMelee)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.SHIELD.getIndex()] = this.OffhandMelee + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.SHIELD.getIndex()] = this.offhandMelee + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.HelmetMelee > 0)
|
||||
if (this.helmetMelee > 0)
|
||||
{
|
||||
if (this.targetHelmetMelee > 0)
|
||||
{
|
||||
if (helmetID == this.targetHelmetMelee)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.HELMET.getIndex()] = this.HelmetMelee + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.HELMET.getIndex()] = this.helmetMelee + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.CapeMelee > 0)
|
||||
if (this.capeMelee > 0)
|
||||
{
|
||||
if (this.targetCapeMelee > 0)
|
||||
{
|
||||
if (capeID == this.targetCapeMelee)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.CAPE.getIndex()] = this.CapeMelee + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.CAPE.getIndex()] = this.capeMelee + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.NeckMelee > 0)
|
||||
if (this.neckMelee > 0)
|
||||
{
|
||||
if (this.targetNeckMelee > 0)
|
||||
{
|
||||
if (neckID == this.targetNeckMelee)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.AMULET.getIndex()] = this.NeckMelee + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.AMULET.getIndex()] = this.neckMelee + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.BodyMelee > 0)
|
||||
if (this.bodyMelee > 0)
|
||||
{
|
||||
if (this.targetBodyMelee > 0)
|
||||
{
|
||||
if (bodyID == this.targetBodyMelee)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.TORSO.getIndex()] = this.BodyMelee + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.TORSO.getIndex()] = this.bodyMelee + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.LegsMelee > 0)
|
||||
if (this.legsMelee > 0)
|
||||
{
|
||||
if (this.targetLegsMelee > 0)
|
||||
{
|
||||
if (legsID == this.targetLegsMelee)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.LEGS.getIndex()] = this.LegsMelee + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.LEGS.getIndex()] = this.legsMelee + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.BootsMelee > 0)
|
||||
if (this.bootsMelee > 0)
|
||||
{
|
||||
if (this.targetBootsMelee > 0)
|
||||
{
|
||||
if (bootsID == this.targetBootsMelee)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.BOOTS.getIndex()] = this.BootsMelee + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.BOOTS.getIndex()] = this.bootsMelee + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.GlovesMelee > 0)
|
||||
if (this.glovesMelee > 0)
|
||||
{
|
||||
if (this.targetGlovesMelee > 0)
|
||||
{
|
||||
if (glovesID == this.targetGlovesMelee)
|
||||
{
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.HANDS.getIndex()] = this.GlovesMelee + 512;
|
||||
player.getPlayerAppearance().getEquipmentIds()[KitType.HANDS.getIndex()] = this.glovesMelee + 512;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -497,65 +530,68 @@ public class TMorph extends Plugin
|
||||
|
||||
private void updateConfig()
|
||||
{
|
||||
this.mageSwap = config.mageSwap();
|
||||
this.rangeSwap = config.rangeSwap();
|
||||
this.meleeSwap = config.meleeSwap();
|
||||
this.animation = config.animationSwap();
|
||||
this.bodyMage = config.BodyMage();
|
||||
this.bodyMelee = config.BodyMelee();
|
||||
this.bodyRange = config.BodyRange();
|
||||
this.bootsMage = config.BootsMage();
|
||||
this.bootsMelee = config.BootsMelee();
|
||||
this.bootsRange = config.BootsRange();
|
||||
this.capeMage = config.CapeMage();
|
||||
this.capeMelee = config.CapeMelee();
|
||||
this.capeRange = config.CapeRange();
|
||||
this.globalAnimSwap = config.globalAnimSwap();
|
||||
this.animationSwap = config.animationSwap();
|
||||
this.animationTarget = config.animationTarget();
|
||||
this.MainhandMage = config.MainhandMage();
|
||||
this.targetMainhandMage = config.targetMainhandMage();
|
||||
this.OffhandMage = config.OffhandMage();
|
||||
this.targetOffhandMage = config.targetOffhandMage();
|
||||
this.HelmetMage = config.HelmetMage();
|
||||
this.targetHelmetMage = config.targetHelmetMage();
|
||||
this.CapeMage = config.CapeMage();
|
||||
this.targetCapeMage = config.targetCapeMage();
|
||||
this.NeckMage = config.NeckMage();
|
||||
this.targetNeckMage = config.targetNeckMage();
|
||||
this.BodyMage = config.BodyMage();
|
||||
this.globalGraphicSwap = config.globalGraphicSwap();
|
||||
this.glovesMage = config.GlovesMage();
|
||||
this.glovesMelee = config.GlovesMelee();
|
||||
this.glovesRange = config.GlovesRange();
|
||||
this.graphic = config.graphicSwap();
|
||||
this.helmetMage = config.HelmetMage();
|
||||
this.helmetMelee = config.HelmetMelee();
|
||||
this.helmetRange = config.HelmetRange();
|
||||
this.legsMage = config.LegsMage();
|
||||
this.legsMelee = config.LegsMelee();
|
||||
this.legsRange = config.LegsRange();
|
||||
this.mageSwap = config.mageSwap();
|
||||
this.mainhandMage = config.MainhandMage();
|
||||
this.mainhandMelee = config.MainhandMelee();
|
||||
this.mainhandRange = config.MainhandRange();
|
||||
this.meleeSwap = config.meleeSwap();
|
||||
this.neckMage = config.NeckMage();
|
||||
this.neckMelee = config.NeckMelee();
|
||||
this.neckRange = config.NeckRange();
|
||||
this.offhandMage = config.OffhandMage();
|
||||
this.offhandMelee = config.OffhandMelee();
|
||||
this.offhandRange = config.OffhandRange();
|
||||
this.rangeSwap = config.rangeSwap();
|
||||
this.targetAnimation = config.animationTarget();
|
||||
this.targetBodyMage = config.targetBodyMage();
|
||||
this.LegsMage = config.LegsMage();
|
||||
this.targetLegsMage = config.targetLegsMage();
|
||||
this.BootsMage = config.BootsMage();
|
||||
this.targetBootsMage = config.targetBootsMage();
|
||||
this.GlovesMage = config.GlovesMage();
|
||||
this.targetGlovesMage = config.targetGlovesMage();
|
||||
this.MainhandRange = config.MainhandRange();
|
||||
this.targetMainhandRange = config.targetMainhandRange();
|
||||
this.OffhandRange = config.OffhandRange();
|
||||
this.targetOffhandRange = config.targetOffhandRange();
|
||||
this.HelmetRange = config.HelmetRange();
|
||||
this.targetHelmetRange = config.targetHelmetRange();
|
||||
this.CapeRange = config.CapeRange();
|
||||
this.targetCapeRange = config.targetCapeRange();
|
||||
this.NeckRange = config.NeckRange();
|
||||
this.targetNeckRange = config.targetNeckRange();
|
||||
this.BodyRange = config.BodyRange();
|
||||
this.targetBodyRange = config.targetBodyRange();
|
||||
this.LegsRange = config.LegsRange();
|
||||
this.targetLegsRange = config.targetLegsRange();
|
||||
this.BootsRange = config.BootsRange();
|
||||
this.targetBootsRange = config.targetBootsRange();
|
||||
this.GlovesRange = config.GlovesRange();
|
||||
this.targetGlovesRange = config.targetGlovesRange();
|
||||
this.MainhandMelee = config.MainhandMelee();
|
||||
this.targetMainhandMelee = config.targetMainhandMelee();
|
||||
this.OffhandMelee = config.OffhandMelee();
|
||||
this.targetOffhandMelee = config.targetOffhandMelee();
|
||||
this.HelmetMelee = config.HelmetMelee();
|
||||
this.targetHelmetMelee = config.targetHelmetMelee();
|
||||
this.CapeMelee = config.CapeMelee();
|
||||
this.targetCapeMelee = config.targetCapeMelee();
|
||||
this.NeckMelee = config.NeckMelee();
|
||||
this.targetNeckMelee = config.targetNeckMelee();
|
||||
this.BodyMelee = config.BodyMelee();
|
||||
this.targetBodyMelee = config.targetBodyMelee();
|
||||
this.LegsMelee = config.LegsMelee();
|
||||
this.targetLegsMelee = config.targetLegsMelee();
|
||||
this.BootsMelee = config.BootsMelee();
|
||||
this.targetBodyRange = config.targetBodyRange();
|
||||
this.targetBootsMage = config.targetBootsMage();
|
||||
this.targetBootsMelee = config.targetBootsMelee();
|
||||
this.GlovesMelee = config.GlovesMelee();
|
||||
this.targetBootsRange = config.targetBootsRange();
|
||||
this.targetCapeMage = config.targetCapeMage();
|
||||
this.targetCapeMelee = config.targetCapeMelee();
|
||||
this.targetCapeRange = config.targetCapeRange();
|
||||
this.targetGlovesMage = config.targetGlovesMage();
|
||||
this.targetGlovesMelee = config.targetGlovesMelee();
|
||||
this.targetGlovesRange = config.targetGlovesRange();
|
||||
this.targetGraphic = config.graphicTarget();
|
||||
this.targetHelmetMage = config.targetHelmetMage();
|
||||
this.targetHelmetMelee = config.targetHelmetMelee();
|
||||
this.targetHelmetRange = config.targetHelmetRange();
|
||||
this.targetLegsMage = config.targetLegsMage();
|
||||
this.targetLegsMelee = config.targetLegsMelee();
|
||||
this.targetLegsRange = config.targetLegsRange();
|
||||
this.targetMainhandMage = config.targetMainhandMage();
|
||||
this.targetMainhandMelee = config.targetMainhandMelee();
|
||||
this.targetMainhandRange = config.targetMainhandRange();
|
||||
this.targetNeckMage = config.targetNeckMage();
|
||||
this.targetNeckMelee = config.targetNeckMelee();
|
||||
this.targetNeckRange = config.targetNeckRange();
|
||||
this.targetOffhandMage = config.targetOffhandMage();
|
||||
this.targetOffhandMelee = config.targetOffhandMelee();
|
||||
this.targetOffhandRange = config.targetOffhandRange();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -96,7 +96,6 @@ public interface TMorphConfig extends Config
|
||||
keyName = "globalAnimSwap",
|
||||
name = "Global Animation Swap",
|
||||
description = "DO NOT USE WITH ANIMATION SWAP BELOW",
|
||||
|
||||
group = "Experimental Functions",
|
||||
hidden = true,
|
||||
unhide = "experimentalFunctions"
|
||||
@@ -132,6 +131,45 @@ public interface TMorphConfig extends Config
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ConfigItem(
|
||||
keyName = "globalGraphicSwap",
|
||||
name = "Global Graphic Swap",
|
||||
description = "DO NOT USE WITH GRAPHIC SWAP BELOW",
|
||||
group = "Experimental Functions",
|
||||
hidden = true,
|
||||
unhide = "experimentalFunctions"
|
||||
)
|
||||
default int globalGraphicSwap()
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ConfigItem(
|
||||
keyName = "graphicSwap",
|
||||
name = "Graphic Swap",
|
||||
description = "ID",
|
||||
group = "Experimental Functions",
|
||||
hidden = true,
|
||||
unhide = "experimentalFunctions"
|
||||
)
|
||||
default int graphicSwap()
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ConfigItem(
|
||||
keyName = "graphicTarget",
|
||||
name = "Graphic Target",
|
||||
description = "ID",
|
||||
group = "Experimental Functions",
|
||||
hidden = true,
|
||||
unhide = "experimentalFunctions"
|
||||
)
|
||||
default int graphicTarget()
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
//////////////////Mage
|
||||
|
||||
|
||||
@@ -24,6 +24,7 @@
|
||||
*/
|
||||
package net.runelite.client.plugins.worldhopper.ping;
|
||||
|
||||
import com.sun.jna.Native;
|
||||
import com.sun.jna.Pointer;
|
||||
import com.sun.jna.Structure;
|
||||
import com.sun.jna.platform.win32.WinDef;
|
||||
@@ -32,8 +33,8 @@ import java.util.List;
|
||||
|
||||
public class IcmpEchoReply extends Structure
|
||||
{
|
||||
private static final int IP_OPTION_INFO_SIZE = 1 + 1 + 1 + 1 + (Pointer.SIZE == 8 ? 12 : 4); // on 64bit vms add 4 byte padding
|
||||
public static final int SIZE = 4 + 4 + 4 + 2 + 2 + Pointer.SIZE + IP_OPTION_INFO_SIZE;
|
||||
private static final int IP_OPTION_INFO_SIZE = 1 + 1 + 1 + 1 + (Native.POINTER_SIZE == 8 ? 12 : 4); // on 64bit vms add 4 byte padding
|
||||
public static final int SIZE = 4 + 4 + 4 + 2 + 2 + Native.POINTER_SIZE + IP_OPTION_INFO_SIZE;
|
||||
|
||||
public WinDef.ULONG address;
|
||||
public WinDef.ULONG status;
|
||||
|
||||
@@ -24,6 +24,7 @@
|
||||
*/
|
||||
package net.runelite.client.util.ping;
|
||||
|
||||
import com.sun.jna.Native;
|
||||
import com.sun.jna.Pointer;
|
||||
import com.sun.jna.Structure;
|
||||
import com.sun.jna.platform.win32.WinDef;
|
||||
@@ -32,8 +33,8 @@ import java.util.List;
|
||||
|
||||
public class IcmpEchoReply extends Structure
|
||||
{
|
||||
private static final int IP_OPTION_INFO_SIZE = 1 + 1 + 1 + 1 + (Pointer.SIZE == 8 ? 12 : 4); // on 64bit vms add 4 byte padding
|
||||
public static final int SIZE = 4 + 4 + 4 + 2 + 2 + Pointer.SIZE + IP_OPTION_INFO_SIZE;
|
||||
private static final int IP_OPTION_INFO_SIZE = 1 + 1 + 1 + 1 + (Native.POINTER_SIZE == 8 ? 12 : 4); // on 64bit vms add 4 byte padding
|
||||
public static final int SIZE = 4 + 4 + 4 + 2 + 2 + Native.POINTER_SIZE + IP_OPTION_INFO_SIZE;
|
||||
|
||||
public WinDef.ULONG address;
|
||||
public WinDef.ULONG status;
|
||||
|
||||
@@ -1,10 +1,9 @@
|
||||
|
||||
description = 'RuneLite Mixins'
|
||||
dependencies {
|
||||
testCompile group: 'junit', name: 'junit', version:'4.12'
|
||||
testCompile group: 'org.mockito', name: 'mockito-all', version:'1.10.19'
|
||||
compileOnly group: 'org.slf4j', name: 'slf4j-api', version:'1.7.25'
|
||||
testCompile group: 'junit', name: 'junit', version: '4.12'
|
||||
testCompile group: 'org.mockito', name: 'mockito-all', version: '1.10.19'
|
||||
compileOnly group: 'org.slf4j', name: 'slf4j-api', version: '1.7.26'
|
||||
compile project(':runescape-api')
|
||||
compileOnly group: 'com.google.guava', name: 'guava', version:'28.0-jre'
|
||||
compileOnly group: 'javax.inject', name: 'javax.inject', version:'1'
|
||||
compileOnly group: 'com.google.guava', name: 'guava', version: '28.0-jre'
|
||||
compileOnly group: 'javax.inject', name: 'javax.inject', version: '1'
|
||||
}
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
|
||||
description = 'RuneLite Plugin Archetype'
|
||||
|
||||
@@ -1,27 +1,29 @@
|
||||
|
||||
description = 'Script Assembler Plugin'
|
||||
dependencies {
|
||||
compile project(':cache')
|
||||
compile project(':runelite-api')
|
||||
compile group: 'org.apache.maven', name: 'maven-plugin-api', version:'3.6.1'
|
||||
compileOnly group: 'org.apache.maven.plugin-tools', name: 'maven-plugin-annotations', version:'3.6.0'
|
||||
compile project(':cache')
|
||||
compile project(':runelite-api')
|
||||
compile group: 'org.apache.maven', name: 'maven-plugin-api', version: '3.6.1'
|
||||
compile group: 'org.slf4j', name: 'slf4j-nop', version: '1.7.26'
|
||||
compileOnly group: 'org.apache.maven.plugin-tools', name: 'maven-plugin-annotations', version: '3.6.0'
|
||||
annotationProcessor group: 'org.eclipse.sisu', name: 'org.eclipse.sisu.inject', version: '0.3.3'
|
||||
}
|
||||
|
||||
task assembleMojo(type:JavaExec) {
|
||||
classpath = sourceSets.main.runtimeClasspath
|
||||
|
||||
main = "net.runelite.script.AssembleMojo"
|
||||
args('../runelite-client/src/main/scripts,../runelite-client/src/main/resources/runelite'.split(','))
|
||||
}
|
||||
|
||||
task indexMojo(type:JavaExec) {
|
||||
classpath = sourceSets.main.runtimeClasspath
|
||||
|
||||
main = "net.runelite.script.IndexMojo"
|
||||
args('../runelite-client/src/main/resources/runelite,../runelite-client/src/main/resources/runelite/index'.split(','))
|
||||
}
|
||||
compileJava.outputs.upToDateWhen {false}
|
||||
|
||||
compileJava.doLast {
|
||||
tasks.assembleMojo.execute()
|
||||
tasks.indexMojo.execute()
|
||||
def path = sourceSets.main.runtimeClasspath
|
||||
def loader = new URLClassLoader(path.collect { f -> f.toURL() } as URL[])
|
||||
def assemble = loader.loadClass('net.runelite.script.AssembleMojo')
|
||||
String[] assembleArgs = [
|
||||
"${project.rootDir}/runelite-client/src/main/scripts",
|
||||
"${project.rootDir}/runelite-client/src/main/resources/runelite"
|
||||
]
|
||||
assemble.main(assembleArgs)
|
||||
|
||||
def index = loader.loadClass('net.runelite.script.IndexMojo')
|
||||
String[] indexArgs = [
|
||||
"${project.rootDir}/runelite-client/src/main/resources/runelite",
|
||||
"${project.rootDir}/runelite-client/src/main/resources/runelite/index"
|
||||
]
|
||||
index.main(indexArgs)
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
group = 'net.runelite.rs'
|
||||
description = 'RuneScape API'
|
||||
dependencies {
|
||||
compile project(':runelite-api')
|
||||
compile project(':runelite-api')
|
||||
}
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
group = 'net.runelite.rs'
|
||||
description = 'RuneScape Client'
|
||||
dependencies {
|
||||
compile project(':runescape-api')
|
||||
testCompile group: 'junit', name: 'junit', version:'4.12'
|
||||
testCompile group: 'org.slf4j', name: 'slf4j-api', version:'1.7.26'
|
||||
testCompile group: 'org.slf4j', name: 'slf4j-simple', version:'1.7.26'
|
||||
compile project(':runescape-api')
|
||||
testCompile group: 'junit', name: 'junit', version: '4.12'
|
||||
testCompile group: 'org.slf4j', name: 'slf4j-api', version: '1.7.26'
|
||||
testCompile group: 'org.slf4j', name: 'slf4j-simple', version: '1.7.26'
|
||||
}
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
./gradlew clean build -x test
|
||||
@@ -1,279 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
|
||||
<!--
|
||||
Licensed to the Apache Software Foundation (ASF) under one
|
||||
or more contributor license agreements. See the NOTICE file
|
||||
distributed with this work for additional information
|
||||
regarding copyright ownership. The ASF licenses this file
|
||||
to you under the Apache License, Version 2.0 (the
|
||||
"License"); you may not use this file except in compliance
|
||||
with the License. You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing,
|
||||
software distributed under the License is distributed on an
|
||||
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
KIND, either express or implied. See the License for the
|
||||
specific language governing permissions and limitations
|
||||
under the License.
|
||||
-->
|
||||
|
||||
<!--
|
||||
| This is the configuration file for Maven. It can be specified at two levels:
|
||||
|
|
||||
| 1. User Level. This settings.xml file provides configuration for a single user,
|
||||
| and is normally provided in ${user.home}/.m2/settings.xml.
|
||||
|
|
||||
| NOTE: This location can be overridden with the CLI option:
|
||||
|
|
||||
| -s /path/to/user/settings.xml
|
||||
|
|
||||
| 2. Global Level. This settings.xml file provides configuration for all Maven
|
||||
| users on a machine (assuming they're all using the same Maven
|
||||
| installation). It's normally provided in
|
||||
| ${maven.home}/conf/settings.xml.
|
||||
|
|
||||
| NOTE: This location can be overridden with the CLI option:
|
||||
|
|
||||
| -gs /path/to/global/settings.xml
|
||||
|
|
||||
| The sections in this sample file are intended to give you a running start at
|
||||
| getting the most out of your Maven installation. Where appropriate, the default
|
||||
| values (values used when the setting is not specified) are provided.
|
||||
|
|
||||
|-->
|
||||
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd">
|
||||
<!-- localRepository
|
||||
| The path to the local repository maven will use to store artifacts.
|
||||
|
|
||||
| Default: ${user.home}/.m2/repository
|
||||
<localRepository>/path/to/local/repo</localRepository>
|
||||
-->
|
||||
|
||||
<!-- interactiveMode
|
||||
| This will determine whether maven prompts you when it needs input. If set to false,
|
||||
| maven will use a sensible default value, perhaps based on some other setting, for
|
||||
| the parameter in question.
|
||||
|
|
||||
| Default: true
|
||||
<interactiveMode>true</interactiveMode>
|
||||
-->
|
||||
<interactiveMode>false</interactiveMode>
|
||||
|
||||
<!-- offline
|
||||
| Determines whether maven should attempt to connect to the network when executing a build.
|
||||
| This will have an effect on artifact downloads, artifact deployment, and others.
|
||||
|
|
||||
| Default: false
|
||||
<offline>false</offline>
|
||||
-->
|
||||
|
||||
<!-- pluginGroups
|
||||
| This is a list of additional group identifiers that will be searched when resolving plugins by their prefix, i.e.
|
||||
| when invoking a command line like "mvn prefix:goal". Maven will automatically add the group identifiers
|
||||
| "org.apache.maven.plugins" and "org.codehaus.mojo" if these are not already contained in the list.
|
||||
|-->
|
||||
<pluginGroups>
|
||||
<!-- pluginGroup
|
||||
| Specifies a further group identifier to use for plugin lookup.
|
||||
<pluginGroup>com.your.plugins</pluginGroup>
|
||||
-->
|
||||
</pluginGroups>
|
||||
|
||||
<!-- proxies
|
||||
| This is a list of proxies which can be used on this machine to connect to the network.
|
||||
| Unless otherwise specified (by system property or command-line switch), the first proxy
|
||||
| specification in this list marked as active will be used.
|
||||
|-->
|
||||
<proxies>
|
||||
<!-- proxy
|
||||
| Specification for one proxy, to be used in connecting to the network.
|
||||
|
|
||||
<proxy>
|
||||
<id>optional</id>
|
||||
<active>true</active>
|
||||
<protocol>http</protocol>
|
||||
<username>proxyuser</username>
|
||||
<password>proxypass</password>
|
||||
<host>proxy.host.net</host>
|
||||
<port>80</port>
|
||||
<nonProxyHosts>local.net|some.host.com</nonProxyHosts>
|
||||
</proxy>
|
||||
-->
|
||||
</proxies>
|
||||
|
||||
<!-- servers
|
||||
| This is a list of authentication profiles, keyed by the server-id used within the system.
|
||||
| Authentication profiles can be used whenever maven must make a connection to a remote server.
|
||||
|-->
|
||||
<servers>
|
||||
<!-- server
|
||||
| Specifies the authentication information to use when connecting to a particular server, identified by
|
||||
| a unique name within the system (referred to by the 'id' attribute below).
|
||||
|
|
||||
| NOTE: You should either specify username/password OR privateKey/passphrase, since these pairings are
|
||||
| used together.
|
||||
|
|
||||
<server>
|
||||
<id>deploymentRepo</id>
|
||||
<username>repouser</username>
|
||||
<password>repopwd</password>
|
||||
</server>
|
||||
-->
|
||||
|
||||
<!-- Another sample, using keys to authenticate.
|
||||
<server>
|
||||
<id>siteServer</id>
|
||||
<privateKey>/path/to/private/key</privateKey>
|
||||
<passphrase>optional; leave empty if not used.</passphrase>
|
||||
</server>
|
||||
-->
|
||||
|
||||
<!-- <server>
|
||||
<id>runelite</id>
|
||||
<username>repo</username>
|
||||
<password>${env.REPO_PASSWORD}</password>
|
||||
</server>-->
|
||||
|
||||
</servers>
|
||||
|
||||
<!-- mirrors
|
||||
| This is a list of mirrors to be used in downloading artifacts from remote repositories.
|
||||
|
|
||||
| It works like this: a POM may declare a repository to use in resolving certain artifacts.
|
||||
| However, this repository may have problems with heavy traffic at times, so people have mirrored
|
||||
| it to several places.
|
||||
|
|
||||
| That repository definition will have a unique id, so we can create a mirror reference for that
|
||||
| repository, to be used as an alternate download site. The mirror site will be the preferred
|
||||
| server for that repository.
|
||||
|-->
|
||||
<mirrors>
|
||||
<!-- mirror
|
||||
| Specifies a repository mirror site to use instead of a given repository. The repository that
|
||||
| this mirror serves has an ID that matches the mirrorOf element of this mirror. IDs are used
|
||||
| for inheritance and direct lookup purposes, and must be unique across the set of mirrors.
|
||||
|
|
||||
<mirror>
|
||||
<id>mirrorId</id>
|
||||
<mirrorOf>repositoryId</mirrorOf>
|
||||
<name>Human Readable Name for this Mirror.</name>
|
||||
<url>http://my.repository.com/repo/path</url>
|
||||
</mirror>
|
||||
-->
|
||||
</mirrors>
|
||||
|
||||
<!-- profiles
|
||||
| This is a list of profiles which can be activated in a variety of ways, and which can modify
|
||||
| the build process. Profiles provided in the settings.xml are intended to provide local machine-
|
||||
| specific paths and repository locations which allow the build to work in the local environment.
|
||||
|
|
||||
| For example, if you have an integration testing plugin - like cactus - that needs to know where
|
||||
| your Tomcat instance is installed, you can provide a variable here such that the variable is
|
||||
| dereferenced during the build process to configure the cactus plugin.
|
||||
|
|
||||
| As noted above, profiles can be activated in a variety of ways. One way - the activeProfiles
|
||||
| section of this document (settings.xml) - will be discussed later. Another way essentially
|
||||
| relies on the detection of a system property, either matching a particular value for the property,
|
||||
| or merely testing its existence. Profiles can also be activated by JDK version prefix, where a
|
||||
| value of '1.4' might activate a profile when the build is executed on a JDK version of '1.4.2_07'.
|
||||
| Finally, the list of active profiles can be specified directly from the command line.
|
||||
|
|
||||
| NOTE: For profiles defined in the settings.xml, you are restricted to specifying only artifact
|
||||
| repositories, plugin repositories, and free-form properties to be used as configuration
|
||||
| variables for plugins in the POM.
|
||||
|
|
||||
|-->
|
||||
<profiles>
|
||||
<!-- profile
|
||||
| Specifies a set of introductions to the build process, to be activated using one or more of the
|
||||
| mechanisms described above. For inheritance purposes, and to activate profiles via <activatedProfiles/>
|
||||
| or the command line, profiles have to have an ID that is unique.
|
||||
|
|
||||
| An encouraged best practice for profile identification is to use a consistent naming convention
|
||||
| for profiles, such as 'env-dev', 'env-test', 'env-production', 'user-jdcasey', 'user-brett', etc.
|
||||
| This will make it more intuitive to understand what the set of introduced profiles is attempting
|
||||
| to accomplish, particularly when you only have a list of profile id's for debug.
|
||||
|
|
||||
| This profile example uses the JDK version to trigger activation, and provides a JDK-specific repo.
|
||||
<profile>
|
||||
<id>jdk-1.4</id>
|
||||
|
||||
<activation>
|
||||
<jdk>1.4</jdk>
|
||||
</activation>
|
||||
|
||||
<repositories>
|
||||
<repository>
|
||||
<id>jdk14</id>
|
||||
<name>Repository for JDK 1.4 builds</name>
|
||||
<url>http://www.myhost.com/maven/jdk14</url>
|
||||
<layout>default</layout>
|
||||
<snapshotPolicy>always</snapshotPolicy>
|
||||
</repository>
|
||||
</repositories>
|
||||
</profile>
|
||||
-->
|
||||
|
||||
<!--
|
||||
| Here is another profile, activated by the system property 'target-env' with a value of 'dev',
|
||||
| which provides a specific path to the Tomcat instance. To use this, your plugin configuration
|
||||
| might hypothetically look like:
|
||||
|
|
||||
| ...
|
||||
| <plugin>
|
||||
| <groupId>org.myco.myplugins</groupId>
|
||||
| <artifactId>myplugin</artifactId>
|
||||
|
|
||||
| <configuration>
|
||||
| <tomcatLocation>${tomcatPath}</tomcatLocation>
|
||||
| </configuration>
|
||||
| </plugin>
|
||||
| ...
|
||||
|
|
||||
| NOTE: If you just wanted to inject this configuration whenever someone set 'target-env' to
|
||||
| anything, you could just leave off the <value/> inside the activation-property.
|
||||
|
|
||||
<profile>
|
||||
<id>env-dev</id>
|
||||
|
||||
<activation>
|
||||
<property>
|
||||
<name>target-env</name>
|
||||
<value>dev</value>
|
||||
</property>
|
||||
</activation>
|
||||
|
||||
<properties>
|
||||
<tomcatPath>/path/to/tomcat/instance</tomcatPath>
|
||||
</properties>
|
||||
</profile>
|
||||
-->
|
||||
|
||||
<profile>
|
||||
<id>runelite</id>
|
||||
|
||||
<properties>
|
||||
<maven.javadoc.skip>true</maven.javadoc.skip>
|
||||
<checkstyle.skip>false</checkstyle.skip>
|
||||
<archetype.test.skip>true</archetype.test.skip>
|
||||
<test.skip>false</test.skip>
|
||||
</properties>
|
||||
</profile>
|
||||
</profiles>
|
||||
|
||||
<!-- activeProfiles
|
||||
| List of profiles that are active for all builds.
|
||||
|
|
||||
<activeProfiles>
|
||||
<activeProfile>alwaysActiveProfile</activeProfile>
|
||||
<activeProfile>anotherAlwaysActiveProfile</activeProfile>
|
||||
</activeProfiles>
|
||||
-->
|
||||
<activeProfiles>
|
||||
<activeProfile>runelite</activeProfile>
|
||||
</activeProfiles>
|
||||
</settings>
|
||||
Reference in New Issue
Block a user