summaryrefslogtreecommitdiffstats
path: root/src/main/java/org
Commit message (Collapse)AuthorAgeLines
* Return correct hasLineOfSight value for players. Fixes BUKKIT-4634Roger Baumgartner2013-08-26-1/+1
| | | | | | | Prior to this change when a plugin called Player.hasLineOfSite() the method would always return false because EntityHuman does not extend EntityInsentient. This commit changes that by explicitly checking for line of sight between two entities and returning that value.
* Return instance of CraftInventoryBeacon for Beacons. Fixes BUKKIT-4521T00thpick12013-08-07-2/+2
|
* Fix missed diff for chat packets. Fixes BUKKIT-4666Wesley Wolfe2013-08-07-24/+0
| | | | | | | | This commit removes chat wrapping. It is no longer needed, as clients properly render lines with line breaks. This commit also changes an outgoing chat message to use the vanilla behavior for indicating a client cannot chat with commands-only setting.
* Wrap plugin.getDefaultWorldGenerator in try-catch. Fixes BUKKIT-4116riking2013-08-07-3/+7
| | | | | | If a plugin generates an exception when returning a world generator, the server will crash. This change adds a try-catch block to keep the server from crashing on plugin defined world generators.
* Validate title for custom inventories. Fixes BUKKIT-4616, BUKKIT-4663Wesley Wolfe2013-08-06-0/+3
| | | | | | | | | Custom inventories currently do not validate the titles provided. Null values cause NPEs when writing packets. Values longer than 32 characters disconnect clients. This change throws and IllegalArgumentException for null titles or titles longer than 32 characters.
* Fix off by 1 error for spawn protection. Fixes BUKKIT-4154Jonatan Noponen2013-08-03-1/+1
|
* Fix mistranslation in isPlayerCreated() for IronGolems. Fixes BUKKIT-4543Kai Dederichs2013-08-03-1/+1
|
* Implement Leash API. Adds BUKKIT-4459, BUKKIT-4583T00thpick12013-08-03-10/+89
|
* Ignore null sound by contract. Fixes BUKKIT-4641Wesley Wolfe2013-08-02-0/+3
|
* Indicate help is a command. Fixes BUKKIT-4642Wesley Wolfe2013-08-02-1/+5
|
* Add raw sound string playSound method. Adds BUKKIT-2443h31ix2013-08-02-1/+5
| | | | A method has been added to Player which allows the server to send a sound string to the client. Assuming the client has the specified sound, it will be played. This is needed by the implementation of the /playsound command.
* Fix NBT token for attribute names. Addresses BUKKIT-4483Wesley Wolfe2013-07-28-1/+7
|
* Store item attributes. Addresses BUKKIT-4523Wesley Wolfe2013-07-27-1/+89
|
* Add API to control scaled health. Adds BUKKIT-4590T00thpick12013-07-23-6/+61
| | | | | | | | | | | | | | | | | | | | | | | This commit implements the ability to set the scale of hearts that the client renders. When the Packet44UpdateAttributes packet is sent, the max health attribute is replaced with a scaled version, to preserve the scaled health illusion clientside. In order to accurately display the scaled health for players, a true health is stored within CraftPlayer, and the datawatcher now stores the scaled health. The getHealth() method for players still returns their true health. Changed setHealth() within EntityLiving to appropriately handle health for instances of EntityPlayer. Inlined a call to setHealth(getMaxHealth()) within the EntityLiving constructor to work around CraftEntity instantiation. Additionally fixes the health values sent when eating food within FoodMetaData and ItemFood, which previously sent the unscaled health; this commit alters them to send the properly scaled health. Additionally fixes BUKKIT-4535, BUKKIT-4536, and BUKKIT-4127
* Use ambient setting of potion effects. Fixes BUKKIT-4357 and BUKKIT-3653Jim Bilbrey2013-07-13-2/+2
| | | | | | | | | This changes livingEntity.addPotionEffect(PotionEffect, boolean) to construct the MobEffect using the constructor that includes the ambient setting as supplied by the PotionEffect This also changes livingEntity.getActivePotionEffects() to construct the PotionEffects using the ambient setting supplied by the MobEffects.
* Return inGround when checking Arrow's OnGround state. Fixes BUKKIT-4439EvilSeph2013-07-10-0/+3
|
* Implement Horse API. Adds BUKKIT-4424h31ix2013-07-10-33/+159
| | | | | | | | API has been added to interface with Horses and to modify their inventories. Horse entities will now be recognized with the type EntityType.HORSE, and will no longer be UNKNOWN. HorseJumpEvent, EntityDamageEvent, and EntityTameEvent are all correctly fired for horses. This commit fixes BUKKIT-4393.
* Update CraftBukkit to 1.6.2mbax2013-07-08-1/+7
|
* Properly clear attributes on remove and death. Fixes BUKKIT-4416EvilSeph2013-07-03-6/+1
|
* Fix scaling for player health. Fixes BUKKIT-4431Wesley Wolfe2013-07-02-0/+13
|
* Rework max health values. Fixes BUKKIT-4398Wesley Wolfe2013-07-02-2/+3
|
* Update CraftBukkit to 1.6.1Nate Mortensen2013-07-01-57/+214
|
* Implement PlayerBookEditEvent. Adds BUKKIT-1995Des Herriott2013-06-10-2/+28
|
* Update blaze breathe sound. Fixes BUKKIT-4286mbax2013-06-05-1/+1
|
* Send block updates even when applyPhysics is false. Fixes BUKKIT-3971Des Herriott2013-05-02-3/+3
| | | | | | The CraftBlock class is setting bit 0x4 of the update flag when bit 0x2 should in fact be set here. Bit 0x2 means "do updates"; bit 0x4 means "don't do updates if the world is static, even when bit 0x2 is set".
* Improve InventoryCloseEvent handling. Fixes BUKKIT-3286Travis Watkins2013-05-02-0/+7
| | | | | | | | | | Currently there are several cases where a player will have their inventory screen closed client side but we will not call an event. To correct this we call the event when the server is the cause of the inventory closing instead of just when the client is the cause. We also ensure the server is closing the inventory reliably so we get the events. Additionally this commit also calls the event when a player disconnects which will handle kicks, quits, and server shutdown.
* Move world generator warning to CraftBukkit. Fixes BUKKIT-2565Score_Under2013-04-30-1/+4
|
* Update CraftBukkit to Minecraft 1.5.2Travis Watkins2013-04-27-14/+18
|
* Rework EntityExplodeEvent. Fixes BUKKIT-4140. Adds BUKKIT-4141Wesley Wolfe2013-04-24-17/+0
|
* Check connection status before setting scoreboard. Fixes BUKKIT-4064Wesley Wolfe2013-04-12-0/+8
| | | | | | | | | Two connection status checks were added to setting a scoreboard for a player. The first checks to see if a player has logged in yet, which implicates the ability to receive packets. The second checks to affirm that the CraftPlayer reference is still to a logged in player; setting it while not logged in would maintain a stale player reference in the scoreboard manager.
* Use correct method for getting player's team. Fixes BUKKIT-4050Wesley Wolfe2013-04-11-1/+1
| | | | | | | The method getTeam gets the team from name of, as opposed to getting the team a player belongs to. This also addresses BUKKIT-4002 and partially BUKKIT-4044
* Refactor EntityDamageEvents. Adds BUKKIT-1944 & BUKKIT-3684feildmaster2013-04-10-12/+85
|
* Make auxiliary worlds use the main scoreboard. Addresses BUKKIT-3984Wesley Wolfe2013-04-04-1/+2
| | | | | | | | | | | When a world is created using our API, it does not use secondary world server and will maintain a reference to its own scoreboard. In vanilla, this is not an issue as there is only ever one world. Similarly to maps, an overwrite to the scoreboard reference has been added for when another world has been created. This should also address BUKKIT-3982 and BUKKIT-3985
* We compile for 1.5Wesley Wolfe2013-04-04-3/+0
|
* Implement Scoreboard API. Adds BUKKIT-3776mbax2013-04-04-3/+697
| | | | | | | | | | | | | | | | | | This implementation facilitates the correspondence of the Bukkit Scoreboard API to the internal minecraft implementation. When the first scoreboard is loaded, the scoreboard manager will be created. It uses the newly added WeakCollection for handling plugin scoreboard references to update the respective objectives. When a scoreboard contains no more active references, it should be garbage collected. An active reference can be held by a still registered objective, team, and transitively a score for a still registered objective. An internal reference will also be kept if a player's specific scoreboard has been set, and will remain persistent until that player logs out. A player's specific scoreboard becomes the scoreboard used when determining team structure for the player's attacking damage and the player's vision.
* Add a WeakCollection utility class.Wesley Wolfe2013-04-04-0/+173
| | | | | | | | | | This class is designed to be an invisible layer between a normal collection, and one that silently loses entries because they are only weakly referencable. Some operations have additional overhead to be semantically correct, but it maintains the equals contract for all entries, as opposed to identity. It does not support the equals or hash code method as it cannot easily have the transitive and commutative properties.
* Properly return contents of Inventory. Fixes BUKKIT-3930h31ix2013-04-02-1/+2
| | | | | | When an array of an inventory's contents is requested, we loop through the contents of the NMS inventory's ItemStacks in order to return Bukkit ItemStacks that can be used through the API. However, the NMS ItemStack can, in some cases, be larger than the physical size of the inventory. Using the size of the NMS array as a limit on the loop that follows can result in an ArrayIndexOutOfBoundsException because the Bukkit array's length is the actual size of the inventory, and thus will be smaller. With this commit we use the smaller of the two arrays' length as the limit in the loop, thus eliminating the possibility that the smaller array will be asked for an index higher than its length.
* Don't update physics when block place is cancelled. Fixes BUKKIT-3939Travis Watkins2013-03-31-23/+27
| | | | | | | | | When a block placement happens we currently update physics on the attempted placement and update again if the placement is cancelled. To correct the first one we simply set the block without applying physics. To correct the second we have to add a new method to BlockState that lets us update without applying physics and use this method method when putting the block back.
* Correct slot types for brewing stand. Fixes BUKKIT-3937Travis Watkins2013-03-31-1/+1
|
* Throw exception for disabled plugin tasks. Fixes BUKKIT-3951Wesley Wolfe2013-03-31-0/+4
| | | | | | | | | | | Without this check, any non-null reference to a plugin is considered 'valid' for registering a task in the scheduler. This is obviously unintentional behavior and has been changed to throw an IllegalPluginAccessException. It is now consistent with the SimplePluginManager event registration contract. This in affect also addresses BUKKIT-3950 for uninitialized plugin references (ones without a description).
* Include anvil result in inventory size. Fixes BUKKIT-3741Travis Watkins2013-03-30-2/+18
|
* Add Beacon block state for hopper events. Fixes BUKKIT-3932Travis Watkins2013-03-29-0/+39
|
* Properly copy collection references in ItemMeta.clone(). Fixes BUKKIT-3913Wesley Wolfe2013-03-28-5/+12
| | | | | | | | | | | | When cloning an item, all references are copied to the new item. For collections, this makes internal changes become visible in both the old and new items. In CraftMetaItem, clone was not making copies of the appropriate collections and has been fixed for non-null values. In CraftMetaEnchantedBook and CraftMetaPotion, clone was using possible empty collection references and has been changed to explicitly null-check instead.
* Improve calling of ProjectileHitEvent. Fixes BUKKIT-3872Andre LeBlanc2013-03-26-0/+6
|
* Allow fishing success rate to be adjustable. Adds BUKKIT-3837Andre LeBlanc2013-03-25-0/+21
|
* Add methods to check conflicting enchantments. Adds BUKKIT-3830GJ2013-03-25-0/+22
|
* Cleanup comments, formatting, etcTravis Watkins2013-03-25-139/+111
|
* Add ability to change player item in hand. Adds BUKKIT-3318Patrick Seidel2013-03-24-0/+9
|
* Add check for Thorns damage - Fixes BUKKIT-3505riking2013-03-23-0/+2
|
* Include ThrownPotion in spawn methods. Adds BUKKIT-2542Carlos Cobo2013-03-23-0/+9
|