class WintertodtPlugin extends Plugin {

	@Subscribe
	void onVarbitChanged(VarbitChanged varbitChanged)
	{
		int timerValue = client.getVar(Varbits.WINTERTODT_TIMER);
		if (timerValue != previousTimerValue)
		{
			int timeToNotify = config.roundNotification();
			if (timeToNotify > 0)
			{
				int timeInSeconds = timerValue * 30 / 50;
				int prevTimeInSeconds = previousTimerValue * 30 / 50;

				log.debug("Seconds left until round start: {}", timeInSeconds);

				if (prevTimeInSeconds > timeToNotify && timeInSeconds <= timeToNotify)
				{
					notifier.notify("Wintertodt round is about to start");
				}
			}

			previousTimerValue = timerValue;
		}
	}

}