Commit Graph

32 Commits

Author SHA1 Message Date
Josh Roy
f6cb9ff470
Improve command codestyle (#3337)
Co-authored-by: MD <1917406+md678685@users.noreply.github.com>

Fixes #3579 (async `/skull` command)
Fixes #3336 (improve codestyle of commands)
Partially addresses #3339 (`/spawn` and `/setspawn` are now hidden from tabcomplete)
Closes #3087 (`/paytoggle` is now a loop command)
2020-08-11 19:09:22 +01:00
Josh Roy
23f0f98af3
Cleanup code (#3067)
Co-Authored-By: md678685 <1917406+md678685@users.noreply.github.com>

Basically cleans up a bunch of warnings that are easily suppressed.
2020-04-25 13:08:57 +01:00
Ali 'SupaHam' M
bbe0ca9302 Implement tab completion for all commands. (#1282)
List of supported commands:
```
/afk
/balance
/balancetop
/ban
/banip
/bigtree
/book
/broadcastworld
/burn
/clearinventory
/condense
/delhome
/deljail
/delwarp
/eco
/enchant
/enderchest
/essentials
/exp
/ext
/feed
/fireball
/firework
/gamemode
/getpos
/give
/hat
/heal
/help
/helpop
/home
/ignore
/invsee
/item
/itemdb
/jump
/kick
/kill
/kit
/lightning
/list
/mail
/me
/msg
/mute
/near
/nick
/nuke
/pay
/potion
/powertool
/ptime
/pweather
/recipe
/remove
/repair
/sell
/showkit
/skull
/speed
/tempban
/thunder
/time
/togglejail
/tp
/tpa
/tpaall
/tpahere
/tpall
/tphere
/tpo
/tpohere
/tppos
/tree
/warp
/weather
/world
/worth```
2017-06-11 01:17:43 +01:00
drtshock
dde0b20775 Reformat 2015-04-14 23:06:16 -05:00
KHobbits
36e580474f Converted emulated player class calls to use base class. 2014-04-13 01:01:49 +01:00
FearFree
5724c0c8df Future Java versions may not support _ as identifier. 2014-03-22 16:08:11 +11:00
KHobbits
6f85761f7f Extract CommandSender to CommandSource, this should prevent Ess user object leaks. 2013-10-16 21:05:33 +01:00
KHobbits
d858555263 Don't cast sender to User. 2013-07-11 09:20:52 +01:00
KHobbits
1abacf00df More cleanup 2013-07-07 13:02:40 +01:00
KHobbits
09f67c9723 Split util classes. 2013-06-08 22:31:19 +01:00
KHobbits
c4173c0486 Allow powertool to be set from console. 2013-04-30 02:18:22 +01:00
KHobbits
932de33349 Little bit of powertools code cleanup. 2012-04-04 00:40:58 +01:00
KHobbits
195604997b Enable powertools if they are disabled when setting a new tool. 2012-04-04 00:39:59 +01:00
KHobbits
c0e903c1f3 New permissions: essentials.powertool.append. 2011-12-09 21:42:36 +00:00
snowleo
220d68f375 Switch to the new I18n class and format cleanup of all classes 2011-11-21 02:55:26 +01:00
KHobbits
fd2ec22919 Clear all powertools - /powertool c: 2011-11-04 16:42:03 +00:00
okamosy
d2bf35dac2 added a clearall option to powertools 2011-09-10 10:39:35 +01:00
snowleo
17e11adf9a Catch NPE in /powertool, also cleanup 2011-08-30 01:14:03 +02:00
snowleo
6427a93d14 Correctly charge for the use of commands.
We now first test, if the user could pay it, do the stuff and then charge him. If the command throws an exception, the user will not be charged.
2011-08-27 23:14:49 +02:00
KHobbits
00050d08d4 Powertool fix. 2011-08-27 02:54:45 +01:00
okamosy
53a73998a2 Updated joinList to properly handle lists of lists. 2011-08-23 23:40:41 +01:00
okamosy
f12a14d7f7 Added util function concat(List) and concat(string, list) to concatenate lists into a string.
Updated powertool to use new concat method.
2011-08-23 23:40:27 +01:00
okamosy
c0d21b6044 Removed commented-out code 2011-08-21 20:06:25 +01:00
okamosy
e10675dfdc Completed changing powertool config from tokenized string to lists 2011-08-21 19:33:37 +01:00
okamosy
812a357361 added config upgrade for powertools 2011-08-21 19:02:01 +01:00
okamosy
43d7fb367b converted powertool config to use lists instead of tokenized strings
Powertool update
2011-08-21 17:52:58 +01:00
okamosy
45f88016fc Added ability to assign multiple powertools to an item
Added option to list commands assigned powertools
2011-08-21 02:50:48 +01:00
snowleo
117d938ac5 Several bug fixes and cleanup.
Found using PMD and FindBugs.

git-svn-id: https://svn.java.net/svn/essentials~svn/trunk@1553 e251c2fe-e539-e718-e476-b85c1f46cddb
2011-06-01 10:40:12 +00:00
ementalo
92b34ec15f [trunk] translations = T's
git-svn-id: https://svn.java.net/svn/essentials~svn/trunk@1424 e251c2fe-e539-e718-e476-b85c1f46cddb
2011-05-11 22:42:48 +00:00
snowleo
224c18348a This is a big refactoring of the user class and more.
Many commands have been cleaned.

File changes:
- all user data has been moved from users.yml to userdata folder
- all files in userdata folder are lower case
Both changes should be done automatically.

Class changes:
- Moved all user data functions to UserData class
- Moved all user teleport functions to Teleport class
- Moved the user list to Essentials class
- Less static functions for better testing
- EssentialsCommand now has ess Property (Essentials class)
- New NotEnoughArgumentsException, that will show command description and syntax

New commands:
- /seen, shows the last login or logout
- /tempban, temporarily ban someone
- /tjail and mute, temporarily option added

Other changes:
- ban reason is saved
- don't show "You have xxx mail" on login, if user doesn't have essentials.mail permission
-  time will be parsed: years, months (mo), weeks, days, hours, minutes (m), seconds, these can be shortened and combined, example: 2 days 5h 30m

git-svn-id: https://svn.java.net/svn/essentials~svn/trunk@1300 e251c2fe-e539-e718-e476-b85c1f46cddb
2011-05-01 21:07:30 +00:00
snowleo
22f9b76d77 [trunk] empty fields in Inventory now return null instead of Material.AIR
git-svn-id: https://svn.java.net/svn/essentials~svn/trunk@1156 e251c2fe-e539-e718-e476-b85c1f46cddb
2011-04-08 11:43:10 +00:00
snowleo
7d0e9a26b0 [trunk] New /powertool command
git-svn-id: https://svn.java.net/svn/essentials~svn/trunk@1112 e251c2fe-e539-e718-e476-b85c1f46cddb
2011-04-04 01:26:45 +00:00