diff --git a/.idea/misc.xml b/.idea/misc.xml index 501ce09..4458232 100644 --- a/.idea/misc.xml +++ b/.idea/misc.xml @@ -1,6 +1,6 @@ - + \ No newline at end of file diff --git a/ProjectElectricLocomotive/EntityElectricLocomotive.java b/ProjectElectricLocomotive/EntityElectricLocomotive.java new file mode 100644 index 0000000..962864f --- /dev/null +++ b/ProjectElectricLocomotive/EntityElectricLocomotive.java @@ -0,0 +1,26 @@ +package ProjectElectricLocomotive; + +import java.awt.*; + +public class EntityElectricLocomotive { + public int Speed; + public int Weight; + public Color BodyColor; + public Color AdditionalColor; + public boolean Horns; + public boolean SeifBatteries; + public double Step() + { + return (double) Speed * 100 / Weight; + } + public void Init(int speed, int weight, Color bodyColor, Color additionalColor, + boolean horns, boolean seifBatteries) + { + Speed = speed; + Weight = weight; + BodyColor = bodyColor; + AdditionalColor = additionalColor; + Horns = horns; + SeifBatteries = seifBatteries; + } +}