Arg this code won't work >.<

im trying to put a select in my game
it is a rts based game but when i want to select a unit it now is like a multi select.
i want it when i select a guy it released my select en selects the other.

Here is my code
 Code:
 


//////////////////////////////
// Ingame Unit Control
//////////////////////////////
//var Unit_Selected[30];  //cant store entity in array...
var own_unit;
var secondtry;
string bmp_selected, <Selected.bmp>;

function highlight_me()

{
		 if (event_type == event_click)
       {
       		play_random_snd_hfx();
       		if(own_unit==0)
       		{Selection();secondtry=1;}
       		
       }
	
	
       if (event_type == event_touch)
       {
               my.ambient = 100; 
       }
  
            
       while (event_type != event_release) {wait (1);}
       my.ambient = 0;
}

function DoubleCheck()
{
	while(1)
	{
		if(own_unit==1&&secondtry==1)
		{
			ent_remove(me);
		}
		wait(1);
	}
}

function Selection()
{
	if (!own_unit == 1)
	{	
		me = ent_create (bmp_selected,vector (my.x,my.y,my.z-15 ),DoubleCheck());
		me.tilt = 90;
		own_unit = 1;
		while(!mouse_right)
		{
			me.pan +=-0.2;
			wait(1);
			if(mouse_right)
				{
					own_unit = 0;
					secondtry = 0;
					ent_remove(me);
				}	
		}
	}
}

action my_unit

{
       my.enable_touch = on;
       my.enable_click = on;
       my.enable_release = on;
       my.event = highlight_me;
	
}
//////////////////////////////
// End
//////////////////////////////




hope someone can help me out \:\)

thnx allready,


-The Dragon's Eye is alway's watching you!-