Creating planes in runtime

I’m trying to make a re-creation of this ( simple game using Unity.

Is there a way to create a plane (with collision) during runtime that can be changed after placing?

To create objects, make a prefab and Instantiate it at run time.

To move and resize an object, change its transform.position and transform.localScale.

Read the documentation of these functions for details.

You could also try:

GameObject g = (GameObject)GameObject.CreatePrimitive(PrimitiveType.Cube);

g.transform.localscale=new Vector3(mywidth/2,myheight/2,mylength/2);

// from here out just change g.transform.position to move the object.

You cann also use something like this. Look for more here.

using UnityEngine;
using System.Collections;

public class PlaneF : MonoBehaviour {
public Transform vector2;
public Transform vector3;

void Start () {
vector2 = GameObject.Find(“vec2”).transform;

  vector3 = GameObject.Find("vec3").transform;

  Plane myPlane = new