I need help with Unity Scrips

Hello every one am going to use the underwater scrips from unity in Unity 4.2.1,And wen i open in a new project it set that the float cant be converted to unity here is the scrips from unity island underwater can any one help me.

var waterLevel : float;
var uAudio : AudioClip;
var aAudio : AudioClip;

var uColor = Color(1,1,1,1);
var uDensity = .05;

var aColor = Color(1,1,1,1);
var aDensity = .008;

var waterSurface : Renderer;
var underwaterSurface : Renderer;

private var below = false;
private var glow : GlowEffect;
private var blur : BlurEffect;


function Awake() {
	if(!waterLevel)
	{
		water = FindObjectOfType(Water);
		if(water) waterLevel = water.gameObject;
	}
	aColor = RenderSettings.fogColor;
	aDensity = RenderSettings.fogDensity;
	
	glow = GetComponent(GlowEffect);
	blur = GetComponent(BlurEffect);
	if( !glow || !blur )
	{
		Debug.LogError("no right Glow/Blur assigned to camera!");
		enabled = false;
	}
	if( !waterSurface || !underwaterSurface )
	{
		Debug.LogError("assign water  underwater surfaces");
		enabled = false;
	}
	if( underwaterSurface != null )
		underwaterSurface.enabled = false; // initially underwater is disabled
}

function Update ()
{
	if (waterLevel < transform.position.y  below)
	{
		audio.clip = aAudio;
		audio.Play();
		RenderSettings.fogDensity = aDensity;
		RenderSettings.fogColor = aColor;
		
		below = false;
		
		glow.enabled = !below; 
		blur.enabled = below; 
		waterSurface.enabled = true;
		underwaterSurface.enabled = false;
	}
	
	if (waterLevel > transform.position.y  !below)
	{
		audio.clip = uAudio;
		audio.Play();
		RenderSettings.fogDensity = uDensity;
		RenderSettings.fogColor = uColor;
		
		below = true;
		
		glow.enabled = !below; 
		blur.enabled = below;
		waterSurface.enabled = false;
		underwaterSurface.enabled = false;
	}
}

Thanks Black Mantis for the Advise

It helps to write down the error word for word, and what line the error is on. Also your code is easier to read if our code is inside code tags. You can find the code tags options from clicking the Go Advanced button at the bottom right of the page when creating your post.

waterLevel = water.gameObject;

this might be your error…

remove the above code and check…

I did what you said but create more problems

Forgot to mention am using Indy Version of Unity 3D i now there is a different in Pro and Indy

On line 23 change this water.gameObject; to water.transform.position.y; .

Your code is trying to set a float from the position of the water.

Thanks Black Mantis:Wen i make the change it wen from underwater scrip to update scrips i thing this scrip don’t work on unity 4 they whore make for Unity 2.6 or below, Unles Unity fix this scrip to work with unity 4 i won’t be able to use them

This is the error from the update scrip hoping this will fix the problem

@MenuItem("Terrain/Update Tree Lightmap Color")
static function RebuildWithLightmap () {
	var tex : Texture2D = Selection.activeObject as Texture2D;
	if (tex)
	{
		if (Terrain.activeTerrain == null || Terrain.activeTerrain.terrainData == null)
		{
			EditorUtility.DisplayDialog("No active terrain in the scene", "No active terrain in the scene", "Ok");
			return;
		}
		
		Undo.RegisterUndo(Terrain.activeTerrain.terrainData, "Set Tree colors");
		UnityEditor.TerrainLightmapper.UpdateTreeLightmapColor(tex, Terrain.activeTerrain.terrainData);
	}
	else
		EditorUtility.DisplayDialog("Select a lightmap", "Select a lightmap", "Ok");
}

@MenuItem("Terrain/Update Tree Color")
static function RebuildWithColor () {
	var tex : Texture2D = Selection.activeObject as Texture2D;
	if (tex)
	{
		if (Terrain.activeTerrain == null || Terrain.activeTerrain.terrainData == null)
		{
			EditorUtility.DisplayDialog("No active terrain in the scene", "No active terrain in the scene", "Ok");
			return;
		}
		
		Undo.RegisterUndo(Terrain.activeTerrain.terrainData, "Set Tree colors");
		UnityEditor.TerrainLightmapper.UpdateTreeColor(tex, Terrain.activeTerrain.terrainData);
	}
	else
		EditorUtility.DisplayDialog("Select a lightmap", "Select a lightmap", "Ok");
}

PS. I remove this scrips from the island and is working fine know.
Thank you for the help