| Commit message (Collapse) | Author | Age | Lines |
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
| |
If a custom TravelAgent is used and returns null for findOrCreate method
a NullPointerException will occur.
Conflicts:
src/main/java/net/minecraft/server/PlayerList.java
|
|
|
|
| |
Currently, CraftTravelAgent will call s() on the passed-in WorldServer in order to set DEFAULT. However, s() will always return null at this point, because WorldServer.P will still be null, as it is set after the constructor is called. Instead, we set CraftTravelAgent.DEFAULT to the instance that is being constructed.
|
|
|
|
|
|
| |
The entity id is a non-unique, non-persistent value, and will cause
entities to lose their respective meta data on chunk unloading, and
teleportation.
|
|
|
|
|
|
|
|
|
|
|
| |
Recent changes caused PlayerPortalEvent to suddenly return null
unexpectedly and could end up in NPEs resulting that did not before.
This commit addresses that situation by always ensuring a TravelAgent
instance is returned.
The TravelAgent for world 0 is returned arbitrarily in an effort to
compensate for plugins that are implementation dependent and expect some
form of a TravelAgent to be accessible in the event at all times.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Vanilla does not check for blocks in which the player could
suffocate when changing dimension, so portals will happily spawn
players in blocks when using a portal under certain
circumstances. However, we currently check for these instances
and move the player up until they will not suffocate. This means
that players can sometimes be taken to above the target portal,
making it seem as if a portal was not created. Instead, we now
disable this suffocation check when moveToWorld is called from
changeDimension, mirroring vanilla behavior more accurately.
|
| |
|
| |
|
| |
|
|
|
|
|
| |
Getting the bed spawn location is supposed to check if the bed is
valid, however, it currently did not do so.
|
| |
|
| |
|
|
|
|
|
|
|
| |
Due to the having to generate new logic to avoid using the customized
PlayerConnection.moveToWorld, entities returning from The End were not
properly calculating their exit target. This commit corrects that
logic.
|
| |
|
|
|
|
| |
Adds BUKKIT-3516
|
|
|
|
|
| |
Skulls don't normally get block data applied to them, so we shouldn't
apply it either.
|
|
|
|
|
|
|
|
|
|
| |
By having a single function to process BlockPlacement logic, we make
it so that there is consistent behavior throughout all BlockPlace
events. This should allow for easier troubleshooting and less diffs
in source.
This also fixes BUKKIT-3463 by including the correct coordinates that
were clicked to the event.
|
|
|
|
|
|
|
|
|
|
| |
Also fixes: BUKKIT-3477 and BUKKIT-3488
Minecraft likes to double check that tile entities get set after they
are placed, however we didn't set tile entities until after our event
was called. This caused the world to have multiple tile entities in a
single block location; to fix this we now set tile entities before
the event.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
When the skull BlockPlaceEvent was added it was made so the event
would be called after all the data has been set, however this is a
behavior change that is inconsistent with other BlockPlaceEvents.
Instead, if people wish to get the block data they should schedule
a task.
Relates to: BUKKIT-3438
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When either of those settings are false, the worlds are not loaded and
therefore will not be targeted for portal exits. Existing worlds are
iterated directly to avoid defaulting to the first world if a direct
dimension match is not found.
Plugins must also specify exit from custom Bukkit worlds to comply with
original commit: https://github.com/Bukkit/CraftBukkit/commit/2dc2af0
This commit introduces a constant to clarify the dependency on the
CraftBukkit implementation of custom worlds having a dimension offset.
|
| |
|
|
|
|
|
|
| |
By returning the following value (7) we remove the need to special
case pistons in any way (other than the original purpose of this
check, which is to ensure pistons have valid data)
|
|
|
|
|
|
|
| |
The previous logic was faulty since it lost the logic of "placing" the
block. It was also taking into account data that could have been
changed outside of the processing of this event, which is irrelevant
to the processing of this event.
|
|
|
|
|
|
|
|
| |
The javadocs state that a null may be used to remove the currently
playing sound, however this causes a NullPointerException.
It also doesn't process registering the record correctly, along with
processing non-valid items.
|
| |
|
| |
|
|
|
|
|
|
| |
Fixed the ItemMetaFireworkTest
Add set power unit tests for FireworkMeta
|
|
|
|
|
| |
This change allows plugins to add recipients to a PotionSplashEvent
when it would have otherwise had none.
|
| |
|
| |
|
|
|
|
|
|
| |
Vanilla does the initialize before spawning everywhere except in the
SpawnerCreature, our spawn event depends on this behavior to be
consistent.
|
|
|
|
| |
Original: Update mappings to correct 1.4.6 version.
|
| |
|
|
|
|
| |
Relates to: BUKKIT-3438
|
| |
|
|
|
|
| |
This test was missing from c056293b38cb9a1296937d91746b175252be044a
|
|
|
|
|
|
|
| |
By using return 0, we exit the loop prematurely preventing other
creature types from being spawned if one type is set to 0. By using
continue we move on to the other types and allow them to spawn
properly.
|
|
|
|
|
|
|
|
|
| |
Fixes BUKKIT-3408, BUKKIT-3190, BUKKIT-3191, BUKKIT-3407
These changes relate mostly to semantical changes for serialization
contract, exception of changing the map scaling value from byte to boolean,
what it should have been in the first place. Appropriate unit tests were
added for CraftMapMeta, as they were missing.
|
|
|
|
| |
The ItemDye color-int array uses dye data values, not wool.
|
|
|
|
|
| |
These two methods are now deprecated and replaced by the strictly
equivalent calls using wool data.
|
| |
|