(Block blockIn)
| 1061 | } |
| 1062 | |
| 1063 | public boolean canPlaceOn(Block blockIn) |
| 1064 | { |
| 1065 | if (blockIn == this.canPlaceOnCacheBlock) |
| 1066 | { |
| 1067 | return this.canPlaceOnCacheResult; |
| 1068 | } |
| 1069 | else |
| 1070 | { |
| 1071 | this.canPlaceOnCacheBlock = blockIn; |
| 1072 | |
| 1073 | if (this.hasTagCompound() && this.stackTagCompound.hasKey("CanPlaceOn", 9)) |
| 1074 | { |
| 1075 | NBTTagList nbttaglist = this.stackTagCompound.getTagList("CanPlaceOn", 8); |
| 1076 | |
| 1077 | for (int i = 0; i < nbttaglist.tagCount(); ++i) |
| 1078 | { |
| 1079 | Block block = Block.getBlockFromName(nbttaglist.getStringTagAt(i)); |
| 1080 | |
| 1081 | if (block == blockIn) |
| 1082 | { |
| 1083 | this.canPlaceOnCacheResult = true; |
| 1084 | return true; |
| 1085 | } |
| 1086 | } |
| 1087 | } |
| 1088 | |
| 1089 | this.canPlaceOnCacheResult = false; |
| 1090 | return false; |
| 1091 | } |
| 1092 | } |
| 1093 | } |
no test coverage detected