Skip to content

Frequently Asked Questions

Thijs Wiefferink edited this page Sep 15, 2016 · 22 revisions

Quick select:


How to disable the greeting messages that AreaShop regions have?

If you don't want the greetings then you can disable them like this:

  1. Open the config.yml file that is inside the AreaShop folder
  2. Scroll to the flagProfiles section
  3. Change each line that starts with greeting: to this: greeting: ''
  4. Save the file, then use /as reload or restart your server.

Why can't the buyer/renter of the region build inside of it?

You probably have more regions at the same spot as the region you use for AreaShop, this prevents the members/owners of the region from building inside of it. You can set the priority of other regions to something lower than 0 with /region setpriority <region> <number>, if that is not an option you can set the priority of the AreaShop regions to something higher:

  1. Open the config.yml file
  2. Scroll to the flagProfiles section
  3. Add the following line to all the sections that are inside the default profile (be sure to indent this line with the same number of spaces as for example the members one): priority: 1
  4. Save the file, then use /as reload or restart your server.

How can I set the buyer/renter as owner of a region instead of member?

Quick answer: Replace members: in the flagProfiles section of the config.yml file to owners: and then use /as reload.

You can completely customize which WorldGuard flags AreaShop should set for regions, including how it should add the renter/buyer, and friends. The flagProfiles section in the config.yml file contains all options for WorldGuard flags. Currently there are 5 states a region can be in (forrent, rented, forsale, sold, resale), for each of these you can set the flags that you want. \Things that might help you:

  • You can set the priority of a region here just like you would set a flag, this helps if you have other regions interfering (add the line to all states).
  • You can set group flags to for example only give access to chests for the renter of the region: chest-access: 'deny g:non_members'
  • You can use all variables in these flags as defined in the config.
  • The owners and members flag take UUIDs as arguments, but also accept names (n:<name>), and permission groups (g:<group>).
  • Use '' as value of a flag to reset it.

How to setup different limits for different players groups and worlds? (how many regions each player can buy)

First of all read the text above the limitGroups config section inside the config.yml file, that is the basic information you need. An advanced example about most aspects of the limitGroups section can be found here: advanced limitgroups setup examples.

What happens when a player changes his name?

General notes:

  • If you have your server in offline mode (and are not using the bungeecord: true setting for when you have a BungeeCord network) then a player will lose his bought regions anyway because the UUID's returned by Bukkit/Spigot will change anyway.
  • Even when the sign and/or greeting is showing an old name, the correct player will still be paying for the region. That is because AreaShop uses UUID's and that ensures the correct player is accounted for, the old names on signs/greetings is simply because those did not get updated yet (starting from AreaShop V2.1.5 they automatically update).

Using AreaShop V2.1.5 or higher:

  • Name changes are fully supported and should give no trouble at all. When a player with a changed name logs in AreaShop will detect a name change and then updates all of his regions. That ensures that even when you use WorldGuard 5.X the player will immediately have access to his region again and also ensures that the signs and greeting messages show the new name of the player.

Using an older AreaShop version:

  • Update if you can, that is simply the best idea to handle it best (be sure to backup your server before upgrading as always).
  • Since AreaShop V1.3.0 the players that bought/rented a region are saved with their UUID instead of their name, so from this version a user would be registered correctly in the system of AreaShop even after changing his name.
  • If you use AreaShop V2.1.0 or higher in combination with WorldGuard 6.0 or higher then the user should be able to use his regions as normal directly after his name change (after re-logging with the new name of course), but the old name is still displayed on the signs and in the greeting message (manually update with /as updaterents and /as updatebuys, or simply update to the latest AreaShop to automate it)
  • If you use a version of AreaShop between V1.3.0 and V2.1.0 or WorldGuard 5.9, then the AreaShop region of the player that changed his name will need to be updated first before he can use it again. You can do this by using /as updaterents and/or /as updatebuys. (WorldGuard 5.9 uses names as members/owners of regions, so AreaShop could not properly add a player, but could only update it after a player changed his name)

How to prevent players from opening chests in regions that other players bought/rented?

To prevent other players from opening and using chests in regions that are bought/rented you can add a line to the flagProfiles section in the config.yml file. The flagProfiles section describes which flags AreaShop should add to the WorldGuard region and which value they should have. To disable using chests you can add the following line: chest-access: deny g:non_members, that would disallow using chest for anyone that is not a member or owner of the region. The complete flagProfiles section in the config could look something like this after you added it:

flagProfiles:
  default:
    forrent:
      members: ''
      greeting: '%lang:prefix%%lang:greeting-forrent%'
      chest-access: 'deny g:non_members'
    rented:
      members: '%uuid%, %friendsuuid%'
      greeting: '%lang:prefix%%lang:greeting-rented%'
      chest-access: 'deny g:non_members'
    forsale:
      members: ''
      greeting: '%lang:prefix%%lang:greeting-forsale%'
      chest-access: 'deny g:non_members'
    sold:
      members: '%uuid%, %friendsuuid%'
      greeting: '%lang:prefix%%lang:greeting-bought%'
      chest-access: 'deny g:non_members'
    resale:
      members: '%uuid%, %friendsuuid%'
      greeting: '%lang:prefix%%lang:greeting-resale%'
      chest-access: 'deny g:non_members'

The above assumes that you also want players unable to interact with chests if the region is not rented or bought. If you however want to allow raiding of abandoned regions you can change the chest-access lines of the forrent and forsale sections to the following: chest-access: 'allow', which allows anyone to use the chests.

How can I use items as currency to pay for regions of AreaShop?

AreaShop supports all economy plugins that are supported by Vault, so if you want to use items as currency then you need an economy plugin that has that and also works with Vault. The Gringotts economy should work for this purpose, this plugin has been successfully used by a couple AreaShop users. There might be other suitable plugins to do the same thing though.

How do I require players to confirm that they want to rent/unrent/buy/sell their region?

Because clicking a sign to rent/unrent can be a bit too easy sometimes, you might want to have confirmation messages. You can add those by changing the signProfiles in the config.yml file to send a /tellraw message to the user instead of immediately buying/renting a region. This will mean that the player will first get a message in chat asking to confirm, and the player can click the confirm text of the message to perform the action.

To get confirmation messages copy the signProfile below to your config.yml file, below the default one.

  confirm:
    forrent:
      line1: '&2&l[For Rent]'
      line2: '%region%'
      line3: '%duration%'
      line4: '%price%'
      rightClickConsole:
      - 'tellraw %clicker% [{"text":"[Areashop]","color":"dark_green"},{"text":" Are you sure you want to rent region %region%? ","color":"white"},{"text":"[Yes, go ahead]","color":"dark_green","clickEvent":{"action":"run_command","value":"/areashop rent %region%"},"hoverEvent":{"action":"show_text","value":{"text":"","extra":[{"text":"Click to rent %region%"}]}}}]'
      leftClickPlayer:
      - 'areashop info region %region%'
    rented:
      line1: '&4&l[Rented]'
      line2: '%region%'
      line3: '%player%'
      line4: '%untilshort%'
      rightClickConsole:
      - 'tellraw %clicker% ["",{"text":"[Areashop]","color":"dark_green"},{"text":" Are you sure you want to extend the rent of region %region%? ","color":"white"},{"text":"[Yes, go ahead]","color":"dark_green","clickEvent":{"action":"run_command","value":"/areashop rent %region%"},"hoverEvent":{"action":"show_text","value":{"text":"","extra":[{"text":"Click to extend %region%"}]}}}]'
      leftClickPlayer:
      - 'areashop info region %region%'
      shiftRightClickConsole:
      - 'tellraw %clicker% ["",{"text":"[Areashop]","color":"dark_green"},{"text":" Are you sure you want to unrent region %region%? ","color":"white"},{"text":"[Yes, go ahead]","color":"dark_green","clickEvent":{"action":"run_command","value":"/areashop unrent %region%"},"hoverEvent":{"action":"show_text","value":{"text":"","extra":[{"text":"Click to unrent %region%"}]}}}]'
    forsale:
      line1: '&2&l[For Sale]'
      line2: '%region%'
      line3: '%price%'
      line4:
      rightClickConsole:
      - 'tellraw %clicker% ["",{"text":"[Areashop]","color":"dark_green"},{"text":" Are you sure you want to buy region %region%? ","color":"white"},{"text":"[Yes, go ahead]","color":"dark_green","clickEvent":{"action":"run_command","value":"/areashop buy %region%"},"hoverEvent":{"action":"show_text","value":{"text":"","extra":[{"text":"Click to buy %region%"}]}}}]'
      leftClickPlayer:
      - 'areashop info region %region%'
    resell:
      line1: '&9&l[Resale]'
      line2: '%region%'
      line3: '%resellprice%'
      line4: '&8%player%'
      rightClickConsole:
      - 'tellraw %clicker% ["",{"text":"[Areashop]","color":"dark_green"},{"text":" Are you sure you want to buy region %region% from %player%? ","color":"white"},{"text":"[Yes, go ahead]","color":"dark_green","clickEvent":{"action":"run_command","value":"/areashop buy %region%"},"hoverEvent":{"action":"show_text","value":{"text":"","extra":[{"text":"Click to buy %region% from %player%"}]}}}]'
      leftClickPlayer:
      - 'areashop info region %region%'
      shiftRightClickConsole:
      - 'tellraw %clicker% ["",{"text":"[Areashop]","color":"dark_green"},{"text":" Are you sure you want to stop reselling region %region%? ","color":"white"},{"text":"[Yes, go ahead]","color":"dark_green","clickEvent":{"action":"run_command","value":"/areashop stopresell %region%"},"hoverEvent":{"action":"show_text","value":{"text":"","extra":[{"text":"Click to stop reselling %region%"}]}}}]'
    sold:
      line1: '&4&l[Sold]'
      line2: '%region%'
      line3: '%player%'
      line4:
      leftClickPlayer:
      - 'areashop info region %region%'
      shiftRightClickConsole:
      - 'tellraw %clicker% ["",{"text":"[Areashop]","color":"dark_green"},{"text":" Are you sure you want to sell region %region%? ","color":"white"},{"text":"[Yes, go ahead]","color":"dark_green","clickEvent":{"action":"run_command","value":"/areashop sell %region%"},"hoverEvent":{"action":"show_text","value":{"text":"","extra":[{"text":"Click to sell %region%"}]}}}]'

