package org.mwc.debrief.core.creators.shapes;

import MWC.GUI.Shapes.LineShape;
import MWC.GUI.Shapes.PlainShape;
import MWC.GUI.Shapes.VectorShape;
import MWC.GenericData.WorldLocation;
import MWC.GenericData.WorldVector;

/**
 * @author ian.mayo
 *
 */
public class InsertVector extends CoreInsertShape
{


	/** produce the shape for the user
	 * 
	 * @param centre the current centre of the screen
	 * @return a shape, based on the centre
	 */
	protected PlainShape getShape(WorldLocation centre)
	{
		// generate the shape
		PlainShape res = new VectorShape(centre,
        centre.add(new WorldVector(MWC.Algorithms.Conversions.Degs2Rads(45.0),
            0.05, 0)));
		return res;
	}	
	
	/** return the name of this shape, used give the shape an initial name
	 * 
	 * @return the name of this type of shape, eg: rectangle
	 */
	protected String getShapeName()
	{
		return "vector";
	}	
	
}

@@ -44,41 +44,8 @@
 s;%0A%0A
-import MWC.GUI.Shapes.LineShape;%0A
 impo
@@ -137,24 +137,24 @@
 ta.World
-Location
+Distance
 ;%0Aimport
@@ -175,22 +175,24 @@
 ta.World
-Vector
+Location
 ;%0A%0A/**%0A 
@@ -535,108 +535,51 @@
 tre,
-%0A        centre.add(new WorldVector(MWC.Algorithms.Conversions.Degs2Rads(45.0),%0A            0.05, 0)
+45.0, new WorldDistance(4, WorldDistance.NM
 ));%0A

create as vector, to keep constructors 'pure'