im getting th error "cannon convert "int" to "system.type"" what is wrong?

var PlayerState = float;
var PlayerAnimsec:GameObject;
function Update () {
}
function PlayerStateController(){
if(Input.GetButton(“Horizontal”)!=0||Input.GetButton(“Vertical”)!=0){
PlayerState = 1;
}
}

The error is caused by the first line:

var PlayerState = float;

This assigns the type float to PlayerState. You should use a “:” instead - like this:

var PlayerState : float;