SOS. Box collider trigger for audio

have a presentation in a few hours, and im desperate. one of my scripts is acting up.

Basically a Box Collider is hit and audio and text come out.

var stringToEdit = " ";
var showgui:int=0;
var PlayClip:audio.Play;

function OnGUI () {

if (showgui==1){
    // Make a multiline text area that modifies stringToEdit.
    stringToEdit = GUI.TextArea (Rect (10, 10, 300, 100), stringToEdit, 200);audio.Play(PlayClip);
    }
}

function OnTriggerEnter(){
showgui=1;
}

GUI came out but audio was messed up! Whats wrong?

That code wouldn't actually compile anyway; maybe you wanted something more like this:

var stringToEdit = " ";
var showgui = false;
var playClip : AudioClip;

function OnGUI () {
    if (showgui) {
        // Make a multiline text area that modifies stringToEdit.
        stringToEdit = GUI.TextArea (Rect (10, 10, 300, 100), stringToEdit, 200);
    }
}

function OnTriggerEnter(){
    showgui = true;
    audio.clip = playClip;
    audio.Play();
}

OnGUI runs at least twice per frame, so it's unlikely you want audio.Play() in there.