@@ -251,7 +251,7 @@ public static void load() {
251251 range = maxRange = 160f ;
252252 hitSize = 8f ;
253253 rotateSpeed = 4 ;
254- outlines = false ;
254+ outlines = faceTarget = false ;
255255 treadRects = new Rect []{new Rect (11f - 32f , 8f - 32f , 14 , 53 )};
256256 ammoType = new ItemAmmoType (Items .copper );
257257 constructor = TankUnit ::create ;
@@ -261,7 +261,9 @@ public static void load() {
261261 y = 0.25f ;
262262 reload = 120f ;
263263 recoil = 0f ;
264+ range = 160f ;
264265 rotate = true ;
266+ rotateSpeed = 7f ;
265267 mirror = false ;
266268 shootY = 4 ;
267269 shootSound = Sounds .pulseBlast ;
@@ -274,7 +276,8 @@ public static void load() {
274276 new ShrapnelBulletType () {{
275277 damage = 36 ;
276278 length = 160f ;
277- toColor = Pal .accent ;
279+ fromColor = Pal .accent ;
280+ toColor = Color .gray ;
278281 }},
279282 new BasicBulletType (2f , 0 , "circle-bullet" ) {{
280283 lifetime = 80f ;
@@ -283,7 +286,7 @@ public static void load() {
283286 intervalBullets = 10 ;
284287 intervalBullet = new LightningBulletType () {{
285288 damage = 1 ;
286- lightningColor = this . hitColor = Pal .accent ;
289+ lightningColor = hitColor = Pal .accent ;
287290 lightningLength = 5 ;
288291 lightningLengthRand = 3 ;
289292 lightningType = new BulletType (1.0E-4f , 0.0f ) {{
@@ -303,8 +306,7 @@ public static void load() {
303306 range = maxRange = 160f ;
304307 hitSize = 10f ;
305308 rotateSpeed = 3 ;
306- outlineColor = Pal .darkerMetal ;
307- outlines = false ;
309+ outlines = faceTarget = false ;
308310 treadRects = new Rect []{new Rect (-25 , -36 , 13 , 71 )};
309311 ammoType = new ItemAmmoType (Items .copper );
310312 constructor = TankUnit ::create ;
@@ -313,10 +315,13 @@ public static void load() {
313315 x = 0f ;
314316 y = 0.5f ;
315317 reload = 60f ;
318+ range = 160f ;
316319 mirror = false ;
317320 rotate = true ;
321+ rotateSpeed = 5f ;
318322 shootSound = Sounds .shootAltLong ;
319323 bullet = new MultiBulletType () {{
324+ range = 160f ;
320325 shake = 3f ;
321326 shootEffect = Fx .shootBigColor ;
322327 smokeEffect = Fx .shootSmokeSquareSparse ;
@@ -338,7 +343,59 @@ public static void load() {
338343 new LaserBulletType (30 ) {{
339344 length = 160 ;
340345 width = 7.5f ;
341- colors = new Color []{Pal .accent , Color .white , Color .white };
346+ colors = new Color []{Pal .accent , Pal .accent , Color .white };
347+ }}
348+ );
349+ }};
350+ }});
351+ }};
352+ castle = new TankUnitType ("castle" ) {{
353+ health = 1400 ;
354+ speed = 0.7f ;
355+ range = maxRange = 220f ;
356+ hitSize = 14f ;
357+ rotateSpeed = 2.5f ;
358+ outlines = false ;
359+ treadFrames = 20 ;
360+ treadRects = new Rect []{new Rect (-8f , -49 , 16 , 95 ), new Rect (-34 , -40 , 13 , 88 )};
361+ ammoType = new ItemAmmoType (Items .copper );
362+ constructor = TankUnit ::create ;
363+
364+ weapons .add (new Weapon ("sw-castle-gun" ) {{
365+ x = y = 0f ;
366+ reload = 120f ;
367+ range = 220f ;
368+ shake = 5f ;
369+ shootY = 8f ;
370+ mirror = false ;
371+ rotate = true ;
372+ rotateSpeed = 3f ;
373+ shootSound = Sounds .pulseBlast ;
374+ bullet = new MultiBulletType () {{
375+ range = 220f ;
376+ shootEffect = smokeEffect = Fx .sparkShoot ;
377+ bullets .add (
378+ new BulletType (10f , 0 ) {{
379+ lifetime = 22f ;
380+ bulletInterval = 1 ;
381+ intervalBullets = 10 ;
382+ hitEffect = despawnEffect = Fx .none ;
383+ intervalBullet = new LightningBulletType () {{
384+ damage = 5 ;
385+ lightningColor = hitColor = Pal .accent ;
386+ lightningLength = 5 ;
387+ lightningLengthRand = 3 ;
388+ lightningType = new BulletType (1.0E-4f , 0.0f ) {{
389+ lifetime = Fx .lightning .lifetime ;
390+ despawnEffect = Fx .none ;
391+ hittable = false ;
392+ }};
393+ }};
394+ }},
395+ new LaserBulletType (300 ) {{
396+ length = 220f ;
397+ lifetime = 22f ;
398+ colors = new Color []{Pal .accent , Pal .accent , Color .white };
342399 }}
343400 );
344401 }};
@@ -368,8 +425,17 @@ public static void load() {
368425 constructor = CrafterUnit ::new ;
369426 }};
370427
428+ ((UnitFactory ) Blocks .groundFactory ).plans .add (new UnitPlan (sentry , 60f * 40f , with (SWItems .compound , 16 , Items .silicon , 7 , Items .titanium , 7 )));
371429 ((UnitFactory ) Blocks .airFactory ).plans .add (new UnitPlan (swarm , 60f * 10f , with (SWItems .compound , 12 , Items .silicon , 7 )));
372- ((Reconstructor ) Blocks .additiveReconstructor ).upgrades .add (new UnitType []{swarm , ambush }, new UnitType []{recluse , retreat });
373- ((Reconstructor ) Blocks .multiplicativeReconstructor ).upgrades .add (new UnitType []{ambush , trap }, new UnitType []{retreat , evade });
430+ ((Reconstructor ) Blocks .additiveReconstructor ).upgrades .addAll (
431+ new UnitType []{swarm , ambush },
432+ new UnitType []{recluse , retreat },
433+ new UnitType []{sentry , tower }
434+ );
435+ ((Reconstructor ) Blocks .multiplicativeReconstructor ).upgrades .addAll (
436+ new UnitType []{ambush , trap },
437+ new UnitType []{retreat , evade },
438+ new UnitType []{tower , castle }
439+ );
374440 }
375441}
0 commit comments