diff --git a/core/assets-raw/sprites/blocks/turrets/laserturret-heat.png b/core/assets-raw/sprites/blocks/turrets/laserturret-heat.png new file mode 100644 index 0000000000..c2b0d734d0 Binary files /dev/null and b/core/assets-raw/sprites/blocks/turrets/laserturret-heat.png differ diff --git a/core/assets/sprites/sprites.atlas b/core/assets/sprites/sprites.atlas index b12d2c2647..982c04dafb 100644 --- a/core/assets/sprites/sprites.atlas +++ b/core/assets/sprites/sprites.atlas @@ -13,42 +13,42 @@ background index: -1 conduit-bottom rotate: false - xy: 602, 188 + xy: 612, 188 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 conduit-top rotate: false - xy: 600, 178 + xy: 600, 168 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 conduittunnel rotate: false - xy: 612, 188 + xy: 610, 178 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 conveyor rotate: false - xy: 590, 158 + xy: 622, 188 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 conveyormove rotate: false - xy: 600, 168 + xy: 590, 148 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 conveyortunnel rotate: false - xy: 610, 178 + xy: 600, 158 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -62,42 +62,42 @@ core index: -1 junction rotate: false - xy: 453, 144 + xy: 443, 134 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 liquidjunction rotate: false - xy: 473, 144 + xy: 453, 124 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 liquidrouter rotate: false - xy: 443, 114 + xy: 463, 134 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 liquidrouter-bottom rotate: false - xy: 453, 124 + xy: 483, 144 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 liquidrouter-liquid rotate: false - xy: 463, 134 + xy: 453, 114 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 liquidrouter-top rotate: false - xy: 483, 144 + xy: 463, 124 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -132,70 +132,70 @@ multiplexer index: -1 poweredconveyor rotate: false - xy: 483, 134 + xy: 483, 124 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 poweredconveyormove rotate: false - xy: 473, 114 + xy: 493, 134 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 pulseconduit-bottom rotate: false - xy: 493, 124 + xy: 503, 143 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 pulseconduit-top rotate: false - xy: 493, 114 + xy: 503, 133 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 router rotate: false - xy: 533, 143 + xy: 533, 133 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 sortedunloader rotate: false - xy: 593, 138 + xy: 603, 138 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 sorter rotate: false - xy: 593, 128 + xy: 593, 118 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 splitter rotate: false - xy: 603, 138 + xy: 603, 128 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 steelconveyor rotate: false - xy: 593, 118 + xy: 613, 138 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 steelconveyormove rotate: false - xy: 603, 128 + xy: 603, 118 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -209,7 +209,7 @@ teleporter-top index: -1 unloader rotate: false - xy: 877, 405 + xy: 897, 405 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -223,7 +223,7 @@ vault index: -1 vault-icon rotate: false - xy: 887, 405 + xy: 907, 405 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -237,56 +237,56 @@ weaponfactory index: -1 blackrock1 rotate: false - xy: 149, 16 + xy: 726, 390 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 blackrockshadow1 rotate: false - xy: 149, 6 + xy: 736, 390 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 blackstone1 rotate: false - xy: 716, 389 + xy: 746, 390 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 blackstone2 rotate: false - xy: 726, 390 + xy: 756, 394 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 blackstone3 rotate: false - xy: 736, 390 + xy: 766, 394 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 blackstoneblock1 rotate: false - xy: 746, 390 + xy: 1003, 411 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 blackstoneblock2 rotate: false - xy: 756, 394 + xy: 1013, 411 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 blackstoneblock3 rotate: false - xy: 766, 394 + xy: 218, 60 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -300,49 +300,49 @@ blackstoneedge index: -1 coal1 rotate: false - xy: 613, 198 + xy: 643, 198 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 coal2 rotate: false - xy: 623, 198 + xy: 592, 188 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 coal3 rotate: false - xy: 633, 198 + xy: 590, 178 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 deepwater rotate: false - xy: 590, 148 + xy: 620, 178 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 dirt1 rotate: false - xy: 600, 158 + xy: 632, 188 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 dirt2 rotate: false - xy: 610, 168 + xy: 600, 148 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 dirt3 rotate: false - xy: 620, 178 + xy: 610, 158 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -356,35 +356,35 @@ dirtedge index: -1 grass1 rotate: false - xy: 620, 158 + xy: 620, 148 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 grass2 rotate: false - xy: 630, 168 + xy: 630, 158 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 grass3 rotate: false - xy: 640, 178 + xy: 640, 168 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 grassblock1 rotate: false - xy: 620, 148 + xy: 630, 148 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 grassblock2 rotate: false - xy: 630, 158 + xy: 640, 158 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -398,21 +398,21 @@ grassedge index: -1 ice1 rotate: false - xy: 640, 168 + xy: 640, 148 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 ice2 rotate: false - xy: 630, 148 + xy: 363, 113 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 ice3 rotate: false - xy: 640, 158 + xy: 373, 114 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -426,70 +426,70 @@ iceedge index: -1 icerock1 rotate: false - xy: 640, 148 + xy: 383, 114 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 icerock2 rotate: false - xy: 363, 113 + xy: 393, 113 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 icerockshadow1 rotate: false - xy: 373, 114 + xy: 403, 113 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 rockshadow1 rotate: false - xy: 373, 114 + xy: 403, 113 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 icerockshadow2 rotate: false - xy: 383, 114 + xy: 413, 113 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 rockshadow2 rotate: false - xy: 383, 114 + xy: 413, 113 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 iron1 rotate: false - xy: 393, 113 + xy: 677, 281 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 iron2 rotate: false - xy: 403, 113 + xy: 687, 281 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 iron3 rotate: false - xy: 413, 113 + xy: 697, 281 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 lava rotate: false - xy: 433, 124 + xy: 463, 144 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -503,35 +503,35 @@ lavaedge index: -1 lead1 rotate: false - xy: 463, 144 + xy: 443, 124 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 lead2 rotate: false - xy: 433, 114 + xy: 453, 134 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 lead3 rotate: false - xy: 443, 124 + xy: 473, 144 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 mossblock rotate: false - xy: 473, 134 + xy: 463, 114 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 oil rotate: false - xy: 493, 144 + xy: 473, 124 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -545,56 +545,56 @@ oiledge index: -1 rock1 rotate: false - xy: 513, 123 + xy: 533, 143 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 rock2 rotate: false - xy: 523, 133 + xy: 523, 123 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 sand1 rotate: false - xy: 543, 143 + xy: 543, 133 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 sand2 rotate: false - xy: 533, 123 + xy: 553, 143 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 sand3 rotate: false - xy: 543, 133 + xy: 543, 123 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 sandblock1 rotate: false - xy: 553, 143 + xy: 553, 133 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 sandblock2 rotate: false - xy: 543, 123 + xy: 563, 143 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 sandblock3 rotate: false - xy: 553, 133 + xy: 553, 123 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -608,56 +608,56 @@ sandedge index: -1 shrub rotate: false - xy: 523, 113 + xy: 543, 113 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 shrubshadow rotate: false - xy: 533, 113 + xy: 553, 113 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 snow1 rotate: false - xy: 563, 113 + xy: 573, 126 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 snow2 rotate: false - xy: 573, 136 + xy: 573, 116 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 snow3 rotate: false - xy: 573, 126 + xy: 583, 136 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 snowblock1 rotate: false - xy: 573, 116 + xy: 583, 126 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 snowblock2 rotate: false - xy: 583, 136 + xy: 583, 116 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 snowblock3 rotate: false - xy: 583, 126 + xy: 593, 138 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -671,42 +671,42 @@ snowedge index: -1 stone1 rotate: false - xy: 613, 118 + xy: 633, 138 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 stone2 rotate: false - xy: 623, 128 + xy: 623, 118 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 stone3 rotate: false - xy: 633, 138 + xy: 633, 128 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 stoneblock1 rotate: false - xy: 623, 118 + xy: 643, 138 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 stoneblock2 rotate: false - xy: 633, 128 + xy: 633, 118 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 stoneblock3 rotate: false - xy: 643, 138 + xy: 643, 128 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -720,49 +720,49 @@ stoneedge index: -1 thorium1 rotate: false - xy: 653, 128 + xy: 777, 405 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 thorium2 rotate: false - xy: 653, 118 + xy: 787, 405 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 thorium3 rotate: false - xy: 777, 405 + xy: 797, 405 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 titanium1 rotate: false - xy: 787, 405 + xy: 807, 405 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 titanium2 rotate: false - xy: 797, 405 + xy: 817, 405 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 titanium3 rotate: false - xy: 807, 405 + xy: 827, 405 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 water rotate: false - xy: 917, 405 + xy: 937, 405 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -776,28 +776,28 @@ wateredge index: -1 block-middle rotate: false - xy: 228, 60 + xy: 613, 198 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 pump-liquid rotate: false - xy: 228, 60 + xy: 613, 198 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 conduit-liquid rotate: false - xy: 590, 168 + xy: 590, 158 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 cross-1 rotate: false - xy: 622, 188 + xy: 610, 168 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -825,35 +825,35 @@ cross-4 index: -1 enemyspawn rotate: false - xy: 630, 178 + xy: 620, 158 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 playerspawn rotate: false - xy: 473, 124 + xy: 473, 114 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 ripples rotate: false - xy: 933, 415 + xy: 945, 415 size: 10, 10 orig: 10, 10 offset: 0, 0 index: -1 shadow rotate: false - xy: 945, 415 + xy: 957, 415 size: 10, 10 orig: 10, 10 offset: 0, 0 index: -1 battery rotate: false - xy: 129, 11 + xy: 129, 1 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -867,14 +867,14 @@ batterylarge index: -1 combustiongenerator rotate: false - xy: 643, 198 + xy: 602, 188 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 combustiongenerator-top rotate: false - xy: 592, 188 + xy: 590, 168 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -944,7 +944,7 @@ largesolarpanel index: -1 liquidcombustiongenerator rotate: false - xy: 453, 134 + xy: 443, 114 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -972,14 +972,14 @@ nuclearreactor-lights index: -1 powerinfinite rotate: false - xy: 483, 124 + xy: 483, 114 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 powernode rotate: false - xy: 493, 134 + xy: 493, 124 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -993,28 +993,28 @@ powernodelarge index: -1 powervoid rotate: false - xy: 483, 114 + xy: 493, 114 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 rtgenerator rotate: false - xy: 523, 123 + xy: 543, 143 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 rtgenerator-top rotate: false - xy: 533, 133 + xy: 533, 123 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 shieldgenerator rotate: false - xy: 563, 133 + xy: 503, 113 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -1028,7 +1028,7 @@ shieldprojector index: -1 solarpanel rotate: false - xy: 583, 116 + xy: 593, 128 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -1042,14 +1042,14 @@ teleporter index: -1 thermalgenerator rotate: false - xy: 653, 138 + xy: 653, 118 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 alloysmelter rotate: false - xy: 139, 16 + xy: 129, 11 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -1154,56 +1154,56 @@ cultivator-top index: -1 extractor rotate: false - xy: 642, 188 + xy: 630, 168 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 fluxpump rotate: false - xy: 610, 148 + xy: 640, 178 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 irondrill rotate: false - xy: 677, 281 + xy: 151, 16 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 irondrill-rotator rotate: false - xy: 687, 281 + xy: 756, 384 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 titaniumdrill-rotator rotate: false - xy: 687, 281 + xy: 756, 384 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 irondrill-top rotate: false - xy: 697, 281 + xy: 766, 384 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 itemsource rotate: false - xy: 443, 144 + xy: 453, 144 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 itemvoid rotate: false - xy: 433, 134 + xy: 433, 124 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -1231,21 +1231,21 @@ laserdrill-top index: -1 lavasmelter rotate: false - xy: 443, 134 + xy: 433, 114 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 liquidsource rotate: false - xy: 453, 114 + xy: 473, 134 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 melter rotate: false - xy: 463, 124 + xy: 493, 144 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -1308,7 +1308,7 @@ oilextractor-top index: -1 oilrefinery rotate: false - xy: 463, 114 + xy: 483, 134 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -1392,63 +1392,63 @@ siliconsmelter-top index: -1 pulverizer rotate: false - xy: 503, 143 + xy: 513, 143 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 pulverizer-rotator rotate: false - xy: 503, 133 + xy: 503, 123 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 pump rotate: false - xy: 513, 143 + xy: 513, 133 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 reinforceddrill rotate: false - xy: 503, 123 + xy: 523, 143 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 reinforceddrill-rotator rotate: false - xy: 513, 133 + xy: 513, 123 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 reinforceddrill-top rotate: false - xy: 523, 143 + xy: 523, 133 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 separator rotate: false - xy: 563, 143 + xy: 563, 133 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 separator-liquid rotate: false - xy: 553, 123 + xy: 563, 123 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 siliconextractor rotate: false - xy: 543, 113 + xy: 563, 113 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -1462,56 +1462,56 @@ siliconsmelter index: -1 smelter rotate: false - xy: 553, 113 + xy: 573, 136 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 steeldrill rotate: false - xy: 613, 138 + xy: 613, 128 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 steeldrill-rotator rotate: false - xy: 603, 118 + xy: 623, 138 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 steeldrill-top rotate: false - xy: 613, 128 + xy: 613, 118 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 stonedrill rotate: false - xy: 633, 118 + xy: 643, 118 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 stoneformer rotate: false - xy: 643, 128 + xy: 653, 138 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 titaniumdrill rotate: false - xy: 817, 405 + xy: 837, 405 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 titaniumdrill-top rotate: false - xy: 827, 405 + xy: 847, 405 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -1546,7 +1546,7 @@ waterextractor-top index: -1 block-1 rotate: false - xy: 218, 60 + xy: 603, 198 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -1588,7 +1588,7 @@ chainturret index: -1 doubleturret rotate: false - xy: 610, 158 + xy: 642, 188 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -1663,6 +1663,13 @@ laserturret orig: 10, 10 offset: 0, 0 index: -1 +laserturret-heat + rotate: false + xy: 897, 415 + size: 10, 10 + orig: 10, 10 + offset: 0, 0 + index: -1 magmaturret rotate: false xy: 720, 400 @@ -1686,35 +1693,35 @@ missileturret index: -1 railgunturret rotate: false - xy: 897, 415 + xy: 909, 415 size: 10, 10 orig: 10, 10 offset: 0, 0 index: -1 railgunturret-heat rotate: false - xy: 909, 415 + xy: 921, 415 size: 10, 10 orig: 10, 10 offset: 0, 0 index: -1 repairturret rotate: false - xy: 921, 415 + xy: 933, 415 size: 10, 10 orig: 10, 10 offset: 0, 0 index: -1 shotgunturret rotate: false - xy: 957, 415 + xy: 969, 415 size: 10, 10 orig: 10, 10 offset: 0, 0 index: -1 teslaturret rotate: false - xy: 969, 415 + xy: 139, 14 size: 10, 10 orig: 10, 10 offset: 0, 0 @@ -1770,14 +1777,14 @@ walkerfactory-top-open index: -1 compositewall rotate: false - xy: 590, 178 + xy: 600, 178 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 door rotate: false - xy: 632, 188 + xy: 620, 168 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -1798,14 +1805,14 @@ door-large-open index: -1 door-open rotate: false - xy: 600, 148 + xy: 630, 178 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 duriumwall rotate: false - xy: 620, 168 + xy: 610, 148 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -1819,14 +1826,14 @@ duriumwall-large index: -1 ironwall rotate: false - xy: 756, 384 + xy: 653, 198 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 steelwall rotate: false - xy: 623, 138 + xy: 623, 128 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -1840,21 +1847,21 @@ steelwall-large index: -1 stonewall rotate: false - xy: 643, 118 + xy: 653, 128 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 titaniumshieldwall rotate: false - xy: 837, 405 + xy: 857, 405 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 titaniumwall rotate: false - xy: 847, 405 + xy: 867, 405 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -1938,91 +1945,91 @@ shell-back index: -1 shot rotate: false - xy: 513, 113 + xy: 533, 113 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 item-biomatter rotate: false - xy: 766, 384 + xy: 652, 188 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 item-coal rotate: false - xy: 653, 198 + xy: 650, 178 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 item-densealloy rotate: false - xy: 652, 188 + xy: 650, 168 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 item-iron rotate: false - xy: 650, 178 + xy: 650, 158 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 item-lead rotate: false - xy: 650, 168 + xy: 650, 148 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 item-plastic rotate: false - xy: 650, 158 + xy: 423, 143 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 item-sand rotate: false - xy: 650, 148 + xy: 423, 133 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 item-silicon rotate: false - xy: 423, 143 + xy: 423, 123 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 item-steel rotate: false - xy: 423, 133 + xy: 423, 113 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 item-stone rotate: false - xy: 423, 123 + xy: 433, 144 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 item-thorium rotate: false - xy: 423, 113 + xy: 443, 144 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 item-titanium rotate: false - xy: 433, 144 + xy: 433, 134 size: 8, 8 orig: 8, 8 offset: 0, 0 @@ -2941,7 +2948,7 @@ slider-knob-over index: -1 slider-vertical rotate: false - xy: 763, 450 + xy: 139, 1 size: 8, 1 orig: 8, 1 offset: 0, 0 @@ -3050,84 +3057,84 @@ standard-mech-leg index: -1 beam rotate: false - xy: 129, 1 + xy: 139, 4 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 beam-equip rotate: false - xy: 139, 6 + xy: 716, 389 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 blaster rotate: false - xy: 1003, 411 + xy: 228, 60 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 blaster-equip rotate: false - xy: 1013, 411 + xy: 593, 198 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 clustergun rotate: false - xy: 593, 198 + xy: 623, 198 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 clustergun-equip rotate: false - xy: 603, 198 + xy: 633, 198 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 shockgun rotate: false - xy: 563, 123 + xy: 513, 113 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 shockgun-equip rotate: false - xy: 503, 113 + xy: 523, 113 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 triblaster rotate: false - xy: 857, 405 + xy: 877, 405 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 triblaster-equip rotate: false - xy: 867, 405 + xy: 887, 405 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 vulcan rotate: false - xy: 897, 405 + xy: 917, 405 size: 8, 8 orig: 8, 8 offset: 0, 0 index: -1 vulcan-equip rotate: false - xy: 907, 405 + xy: 927, 405 size: 8, 8 orig: 8, 8 offset: 0, 0 diff --git a/core/assets/sprites/sprites.png b/core/assets/sprites/sprites.png index 0fb7b4fe9b..3983630a25 100644 Binary files a/core/assets/sprites/sprites.png and b/core/assets/sprites/sprites.png differ diff --git a/core/assets/version.properties b/core/assets/version.properties index 8029da0e9e..37ae6c9e0a 100644 --- a/core/assets/version.properties +++ b/core/assets/version.properties @@ -1,7 +1,7 @@ #Autogenerated file. Do not modify. -#Wed Apr 04 23:49:24 EDT 2018 +#Thu Apr 05 17:29:03 EDT 2018 version=release -androidBuildCode=845 +androidBuildCode=846 name=Mindustry code=3.4 build=custom build diff --git a/core/src/io/anuke/mindustry/content/blocks/WeaponBlocks.java b/core/src/io/anuke/mindustry/content/blocks/WeaponBlocks.java index adfb6ab431..f603141038 100644 --- a/core/src/io/anuke/mindustry/content/blocks/WeaponBlocks.java +++ b/core/src/io/anuke/mindustry/content/blocks/WeaponBlocks.java @@ -1,5 +1,6 @@ package io.anuke.mindustry.content.blocks; +import com.badlogic.gdx.graphics.Color; import io.anuke.mindustry.content.AmmoTypes; import io.anuke.mindustry.content.fx.BulletFx; import io.anuke.mindustry.resource.AmmoType; @@ -90,13 +91,20 @@ public class WeaponBlocks{ }; }}, - laserturret = new PowerTurret("laserturret"){{ + laserturret = new LaserTurret("laserturret"){{ range = 70f; + chargeTime = 70f; + chargeMaxDelay = 30f; + chargeEffects = 7; shootType = AmmoTypes.lancerLaser; recoil = 2f; - reload = 80f; + reload = 130f; + cooldown = 0.03f; shootEffect = BulletFx.lancerLaserShoot; smokeEffect = BulletFx.lancerLaserShootSmoke; + chargeEffect = BulletFx.lancerLaserCharge; + chargeBeginEffect = BulletFx.lancerLaserChargeBegin; + heatColor = Color.RED; }}, teslaturret = new PowerTurret("teslaturret"){ diff --git a/core/src/io/anuke/mindustry/content/bullets/TurretBullets.java b/core/src/io/anuke/mindustry/content/bullets/TurretBullets.java index 43abc754c5..1be4aefb6e 100644 --- a/core/src/io/anuke/mindustry/content/bullets/TurretBullets.java +++ b/core/src/io/anuke/mindustry/content/bullets/TurretBullets.java @@ -110,7 +110,7 @@ public class TurretBullets { hiteffect = BulletFx.hitLancer; despawneffect = Fx.none; hitsize = 4; - lifetime = 12f; + lifetime = 20f; pierce = true; } diff --git a/core/src/io/anuke/mindustry/content/fx/BlockFx.java b/core/src/io/anuke/mindustry/content/fx/BlockFx.java index bb12c1c940..09589d2a02 100644 --- a/core/src/io/anuke/mindustry/content/fx/BlockFx.java +++ b/core/src/io/anuke/mindustry/content/fx/BlockFx.java @@ -14,202 +14,202 @@ public class BlockFx { public static final Effect reactorsmoke = new Effect(17, e -> { - Angles.randLenVectors(e.id, 4, e.ifract()*8f, (x, y)->{ - float size = 1f+e.fract()*5f; - Draw.color(Color.LIGHT_GRAY, Color.GRAY, e.ifract()); + Angles.randLenVectors(e.id, 4, e.fin()*8f, (x, y)->{ + float size = 1f+e.fout()*5f; + Draw.color(Color.LIGHT_GRAY, Color.GRAY, e.fin()); Draw.rect("circle", e.x + x, e.y + y, size, size); Draw.reset(); }); }), nuclearsmoke = new Effect(40, e -> { - Angles.randLenVectors(e.id, 4, e.ifract()*13f, (x, y)->{ - float size = e.sfract()*4f; - Draw.color(Color.LIGHT_GRAY, Color.GRAY, e.ifract()); + Angles.randLenVectors(e.id, 4, e.fin()*13f, (x, y)->{ + float size = e.fslope()*4f; + Draw.color(Color.LIGHT_GRAY, Color.GRAY, e.fin()); Draw.rect("circle", e.x + x, e.y + y, size, size); Draw.reset(); }); }), nuclearcloud = new Effect(90, 200f, e -> { - Angles.randLenVectors(e.id, 10, e.powfract()*90f, (x, y)->{ - float size = e.fract()*14f; - Draw.color(Color.LIME, Color.GRAY, e.ifract()); + Angles.randLenVectors(e.id, 10, e.finpow()*90f, (x, y)->{ + float size = e.fout()*14f; + Draw.color(Color.LIME, Color.GRAY, e.fin()); Draw.rect("circle", e.x + x, e.y + y, size, size); Draw.reset(); }); }), redgeneratespark = new Effect(18, e -> { - Angles.randLenVectors(e.id, 5, e.ifract()*8f, (x, y)->{ - float len = e.fract()*4f; - Draw.color(Color.valueOf("fbb97f"), Color.GRAY, e.ifract()); - //Draw.alpha(e.fract()); + Angles.randLenVectors(e.id, 5, e.fin()*8f, (x, y)->{ + float len = e.fout()*4f; + Draw.color(Color.valueOf("fbb97f"), Color.GRAY, e.fin()); + //Draw.alpha(e.fout()); Draw.rect("circle", e.x + x, e.y + y, len, len); Draw.reset(); }); }), generatespark = new Effect(18, e -> { - Angles.randLenVectors(e.id, 5, e.ifract()*8f, (x, y)->{ - float len = e.fract()*4f; - Draw.color(Color.valueOf("d2b29c"), Color.GRAY, e.ifract()); + Angles.randLenVectors(e.id, 5, e.fin()*8f, (x, y)->{ + float len = e.fout()*4f; + Draw.color(Color.valueOf("d2b29c"), Color.GRAY, e.fin()); Draw.rect("circle", e.x + x, e.y + y, len, len); Draw.reset(); }); }), fuelburn = new Effect(23, e -> { - Angles.randLenVectors(e.id, 5, e.ifract()*9f, (x, y)->{ - float len = e.fract()*4f; - Draw.color(Color.LIGHT_GRAY, Color.GRAY, e.ifract()); + Angles.randLenVectors(e.id, 5, e.fin()*9f, (x, y)->{ + float len = e.fout()*4f; + Draw.color(Color.LIGHT_GRAY, Color.GRAY, e.fin()); Draw.rect("circle", e.x + x, e.y + y, len, len); Draw.reset(); }); }), plasticburn = new Effect(40, e -> { - Angles.randLenVectors(e.id, 5, 3f + e.ifract()*5f, (x, y)->{ - Draw.color(Color.valueOf("e9ead3"), Color.GRAY, e.ifract()); - Fill.circle(e.x + x, e.y + y, e.fract()*1f); + Angles.randLenVectors(e.id, 5, 3f + e.fin()*5f, (x, y)->{ + Draw.color(Color.valueOf("e9ead3"), Color.GRAY, e.fin()); + Fill.circle(e.x + x, e.y + y, e.fout()*1f); Draw.reset(); }); }), pulverize = new Effect(40, e -> { - Angles.randLenVectors(e.id, 5, 3f + e.ifract()*8f, (x, y)->{ + Angles.randLenVectors(e.id, 5, 3f + e.fin()*8f, (x, y)->{ Draw.color(Fx.stoneGray); - Fill.poly(e.x + x, e.y + y, 4, e.fract() * 2f + 0.5f, 45); + Fill.poly(e.x + x, e.y + y, 4, e.fout() * 2f + 0.5f, 45); Draw.reset(); }); }), pulverizeRed = new Effect(40, e -> { - Angles.randLenVectors(e.id, 5, 3f + e.ifract()*8f, (x, y)->{ - Draw.color(Color.valueOf("ffa480"), Fx.stoneGray, e.ifract()); - Fill.poly(e.x + x, e.y + y, 4, e.fract() * 2f + 0.5f, 45); + Angles.randLenVectors(e.id, 5, 3f + e.fin()*8f, (x, y)->{ + Draw.color(Color.valueOf("ffa480"), Fx.stoneGray, e.fin()); + Fill.poly(e.x + x, e.y + y, 4, e.fout() * 2f + 0.5f, 45); Draw.reset(); }); }), pulverizeRedder = new Effect(40, e -> { - Angles.randLenVectors(e.id, 5, 3f + e.ifract()*9f, (x, y)->{ - Draw.color(Color.valueOf("ff7b69"), Fx.stoneGray, e.ifract()); - Fill.poly(e.x + x, e.y + y, 4, e.fract() * 2.5f + 0.5f, 45); + Angles.randLenVectors(e.id, 5, 3f + e.fin()*9f, (x, y)->{ + Draw.color(Color.valueOf("ff7b69"), Fx.stoneGray, e.fin()); + Fill.poly(e.x + x, e.y + y, 4, e.fout() * 2.5f + 0.5f, 45); Draw.reset(); }); }), pulverizeSmall = new Effect(30, e -> { - Angles.randLenVectors(e.id, 3, e.ifract()*5f, (x, y)->{ + Angles.randLenVectors(e.id, 3, e.fin()*5f, (x, y)->{ Draw.color(Fx.stoneGray); - Fill.poly(e.x + x, e.y + y, 4, e.fract() * 1f + 0.5f, 45); + Fill.poly(e.x + x, e.y + y, 4, e.fout() * 1f + 0.5f, 45); Draw.reset(); }); }), pulverizeMedium = new Effect(30, e -> { - Angles.randLenVectors(e.id, 5, 3f + e.ifract()*8f, (x, y)->{ + Angles.randLenVectors(e.id, 5, 3f + e.fin()*8f, (x, y)->{ Draw.color(Fx.stoneGray); - Fill.poly(e.x + x, e.y + y, 4, e.fract() * 1f + 0.5f, 45); + Fill.poly(e.x + x, e.y + y, 4, e.fout() * 1f + 0.5f, 45); Draw.reset(); }); }), producesmoke = new Effect(12, e -> { - Angles.randLenVectors(e.id, 8, 4f + e.ifract()*18f, (x, y)->{ - Draw.color(Color.WHITE, Colors.get("accent"), e.ifract()); - Fill.poly(e.x + x, e.y + y, 4, 1f+e.fract()*3f, 45); + Angles.randLenVectors(e.id, 8, 4f + e.fin()*18f, (x, y)->{ + Draw.color(Color.WHITE, Colors.get("accent"), e.fin()); + Fill.poly(e.x + x, e.y + y, 4, 1f+e.fout()*3f, 45); Draw.reset(); }); }), smeltsmoke = new Effect(15, e -> { - Angles.randLenVectors(e.id, 6, 4f + e.ifract()*5f, (x, y)->{ - Draw.color(Color.WHITE, e.color, e.ifract()); - Fill.poly(e.x + x, e.y + y, 4, 0.5f+e.fract()*2f, 45); + Angles.randLenVectors(e.id, 6, 4f + e.fin()*5f, (x, y)->{ + Draw.color(Color.WHITE, e.color, e.fin()); + Fill.poly(e.x + x, e.y + y, 4, 0.5f+e.fout()*2f, 45); Draw.reset(); }); }), formsmoke = new Effect(40, e -> { - Angles.randLenVectors(e.id, 6, 5f + e.ifract()*8f, (x, y)->{ - Draw.color(Color.valueOf("f1e479"), Color.LIGHT_GRAY, e.ifract()); - Fill.poly(e.x + x, e.y + y, 4, 0.2f+e.fract()*2f, 45); + Angles.randLenVectors(e.id, 6, 5f + e.fin()*8f, (x, y)->{ + Draw.color(Color.valueOf("f1e479"), Color.LIGHT_GRAY, e.fin()); + Fill.poly(e.x + x, e.y + y, 4, 0.2f+e.fout()*2f, 45); Draw.reset(); }); }), blastsmoke = new Effect(26, e -> { - Angles.randLenVectors(e.id, 12, 1f + e.ifract()*23f, (x, y)->{ - float size = 2f+e.fract()*6f; - Draw.color(Color.LIGHT_GRAY, Color.DARK_GRAY, e.ifract()); + Angles.randLenVectors(e.id, 12, 1f + e.fin()*23f, (x, y)->{ + float size = 2f+e.fout()*6f; + Draw.color(Color.LIGHT_GRAY, Color.DARK_GRAY, e.fin()); Draw.rect("circle", e.x + x, e.y + y, size, size); Draw.reset(); }); }), lava = new Effect(18, e -> { - Angles.randLenVectors(e.id, 3, 1f + e.ifract()*10f, (x, y)->{ - float size = e.sfract()*4f; - Draw.color(Color.ORANGE, Color.GRAY, e.ifract()); + Angles.randLenVectors(e.id, 3, 1f + e.fin()*10f, (x, y)->{ + float size = e.fslope()*4f; + Draw.color(Color.ORANGE, Color.GRAY, e.fin()); Draw.rect("circle", e.x + x, e.y + y, size, size); Draw.reset(); }); }), dooropen = new Effect(10, e -> { - Lines.stroke(e.fract() * 1.6f); - Lines.square(e.x, e.y, tilesize / 2f + e.ifract() * 2f); + Lines.stroke(e.fout() * 1.6f); + Lines.square(e.x, e.y, tilesize / 2f + e.fin() * 2f); Draw.reset(); }), doorclose= new Effect(10, e -> { - Lines.stroke(e.fract() * 1.6f); - Lines.square(e.x, e.y, tilesize / 2f + e.fract() * 2f); + Lines.stroke(e.fout() * 1.6f); + Lines.square(e.x, e.y, tilesize / 2f + e.fout() * 2f); Draw.reset(); }), dooropenlarge = new Effect(10, e -> { - Lines.stroke(e.fract() * 1.6f); - Lines.square(e.x, e.y, tilesize + e.ifract() * 2f); + Lines.stroke(e.fout() * 1.6f); + Lines.square(e.x, e.y, tilesize + e.fin() * 2f); Draw.reset(); }), doorcloselarge = new Effect(10, e -> { - Lines.stroke(e.fract() * 1.6f); - Lines.square(e.x, e.y, tilesize + e.fract() * 2f); + Lines.stroke(e.fout() * 1.6f); + Lines.square(e.x, e.y, tilesize + e.fout() * 2f); Draw.reset(); }), purify = new Effect(10, e -> { - Draw.color(Color.ROYAL, Color.GRAY, e.ifract()); + Draw.color(Color.ROYAL, Color.GRAY, e.fin()); Lines.stroke(2f); - Lines.spikes(e.x, e.y, e.ifract() * 4f, 2, 6); + Lines.spikes(e.x, e.y, e.fin() * 4f, 2, 6); Draw.reset(); }), purifyoil = new Effect(10, e -> { - Draw.color(Color.BLACK, Color.GRAY, e.ifract()); + Draw.color(Color.BLACK, Color.GRAY, e.fin()); Lines.stroke(2f); - Lines.spikes(e.x, e.y, e.ifract() * 4f, 2, 6); + Lines.spikes(e.x, e.y, e.fin() * 4f, 2, 6); Draw.reset(); }), purifystone = new Effect(10, e -> { - Draw.color(Color.ORANGE, Color.GRAY, e.ifract()); + Draw.color(Color.ORANGE, Color.GRAY, e.fin()); Lines.stroke(2f); - Lines.spikes(e.x, e.y, e.ifract() * 4f, 2, 6); + Lines.spikes(e.x, e.y, e.fin() * 4f, 2, 6); Draw.reset(); }), generate = new Effect(11, e -> { - Draw.color(Color.ORANGE, Color.YELLOW, e.ifract()); + Draw.color(Color.ORANGE, Color.YELLOW, e.fin()); Lines.stroke(1f); - Lines.spikes(e.x, e.y, e.ifract() * 5f, 2, 8); + Lines.spikes(e.x, e.y, e.fin() * 5f, 2, 8); Draw.reset(); }), mine = new Effect(20, e -> { - Angles.randLenVectors(e.id, 6, 3f + e.ifract()*6f, (x, y)->{ - Draw.color(e.color, Color.LIGHT_GRAY, e.ifract()); - Fill.poly(e.x + x, e.y + y, 4, e.fract() * 2f, 45); + Angles.randLenVectors(e.id, 6, 3f + e.fin()*6f, (x, y)->{ + Draw.color(e.color, Color.LIGHT_GRAY, e.fin()); + Fill.poly(e.x + x, e.y + y, 4, e.fout() * 2f, 45); Draw.reset(); }); }), mineBig = new Effect(30, e -> { - Angles.randLenVectors(e.id, 6, 4f + e.ifract()*8f, (x, y)->{ - Draw.color(e.color, Color.LIGHT_GRAY, e.ifract()); - Fill.poly(e.x + x, e.y + y, 4, e.fract() * 2f + 0.2f, 45); + Angles.randLenVectors(e.id, 6, 4f + e.fin()*8f, (x, y)->{ + Draw.color(e.color, Color.LIGHT_GRAY, e.fin()); + Fill.poly(e.x + x, e.y + y, 4, e.fout() * 2f + 0.2f, 45); Draw.reset(); }); }), mineHuge = new Effect(40, e -> { - Angles.randLenVectors(e.id, 8, 5f + e.ifract()*10f, (x, y)->{ - Draw.color(e.color, Color.LIGHT_GRAY, e.ifract()); - Fill.poly(e.x + x, e.y + y, 4, e.fract() * 2f + 0.5f, 45); + Angles.randLenVectors(e.id, 8, 5f + e.fin()*10f, (x, y)->{ + Draw.color(e.color, Color.LIGHT_GRAY, e.fin()); + Fill.poly(e.x + x, e.y + y, 4, e.fout() * 2f + 0.5f, 45); Draw.reset(); }); }), smelt = new Effect(20, e -> { - Angles.randLenVectors(e.id, 6, 2f + e.ifract()*5f, (x, y)->{ - Draw.color(Color.WHITE, e.color, e.ifract()); - Fill.poly(e.x + x, e.y + y, 4, 0.5f+e.fract()*2f, 45); + Angles.randLenVectors(e.id, 6, 2f + e.fin()*5f, (x, y)->{ + Draw.color(Color.WHITE, e.color, e.fin()); + Fill.poly(e.x + x, e.y + y, 4, 0.5f+e.fout()*2f, 45); Draw.reset(); }); }); diff --git a/core/src/io/anuke/mindustry/content/fx/BulletFx.java b/core/src/io/anuke/mindustry/content/fx/BulletFx.java index db99726ab9..d29fe271a8 100644 --- a/core/src/io/anuke/mindustry/content/fx/BulletFx.java +++ b/core/src/io/anuke/mindustry/content/fx/BulletFx.java @@ -16,102 +16,102 @@ public class BulletFx { public static final Effect shootSmall = new Effect(8, e -> { - Draw.color(Palette.lighterOrange, Palette.lightOrange, e.ifract()); - float w = 1f + 5 * e.fract(); - Shapes.tri(e.x, e.y, w, 15f * e.fract(), e.rotation); - Shapes.tri(e.x, e.y, w, 3f * e.fract(), e.rotation + 180f); + Draw.color(Palette.lighterOrange, Palette.lightOrange, e.fin()); + float w = 1f + 5 * e.fout(); + Shapes.tri(e.x, e.y, w, 15f * e.fout(), e.rotation); + Shapes.tri(e.x, e.y, w, 3f * e.fout(), e.rotation + 180f); Draw.reset(); }), shootSmallSmoke = new Effect(20f, e -> { - Draw.color(Palette.lighterOrange, Color.LIGHT_GRAY, Color.GRAY, e.ifract()); + Draw.color(Palette.lighterOrange, Color.LIGHT_GRAY, Color.GRAY, e.fin()); - Angles.randLenVectors(e.id, 5, e.powfract()*6f, e.rotation, 20f, (x, y) -> { - Fill.circle(e.x + x, e.y + y, e.fract()*1.5f); + Angles.randLenVectors(e.id, 5, e.finpow()*6f, e.rotation, 20f, (x, y) -> { + Fill.circle(e.x + x, e.y + y, e.fout()*1.5f); }); Draw.reset(); }), shootBig = new Effect(9, e -> { - Draw.color(Palette.lighterOrange, Palette.lightOrange, e.ifract()); - float w = 1.2f + 7 * e.fract(); - Shapes.tri(e.x, e.y, w, 25f * e.fract(), e.rotation); - Shapes.tri(e.x, e.y, w, 4f * e.fract(), e.rotation + 180f); + Draw.color(Palette.lighterOrange, Palette.lightOrange, e.fin()); + float w = 1.2f + 7 * e.fout(); + Shapes.tri(e.x, e.y, w, 25f * e.fout(), e.rotation); + Shapes.tri(e.x, e.y, w, 4f * e.fout(), e.rotation + 180f); Draw.reset(); }), shootBig2 = new Effect(10, e -> { - Draw.color(Palette.lightOrange, Color.GRAY, e.ifract()); - float w = 1.2f + 8 * e.fract(); - Shapes.tri(e.x, e.y, w, 29f * e.fract(), e.rotation); - Shapes.tri(e.x, e.y, w, 5f * e.fract(), e.rotation + 180f); + Draw.color(Palette.lightOrange, Color.GRAY, e.fin()); + float w = 1.2f + 8 * e.fout(); + Shapes.tri(e.x, e.y, w, 29f * e.fout(), e.rotation); + Shapes.tri(e.x, e.y, w, 5f * e.fout(), e.rotation + 180f); Draw.reset(); }), shootBigSmoke = new Effect(17f, e -> { - Draw.color(Palette.lighterOrange, Color.LIGHT_GRAY, Color.GRAY, e.ifract()); + Draw.color(Palette.lighterOrange, Color.LIGHT_GRAY, Color.GRAY, e.fin()); - Angles.randLenVectors(e.id, 8, e.powfract()*19f, e.rotation, 10f, (x, y) -> { - Fill.circle(e.x + x, e.y + y, e.fract()*2f + 0.2f); + Angles.randLenVectors(e.id, 8, e.finpow()*19f, e.rotation, 10f, (x, y) -> { + Fill.circle(e.x + x, e.y + y, e.fout()*2f + 0.2f); }); Draw.reset(); }), shootBigSmoke2 = new Effect(18f, e -> { - Draw.color(Palette.lightOrange, Color.LIGHT_GRAY, Color.GRAY, e.ifract()); + Draw.color(Palette.lightOrange, Color.LIGHT_GRAY, Color.GRAY, e.fin()); - Angles.randLenVectors(e.id, 9, e.powfract()*23f, e.rotation, 20f, (x, y) -> { - Fill.circle(e.x + x, e.y + y, e.fract()*2.4f + 0.2f); + Angles.randLenVectors(e.id, 9, e.finpow()*23f, e.rotation, 20f, (x, y) -> { + Fill.circle(e.x + x, e.y + y, e.fout()*2.4f + 0.2f); }); Draw.reset(); }), shootSmallFlame = new Effect(30f, e -> { - Draw.color(Palette.lightFlame, Palette.darkFlame, Color.GRAY, e.ifract()); + Draw.color(Palette.lightFlame, Palette.darkFlame, Color.GRAY, e.fin()); - Angles.randLenVectors(e.id, 8, e.powfract()*26f, e.rotation, 10f, (x, y) -> { - Fill.circle(e.x + x, e.y + y, 0.65f + e.fract()*1.5f); + Angles.randLenVectors(e.id, 8, e.finpow()*26f, e.rotation, 10f, (x, y) -> { + Fill.circle(e.x + x, e.y + y, 0.65f + e.fout()*1.5f); }); Draw.reset(); }), shellEjectSmall = new StaticEffect(30f, 400f, e -> { - Draw.color(Palette.lightOrange, Color.LIGHT_GRAY, Palette.lightishGray, e.ifract()); + Draw.color(Palette.lightOrange, Color.LIGHT_GRAY, Palette.lightishGray, e.fin()); float rot = e.rotation + 90f; for(int i : Mathf.signs){ - float len = (2f + e.powfract()*6f) * i; - float lr = rot + e.ifract()*30f*i; + float len = (2f + e.finpow()*6f) * i; + float lr = rot + e.fin()*30f*i; Draw.rect("white", - e.x + Angles.trnsx(lr, len) + Mathf.randomSeedRange(e.id + i + 7, 3f * e.ifract()), - e.y + Angles.trnsy(lr, len) + Mathf.randomSeedRange(e.id + i + 8, 3f * e.ifract()), - 1f, 2f, rot + e.ifract()*50f*i); + e.x + Angles.trnsx(lr, len) + Mathf.randomSeedRange(e.id + i + 7, 3f * e.fin()), + e.y + Angles.trnsy(lr, len) + Mathf.randomSeedRange(e.id + i + 8, 3f * e.fin()), + 1f, 2f, rot + e.fin()*50f*i); } Draw.color(); }), shellEjectMedium = new StaticEffect(34f, 400f, e -> { - Draw.color(Palette.lightOrange, Color.LIGHT_GRAY, Palette.lightishGray, e.ifract()); + Draw.color(Palette.lightOrange, Color.LIGHT_GRAY, Palette.lightishGray, e.fin()); float rot = e.rotation + 90f; for(int i : Mathf.signs){ - float len = (2f + e.powfract()*10f) * i; - float lr = rot + e.ifract()*20f*i; + float len = (2f + e.finpow()*10f) * i; + float lr = rot + e.fin()*20f*i; Draw.rect("casing", - e.x + Angles.trnsx(lr, len) + Mathf.randomSeedRange(e.id + i + 7, 3f * e.ifract()), - e.y + Angles.trnsy(lr, len) + Mathf.randomSeedRange(e.id + i + 8, 3f * e.ifract()), + e.x + Angles.trnsx(lr, len) + Mathf.randomSeedRange(e.id + i + 7, 3f * e.fin()), + e.y + Angles.trnsy(lr, len) + Mathf.randomSeedRange(e.id + i + 8, 3f * e.fin()), 2f, 3f, rot); } - Draw.color(Color.LIGHT_GRAY, Color.GRAY, e.ifract()); + Draw.color(Color.LIGHT_GRAY, Color.GRAY, e.fin()); for(int i : Mathf.signs){ - Angles.randLenVectors(e.id, 4, 1f + e.powfract()*11f, e.rotation + 90f*i, 20f, (x, y) -> { - Fill.circle(e.x + x, e.y + y, e.fract()*1.5f); + Angles.randLenVectors(e.id, 4, 1f + e.finpow()*11f, e.rotation + 90f*i, 20f, (x, y) -> { + Fill.circle(e.x + x, e.y + y, e.fout()*1.5f); }); } @@ -119,23 +119,23 @@ public class BulletFx { }), shellEjectBig = new StaticEffect(22f, 400f, e -> { - Draw.color(Palette.lightOrange, Color.LIGHT_GRAY, Palette.lightishGray, e.ifract()); + Draw.color(Palette.lightOrange, Color.LIGHT_GRAY, Palette.lightishGray, e.fin()); float rot = e.rotation + 90f; for(int i : Mathf.signs){ - float len = (4f + e.powfract()*8f) * i; - float lr = rot + Mathf.randomSeedRange(e.id + i + 6, 20f * e.ifract())*i; + float len = (4f + e.finpow()*8f) * i; + float lr = rot + Mathf.randomSeedRange(e.id + i + 6, 20f * e.fin())*i; Draw.rect("casing", - e.x + Angles.trnsx(lr, len) + Mathf.randomSeedRange(e.id + i + 7, 3f * e.ifract()), - e.y + Angles.trnsy(lr, len) + Mathf.randomSeedRange(e.id + i + 8, 3f * e.ifract()), + e.x + Angles.trnsx(lr, len) + Mathf.randomSeedRange(e.id + i + 7, 3f * e.fin()), + e.y + Angles.trnsy(lr, len) + Mathf.randomSeedRange(e.id + i + 8, 3f * e.fin()), 2.5f, 4f, - rot+ e.ifract()*30f*i + Mathf.randomSeedRange(e.id + i + 9, 40f * e.ifract())); + rot+ e.fin()*30f*i + Mathf.randomSeedRange(e.id + i + 9, 40f * e.fin())); } Draw.color(Color.LIGHT_GRAY); for(int i : Mathf.signs){ - Angles.randLenVectors(e.id, 4, -e.powfract()*15f, e.rotation + 90f*i, 25f, (x, y) -> { - Fill.circle(e.x + x, e.y + y, e.fract()*2f); + Angles.randLenVectors(e.id, 4, -e.finpow()*15f, e.rotation + 90f*i, 25f, (x, y) -> { + Fill.circle(e.x + x, e.y + y, e.fout()*2f); }); } @@ -143,36 +143,36 @@ public class BulletFx { }), hitBulletSmall = new Effect(14, e -> { - Draw.color(Color.WHITE, Palette.lightOrange, e.ifract()); - Lines.stroke(0.5f + e.fract()); + Draw.color(Color.WHITE, Palette.lightOrange, e.fin()); + Lines.stroke(0.5f + e.fout()); - Angles.randLenVectors(e.id, 5, e.ifract()*15f, e.rotation, 50f, (x, y) -> { + Angles.randLenVectors(e.id, 5, e.fin()*15f, e.rotation, 50f, (x, y) -> { float ang = Mathf.atan2(x, y); - Lines.lineAngle(e.x + x, e.y + y, ang, e.fract()*3 + 1f); + Lines.lineAngle(e.x + x, e.y + y, ang, e.fout()*3 + 1f); }); Draw.reset(); }), hitBulletBig = new Effect(13, e -> { - Draw.color(Color.WHITE, Palette.lightOrange, e.ifract()); - Lines.stroke(0.5f + e.fract()*1.5f); + Draw.color(Color.WHITE, Palette.lightOrange, e.fin()); + Lines.stroke(0.5f + e.fout()*1.5f); - Angles.randLenVectors(e.id, 8, e.powfract()*30f, e.rotation, 50f, (x, y) -> { + Angles.randLenVectors(e.id, 8, e.finpow()*30f, e.rotation, 50f, (x, y) -> { float ang = Mathf.atan2(x, y); - Lines.lineAngle(e.x + x, e.y + y, ang, e.fract()*4 + 1.5f); + Lines.lineAngle(e.x + x, e.y + y, ang, e.fout()*4 + 1.5f); }); Draw.reset(); }), hitFlameSmall = new Effect(14, e -> { - Draw.color(Palette.lightFlame, Palette.darkFlame, e.ifract()); - Lines.stroke(0.5f + e.fract()); + Draw.color(Palette.lightFlame, Palette.darkFlame, e.fin()); + Lines.stroke(0.5f + e.fout()); - Angles.randLenVectors(e.id, 5, e.ifract()*15f, e.rotation, 50f, (x, y) -> { + Angles.randLenVectors(e.id, 5, e.fin()*15f, e.rotation, 50f, (x, y) -> { float ang = Mathf.atan2(x, y); - Lines.lineAngle(e.x + x, e.y + y, ang, e.fract()*3 + 1f); + Lines.lineAngle(e.x + x, e.y + y, ang, e.fout()*3 + 1f); }); Draw.reset(); @@ -180,23 +180,23 @@ public class BulletFx { hitLancer = new Effect(12, e -> { Draw.color(Color.WHITE); - Lines.stroke(e.fract()*1.5f); + Lines.stroke(e.fout()*1.5f); - Angles.randLenVectors(e.id, 8, e.powfract()*17f, e.rotation, 360f, (x, y) -> { + Angles.randLenVectors(e.id, 8, e.finpow()*17f, e.rotation, 360f, (x, y) -> { float ang = Mathf.atan2(x, y); - Lines.lineAngle(e.x + x, e.y + y, ang, e.fract()*4 + 1f); + Lines.lineAngle(e.x + x, e.y + y, ang, e.fout()*4 + 1f); }); Draw.reset(); }), despawn = new Effect(12, e -> { - Draw.color(Palette.lighterOrange, Color.GRAY, e.ifract()); - Lines.stroke(e.fract()); + Draw.color(Palette.lighterOrange, Color.GRAY, e.fin()); + Lines.stroke(e.fout()); - Angles.randLenVectors(e.id, 7, e.ifract()*7f, e.rotation, 40f, (x, y) -> { + Angles.randLenVectors(e.id, 7, e.fin()*7f, e.rotation, 40f, (x, y) -> { float ang = Mathf.atan2(x, y); - Lines.lineAngle(e.x + x, e.y + y, ang, e.fract()*2 + 1f); + Lines.lineAngle(e.x + x, e.y + y, ang, e.fout()*2 + 1f); }); Draw.reset(); @@ -206,43 +206,61 @@ public class BulletFx { Draw.color(Palette.bulletYellow); e.scaled(6, i -> { - Lines.stroke(3f * i.fract()); - Lines.circle(e.x, e.y, 3f + i.ifract()*10f); + Lines.stroke(3f * i.fout()); + Lines.circle(e.x, e.y, 3f + i.fin()*10f); }); Draw.color(Color.GRAY); - Angles.randLenVectors(e.id, 5, 2f + 23f * e.powfract(), (x, y) ->{ - Fill.circle(e.x + x, e.y + y, e.fract()*3f + 0.5f); + Angles.randLenVectors(e.id, 5, 2f + 23f * e.finpow(), (x, y) ->{ + Fill.circle(e.x + x, e.y + y, e.fout()*3f + 0.5f); }); Draw.color(Palette.lighterOrange); - Lines.stroke(1f * e.fract()); + Lines.stroke(1f * e.fout()); - Angles.randLenVectors(e.id + 1, 4, 1f + 23f * e.powfract(), (x, y) -> { - Lines.lineAngle(e.x + x, e.y + y, Mathf.atan2(x, y), 1f + e.fract()*3f); + Angles.randLenVectors(e.id + 1, 4, 1f + 23f * e.finpow(), (x, y) -> { + Lines.lineAngle(e.x + x, e.y + y, Mathf.atan2(x, y), 1f + e.fout()*3f); }); Draw.reset(); }), - lancerLaserShoot = new Effect(12f, e -> { + lancerLaserShoot = new Effect(21f, e -> { Draw.color(Palette.lancerLaser); for(int i : Mathf.signs){ - Shapes.tri(e.x, e.y, 4f * e.fract(), 29f, e.rotation + 90f*i); + Shapes.tri(e.x, e.y, 4f * e.fout(), 29f, e.rotation + 90f*i); } Draw.reset(); }), - lancerLaserShootSmoke = new Effect(20f, e -> { + lancerLaserShootSmoke = new Effect(26f, e -> { Draw.color(Palette.lancerLaser); Angles.randLenVectors(e.id, 7, 80f, e.rotation, 0f, (x, y) -> { - Lines.lineAngle(e.x + x, e.y + y, Mathf.atan2(x, y), e.fract()*9f); + Lines.lineAngle(e.x + x, e.y + y, Mathf.atan2(x, y), e.fout()*9f); }); Draw.reset(); + }), + + lancerLaserCharge = new Effect(38f, e -> { + Draw.color(Palette.lancerLaser); + + Angles.randLenVectors(e.id, 2, 1f + 20f * e.fout(), e.rotation, 120f, (x, y) -> { + Lines.lineAngle(e.x + x, e.y + y, Mathf.atan2(x, y), e.fslope()*3f + 1f); + }); + + Draw.reset(); + }), + + lancerLaserChargeBegin = new Effect(71f, e -> { + Draw.color(Palette.lancerLaser); + Fill.circle(e.x, e.y, e.fin() * 3f); + + Draw.color(); + Fill.circle(e.x, e.y, e.fin() * 2f); }); } diff --git a/core/src/io/anuke/mindustry/content/fx/ExplosionFx.java b/core/src/io/anuke/mindustry/content/fx/ExplosionFx.java index 9861a3b542..a456d53249 100644 --- a/core/src/io/anuke/mindustry/content/fx/ExplosionFx.java +++ b/core/src/io/anuke/mindustry/content/fx/ExplosionFx.java @@ -13,46 +13,46 @@ public class ExplosionFx { public static final Effect generatorexplosion = new Effect(28, 40f, e -> { - Angles.randLenVectors(e.id, 16, 10f + e.ifract()*8f, (x, y) -> { - float size = e.fract()*12f + 1f; - Draw.color(Color.WHITE, Color.PURPLE, e.ifract()); + Angles.randLenVectors(e.id, 16, 10f + e.fin()*8f, (x, y) -> { + float size = e.fout()*12f + 1f; + Draw.color(Color.WHITE, Color.PURPLE, e.fin()); Draw.rect("circle", e.x + x, e.y + y, size, size); Draw.reset(); }); }), shockwave = new Effect(10f, 80f, e -> { - Draw.color(Color.WHITE, Color.LIGHT_GRAY, e.ifract()); - Lines.stroke(e.fract()*2f + 0.2f); - Lines.circle(e.x, e.y, e.ifract()*28f); + Draw.color(Color.WHITE, Color.LIGHT_GRAY, e.fin()); + Lines.stroke(e.fout()*2f + 0.2f); + Lines.circle(e.x, e.y, e.fin()*28f); Draw.reset(); }), nuclearShockwave = new Effect(10f, 200f, e -> { - Draw.color(Color.WHITE, Color.LIGHT_GRAY, e.ifract()); - Lines.stroke(e.fract()*3f + 0.2f); - Lines.poly(e.x, e.y, 40, e.ifract()*140f); + Draw.color(Color.WHITE, Color.LIGHT_GRAY, e.fin()); + Lines.stroke(e.fout()*3f + 0.2f); + Lines.poly(e.x, e.y, 40, e.fin()*140f); Draw.reset(); }), explosion = new Effect(30, e -> { e.scaled(7, i -> { - Lines.stroke(3f * i.fract()); - Lines.circle(e.x, e.y, 3f + i.ifract()*10f); + Lines.stroke(3f * i.fout()); + Lines.circle(e.x, e.y, 3f + i.fin()*10f); }); Draw.color(Color.GRAY); - Angles.randLenVectors(e.id, 6, 2f + 19f * e.powfract(), (x, y) ->{ - Fill.circle(e.x + x, e.y + y, e.fract()*3f + 0.5f); - Fill.circle(e.x + x/2f, e.y + y/2f, e.fract()*1f); + Angles.randLenVectors(e.id, 6, 2f + 19f * e.finpow(), (x, y) ->{ + Fill.circle(e.x + x, e.y + y, e.fout()*3f + 0.5f); + Fill.circle(e.x + x/2f, e.y + y/2f, e.fout()*1f); }); - Draw.color(Palette.lighterOrange, Palette.lightOrange, Color.GRAY, e.ifract()); - Lines.stroke(1.5f * e.fract()); + Draw.color(Palette.lighterOrange, Palette.lightOrange, Color.GRAY, e.fin()); + Lines.stroke(1.5f * e.fout()); - Angles.randLenVectors(e.id + 1, 8, 1f + 23f * e.powfract(), (x, y) -> { - Lines.lineAngle(e.x + x, e.y + y, Mathf.atan2(x, y), 1f + e.fract()*3f); + Angles.randLenVectors(e.id + 1, 8, 1f + 23f * e.finpow(), (x, y) -> { + Lines.lineAngle(e.x + x, e.y + y, Mathf.atan2(x, y), 1f + e.fout()*3f); }); Draw.reset(); diff --git a/core/src/io/anuke/mindustry/content/fx/Fx.java b/core/src/io/anuke/mindustry/content/fx/Fx.java index 71e4094dec..f40d5cf667 100644 --- a/core/src/io/anuke/mindustry/content/fx/Fx.java +++ b/core/src/io/anuke/mindustry/content/fx/Fx.java @@ -18,36 +18,36 @@ public class Fx{ none = new Effect(0, 0f, e->{}), place = new Effect(16, e -> { - Lines.stroke(3f - e.ifract() * 2f); - Lines.square(e.x, e.y, tilesize / 2f + e.ifract() * 3f); + Lines.stroke(3f - e.fin() * 2f); + Lines.square(e.x, e.y, tilesize / 2f + e.fin() * 3f); Draw.reset(); }), breakBlock = new Effect(12, e -> { Lines.stroke(2f); - Draw.color(Color.WHITE, Colors.get("break"), e.ifract()); - Lines.spikes(e.x, e.y, e.ifract() * 6f, 2, 5, 90); + Draw.color(Color.WHITE, Colors.get("break"), e.fin()); + Lines.spikes(e.x, e.y, e.fin() * 6f, 2, 5, 90); Draw.reset(); }), smoke = new Effect(100, e -> { - Draw.color(Color.GRAY, new Color(0.3f, 0.3f, 0.3f, 1f), e.ifract()); - float size = 7f-e.ifract()*7f; + Draw.color(Color.GRAY, new Color(0.3f, 0.3f, 0.3f, 1f), e.fin()); + float size = 7f-e.fin()*7f; Draw.rect("circle", e.x, e.y, size, size); Draw.reset(); }), dash = new Effect(30, e -> { - Draw.color(Color.CORAL, Color.GRAY, e.ifract()); - float size = e.fract()*4f; + Draw.color(Color.CORAL, Color.GRAY, e.fin()); + float size = e.fout()*4f; Draw.rect("circle", e.x, e.y, size, size); Draw.reset(); }), spawn = new Effect(23, e -> { Lines.stroke(2f); - Draw.color(Color.DARK_GRAY, Color.SCARLET, e.ifract()); - Lines.circle(e.x, e.y, 7f - e.ifract() * 6f); + Draw.color(Color.DARK_GRAY, Color.SCARLET, e.fin()); + Lines.circle(e.x, e.y, 7f - e.fin() * 6f); Draw.reset(); }), diff --git a/core/src/io/anuke/mindustry/world/blocks/types/defense/Turret.java b/core/src/io/anuke/mindustry/world/blocks/types/defense/Turret.java index df7a7d79bd..81e2bfc8d7 100644 --- a/core/src/io/anuke/mindustry/world/blocks/types/defense/Turret.java +++ b/core/src/io/anuke/mindustry/world/blocks/types/defense/Turret.java @@ -33,6 +33,12 @@ public abstract class Turret extends Block{ protected final int timerTarget = timers++; + protected Color heatColor = Palette.turretHeat; + protected Effect shootEffect = Fx.none; + protected Effect smokeEffect = Fx.none; + protected Effect ammoUseEffect = Fx.none; + protected String shootsound = "shoot"; + protected int ammoPerShot = 1; protected float ammoEjectBack = 1f; protected float range = 50f; @@ -51,18 +57,12 @@ public abstract class Turret extends Block{ protected BiConsumer drawer = (tile, entity) -> Draw.rect(name, tile.drawx() + tr2.x, tile.drawy() + tr2.y, entity.rotation - 90); protected BiConsumer heatDrawer = (tile, entity) ->{ Graphics.setAdditiveBlending(); - Draw.color(Palette.turretHeat); + Draw.color(heatColor); Draw.alpha(entity.heat); Draw.rect(name + "-heat", tile.drawx() + tr2.x, tile.drawy() + tr2.y, entity.rotation - 90); Graphics.setNormalBlending(); }; - - protected Effect shootEffect = Fx.none; - protected Effect smokeEffect = Fx.none; - protected Effect ammoUseEffect = Fx.none; - protected String shootsound = "shoot"; - public Turret(String name) { super(name); update = true; diff --git a/core/src/io/anuke/mindustry/world/blocks/types/defense/turrets/LaserTurret.java b/core/src/io/anuke/mindustry/world/blocks/types/defense/turrets/LaserTurret.java new file mode 100644 index 0000000000..6456f28163 --- /dev/null +++ b/core/src/io/anuke/mindustry/world/blocks/types/defense/turrets/LaserTurret.java @@ -0,0 +1,48 @@ +package io.anuke.mindustry.world.blocks.types.defense.turrets; + +import io.anuke.mindustry.content.fx.Fx; +import io.anuke.mindustry.resource.AmmoType; +import io.anuke.mindustry.world.Tile; +import io.anuke.ucore.core.Effects; +import io.anuke.ucore.core.Effects.Effect; +import io.anuke.ucore.core.Timers; +import io.anuke.ucore.util.Mathf; + +import static io.anuke.mindustry.Vars.tilesize; + +public class LaserTurret extends PowerTurret { + + protected float chargeTime = 30f; + protected int chargeEffects = 5; + protected float chargeMaxDelay = 10f; + protected Effect chargeEffect = Fx.none; + protected Effect chargeBeginEffect = Fx.none; + + public LaserTurret(String name) { + super(name); + } + + @Override + public void shoot(Tile tile, AmmoType ammo){ + TurretEntity entity = tile.entity(); + + useAmmo(tile); + + tr.trns(entity.rotation, size * tilesize / 2); + Effects.effect(chargeBeginEffect, tile.drawx() + tr.x, tile.drawy() + tr.y, entity.rotation); + + for(int i = 0; i < chargeEffects; i ++){ + Timers.run(Mathf.random(chargeMaxDelay), () -> { + tr.trns(entity.rotation, size * tilesize / 2); + Effects.effect(chargeEffect, tile.drawx() + tr.x, tile.drawy() + tr.y, entity.rotation); + }); + } + + Timers.run(chargeTime, () -> { + entity.recoil = recoil; + entity.heat = 1f; + bullet(tile, ammo.bullet, entity.rotation + Mathf.range(inaccuracy)); + effects(tile); + }); + } +}