Linking Skills to play Animations

Hey guys so I’ve gotten quite a bit down with the basics of unity and I can understand most of the syntax with Java and C# but I’ve had some problems creating my own scripts and getting them to work the way that I want too so I’ve relied heavily on tutorials and reviewing other scripts that people have written. I guess its that I know what i want to do and how to do it I just can’t do it… if that makes any sense. With that here’s my issue. I’ve gotten my characters to move around with my scripts with my character controller and I can fire off particles for skills with this script:

    var btnTexture : Texture;
    var bullitPrefab:Transform;
    var SpellSound : AudioClip;
     
function OnGUI() {

    if (!btnTexture) {

        Debug.LogError("Please assign a texture on the inspector");

        return;

    }

    if (GUI.Button(Rect(506,Screen.height - 105,35,35),btnTexture))

    {

        audio.PlayOneShot(SpellSound);

		var bullit = Instantiate(bullitPrefab, transform.position, Quaternion.identity);

        bullit.rigidbody.AddForce(transform.forward * 200);

    }

}

However my issue is inputting in a command such as

public void Fire1() {
	animation.CrossFade("Fire1");	

for an animation to trigger with the skill once its cast. I was trying to work it out so that I wouldn’t have to script in the animation skill with my CharacterInput script and trigger the skill based off of animation events because I wanted the players to have the freedom to change up skills in a skill bar. If anyone can offer any kind of advice on this it would be much appreciated. Thanks for taking the time to read this over sorry I’m not an indept coder/programer just a guy that picked up unity a few months ago.

Regards,

-Alio

As far as the animation events, with the animation view window you can slide your animations to certain points and at that point of the animation have it trigger a script. i was going to just have my animations play with my character controller with a if(GetButtonDown statement for the firing animations and have them hard coded into my script to trigger the spell script at the apex of the cast animation. I know that this is most definately not the right way to go about doing it but I have no understanding of how to compile arrays and strings to call back to the base characters and their animation list. Its hard enough with just one character but I want to do it for multiple characters which I have created along with their animations. I suppose once I get one done the rest should be pretty easy as long as I keep the animation names the same. As far as looking on the unity site references I know where and how to find that information the problem is knowing how and where to plug it into my scripts for my game.