MCPcopy Create free account
hub / github.com/Garten/sourcecraft / setAddable

Method setAddable

src/source/addable/AddableManager.java:101–108  ·  view source on GitHub ↗
(Addable addable)

Source from the content-addressed store, hash-verified

99 }
100
101 private void setAddable(Addable addable) {
102 addable.setAccess(this.cuboidFinder, this.map, this);
103 int[] materialsUsed = addable.getMaterialUsedFor();
104 for (int material : materialsUsed) {
105 // add all material that use addable
106 this.materialToAddable[material] = addable;
107 }
108 }
109
110 public Addable getAddable(int material) {
111 if (material >= 0 && material <= this.materialToAddable.length) {

Callers 1

setAddablesMethod · 0.95

Calls 2

getMaterialUsedForMethod · 0.80
setAccessMethod · 0.45

Tested by

no test coverage detected