TownBlockStatus

An explanation of the many types of TownBlockStatus, as deduced from the Towny source code (specifically a rundown of the TownBlockStatus enum defined in PlayerCache, and given by getTownBlockStatus in PlayerCacheUtil). There was no explanation of any of these given anywhere, so here is what I deduced. If you want to change what plots the notification triggers in, you will need to know these.

TownBlockStatus is the state of the town block in respect to a player stood in that block.

In the following table, "resident" is the player being considered, "town block" is the town block the resident is stood in, and "owner" is the resident who owns that town block. The table is ordered in the order of prevalence of the statuses. The Config Option column states which option in the configuration represents that town block status, and the Default column gives the default value that option has - see here for more.

StatusMeaningConfig OptionDefault
UNKOWNUnknown status - initial assignment before the status is actually calculated. Should not ever actually be passed to TownyNotifier - NOT_REGISTERED will probably happen first. Misspelled in source. Unwise to change from false - included for completion.unknownfalse
OFF_WORLDResident is on world on the server that Towny does not manage (e.g. a separate creative world, or a map-based PVP world, etc) - set using /townyworld toggle usingtowny or by editing a Towny config file. You probably do not want to change this from false unless you have a good reason to.offworldfalse
NOT_REGISTEREDThere was an issue with the world or resident (one of them could not be registered correctly; an exception was thrown). Unwise to change from false - included for completion.notregisteredfalse
UNCLAIMED_ZONEResident is stood in a town block not yet claimed by any town - the wilderness.unclaimedfalse
LOCKEDA plot that has been locked by Towny. This occurs when the plot's status has been changed too much in a short time, and expires after some time has passed or server restarted.lockedfalse
WARZONEResident is stood in any part of any nation, resident's town is part of a nation, and a war is ongoing. Also includes outsiders when nationless towns are allowed in the war.warzonefalse
TOWN_OWNERResident is mayor of the town which the town block is a part of.townownerfalse
PLOT_OWNERResident is owner of the town block.plotownerfalse
PLOT_FRIENDResident is on the owner's friend list.plotfriendfalse
PLOT_ALLYResident's and owner's towns are allies. Also applies when resident and owner are part of the same town.plotallytrue
OUTSIDERResident is not part of the town which the town block belongs to, resident's town is not an ally of the town, and resident is not a friend of owner.outsidertrue
TOWN_ALLYResident is stood in a town block of an allied town, and the town block is not owned by a player (i.e. an unclaimed or for sale plot). Unlike PLOT_ALLY, does not include the same town.townallytrue
ENEMYResident is stood in an enemy town, when not at war.enemytrue
TOWN_RESIDENTResident is stood in a town block of their town, and the town block is not owned by a player (i.e. an unclaimed or for sale plot).townresidenttrue

Comments

Posts Quoted:
Reply
Clear All Quotes