@EventHandler
	public void onButtonClick(ButtonClickEvent event) 
	{
		SpoutPlayer sPlayer = event.getPlayer();
		friendsList list = new friendsList(sPlayer, plugin);
		levels stats = new levels(sPlayer, plugin);
		
		if (event.getButton() instanceof friendsListButton)
		{
			sPlayer.getMainScreen().closePopup();
			sPlayer.getMainScreen().attachPopupScreen(list);			
			sPlayer.getMainScreen().setDirty(true);
		}
		
		else if (event.getButton() instanceof addInputButton)
		{
			sPlayer.sendMessage(friendname);
			FriendMap.addnewFriend(event.getPlayer(), friendname);
		}
		
		else if (event.getButton() instanceof statButton)
		{
			sPlayer.getMainScreen().closePopup();
			sPlayer.getMainScreen().attachPopupScreen(stats);
			sPlayer.getMainScreen().setDirty(true);
		}
		
		else if (event.getButton() instanceof exitButton) 
		{
			sPlayer.getMainScreen().closePopup();
		}
	}