I have a Human1 Object and 4 directional Arrow Object (Up, Down, Left, Right)
I want to do the following in one script
OnMouseDown,
Check which directional Arrow was Clicked.
Move Human1 according to the directions.
Example code;
OnMouseDown(){
switch(gameobject)
{
up:
Human1 Moves up;
break;
down:
Human1 Moves down;
break;
Left:
Human1 Moves Left ;
break;
Right:
Human1 Moves Right ;
Break;
}//end switch
}//end OnMouseClick