Compare commits
135 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a2e55f7861 | ||
|
|
761e0114a5 | ||
|
|
dcae128d06 | ||
|
|
a891a8badc | ||
|
|
f3ec5b533e | ||
|
|
d50397edf1 | ||
|
|
49986f22c8 | ||
|
|
70f279d978 | ||
|
|
84c5a75b6c | ||
|
|
97663e87a6 | ||
|
|
5956edcb8e | ||
|
|
7e975f2134 | ||
|
|
40de13f9c7 | ||
|
|
70946539e3 | ||
|
|
996c594dfc | ||
|
|
d8eeb79b63 | ||
|
|
cf61dd0704 | ||
|
|
6fd5f1563a | ||
|
|
3c643c917a | ||
|
|
378be0ef86 | ||
|
|
29e90969eb | ||
|
|
fb724514f3 | ||
|
|
1f11da75d2 | ||
|
|
fcc433fe17 | ||
|
|
617bdf9910 | ||
|
|
3b2aa92eb7 | ||
|
|
4c17b56e28 | ||
|
|
ad13c83f93 | ||
|
|
768d67a8ae | ||
|
|
d827cda395 | ||
|
|
106e6c98a3 | ||
|
|
e7ad797d4e | ||
|
|
6e1fb71194 | ||
|
|
9f5dc7f091 | ||
|
|
57b273639c | ||
|
|
278d690a6b | ||
|
|
c91c0f7b47 | ||
|
|
6a406f4d45 | ||
|
|
eecaa850e0 | ||
|
|
f332332eaa | ||
|
|
79b0e76be0 | ||
|
|
30650efd98 | ||
|
|
b7759c8151 | ||
|
|
0382c35ac0 | ||
|
|
819262c93f | ||
|
|
db60f4bb1c | ||
|
|
7785ca55c2 | ||
|
|
75dcceff43 | ||
|
|
af91979d4c | ||
|
|
52cd4a77dd | ||
|
|
8a1da3c0ed | ||
|
|
9d67c36c32 | ||
|
|
f283709e62 | ||
|
|
5035559b08 | ||
|
|
01e1438382 | ||
|
|
4eee472043 | ||
|
|
5f89a1b9ca | ||
|
|
b9db5ad662 | ||
|
|
5b8084e1fa | ||
|
|
ab67b67e4c | ||
|
|
f825931f92 | ||
|
|
6113edf2ce | ||
|
|
8413443c26 | ||
|
|
f67fb31bc5 | ||
|
|
d321ec5ed1 | ||
|
|
084ae184f9 | ||
|
|
d1ec652f7b | ||
|
|
7a2a6586be | ||
|
|
392dcf3092 | ||
|
|
8a983c784d | ||
|
|
a443263439 | ||
|
|
3e766b9f54 | ||
|
|
89b9501f35 | ||
|
|
816ae84005 | ||
|
|
c0e425cf46 | ||
|
|
9ebb4c7d12 | ||
|
|
46c3b35028 | ||
|
|
ef2b8be726 | ||
|
|
df51078858 | ||
|
|
5783b61631 | ||
|
|
98a53381fb | ||
|
|
daccfa5fe3 | ||
|
|
d82c24616f | ||
|
|
905ca3dcfc | ||
|
|
b4fb687c4f | ||
|
|
39fb2ae5ab | ||
|
|
b40beb0d1d | ||
|
|
4a96b9bb00 | ||
|
|
f83a178982 | ||
|
|
986b4276e1 | ||
|
|
6f6f418ec9 | ||
|
|
1463571cd7 | ||
|
|
7dfb0a81e3 | ||
|
|
9699d9467a | ||
|
|
08a2872527 | ||
|
|
7c81a807ea | ||
|
|
3bf7031e6a | ||
|
|
503fc980f4 | ||
|
|
efed11eb97 | ||
|
|
330820062f | ||
|
|
45d157fe3f | ||
|
|
812dea385c | ||
|
|
c582bdea46 | ||
|
|
e6c6a9381b | ||
|
|
4b4c0755c6 | ||
|
|
aeb0539c91 | ||
|
|
9feafa45f5 | ||
|
|
927df391f3 | ||
|
|
cbef6adeb1 | ||
|
|
2dee221861 | ||
|
|
0b175cb25d | ||
|
|
0820338b55 | ||
|
|
a2b46eee6f | ||
|
|
09a435320a | ||
|
|
bf56200c06 | ||
|
|
2d18df2011 | ||
|
|
bab87c0da8 | ||
|
|
148f272500 | ||
|
|
6de4af727b | ||
|
|
75946b9d14 | ||
|
|
1c63ee6743 | ||
|
|
efdaf0d986 | ||
|
|
3f6aeac33d | ||
|
|
d9692004cc | ||
|
|
67a12eecad | ||
|
|
37999e0870 | ||
|
|
66dc1e94f5 | ||
|
|
ebcce194a0 | ||
|
|
95eab94c80 | ||
|
|
41a6dbe06c | ||
|
|
fa22b0ec12 | ||
|
|
be60a367e8 | ||
|
|
608de34205 | ||
|
|
0a8f2edb05 | ||
|
|
41b08f38c5 |
11
.travis.yml
@@ -1,11 +1,10 @@
|
|||||||
|
|
||||||
jdk:
|
jdk:
|
||||||
- openjdk8
|
- openjdk8
|
||||||
script:
|
script:
|
||||||
- "git clone --depth=1 --branch=master https://github.com/Anuken/Arc ../Arc"
|
- "git clone --depth=1 --branch=master https://github.com/Anuken/Arc ../Arc"
|
||||||
- "./gradlew test"
|
- "./gradlew test"
|
||||||
- "./gradlew desktop:dist -Pbuildversion=${TRAVIS_TAG:1}"
|
- "./gradlew desktop:dist -Pbuildversion=${TRAVIS_TAG:1}"
|
||||||
- "./gradlew server:dist -Pbuildversion=${TRAVIS_TAG:1}"
|
- "./gradlew server:dist -Pbuildversion=${TRAVIS_TAG:1}"
|
||||||
|
|
||||||
deploy:
|
deploy:
|
||||||
provider: releases
|
provider: releases
|
||||||
|
|||||||
@@ -2,11 +2,10 @@
|
|||||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
package="io.anuke.mindustry">
|
package="io.anuke.mindustry">
|
||||||
|
|
||||||
<uses-feature android:glEsVersion="0x00020000" android:required="true" />
|
<uses-feature android:glEsVersion="0x00020000" android:required="true"/>
|
||||||
<uses-permission android:name="com.android.vending.BILLING" />
|
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
|
||||||
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
|
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
|
||||||
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
|
<uses-permission android:name="android.permission.INTERNET"/>
|
||||||
<uses-permission android:name="android.permission.INTERNET" />
|
|
||||||
|
|
||||||
<application
|
<application
|
||||||
android:resizeableActivity="false"
|
android:resizeableActivity="false"
|
||||||
@@ -17,7 +16,7 @@
|
|||||||
android:appCategory="game"
|
android:appCategory="game"
|
||||||
android:label="@string/app_name"
|
android:label="@string/app_name"
|
||||||
android:theme="@style/GdxTheme" android:fullBackupContent="@xml/backup_rules">
|
android:theme="@style/GdxTheme" android:fullBackupContent="@xml/backup_rules">
|
||||||
<meta-data android:name="android.max_aspect" android:value="2.1" />
|
<meta-data android:name="android.max_aspect" android:value="2.1"/>
|
||||||
<activity
|
<activity
|
||||||
android:name="io.anuke.mindustry.AndroidLauncher"
|
android:name="io.anuke.mindustry.AndroidLauncher"
|
||||||
android:label="@string/app_name"
|
android:label="@string/app_name"
|
||||||
@@ -25,8 +24,8 @@
|
|||||||
android:configChanges="keyboard|keyboardHidden|orientation|screenSize|screenLayout">
|
android:configChanges="keyboard|keyboardHidden|orientation|screenSize|screenLayout">
|
||||||
|
|
||||||
<intent-filter>
|
<intent-filter>
|
||||||
<action android:name="android.intent.action.MAIN" />
|
<action android:name="android.intent.action.MAIN"/>
|
||||||
<category android:name="android.intent.category.LAUNCHER" />
|
<category android:name="android.intent.category.LAUNCHER"/>
|
||||||
</intent-filter>
|
</intent-filter>
|
||||||
|
|
||||||
<intent-filter>
|
<intent-filter>
|
||||||
@@ -34,7 +33,7 @@
|
|||||||
<category android:name="android.intent.category.DEFAULT"/>
|
<category android:name="android.intent.category.DEFAULT"/>
|
||||||
<category android:name="android.intent.category.BROWSABLE"/>
|
<category android:name="android.intent.category.BROWSABLE"/>
|
||||||
<data android:mimeType="application/octet-stream"/>
|
<data android:mimeType="application/octet-stream"/>
|
||||||
<data android:scheme="file" android:host="*" android:pathPattern=".*\\.mmap" />
|
<data android:scheme="file" android:host="*" android:pathPattern=".*\\.mmap"/>
|
||||||
</intent-filter>
|
</intent-filter>
|
||||||
|
|
||||||
<intent-filter>
|
<intent-filter>
|
||||||
@@ -42,29 +41,25 @@
|
|||||||
<category android:name="android.intent.category.DEFAULT"/>
|
<category android:name="android.intent.category.DEFAULT"/>
|
||||||
<category android:name="android.intent.category.BROWSABLE"/>
|
<category android:name="android.intent.category.BROWSABLE"/>
|
||||||
<data android:mimeType="application/octet-stream"/>
|
<data android:mimeType="application/octet-stream"/>
|
||||||
<data android:scheme="file" android:host="*" android:pathPattern=".*\\.msav" />
|
<data android:scheme="file" android:host="*" android:pathPattern=".*\\.msav"/>
|
||||||
</intent-filter>
|
</intent-filter>
|
||||||
|
|
||||||
|
|
||||||
<intent-filter android:icon="@mipmap/ic_launcher"
|
<intent-filter android:icon="@mipmap/ic_launcher"
|
||||||
android:label="Mindustry Map"
|
android:label="Mindustry Map"
|
||||||
android:priority="1">
|
android:priority="1">
|
||||||
<action android:name="android.intent.action.VIEW" />
|
<action android:name="android.intent.action.VIEW"/>
|
||||||
<category android:name="android.intent.category.DEFAULT" />
|
<category android:name="android.intent.category.DEFAULT"/>
|
||||||
<data android:scheme="file" android:host="*" android:pathPattern=".*\\.mmap" android:mimeType="*/*" />
|
<data android:scheme="file" android:host="*" android:pathPattern=".*\\.mmap" android:mimeType="*/*"/>
|
||||||
</intent-filter>
|
</intent-filter>
|
||||||
|
|
||||||
<intent-filter>
|
<intent-filter>
|
||||||
<action android:name="android.intent.action.VIEW" />
|
<action android:name="android.intent.action.VIEW"/>
|
||||||
<category android:name="android.intent.category.DEFAULT" />
|
<category android:name="android.intent.category.DEFAULT"/>
|
||||||
<data android:scheme="file" android:host="*" android:pathPattern=".*\\.msav" android:mimeType="*/*" />
|
<data android:scheme="file" android:host="*" android:pathPattern=".*\\.msav" android:mimeType="*/*"/>
|
||||||
</intent-filter>
|
</intent-filter>
|
||||||
</activity>
|
</activity>
|
||||||
|
|
||||||
|
|
||||||
<activity android:name=".DonationsActivity"
|
|
||||||
android:theme="@style/GdxTheme" />
|
|
||||||
|
|
||||||
</application>
|
</application>
|
||||||
|
|
||||||
</manifest>
|
</manifest>
|
||||||
|
|||||||
@@ -1,35 +1,32 @@
|
|||||||
buildscript {
|
buildscript{
|
||||||
repositories {
|
repositories{
|
||||||
mavenLocal()
|
mavenLocal()
|
||||||
mavenCentral()
|
mavenCentral()
|
||||||
google()
|
google()
|
||||||
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
|
maven{ url "https://oss.sonatype.org/content/repositories/snapshots/" }
|
||||||
jcenter()
|
jcenter()
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies{
|
||||||
classpath 'com.android.tools.build:gradle:3.3.2'
|
classpath 'com.android.tools.build:gradle:3.4.0'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
apply plugin: "com.android.application"
|
apply plugin: "com.android.application"
|
||||||
|
|
||||||
configurations { natives }
|
configurations{ natives }
|
||||||
|
|
||||||
repositories {
|
repositories{
|
||||||
mavenCentral()
|
mavenCentral()
|
||||||
jcenter()
|
jcenter()
|
||||||
maven {
|
maven{
|
||||||
url "https://maven.google.com"
|
url "https://maven.google.com"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies{
|
||||||
implementation project(":core")
|
implementation project(":core")
|
||||||
implementation project(":net")
|
implementation project(":net")
|
||||||
implementation 'com.android.support:support-v4:28.0.0'
|
|
||||||
implementation 'org.sufficientlysecure:donations:2.5'
|
|
||||||
implementation 'com.google.android.gms:play-services-auth:16.0.1'
|
|
||||||
|
|
||||||
implementation arcModule("backends:backend-android")
|
implementation arcModule("backends:backend-android")
|
||||||
natives "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-armeabi"
|
natives "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-armeabi"
|
||||||
@@ -47,16 +44,16 @@ dependencies {
|
|||||||
task deploy(type: Copy){
|
task deploy(type: Copy){
|
||||||
dependsOn "assembleRelease"
|
dependsOn "assembleRelease"
|
||||||
|
|
||||||
from "build/outputs/apk/google/release/android-google-release.apk"
|
from "build/outputs/apk/release/android-release.apk"
|
||||||
into "../deploy/"
|
into "../deploy/"
|
||||||
rename ("android-google-release.apk", appName + "-android-" + getVersionString() + ".apk")
|
rename("android-release.apk", appName + "-android-" + getVersionString() + ".apk")
|
||||||
}
|
}
|
||||||
|
|
||||||
android {
|
android{
|
||||||
buildToolsVersion '28.0.3'
|
buildToolsVersion '28.0.3'
|
||||||
compileSdkVersion 28
|
compileSdkVersion 28
|
||||||
sourceSets {
|
sourceSets{
|
||||||
main {
|
main{
|
||||||
manifest.srcFile 'AndroidManifest.xml'
|
manifest.srcFile 'AndroidManifest.xml'
|
||||||
java.srcDirs = ['src']
|
java.srcDirs = ['src']
|
||||||
aidl.srcDirs = ['src']
|
aidl.srcDirs = ['src']
|
||||||
@@ -68,11 +65,11 @@ android {
|
|||||||
|
|
||||||
androidTest.setRoot('tests')
|
androidTest.setRoot('tests')
|
||||||
}
|
}
|
||||||
packagingOptions {
|
packagingOptions{
|
||||||
exclude 'META-INF/robovm/ios/robovm.xml'
|
exclude 'META-INF/robovm/ios/robovm.xml'
|
||||||
}
|
}
|
||||||
|
|
||||||
defaultConfig {
|
defaultConfig{
|
||||||
def vfile = file('../core/assets/version.properties')
|
def vfile = file('../core/assets/version.properties')
|
||||||
|
|
||||||
def code = 0
|
def code = 0
|
||||||
@@ -96,22 +93,16 @@ android {
|
|||||||
versionName versionNameResult
|
versionName versionNameResult
|
||||||
}
|
}
|
||||||
|
|
||||||
compileOptions {
|
compileOptions{
|
||||||
sourceCompatibility JavaVersion.VERSION_1_8
|
sourceCompatibility JavaVersion.VERSION_1_8
|
||||||
targetCompatibility JavaVersion.VERSION_1_8
|
targetCompatibility JavaVersion.VERSION_1_8
|
||||||
}
|
}
|
||||||
|
|
||||||
flavorDimensions "google"
|
flavorDimensions "google"
|
||||||
|
|
||||||
productFlavors {
|
signingConfigs{
|
||||||
google {
|
release{
|
||||||
buildConfigField "boolean", "DONATIONS_GOOGLE", "true"
|
if(project.hasProperty("RELEASE_STORE_FILE")){
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
signingConfigs {
|
|
||||||
release {
|
|
||||||
if(project.hasProperty("RELEASE_STORE_FILE")) {
|
|
||||||
storeFile file(RELEASE_STORE_FILE)
|
storeFile file(RELEASE_STORE_FILE)
|
||||||
storePassword RELEASE_STORE_PASSWORD
|
storePassword RELEASE_STORE_PASSWORD
|
||||||
keyAlias RELEASE_KEY_ALIAS
|
keyAlias RELEASE_KEY_ALIAS
|
||||||
@@ -122,8 +113,8 @@ android {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
buildTypes {
|
buildTypes{
|
||||||
release {
|
release{
|
||||||
signingConfig signingConfigs.release
|
signingConfig signingConfigs.release
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -131,22 +122,22 @@ android {
|
|||||||
// called every time gradle gets executed, takes the native dependencies of
|
// called every time gradle gets executed, takes the native dependencies of
|
||||||
// the natives configuration, and extracts them to the proper libs/ folders
|
// the natives configuration, and extracts them to the proper libs/ folders
|
||||||
// so they get packed with the APK.
|
// so they get packed with the APK.
|
||||||
task copyAndroidNatives() {
|
task copyAndroidNatives(){
|
||||||
file("libs/armeabi/").mkdirs()
|
file("libs/armeabi/").mkdirs()
|
||||||
file("libs/armeabi-v7a/").mkdirs()
|
file("libs/armeabi-v7a/").mkdirs()
|
||||||
file("libs/arm64-v8a/").mkdirs()
|
file("libs/arm64-v8a/").mkdirs()
|
||||||
file("libs/x86_64/").mkdirs()
|
file("libs/x86_64/").mkdirs()
|
||||||
file("libs/x86/").mkdirs()
|
file("libs/x86/").mkdirs()
|
||||||
|
|
||||||
configurations.natives.files.each { jar ->
|
configurations.natives.files.each{ jar ->
|
||||||
def outputDir = null
|
def outputDir = null
|
||||||
if (jar.name.endsWith("natives-arm64-v8a.jar")) outputDir = file("libs/arm64-v8a")
|
if(jar.name.endsWith("natives-arm64-v8a.jar")) outputDir = file("libs/arm64-v8a")
|
||||||
if (jar.name.endsWith("natives-armeabi-v7a.jar")) outputDir = file("libs/armeabi-v7a")
|
if(jar.name.endsWith("natives-armeabi-v7a.jar")) outputDir = file("libs/armeabi-v7a")
|
||||||
if (jar.name.endsWith("natives-armeabi.jar")) outputDir = file("libs/armeabi")
|
if(jar.name.endsWith("natives-armeabi.jar")) outputDir = file("libs/armeabi")
|
||||||
if (jar.name.endsWith("natives-x86_64.jar")) outputDir = file("libs/x86_64")
|
if(jar.name.endsWith("natives-x86_64.jar")) outputDir = file("libs/x86_64")
|
||||||
if (jar.name.endsWith("natives-x86.jar")) outputDir = file("libs/x86")
|
if(jar.name.endsWith("natives-x86.jar")) outputDir = file("libs/x86")
|
||||||
if (outputDir != null) {
|
if(outputDir != null){
|
||||||
copy {
|
copy{
|
||||||
from zipTree(jar)
|
from zipTree(jar)
|
||||||
into outputDir
|
into outputDir
|
||||||
include "*.so"
|
include "*.so"
|
||||||
@@ -155,21 +146,21 @@ task copyAndroidNatives() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
task run(type: Exec) {
|
task run(type: Exec){
|
||||||
def path
|
def path
|
||||||
def localProperties = project.file("../local.properties")
|
def localProperties = project.file("../local.properties")
|
||||||
if (localProperties.exists()) {
|
if(localProperties.exists()){
|
||||||
Properties properties = new Properties()
|
Properties properties = new Properties()
|
||||||
localProperties.withInputStream { instr ->
|
localProperties.withInputStream{ instr ->
|
||||||
properties.load(instr)
|
properties.load(instr)
|
||||||
}
|
}
|
||||||
def sdkDir = properties.getProperty('sdk.dir')
|
def sdkDir = properties.getProperty('sdk.dir')
|
||||||
if (sdkDir) {
|
if(sdkDir){
|
||||||
path = sdkDir
|
path = sdkDir
|
||||||
} else {
|
}else{
|
||||||
path = "$System.env.ANDROID_HOME"
|
path = "$System.env.ANDROID_HOME"
|
||||||
}
|
}
|
||||||
} else {
|
}else{
|
||||||
path = "$System.env.ANDROID_HOME"
|
path = "$System.env.ANDROID_HOME"
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -178,19 +169,19 @@ task run(type: Exec) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// sets up the Android Idea project, using the old Ant based build.
|
// sets up the Android Idea project, using the old Ant based build.
|
||||||
idea {
|
idea{
|
||||||
module {
|
module{
|
||||||
sourceDirs += file("src")
|
sourceDirs += file("src")
|
||||||
scopes = [COMPILE: [plus: [project.configurations.compile]]]
|
scopes = [COMPILE: [plus: [project.configurations.compile]]]
|
||||||
|
|
||||||
iml {
|
iml{
|
||||||
withXml {
|
withXml{
|
||||||
def node = it.asNode()
|
def node = it.asNode()
|
||||||
def builder = NodeBuilder.newInstance()
|
def builder = NodeBuilder.newInstance()
|
||||||
builder.current = node
|
builder.current = node
|
||||||
builder.component(name: "FacetManager") {
|
builder.component(name: "FacetManager"){
|
||||||
facet(type: "android", name: "Android") {
|
facet(type: "android", name: "Android"){
|
||||||
configuration {
|
configuration{
|
||||||
option(name: "UPDATE_PROPERTY_FILES", value: "true")
|
option(name: "UPDATE_PROPERTY_FILES", value: "true")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -9,6 +9,5 @@
|
|||||||
#
|
#
|
||||||
# To enable ProGuard to shrink and obfuscate your code, uncomment this (available properties: sdk.dir, user.home):
|
# To enable ProGuard to shrink and obfuscate your code, uncomment this (available properties: sdk.dir, user.home):
|
||||||
#proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt
|
#proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt
|
||||||
|
|
||||||
# Project target.
|
# Project target.
|
||||||
target=android-19
|
target=android-19
|
||||||
|
|||||||
|
Before Width: | Height: | Size: 20 KiB |
@@ -1,32 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
|
||||||
xmlns:tools="http://schemas.android.com/tools"
|
|
||||||
android:layout_width="fill_parent"
|
|
||||||
android:layout_height="fill_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:background="#000">
|
|
||||||
|
|
||||||
<RelativeLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent">
|
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:layout_gravity="top"
|
|
||||||
android:adjustViewBounds="false"
|
|
||||||
android:contentDescription="background"
|
|
||||||
android:cropToPadding="false"
|
|
||||||
android:scaleType="centerCrop"
|
|
||||||
android:src="@drawable/background" />
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/donations_activity_container"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical">
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
</RelativeLayout>
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<resources>
|
|
||||||
|
|
||||||
<string name="app_name">Mindustry</string>
|
|
||||||
<string-array name="donation_google_catalog_values">
|
|
||||||
<item>1 달러</item>
|
|
||||||
<item>2 달러</item>
|
|
||||||
<item>5 달러</item>
|
|
||||||
<item>10 달러</item>
|
|
||||||
<item>15 달러</item>
|
|
||||||
<item>25 달러</item>
|
|
||||||
<item>50 달러</item>
|
|
||||||
</string-array>
|
|
||||||
|
|
||||||
</resources>
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<resources>
|
|
||||||
|
|
||||||
<string name="app_name">Mindustry</string>
|
|
||||||
<string-array name="donation_google_catalog_values">
|
|
||||||
<item>1 Доллар</item>
|
|
||||||
<item>2 Доллара</item>
|
|
||||||
<item>5 Долларов</item>
|
|
||||||
<item>10 Долларов</item>
|
|
||||||
<item>15 Долларов</item>
|
|
||||||
<item>25 Долларов</item>
|
|
||||||
<item>50 Долларов</item>
|
|
||||||
</string-array>
|
|
||||||
|
|
||||||
</resources>
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<resources>
|
|
||||||
|
|
||||||
<string name="app_name">Mindustry</string>
|
|
||||||
<string-array name="donation_google_catalog_values">
|
|
||||||
<item>1 Доллар</item>
|
|
||||||
<item>2 Доллара</item>
|
|
||||||
<item>5 Долларів</item>
|
|
||||||
<item>10 Долларів</item>
|
|
||||||
<item>15 Долларів</item>
|
|
||||||
<item>25 Долларів</item>
|
|
||||||
<item>50 Долларів</item>
|
|
||||||
</string-array>
|
|
||||||
|
|
||||||
</resources>
|
|
||||||
@@ -2,14 +2,5 @@
|
|||||||
<resources>
|
<resources>
|
||||||
|
|
||||||
<string name="app_name">Mindustry</string>
|
<string name="app_name">Mindustry</string>
|
||||||
<string-array name="donation_google_catalog_values">
|
|
||||||
<item>1 Dollar</item>
|
|
||||||
<item>2 Dollars</item>
|
|
||||||
<item>5 Dollars</item>
|
|
||||||
<item>10 Dollars</item>
|
|
||||||
<item>15 Dollars</item>
|
|
||||||
<item>25 Dollars</item>
|
|
||||||
<item>50 Dollars</item>
|
|
||||||
</string-array>
|
|
||||||
|
|
||||||
</resources>
|
</resources>
|
||||||
@@ -10,11 +10,6 @@ import android.os.Build;
|
|||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import android.provider.Settings.Secure;
|
import android.provider.Settings.Secure;
|
||||||
import android.telephony.TelephonyManager;
|
import android.telephony.TelephonyManager;
|
||||||
import android.util.Log;
|
|
||||||
import com.google.android.gms.common.GoogleApiAvailability;
|
|
||||||
import com.google.android.gms.common.GooglePlayServicesNotAvailableException;
|
|
||||||
import com.google.android.gms.common.GooglePlayServicesRepairableException;
|
|
||||||
import com.google.android.gms.security.ProviderInstaller;
|
|
||||||
import io.anuke.arc.Core;
|
import io.anuke.arc.Core;
|
||||||
import io.anuke.arc.backends.android.surfaceview.AndroidApplication;
|
import io.anuke.arc.backends.android.surfaceview.AndroidApplication;
|
||||||
import io.anuke.arc.backends.android.surfaceview.AndroidApplicationConfiguration;
|
import io.anuke.arc.backends.android.surfaceview.AndroidApplicationConfiguration;
|
||||||
@@ -23,18 +18,15 @@ import io.anuke.arc.function.Consumer;
|
|||||||
import io.anuke.arc.scene.ui.layout.Unit;
|
import io.anuke.arc.scene.ui.layout.Unit;
|
||||||
import io.anuke.arc.util.Strings;
|
import io.anuke.arc.util.Strings;
|
||||||
import io.anuke.arc.util.serialization.Base64Coder;
|
import io.anuke.arc.util.serialization.Base64Coder;
|
||||||
import io.anuke.net.KryoClient;
|
|
||||||
import io.anuke.net.KryoServer;
|
|
||||||
import io.anuke.mindustry.core.Platform;
|
import io.anuke.mindustry.core.Platform;
|
||||||
import io.anuke.mindustry.game.Saves.SaveSlot;
|
import io.anuke.mindustry.game.Saves.SaveSlot;
|
||||||
import io.anuke.mindustry.io.SaveIO;
|
import io.anuke.mindustry.io.SaveIO;
|
||||||
import io.anuke.mindustry.net.Net;
|
import io.anuke.mindustry.net.Net;
|
||||||
import io.anuke.mindustry.ui.dialogs.FileChooser;
|
import io.anuke.mindustry.ui.dialogs.FileChooser;
|
||||||
|
import io.anuke.mindustry.net.ArcNetClient;
|
||||||
|
import io.anuke.mindustry.net.ArcNetServer;
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.*;
|
||||||
import java.io.FileInputStream;
|
|
||||||
import java.io.IOException;
|
|
||||||
import java.io.InputStream;
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
|
||||||
import static io.anuke.mindustry.Vars.*;
|
import static io.anuke.mindustry.Vars.*;
|
||||||
@@ -57,11 +49,6 @@ public class AndroidLauncher extends AndroidApplication{
|
|||||||
moveTaskToBack(true);
|
moveTaskToBack(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public void openDonations(){
|
|
||||||
showDonations();
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String getUUID(){
|
public String getUUID(){
|
||||||
try{
|
try{
|
||||||
@@ -69,7 +56,7 @@ public class AndroidLauncher extends AndroidApplication{
|
|||||||
int len = s.length();
|
int len = s.length();
|
||||||
byte[] data = new byte[len / 2];
|
byte[] data = new byte[len / 2];
|
||||||
for(int i = 0; i < len; i += 2){
|
for(int i = 0; i < len; i += 2){
|
||||||
data[i / 2] = (byte) ((Character.digit(s.charAt(i), 16) << 4)
|
data[i / 2] = (byte)((Character.digit(s.charAt(i), 16) << 4)
|
||||||
+ Character.digit(s.charAt(i + 1), 16));
|
+ Character.digit(s.charAt(i + 1), 16));
|
||||||
}
|
}
|
||||||
String result = new String(Base64Coder.encode(data));
|
String result = new String(Base64Coder.encode(data));
|
||||||
@@ -99,7 +86,7 @@ public class AndroidLauncher extends AndroidApplication{
|
|||||||
if(checkSelfPermission(Manifest.permission.READ_EXTERNAL_STORAGE) != PackageManager.PERMISSION_GRANTED){
|
if(checkSelfPermission(Manifest.permission.READ_EXTERNAL_STORAGE) != PackageManager.PERMISSION_GRANTED){
|
||||||
perms.add(Manifest.permission.READ_EXTERNAL_STORAGE);
|
perms.add(Manifest.permission.READ_EXTERNAL_STORAGE);
|
||||||
}
|
}
|
||||||
requestPermissions(perms.toArray(new String[perms.size()]), PERMISSION_REQUEST_CODE);
|
requestPermissions(perms.toArray(new String[0]), PERMISSION_REQUEST_CODE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -119,20 +106,13 @@ public class AndroidLauncher extends AndroidApplication{
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
try{
|
|
||||||
ProviderInstaller.installIfNeeded(this);
|
|
||||||
}catch(GooglePlayServicesRepairableException e){
|
|
||||||
GoogleApiAvailability apiAvailability = GoogleApiAvailability.getInstance();
|
|
||||||
apiAvailability.getErrorDialog(this, e.getConnectionStatusCode(), 0).show();
|
|
||||||
}catch(GooglePlayServicesNotAvailableException e){
|
|
||||||
Log.e("SecurityException", "Google Play Services not available.");
|
|
||||||
}
|
|
||||||
if(doubleScaleTablets && isTablet(this.getContext())){
|
if(doubleScaleTablets && isTablet(this.getContext())){
|
||||||
Unit.dp.addition = 0.5f;
|
Unit.dp.addition = 0.5f;
|
||||||
}
|
}
|
||||||
|
|
||||||
config.hideStatusBar = true;
|
config.hideStatusBar = true;
|
||||||
Net.setClientProvider(new KryoClient());
|
Net.setClientProvider(new ArcNetClient());
|
||||||
Net.setServerProvider(new KryoServer());
|
Net.setServerProvider(new ArcNetServer());
|
||||||
initialize(new Mindustry(), config);
|
initialize(new Mindustry(), config);
|
||||||
checkFiles(getIntent());
|
checkFiles(getIntent());
|
||||||
}
|
}
|
||||||
@@ -200,22 +180,8 @@ public class AndroidLauncher extends AndroidApplication{
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private boolean isPackageInstalled(String packagename){
|
|
||||||
try{
|
|
||||||
getPackageManager().getPackageInfo(packagename, 0);
|
|
||||||
return true;
|
|
||||||
}catch(Exception e){
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isTablet(Context context){
|
private boolean isTablet(Context context){
|
||||||
TelephonyManager manager = (TelephonyManager) context.getSystemService(Context.TELEPHONY_SERVICE);
|
TelephonyManager manager = (TelephonyManager)context.getSystemService(Context.TELEPHONY_SERVICE);
|
||||||
return manager.getPhoneType() == TelephonyManager.PHONE_TYPE_NONE;
|
return manager != null && manager.getPhoneType() == TelephonyManager.PHONE_TYPE_NONE;
|
||||||
}
|
|
||||||
|
|
||||||
private void showDonations(){
|
|
||||||
Intent intent = new Intent(this, DonationsActivity.class);
|
|
||||||
startActivity(intent);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,73 +0,0 @@
|
|||||||
package io.anuke.mindustry;
|
|
||||||
|
|
||||||
import android.content.Intent;
|
|
||||||
import android.os.Bundle;
|
|
||||||
import android.support.v4.app.Fragment;
|
|
||||||
import android.support.v4.app.FragmentActivity;
|
|
||||||
import android.support.v4.app.FragmentManager;
|
|
||||||
import android.support.v4.app.FragmentTransaction;
|
|
||||||
import android.view.View;
|
|
||||||
import android.widget.Button;
|
|
||||||
import org.sufficientlysecure.donations.DonationsFragment;
|
|
||||||
|
|
||||||
public class DonationsActivity extends FragmentActivity{
|
|
||||||
/**
|
|
||||||
* Google
|
|
||||||
*/
|
|
||||||
private static final String GOOGLE_PUBKEY = "MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAzG93KhpfBPKTo2jF0yxbWkkmMKwsPNM4SsMj1aDq7vv6n3R+mqJVfprOJxFfJh7JchXTflLIgiaKXFAiU70gJbMTniEWnEaFSxAeF09a7U0RjOwN+7rFwjCG91c2CpYxPanBTQP4zasc1ODPVzq4q6/4ByjhenN71V4WmR08NFIAodcfFPrOkDPil7i8y7cgcd1Ky53U0TS+LLYJttAK3XdTK4s7VE3I5IKoeNa4uwCmIM59R67q2k3cXjLk/nP6MP+y++EzHN/PTiR1sVg4dMP8K31RPw/1QNLPQwJz6Wc872oWwb7xo5gkoXbDc5WPPydsi8F3SyKNaYwzN6CDFQIDAQAB";
|
|
||||||
private static final String[] GOOGLE_CATALOG = new String[]{
|
|
||||||
"mindustry.donation.1", "mindustry.donation.2", "mindustry.donation.5",
|
|
||||||
"mindustry.donation.10", "mindustry.donation.15",
|
|
||||||
"mindustry.donation.25", "mindustry.donation.50"};
|
|
||||||
DonationsFragment donationsFragment;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Called when the activity is first created.
|
|
||||||
*/
|
|
||||||
@Override
|
|
||||||
public void onCreate(Bundle savedInstanceState){
|
|
||||||
super.onCreate(savedInstanceState);
|
|
||||||
|
|
||||||
setTheme(R.style.GdxTheme);
|
|
||||||
|
|
||||||
setContentView(R.layout.donations_activity);
|
|
||||||
|
|
||||||
FragmentTransaction ft = getSupportFragmentManager().beginTransaction();
|
|
||||||
if(BuildConfig.DONATIONS_GOOGLE){
|
|
||||||
donationsFragment = DonationsFragment.newInstance(BuildConfig.DEBUG, true, GOOGLE_PUBKEY, GOOGLE_CATALOG,
|
|
||||||
getResources().getStringArray(R.array.donation_google_catalog_values), false, null, null,
|
|
||||||
null, false, null, null, false, null);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
ft.replace(R.id.donations_activity_container, donationsFragment, "donationsFragment");
|
|
||||||
ft.commit();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void onStart(){
|
|
||||||
super.onStart();
|
|
||||||
Button b = findViewById(org.sufficientlysecure.donations.R.id.donations__google_android_market_donate_button);
|
|
||||||
b.setOnClickListener(view -> {
|
|
||||||
donationsFragment.donateGoogleOnClick(donationsFragment.getView());
|
|
||||||
b.setEnabled(false);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Needed for Google Play In-app Billing. It uses startIntentSenderForResult(). The result is not propagated to
|
|
||||||
* the Fragment like in startActivityForResult(). Thus we need to propagate manually to our Fragment.
|
|
||||||
*/
|
|
||||||
@Override
|
|
||||||
protected void onActivityResult(int requestCode, int resultCode, Intent data){
|
|
||||||
super.onActivityResult(requestCode, resultCode, data);
|
|
||||||
Button b = findViewById(org.sufficientlysecure.donations.R.id.donations__google_android_market_donate_button);
|
|
||||||
b.setEnabled(true);
|
|
||||||
|
|
||||||
FragmentManager fragmentManager = getSupportFragmentManager();
|
|
||||||
Fragment fragment = fragmentManager.findFragmentByTag("donationsFragment");
|
|
||||||
if(fragment != null){
|
|
||||||
fragment.onActivityResult(requestCode, resultCode, data);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
apply plugin: "java"
|
apply plugin: "java"
|
||||||
|
|
||||||
sourceCompatibility = 1.8
|
sourceCompatibility = 1.8
|
||||||
sourceSets.main.java.srcDirs = [ "src/main/java/" ]
|
sourceSets.main.java.srcDirs = ["src/main/java/"]
|
||||||
sourceSets.main.resources.srcDirs = [ "src/main/resources/" ]
|
sourceSets.main.resources.srcDirs = ["src/main/resources/"]
|
||||||
|
|
||||||
|
|||||||
@@ -1,9 +1,6 @@
|
|||||||
package io.anuke.annotations;
|
package io.anuke.annotations;
|
||||||
|
|
||||||
import java.lang.annotation.ElementType;
|
import java.lang.annotation.*;
|
||||||
import java.lang.annotation.Retention;
|
|
||||||
import java.lang.annotation.RetentionPolicy;
|
|
||||||
import java.lang.annotation.Target;
|
|
||||||
|
|
||||||
public class Annotations{
|
public class Annotations{
|
||||||
|
|
||||||
@@ -19,25 +16,25 @@ public class Annotations{
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Marks a class as serializable.*/
|
/** Marks a class as serializable. */
|
||||||
@Target(ElementType.TYPE)
|
@Target(ElementType.TYPE)
|
||||||
@Retention(RetentionPolicy.SOURCE)
|
@Retention(RetentionPolicy.SOURCE)
|
||||||
public @interface Serialize{
|
public @interface Serialize{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Marks a class as a special value type struct. Class name must end in 'Struct'.*/
|
/** Marks a class as a special value type struct. Class name must end in 'Struct'. */
|
||||||
@Target(ElementType.TYPE)
|
@Target(ElementType.TYPE)
|
||||||
@Retention(RetentionPolicy.SOURCE)
|
@Retention(RetentionPolicy.SOURCE)
|
||||||
public @interface Struct{
|
public @interface Struct{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**Marks a field of a struct. Optional.*/
|
/** Marks a field of a struct. Optional. */
|
||||||
@Target(ElementType.FIELD)
|
@Target(ElementType.FIELD)
|
||||||
@Retention(RetentionPolicy.SOURCE)
|
@Retention(RetentionPolicy.SOURCE)
|
||||||
public @interface StructField{
|
public @interface StructField{
|
||||||
/**Size of a struct field in bits. Not valid on booleans or floating point numbers.*/
|
/** Size of a struct field in bits. Not valid on booleans or floating point numbers. */
|
||||||
int value();
|
int value();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,5 @@
|
|||||||
package io.anuke.annotations;
|
package io.anuke.annotations;
|
||||||
|
|
||||||
import io.anuke.annotations.MethodEntry;
|
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
|
||||||
/** Represents a class witha list method entries to include in it. */
|
/** Represents a class witha list method entries to include in it. */
|
||||||
|
|||||||
@@ -1,8 +1,6 @@
|
|||||||
package io.anuke.annotations;
|
package io.anuke.annotations;
|
||||||
|
|
||||||
import io.anuke.annotations.Annotations.Loc;
|
import io.anuke.annotations.Annotations.*;
|
||||||
import io.anuke.annotations.Annotations.PacketPriority;
|
|
||||||
import io.anuke.annotations.Annotations.Variant;
|
|
||||||
|
|
||||||
import javax.lang.model.element.ExecutableElement;
|
import javax.lang.model.element.ExecutableElement;
|
||||||
|
|
||||||
|
|||||||
@@ -1,18 +1,13 @@
|
|||||||
package io.anuke.annotations;
|
package io.anuke.annotations;
|
||||||
|
|
||||||
import com.squareup.javapoet.FieldSpec;
|
import com.squareup.javapoet.*;
|
||||||
import com.squareup.javapoet.JavaFile;
|
|
||||||
import com.squareup.javapoet.TypeSpec;
|
|
||||||
import io.anuke.annotations.Annotations.Loc;
|
import io.anuke.annotations.Annotations.Loc;
|
||||||
import io.anuke.annotations.Annotations.Remote;
|
import io.anuke.annotations.Annotations.Remote;
|
||||||
import io.anuke.annotations.IOFinder.ClassSerializer;
|
import io.anuke.annotations.IOFinder.ClassSerializer;
|
||||||
|
|
||||||
import javax.annotation.processing.*;
|
import javax.annotation.processing.*;
|
||||||
import javax.lang.model.SourceVersion;
|
import javax.lang.model.SourceVersion;
|
||||||
import javax.lang.model.element.Element;
|
import javax.lang.model.element.*;
|
||||||
import javax.lang.model.element.ExecutableElement;
|
|
||||||
import javax.lang.model.element.Modifier;
|
|
||||||
import javax.lang.model.element.TypeElement;
|
|
||||||
import javax.tools.Diagnostic.Kind;
|
import javax.tools.Diagnostic.Kind;
|
||||||
import java.util.*;
|
import java.util.*;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
@@ -21,14 +16,14 @@ import java.util.stream.Collectors;
|
|||||||
/** The annotation processor for generating remote method call code. */
|
/** The annotation processor for generating remote method call code. */
|
||||||
@SupportedSourceVersion(SourceVersion.RELEASE_8)
|
@SupportedSourceVersion(SourceVersion.RELEASE_8)
|
||||||
@SupportedAnnotationTypes({
|
@SupportedAnnotationTypes({
|
||||||
"io.anuke.annotations.Annotations.Remote",
|
"io.anuke.annotations.Annotations.Remote",
|
||||||
"io.anuke.annotations.Annotations.WriteClass",
|
"io.anuke.annotations.Annotations.WriteClass",
|
||||||
"io.anuke.annotations.Annotations.ReadClass",
|
"io.anuke.annotations.Annotations.ReadClass",
|
||||||
})
|
})
|
||||||
public class RemoteMethodAnnotationProcessor extends AbstractProcessor{
|
public class RemoteMethodAnnotationProcessor extends AbstractProcessor{
|
||||||
/** Maximum size of each event packet. */
|
/** Maximum size of each event packet. */
|
||||||
public static final int maxPacketSize = 4096;
|
public static final int maxPacketSize = 4096;
|
||||||
/** Warning on top of each autogenerated file.*/
|
/** Warning on top of each autogenerated file. */
|
||||||
public static final String autogenWarning = "Autogenerated file. Do not modify!\n";
|
public static final String autogenWarning = "Autogenerated file. Do not modify!\n";
|
||||||
/** Name of the base package to put all the generated classes. */
|
/** Name of the base package to put all the generated classes. */
|
||||||
private static final String packageName = "io.anuke.mindustry.gen";
|
private static final String packageName = "io.anuke.mindustry.gen";
|
||||||
@@ -37,7 +32,7 @@ public class RemoteMethodAnnotationProcessor extends AbstractProcessor{
|
|||||||
private static final String readServerName = "RemoteReadServer";
|
private static final String readServerName = "RemoteReadServer";
|
||||||
/** Name of class that handles reading and invoking packets on the client. */
|
/** Name of class that handles reading and invoking packets on the client. */
|
||||||
private static final String readClientName = "RemoteReadClient";
|
private static final String readClientName = "RemoteReadClient";
|
||||||
/**Simple class name of generated class name.*/
|
/** Simple class name of generated class name. */
|
||||||
private static final String callLocation = "Call";
|
private static final String callLocation = "Call";
|
||||||
|
|
||||||
/** Processing round number. */
|
/** Processing round number. */
|
||||||
@@ -115,7 +110,7 @@ public class RemoteMethodAnnotationProcessor extends AbstractProcessor{
|
|||||||
|
|
||||||
//create and add entry
|
//create and add entry
|
||||||
MethodEntry method = new MethodEntry(entry.name, Utils.getMethodName(element), annotation.targets(), annotation.variants(),
|
MethodEntry method = new MethodEntry(entry.name, Utils.getMethodName(element), annotation.targets(), annotation.variants(),
|
||||||
annotation.called(), annotation.unreliable(), annotation.forward(), lastMethodID++, (ExecutableElement) element, annotation.priority());
|
annotation.called(), annotation.unreliable(), annotation.forward(), lastMethodID++, (ExecutableElement)element, annotation.priority());
|
||||||
|
|
||||||
entry.methods.add(method);
|
entry.methods.add(method);
|
||||||
methods.add(method);
|
methods.add(method);
|
||||||
|
|||||||
@@ -3,9 +3,7 @@ package io.anuke.annotations;
|
|||||||
import com.squareup.javapoet.*;
|
import com.squareup.javapoet.*;
|
||||||
import io.anuke.annotations.IOFinder.ClassSerializer;
|
import io.anuke.annotations.IOFinder.ClassSerializer;
|
||||||
|
|
||||||
import javax.lang.model.element.Modifier;
|
import javax.lang.model.element.*;
|
||||||
import javax.lang.model.element.TypeElement;
|
|
||||||
import javax.lang.model.element.VariableElement;
|
|
||||||
import javax.tools.Diagnostic.Kind;
|
import javax.tools.Diagnostic.Kind;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.lang.reflect.Constructor;
|
import java.lang.reflect.Constructor;
|
||||||
@@ -25,7 +23,6 @@ public class RemoteReadGenerator{
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Generates a class for reading remote invoke packets.
|
* Generates a class for reading remote invoke packets.
|
||||||
*
|
|
||||||
* @param entries List of methods to use.
|
* @param entries List of methods to use.
|
||||||
* @param className Simple target class name.
|
* @param className Simple target class name.
|
||||||
* @param packageName Full target package name.
|
* @param packageName Full target package name.
|
||||||
@@ -115,7 +112,7 @@ public class RemoteReadGenerator{
|
|||||||
|
|
||||||
//execute the relevant method before the forward
|
//execute the relevant method before the forward
|
||||||
//if it throws a ValidateException, the method won't be forwarded
|
//if it throws a ValidateException, the method won't be forwarded
|
||||||
readBlock.addStatement("$N." + entry.element.getSimpleName() + "(" + varResult.toString() + ")", ((TypeElement) entry.element.getEnclosingElement()).getQualifiedName().toString());
|
readBlock.addStatement("$N." + entry.element.getSimpleName() + "(" + varResult.toString() + ")", ((TypeElement)entry.element.getEnclosingElement()).getQualifiedName().toString());
|
||||||
|
|
||||||
//call forwarded method, don't forward on the client reader
|
//call forwarded method, don't forward on the client reader
|
||||||
if(entry.forward && entry.where.isServer && needsPlayer){
|
if(entry.forward && entry.where.isServer && needsPlayer){
|
||||||
|
|||||||
@@ -4,10 +4,7 @@ import com.squareup.javapoet.*;
|
|||||||
import io.anuke.annotations.Annotations.Loc;
|
import io.anuke.annotations.Annotations.Loc;
|
||||||
import io.anuke.annotations.IOFinder.ClassSerializer;
|
import io.anuke.annotations.IOFinder.ClassSerializer;
|
||||||
|
|
||||||
import javax.lang.model.element.ExecutableElement;
|
import javax.lang.model.element.*;
|
||||||
import javax.lang.model.element.Modifier;
|
|
||||||
import javax.lang.model.element.TypeElement;
|
|
||||||
import javax.lang.model.element.VariableElement;
|
|
||||||
import javax.tools.Diagnostic.Kind;
|
import javax.tools.Diagnostic.Kind;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.nio.ByteBuffer;
|
import java.nio.ByteBuffer;
|
||||||
@@ -119,7 +116,7 @@ public class RemoteWriteGenerator{
|
|||||||
|
|
||||||
//add the statement to call it
|
//add the statement to call it
|
||||||
method.addStatement("$N." + elem.getSimpleName() + "(" + results.toString() + ")",
|
method.addStatement("$N." + elem.getSimpleName() + "(" + results.toString() + ")",
|
||||||
((TypeElement) elem.getEnclosingElement()).getQualifiedName().toString());
|
((TypeElement)elem.getEnclosingElement()).getQualifiedName().toString());
|
||||||
|
|
||||||
if(methodEntry.local != Loc.both){
|
if(methodEntry.local != Loc.both){
|
||||||
method.endControlFlow();
|
method.endControlFlow();
|
||||||
|
|||||||
@@ -5,13 +5,9 @@ import io.anuke.annotations.Annotations.Serialize;
|
|||||||
|
|
||||||
import javax.annotation.processing.*;
|
import javax.annotation.processing.*;
|
||||||
import javax.lang.model.SourceVersion;
|
import javax.lang.model.SourceVersion;
|
||||||
import javax.lang.model.element.Modifier;
|
import javax.lang.model.element.*;
|
||||||
import javax.lang.model.element.TypeElement;
|
|
||||||
import javax.lang.model.element.VariableElement;
|
|
||||||
import javax.lang.model.util.ElementFilter;
|
import javax.lang.model.util.ElementFilter;
|
||||||
import java.io.DataInput;
|
import java.io.*;
|
||||||
import java.io.DataOutput;
|
|
||||||
import java.io.IOException;
|
|
||||||
import java.lang.reflect.Field;
|
import java.lang.reflect.Field;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
@@ -21,7 +17,7 @@ import java.util.Set;
|
|||||||
"io.anuke.annotations.Annotations.Serialize"
|
"io.anuke.annotations.Annotations.Serialize"
|
||||||
})
|
})
|
||||||
public class SerializeAnnotationProcessor extends AbstractProcessor{
|
public class SerializeAnnotationProcessor extends AbstractProcessor{
|
||||||
/**Target class name.*/
|
/** Target class name. */
|
||||||
private static final String className = "Serialization";
|
private static final String className = "Serialization";
|
||||||
/** Name of the base package to put all the generated classes. */
|
/** Name of the base package to put all the generated classes. */
|
||||||
private static final String packageName = "io.anuke.mindustry.gen";
|
private static final String packageName = "io.anuke.mindustry.gen";
|
||||||
@@ -50,8 +46,21 @@ public class SerializeAnnotationProcessor extends AbstractProcessor{
|
|||||||
classBuilder.addJavadoc(RemoteMethodAnnotationProcessor.autogenWarning);
|
classBuilder.addJavadoc(RemoteMethodAnnotationProcessor.autogenWarning);
|
||||||
MethodSpec.Builder method = MethodSpec.methodBuilder("init").addModifiers(Modifier.PUBLIC, Modifier.STATIC);
|
MethodSpec.Builder method = MethodSpec.methodBuilder("init").addModifiers(Modifier.PUBLIC, Modifier.STATIC);
|
||||||
|
|
||||||
|
TypeName jsonType = ClassName.bestGuess("io.anuke.arc.util.serialization.Json");
|
||||||
|
TypeName jsonValueType = ClassName.bestGuess("io.anuke.arc.util.serialization.JsonValue");
|
||||||
|
TypeName ubJsonWriterType = ClassName.bestGuess("io.anuke.arc.util.serialization.UBJsonWriter");
|
||||||
|
TypeName ubJsonReaderType = ClassName.bestGuess("io.anuke.arc.util.serialization.UBJsonReader");
|
||||||
|
|
||||||
|
classBuilder.addField(jsonType, "bjson", Modifier.STATIC, Modifier.PRIVATE);
|
||||||
|
classBuilder.addField(ubJsonReaderType, "bjsonReader", Modifier.STATIC, Modifier.PRIVATE);
|
||||||
|
classBuilder.addStaticBlock(CodeBlock.builder()
|
||||||
|
.addStatement("bjson = new " + jsonType + "()")
|
||||||
|
.addStatement("bjsonReader = new " + ubJsonReaderType + "()")
|
||||||
|
.build());
|
||||||
|
|
||||||
for(TypeElement elem : elements){
|
for(TypeElement elem : elements){
|
||||||
TypeName type = TypeName.get(elem.asType());
|
TypeName type = TypeName.get(elem.asType());
|
||||||
|
String simpleTypeName = type.toString().substring(type.toString().lastIndexOf('.') + 1);
|
||||||
|
|
||||||
TypeSpec.Builder serializer = TypeSpec.anonymousClassBuilder("")
|
TypeSpec.Builder serializer = TypeSpec.anonymousClassBuilder("")
|
||||||
.addSuperinterface(ParameterizedTypeName.get(
|
.addSuperinterface(ParameterizedTypeName.get(
|
||||||
@@ -70,11 +79,24 @@ public class SerializeAnnotationProcessor extends AbstractProcessor{
|
|||||||
.addException(IOException.class)
|
.addException(IOException.class)
|
||||||
.addModifiers(Modifier.PUBLIC);
|
.addModifiers(Modifier.PUBLIC);
|
||||||
|
|
||||||
|
MethodSpec.Builder jsonWriteMethod = MethodSpec.methodBuilder("write" + simpleTypeName + "Json")
|
||||||
|
.returns(void.class)
|
||||||
|
.addParameter(jsonType, "json")
|
||||||
|
.addParameter(type, "object")
|
||||||
|
.addModifiers(Modifier.PUBLIC, Modifier.STATIC);
|
||||||
|
|
||||||
|
MethodSpec.Builder jsonReadMethod = MethodSpec.methodBuilder("read" + simpleTypeName + "Json")
|
||||||
|
.returns(type)
|
||||||
|
.addParameter(jsonValueType, "value")
|
||||||
|
.addModifiers(Modifier.PUBLIC, Modifier.STATIC);
|
||||||
|
|
||||||
readMethod.addStatement("$L object = new $L()", type, type);
|
readMethod.addStatement("$L object = new $L()", type, type);
|
||||||
|
jsonReadMethod.addStatement("$L object = new $L()", type, type);
|
||||||
|
|
||||||
List<VariableElement> fields = ElementFilter.fieldsIn(Utils.elementUtils.getAllMembers(elem));
|
List<VariableElement> fields = ElementFilter.fieldsIn(Utils.elementUtils.getAllMembers(elem));
|
||||||
for(VariableElement field : fields){
|
for(VariableElement field : fields){
|
||||||
if(field.getModifiers().contains(Modifier.STATIC) || field.getModifiers().contains(Modifier.TRANSIENT) || field.getModifiers().contains(Modifier.PRIVATE)) continue;
|
if(field.getModifiers().contains(Modifier.STATIC) || field.getModifiers().contains(Modifier.TRANSIENT) || field.getModifiers().contains(Modifier.PRIVATE))
|
||||||
|
continue;
|
||||||
|
|
||||||
String name = field.getSimpleName().toString();
|
String name = field.getSimpleName().toString();
|
||||||
String typeName = Utils.typeUtils.erasure(field.asType()).toString().replace('$', '.');
|
String typeName = Utils.typeUtils.erasure(field.asType()).toString().replace('$', '.');
|
||||||
@@ -83,29 +105,57 @@ public class SerializeAnnotationProcessor extends AbstractProcessor{
|
|||||||
if(field.asType().getKind().isPrimitive()){
|
if(field.asType().getKind().isPrimitive()){
|
||||||
writeMethod.addStatement("stream.write" + capName + "(object." + name + ")");
|
writeMethod.addStatement("stream.write" + capName + "(object." + name + ")");
|
||||||
readMethod.addStatement("object." + name + "= stream.read" + capName + "()");
|
readMethod.addStatement("object." + name + "= stream.read" + capName + "()");
|
||||||
|
|
||||||
|
jsonWriteMethod.addStatement("json.writeValue(\"" + name + "\", object." + name + ")");
|
||||||
|
jsonReadMethod.addStatement("if(value.has(\"" + name + "\")) object." + name + "= value.get" + capName + "(\"" + name + "\")");
|
||||||
}else{
|
}else{
|
||||||
writeMethod.addStatement("io.anuke.arc.Core.settings.getSerializer(" + typeName+ ".class).write(stream, object." + name + ")");
|
writeMethod.addStatement("io.anuke.arc.Core.settings.getSerializer(" + typeName + ".class).write(stream, object." + name + ")");
|
||||||
readMethod.addStatement("object." + name + " = (" +typeName+")io.anuke.arc.Core.settings.getSerializer(" + typeName+ ".class).read(stream)");
|
readMethod.addStatement("object." + name + " = (" + typeName + ")io.anuke.arc.Core.settings.getSerializer(" + typeName + ".class).read(stream)");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
readMethod.addStatement("return object");
|
readMethod.addStatement("return object");
|
||||||
|
jsonReadMethod.addStatement("return object");
|
||||||
|
|
||||||
serializer.addMethod(writeMethod.build());
|
serializer.addMethod(writeMethod.build());
|
||||||
serializer.addMethod(readMethod.build());
|
serializer.addMethod(readMethod.build());
|
||||||
|
|
||||||
method.addStatement("io.anuke.arc.Core.settings.setSerializer($N, $L)", Utils.elementUtils.getBinaryName(elem).toString().replace('$', '.') + ".class", serializer.build());
|
method.addStatement("io.anuke.arc.Core.settings.setSerializer($N, $L)", Utils.elementUtils.getBinaryName(elem).toString().replace('$', '.') + ".class", serializer.build());
|
||||||
|
|
||||||
String sname = type.toString().substring(type.toString().lastIndexOf('.') + 1);
|
name(writeMethod, "write" + simpleTypeName);
|
||||||
|
name(readMethod, "read" + simpleTypeName);
|
||||||
name(writeMethod, "write" + sname);
|
|
||||||
name(readMethod, "read" + sname);
|
|
||||||
|
|
||||||
writeMethod.addModifiers(Modifier.STATIC);
|
writeMethod.addModifiers(Modifier.STATIC);
|
||||||
readMethod.addModifiers(Modifier.STATIC);
|
readMethod.addModifiers(Modifier.STATIC);
|
||||||
|
|
||||||
classBuilder.addMethod(writeMethod.build());
|
classBuilder.addMethod(writeMethod.build());
|
||||||
classBuilder.addMethod(readMethod.build());
|
classBuilder.addMethod(readMethod.build());
|
||||||
|
|
||||||
|
classBuilder.addMethod(jsonWriteMethod.build());
|
||||||
|
classBuilder.addMethod(jsonReadMethod.build());
|
||||||
|
|
||||||
|
MethodSpec.Builder binaryJsonWriteMethod = MethodSpec.methodBuilder("write" + simpleTypeName + "StreamJson")
|
||||||
|
.returns(void.class)
|
||||||
|
.addParameter(DataOutput.class, "stream")
|
||||||
|
.addParameter(type, "object")
|
||||||
|
.addException(IOException.class)
|
||||||
|
.addModifiers(Modifier.PUBLIC, Modifier.STATIC)
|
||||||
|
.addStatement("java.io.StringWriter output = new java.io.StringWriter()")
|
||||||
|
.addStatement("bjson.setWriter(output)")
|
||||||
|
.addStatement("bjson.writeObjectStart(" + type + ".class, " + type + ".class)")
|
||||||
|
.addStatement("write" + simpleTypeName + "Json(bjson, object)")
|
||||||
|
.addStatement("bjson.writeObjectEnd()")
|
||||||
|
.addStatement("stream.writeUTF(output.toString())");
|
||||||
|
|
||||||
|
MethodSpec.Builder binaryJsonReadMethod = MethodSpec.methodBuilder("read" + simpleTypeName + "StreamJson")
|
||||||
|
.returns(type)
|
||||||
|
.addParameter(DataInput.class, "stream")
|
||||||
|
.addException(IOException.class)
|
||||||
|
.addModifiers(Modifier.PUBLIC, Modifier.STATIC)
|
||||||
|
.addStatement("return read" + simpleTypeName + "Json(bjson.fromJson(null, stream.readUTF()))");
|
||||||
|
|
||||||
|
classBuilder.addMethod(binaryJsonWriteMethod.build());
|
||||||
|
classBuilder.addMethod(binaryJsonReadMethod.build());
|
||||||
}
|
}
|
||||||
|
|
||||||
classBuilder.addMethod(method.build());
|
classBuilder.addMethod(method.build());
|
||||||
|
|||||||
@@ -1,28 +1,25 @@
|
|||||||
package io.anuke.annotations;
|
package io.anuke.annotations;
|
||||||
|
|
||||||
import com.squareup.javapoet.JavaFile;
|
import com.squareup.javapoet.*;
|
||||||
import com.squareup.javapoet.MethodSpec;
|
|
||||||
import com.squareup.javapoet.TypeName;
|
|
||||||
import com.squareup.javapoet.TypeSpec;
|
|
||||||
import io.anuke.annotations.Annotations.Struct;
|
import io.anuke.annotations.Annotations.Struct;
|
||||||
import io.anuke.annotations.Annotations.StructField;
|
import io.anuke.annotations.Annotations.StructField;
|
||||||
|
|
||||||
import javax.annotation.processing.*;
|
import javax.annotation.processing.*;
|
||||||
import javax.lang.model.SourceVersion;
|
import javax.lang.model.SourceVersion;
|
||||||
import javax.lang.model.element.Modifier;
|
import javax.lang.model.element.*;
|
||||||
import javax.lang.model.element.TypeElement;
|
|
||||||
import javax.lang.model.element.VariableElement;
|
|
||||||
import javax.lang.model.type.TypeKind;
|
import javax.lang.model.type.TypeKind;
|
||||||
import javax.lang.model.util.ElementFilter;
|
import javax.lang.model.util.ElementFilter;
|
||||||
import javax.tools.Diagnostic.Kind;
|
import javax.tools.Diagnostic.Kind;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
|
|
||||||
/**Generates ""value types"" classes that are packed into integer primitives of the most aproppriate size.
|
/**
|
||||||
* It would be nice if Java didn't make crazy hacks like this necessary.*/
|
* Generates ""value types"" classes that are packed into integer primitives of the most aproppriate size.
|
||||||
|
* It would be nice if Java didn't make crazy hacks like this necessary.
|
||||||
|
*/
|
||||||
@SupportedSourceVersion(SourceVersion.RELEASE_8)
|
@SupportedSourceVersion(SourceVersion.RELEASE_8)
|
||||||
@SupportedAnnotationTypes({
|
@SupportedAnnotationTypes({
|
||||||
"io.anuke.annotations.Annotations.Struct"
|
"io.anuke.annotations.Annotations.Struct"
|
||||||
})
|
})
|
||||||
public class StructAnnotationProcessor extends AbstractProcessor{
|
public class StructAnnotationProcessor extends AbstractProcessor{
|
||||||
/** Name of the base package to put all the generated classes. */
|
/** Name of the base package to put all the generated classes. */
|
||||||
@@ -209,7 +206,7 @@ public class StructAnnotationProcessor extends AbstractProcessor{
|
|||||||
throw new IllegalArgumentException("Too many fields, must fit in 64 bits. Curent size: " + size);
|
throw new IllegalArgumentException("Too many fields, must fit in 64 bits. Curent size: " + size);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**returns a type's element size in bits.*/
|
/** returns a type's element size in bits. */
|
||||||
static int typeSize(TypeKind kind) throws IllegalArgumentException{
|
static int typeSize(TypeKind kind) throws IllegalArgumentException{
|
||||||
switch(kind){
|
switch(kind){
|
||||||
case BOOLEAN:
|
case BOOLEAN:
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ public class Utils{
|
|||||||
public static Messager messager;
|
public static Messager messager;
|
||||||
|
|
||||||
public static String getMethodName(Element element){
|
public static String getMethodName(Element element){
|
||||||
return ((TypeElement) element.getEnclosingElement()).getQualifiedName().toString() + "." + element.getSimpleName();
|
return ((TypeElement)element.getEnclosingElement()).getQualifiedName().toString() + "." + element.getSimpleName();
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean isPrimitive(String type){
|
public static boolean isPrimitive(String type){
|
||||||
|
|||||||
10
build.gradle
@@ -89,7 +89,8 @@ allprojects{
|
|||||||
|
|
||||||
try{
|
try{
|
||||||
pfile.createNewFile()
|
pfile.createNewFile()
|
||||||
}catch(Exception ignored){}
|
}catch(Exception ignored){
|
||||||
|
}
|
||||||
|
|
||||||
if(pfile.exists()){
|
if(pfile.exists()){
|
||||||
props.load(new FileInputStream(pfile))
|
props.load(new FileInputStream(pfile))
|
||||||
@@ -112,6 +113,7 @@ allprojects{
|
|||||||
maven{ url "https://oss.sonatype.org/content/repositories/snapshots/" }
|
maven{ url "https://oss.sonatype.org/content/repositories/snapshots/" }
|
||||||
maven{ url "https://oss.sonatype.org/content/repositories/releases/" }
|
maven{ url "https://oss.sonatype.org/content/repositories/releases/" }
|
||||||
maven{ url 'https://jitpack.io' }
|
maven{ url 'https://jitpack.io' }
|
||||||
|
jcenter()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -128,7 +130,7 @@ project(":desktop"){
|
|||||||
compile "com.badlogicgames.gdx:gdx-freetype-platform:$gdxVersion:natives-desktop"
|
compile "com.badlogicgames.gdx:gdx-freetype-platform:$gdxVersion:natives-desktop"
|
||||||
|
|
||||||
compile arcModule("backends:backend-lwjgl3")
|
compile arcModule("backends:backend-lwjgl3")
|
||||||
compile 'com.github.MinnDevelopment:java-discord-rpc:v2.0.0'
|
compile 'com.github.MinnDevelopment:java-discord-rpc:v2.0.2'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -185,7 +187,7 @@ project(":core"){
|
|||||||
task copyGen{
|
task copyGen{
|
||||||
doLast{
|
doLast{
|
||||||
copy{
|
copy{
|
||||||
from("../core/build/classes/java/main/io/anuke/mindustry/gen/"){
|
from("../core/build/generated/sources/annotationProcessor/java/main/io/anuke/mindustry/gen"){
|
||||||
include "**/*.java"
|
include "**/*.java"
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -200,6 +202,7 @@ project(":core"){
|
|||||||
|
|
||||||
compile arcModule("arc-core")
|
compile arcModule("arc-core")
|
||||||
compile arcModule("extensions:freetype")
|
compile arcModule("extensions:freetype")
|
||||||
|
compile arcModule("extensions:arcnet")
|
||||||
if(localArc() && debugged()) compile arcModule("extensions:recorder")
|
if(localArc() && debugged()) compile arcModule("extensions:recorder")
|
||||||
|
|
||||||
compileOnly project(":annotations")
|
compileOnly project(":annotations")
|
||||||
@@ -256,7 +259,6 @@ project(":net"){
|
|||||||
dependencies{
|
dependencies{
|
||||||
compile project(":core")
|
compile project(":core")
|
||||||
compile "org.lz4:lz4-java:1.4.1"
|
compile "org.lz4:lz4-java:1.4.1"
|
||||||
compile 'com.github.Anuken:kryonet:a64d2280880e80566ca1bdaffa55de43e51cad38'
|
|
||||||
compile 'com.github.Anuken:WaifUPnP:05eb46bc577fd7674596946ba288c96c0cedd893'
|
compile 'com.github.Anuken:WaifUPnP:05eb46bc577fd7674596946ba288c96c0cedd893'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
BIN
core/assets-raw/sprites/blocks/environment/creeptree.png
Normal file
|
After Width: | Height: | Size: 10 KiB |
BIN
core/assets-raw/sprites/blocks/environment/dark-metal-large.png
Normal file
|
After Width: | Height: | Size: 310 B |
BIN
core/assets-raw/sprites/blocks/environment/dark-metal1.png
Normal file
|
After Width: | Height: | Size: 1.1 KiB |
BIN
core/assets-raw/sprites/blocks/environment/dark-metal2.png
Normal file
|
After Width: | Height: | Size: 1.2 KiB |
BIN
core/assets-raw/sprites/blocks/environment/dark-panel-1.png
Normal file
|
After Width: | Height: | Size: 1.1 KiB |
BIN
core/assets-raw/sprites/blocks/environment/dark-panel-2.png
Normal file
|
After Width: | Height: | Size: 1.1 KiB |
BIN
core/assets-raw/sprites/blocks/environment/dark-panel-3.png
Normal file
|
After Width: | Height: | Size: 1.1 KiB |
BIN
core/assets-raw/sprites/blocks/environment/dark-panel-4.png
Normal file
|
After Width: | Height: | Size: 1.1 KiB |
BIN
core/assets-raw/sprites/blocks/environment/dark-panel-5.png
Normal file
|
After Width: | Height: | Size: 1.1 KiB |
BIN
core/assets-raw/sprites/blocks/environment/dark-panel-6.png
Normal file
|
After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 336 B |
|
Before Width: | Height: | Size: 116 B |
|
Before Width: | Height: | Size: 120 B |
|
Before Width: | Height: | Size: 114 B |
|
Before Width: | Height: | Size: 105 B |
|
Before Width: | Height: | Size: 115 B |
|
Before Width: | Height: | Size: 121 B |
@@ -4,5 +4,5 @@
|
|||||||
flattenPaths: true,
|
flattenPaths: true,
|
||||||
maxWidth: 2048,
|
maxWidth: 2048,
|
||||||
maxHeight: 2048,
|
maxHeight: 2048,
|
||||||
fast: true,
|
fast: true
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,5 +4,5 @@
|
|||||||
flattenPaths: true,
|
flattenPaths: true,
|
||||||
maxWidth: 1024,
|
maxWidth: 1024,
|
||||||
maxHeight: 1024,
|
maxHeight: 1024,
|
||||||
fast: true,
|
fast: true
|
||||||
}
|
}
|
||||||
|
|||||||
BIN
core/assets-raw/sprites/blocks/environment/pebbles1.png
Normal file
|
After Width: | Height: | Size: 1.1 KiB |
BIN
core/assets-raw/sprites/blocks/environment/pebbles2.png
Normal file
|
After Width: | Height: | Size: 1.1 KiB |
BIN
core/assets-raw/sprites/blocks/environment/pebbles3.png
Normal file
|
After Width: | Height: | Size: 1.1 KiB |
BIN
core/assets-raw/sprites/blocks/environment/saltrocks-large.png
Normal file
|
After Width: | Height: | Size: 1.4 KiB |
BIN
core/assets-raw/sprites/blocks/environment/saltrocks1.png
Normal file
|
After Width: | Height: | Size: 1.2 KiB |
BIN
core/assets-raw/sprites/blocks/environment/saltrocks2.png
Normal file
|
After Width: | Height: | Size: 1.2 KiB |
BIN
core/assets-raw/sprites/blocks/environment/shrubs-large.png
Normal file
|
After Width: | Height: | Size: 680 B |
BIN
core/assets-raw/sprites/blocks/environment/shrubs1.png
Normal file
|
After Width: | Height: | Size: 1.6 KiB |
BIN
core/assets-raw/sprites/blocks/environment/shrubs2.png
Normal file
|
After Width: | Height: | Size: 1.6 KiB |
|
Before Width: | Height: | Size: 201 B After Width: | Height: | Size: 201 B |
BIN
core/assets-raw/sprites/blocks/production/coal-centrifuge.png
Normal file
|
After Width: | Height: | Size: 1.7 KiB |
|
Before Width: | Height: | Size: 125 B |
@@ -4,5 +4,5 @@
|
|||||||
flattenPaths: true,
|
flattenPaths: true,
|
||||||
maxWidth: 2048,
|
maxWidth: 2048,
|
||||||
maxHeight: 2048,
|
maxHeight: 2048,
|
||||||
fast: true,
|
fast: true
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,5 +4,5 @@
|
|||||||
flattenPaths: true,
|
flattenPaths: true,
|
||||||
maxWidth: 1024,
|
maxWidth: 1024,
|
||||||
maxHeight: 1024,
|
maxHeight: 1024,
|
||||||
fast: true,
|
fast: true
|
||||||
}
|
}
|
||||||
|
|||||||
BIN
core/assets-raw/sprites/ui/check-disabled.png
Normal file
|
After Width: | Height: | Size: 1.8 KiB |
BIN
core/assets-raw/sprites/ui/check-on-disabled.png
Normal file
|
After Width: | Height: | Size: 1.9 KiB |
BIN
core/assets-raw/sprites/ui/content-background-noitems.9.png
Normal file
|
After Width: | Height: | Size: 5.0 KiB |
BIN
core/assets-raw/sprites/ui/underline-disabled.9.png
Normal file
|
After Width: | Height: | Size: 3.1 KiB |
BIN
core/assets-raw/sprites_replacement/blocks/environment/coal1.png
Normal file
|
After Width: | Height: | Size: 2.0 KiB |
BIN
core/assets-raw/sprites_replacement/blocks/environment/coal2.png
Normal file
|
After Width: | Height: | Size: 2.1 KiB |
BIN
core/assets-raw/sprites_replacement/blocks/environment/coal3.png
Normal file
|
After Width: | Height: | Size: 1.9 KiB |
|
After Width: | Height: | Size: 2.7 KiB |
|
After Width: | Height: | Size: 2.6 KiB |
|
After Width: | Height: | Size: 2.7 KiB |
|
After Width: | Height: | Size: 2.1 KiB |
|
After Width: | Height: | Size: 1.9 KiB |
|
After Width: | Height: | Size: 1.9 KiB |
|
After Width: | Height: | Size: 1.9 KiB |
|
After Width: | Height: | Size: 3.2 KiB |
|
After Width: | Height: | Size: 1.5 KiB |
|
After Width: | Height: | Size: 1.7 KiB |
|
After Width: | Height: | Size: 1.4 KiB |
|
After Width: | Height: | Size: 1.6 KiB |
|
After Width: | Height: | Size: 1.3 KiB |
|
After Width: | Height: | Size: 1.3 KiB |
|
After Width: | Height: | Size: 1.6 KiB |
|
After Width: | Height: | Size: 1.7 KiB |
|
After Width: | Height: | Size: 1.2 KiB |
|
After Width: | Height: | Size: 1.8 KiB |
|
After Width: | Height: | Size: 1.3 KiB |
|
Before Width: | Height: | Size: 11 KiB |
|
Before Width: | Height: | Size: 11 KiB |
|
After Width: | Height: | Size: 11 KiB |
|
After Width: | Height: | Size: 1.6 KiB |
|
After Width: | Height: | Size: 1.6 KiB |
|
After Width: | Height: | Size: 1.7 KiB |
|
After Width: | Height: | Size: 1.9 KiB |
|
After Width: | Height: | Size: 2.0 KiB |
|
After Width: | Height: | Size: 1.9 KiB |
|
After Width: | Height: | Size: 2.1 KiB |
|
After Width: | Height: | Size: 2.3 KiB |
|
After Width: | Height: | Size: 2.2 KiB |
BIN
core/assets-raw/sprites_replacement/blocks/environment/ice1.png
Normal file
|
After Width: | Height: | Size: 1.8 KiB |
BIN
core/assets-raw/sprites_replacement/blocks/environment/ice2.png
Normal file
|
After Width: | Height: | Size: 1.8 KiB |
BIN
core/assets-raw/sprites_replacement/blocks/environment/ice3.png
Normal file
|
After Width: | Height: | Size: 1.8 KiB |
|
After Width: | Height: | Size: 1.3 KiB |
|
After Width: | Height: | Size: 1.3 KiB |
|
After Width: | Height: | Size: 1.4 KiB |