Bukkit/CraftBukkit — pull request #1322 by me4502 (2014-01-19 02:53:58+00:00)
Title: [B+C] Implements a new getTemperature(x,y,z) method, to allow for height to be included in calculations. Fixes BUKKIT-5315

The Issue:

Prior to mc 1.7, temperatures were constant across a biome. The old method of temperature detection knew this, and therefore only allowed checking the x and z coordinates. As of 1.7, the temperature varies based on the Y axis, and the bukkit API does not allow checking of this changed temperature.

Justification for this PR:

This PR allows for plugins to accurately grab the temperature information for a specific block.

PR Breakdown:

This PR adds a new getTemperature method with the y coordinate as an argument, deprecates the old method, and makes Block.getTemperature() use the new method.

Testing Results and Materials:

Using this simple plugin, "TempTest", https://dl.dropboxusercontent.com/u/20806998/TempTest.jar
I was able to check the temperature of different blocks by right clicking them. I tested this mainly by making it snow, then going up to a height where it was snowing and right clicking, versus the same column lower.

Relevant PR(s):

B-#### - https://github.com/Bukkit/Bukkit/pull/####
CB-#### - https://github.com/Bukkit/CraftBukkit/pull/####

JIRA Ticket:

BUKKIT-5315 - https://bukkit.atlassian.net/browse/BUKKIT-5315