Move a GameObject using Raycasting Hit position

var buildingObject : GameObject;
var myGround : Transform;

function Update () {

function checkForBuilding() {
        var ray = Camera.main.ScreenPointToRay (Input.mousePosition);
        var hit : RaycastHit;
         if (Physics.Raycast (ray, hit, 100) && hit.collider.gameObject.CompareTag("Ground")){
                //This is where i want to tell my buildingObject to move

I'm struggling to get my head around getting the buildingObject transform position to be where the raycasting has hit.

any suggestions on the simplest way of achieving this?

Thanks - C

With RaycastHit.point you get the position (Vector3) and with RaycastHit.normal the normal of the surface (also Vector3) witch you can use for rotation. But for buildings you should use no rotation. Then you could instantiate your building like this:

Instantiate(buildingObject, hit.point, Quaternion.identity);

Make sure your building is a prefab and the y-origin of it is 0.