Jump to content
  • 0

[Help]Weekly Sieges


l2vicio

Question

I've searched everywhere and there was no good answer..

 

How can i change the sieges to happen every week...

I know a little about java, but i can't find WHERE to modify this.

 

Someone give me a light please!

Link to comment
Share on other sites

13 answers to this question

Recommended Posts

  • 0

/** Set the date for the next siege. */
private void setNextSiegeDate()
{
	while (getCastle().getSiegeDate().getTimeInMillis() < Calendar.getInstance().getTimeInMillis())
	{
if (getCastle().getSiegeDate().get(Calendar.DAY_OF_WEEK) != Calendar.SATURDAY && getCastle().getSiegeDat().get(Calendar.DAY_OF_WEEK) != Calendar.SUNDAY)
			getCastle().getSiegeDate().set(Calendar.DAY_OF_WEEK, Calendar.SATURDAY);
		// from CT2.3 Castle sieges are on Sunday, but if server admins allow to set day of the siege
		// then sieges can occur on Saturdays as well11.			if (getCastle().getSiegeDate().get(Calendar.DAY_OF_WEEK) == Calendar.SATURDAY && !Config.CL_SET_SIEGE_TIME_LIST.contains("day"))
			getCastle().getSiegeDate().set(Calendar.DAY_OF_WEEK, Calendar.SUNDAY);
		// set the next siege day to the next weekend
		getCastle().getSiegeDate().add(Calendar.DAY_OF_MONTH, 7);
	}

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.


×
×
  • Create New...