diff --git a/Tank/src/DrawingTank.java b/Tank/src/DrawingTank.java index 2d2d5f7..1f363ce 100644 --- a/Tank/src/DrawingTank.java +++ b/Tank/src/DrawingTank.java @@ -120,6 +120,7 @@ public class DrawingTank { g2.drawPolygon(xPointsGun,yPointsGun,nPointsGun); g2.fillPolygon(xPointsGun,yPointsGun,nPointsGun); } + public void ChangeBorders(int width,int height) { _pictureWidth = width; diff --git a/Tank/src/EntityTank.java b/Tank/src/EntityTank.java index 5b36178..37840a1 100644 --- a/Tank/src/EntityTank.java +++ b/Tank/src/EntityTank.java @@ -17,7 +17,6 @@ public class EntityTank { public float Step; public void Init(int speed, float weight, Color bodyColor){ - Random rnd = new Random(); Speed = speed <= 0 ? rnd.nextInt(50)+10 : speed; Weight = weight <= 0 ? rnd.nextInt(100)+500 : weight;