public void keyPressed()
	{ // keys pressed for avatar movement
		
		if(key == CODED && keyCode == RIGHT)
		{
			rightKey = true;
		}
		
		if(key == CODED && keyCode == LEFT)
		{
			leftKey = true;
		}
		
		if(key == CODED && keyCode == UP)
		{
			upKey = true;
		}
		
		if(key == CODED && keyCode == DOWN)
		{
			downKey = true;
		}
		
	}