package model.persons;

import java.util.Random;

/**
 * Created by tgdflto1 on 30/09/16.
 */
public class MidAgePerson extends Person{
    public MidAgePerson(double maxHeigth, double maxWidth){

        Random r = new Random();
        double randomWidth = 0 + (maxWidth - PERSON_RADIUS) * r.nextDouble();
        double randomHeight = 0 + (maxHeigth - PERSON_RADIUS) * r.nextDouble();

        this.relocate(randomWidth, randomHeight);
    }
}

@@ -43,16 +43,40 @@
 andom;%0A%0A
+import model.Position;%0A%0A
 /**%0A * C
@@ -155,14 +155,12 @@
 rson
+ 
 %7B%0A
-    
+%09
 publ
@@ -213,19 +213,14 @@
 dth)
+ 
 %7B%0A%0A
-        
+%09%09
 Rand
@@ -236,32 +236,26 @@
 w Random();%0A
-        
+%09%09
 double rando
@@ -312,24 +312,18 @@
 uble();%0A
-        
+%09%09
 double r
@@ -390,17 +390,78 @@
 ();%0A
-%0A        
+%09%09this.setCurrentPosition(new Position(randomWidth, randomHeight));%0A%09%09
 this
@@ -502,12 +502,9 @@
 t);%0A
-    
+%09
 %7D%0A%7D%0A

create currentPosition