MCPcopy Create free account
hub / github.com/BuildCraft/BuildCraft / readDoubleArray

Method readDoubleArray

common/buildcraft/lib/misc/NBTUtils.java:258–267  ·  view source on GitHub ↗
(NBTBase tag, int intendedLength)

Source from the content-addressed store, hash-verified

256 }
257
258 public static double[] readDoubleArray(NBTBase tag, int intendedLength) {
259 double[] arr = new double[intendedLength];
260 if (tag instanceof NBTTagList) {
261 NBTTagList list = (NBTTagList) tag;
262 for (int i = 0; i < list.tagCount() && i < intendedLength; i++) {
263 arr[i] = list.getDoubleAt(i);
264 }
265 }
266 return arr;
267 }
268
269 public static NBTTagCompound writeEntireBlockState(IBlockState state) {
270 if (state == null || state == Blocks.AIR.getDefaultState()) {

Callers 1

deserializeNBTMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected