Compare commits

..

203 Commits
v64 ... v71

Author SHA1 Message Date
Anuken
812dea385c more bugfixes 2019-04-04 22:05:12 -04:00
키에르
c582bdea46 Update bundle_ko.properties (#439)
* Update bundle_ko.properties

* Update bundle_ko.properties

* Update bundle_ko.properties

* Update bundle_ko.properties

* Update bundle_ko.properties

* Update bundle_ko.properties

* Update bundle_ko.properties

* match orignal bundle

* Update bundle_ko.properties

* Update bundle_ko.properties
2019-04-04 19:59:09 -06:00
laohuaji233
e6c6a9381b Update bundle_zh_CN.properties (#440)
* Update bundle_zh_CN.properties

More translations and fixed some wrong words

* Update bundle_zh_CN.properties
2019-04-04 19:58:05 -06:00
VXF
4b4c0755c6 Update bundle_zh_CN.properties (#441) 2019-04-04 19:53:34 -06:00
Prosta4okua
aeb0539c91 Russian bundle (#443)
* Go build communism

* Update bundle_ru.properties

Last commit: minimap

* Update bundle_ru.properties

* Update bundle_ru.properties

* Update bundle_ru.properties

* Update bundle_ru.properties
2019-04-04 19:53:02 -06:00
Prosta4okua
9feafa45f5 Ukrainian bundle (#444)
* No. Routernism is better.

Last commit: bugfixes

* Update bundle_uk_UA.properties

Last commit: minimap

* Update bundle_uk_UA.properties

* Update bundle_uk_UA.properties

* Update bundle_uk_UA.properties
2019-04-04 19:52:09 -06:00
Math2128
927df391f3 Update bundle_fr.properties (#447)
* Update bundle_fr.properties

Haven't done much. If I have more time, I will work on it. If anyone else wants to contribute, make sure not to do the same as me ! :p

* Update bundle_fr.properties

* Update bundle_fr.properties

* Update bundle_fr.properties

Add a bit more. If anyone knows where to find all the filters in the game, please tell me. It'll help me get the word in context

* Update bundle_fr.properties

* Update bundle_fr.properties

* Update bundle_fr.properties

* Update bundle_fr.properties

* Update bundle_fr.properties
2019-04-04 19:50:59 -06:00
Anuken
cbef6adeb1 Crafter bugfixes 2019-04-04 21:49:45 -04:00
Anuken
2dee221861 Crash fix 2019-04-04 20:39:04 -04:00
Anuken
0b175cb25d Fixed release script using wrong folder 2019-04-04 19:36:15 -04:00
Anuken
0820338b55 Moved FPS counter once more / Pulverizer sprite fix 2019-04-04 19:31:17 -04:00
Anuken
a2b46eee6f Improved pixel zoom / Possible player duplicate glitch 2019-04-04 18:58:48 -04:00
Anuken
09a435320a Impact reactor display bugfix 2019-04-04 15:14:45 -04:00
Anuken
bf56200c06 Power amount message for buffered blocks 2019-04-04 15:06:27 -04:00
Anuken
2d18df2011 Multiplayer bugfixes / Balancing 2019-04-04 14:46:41 -04:00
Anuken
bab87c0da8 Default spawn limit bumped to 4 2019-04-04 00:05:59 -04:00
Anuken
148f272500 New rule modifiers 2019-04-04 00:03:19 -04:00
Anuken
6de4af727b JSON read/write generation 2019-04-03 22:24:14 -04:00
Anuken
75946b9d14 Explosion propagation 2019-04-03 09:39:11 -04:00
Anuken
1c63ee6743 Clean pixel zoom 2019-04-02 23:30:40 -04:00
Anuken
efdaf0d986 Balancing, tweaks and bugfixes 2019-04-02 22:43:20 -04:00
Anuken
3f6aeac33d Cleanup of new graphical options 2019-04-02 17:18:55 -04:00
Anuken
d9692004cc Shield optimization 2019-04-02 17:08:22 -04:00
Anuken
67a12eecad Bugfixes 2019-04-02 15:52:44 -04:00
Anuken
37999e0870 Risky building changes 2019-04-02 14:26:23 -04:00
Anuken
66dc1e94f5 Slight entity optimizations / Turret sprite fixes 2019-04-02 13:58:44 -04:00
Anuken
ebcce194a0 Turret coolant use balancing 2019-04-02 11:26:02 -04:00
Anuken
95eab94c80 Fixed liquid blocks not accepting liquids 2019-04-02 10:51:52 -04:00
Anuken
41a6dbe06c Basic minimap 2019-04-01 21:16:22 -04:00
Anuken
fa22b0ec12 Removed dead donations code 2019-04-01 18:51:49 -04:00
Anuken
be60a367e8 Removed donations library and Android support libraries 2019-04-01 18:46:11 -04:00
Anuken
608de34205 Updated bundles 2019-04-01 13:32:49 -04:00
Anuken
0a8f2edb05 Block update unit tests 2019-04-01 11:57:43 -04:00
Anuken
41b08f38c5 Fixed tests 2019-04-01 11:34:10 -04:00
Anuken
a83c0b2e9a "fixes" 2019-03-31 22:27:11 -04:00
Anuken
8f853c8f18 Back button cleanup 2019-03-31 18:26:52 -04:00
Anuken
b4071f6dcb Merge 2019-03-31 18:24:25 -04:00
Anuken
6b70418861 Cleanup 2019-03-31 18:20:38 -04:00
Anuken
de0235ad94 Sweeping rework 2019-03-31 17:49:15 -04:00
Anuken
c278c632b3 Back button quitting 2019-03-31 13:16:43 -04:00
Anuken
6392330e70 Optimizations / Very broken changes 2019-03-31 13:11:12 -04:00
Anuken
160ae4e244 Fixed startup crashing 2019-03-31 10:37:52 -04:00
Anuken
a6c9bd3182 Class cleanup 2019-03-30 23:23:57 -04:00
Anuken
801eadd8a8 Bugfixes 2019-03-30 19:10:06 -04:00
Anuken
211dab1297 Compilation cleanup 2019-03-30 18:48:54 -04:00
Anuken
0c3b39ffdc Merge branches 'avoidance-optimization' and 'master' of https://github.com/Anuken/Mindustry 2019-03-30 13:52:46 -04:00
Anuken
c31f88a318 Fixes 2019-03-30 13:01:55 -04:00
Anuken
e9eb981782 More optimization / Flying avoidance 2019-03-30 12:54:29 -04:00
Anuken
83bde8a781 Improved avoidance 2019-03-30 12:33:01 -04:00
Anuken
52f352bf94 Fixed nondeterministic drill item sorting 2019-03-30 10:16:48 -04:00
Anuken
b419a96d69 Mech balance / Re-added map screenshot 2019-03-30 00:17:29 -04:00
Anuken
eb3d5b62f5 Tweaks 2019-03-29 22:48:04 -04:00
Anuken
1c5f578d88 Initial implementation 2019-03-29 18:48:03 -04:00
Anuken
db3aae1388 Merge remote-tracking branch 'origin/master' 2019-03-29 18:15:31 -04:00
Anuken
0b08eb72a6 Bugfixes 2019-03-29 18:15:22 -04:00
Skybbles // L5474
cbc81376be pulverizer pulverises scrap not stone (#442) 2019-03-29 13:55:45 -06:00
Anuken
27e9901d05 Removed unused shadow methods; minor tweaks 2019-03-29 09:07:46 -04:00
Anuken
532c36677c Map preview block shadows 2019-03-28 22:23:59 -04:00
Anuken
0c20c6ecb7 Removed greek bundle temporarily, as font does not support it 2019-03-28 20:48:34 -04:00
Anuken
fbb3240ebb Hid 0-damage stat to prevent confusion 2019-03-28 19:20:09 -04:00
Anuken
bffae90022 Crash fixes 2019-03-28 17:41:57 -04:00
Anuken
61f6368591 Bundle update 2019-03-28 17:31:22 -04:00
Valen. H
1027ca2a85 Greek (#394)
Made in 2018, might be a bit out of date but seems functional. (4-alpha-63)
**Not complete**
2019-03-28 15:29:11 -06:00
Prosta4okua
5acc42f739 @router & @xzimur Create a PR for the Russian language (#437)
Останній комміт — Code cleanup (97f5bf3cc4 (diff-daade3141498d8856d75ec34b88bbb19))
2019-03-28 15:26:14 -06:00
laohuaji233
1edeaeb94e Update bundle_zh_CN.properties (#436)
more translations
2019-03-28 15:26:08 -06:00
키에르
879acc6077 Update bundle_ko.properties (#435)
* Update bundle_ko.properties

* Oops

* Oops 2

* Update bundle_ko.properties

* Update bundle_ko.properties
2019-03-28 15:25:35 -06:00
Anuken
4e5d87104c Unit AI fixes / Other general fixes 2019-03-28 17:12:49 -04:00
Anuken
e6a24b8ba1 Balancing / Bugfixes / Decreased build duration slightly 2019-03-28 14:38:00 -04:00
Anuken
fd190c7770 UI layout fixes 2019-03-28 12:50:22 -04:00
Anuken
d56869aefa Unit shadows 2019-03-28 12:42:04 -04:00
Anuken
c8a15bb7e4 Shadow optimization: 30 -> 60 FPS on phone tested 2019-03-28 12:19:54 -04:00
Anuken
07c28c3f6d Minor fixes 2019-03-28 11:00:34 -04:00
Anuken
855957b099 Broke all crafting 2019-03-27 23:24:07 -04:00
Anuken
50959317e9 New launch pad / Tech tree tweaks 2019-03-27 22:13:40 -04:00
Anuken
20a681a71f Zone unlocking tweak 2019-03-27 19:21:15 -04:00
Anuken
4e2d558b36 Merge remote-tracking branch 'origin/master' 2019-03-27 09:31:12 -04:00
Anuken
0430b908f4 New requirements for zone unlock, currently broken 2019-03-27 09:31:07 -04:00
Anuken
a84e9f2aaa Updated RoboVM plugin 2019-03-26 20:35:29 -04:00
Anuken
7ce571e59c New tentative edge style / Zone tweaks 2019-03-26 20:10:01 -04:00
Anuken
545a64f7dc Merge remote-tracking branch 'origin/master' 2019-03-26 11:05:55 -04:00
Anuken
10c999a4a2 Bugfixes / Mender block / Extra stats / Balancing 2019-03-26 11:05:47 -04:00
Anuken
d0e026d597 Bugfixes 2019-03-25 13:12:55 -04:00
Anuken
0b1e2bf19b Compile fixes 2019-03-24 21:54:01 -04:00
Anuken
71c2c7ad05 More code cleanup 2019-03-24 21:10:59 -04:00
Anuken
97f5bf3cc4 Code cleanup 2019-03-24 19:58:51 -04:00
Anuken
bb9573b85a Build cost/speed rules 2019-03-24 18:33:07 -04:00
Anuken
e1f53dfc67 Added bundle entries 2019-03-24 17:58:59 -04:00
Anuken
87481e0a4d Ammo stats 2019-03-24 17:55:41 -04:00
Anuken
f7aa58e385 Many small tweaks / Custom rules / Server run files / Balance 2019-03-24 16:29:25 -04:00
Anuken
ea5c78f814 UI scaling fixes 2019-03-23 22:00:41 -04:00
Anuken
c93c016e9c more icons 2019-03-23 19:06:50 -04:00
Anuken
4bb6664c7e Merge remote-tracking branch 'origin/master' 2019-03-23 18:48:00 -04:00
Anuken
9578068a02 another menu attempt 2019-03-23 18:47:57 -04:00
Anuken
30e5f2b17d iOS building fix 2019-03-23 18:33:33 -04:00
Anuken
f959760c07 More iOS icon stuff 2019-03-23 15:05:22 -04:00
Anuken
e7db2350bc Merge remote-tracking branch 'origin/master' 2019-03-23 14:39:08 -04:00
Anuken
0585dabf7a iOS icons 2019-03-23 14:39:04 -04:00
William So
a3c6e3f1df Update 'bundle_zh_TW.properties' (#433)
* Match 'bundle_zh_TW.properties' with 'bundle.properties'

* Update 'bundle_zh_TW.properties'
2019-03-23 11:48:55 -06:00
Prosta4okua
9f57278644 Update bundle_uk_UA.properties (#430)
* Update bundle_uk_UA.properties

* Update bundle_uk_UA.properties

* Update bundle_uk_UA.properties

* Update bundle_uk_UA.properties

* Update bundle_uk_UA.properties

* deleted Ыы

* Update bundle_uk_UA.properties
2019-03-23 11:48:50 -06:00
ScriptHosT12
afc35cf623 Update bundle_pt_BR.properties (#432) 2019-03-23 11:48:37 -06:00
Prosta4okua
6d8523054b Update bundle_ru.properties (#429)
* Update bundle_ru.properties

* Update bundle_ru.properties

* Update bundle_ru.properties

* Update bundle_ru.properties

* Update bundle_ru.properties

* Update bundle_ru.properties
2019-03-23 11:48:31 -06:00
Anuken
fdecd55278 Updated build files 2019-03-23 13:40:13 -04:00
Anuken
7e7f95916b Moved launch button to top right 2019-03-23 11:49:48 -04:00
Anuken
ab52c65dcf Updated bundles 2019-03-23 11:08:46 -04:00
Anuken
ed4d0eb5d0 Shadows setting / Server map text limit / Fallback spritesheet 2019-03-23 11:02:59 -04:00
Anuken
4bc9143306 New icon / Windows deployment fixes / Map fixes / Menu fix 2019-03-22 22:30:26 -04:00
Anuken
a4f558c77a Code cleanup / Tainted water 2019-03-22 19:16:15 -04:00
Anuken
e4f226a9c5 more menu table fighting 2019-03-22 13:58:51 -04:00
Anuken
c7d34049fa Crash fix / Input tweak 2019-03-22 00:16:09 -04:00
Anuken
ee06e620c6 Zone wave bugfix / New tests / More "encouragement" 2019-03-21 19:19:12 -04:00
Anuken
b48110db3b Fixed #431 [item spacing not taken into account] 2019-03-21 17:13:46 -04:00
Anuken
8413046dd8 Crash/visual fixes 2019-03-21 15:37:36 -04:00
Anuken
83a5a82e18 Fixed server map find bug 2019-03-21 11:22:10 -04:00
Anuken
771c5fbe3d Better packr minimization 2019-03-21 11:15:03 -04:00
Anuken
74f16d0137 Reduced drone factory cost 2019-03-21 10:43:04 -04:00
Anuken
5d5d354f7d Balancing 2019-03-21 10:36:33 -04:00
Anuken
8f5f27755d Bugfixes / Allow placing blocks in shallow liquids 2019-03-21 10:16:37 -04:00
Anuken
4cb92cdb06 Fixed some deployment issues 2019-03-21 00:58:06 -04:00
Anuken
9e067ebdd6 Merge remote-tracking branch 'origin/master' 2019-03-21 00:19:10 -04:00
Anuken
fd5fcc9928 Wave editor bugfixes 2019-03-21 00:19:06 -04:00
Prosta4okua
c0b2abb5fd Update bundle_uk_UA.properties (#423)
* Update bundle_uk_UA.properties

* Update bundle_uk_UA.properties

* Update bundle_uk_UA.properties

* Update bundle_uk_UA.properties

* Update bundle_uk_UA.properties

* Update bundle_uk_UA.properties

* Update bundle_uk_UA.properties
2019-03-20 21:04:20 -06:00
Anuken
2c8620a75c Added missing sprites 2019-03-20 22:42:33 -04:00
Anuken
62f6ed0878 Merge remote-tracking branch 'origin/master'
# Conflicts:
#	core/assets/bundles/bundle_ru.properties
2019-03-20 22:41:24 -04:00
Anuken
886b62bbad Too many things to list in a single line commit log 2019-03-20 22:40:47 -04:00
Prosta4okua
4bd58589fc Update bundle_ru.properties (#422)
* Update bundle_ru.properties

* Update bundle_ru.properties

* Update bundle_ru.properties

* Update bundle_ru.properties

* Update bundle_ru.properties

* Update bundle_ru.properties

* Update bundle_ru.properties

* Update bundle_ru.properties

* Update bundle_ru.properties

* Update bundle_ru.properties
2019-03-20 17:37:46 -06:00
키에르
0ce4144767 Update bundle_ko.properties (#425)
* Update bundle_ko.properties

* Update bundle_ko.properties

* Update bundle_ko.properties

91741ec29c

* Update bundle_ko.properties

783f453da3 (diff-daade3141498d8856d75ec34b88bbb19)
2019-03-20 17:16:21 -06:00
bei2
cde945f40e Update Japanese translations (#428)
* Add new japanese translation

It translated on commit 66810c8.
so it don't apply changes from commit 17e0489.

* Update Japanese translation

Applies commit 7a51693. and small changes.

* Upadte Japanese translations

* Update Japanese

* Update Japanese

* Update Japanese translations

Improve and update for new changes

* Update Japanese

* Update Japanese translations

* Update Japanese translations

* Update Japanese translations

* Update Japanese translations

* Update Japanese translations

* Update Japanese translations

* Update Japanese translation

* Update Japanese translations

* Update Japanese translations

* Oops!

* Update Japanese translations

* Update Japanese

* Update Japanese

* Update Japanese translations
2019-03-20 17:14:03 -06:00
Anuken
e2126a2693 Mandatory line placement tutorial 2019-03-20 19:12:14 -04:00
Anuken
c9f6d92bef committing from a phone is hard 2019-03-20 09:58:54 -04:00
Anuken
fbf4c411c1 Map editor fixes / Zone environment changes 2019-03-19 23:51:52 -04:00
Anuken
ce5218db58 Wave editor clipboard save+load / Bugfixes / Balancing 2019-03-19 19:25:48 -04:00
Anuken
e2ea7f9b87 Bundle update 2019-03-19 15:27:19 -04:00
Anuken
94d9f04814 Toggleable diagonals 2019-03-19 15:26:30 -04:00
Anuken
c86dbac04a no snek 2019-03-19 14:01:00 -04:00
Anuken
f36eed32b9 Bugfixes / Balancing 2019-03-19 12:47:09 -04:00
Anuken
cd752209ad Snake cleanup 2019-03-19 11:46:00 -04:00
Anuken
fe37d619b9 Mobile snake 2019-03-19 10:30:13 -04:00
Anuken
043f4688ef snakes 2019-03-18 23:09:03 -04:00
Anuken
949f171579 Fixed ores not spawning in certain maps 2019-03-18 09:29:27 -04:00
Anuken
87d586a30e More boulders 2019-03-17 18:35:33 -04:00
Anuken
783f453da3 Generate tool bugfixes / Map edits / New blocks 2019-03-17 18:30:33 -04:00
Anuken
6dcf889ffe Map tweaks 2019-03-17 14:04:55 -04:00
Anuken
8d44879cc6 Power/wave dialog fixes 2019-03-17 12:03:48 -04:00
Anuken
e7b813962d Bugfixes 2019-03-16 22:59:50 -04:00
Anuken
22fadab3b3 Fixed units patrolling too quickly / Editor bugfixes 2019-03-16 13:25:50 -04:00
Anuken
91741ec29c Enemy indicators 2019-03-16 12:44:45 -04:00
Anuken
8269d842ce Removed redundant zone waves / Fixed wave dialog float issue 2019-03-16 10:13:49 -04:00
Anuken
d038bdb6ce Better filter layout 2019-03-15 20:32:08 -04:00
Anuken
6cef301b94 Filter localization / Ore filter / Pick tool ore compatibility 2019-03-15 20:19:09 -04:00
Anuken
e7ffbd817c Improved generation tool 2019-03-15 15:06:55 -04:00
Anuken
97067a6ee2 heck 2019-03-15 10:25:27 -04:00
Anuken
7d1a8f5404 Unfinished generation tool 2019-03-15 00:13:54 -04:00
Anuken
43bcf0cf3b Fixed unit icons / New scatter AA turret 2019-03-14 16:37:07 -04:00
Anuken
71751ee18d Fixed build error / Minor wave info dialog correction / Bugfix 2019-03-14 14:12:08 -04:00
Anuken
ed105b102d Custom wave patterns / Fixed checkbox sprite / Bugfixes 2019-03-14 14:01:22 -04:00
Anuken
f2662045ed New item bars / Map bugfixes / Stub wave editing 2019-03-13 21:26:53 -04:00
Anuken
ecb77b0283 Fortress builtin map / Attributes / Efficiency stat / Bugfixes 2019-03-12 23:39:39 -04:00
Anuken
4d4869842e Bugfixes 2019-03-12 16:37:32 -04:00
BLucky-gh
47300b42b0 Add instructions to change permissions (#415) 2019-03-12 13:09:06 -06:00
Andreas Heiskanen
609565af5f Tests: Add tests for addDarkness() in World.java (#412)
* Tests: Add tests for addDarkness() in World.java

Add Junit tests for the addDarkness found in core/src/io/anuke/mindustry/core/World.java

* Refactor: Remove code duplication

Remove code duplication in WorldTests. Invoke launchApplication directly from ApplicationTests.

* BugFix: Assign Tiles[][] tiles used for testing. 

Add assignment of Tiles[][] tiles separately when invoking ApplicationTests.launchApplication.
2019-03-12 13:08:35 -06:00
Anuken
0c75f920de Fixed editor placing blocks at 0 health 2019-03-12 14:57:10 -04:00
Anuken
e7b51f313b Merge branches 'master' and 'new-map-format' of https://github.com/Anuken/Mindustry 2019-03-12 13:50:48 -04:00
Anuken
e8204fc983 Fixed misc compile errors 2019-03-12 13:46:40 -04:00
Anuken
aa69af64fb Fixed some ores not loading in correctly / Conflict check 2019-03-12 13:42:20 -04:00
Anuken
41f734b04d Fixed legacy maps loading with no team 2019-03-12 13:35:25 -04:00
Anuken
8ad6f3abcc New ore system / Multiblock fixes 2019-03-12 13:28:00 -04:00
Anuken
e4875903f1 More fixes 2019-03-12 11:31:14 -04:00
Anuken
0a04de04f1 Format bugfixes 2019-03-12 11:07:02 -04:00
Anuken
20427fdffa Implemented correct map loading, legacy format support 2019-03-12 10:36:04 -04:00
Anuken
0fd0abc6c0 Fixed compile errors / New non-crappy undo system 2019-03-11 23:06:41 -04:00
Anuken
70f7fc29d4 Cleanup 2019-03-11 17:18:37 -04:00
Anuken
b0c1aff783 Heal bullet effect fix / Spawned ID sync / Crash fix 2019-03-11 14:54:15 -04:00
Anuken
4909c28ed9 Better low-FPS predict 2019-03-11 14:33:39 -04:00
Anuken
9e6745f691 Fixed polluted water 2019-03-11 13:34:15 -04:00
Anuken
6c3ccb259f Some errors fixed 2019-03-11 13:27:15 -04:00
Anuken
6c8d80777c Removed useless name mapping / Cleanup 2019-03-11 11:43:23 -04:00
Anuken
2db61f93ac Balance 2019-03-11 09:28:50 -04:00
Anuken
ad059cbc38 Unfinished RLE 2019-03-11 09:26:35 -04:00
Anuken
87e7e04c5e Balance 2019-03-11 08:29:18 -04:00
Anuken
c083d059c9 Progress 2019-03-11 08:25:03 -04:00
Anuken
ebd44d3b60 Merge 2019-03-10 22:51:04 -04:00
Anuken
51f5d04889 Work on map format upgrade 2019-03-10 22:47:09 -04:00
Anuken
0f4d574115 New unfinished environment blocks / Bugfixes / Tech tree tweak 2019-03-10 22:38:53 -04:00
Anuken
1feb4a5e6d Tar shader / Spritesheet split / Font cleanup 2019-03-10 11:11:16 -04:00
키에르
f861b75c7d Fix fonts (#424)
* Fix fonts

* Add more fonts & bundle update

* Increase font size
2019-03-10 08:03:54 -06:00
Anuken
3530ca8989 Fixed more tests 2019-03-10 00:21:21 -05:00
Anuken
6b074ed4b2 Fixed some tests failing 2019-03-10 00:10:33 -05:00
Anuken
671823b4fa Tentative travis build fix 2019-03-09 23:55:01 -05:00
Anuken
8ceebf1546 More UDP 2019-03-09 23:10:47 -05:00
Anuken
376495836a ok 2019-03-09 23:06:55 -05:00
Anuken
98212df076 Water shader 2019-03-09 22:53:16 -05:00
Anuken
1316c9235a Made inventory hide on second tap / Mobile rotation arrow 2019-03-09 19:43:33 -05:00
Anuken
a0905d5695 Faster, smaller server / Bundle check cleanup 2019-03-09 19:12:54 -05:00
Anuken
2a35e22dd2 Merge remote-tracking branch 'origin/master' 2019-03-09 16:47:12 -05:00
Anuken
f86a07daee Removed awt use / Sand recolor / Bugfixes / Link fix 2019-03-09 16:47:08 -05:00
키에르
997628622a bundle upgrade for beta version (#421)
* Update bundle_ko.properties

* Update bundle_ko.properties
2019-03-09 09:19:17 -07:00
Anuken
563e015c92 Fixed power bug 2019-03-09 09:51:12 -05:00
Anuken
64533de597 Bugfixes / Font changed / Zone tweaks 2019-03-08 19:07:23 -05:00
Anuken
3776b99c39 nothing 2019-03-06 17:36:47 -05:00
Anuken
6f07576748 Merge branches 'master' and 'new-map-format' of https://github.com/Anuken/Mindustry into new-map-format
# Conflicts:
#	core/src/io/anuke/mindustry/editor/MapEditorDialog.java
#	core/src/io/anuke/mindustry/io/MapIO.java
#	core/src/io/anuke/mindustry/maps/MapTileData.java
2019-01-23 13:52:36 -05:00
Anuken
550a11962e Fixed compile errors in MapIO 2019-01-23 09:23:34 -05:00
Anuken
6d01193e1e Tweaks 2019-01-15 23:04:27 -05:00
Anuken
8c3d6d05ab broken stuff 2019-01-15 22:16:02 -05:00
591 changed files with 26475 additions and 10593 deletions

1
.gitignore vendored
View File

@@ -28,6 +28,7 @@ logs/
/ios/src/io/anuke/mindustry/gen/ /ios/src/io/anuke/mindustry/gen/
/core/src/io/anuke/mindustry/gen/ /core/src/io/anuke/mindustry/gen/
ios/robovm.properties ios/robovm.properties
packr-out/
config/ config/
*.gif *.gif

View File

@@ -2,6 +2,7 @@
jdk: jdk:
- openjdk8 - openjdk8
script: script:
- "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}"

View File

@@ -29,6 +29,10 @@ _Building:_ `./gradlew desktop:dist`
Server builds are bundled with each released build (in Releases). If you'd rather compile on your own, replace 'desktop' with 'server', e.g. `gradlew server:dist`. Server builds are bundled with each released build (in Releases). If you'd rather compile on your own, replace 'desktop' with 'server', e.g. `gradlew server:dist`.
##### Troubleshooting
If the terminal returns `Permission denied` or `Command not found` on Mac/Linux, run `chmod +x ./gradlew` before running `./gradlew`. *This is a one-time procedure.*
--- ---
Gradle may take up to several minutes to download files. Be patient. <br> Gradle may take up to several minutes to download files. Be patient. <br>

View File

@@ -3,7 +3,6 @@
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" />

View File

@@ -8,7 +8,7 @@ buildscript {
} }
dependencies { dependencies {
classpath 'com.android.tools.build:gradle:3.3.1' classpath 'com.android.tools.build:gradle:3.3.2'
} }
} }
@@ -27,9 +27,6 @@ repositories {
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,9 +44,9 @@ 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 {
@@ -103,12 +100,6 @@ android {
flavorDimensions "google" flavorDimensions "google"
productFlavors {
google {
buildConfigField "boolean", "DONATIONS_GOOGLE", "true"
}
}
signingConfigs { signingConfigs {
release { release {
if(project.hasProperty("RELEASE_STORE_FILE")) { if(project.hasProperty("RELEASE_STORE_FILE")) {

Binary file not shown.

Before

Width:  |  Height:  |  Size: 24 KiB

After

Width:  |  Height:  |  Size: 76 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 911 B

After

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 23 KiB

View File

@@ -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>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.3 KiB

After

Width:  |  Height:  |  Size: 6.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

After

Width:  |  Height:  |  Size: 7.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.6 KiB

After

Width:  |  Height:  |  Size: 8.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.1 KiB

After

Width:  |  Height:  |  Size: 7.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.6 KiB

After

Width:  |  Height:  |  Size: 4.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 553 B

After

Width:  |  Height:  |  Size: 4.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.1 KiB

After

Width:  |  Height:  |  Size: 5.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.4 KiB

After

Width:  |  Height:  |  Size: 4.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.4 KiB

After

Width:  |  Height:  |  Size: 9.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

After

Width:  |  Height:  |  Size: 9.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.0 KiB

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.1 KiB

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 9.0 KiB

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.4 KiB

After

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.1 KiB

After

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 14 KiB

After

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 23 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.0 KiB

After

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.1 KiB

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

After

Width:  |  Height:  |  Size: 28 KiB

View File

@@ -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>

View File

@@ -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>

View File

@@ -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>

View File

@@ -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>

View File

@@ -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;
@@ -53,8 +48,8 @@ public class AndroidLauncher extends AndroidApplication{
Platform.instance = new Platform(){ Platform.instance = new Platform(){
@Override @Override
public void openDonations(){ public void hide(){
showDonations(); moveTaskToBack(true);
} }
@Override @Override
@@ -94,13 +89,13 @@ 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);
} }
} }
@Override @Override
public void beginForceLandscape(){ public void beginForceLandscape(){
setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE); setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_SENSOR_LANDSCAPE);
} }
@Override @Override
@@ -114,17 +109,10 @@ 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 KryoClient());
Net.setServerProvider(new KryoServer()); Net.setServerProvider(new KryoServer());
@@ -133,7 +121,7 @@ public class AndroidLauncher extends AndroidApplication{
} }
@Override @Override
public void onRequestPermissionsResult(int requestCode, String permissions[], int[] grantResults){ public void onRequestPermissionsResult(int requestCode, String[] permissions, int[] grantResults){
if(requestCode == PERMISSION_REQUEST_CODE){ if(requestCode == PERMISSION_REQUEST_CODE){
for(int i : grantResults){ for(int i : grantResults){
if(i != PackageManager.PERMISSION_GRANTED) return; if(i != PackageManager.PERMISSION_GRANTED) return;
@@ -178,12 +166,14 @@ public class AndroidLauncher extends AndroidApplication{
ui.showError("$save.import.invalid"); ui.showError("$save.import.invalid");
} }
}else if(map){ //open map }else if(map){ //open map
FileHandle file = Core.files.local("temp-map." + mapExtension);
file.write(inStream, false);
Core.app.post(() -> { Core.app.post(() -> {
System.out.println("Opening map."); System.out.println("Opening map.");
if(!ui.editor.isShown()){ if(!ui.editor.isShown()){
ui.editor.show(); ui.editor.show();
} }
ui.editor.beginEditMap(inStream); ui.editor.beginEditMap(file);
}); });
} }
}); });
@@ -193,22 +183,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);
} }
} }

View File

@@ -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);
}
}
}

View File

@@ -7,6 +7,18 @@ import java.lang.annotation.Target;
public class Annotations{ public class Annotations{
@Target({ElementType.METHOD, ElementType.FIELD})
@Retention(RetentionPolicy.SOURCE)
public @interface Nullable{
}
@Target({ElementType.METHOD, ElementType.FIELD})
@Retention(RetentionPolicy.SOURCE)
public @interface NonNull{
}
/** Marks a class as serializable.*/ /** Marks a class as serializable.*/
@Target(ElementType.TYPE) @Target(ElementType.TYPE)
@Retention(RetentionPolicy.SOURCE) @Retention(RetentionPolicy.SOURCE)

View File

@@ -109,7 +109,7 @@ public class RemoteWriteGenerator{
for(VariableElement var : elem.getParameters()){ for(VariableElement var : elem.getParameters()){
//special case: calling local-only methods uses the local player //special case: calling local-only methods uses the local player
if(index == 0 && methodEntry.where == Loc.client){ if(index == 0 && methodEntry.where == Loc.client){
results.append("io.anuke.mindustry.Vars.players[0]"); results.append("io.anuke.mindustry.Vars.player");
}else{ }else{
results.append(var.getSimpleName()); results.append(var.getSimpleName());
} }

View File

@@ -50,8 +50,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,7 +83,19 @@ 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){
@@ -83,6 +108,9 @@ 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)");
@@ -90,22 +118,47 @@ public class SerializeAnnotationProcessor extends AbstractProcessor{
} }
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());

View File

@@ -129,7 +129,7 @@ public class StructAnnotationProcessor extends AbstractProcessor{
//floats: need conversion //floats: need conversion
setter.addStatement("return ($T)(($L & $L) | (($T)Float.floatToIntBits(value) << $LL))", structType, structParam, bitString(offset, size, structTotalSize), structType, offset); setter.addStatement("return ($T)(($L & $L) | (($T)Float.floatToIntBits(value) << $LL))", structType, structParam, bitString(offset, size, structTotalSize), structType, offset);
}else{ }else{
cons.append(" | (").append("(").append(structType).append(")").append(varName).append(" << ").append(offset).append("L)"); cons.append(" | (((").append(structType).append(")").append(varName).append(" << ").append(offset).append("L)").append(" & ").append(bitString(offset, size, structTotalSize)).append(")");
//bytes, shorts, chars, ints //bytes, shorts, chars, ints
setter.addStatement("return ($T)(($L & $L) | (($T)value << $LL))", structType, structParam, bitString(offset, size, structTotalSize), structType, offset); setter.addStatement("return ($T)(($L & $L) | (($T)value << $LL))", structType, structParam, bitString(offset, size, structTotalSize), structType, offset);

View File

@@ -8,8 +8,9 @@ buildscript{
} }
dependencies{ dependencies{
classpath 'com.mobidevelop.robovm:robovm-gradle-plugin:2.3.5' classpath 'com.mobidevelop.robovm:robovm-gradle-plugin:2.3.6'
classpath "com.badlogicgames.gdx:gdx-tools:1.9.9" classpath "com.badlogicgames.gdx:gdx-tools:1.9.9"
classpath "com.badlogicgames.packr:packr:2.1-SNAPSHOT"
} }
} }
@@ -24,15 +25,15 @@ allprojects{
if(!project.hasProperty("versionType")) versionType = 'official' if(!project.hasProperty("versionType")) versionType = 'official'
appName = 'Mindustry' appName = 'Mindustry'
gdxVersion = '1.9.9' gdxVersion = '1.9.9'
roboVMVersion = '2.3.0' roboVMVersion = '2.3.6'
arcHash = null arcHash = null
debugged = { debugged = {
return new File(projectDir.parent, '../debug').exists() && System.properties["release"] == null return new File(projectDir.parent, '../debug').exists() && !project.hasProperty("release")
} }
localArc = { localArc = {
return (System.properties["release"] == null || System.properties["release"] == "false") && new File(projectDir.parent, '../Arc').exists() return (!project.hasProperty("release")) && new File(projectDir.parent, '../Arc').exists()
} }
getArcHash = { getArcHash = {
@@ -42,7 +43,7 @@ allprojects{
arcHash = 'git ls-remote https://github.com/Anuken/Arc.git'.execute().text.split("\t")[0] arcHash = 'git ls-remote https://github.com/Anuken/Arc.git'.execute().text.split("\t")[0]
}catch(e){ }catch(e){
e.printStackTrace() e.printStackTrace()
arcHash = "-SNAPSHOT"; arcHash = "-SNAPSHOT"
} }
} }
return arcHash return arcHash
@@ -155,6 +156,7 @@ project(":ios"){
dependencies{ dependencies{
compile project(":core") compile project(":core")
compile project(":net") compile project(":net")
compileOnly project(":annotations")
compile arcModule("backends:backend-robovm") compile arcModule("backends:backend-robovm")

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 1018 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

View File

Before

Width:  |  Height:  |  Size: 405 B

After

Width:  |  Height:  |  Size: 405 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.3 KiB

After

Width:  |  Height:  |  Size: 354 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.2 KiB

After

Width:  |  Height:  |  Size: 168 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.0 KiB

After

Width:  |  Height:  |  Size: 155 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.1 KiB

After

Width:  |  Height:  |  Size: 291 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.3 KiB

After

Width:  |  Height:  |  Size: 170 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.6 KiB

After

Width:  |  Height:  |  Size: 294 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 94 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 105 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 94 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 195 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 578 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 189 B

After

Width:  |  Height:  |  Size: 190 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 121 B

After

Width:  |  Height:  |  Size: 121 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 118 B

After

Width:  |  Height:  |  Size: 118 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 354 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 127 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 125 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 129 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 390 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1005 B

After

Width:  |  Height:  |  Size: 100 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 999 B

After

Width:  |  Height:  |  Size: 100 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 KiB

After

Width:  |  Height:  |  Size: 100 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

After

Width:  |  Height:  |  Size: 135 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 132 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

After

Width:  |  Height:  |  Size: 132 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 KiB

After

Width:  |  Height:  |  Size: 97 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1015 B

After

Width:  |  Height:  |  Size: 90 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 KiB

After

Width:  |  Height:  |  Size: 112 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 116 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 120 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 114 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1018 B

After

Width:  |  Height:  |  Size: 105 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 KiB

After

Width:  |  Height:  |  Size: 115 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 121 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 KiB

After

Width:  |  Height:  |  Size: 115 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 106 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 102 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 104 B

View File

@@ -0,0 +1,8 @@
{
duplicatePadding: true,
combineSubdirectories: true,
flattenPaths: true,
maxWidth: 2048,
maxHeight: 2048,
fast: true,
}

View File

@@ -0,0 +1,8 @@
{
duplicatePadding: true,
combineSubdirectories: true,
flattenPaths: true,
maxWidth: 1024,
maxHeight: 1024,
fast: true,
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 128 B

After

Width:  |  Height:  |  Size: 143 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 92 B

After

Width:  |  Height:  |  Size: 96 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 103 B

After

Width:  |  Height:  |  Size: 107 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 92 B

After

Width:  |  Height:  |  Size: 96 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 195 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 122 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 119 B

View File

Before

Width:  |  Height:  |  Size: 132 B

After

Width:  |  Height:  |  Size: 132 B

View File

Before

Width:  |  Height:  |  Size: 129 B

After

Width:  |  Height:  |  Size: 129 B

Some files were not shown because too many files have changed in this diff Show More