public SimulationObject(MouseEventArgs e, Random rand) { LocationF = new Physics.VectorF(e.X, e.Y); this.Rand = rand; VelocityF.X = (float)rand.NextDouble() * rand.Next(-1, 2); VelocityF.Y = (float)rand.NextDouble() * rand.Next(-1, 2); SizeF.X = (float)rand.Next(20, 100); SizeF.Y = (float)rand.Next(20, 100); Rotation = rand.Next(0, 360); Mass = SizeF.Y * SizeF.X; }
public Physics.VectorF UpdateLocation(SimulationObject simObj, List <SimulationObject> SimObjs) { Physics.VectorF newItem = simObj.LocationF; return(newItem); }
public void ChangeVelocity(Physics.VectorF newVector) { VelocityF.X = newVector.X; VelocityF.Y = newVector.Y; }