Dylan K. Taylor
b480c63060
Fixed ItemFactory::fromString() meta handling bug introduced by 71c3c349766e348bf53a1beeefaf9a897bc0a954
2018-07-17 14:46:08 +01:00
Dylan K. Taylor
71c3c34976
ItemFactory: prepare for handling items with negative IDs
2018-07-16 13:24:12 +01:00
Dylan K. Taylor
16c253d7a9
Item: allow negative IDs
...
this will be needed in the future for extended blocks support.
2018-07-16 12:46:16 +01:00
Dylan K. Taylor
32574118ea
Implemented Mending enchantment ( #2257 )
2018-07-06 13:28:33 +01:00
Dylan K. Taylor
8c672cb7c8
Implemented Sharpness, Fire Aspect and Knockback enchantments
2018-06-24 12:13:54 +01:00
Dylan K. Taylor
97c267c70c
Implemented Punch enchantment
2018-06-23 17:40:01 +01:00
Dylan K. Taylor
85a3c0e7dc
Implemented Flame enchantment
2018-06-23 17:11:20 +01:00
Dylan K. Taylor
2f70a1eefb
Implemented Thorns enchantment ( #2258 )
...
This implementation is rough and can probably be improved to make it extendable, but this works for now and can be improved later.
2018-06-23 13:36:58 +01:00
Dylan K. Taylor
7ba6e92b6c
Merge branch 'release/3.0' into release/3.1
2018-06-23 13:04:05 +01:00
Dylan K. Taylor
1c0b49343c
Implemented Infinity enchantment ( #2259 )
2018-06-23 11:44:35 +01:00
Dylan K. Taylor
814a949580
Implemented Power enchantment
2018-06-23 11:39:39 +01:00
Dylan K. Taylor
056d24c67d
Add MUTTON as an ID constant
...
fixes crashdump #518862 - Unable to resolve "minecraft:mutton" to a valid item
PC refers to these as just mutton, but PE calls them muttonraw
2018-06-22 19:39:18 +01:00
Dylan K. Taylor
9f7f62e9e5
Don't use Config for builtin JSON resources
...
it doesn't make sense to use a config in these cases, and also it just hides problems when the files are missing.
2018-06-16 16:35:47 +01:00
Dylan K. Taylor
7b0ce16b12
Fixed buckets being able to delete any block
2018-06-13 17:05:51 +01:00
Dylan K. Taylor
2e9e44ba05
Moved JSON blobs to submodule
2018-06-12 18:49:18 +01:00
Dylan K. Taylor
3def3cd502
Item: use base64 instead of hex for json encoding NBT
2018-06-12 18:31:35 +01:00
Dylan K. Taylor
05af87e1d4
Strip empty lines at the end of classes
2018-06-11 13:19:23 +01:00
Dylan K. Taylor
e3d2fa10a5
Item: added count parameter to pop()
...
this allows popping an arbitrary number of items from the stack, instead of just 1.
2018-05-29 10:21:04 +01:00
Dylan K. Taylor
509e8c5f6d
ItemFactory: register some easy items
...
these are items that do nothing and/or are only used for crafting. As such they are simple to add.
Others will be added later on, but others require extra work and/or reverse engineering which I don't have time for now.
2018-05-23 19:48:30 +01:00
Dylan K. Taylor
263cd900a8
Enchantment: update item type flags
2018-05-23 17:39:52 +01:00
Dylan K. Taylor
164ce76ff5
Enchantment: apply typehints to PHP 7.2 standards
2018-05-23 17:28:40 +01:00
Dylan K. Taylor
fbf760bafe
Enchantment: implemented Vanishing
2018-05-23 17:23:56 +01:00
Dylan K. Taylor
2c1afe5f2c
ItemFactory: generate some TODOs
2018-05-23 13:42:19 +01:00
Dylan K. Taylor
b109b457dc
Item: added some new constants
2018-05-23 13:35:15 +01:00
Dylan K. Taylor
e12e2897bb
Enchantment: Add new constants
...
these aren't registered yet because they aren't implemented.
2018-05-23 12:34:58 +01:00
Dylan K. Taylor
8f41384923
Item: remove workaround for anvils
...
they removed this in the 1.2.13 release. now the metadata matches the block.
2018-05-23 11:43:55 +01:00
Dylan K. Taylor
acf29711c2
Implemented Totems, close #2198
...
Totem usage can be detected using the MODIFIER_TOTEM constant of EntityDamageEvent.
This does not currently support using the totem in the offhand because offhand is not implemented yet.
2018-05-23 10:06:35 +01:00
Dylan K. Taylor
8239c67b1a
Enchantment: split up primary and secondary flags
...
closes #1911
2018-05-12 11:20:27 +01:00
Dylan K. Taylor
083ac8a770
Clean up Tool garbage leftovers
...
these were intended to be removed long ago, but other things came up and durability handling still depended on them.
2018-05-11 09:23:51 +01:00
Dylan K. Taylor
b21572774a
Tool: cleanup durability handling, closes #379
...
long overdue... this isn't quite as extensible as the original api3/blocks system was, but this is primarily intended to replace Item->useOn(). If plugins want to use it it can be extended later on.
2018-05-10 19:48:51 +01:00
Dylan K. Taylor
3095eb544d
Item: removed isTool()
...
this should be replaced with `instanceof Tool`.
2018-05-01 20:05:53 +01:00
Dylan K. Taylor
0247dff909
Fixed mis-uses of Item->isTool()
...
this has been wrongly used to indicate a durable item, but not just tools are durable items.
2018-05-01 20:05:02 +01:00
Dylan K. Taylor
691df5c11d
FlintSteel: remove instanceof Solid check
...
This makes the behaviour match vanilla. This will now allow Fire block itself to handle deletion of itself when the area is not suitable (now that the logic is implemented in Fire for this).
This allows attempting to place in invalid conditions, which is as expected. This will produce the sound and flash as per vanilla, as the fire extinguishes itself.
2018-04-10 09:59:27 +01:00
Dylan K. Taylor
ac5a91b67e
Cleaned up bool comparison mess
2018-03-19 14:10:55 +00:00
Dylan K. Taylor
ba0a256834
SplashPotion: fix max stack size
2018-03-11 13:43:45 +00:00
Dylan K. Taylor
cd35bd6872
git diff-tree --check $(git hash-object -t tree /dev/null) HEAD
2018-03-11 10:31:25 +00:00
Dylan K. Taylor
606407933e
ProjectileItem: fixed error when projectile entity is null
2018-03-10 10:59:22 +00:00
Dylan K. Taylor
ad09e8c8d0
Implemented Bottle o' Enchanting
2018-03-10 10:53:03 +00:00
Dylan K. Taylor
9098502199
Item: added some foods, cleaned up Fish abomination
...
@PEMapModder GET A CLIENT ALREADY
2018-03-09 19:54:42 +00:00
Dylan K. Taylor
b130374e46
EnderPearl: fixed max stack size
2018-03-09 19:19:21 +00:00
Dylan K. Taylor
31106bc227
ItemFactory: Register Dragon's Breath item
...
this is only used for brewing, it doesn't need anything special.
2018-03-09 19:13:30 +00:00
Dylan K. Taylor
cc1a3d695f
Implemented basic Ender Pearls
...
this doesn't have full functionality yet (like spawning endermites) because some things aren't implemented yet.
2018-03-09 19:05:14 +00:00
Dylan K. Taylor
2f266a5922
Player: added a server-side forced cooldown mechanism
...
This is necessary because the stupid client constantly spams right-click actions if you carry on trying to eat/throw/whatever the item when cooldown is in effect. Therefore ender pearls would be fired like machine guns without these checks server side.
2018-03-09 14:45:01 +00:00
Dylan K. Taylor
e06b78b0ee
Implemented armor durability
2018-03-09 13:21:05 +00:00
Dylan K. Taylor
2e9bf7e93b
Implemented Splash Potions
2018-03-09 12:25:02 +00:00
Dylan K. Taylor
5059a92b91
Fixed bow and throwable sounds
2018-03-08 13:20:26 +00:00
Dylan K. Taylor
dc3bf8546e
Refactored effects handling, split up concerns of effect types and instances
...
Removed json insanity for effects
Split up effect types and effect instances
Saturation is an instant effect
2018-03-07 12:42:31 +00:00
Dylan K. Taylor
c7f8796136
Implemented Paintings ( #2073 )
...
This supports vanilla placement of paintings, with overlap and collision checking.
Paintings are removed when a block is placed inside them or if any of their supporting blocks are removed.
As per vanilla, a random painting is chosen from the largest subset that will fit into the given space.
2018-03-07 09:03:30 +00:00
Dylan K. Taylor
f0535df96d
Remove deprecated things
2018-02-27 11:59:16 +00:00
Dylan K. Taylor
da5febc34a
fix crash report 127835
2018-02-24 11:46:36 +00:00