public void clearLightnings()
	{
		Thread t = new Thread(new Runnable()
		{
			@Override
			public void run()
			{
				boolean allLightningsWereAnimated = true;

				while (!allLightningsWereAnimated)
				{

					for (Lightning l : lightnings)
					{
						if (!l.isDone())
						{
							allLightningsWereAnimated = false;
						}
					}
					if (allLightningsWereAnimated)
					{
						lightnings.clear();
					}
					else
					{
						try
						{
							Thread.sleep(1000);
						}
						catch (InterruptedException e)
						{
							// TODO Auto-generated catch block
							e.printStackTrace();
						}
					}
				}
			}
		});

		t.start();

	}