Изменил(а) на 'EntityPlane.java'

This commit is contained in:
devil_1nc 2022-11-08 14:54:01 +04:00
parent 5324095e2a
commit 91db5cf763

View File

@ -2,8 +2,8 @@ import java.awt.Color;
import java.util.Random;
public class EntityPlane {
private int Speed;
private float Weight;
private int Speed = 0;
private float Weight = 0;
private Color BodyColor;
public int getSpeed(){return Speed;}
@ -16,7 +16,13 @@ public class EntityPlane {
{
Random rand = new Random();
if (speed <= 0) speed = rand.nextInt(350, 550);
else {
Speed = speed;
};
if (weight <= 0) weight = rand.nextFloat(350, 550);
else {
Weight = weight;
}
BodyColor = bodyColor;
}
}