Commit graph

76 commits

Author SHA1 Message Date
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
imDaniX
13f454a022
Properly escape pipe character on item lore (#2994)
Using negative lookbehind instead of negated characters set.

Fixes #2962, fixes #2984
2020-02-07 10:10:54 +00:00
Mark Vadeika
843ecb4a42 Escape pipe character on item lore (#2831)
I just adjusted the regex used to split the item lore into multiple lines in order to allow escaping of the pipe character using \|.

Fixes #2830.
2019-12-23 13:15:26 +00:00
md678685
219012bc35
Set item meta in setSkullOwner before returning
*Should* address #2765.
2019-08-28 15:26:23 +01:00
md678685
5f9eb22d23 Fix player head meta on versions below 1.13 2019-08-24 10:05:26 +01:00
Julian van Doorn
d107d00ac3 Fix spawning shields with enchantments (#2515) @Argetan
* Moved comment to newline for style consistency.
* Fixed issue 2507 by checking if an enchantment is being applied.
* Added a couple newlines for readability.
* Removed faulty ifs).
2019-05-12 13:50:35 +01:00
md678685
5922b85290 Move SHIELD to from MetaItemStack to MaterialUtil 2018-12-09 13:47:52 +00:00
md678685
1206178eca Use utility methods in MetaItemStack 2018-12-09 12:17:13 +00:00
md678685
d1d5ae814f Merge branch '2.x' into 1.13 2018-08-27 20:01:01 +01:00
Max Roncace
935b5cfe0f Fix unbreakable attribute for kits (#2071) @caseif
This PR fixes the `unbreakable` attribute on kit items. Previously, Essentials was exclusively using an internal Spigot method to set this on `ItemMeta` objects; however, this solution seems to be non-functional on more recent Spigot builds (1.12.2).

I have altered the `MetaItemStack#setUnbreakable` method to use the native Bukkit method, available for [some time now](https://hub.spigotmc.org/stash/projects/SPIGOT/repos/bukkit/commits/d986a3f), by default. Essentials will still use the old solution as a fallback in case of an older Bukkit version which does not have native support for the attribute.
2018-08-25 11:33:17 +01:00
md678685
1ddb1822ef Merge branch '2.x' into 1.13 2018-08-05 23:02:11 +01:00
Trent Hensler
09af6ad186 Don't add itemflags if none are present 2018-01-22 16:37:01 -08:00
Trent Hensler
ace361af60 Compile against 1.13 preview.
Still a lot of work to do. One thing to note is that I used LEGACY materials in a few spots where I didn't know what the new ones are as I'm not very familiar with the 1.13 update and what it changes.
2018-01-18 17:52:44 -08:00
Trent Hensler
377c716d52 Add itemflag support to kits. Resolves #795.
Syntax is "itemflags:HIDE_ATTRIBUTES,HIDE_ENCHANTS"
2018-01-18 00:26:40 -08:00
Trent Hensler
147c5e0ddf
Merge branch '2.x' into fix-metaitemstack-keyword-replacer 2018-01-16 15:11:05 -08:00
Ali Moghnieh
b6aea0a5f8
Fix splash potion support for /potion. Resolves #1166 2018-01-07 02:22:31 +00:00
Ali Moghnieh
f0bf359df3
Allow KeywordReplacer to input replacements with underscore spacers.
Resolves #1725 and provides a less breaking fix for #1722.

----

Revert "Consume everything after lore as lore in MetaItemStack. Fixes #1722."

This reverts commit 5fa2ce7d9e.
2018-01-07 01:22:42 +00:00
Ali Moghnieh
d16e67c51e
Remove debug message. 2017-12-22 20:01:58 +00:00
Ali Moghnieh
5fa2ce7d9e
Consume everything after lore as lore in MetaItemStack. Fixes #1722. 2017-12-22 19:50:33 +00:00
Ali Moghnieh
203d6561ac
Allow unbreakable to not take any arguments, defaulting to true. Fixes #377 2017-08-07 14:05:20 +01:00
Ali Moghnieh
5960f55339
Fix banner/shield deserializer with PatternType. 2016-07-26 22:03:33 +01:00
Ali Moghnieh
352c92b880
Implement Shield item serialization. 2016-07-25 12:06:24 +01:00
vemacs
65a2e942c4 Attempt fixing kit/createkit for splash potions in 1.9 2016-03-31 11:54:19 -06:00
vemacs
62c2c57d4d [Experimental] Support Unbreakable meta tag 2016-03-01 18:16:13 -07:00
AdamQpzm
dfdc6a52be Add fix for enchants & kits on 1.7 2016-02-06 11:24:36 +00:00
Matthew Steglinski
2175cb8a44 Group allowShortName check when checking if the short form version of 'splash' was used 2015-10-29 16:42:19 -04:00
Matthew Steglinski
607f1980a1 [Fix] Adds splash potion persistence when serializing items. Fixes #232 2015-10-28 10:59:11 -04:00
Ali Moghnieh
9805f3f4d1 Add support for HEX RGB values. 2015-10-08 19:33:14 +01:00
Ali Moghnieh
a721e04119 Add support for deserializing item color RGB values as integers. 2015-10-08 19:14:04 +01:00
vemacs
ff3b1e810f Fix MetaItemStack canSpawn() method to try it on a clone, readd check to /give and /i 2015-06-04 11:18:47 -06:00
drtshock
090e0b6757 Add banner meta. Resolves #8. 2015-04-20 18:09:52 -05:00
drtshock
dde0b20775 Reformat 2015-04-14 23:06:16 -05:00
KHobbits
3887fdd47d New permission: essentials.itemspawn.meta-vanilla
Without this permission you cannot use vanilla itemmeta.  You can still use essentials style meta, if you have the appropriate permissions.
2014-06-07 16:08:51 +01:00
KHobbits
1bb569fff2 Fix attempting to spawn invalid items. 2014-04-30 05:41:42 +01:00
FearFree
5724c0c8df Future Java versions may not support _ as identifier. 2014-03-22 16:08:11 +11:00
Iaccidentally
518650e842 Modifier order consistency 2014-02-04 11:11:43 -05:00
Chris Ward
9ce1158aeb Add support for vanilla JSON metadata syntax (/give, /i, /kit, etc.) 2014-01-21 00:54:48 +11:00
KHobbits
946051de71 Add support for adding item meta to [free] signs.
Fix NPE on [sign] creation.
2013-12-07 20:25:23 +00:00
Iaccidentally
3e725ef060 Cleanup various aspects of code, fix some formatting, more netbeans 7.4 stuff 2013-11-06 21:22:32 -05:00
Chris Ward
48261daf89 Fix null pointer exception on kits with meta 2013-10-19 12:19:39 +01:00
KHobbits
6f85761f7f Extract CommandSender to CommandSource, this should prevent Ess user object leaks. 2013-10-16 21:05:33 +01:00
KHobbits
59b501b2b1 Clean Imports 2013-10-11 03:44:41 +01:00
KHobbits
64743ef428 Add support for coloured authors on books
Fixes ESS-4690
2013-08-31 13:20:36 +01:00
Iaccidentally
dad348d3d0 [API] Move 2.x API to new package, create dummy classes for compatibility 2013-07-13 11:14:39 -04:00
Iaccidentally
f1eae9be6f Cleanup imports 2013-06-11 20:45:12 +01:00
KHobbits
09f67c9723 Split util classes. 2013-06-08 22:31:19 +01:00
GunfighterJ
fd0134227c Fix NPE on invalid enchant 2013-04-19 10:06:43 -05:00
KHobbits
656a40abb2 Remove duplicate perm. 2013-04-13 23:50:17 +01:00
GunfighterJ
ce51a07bf1 Potion erroring and duration/power fix 2013-03-18 06:14:44 +00:00
KHobbits
3ddf883d5d Import cleanup 2013-03-16 09:19:30 +00:00