Skip to content

Commit

Permalink
made palm models be BoP's palm models
Browse files Browse the repository at this point in the history
  • Loading branch information
supermassimo committed Jun 3, 2021
1 parent 9c6762a commit 3f8fd32
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 16 deletions.
2 changes: 1 addition & 1 deletion src/main/java/therealeststu/dtbop/DTBOPRegistries.java
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public static void registerSpecies (final com.ferreusveritas.dynamictrees.api.re
@SubscribeEvent
public static void onBlocksRegistry(final RegistryEvent.Register<Block> event) {
Bush.INSTANCES.forEach((Bush::setup));

DirtHelper.registerSoil(BOPBlocks.origin_grass_block, DirtHelper.DIRT_LIKE);
DirtHelper.registerSoil(BOPBlocks.white_sand, DirtHelper.SAND_LIKE);
DirtHelper.registerSoil(BOPBlocks.orange_sand, DirtHelper.SAND_LIKE);
Expand Down
20 changes: 6 additions & 14 deletions src/main/java/therealeststu/dtbop/models/PalmLeavesBakedModel.java
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public void setupModels (){
new BlockVertexData(0, 1, 3, 15, 0)
};

for (int pass = 0; pass < 4; pass++) {
for (int pass = 0; pass < 3; pass++) {
for (int half = 0; half < 2; half++) {

BlockVertexData[] outData = new BlockVertexData[8];
Expand Down Expand Up @@ -86,16 +86,13 @@ public void setupModels (){
angle = Math.atan2(y, z);
switch (pass){
case 0:
mult = -0.29;
mult = -0.17;
break;
case 1:
mult = -0.06;
mult = 0.06;
break;
case 2:
mult = 0.16;
break;
case 3:
mult = 0.32;
mult = 0.28;
break;
default:
mult = 0;
Expand All @@ -111,7 +108,6 @@ public void setupModels (){
angle = Math.atan2(x, z);
switch (pass){
default:
case 3:
case 0:
mult = 0;
break;
Expand Down Expand Up @@ -140,8 +136,6 @@ public void setupModels (){
default:
y += 0;
}
//y -= 0.25f;


// Move to center of palm crown
x += surr.getOffset().getX();
Expand All @@ -158,8 +152,7 @@ public void setupModels (){
outData[3].toInts(frondsTexture)
);
builder.addUnculledFace(new BakedQuad(vertices,
0, FaceBakery.calculateFacing(vertices), frondsTexture, false)
);
0, FaceBakery.calculateFacing(vertices), frondsTexture, false));

vertices = Ints.concat(
outData[4].toInts(frondsTexture),
Expand All @@ -168,8 +161,7 @@ public void setupModels (){
outData[7].toInts(frondsTexture)
);
builder.addUnculledFace(new BakedQuad(vertices,
0, FaceBakery.calculateFacing(vertices), frondsTexture, false)
);
0, FaceBakery.calculateFacing(vertices), frondsTexture, false));


bakedFronds[surr.ordinal()] = builder.build();
Expand Down
Binary file modified src/main/resources/assets/dtbop/textures/block/palm_frond.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/main/resources/trees/dtbop/world_gen/default.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
}
},
"density": [ 5 ],
"chance": 0.8,
"chance": 1.0,
"forestness" : 0.5
}
}
Expand Down

0 comments on commit 3f8fd32

Please sign in to comment.