-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
a411153
commit 2047e4e
Showing
14 changed files
with
158 additions
and
28 deletions.
There are no files selected for viewing
20 changes: 20 additions & 0 deletions
20
src/generated/resources/assets/kasuga_lib/blockstates/test/rotation_test.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
{ | ||
"variants": { | ||
"facing=north": { | ||
"model": "kasuga_lib:block/test/test_model_complicate" | ||
}, | ||
"facing=south": { | ||
"model": "kasuga_lib:block/test/test_model_complicate", | ||
"y": 180 | ||
}, | ||
"facing=east": { | ||
"model": "kasuga_lib:block/test/test_model_complicate", | ||
"y": 270 | ||
}, | ||
"facing=west": { | ||
"model": "kasuga_lib:block/test/test_model_complicate", | ||
"y": 90 | ||
} | ||
}, | ||
"model": "kasuga_lib:block/test/rotation_test_model" | ||
} |
71 changes: 71 additions & 0 deletions
71
src/generated/resources/assets/kasuga_lib/models/block/test/rotation_test_model.geo.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
{ | ||
"format_version": "1.12.0", | ||
"minecraft:geometry": [ | ||
{ | ||
"description": { | ||
"identifier": "geometry.unknown", | ||
"texture_width": 16, | ||
"texture_height": 16, | ||
"visible_bounds_width": 3, | ||
"visible_bounds_height": 1.5, | ||
"visible_bounds_offset": [0, 0.25, 0] | ||
}, | ||
"bones": [ | ||
{ | ||
"name": "bb_main", | ||
"pivot": [0, 0, 0], | ||
"cubes": [ | ||
{ | ||
"origin": [-1, 0, 6], | ||
"size": [2, 2, 2], | ||
"uv": { | ||
"north": {"uv": [0, 0], "uv_size": [2, 2]}, | ||
"east": {"uv": [0, 2], "uv_size": [2, 2]}, | ||
"south": {"uv": [2, 0], "uv_size": [2, 2]}, | ||
"west": {"uv": [2, 2], "uv_size": [2, 2]}, | ||
"up": {"uv": [0, 4], "uv_size": [2, 2]}, | ||
"down": {"uv": [4, 2], "uv_size": [2, -2]} | ||
} | ||
}, | ||
{ | ||
"origin": [-1, 0, -8], | ||
"size": [2, 2, 2], | ||
"uv": { | ||
"north": {"uv": [0, 0], "uv_size": [2, 2]}, | ||
"east": {"uv": [0, 2], "uv_size": [2, 2]}, | ||
"south": {"uv": [2, 0], "uv_size": [2, 2]}, | ||
"west": {"uv": [2, 2], "uv_size": [2, 2]}, | ||
"up": {"uv": [0, 4], "uv_size": [2, 2]}, | ||
"down": {"uv": [4, 2], "uv_size": [2, -2]} | ||
} | ||
}, | ||
{ | ||
"origin": [6, 0, -1], | ||
"size": [2, 2, 2], | ||
"uv": { | ||
"north": {"uv": [0, 0], "uv_size": [2, 2]}, | ||
"east": {"uv": [0, 2], "uv_size": [2, 2]}, | ||
"south": {"uv": [2, 0], "uv_size": [2, 2]}, | ||
"west": {"uv": [2, 2], "uv_size": [2, 2]}, | ||
"up": {"uv": [0, 4], "uv_size": [2, 2]}, | ||
"down": {"uv": [4, 2], "uv_size": [2, -2]} | ||
} | ||
}, | ||
{ | ||
"origin": [-8, 0, -1], | ||
"size": [2, 2, 2], | ||
"uv": { | ||
"north": {"uv": [0, 0], "uv_size": [2, 2]}, | ||
"east": {"uv": [0, 2], "uv_size": [2, 2]}, | ||
"south": {"uv": [2, 0], "uv_size": [2, 2]}, | ||
"west": {"uv": [2, 2], "uv_size": [2, 2]}, | ||
"up": {"uv": [0, 4], "uv_size": [2, 2]}, | ||
"down": {"uv": [4, 2], "uv_size": [2, -2]} | ||
} | ||
} | ||
] | ||
} | ||
] | ||
} | ||
] | ||
} |
7 changes: 7 additions & 0 deletions
7
src/generated/resources/assets/kasuga_lib/models/block/test/rotation_test_model.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"loader": "kasuga_lib:bedrock_model", | ||
"model": "kasuga_lib:block/test/rotation_test_model", | ||
"texture": "kasuga_lib:block/test/rotation_test_model", | ||
"identifier": "kasuga_lib:rotation_test_model", | ||
"render_type": "solid" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file added
BIN
+157 Bytes
...nerated/resources/assets/kasuga_lib/textures/block/test/rotation_test_model.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+91 Bytes
src/generated/resources/assets/kasuga_lib/textures/default/particle.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 30 additions & 0 deletions
30
src/main/java/kasuga/lib/example_env/block/RotationTestBlock.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
package kasuga.lib.example_env.block; | ||
|
||
import com.sk89q.worldedit.registry.state.EnumProperty; | ||
import net.minecraft.core.BlockPos; | ||
import net.minecraft.core.Direction; | ||
import net.minecraft.world.item.context.BlockPlaceContext; | ||
import net.minecraft.world.level.Level; | ||
import net.minecraft.world.level.block.Block; | ||
import net.minecraft.world.level.block.DirectionalBlock; | ||
import net.minecraft.world.level.block.state.BlockState; | ||
import net.minecraft.world.level.block.state.StateDefinition; | ||
import org.jetbrains.annotations.Nullable; | ||
|
||
public class RotationTestBlock extends DirectionalBlock { | ||
|
||
public RotationTestBlock(Properties pProperties) { | ||
super(pProperties); | ||
this.stateDefinition.any().setValue(FACING, Direction.NORTH); | ||
} | ||
|
||
@Override | ||
protected void createBlockStateDefinition(StateDefinition.Builder<Block, BlockState> pBuilder) { | ||
super.createBlockStateDefinition(pBuilder.add(FACING)); | ||
} | ||
|
||
@Override | ||
public @Nullable BlockState getStateForPlacement(BlockPlaceContext pContext) { | ||
return super.getStateForPlacement(pContext).setValue(FACING, pContext.getHorizontalDirection().getOpposite()); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters