Commit Graph

117 Commits

Author SHA1 Message Date
Thijs Wiefferink
fb51da84ae Fix a bug with teleporting to signs
If no signs are connected to the region it will now correctly teleport
to the location set by '/as settp' instead of always using the default
location.
2015-01-26 12:31:50 +01:00
Thijs Wiefferink
22d214e59d Add an option to set where '/as find' should teleport you to
Adds the 'findTeleportToSign' option in the general section of
default.yml, you can let it teleport to a sign or to the '/as settp'
location (if no location is set the default location is used)
2015-01-26 12:27:43 +01:00
Thijs Wiefferink
175b531eb5 Fix an unclear message when trying to create a sign for a region that is
already added to AreaShop.
2015-01-21 13:28:23 +01:00
Thijs Wiefferink
52591d3b6e Adds a blacklist of region that cannot be added
The blacklist consists of a list of regular expressions, by default the
'__global__' region is blocked because it is highly unlikely you want to
add that to AreaShop. The blacklist can for example be used to exclude
the spawn region while adding shops at spawn with the WorldEdit
selection of the '/as add' command.
2015-01-21 13:20:32 +01:00
Thijs Wiefferink
825074479c Cleanup 2015-01-18 16:58:33 +01:00
Thijs Wiefferink
cc8cf1e560 Add proper punctuation to all languages (dots at the end) + more
Some preparations are made to later enable proper tab completion for
anyone instead of only OPs. Addfriend command only allows you to add
players that have played on the server before now.
2015-01-18 16:03:21 +01:00
Thijs Wiefferink
a4169d127e Adds dots to all language strings and adds Chinese (Taiwan)
(All language files changed because I made a program to download them
all from Transifex and transform them to the format I want. Only
languages that are translated for 70% or more will be added to AreaShop)
2015-01-17 15:39:08 +01:00
Thijs Wiefferink
21340af89f Change the '/as find' command to randomly pick a region that suits
First searches all matching regions (rent/buy, maxprice and group), then
randomly picks one.
2015-01-12 21:55:01 +01:00
Thijs Wiefferink
db06eae6c9 Add a message to show resell price when using '/as info region' 2015-01-12 21:42:54 +01:00
Thijs Wiefferink
5bae5ecf67 Fix a bug with buying a region while it is in resell mode 2015-01-12 17:11:08 +01:00
Thijs Wiefferink
679ffe2145 Releasing 1 version for WorldGuard 5.9 and one for 6.0+ now
The code represents the state of the WorldGuard 6.0+ version, the
uploaded version for 5.9 has some minor changes.
2015-01-07 12:01:04 +01:00
Thijs Wiefferink
e6c5653073 Changes config version number, adds a file check for schematics 2015-01-06 22:35:08 +01:00
Thijs Wiefferink
ea31dfdd65 Update languages (pulled from Transifex) and change version number 2015-01-06 22:03:23 +01:00
Thijs Wiefferink
9da31fed1f Restored compatibility with WorldGuard 5.9
AreaShop will detect if you use a 5.x version or something else, with
5.x it will add players to the regions by name, and otherwise by UUID.
AreaShop will always save UUID's itself, so future upgrading to higher
WorldGuard versions will be no problem.
2015-01-06 16:02:00 +01:00
Thijs Wiefferink
9baf0b7eec Adds an update checker and fixes some possible bugs
The update checker checks for updates at BukkitDev, if an update is
found it will print a message in the console and notifies OPs when
joining the server. It will never download files itself. The update
check can be switched off in the config. Also tried to fix a bug with
the /as me command, which could break when the friends lists is broken.
2015-01-06 11:46:02 +01:00
Thijs Wiefferink
a14dc4e541 Fix a bug with the periodic updating of signs
If there is no sign connected to the region it would spam an error to
the console when the periodic update task runs.
2014-12-29 16:39:54 +01:00
Thijs Wiefferink
00d3256716 Fix a bug with inactive player unrent/sell settings
If the 'inactiveTimeUntilUnrent' or 'inactiveTimeUntilSell' settings
would be set to a value above 35000 it would cause an integer overflow,
resulting in a 50% chance that all regions will be unrentend/sold (and
if that does not happen it will still sell/unrent them too early). This
is caused by an integer overflow, switching to long fixed this problem.
2014-12-18 16:21:07 +01:00
Thijs Wiefferink
40338b66df Fix a bug with the '/as settp' command not accepting arguments
The command would always try to detect regions at the location you are
standing and would not consider the region argument.
2014-12-16 20:21:33 +01:00
Thijs Wiefferink
715bbfd9e3 Fix a bug where regions would not update after added to a group
Also applicable for removing regions from a group.
2014-12-10 16:08:52 +01:00
Thijs Wiefferink
b679c49405 Update the French language file to the latest version
Adds a little more documentationto all language files, just a minor
note. Now '/as reload' will also load the a new language correctly if
you changed that in the config or language files.
2014-12-10 14:57:34 +01:00
Thijs Wiefferink
dd0930bcea Removes excess debug statemements added in previous commit 2014-12-10 13:15:38 +01:00
Thijs Wiefferink
5b961564e1 Fix a bug with settings in groups.yml and region files
Now if a value has been set for a certain setting it will use it for
sure, now if you use getDoubleSetting() the following happends: 15.0 ->
15.0, 7 -> 7.0, '8.0' -> 8.0, 'bs' -> 0.0. While before only 15.0 would
see it as double, and for the others it would continue searching at the
next place (individual files > groups > default.yml).
2014-12-10 13:14:30 +01:00
Thijs Wiefferink
c12314fa98 Fixes a bug with setting the owner flag
Now correctly splits the content of the owner flag at ', ' instead of
just a space (members flag already does this).
2014-12-08 18:07:04 +01:00
Thijs Wiefferink
e23ad74744 Stops the unnecessary saving of the groups file.
It would mark the groups file as changed every time the groups get
loaded from the file. That would cause a unnecessary save after '/as
reload' and after restart/reload of the server.
2014-12-07 00:04:46 +01:00
Thijs Wiefferink
9957e02e65 Fix a bug with detection of files to convert
Previously it would keep sending 2 messages to console at startup saying
that is is converting files to a new format.
2014-12-06 21:43:07 +01:00
Thijs Wiefferink
07ea919aba Updates the language files to the latest version from Transifex 2014-12-05 16:20:00 +01:00
Thijs Wiefferink
2c1771cc52 Added 'friend regions' to the '/as me' command
And added teleporting to regions you are added as friend (permissions
areashop.teleportfriend and areashop.teleportfriendsign)
2014-12-05 13:48:41 +01:00
Thijs Wiefferink
83778ff803 Changes owners/members handling to WorldGuard to UUID's
Now adding uuid's to the owners/members flag in the flagProfiles section
is default, adding names is possible with 'n:<name>', groups is still
'g:<group>'. Now warnings will be displayed in the console if the size
of a schematic does not match the region size.
2014-12-04 22:56:18 +01:00
Thijs Wiefferink
0c79525144 Prevent actions on regions when it is already deleted from AreaShop
When a region is deleted with '/as del' it wil set a flag in
GeneralRegion to indicate it is deleted (isDeleted() can get it). If
this flag is set then no sign updates, saves to disk etc are being
processed by the tasks anymore. This prevents the following case: #1
task starts saving regions (makes copy of region list). #2 User 
executes '/as del' for a region, removes region file. #3 Task arrives at
the region the user just deleted and saves it to disk again #4 The
region will get loaded again next time the server starts.
2014-12-04 11:50:40 +01:00
Thijs Wiefferink
e719930364 Reworks '/as info region' command for buy regions and fixes a bug
'/as info region' for buy regions now also supports more info, like the
same way as it does for rent regions. Fixed a bug with signs, now they
will correctly keep their orientation when placed again after removal
(by for example schematics).
2014-12-03 23:43:24 +01:00
Thijs Wiefferink
5568ee240b Changes the '/as info' command for rent regions to show more info
Some lines will not show up when based on config options (extending, in
advance renting, restoring), some don't show up if empty (friends,
signs) and some don't show up based on permissions (groups, teleport
location, restoring). Also adds a couple of tags to be used in language
files and the config.
2014-12-03 00:38:55 +01:00
Thijs Wiefferink
46abc8f83d Save WorldGuard regions periodically instead of directly
Now uses the saveChanges() method on RegionManager of WorldGuard, that
will only save regions that are actually changed.
2014-12-01 21:26:06 +01:00
Thijs Wiefferink
cf3139f373 Changes handling WorldGuard flags, it now actually adds friends
Reworked applying flag settings configured in AreaShop to the WorldGuard
region. Now supports adding the friends to the regions, adding groups to
a region (g:groupname, would allow someone 'unlocking' functionality of
a region for a whole group of players) and adding group restrictions to
other flags (for example: 'entry: deny g:non_owners').
2014-12-01 21:00:27 +01:00
Thijs Wiefferink
59627e1b97 Add the '/as delfriend' command and minor changes the addfriend command 2014-11-29 17:08:54 +01:00
Thijs Wiefferink
a25b5a5752 Fix the inactive players options, add the '/as addfriend' command
The unrent/selling of regions for inactive players now correctly checks
the option for rent regions when it is about a rent region, rent regions
also correctly check for OP now.
2014-11-29 16:37:24 +01:00
Thijs Wiefferink
aceb6945fd Cleanup for code of commands, preparations for adding friends to regions
Code to dectect regions when a name of a region is not specified as
argument for commands has been cleaned and made the same for all
commands (language file cleanup is still necessary). Some functions to
manage friends for regions have been added to GeneralRegion (commands
and applying friends to regions still has to be done)
2014-11-27 23:59:44 +01:00
Thijs Wiefferink
cbeffe9316 Add the stopresell command, fix a bug with reselling
If you put your region into resell mode and then sold it to the server
with /as sell, the next player buying the region would get an error or
his region would be in reselling mode directly. Now this is fixed
2014-11-27 20:38:48 +01:00
Thijs Wiefferink
9ea97fdb5d Cleans old code for replacing %clicker% tag 2014-11-25 16:48:11 +01:00
Thijs Wiefferink
ed1f73fdd7 Fixes a problem with the %clicker% tag for use with sign commands
With the previous implementation it would only get replaced for commands
executed as the player, but executing as player is not wanted because
then the player should have permission for that (example: /tellraw). Now
it will properly get replaced for console and player commands attached
to a state of the sign.
2014-11-25 16:47:10 +01:00
Thijs Wiefferink
09af826f88 Add the '/as resell' command to let players sell their region to others
After executing the command the player is still owner and can do
everything like normal. The sign changes to the 'resell' section of the
chosen sign profile. The region flags change to the 'resale' section of
the flag profile (other greeting). When a player buys the region it
transfers the money to the previous owner. New schematic event and
commandevents are available for this action. Previous owner will get a
message if he is online.
A command to stop reselling your region is on the TODO list.
2014-11-24 19:16:55 +01:00
Thijs Wiefferink
1fd24d864d Adds a tag for the player name that clicks the sign
Can be used in the commands that get executed when someone clicks an
AreaShop sign. Tag is %clicker%
2014-11-24 12:58:31 +01:00
Thijs Wiefferink
4125364a96 Add highly configurable rent expire warnings for online players and some
minor changes

Rent expire warnings have profiles in config.yml, the profile can be set
in default.yml. Warning can contain a message to the player if he is
online and also have the possibility to execute certain commands.
Renamed the '/as rentduration' command to '/as setduration'.
2014-11-16 22:41:41 +01:00
Thijs Wiefferink
a6f5a2eb5e Expire warning on login for players that rent regions + bugfixes
An option has been added to show a warning to players when their rent
almost runs out on login (so when they login they get a message for each
region that almost runs out, that means lower timeleft than the
'warningOnLoginTime' setting). Also a bug with schematic restoring has
been fixed and some other minor changes done.
2014-11-15 21:57:26 +01:00
Thijs Wiefferink
5eae75fef1 Add current language files again
(They got lost when changing the project setup)
2014-11-14 20:13:47 +01:00
Thijs Wiefferink
7982531e63 Merge branch 'master' of https://github.com/NLthijs48/AreaShop 2014-11-13 23:39:20 +01:00
Thijs Wiefferink
6ce15b27b7 Change the directory layout 2014-11-13 23:38:31 +01:00
Thijs Wiefferink
b1809fb265 Update README.md 2014-11-13 23:17:45 +01:00
Thijs Wiefferink
0344391588 Add all changes from after the v2.0.2 release
Committing all changes made since the v2.0.2 release for now, starting
now committing will happen regularly instead of only when a version of
AreaShop is released to the public. This commit includes a large amount
of things that changed, the changelog for the upcoming version will list
them all.
2014-11-13 23:06:00 +01:00
Thijs Wiefferink
8d254e17bb Merge pull request #6 from NLthijs48/AreaShop_V1.4
Adds code of V2.0.2
2014-09-24 21:41:20 +02:00
Thijs Wiefferink
2098b9f4e3 Adds code of V2.0.2 2014-09-24 21:40:23 +02:00