trying to read mouse button doesn't work

…and I am curious as to why. I have:

function OnMouseUpAsButton () {
if (manager.selectedUnit.isMoving) {return;}
//var e : Event = Event.current;
//if (e.button == 0 && e.isMouse) {
manager.MoveCam(manager.camPivot.position,this.transform.position,2);
manager.selectedUnit.marker.enabled = false;
manager.selectedUnit = this;
marker.enabled = true;
followPath = null;
//}
}

I have commented the event check code out because it doesn’t work. Any idea why?

Please format code when posting; it’s really hard to read like that. The Event class can only be used in OnGUI. Use the Input class everywhere else.