/// <summary> /// Create the robber ant nest object providing the x and y coordinates of the user's mouse click. /// </summary> /// <param name="positionX">The X co-ordinate of the mouse press and where to create the robber nest object in x-axis.</param> /// <param name="positionY">The Y co-ordinate of the mouse press and where to create the robber nest object in y-axis.</param> private void CreateRobberNest(int positionX, int positionY) { Nest robberNest; robberNest = new Nest(new SOFT152Vector(positionX, positionY)); colonyRobberNests.Add(robberNest); Debug.WriteLine("Added new robber nest at x={0} y={1} to the world.", positionX, positionY); }
/// <summary> /// Create the nest object given the x and y coordinates of the user's mouse click. /// </summary> /// <param name="positionX">The X co-ordinate of the mouse press and where to create the nest object in x-axis.</param> /// <param name="positionY">The Y co-ordinate of the mouse press and where to create the nest object in y-axis.</param> private void CreateNest(int positionX, int positionY) { Nest nest; // Get the vector object for the new nest and create the nest. nest = new Nest(new SOFT152Vector(positionX, positionY)); colonyNests.Add(nest); Debug.WriteLine("Added new nest at x={0} y={1} to the world.", positionX, positionY); }