Add Assets
This commit is contained in:
314
assets/Enderman/Enderman.blockymodel
Normal file
314
assets/Enderman/Enderman.blockymodel
Normal file
@@ -0,0 +1,314 @@
|
|||||||
|
{
|
||||||
|
"nodes": [
|
||||||
|
{
|
||||||
|
"id": "1",
|
||||||
|
"name": "legright",
|
||||||
|
"position": {"x": -16, "y": 62, "z": 0},
|
||||||
|
"orientation": {"x": 0, "y": 0, "z": 0, "w": 1},
|
||||||
|
"shape": {
|
||||||
|
"type": "box",
|
||||||
|
"offset": {"x": 8, "y": -28.19108, "z": 5.29767},
|
||||||
|
"stretch": {"x": 1, "y": 1, "z": 1},
|
||||||
|
"settings": {
|
||||||
|
"isPiece": false,
|
||||||
|
"size": {"x": 6, "y": 66, "z": 9}
|
||||||
|
},
|
||||||
|
"textureLayout": {
|
||||||
|
"back": {
|
||||||
|
"offset": {"x": 18, "y": 103},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"right": {
|
||||||
|
"offset": {"x": 76, "y": 77},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"front": {
|
||||||
|
"offset": {"x": 24, "y": 103},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"left": {
|
||||||
|
"offset": {"x": 85, "y": 26},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"top": {
|
||||||
|
"offset": {"x": 72, "y": 35},
|
||||||
|
"mirror": {"x": true, "y": true},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"bottom": {
|
||||||
|
"offset": {"x": 72, "y": 35},
|
||||||
|
"mirror": {"x": true, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"unwrapMode": "custom",
|
||||||
|
"visible": true,
|
||||||
|
"doubleSided": false,
|
||||||
|
"shadingMode": "flat"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "2",
|
||||||
|
"name": "cube",
|
||||||
|
"position": {"x": 0, "y": 82, "z": 5},
|
||||||
|
"orientation": {"x": 0, "y": 0, "z": 0, "w": 1},
|
||||||
|
"shape": {
|
||||||
|
"type": "box",
|
||||||
|
"offset": {"x": -0.5, "y": 0.5, "z": 0},
|
||||||
|
"stretch": {"x": 1, "y": 1, "z": 1},
|
||||||
|
"settings": {
|
||||||
|
"isPiece": false,
|
||||||
|
"size": {"x": 33, "y": 51, "z": 12},
|
||||||
|
"isStaticBox": true
|
||||||
|
},
|
||||||
|
"textureLayout": {
|
||||||
|
"back": {
|
||||||
|
"offset": {"x": 0, "y": 0},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"right": {
|
||||||
|
"offset": {"x": 52, "y": 77},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"front": {
|
||||||
|
"offset": {"x": 33, "y": 0},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"left": {
|
||||||
|
"offset": {"x": 64, "y": 77},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"top": {
|
||||||
|
"offset": {"x": 136, "y": 78},
|
||||||
|
"mirror": {"x": true, "y": true},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"bottom": {
|
||||||
|
"offset": {"x": 136, "y": 78},
|
||||||
|
"mirror": {"x": true, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"unwrapMode": "custom",
|
||||||
|
"visible": true,
|
||||||
|
"doubleSided": false,
|
||||||
|
"shadingMode": "flat"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "3",
|
||||||
|
"name": "cube",
|
||||||
|
"position": {"x": 0, "y": 124, "z": -8},
|
||||||
|
"orientation": {"x": 0, "y": 0, "z": 0, "w": 1},
|
||||||
|
"shape": {
|
||||||
|
"type": "box",
|
||||||
|
"offset": {"x": -1, "y": -3, "z": 12},
|
||||||
|
"stretch": {"x": 1, "y": 1, "z": 1},
|
||||||
|
"settings": {
|
||||||
|
"isPiece": false,
|
||||||
|
"size": {"x": 28, "y": 26, "z": 26},
|
||||||
|
"isStaticBox": true
|
||||||
|
},
|
||||||
|
"textureLayout": {
|
||||||
|
"back": {
|
||||||
|
"offset": {"x": 0, "y": 51},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"right": {
|
||||||
|
"offset": {"x": 0, "y": 77},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"front": {
|
||||||
|
"offset": {"x": 28, "y": 51},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"left": {
|
||||||
|
"offset": {"x": 26, "y": 77},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"top": {
|
||||||
|
"offset": {"x": 84, "y": 77},
|
||||||
|
"mirror": {"x": true, "y": true},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"bottom": {
|
||||||
|
"offset": {"x": 94, "y": 0},
|
||||||
|
"mirror": {"x": true, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"unwrapMode": "custom",
|
||||||
|
"visible": true,
|
||||||
|
"doubleSided": false,
|
||||||
|
"shadingMode": "flat"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "4",
|
||||||
|
"name": "armright",
|
||||||
|
"position": {"x": 0, "y": 102, "z": 0},
|
||||||
|
"orientation": {"x": 0, "y": 0, "z": 0, "w": 1},
|
||||||
|
"shape": {
|
||||||
|
"type": "box",
|
||||||
|
"offset": {"x": -20, "y": -27, "z": 4.5},
|
||||||
|
"stretch": {"x": 1, "y": 1, "z": 1},
|
||||||
|
"settings": {
|
||||||
|
"isPiece": false,
|
||||||
|
"size": {"x": 6, "y": 66, "z": 9}
|
||||||
|
},
|
||||||
|
"textureLayout": {
|
||||||
|
"back": {
|
||||||
|
"offset": {"x": 109, "y": 90},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"right": {
|
||||||
|
"offset": {"x": 103, "y": 0},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"front": {
|
||||||
|
"offset": {"x": 112, "y": 0},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"left": {
|
||||||
|
"offset": {"x": 9, "y": 103},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"top": {
|
||||||
|
"offset": {"x": 121, "y": 99},
|
||||||
|
"mirror": {"x": true, "y": true},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"bottom": {
|
||||||
|
"offset": {"x": 121, "y": 99},
|
||||||
|
"mirror": {"x": true, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"unwrapMode": "custom",
|
||||||
|
"visible": true,
|
||||||
|
"doubleSided": false,
|
||||||
|
"shadingMode": "flat"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "5",
|
||||||
|
"name": "armleft",
|
||||||
|
"position": {"x": 0, "y": 104, "z": 0},
|
||||||
|
"orientation": {"x": 0, "y": 0, "z": 0, "w": 1},
|
||||||
|
"shape": {
|
||||||
|
"type": "box",
|
||||||
|
"offset": {"x": 19, "y": -29, "z": 4.5},
|
||||||
|
"stretch": {"x": 1, "y": 1, "z": 1},
|
||||||
|
"settings": {
|
||||||
|
"isPiece": false,
|
||||||
|
"size": {"x": 6, "y": 66, "z": 9}
|
||||||
|
},
|
||||||
|
"textureLayout": {
|
||||||
|
"back": {
|
||||||
|
"offset": {"x": 42, "y": 103},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"right": {
|
||||||
|
"offset": {"x": 94, "y": 66},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"front": {
|
||||||
|
"offset": {"x": 103, "y": 90},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"left": {
|
||||||
|
"offset": {"x": 0, "y": 103},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"top": {
|
||||||
|
"offset": {"x": 84, "y": 35},
|
||||||
|
"mirror": {"x": true, "y": true},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"bottom": {
|
||||||
|
"offset": {"x": 84, "y": 35},
|
||||||
|
"mirror": {"x": true, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"unwrapMode": "custom",
|
||||||
|
"visible": true,
|
||||||
|
"doubleSided": false,
|
||||||
|
"shadingMode": "flat"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "6",
|
||||||
|
"name": "legleft",
|
||||||
|
"position": {"x": 0, "y": 63, "z": 0},
|
||||||
|
"orientation": {"x": 0, "y": 0, "z": 0, "w": 1},
|
||||||
|
"shape": {
|
||||||
|
"type": "box",
|
||||||
|
"offset": {"x": 8, "y": -30, "z": 4.5},
|
||||||
|
"stretch": {"x": 1, "y": 1, "z": 1},
|
||||||
|
"settings": {
|
||||||
|
"isPiece": false,
|
||||||
|
"size": {"x": 6, "y": 66, "z": 9}
|
||||||
|
},
|
||||||
|
"textureLayout": {
|
||||||
|
"back": {
|
||||||
|
"offset": {"x": 30, "y": 103},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"right": {
|
||||||
|
"offset": {"x": 85, "y": 92},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"front": {
|
||||||
|
"offset": {"x": 36, "y": 103},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"left": {
|
||||||
|
"offset": {"x": 94, "y": 0},
|
||||||
|
"mirror": {"x": false, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"top": {
|
||||||
|
"offset": {"x": 78, "y": 35},
|
||||||
|
"mirror": {"x": true, "y": true},
|
||||||
|
"angle": 0
|
||||||
|
},
|
||||||
|
"bottom": {
|
||||||
|
"offset": {"x": 78, "y": 35},
|
||||||
|
"mirror": {"x": true, "y": false},
|
||||||
|
"angle": 0
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"unwrapMode": "custom",
|
||||||
|
"visible": true,
|
||||||
|
"doubleSided": false,
|
||||||
|
"shadingMode": "flat"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"format": "character",
|
||||||
|
"lod": "auto"
|
||||||
|
}
|
||||||
BIN
assets/Enderman/base.png
Normal file
BIN
assets/Enderman/base.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 3.0 KiB |
139
assets/Enderman/walk.blockyanim
Normal file
139
assets/Enderman/walk.blockyanim
Normal file
@@ -0,0 +1,139 @@
|
|||||||
|
{
|
||||||
|
"formatVersion": 1,
|
||||||
|
"duration": 60,
|
||||||
|
"holdLastKeyframe": false,
|
||||||
|
"nodeAnimations": {
|
||||||
|
"legright": {
|
||||||
|
"position": [],
|
||||||
|
"orientation": [
|
||||||
|
{
|
||||||
|
"time": 0,
|
||||||
|
"delta": {"x": 0, "y": 0, "z": 0, "w": 1},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"time": 15,
|
||||||
|
"delta": {"x": -0.21644, "y": 0, "z": 0, "w": 0.9763},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"time": 30,
|
||||||
|
"delta": {"x": 0, "y": 0, "z": 0, "w": 1},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"time": 45,
|
||||||
|
"delta": {"x": 0.21644, "y": 0, "z": 0, "w": 0.9763},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"time": 60,
|
||||||
|
"delta": {"x": 0, "y": 0, "z": 0, "w": 1},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"shapeStretch": [],
|
||||||
|
"shapeVisible": [],
|
||||||
|
"shapeUvOffset": []
|
||||||
|
},
|
||||||
|
"armright": {
|
||||||
|
"position": [],
|
||||||
|
"orientation": [
|
||||||
|
{
|
||||||
|
"time": 0,
|
||||||
|
"delta": {"x": 0, "y": 0, "z": 0, "w": 1},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"time": 15,
|
||||||
|
"delta": {"x": 0.21644, "y": 0, "z": 0, "w": 0.9763},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"time": 30,
|
||||||
|
"delta": {"x": 0, "y": 0, "z": 0, "w": 1},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"time": 45,
|
||||||
|
"delta": {"x": -0.21644, "y": 0, "z": 0, "w": 0.9763},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"time": 60,
|
||||||
|
"delta": {"x": 0, "y": 0, "z": 0, "w": 1},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"shapeStretch": [],
|
||||||
|
"shapeVisible": [],
|
||||||
|
"shapeUvOffset": []
|
||||||
|
},
|
||||||
|
"armleft": {
|
||||||
|
"position": [],
|
||||||
|
"orientation": [
|
||||||
|
{
|
||||||
|
"time": 0,
|
||||||
|
"delta": {"x": 0, "y": 0, "z": 0, "w": 1},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"time": 15,
|
||||||
|
"delta": {"x": -0.21644, "y": 0, "z": 0, "w": 0.9763},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"time": 30,
|
||||||
|
"delta": {"x": 0, "y": 0, "z": 0, "w": 1},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"time": 45,
|
||||||
|
"delta": {"x": 0.21644, "y": 0, "z": 0, "w": 0.9763},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"time": 60,
|
||||||
|
"delta": {"x": 0, "y": 0, "z": 0, "w": 1},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"shapeStretch": [],
|
||||||
|
"shapeVisible": [],
|
||||||
|
"shapeUvOffset": []
|
||||||
|
},
|
||||||
|
"legleft": {
|
||||||
|
"position": [],
|
||||||
|
"orientation": [
|
||||||
|
{
|
||||||
|
"time": 0,
|
||||||
|
"delta": {"x": 0, "y": 0, "z": 0, "w": 1},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"time": 15,
|
||||||
|
"delta": {"x": 0.21644, "y": 0, "z": 0, "w": 0.9763},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"time": 30,
|
||||||
|
"delta": {"x": 0, "y": 0, "z": 0, "w": 1},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"time": 45,
|
||||||
|
"delta": {"x": -0.21644, "y": 0, "z": 0, "w": 0.9763},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"time": 60,
|
||||||
|
"delta": {"x": 0, "y": 0, "z": 0, "w": 1},
|
||||||
|
"interpolationType": "linear"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"shapeStretch": [],
|
||||||
|
"shapeVisible": [],
|
||||||
|
"shapeUvOffset": []
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -29,11 +29,11 @@ public class AddEndermanTeleportComponentTickSystem extends EntityTickingSystem<
|
|||||||
assert displayNameComponent != null;
|
assert displayNameComponent != null;
|
||||||
assert displayNameComponent.getDisplayName() != null;
|
assert displayNameComponent.getDisplayName() != null;
|
||||||
var displayName = displayNameComponent.getDisplayName().getAnsiMessage();
|
var displayName = displayNameComponent.getDisplayName().getAnsiMessage();
|
||||||
if (!"Bunny".equals(displayName)){
|
if (!"Enderman".equals(displayName)){
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
commandBuffer.addComponent(ref, endermanComponentType, new EndermanTeleportComponent());
|
commandBuffer.addComponent(ref, endermanComponentType, new EndermanTeleportComponent());
|
||||||
HytaleLogger.getLogger().atInfo().log("Added Component to ref: " + displayName);
|
// HytaleLogger.getLogger().atInfo().log("Added Component to ref: " + displayName);
|
||||||
}
|
}
|
||||||
|
|
||||||
@NullableDecl
|
@NullableDecl
|
||||||
|
|||||||
@@ -27,10 +27,13 @@ public class DamageEventSystem extends EntityEventSystem<EntityStore, Damage> {
|
|||||||
@NonNullDecl CommandBuffer<EntityStore> commandBuffer,
|
@NonNullDecl CommandBuffer<EntityStore> commandBuffer,
|
||||||
@NonNullDecl Damage damage) {
|
@NonNullDecl Damage damage) {
|
||||||
Ref<EntityStore> ref = archetypeChunk.getReferenceTo(i);
|
Ref<EntityStore> ref = archetypeChunk.getReferenceTo(i);
|
||||||
TransformComponent transformComponent = store.getComponent(ref, TransformComponent.getComponentType());
|
var transformComponent = store.getComponent(ref, TransformComponent.getComponentType());
|
||||||
assert transformComponent != null;
|
assert transformComponent != null;
|
||||||
|
var endermanComponent = store.getComponent(ref, endermanTeleportComponentType);
|
||||||
|
assert endermanComponent != null;
|
||||||
|
|
||||||
if (Math.random() < 0.3) {
|
endermanComponent.resetElapsedTime();
|
||||||
|
if (Math.random() < 0.15) {
|
||||||
EndermanTeleport(ref,transformComponent.getPosition(),commandBuffer);
|
EndermanTeleport(ref,transformComponent.getPosition(),commandBuffer);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user