To switch to the signProfile with the confirmation messages you have to set the signProfile setting inside the default.yml file to confirm (alternatively you can set this profile only for region in a certain group, individual regions or individual signs).

To generate the correct tellraw messages with a site like Tellraw Generator, or you could change the above messages to your liking.

How can I set a delay for the teleporting commands (/as tp, /as find)?

You can use a plugin like BoosCooldowns to set warmup and cooldows for commands. Check Issue #60 for reasons I'm not implementing adding this to AreaShop itself.

How can I let signs show the time left instead of the end time of a rental?

In the signProfiles section of config.yml you can change the %untilshort% variable to a %timeleft% (you can find it in the rented sign state) variable to show the time that is left instead of the end time. This will help to prevent confusion because of time zones being different for the player and the server.

How do I let a player automatically teleport to a region after he bought/rented it?

Set the 'eventCommandProfiles' section of the config to the following (assuming you have Essentials installed which provides the sudo command):

eventCommandProfiles:
  default:
    created:
      before:
      after:
    deleted:
      before:
      after:
    rented:
      before:
      after:
      - "sudo %player% areashop tp %region%"
    extended:
      before:
      after:
    unrented:
      before:
      after:
    bought:
      before:
      after:
      - "sudo %player% areashop tp %region%"
    sold:
      before:
      after:
    resell:
      before:
      after:

The listed commands will be executed after a player bought/rented a region and force them to use the teleport command to get to their region.

How do I add tax to a buy region?

You cannot directly add a tax, however you can change it into a rental region for which you pay more the first time. This would achieve the same thing, for example buying a region for 1000, and then paying 50 each week to keep it.

First set the price of the region to the initial price you want to charge (1000 in this example). Then change the eventCommandProfiles section in config.yml to the following to setup the tax:

eventCommandProfiles:
  default:
    created:
      before:
      after:
    deleted:
      before:
      after:
    rented:
      before:
      after:
      - "areashop setprice 50 %region%"
    extended:
      before:
      after:
    unrented:
      before:
      after:
      - "areashop setprice 1000 %region%"
    bought:
      before:
      after:
    sold:
      before:
      after:
    resell:
      before:
      after:

Why is my custom profile not working? (flagProfile, signProfile, etc.)

You probably did not assign the profile to a region or region group correctly. One thing to note is that names of profiles have nothing to do with region group names, they are not automatically linked. To set a profile for a region group you need to have something like this in your groups.yml file (the general: line and profile lines are important to add):

mallshops:
  name: mallShops
  priority: 0
  general:
    flagProfile: aFlagProfileName
    signProfile: aSignProfileName
  regions:
  - mall01
  - mall02