diff --git a/DuneRealmsGUI/ecology/models/jerboa.json b/DuneRealmsGUI/ecology/models/jerboa.json index 269c7025..2432b9db 100644 --- a/DuneRealmsGUI/ecology/models/jerboa.json +++ b/DuneRealmsGUI/ecology/models/jerboa.json @@ -1 +1 @@ -{"ambientocclusion":false,"textures":{"fur":"minecraft:block/brown_terracotta","belly":"minecraft:block/terracotta","nose":"minecraft:block/pink_terracotta","ear":"minecraft:block/pink_terracotta","eye":"minecraft:block/black_concrete","glint":"minecraft:block/white_concrete","tail":"minecraft:block/terracotta"},"elements":[{"from":[4,3,8],"to":[12,10,18],"faces":{"north":{"texture":"#fur","uv":[0,0,16,16]},"south":{"texture":"#fur","uv":[0,0,16,16]},"east":{"texture":"#fur","uv":[0,0,16,16]},"west":{"texture":"#fur","uv":[0,0,16,16]},"up":{"texture":"#fur","uv":[0,0,16,16]},"down":{"texture":"#fur","uv":[0,0,16,16]}}},{"from":[3,4,9],"to":[13,9,16],"faces":{"north":{"texture":"#fur","uv":[0,0,16,16]},"south":{"texture":"#fur","uv":[0,0,16,16]},"east":{"texture":"#fur","uv":[0,0,16,16]},"west":{"texture":"#fur","uv":[0,0,16,16]},"up":{"texture":"#fur","uv":[0,0,16,16]},"down":{"texture":"#fur","uv":[0,0,16,16]}}},{"from":[5,2.5,8],"to":[11,5,18],"faces":{"north":{"texture":"#belly","uv":[0,0,16,16]},"south":{"texture":"#belly","uv":[0,0,16,16]},"east":{"texture":"#belly","uv":[0,0,16,16]},"west":{"texture":"#belly","uv":[0,0,16,16]},"up":{"texture":"#belly","uv":[0,0,16,16]},"down":{"texture":"#belly","uv":[0,0,16,16]}}},{"from":[3.5,6,2],"to":[12.5,12,9],"faces":{"north":{"texture":"#fur","uv":[0,0,16,16]},"south":{"texture":"#fur","uv":[0,0,16,16]},"east":{"texture":"#fur","uv":[0,0,16,16]},"west":{"texture":"#fur","uv":[0,0,16,16]},"up":{"texture":"#fur","uv":[0,0,16,16]},"down":{"texture":"#fur","uv":[0,0,16,16]}}},{"from":[5,6,0],"to":[11,9,4],"faces":{"north":{"texture":"#belly","uv":[0,0,16,16]},"south":{"texture":"#belly","uv":[0,0,16,16]},"east":{"texture":"#belly","uv":[0,0,16,16]},"west":{"texture":"#belly","uv":[0,0,16,16]},"up":{"texture":"#belly","uv":[0,0,16,16]},"down":{"texture":"#belly","uv":[0,0,16,16]}}},{"from":[7,7,-0.5],"to":[9,8.5,1],"faces":{"north":{"texture":"#nose","uv":[0,0,16,16]},"south":{"texture":"#nose","uv":[0,0,16,16]},"east":{"texture":"#nose","uv":[0,0,16,16]},"west":{"texture":"#nose","uv":[0,0,16,16]},"up":{"texture":"#nose","uv":[0,0,16,16]},"down":{"texture":"#nose","uv":[0,0,16,16]}}},{"from":[3,11,4],"to":[6,16,6],"faces":{"north":{"texture":"#fur","uv":[0,0,16,16]},"south":{"texture":"#fur","uv":[0,0,16,16]},"east":{"texture":"#fur","uv":[0,0,16,16]},"west":{"texture":"#fur","uv":[0,0,16,16]},"up":{"texture":"#fur","uv":[0,0,16,16]},"down":{"texture":"#fur","uv":[0,0,16,16]}}},{"from":[10,11,4],"to":[13,16,6],"faces":{"north":{"texture":"#fur","uv":[0,0,16,16]},"south":{"texture":"#fur","uv":[0,0,16,16]},"east":{"texture":"#fur","uv":[0,0,16,16]},"west":{"texture":"#fur","uv":[0,0,16,16]},"up":{"texture":"#fur","uv":[0,0,16,16]},"down":{"texture":"#fur","uv":[0,0,16,16]}}},{"from":[3.5,12,3.8],"to":[5.5,15,4],"faces":{"north":{"texture":"#ear","uv":[0,0,16,16]},"south":{"texture":"#ear","uv":[0,0,16,16]},"east":{"texture":"#ear","uv":[0,0,16,16]},"west":{"texture":"#ear","uv":[0,0,16,16]},"up":{"texture":"#ear","uv":[0,0,16,16]},"down":{"texture":"#ear","uv":[0,0,16,16]}}},{"from":[10.5,12,3.8],"to":[12.5,15,4],"faces":{"north":{"texture":"#ear","uv":[0,0,16,16]},"south":{"texture":"#ear","uv":[0,0,16,16]},"east":{"texture":"#ear","uv":[0,0,16,16]},"west":{"texture":"#ear","uv":[0,0,16,16]},"up":{"texture":"#ear","uv":[0,0,16,16]},"down":{"texture":"#ear","uv":[0,0,16,16]}}},{"from":[3.3,9,2.5],"to":[4.1,11,4.5],"faces":{"north":{"texture":"#eye","uv":[0,0,16,16]},"south":{"texture":"#eye","uv":[0,0,16,16]},"east":{"texture":"#eye","uv":[0,0,16,16]},"west":{"texture":"#eye","uv":[0,0,16,16]},"up":{"texture":"#eye","uv":[0,0,16,16]},"down":{"texture":"#eye","uv":[0,0,16,16]}}},{"from":[11.9,9,2.5],"to":[12.7,11,4.5],"faces":{"north":{"texture":"#eye","uv":[0,0,16,16]},"south":{"texture":"#eye","uv":[0,0,16,16]},"east":{"texture":"#eye","uv":[0,0,16,16]},"west":{"texture":"#eye","uv":[0,0,16,16]},"up":{"texture":"#eye","uv":[0,0,16,16]},"down":{"texture":"#eye","uv":[0,0,16,16]}}},{"from":[3.2,10,2.2],"to":[4.2,10.8,2.6],"faces":{"north":{"texture":"#glint","uv":[0,0,16,16]},"south":{"texture":"#glint","uv":[0,0,16,16]},"east":{"texture":"#glint","uv":[0,0,16,16]},"west":{"texture":"#glint","uv":[0,0,16,16]},"up":{"texture":"#glint","uv":[0,0,16,16]},"down":{"texture":"#glint","uv":[0,0,16,16]}}},{"from":[11.8,10,2.2],"to":[12.8,10.8,2.6],"faces":{"north":{"texture":"#glint","uv":[0,0,16,16]},"south":{"texture":"#glint","uv":[0,0,16,16]},"east":{"texture":"#glint","uv":[0,0,16,16]},"west":{"texture":"#glint","uv":[0,0,16,16]},"up":{"texture":"#glint","uv":[0,0,16,16]},"down":{"texture":"#glint","uv":[0,0,16,16]}}},{"from":[3,1,12],"to":[6,5,18],"faces":{"north":{"texture":"#fur","uv":[0,0,16,16]},"south":{"texture":"#fur","uv":[0,0,16,16]},"east":{"texture":"#fur","uv":[0,0,16,16]},"west":{"texture":"#fur","uv":[0,0,16,16]},"up":{"texture":"#fur","uv":[0,0,16,16]},"down":{"texture":"#fur","uv":[0,0,16,16]}}},{"from":[10,1,12],"to":[13,5,18],"faces":{"north":{"texture":"#fur","uv":[0,0,16,16]},"south":{"texture":"#fur","uv":[0,0,16,16]},"east":{"texture":"#fur","uv":[0,0,16,16]},"west":{"texture":"#fur","uv":[0,0,16,16]},"up":{"texture":"#fur","uv":[0,0,16,16]},"down":{"texture":"#fur","uv":[0,0,16,16]}}},{"from":[2,0,8],"to":[6,1.5,17],"faces":{"north":{"texture":"#belly","uv":[0,0,16,16]},"south":{"texture":"#belly","uv":[0,0,16,16]},"east":{"texture":"#belly","uv":[0,0,16,16]},"west":{"texture":"#belly","uv":[0,0,16,16]},"up":{"texture":"#belly","uv":[0,0,16,16]},"down":{"texture":"#belly","uv":[0,0,16,16]}}},{"from":[10,0,8],"to":[14,1.5,17],"faces":{"north":{"texture":"#belly","uv":[0,0,16,16]},"south":{"texture":"#belly","uv":[0,0,16,16]},"east":{"texture":"#belly","uv":[0,0,16,16]},"west":{"texture":"#belly","uv":[0,0,16,16]},"up":{"texture":"#belly","uv":[0,0,16,16]},"down":{"texture":"#belly","uv":[0,0,16,16]}}},{"from":[4.5,0,4],"to":[6,6,7],"faces":{"north":{"texture":"#belly","uv":[0,0,16,16]},"south":{"texture":"#belly","uv":[0,0,16,16]},"east":{"texture":"#belly","uv":[0,0,16,16]},"west":{"texture":"#belly","uv":[0,0,16,16]},"up":{"texture":"#belly","uv":[0,0,16,16]},"down":{"texture":"#belly","uv":[0,0,16,16]}}},{"from":[10,0,4],"to":[11.5,6,7],"faces":{"north":{"texture":"#belly","uv":[0,0,16,16]},"south":{"texture":"#belly","uv":[0,0,16,16]},"east":{"texture":"#belly","uv":[0,0,16,16]},"west":{"texture":"#belly","uv":[0,0,16,16]},"up":{"texture":"#belly","uv":[0,0,16,16]},"down":{"texture":"#belly","uv":[0,0,16,16]}}},{"from":[7,3,17],"to":[9,4.5,24],"faces":{"north":{"texture":"#tail","uv":[0,0,16,16]},"south":{"texture":"#tail","uv":[0,0,16,16]},"east":{"texture":"#tail","uv":[0,0,16,16]},"west":{"texture":"#tail","uv":[0,0,16,16]},"up":{"texture":"#tail","uv":[0,0,16,16]},"down":{"texture":"#tail","uv":[0,0,16,16]}}},{"from":[8,3,23],"to":[10,4.5,28],"faces":{"north":{"texture":"#tail","uv":[0,0,16,16]},"south":{"texture":"#tail","uv":[0,0,16,16]},"east":{"texture":"#tail","uv":[0,0,16,16]},"west":{"texture":"#tail","uv":[0,0,16,16]},"up":{"texture":"#tail","uv":[0,0,16,16]},"down":{"texture":"#tail","uv":[0,0,16,16]}}},{"from":[9,3,27],"to":[12,5,31],"faces":{"north":{"texture":"#eye","uv":[0,0,16,16]},"south":{"texture":"#eye","uv":[0,0,16,16]},"east":{"texture":"#eye","uv":[0,0,16,16]},"west":{"texture":"#eye","uv":[0,0,16,16]},"up":{"texture":"#eye","uv":[0,0,16,16]},"down":{"texture":"#eye","uv":[0,0,16,16]}}}]} +{"ambientocclusion":false,"textures":{"fur":"dunerealms:entity/jerboa"},"elements":[{"from":[5.5,12,5.5],"to":[10.5,16,10.5],"faces":{"west":{"uv":[4.888888888888889,6.222222222222222,7.111111111111111,8],"texture":"#fur"},"north":{"uv":[7.111111111111111,6.222222222222222,9.333333333333334,8],"texture":"#fur"},"east":{"uv":[9.333333333333334,6.222222222222222,11.555555555555555,8],"texture":"#fur"},"south":{"uv":[11.555555555555555,6.222222222222222,13.777777777777779,8],"texture":"#fur"},"up":{"uv":[7.111111111111111,4,9.333333333333334,6.222222222222222],"texture":"#fur"},"down":{"uv":[9.333333333333334,4,11.555555555555555,6.222222222222222],"texture":"#fur"}}},{"from":[6.5,12,3.5],"to":[9.5,14,5.5],"faces":{"west":{"uv":[11.11111111111111,0.8888888888888888,12,1.7777777777777777],"texture":"#fur"},"north":{"uv":[12,0.8888888888888888,13.333333333333334,1.7777777777777777],"texture":"#fur"},"east":{"uv":[13.333333333333334,0.8888888888888888,14.222222222222221,1.7777777777777777],"texture":"#fur"},"south":{"uv":[14.222222222222221,0.8888888888888888,15.555555555555555,1.7777777777777777],"texture":"#fur"},"up":{"uv":[12,0,13.333333333333334,0.8888888888888888],"texture":"#fur"},"down":{"uv":[13.333333333333334,0,14.666666666666666,0.8888888888888888],"texture":"#fur"}}},{"from":[10.5,13,8.5],"to":[11.5,15,9.5],"faces":{"west":{"uv":[5.333333333333333,0.4444444444444444,5.777777777777778,1.3333333333333333],"texture":"#fur"},"north":{"uv":[5.777777777777778,0.4444444444444444,6.222222222222222,1.3333333333333333],"texture":"#fur"},"east":{"uv":[6.222222222222222,0.4444444444444444,6.666666666666667,1.3333333333333333],"texture":"#fur"},"south":{"uv":[6.666666666666667,0.4444444444444444,7.111111111111111,1.3333333333333333],"texture":"#fur"},"up":{"uv":[5.777777777777778,0,6.222222222222222,0.4444444444444444],"texture":"#fur"},"down":{"uv":[6.222222222222222,0,6.666666666666667,0.4444444444444444],"texture":"#fur"}}},{"from":[4.5,13,8.5],"to":[5.5,15,9.5],"faces":{"west":{"uv":[0,0.4444444444444444,0.4444444444444444,1.3333333333333333],"texture":"#fur"},"north":{"uv":[0.4444444444444444,0.4444444444444444,0.8888888888888888,1.3333333333333333],"texture":"#fur"},"east":{"uv":[0.8888888888888888,0.4444444444444444,1.3333333333333333,1.3333333333333333],"texture":"#fur"},"south":{"uv":[1.3333333333333333,0.4444444444444444,1.7777777777777777,1.3333333333333333],"texture":"#fur"},"up":{"uv":[0.4444444444444444,0,0.8888888888888888,0.4444444444444444],"texture":"#fur"},"down":{"uv":[0.8888888888888888,0,1.3333333333333333,0.4444444444444444],"texture":"#fur"}}},{"from":[6,2,6],"to":[10,12,10],"faces":{"west":{"uv":[0,1.7777777777777777,1.7777777777777777,6.222222222222222],"texture":"#fur"},"north":{"uv":[1.7777777777777777,1.7777777777777777,3.5555555555555554,6.222222222222222],"texture":"#fur"},"east":{"uv":[3.5555555555555554,1.7777777777777777,5.333333333333333,6.222222222222222],"texture":"#fur"},"south":{"uv":[5.333333333333333,1.7777777777777777,7.111111111111111,6.222222222222222],"texture":"#fur"},"up":{"uv":[1.7777777777777777,0,3.5555555555555554,1.7777777777777777],"texture":"#fur"},"down":{"uv":[3.5555555555555554,0,5.333333333333333,1.7777777777777777],"texture":"#fur"}}},{"from":[9,6,6],"to":[11,11,8],"faces":{"west":{"uv":[0,9.777777777777779,0.8888888888888888,12],"texture":"#fur"},"north":{"uv":[0.8888888888888888,9.777777777777779,1.7777777777777777,12],"texture":"#fur"},"east":{"uv":[1.7777777777777777,9.777777777777779,2.6666666666666665,12],"texture":"#fur"},"south":{"uv":[2.6666666666666665,9.777777777777779,3.5555555555555554,12],"texture":"#fur"},"up":{"uv":[0.8888888888888888,8.88888888888889,1.7777777777777777,9.777777777777779],"texture":"#fur"},"down":{"uv":[1.7777777777777777,8.88888888888889,2.6666666666666665,9.777777777777779],"texture":"#fur"}},"rotation":{"origin":[8.5,8.5,7.5],"axis":"x","angle":22.5}},{"from":[5,6,6],"to":[7,11,8],"faces":{"west":{"uv":[5.333333333333333,8.88888888888889,6.222222222222222,11.11111111111111],"texture":"#fur"},"north":{"uv":[6.222222222222222,8.88888888888889,7.111111111111111,11.11111111111111],"texture":"#fur"},"east":{"uv":[7.111111111111111,8.88888888888889,8,11.11111111111111],"texture":"#fur"},"south":{"uv":[8,8.88888888888889,8.88888888888889,11.11111111111111],"texture":"#fur"},"up":{"uv":[6.222222222222222,8,7.111111111111111,8.88888888888889],"texture":"#fur"},"down":{"uv":[7.111111111111111,8,8,8.88888888888889],"texture":"#fur"}},"rotation":{"origin":[5.5,8.5,7.5],"axis":"x","angle":22.5}},{"from":[9.5,1,7],"to":[10.5,5,9.5],"faces":{"west":{"uv":[2.2222222222222223,11.777777777777779,3.3333333333333335,13.555555555555555],"texture":"#fur"},"north":{"uv":[3.3333333333333335,11.777777777777779,3.7777777777777777,13.555555555555555],"texture":"#fur"},"east":{"uv":[3.7777777777777777,11.777777777777779,4.888888888888889,13.555555555555555],"texture":"#fur"},"south":{"uv":[4.888888888888889,11.777777777777779,5.333333333333333,13.555555555555555],"texture":"#fur"},"up":{"uv":[3.3333333333333335,10.666666666666666,3.7777777777777777,11.777777777777779],"texture":"#fur"},"down":{"uv":[3.7777777777777777,10.666666666666666,4.222222222222222,11.777777777777779],"texture":"#fur"}}},{"from":[8.5,0,5],"to":[10.5,1,10],"faces":{"west":{"uv":[7.111111111111111,2.2222222222222223,9.333333333333334,2.6666666666666665],"texture":"#fur"},"north":{"uv":[9.333333333333334,2.2222222222222223,10.222222222222221,2.6666666666666665],"texture":"#fur"},"east":{"uv":[10.222222222222221,2.2222222222222223,12.444444444444445,2.6666666666666665],"texture":"#fur"},"south":{"uv":[12.444444444444445,2.2222222222222223,13.333333333333334,2.6666666666666665],"texture":"#fur"},"up":{"uv":[9.333333333333334,0,10.222222222222221,2.2222222222222223],"texture":"#fur"},"down":{"uv":[10.222222222222221,0,11.11111111111111,2.2222222222222223],"texture":"#fur"}}},{"from":[5.5,0,5],"to":[7.5,1,10],"faces":{"west":{"uv":[0,8.444444444444445,2.2222222222222223,8.88888888888889],"texture":"#fur"},"north":{"uv":[2.2222222222222223,8.444444444444445,3.111111111111111,8.88888888888889],"texture":"#fur"},"east":{"uv":[3.111111111111111,8.444444444444445,5.333333333333333,8.88888888888889],"texture":"#fur"},"south":{"uv":[5.333333333333333,8.444444444444445,6.222222222222222,8.88888888888889],"texture":"#fur"},"up":{"uv":[2.2222222222222223,6.222222222222222,3.111111111111111,8.444444444444445],"texture":"#fur"},"down":{"uv":[3.111111111111111,6.222222222222222,4,8.444444444444445],"texture":"#fur"}}},{"from":[5.5,1,7],"to":[6.5,5,9.5],"faces":{"west":{"uv":[8.88888888888889,9.11111111111111,10,10.88888888888889],"texture":"#fur"},"north":{"uv":[10,9.11111111111111,10.444444444444445,10.88888888888889],"texture":"#fur"},"east":{"uv":[10.444444444444445,9.11111111111111,11.555555555555555,10.88888888888889],"texture":"#fur"},"south":{"uv":[11.555555555555555,9.11111111111111,12,10.88888888888889],"texture":"#fur"},"up":{"uv":[10,8,10.444444444444445,9.11111111111111],"texture":"#fur"},"down":{"uv":[10.444444444444445,8,10.88888888888889,9.11111111111111],"texture":"#fur"}}},{"from":[7.5,4,10.5],"to":[8.5,9,11.5],"faces":{"west":{"uv":[5.777777777777778,11.555555555555555,6.222222222222222,13.777777777777779],"texture":"#fur"},"north":{"uv":[6.222222222222222,11.555555555555555,6.666666666666667,13.777777777777779],"texture":"#fur"},"east":{"uv":[6.666666666666667,11.555555555555555,7.111111111111111,13.777777777777779],"texture":"#fur"},"south":{"uv":[7.111111111111111,11.555555555555555,7.555555555555555,13.777777777777779],"texture":"#fur"},"up":{"uv":[6.222222222222222,11.11111111111111,6.666666666666667,11.555555555555555],"texture":"#fur"},"down":{"uv":[6.666666666666667,11.11111111111111,7.111111111111111,11.555555555555555],"texture":"#fur"}},"rotation":{"origin":[7.5,6.5,11.5],"axis":"x","angle":45}}]} diff --git a/DuneRealmsGUI/ecology/models/jerboa_curled.json b/DuneRealmsGUI/ecology/models/jerboa_curled.json new file mode 100644 index 00000000..0132c25f --- /dev/null +++ b/DuneRealmsGUI/ecology/models/jerboa_curled.json @@ -0,0 +1 @@ +{"ambientocclusion":false,"textures":{"fur":"dunerealms:entity/jerboa"},"elements":[{"from":[3,1,4],"to":[13,10,15],"faces":{"north":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"south":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"east":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"west":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"up":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"down":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]}}},{"from":[2,3,5],"to":[14,8,14],"faces":{"north":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"south":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"east":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"west":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"up":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"down":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]}}},{"from":[5,0,6],"to":[11,2,13],"faces":{"north":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"south":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"east":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"west":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"up":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"down":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]}}},{"from":[4,3,2],"to":[12,8,6],"faces":{"north":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"south":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"east":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"west":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"up":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"down":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]}}},{"from":[4,2,14],"to":[12,4,17],"faces":{"north":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"south":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"east":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"west":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"up":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]},"down":{"texture":"#fur","uv":[1.7777777777777777,0.4444444444444444,3.111111111111111,1.7777777777777777]}}}]} diff --git a/DuneRealmsGUI/ecology/models/jerboa_walk_left.json b/DuneRealmsGUI/ecology/models/jerboa_walk_left.json new file mode 100644 index 00000000..201224d6 --- /dev/null +++ b/DuneRealmsGUI/ecology/models/jerboa_walk_left.json @@ -0,0 +1 @@ +{"ambientocclusion":false,"textures":{"fur":"dunerealms:entity/jerboa"},"elements":[{"from":[5.5,12,5.5],"to":[10.5,16,10.5],"faces":{"west":{"uv":[4.888888888888889,6.222222222222222,7.111111111111111,8],"texture":"#fur"},"north":{"uv":[7.111111111111111,6.222222222222222,9.333333333333334,8],"texture":"#fur"},"east":{"uv":[9.333333333333334,6.222222222222222,11.555555555555555,8],"texture":"#fur"},"south":{"uv":[11.555555555555555,6.222222222222222,13.777777777777779,8],"texture":"#fur"},"up":{"uv":[7.111111111111111,4,9.333333333333334,6.222222222222222],"texture":"#fur"},"down":{"uv":[9.333333333333334,4,11.555555555555555,6.222222222222222],"texture":"#fur"}}},{"from":[6.5,12,3.5],"to":[9.5,14,5.5],"faces":{"west":{"uv":[11.11111111111111,0.8888888888888888,12,1.7777777777777777],"texture":"#fur"},"north":{"uv":[12,0.8888888888888888,13.333333333333334,1.7777777777777777],"texture":"#fur"},"east":{"uv":[13.333333333333334,0.8888888888888888,14.222222222222221,1.7777777777777777],"texture":"#fur"},"south":{"uv":[14.222222222222221,0.8888888888888888,15.555555555555555,1.7777777777777777],"texture":"#fur"},"up":{"uv":[12,0,13.333333333333334,0.8888888888888888],"texture":"#fur"},"down":{"uv":[13.333333333333334,0,14.666666666666666,0.8888888888888888],"texture":"#fur"}}},{"from":[10.5,13,8.5],"to":[11.5,15,9.5],"faces":{"west":{"uv":[5.333333333333333,0.4444444444444444,5.777777777777778,1.3333333333333333],"texture":"#fur"},"north":{"uv":[5.777777777777778,0.4444444444444444,6.222222222222222,1.3333333333333333],"texture":"#fur"},"east":{"uv":[6.222222222222222,0.4444444444444444,6.666666666666667,1.3333333333333333],"texture":"#fur"},"south":{"uv":[6.666666666666667,0.4444444444444444,7.111111111111111,1.3333333333333333],"texture":"#fur"},"up":{"uv":[5.777777777777778,0,6.222222222222222,0.4444444444444444],"texture":"#fur"},"down":{"uv":[6.222222222222222,0,6.666666666666667,0.4444444444444444],"texture":"#fur"}}},{"from":[4.5,13,8.5],"to":[5.5,15,9.5],"faces":{"west":{"uv":[0,0.4444444444444444,0.4444444444444444,1.3333333333333333],"texture":"#fur"},"north":{"uv":[0.4444444444444444,0.4444444444444444,0.8888888888888888,1.3333333333333333],"texture":"#fur"},"east":{"uv":[0.8888888888888888,0.4444444444444444,1.3333333333333333,1.3333333333333333],"texture":"#fur"},"south":{"uv":[1.3333333333333333,0.4444444444444444,1.7777777777777777,1.3333333333333333],"texture":"#fur"},"up":{"uv":[0.4444444444444444,0,0.8888888888888888,0.4444444444444444],"texture":"#fur"},"down":{"uv":[0.8888888888888888,0,1.3333333333333333,0.4444444444444444],"texture":"#fur"}}},{"from":[6,2,6],"to":[10,12,10],"faces":{"west":{"uv":[0,1.7777777777777777,1.7777777777777777,6.222222222222222],"texture":"#fur"},"north":{"uv":[1.7777777777777777,1.7777777777777777,3.5555555555555554,6.222222222222222],"texture":"#fur"},"east":{"uv":[3.5555555555555554,1.7777777777777777,5.333333333333333,6.222222222222222],"texture":"#fur"},"south":{"uv":[5.333333333333333,1.7777777777777777,7.111111111111111,6.222222222222222],"texture":"#fur"},"up":{"uv":[1.7777777777777777,0,3.5555555555555554,1.7777777777777777],"texture":"#fur"},"down":{"uv":[3.5555555555555554,0,5.333333333333333,1.7777777777777777],"texture":"#fur"}}},{"from":[9,6,6],"to":[11,11,8],"faces":{"west":{"uv":[0,9.777777777777779,0.8888888888888888,12],"texture":"#fur"},"north":{"uv":[0.8888888888888888,9.777777777777779,1.7777777777777777,12],"texture":"#fur"},"east":{"uv":[1.7777777777777777,9.777777777777779,2.6666666666666665,12],"texture":"#fur"},"south":{"uv":[2.6666666666666665,9.777777777777779,3.5555555555555554,12],"texture":"#fur"},"up":{"uv":[0.8888888888888888,8.88888888888889,1.7777777777777777,9.777777777777779],"texture":"#fur"},"down":{"uv":[1.7777777777777777,8.88888888888889,2.6666666666666665,9.777777777777779],"texture":"#fur"}},"rotation":{"origin":[8.5,8.5,7.5],"axis":"x","angle":-22.5}},{"from":[5,6,6],"to":[7,11,8],"faces":{"west":{"uv":[5.333333333333333,8.88888888888889,6.222222222222222,11.11111111111111],"texture":"#fur"},"north":{"uv":[6.222222222222222,8.88888888888889,7.111111111111111,11.11111111111111],"texture":"#fur"},"east":{"uv":[7.111111111111111,8.88888888888889,8,11.11111111111111],"texture":"#fur"},"south":{"uv":[8,8.88888888888889,8.88888888888889,11.11111111111111],"texture":"#fur"},"up":{"uv":[6.222222222222222,8,7.111111111111111,8.88888888888889],"texture":"#fur"},"down":{"uv":[7.111111111111111,8,8,8.88888888888889],"texture":"#fur"}},"rotation":{"origin":[5.5,8.5,7.5],"axis":"x","angle":22.5}},{"from":[9.5,1,7],"to":[10.5,5,9.5],"faces":{"west":{"uv":[2.2222222222222223,11.777777777777779,3.3333333333333335,13.555555555555555],"texture":"#fur"},"north":{"uv":[3.3333333333333335,11.777777777777779,3.7777777777777777,13.555555555555555],"texture":"#fur"},"east":{"uv":[3.7777777777777777,11.777777777777779,4.888888888888889,13.555555555555555],"texture":"#fur"},"south":{"uv":[4.888888888888889,11.777777777777779,5.333333333333333,13.555555555555555],"texture":"#fur"},"up":{"uv":[3.3333333333333335,10.666666666666666,3.7777777777777777,11.777777777777779],"texture":"#fur"},"down":{"uv":[3.7777777777777777,10.666666666666666,4.222222222222222,11.777777777777779],"texture":"#fur"}},"rotation":{"origin":[9.5,5,8.5],"axis":"x","angle":22.5}},{"from":[8.5,0,5],"to":[10.5,1,10],"faces":{"west":{"uv":[7.111111111111111,2.2222222222222223,9.333333333333334,2.6666666666666665],"texture":"#fur"},"north":{"uv":[9.333333333333334,2.2222222222222223,10.222222222222221,2.6666666666666665],"texture":"#fur"},"east":{"uv":[10.222222222222221,2.2222222222222223,12.444444444444445,2.6666666666666665],"texture":"#fur"},"south":{"uv":[12.444444444444445,2.2222222222222223,13.333333333333334,2.6666666666666665],"texture":"#fur"},"up":{"uv":[9.333333333333334,0,10.222222222222221,2.2222222222222223],"texture":"#fur"},"down":{"uv":[10.222222222222221,0,11.11111111111111,2.2222222222222223],"texture":"#fur"}},"rotation":{"origin":[9.5,5,8.5],"axis":"x","angle":22.5}},{"from":[5.5,0,5],"to":[7.5,1,10],"faces":{"west":{"uv":[0,8.444444444444445,2.2222222222222223,8.88888888888889],"texture":"#fur"},"north":{"uv":[2.2222222222222223,8.444444444444445,3.111111111111111,8.88888888888889],"texture":"#fur"},"east":{"uv":[3.111111111111111,8.444444444444445,5.333333333333333,8.88888888888889],"texture":"#fur"},"south":{"uv":[5.333333333333333,8.444444444444445,6.222222222222222,8.88888888888889],"texture":"#fur"},"up":{"uv":[2.2222222222222223,6.222222222222222,3.111111111111111,8.444444444444445],"texture":"#fur"},"down":{"uv":[3.111111111111111,6.222222222222222,4,8.444444444444445],"texture":"#fur"}},"rotation":{"origin":[6.5,5,8.5],"axis":"x","angle":-22.5}},{"from":[5.5,1,7],"to":[6.5,5,9.5],"faces":{"west":{"uv":[8.88888888888889,9.11111111111111,10,10.88888888888889],"texture":"#fur"},"north":{"uv":[10,9.11111111111111,10.444444444444445,10.88888888888889],"texture":"#fur"},"east":{"uv":[10.444444444444445,9.11111111111111,11.555555555555555,10.88888888888889],"texture":"#fur"},"south":{"uv":[11.555555555555555,9.11111111111111,12,10.88888888888889],"texture":"#fur"},"up":{"uv":[10,8,10.444444444444445,9.11111111111111],"texture":"#fur"},"down":{"uv":[10.444444444444445,8,10.88888888888889,9.11111111111111],"texture":"#fur"}},"rotation":{"origin":[6.5,5,8.5],"axis":"x","angle":-22.5}},{"from":[7.5,4,10.5],"to":[8.5,9,11.5],"faces":{"west":{"uv":[5.777777777777778,11.555555555555555,6.222222222222222,13.777777777777779],"texture":"#fur"},"north":{"uv":[6.222222222222222,11.555555555555555,6.666666666666667,13.777777777777779],"texture":"#fur"},"east":{"uv":[6.666666666666667,11.555555555555555,7.111111111111111,13.777777777777779],"texture":"#fur"},"south":{"uv":[7.111111111111111,11.555555555555555,7.555555555555555,13.777777777777779],"texture":"#fur"},"up":{"uv":[6.222222222222222,11.11111111111111,6.666666666666667,11.555555555555555],"texture":"#fur"},"down":{"uv":[6.666666666666667,11.11111111111111,7.111111111111111,11.555555555555555],"texture":"#fur"}},"rotation":{"origin":[7.5,6.5,11.5],"axis":"x","angle":45}}]} diff --git a/DuneRealmsGUI/ecology/models/jerboa_walk_right.json b/DuneRealmsGUI/ecology/models/jerboa_walk_right.json new file mode 100644 index 00000000..67d28424 --- /dev/null +++ b/DuneRealmsGUI/ecology/models/jerboa_walk_right.json @@ -0,0 +1 @@ +{"ambientocclusion":false,"textures":{"fur":"dunerealms:entity/jerboa"},"elements":[{"from":[5.5,12,5.5],"to":[10.5,16,10.5],"faces":{"west":{"uv":[4.888888888888889,6.222222222222222,7.111111111111111,8],"texture":"#fur"},"north":{"uv":[7.111111111111111,6.222222222222222,9.333333333333334,8],"texture":"#fur"},"east":{"uv":[9.333333333333334,6.222222222222222,11.555555555555555,8],"texture":"#fur"},"south":{"uv":[11.555555555555555,6.222222222222222,13.777777777777779,8],"texture":"#fur"},"up":{"uv":[7.111111111111111,4,9.333333333333334,6.222222222222222],"texture":"#fur"},"down":{"uv":[9.333333333333334,4,11.555555555555555,6.222222222222222],"texture":"#fur"}}},{"from":[6.5,12,3.5],"to":[9.5,14,5.5],"faces":{"west":{"uv":[11.11111111111111,0.8888888888888888,12,1.7777777777777777],"texture":"#fur"},"north":{"uv":[12,0.8888888888888888,13.333333333333334,1.7777777777777777],"texture":"#fur"},"east":{"uv":[13.333333333333334,0.8888888888888888,14.222222222222221,1.7777777777777777],"texture":"#fur"},"south":{"uv":[14.222222222222221,0.8888888888888888,15.555555555555555,1.7777777777777777],"texture":"#fur"},"up":{"uv":[12,0,13.333333333333334,0.8888888888888888],"texture":"#fur"},"down":{"uv":[13.333333333333334,0,14.666666666666666,0.8888888888888888],"texture":"#fur"}}},{"from":[10.5,13,8.5],"to":[11.5,15,9.5],"faces":{"west":{"uv":[5.333333333333333,0.4444444444444444,5.777777777777778,1.3333333333333333],"texture":"#fur"},"north":{"uv":[5.777777777777778,0.4444444444444444,6.222222222222222,1.3333333333333333],"texture":"#fur"},"east":{"uv":[6.222222222222222,0.4444444444444444,6.666666666666667,1.3333333333333333],"texture":"#fur"},"south":{"uv":[6.666666666666667,0.4444444444444444,7.111111111111111,1.3333333333333333],"texture":"#fur"},"up":{"uv":[5.777777777777778,0,6.222222222222222,0.4444444444444444],"texture":"#fur"},"down":{"uv":[6.222222222222222,0,6.666666666666667,0.4444444444444444],"texture":"#fur"}}},{"from":[4.5,13,8.5],"to":[5.5,15,9.5],"faces":{"west":{"uv":[0,0.4444444444444444,0.4444444444444444,1.3333333333333333],"texture":"#fur"},"north":{"uv":[0.4444444444444444,0.4444444444444444,0.8888888888888888,1.3333333333333333],"texture":"#fur"},"east":{"uv":[0.8888888888888888,0.4444444444444444,1.3333333333333333,1.3333333333333333],"texture":"#fur"},"south":{"uv":[1.3333333333333333,0.4444444444444444,1.7777777777777777,1.3333333333333333],"texture":"#fur"},"up":{"uv":[0.4444444444444444,0,0.8888888888888888,0.4444444444444444],"texture":"#fur"},"down":{"uv":[0.8888888888888888,0,1.3333333333333333,0.4444444444444444],"texture":"#fur"}}},{"from":[6,2,6],"to":[10,12,10],"faces":{"west":{"uv":[0,1.7777777777777777,1.7777777777777777,6.222222222222222],"texture":"#fur"},"north":{"uv":[1.7777777777777777,1.7777777777777777,3.5555555555555554,6.222222222222222],"texture":"#fur"},"east":{"uv":[3.5555555555555554,1.7777777777777777,5.333333333333333,6.222222222222222],"texture":"#fur"},"south":{"uv":[5.333333333333333,1.7777777777777777,7.111111111111111,6.222222222222222],"texture":"#fur"},"up":{"uv":[1.7777777777777777,0,3.5555555555555554,1.7777777777777777],"texture":"#fur"},"down":{"uv":[3.5555555555555554,0,5.333333333333333,1.7777777777777777],"texture":"#fur"}}},{"from":[9,6,6],"to":[11,11,8],"faces":{"west":{"uv":[0,9.777777777777779,0.8888888888888888,12],"texture":"#fur"},"north":{"uv":[0.8888888888888888,9.777777777777779,1.7777777777777777,12],"texture":"#fur"},"east":{"uv":[1.7777777777777777,9.777777777777779,2.6666666666666665,12],"texture":"#fur"},"south":{"uv":[2.6666666666666665,9.777777777777779,3.5555555555555554,12],"texture":"#fur"},"up":{"uv":[0.8888888888888888,8.88888888888889,1.7777777777777777,9.777777777777779],"texture":"#fur"},"down":{"uv":[1.7777777777777777,8.88888888888889,2.6666666666666665,9.777777777777779],"texture":"#fur"}},"rotation":{"origin":[8.5,8.5,7.5],"axis":"x","angle":22.5}},{"from":[5,6,6],"to":[7,11,8],"faces":{"west":{"uv":[5.333333333333333,8.88888888888889,6.222222222222222,11.11111111111111],"texture":"#fur"},"north":{"uv":[6.222222222222222,8.88888888888889,7.111111111111111,11.11111111111111],"texture":"#fur"},"east":{"uv":[7.111111111111111,8.88888888888889,8,11.11111111111111],"texture":"#fur"},"south":{"uv":[8,8.88888888888889,8.88888888888889,11.11111111111111],"texture":"#fur"},"up":{"uv":[6.222222222222222,8,7.111111111111111,8.88888888888889],"texture":"#fur"},"down":{"uv":[7.111111111111111,8,8,8.88888888888889],"texture":"#fur"}},"rotation":{"origin":[5.5,8.5,7.5],"axis":"x","angle":-22.5}},{"from":[9.5,1,7],"to":[10.5,5,9.5],"faces":{"west":{"uv":[2.2222222222222223,11.777777777777779,3.3333333333333335,13.555555555555555],"texture":"#fur"},"north":{"uv":[3.3333333333333335,11.777777777777779,3.7777777777777777,13.555555555555555],"texture":"#fur"},"east":{"uv":[3.7777777777777777,11.777777777777779,4.888888888888889,13.555555555555555],"texture":"#fur"},"south":{"uv":[4.888888888888889,11.777777777777779,5.333333333333333,13.555555555555555],"texture":"#fur"},"up":{"uv":[3.3333333333333335,10.666666666666666,3.7777777777777777,11.777777777777779],"texture":"#fur"},"down":{"uv":[3.7777777777777777,10.666666666666666,4.222222222222222,11.777777777777779],"texture":"#fur"}},"rotation":{"origin":[9.5,5,8.5],"axis":"x","angle":-22.5}},{"from":[8.5,0,5],"to":[10.5,1,10],"faces":{"west":{"uv":[7.111111111111111,2.2222222222222223,9.333333333333334,2.6666666666666665],"texture":"#fur"},"north":{"uv":[9.333333333333334,2.2222222222222223,10.222222222222221,2.6666666666666665],"texture":"#fur"},"east":{"uv":[10.222222222222221,2.2222222222222223,12.444444444444445,2.6666666666666665],"texture":"#fur"},"south":{"uv":[12.444444444444445,2.2222222222222223,13.333333333333334,2.6666666666666665],"texture":"#fur"},"up":{"uv":[9.333333333333334,0,10.222222222222221,2.2222222222222223],"texture":"#fur"},"down":{"uv":[10.222222222222221,0,11.11111111111111,2.2222222222222223],"texture":"#fur"}},"rotation":{"origin":[9.5,5,8.5],"axis":"x","angle":-22.5}},{"from":[5.5,0,5],"to":[7.5,1,10],"faces":{"west":{"uv":[0,8.444444444444445,2.2222222222222223,8.88888888888889],"texture":"#fur"},"north":{"uv":[2.2222222222222223,8.444444444444445,3.111111111111111,8.88888888888889],"texture":"#fur"},"east":{"uv":[3.111111111111111,8.444444444444445,5.333333333333333,8.88888888888889],"texture":"#fur"},"south":{"uv":[5.333333333333333,8.444444444444445,6.222222222222222,8.88888888888889],"texture":"#fur"},"up":{"uv":[2.2222222222222223,6.222222222222222,3.111111111111111,8.444444444444445],"texture":"#fur"},"down":{"uv":[3.111111111111111,6.222222222222222,4,8.444444444444445],"texture":"#fur"}},"rotation":{"origin":[6.5,5,8.5],"axis":"x","angle":22.5}},{"from":[5.5,1,7],"to":[6.5,5,9.5],"faces":{"west":{"uv":[8.88888888888889,9.11111111111111,10,10.88888888888889],"texture":"#fur"},"north":{"uv":[10,9.11111111111111,10.444444444444445,10.88888888888889],"texture":"#fur"},"east":{"uv":[10.444444444444445,9.11111111111111,11.555555555555555,10.88888888888889],"texture":"#fur"},"south":{"uv":[11.555555555555555,9.11111111111111,12,10.88888888888889],"texture":"#fur"},"up":{"uv":[10,8,10.444444444444445,9.11111111111111],"texture":"#fur"},"down":{"uv":[10.444444444444445,8,10.88888888888889,9.11111111111111],"texture":"#fur"}},"rotation":{"origin":[6.5,5,8.5],"axis":"x","angle":22.5}},{"from":[7.5,4,10.5],"to":[8.5,9,11.5],"faces":{"west":{"uv":[5.777777777777778,11.555555555555555,6.222222222222222,13.777777777777779],"texture":"#fur"},"north":{"uv":[6.222222222222222,11.555555555555555,6.666666666666667,13.777777777777779],"texture":"#fur"},"east":{"uv":[6.666666666666667,11.555555555555555,7.111111111111111,13.777777777777779],"texture":"#fur"},"south":{"uv":[7.111111111111111,11.555555555555555,7.555555555555555,13.777777777777779],"texture":"#fur"},"up":{"uv":[6.222222222222222,11.11111111111111,6.666666666666667,11.555555555555555],"texture":"#fur"},"down":{"uv":[6.666666666666667,11.11111111111111,7.111111111111111,11.555555555555555],"texture":"#fur"}},"rotation":{"origin":[7.5,6.5,11.5],"axis":"x","angle":45}}]} diff --git a/DuneRealmsGUI/ecology/sounds/jerboa_hurt.ogg b/DuneRealmsGUI/ecology/sounds/jerboa_hurt.ogg new file mode 100644 index 00000000..f51715ec Binary files /dev/null and b/DuneRealmsGUI/ecology/sounds/jerboa_hurt.ogg differ diff --git a/DuneRealmsGUI/ecology/sounds/jerboa_idle.ogg b/DuneRealmsGUI/ecology/sounds/jerboa_idle.ogg new file mode 100644 index 00000000..c0c316f3 Binary files /dev/null and b/DuneRealmsGUI/ecology/sounds/jerboa_idle.ogg differ diff --git a/DuneRealmsGUI/ecology/textures/jerboa.png b/DuneRealmsGUI/ecology/textures/jerboa.png new file mode 100644 index 00000000..3392ceb4 Binary files /dev/null and b/DuneRealmsGUI/ecology/textures/jerboa.png differ diff --git a/DuneRealmsGUI/ecology/vendor/runes-and-dunes/MeerkatModel.java.txt b/DuneRealmsGUI/ecology/vendor/runes-and-dunes/MeerkatModel.java.txt new file mode 100644 index 00000000..2b161e03 --- /dev/null +++ b/DuneRealmsGUI/ecology/vendor/runes-and-dunes/MeerkatModel.java.txt @@ -0,0 +1,84 @@ +package net.thefluffycart.dunes_mod.entity.client; + +import com.mojang.blaze3d.vertex.PoseStack; +import com.mojang.blaze3d.vertex.VertexConsumer; +import net.minecraft.client.model.HierarchicalModel; +import net.minecraft.client.model.geom.ModelPart; +import net.minecraft.client.model.geom.PartPose; +import net.minecraft.client.model.geom.builders.*; +import net.minecraft.util.Mth; +import net.thefluffycart.dunes_mod.entity.animations.ModAnimationDefinitions; +import net.thefluffycart.dunes_mod.entity.custom.MeerkatEntity; + +public class MeerkatModel extends HierarchicalModel { + + private final ModelPart Meerkat; + private final ModelPart head; + + public MeerkatModel(ModelPart root) { + this.Meerkat = root.getChild("meerkat"); + this.head = Meerkat.getChild("head"); + } + + public static LayerDefinition createBodyLayer() { + MeshDefinition meshdefinition = new MeshDefinition(); + PartDefinition partdefinition = meshdefinition.getRoot(); + + PartDefinition meerkat = partdefinition.addOrReplaceChild("meerkat", CubeListBuilder.create(), PartPose.offset(1.0F, 24.0F, -1.0F)); + + PartDefinition head = meerkat.addOrReplaceChild("head", CubeListBuilder.create().texOffs(11, 9).addBox(-2.5F, -4.0F, -2.5F, 5.0F, 4.0F, 5.0F, new CubeDeformation(0.0F)) + .texOffs(25, 0).addBox(-1.5F, -2.0F, -4.5F, 3.0F, 2.0F, 2.0F, new CubeDeformation(0.0F)), PartPose.offset(-1.0F, -12.0F, 1.0F)); + + PartDefinition ear_left = head.addOrReplaceChild("ear_left", CubeListBuilder.create().texOffs(12, 0).addBox(0.0F, -1.0F, -0.5F, 1.0F, 2.0F, 1.0F, new CubeDeformation(0.0F)), PartPose.offset(2.5F, -2.0F, 1.0F)); + + PartDefinition ear_right = head.addOrReplaceChild("ear_right", CubeListBuilder.create().texOffs(0, 0).addBox(-1.0F, -1.0F, -0.5F, 1.0F, 2.0F, 1.0F, new CubeDeformation(0.0F)), PartPose.offset(-2.5F, -2.0F, 1.0F)); + + PartDefinition body = meerkat.addOrReplaceChild("body", CubeListBuilder.create().texOffs(0, 0).addBox(-1.5F, -5.0F, -1.5F, 4.0F, 10.0F, 4.0F, new CubeDeformation(0.0F)), PartPose.offset(-1.5F, -7.0F, 0.5F)); + + PartDefinition arm_left = meerkat.addOrReplaceChild("arm_left", CubeListBuilder.create(), PartPose.offset(0.0F, -10.0F, 1.0F)); + + PartDefinition cube_r1 = arm_left.addOrReplaceChild("cube_r1", CubeListBuilder.create().texOffs(0, 20).addBox(0.5F, -2.5F, -1.5F, 2.0F, 5.0F, 2.0F, new CubeDeformation(0.0F)), PartPose.offsetAndRotation(-0.5F, 1.5F, -0.5F, -0.5236F, 0.0F, 0.0F)); + + PartDefinition arm_right = meerkat.addOrReplaceChild("arm_right", CubeListBuilder.create(), PartPose.offset(-2.0F, -10.0F, 1.0F)); + + PartDefinition cube_r2 = arm_right.addOrReplaceChild("cube_r2", CubeListBuilder.create().texOffs(12, 18).addBox(-0.5F, -2.5F, -1.5F, 2.0F, 5.0F, 2.0F, new CubeDeformation(0.0F)), PartPose.offsetAndRotation(-1.5F, 1.5F, -0.5F, -0.5236F, 0.0F, 0.0F)); + + PartDefinition foot_left = meerkat.addOrReplaceChild("foot_left", CubeListBuilder.create().texOffs(5, 24).addBox(0.0F, 0.0F, -1.5F, 1.0F, 4.0F, 2.5F, new CubeDeformation(0.0F)) + .texOffs(16, 0).addBox(-1.0F, 4.0F, -3.5F, 2.0F, 1.0F, 5.0F, new CubeDeformation(0.0F)), PartPose.offset(0.5F, -5.0F, 1.5F)); + + PartDefinition foot_right = meerkat.addOrReplaceChild("foot_right", CubeListBuilder.create().texOffs(0, 14).addBox(-1.0F, 4.0F, -3.5F, 2.0F, 1.0F, 5.0F, new CubeDeformation(0.0F)) + .texOffs(20, 18).addBox(-1.0F, 0.0F, -1.5F, 1.0F, 4.0F, 2.5F, new CubeDeformation(0.0F)), PartPose.offset(-2.5F, -5.0F, 1.5F)); + + PartDefinition tail = meerkat.addOrReplaceChild("tail", CubeListBuilder.create(), PartPose.offset(-1.0F, -5.5F, 3.0F)); + + PartDefinition cube_r3 = tail.addOrReplaceChild("cube_r3", CubeListBuilder.create().texOffs(13, 25).addBox(0.0F, -2.5F, -1.0F, 1.0F, 5.0F, 1.0F, new CubeDeformation(0.0F)), PartPose.offsetAndRotation(-0.5F, -1.0F, 1.5F, -0.7854F, 0.0F, 0.0F)); + + return LayerDefinition.create(meshdefinition, 36, 36); + } + + @Override + public void setupAnim(T entity, float limbSwing, float limbSwingAmount, float ageInTicks, float netHeadYaw, float headPitch) { + this.root().getAllParts().forEach(ModelPart::resetPose); + this.animateWalk(ModAnimationDefinitions.MEERKAT_WALK, limbSwing, limbSwingAmount, 2f, 2.5f); + this.animate(entity.idleAnimationState, ModAnimationDefinitions.MEERKAT_IDLE, ageInTicks, 1f); + this.animate(entity.sitAnimationState, ModAnimationDefinitions.MEERKAT_SIT, ageInTicks, 1f); + } + + + private void applyHeadRotation(MeerkatEntity pEntity, float pNetHeadYaw, float pHeadPitch, float pAgeInTicks) { + pNetHeadYaw = Mth.clamp(pNetHeadYaw, -30.0F, 30.0F); + pHeadPitch = Mth.clamp(pHeadPitch, -25.0F, 45.0F); + + this.head.yRot = pNetHeadYaw * ((float) Math.PI / 180F); + this.head.xRot = pHeadPitch * ((float) Math.PI / 180F); + } + @Override + public void renderToBuffer(PoseStack poseStack, VertexConsumer vertexConsumer, int packedLight, int packedOverlay, float red, float green, float blue, float alpha) { + Meerkat.render(poseStack, vertexConsumer, packedLight, packedOverlay, red, green, blue, alpha); + } + + @Override + public ModelPart root() { + return Meerkat; + } +} \ No newline at end of file diff --git a/DuneRealmsGUI/ecology/vendor/runes-and-dunes/NOTICE.txt b/DuneRealmsGUI/ecology/vendor/runes-and-dunes/NOTICE.txt new file mode 100644 index 00000000..02816aec --- /dev/null +++ b/DuneRealmsGUI/ecology/vendor/runes-and-dunes/NOTICE.txt @@ -0,0 +1,34 @@ +Runes and Dunes meerkat assets +Author: TheFluffycart55 and Runes and Dunes contributors +Source: https://github.com/TheFluffycart55/Runes-And-Dunes-1.20.X +Pinned revision: c33d58cbae17e0869c4a512a0e4ea2ab7a0251af +Project licence declaration: https://modrinth.com/mod/runes-and-dunes/ +The project author declares MIT on Modrinth. The repository LICENSE.txt is +the Forge development kit's separate LGPL notice, not an asset-specific notice. + +Adapted by DuneRealms on 2026-11-23: converted meerkat box geometry to native +item-display models; two walking poses and defensive curl; newly repainted +jerboa texture. Original idle and hurt OGG recordings are unchanged. +The original model source is included alongside this notice. + +MIT License + +Copyright TheFluffycart55 and Runes and Dunes contributors + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/DuneTerrain/src/main/java/com/example/duneterrain/FaunaModels.java b/DuneTerrain/src/main/java/com/example/duneterrain/FaunaModels.java index 4178bbdf..1828c1cc 100644 --- a/DuneTerrain/src/main/java/com/example/duneterrain/FaunaModels.java +++ b/DuneTerrain/src/main/java/com/example/duneterrain/FaunaModels.java @@ -27,11 +27,14 @@ final class FaunaModels implements AutoCloseable { displays.put(id,display);carriers.put(id,carrier); } carrier.setInvisible(true); + NamespacedKey selected=new NamespacedKey("dunerealms","entity/"+model); + var shown=display.getItemStack();var shownMeta=shown.getItemMeta(); + if(!selected.equals(shownMeta.getItemModel())){shownMeta.setItemModel(selected);shown.setItemMeta(shownMeta);display.setItemStack(shown);} // Living-entity ticks recalculate visibility from effects; a raw entity flag // alone is cleared between model updates on current Paper. var invisible=carrier.getPotionEffect(PotionEffectType.INVISIBILITY);if(invisible==null||invisible.getDuration()<40)carrier.addPotionEffect(new PotionEffect(PotionEffectType.INVISIBILITY,200,0,false,false,false)); if(!Objects.equals(sizes.get(id),size)){float s=(float)size;display.setTransformation(new Transformation(new Vector3f(0,.5f*s,0),new Quaternionf(),new Vector3f(s),new Quaternionf()));sizes.put(id,size);} - Location at=carrier.getLocation();at.setPitch(0);at.setYaw(at.getYaw()+180);Location last=display.getLocation(); + Location at=carrier.getLocation();at.setPitch(0);Location last=display.getLocation(); if(last.distanceSquared(at)>.0001||Math.abs(last.getYaw()-at.getYaw())>.5)display.teleport(at); } void retain(Set alive){for(UUID id:new ArrayList<>(displays.keySet()))if(!alive.contains(id))remove(id);} diff --git a/DuneTerrain/src/main/java/com/example/duneterrain/JerboaMobs.java b/DuneTerrain/src/main/java/com/example/duneterrain/JerboaMobs.java index 7c3a7466..ba426d0a 100644 --- a/DuneTerrain/src/main/java/com/example/duneterrain/JerboaMobs.java +++ b/DuneTerrain/src/main/java/com/example/duneterrain/JerboaMobs.java @@ -14,7 +14,7 @@ import org.bukkit.plugin.Plugin; import net.kyori.adventure.text.Component; import net.kyori.adventure.text.format.NamedTextColor; -/** Cat locomotion and native breeding, with a separate, real jerboa model. */ +/** Armadillo locomotion, defensive curling and native breeding, with a separate, real jerboa model. */ final class JerboaMobs implements Listener { static final NamespacedKey KIND=new NamespacedKey("dunerealms","jerboa"),ROLLED=new NamespacedKey("dunerealms","jerboa_mother_rolled"); private static final NamespacedKey EI=new NamespacedKey("executableitems","ei-id"); @@ -32,22 +32,29 @@ final class JerboaMobs implements Listener { static boolean mother(Entity e){return e.getPersistentDataContainer().getOrDefault(KIND,PersistentDataType.BYTE,(byte)0)==2;} private static boolean arrakis(Entity e){return e.getWorld().getName().equalsIgnoreCase("arrakis");} private static String itemId(ItemStack item){return item==null||!item.hasItemMeta()?null:item.getItemMeta().getPersistentDataContainer().get(EI,PersistentDataType.STRING);} - private static void prepare(Cat cat,int age){cat.getPersistentDataContainer().set(KIND,PersistentDataType.BYTE,(byte)1);cat.setTamed(true);cat.setSitting(false);cat.setAge(age);cat.setRemoveWhenFarAway(true);cat.customName(Component.text("Jerboa",NamedTextColor.YELLOW));var speed=cat.getAttribute(Attribute.MOVEMENT_SPEED);if(speed!=null)speed.setBaseValue(SPEED);var health=cat.getAttribute(Attribute.MAX_HEALTH);if(health!=null){health.setBaseValue(3);cat.setHealth(3);}} - private Cat spawn(Location at,int age){return at.getWorld().spawn(at,Cat.class,c->prepare(c,age));} + private static void prepare(Armadillo cat,int age){cat.getPersistentDataContainer().set(KIND,PersistentDataType.BYTE,(byte)1);cat.setAge(age);cat.setSilent(true);cat.setRemoveWhenFarAway(true);cat.customName(Component.text("Jerboa",NamedTextColor.YELLOW));var speed=cat.getAttribute(Attribute.MOVEMENT_SPEED);if(speed!=null)speed.setBaseValue(SPEED);var health=cat.getAttribute(Attribute.MAX_HEALTH);if(health!=null){health.setBaseValue(3);cat.setHealth(3);}} + private Armadillo spawn(Location at,int age){return at.getWorld().spawn(at,Armadillo.class,c->prepare(c,age));} void replace(Rabbit rabbit){ if(!rabbit.isValid()||rabbit.hasMetadata("NPC")||!replacing.add(rabbit.getUniqueId()))return; - try{Cat cat=spawn(rabbit.getLocation(),rabbit.getAge());if(!cat.isValid())return; + try{Armadillo cat=spawn(rabbit.getLocation(),rabbit.getAge());if(!cat.isValid())return; cat.setFireTicks(rabbit.getFireTicks());cat.setHealth(Math.min(rabbit.getHealth(),cat.getAttribute(Attribute.MAX_HEALTH).getValue()));rabbit.remove(); }finally{replacing.remove(rabbit.getUniqueId());} } + void migrate(Cat old){ + Armadillo replacement=spawn(old.getLocation(),old.getAge());if(!replacement.isValid())return;replacement.setFireTicks(old.getFireTicks());replacement.setHealth(Math.min(3,old.getHealth()));replacement.customName(old.customName());if(old.getPersistentDataContainer().has(ROLLED,PersistentDataType.BYTE))replacement.getPersistentDataContainer().set(ROLLED,PersistentDataType.BYTE,(byte)1);old.remove(); + } private void maintain(){ World world=Bukkit.getWorld("arrakis");if(world==null)return; var valid=new HashSet(); for(var entity:world.getLivingEntities()){ if(entity instanceof Rabbit rabbit){replace(rabbit);continue;} + if(entity instanceof Cat cat&&isJerboa(cat)){migrate(cat);continue;} if(isJerboa(entity)){ - valid.add(entity.getUniqueId());models.track(entity,"jerboa",entity instanceof Cat c&&!c.isAdult()?.48:mother(entity)?2:1); - if(entity instanceof Cat cat){cat.setSitting(false);if(cat.isAdult()&&!cat.getPersistentDataContainer().has(ROLLED,PersistentDataType.BYTE))rollMother(cat);} + valid.add(entity.getUniqueId());entity.setSilent(true);boolean curled=entity instanceof Armadillo a&&a.getState()!=Armadillo.State.IDLE; + String model=curled?"jerboa_curled":entity.getVelocity().lengthSquared()>.001?(entity.getTicksLived()/4%2==0?"jerboa_walk_left":"jerboa_walk_right"):"jerboa"; + models.track(entity,model,entity instanceof Armadillo c&&!c.isAdult()?.48:mother(entity)?2:1); + if(!curled&&random.getAsDouble()<.01)entity.getWorld().playSound(entity.getLocation(),"dunerealms:jerboa.idle",SoundCategory.NEUTRAL,.35f,mother(entity)?.8f:1.1f); + if(entity instanceof Armadillo cat){if(cat.isAdult()&&!cat.getPersistentDataContainer().has(ROLLED,PersistentDataType.BYTE))rollMother(cat);} else if(entity instanceof Spider spider){UUID target=retaliation.get(spider.getUniqueId());LivingEntity attacker=target==null?null:Bukkit.getEntity(target) instanceof LivingEntity l?l:null;if(attacker==null||!attacker.isValid()||attacker.isDead()||!attacker.getWorld().equals(world)||attacker.getLocation().distanceSquared(spider.getLocation())>1024){retaliation.remove(spider.getUniqueId());spider.setTarget(null);}else spider.setTarget(attacker);} }else if(entity instanceof Wolf&&entity.getPersistentDataContainer().has(new NamespacedKey("dunerealms","tiny_worm_pet"),PersistentDataType.BYTE)){ valid.add(entity.getUniqueId());models.track(entity,"tiny_worm",((Wolf)entity).isAdult()?.8:.45); @@ -55,28 +62,29 @@ final class JerboaMobs implements Listener { } models.retain(valid);retaliation.keySet().retainAll(valid);instantFeeds.entrySet().removeIf(e->e.getValue()+1000=MOTHER_CHANCE||adult.getNearbyEntities(32,16,32).stream().anyMatch(JerboaMobs::mother))return; Location at=adult.getLocation().clone().add(2,0,2);if(!at.getChunk().isLoaded()||!at.getBlock().isPassable()||!at.clone().add(0,1,0).getBlock().isPassable()||!at.clone().add(0,-1,0).getBlock().getType().isSolid())return; at.getWorld().spawn(at,Spider.class,s->{s.getPersistentDataContainer().set(KIND,PersistentDataType.BYTE,(byte)2);s.customName(Component.text("Big Mama Jerboa",NamedTextColor.GOLD));s.getAttribute(Attribute.MAX_HEALTH).setBaseValue(6);s.setHealth(6);s.getAttribute(Attribute.MOVEMENT_SPEED).setBaseValue(SPEED);s.getAttribute(Attribute.ATTACK_DAMAGE).setBaseValue(3);var scale=s.getAttribute(Attribute.SCALE);if(scale!=null)scale.setBaseValue(1.4);s.setTarget(null);}); } private static void consume(Player player,EquipmentSlot hand){if(player.getGameMode()==GameMode.CREATIVE)return;ItemStack item=player.getInventory().getItem(hand);item.setAmount(item.getAmount()-1);player.getInventory().setItem(hand,item);} - private void litter(Cat parent){for(int i=0;i<4;i++){var at=parent.getLocation().clone().add((i%2-.5)*.4,0,(i/2-.5)*.4);spawn(at,-24000);}parent.getWorld().spawnParticle(Particle.HEART,parent.getLocation().add(0,.5,0),7,.3,.3,.3);} + private void litter(Armadillo parent){for(int i=0;i<4;i++){var at=parent.getLocation().clone().add((i%2-.5)*.4,0,(i/2-.5)*.4);spawn(at,-24000);}parent.getWorld().spawnParticle(Particle.HEART,parent.getLocation().add(0,.5,0),7,.3,.3,.3);} @EventHandler(priority=EventPriority.HIGHEST,ignoreCancelled=true) public void feed(PlayerInteractEntityEvent event){ if(!arrakis(event.getRightClicked())||!isJerboa(event.getRightClicked()))return;event.setCancelled(true); - if(!(event.getRightClicked() instanceof Cat cat)||!cat.isAdult())return;Player player=event.getPlayer();String id=itemId(player.getInventory().getItem(event.getHand())); + if(!(event.getRightClicked() instanceof Armadillo cat)||!cat.isAdult())return;Player player=event.getPlayer();String id=itemId(player.getInventory().getItem(event.getHand())); if("spice_block".equals(id)||"smuggled_spice_block".equals(id)){ long now=System.currentTimeMillis();if(now-instantFeeds.getOrDefault(cat.getUniqueId(),0L)<250)return; litter(cat);instantFeeds.put(cat.getUniqueId(),now);consume(player,event.getHand()); }else if("refined_spice".equals(id)&&cat.canBreed()&&cat.getLoveModeTicks()==0){cat.setLoveModeTicks(600);consume(player,event.getHand());} } @EventHandler(priority=EventPriority.MONITOR,ignoreCancelled=true) public void breed(EntityBreedEvent event){ - if(!arrakis(event.getEntity())||!isJerboa(event.getMother())||!isJerboa(event.getFather())||!(event.getEntity() instanceof Cat child))return; + if(!arrakis(event.getEntity())||!isJerboa(event.getMother())||!isJerboa(event.getFather())||!(event.getEntity() instanceof Armadillo child))return; prepare(child,-24000);for(int i=0;i<3;i++)spawn(child.getLocation(),-24000); } @EventHandler(priority=EventPriority.HIGHEST,ignoreCancelled=true) public void target(EntityTargetLivingEntityEvent event){if(mother(event.getEntity())&&event.getTarget()!=null&&!event.getTarget().getUniqueId().equals(retaliation.get(event.getEntity().getUniqueId())))event.setCancelled(true);} @EventHandler(priority=EventPriority.MONITOR,ignoreCancelled=true) public void attacked(EntityDamageByEntityEvent event){ + if(isJerboa(event.getEntity()))event.getEntity().getWorld().playSound(event.getEntity().getLocation(),"dunerealms:jerboa.hurt",SoundCategory.NEUTRAL,.5f,mother(event.getEntity())?.8f:1.1f); if(!mother(event.getEntity()))return;Entity attacker=event.getDamager();if(attacker instanceof Projectile p&&p.getShooter() instanceof Entity shooter)attacker=shooter; if(attacker instanceof LivingEntity&&attacker!=event.getEntity())retaliation.put(event.getEntity().getUniqueId(),attacker.getUniqueId()); } diff --git a/tools/ArrakisFaunaSmoke.java b/tools/ArrakisFaunaSmoke.java index 46d59ff6..e5b86fac 100644 --- a/tools/ArrakisFaunaSmoke.java +++ b/tools/ArrakisFaunaSmoke.java @@ -16,7 +16,7 @@ import org.bukkit.plugin.java.JavaPlugin; /** Disposable native boot check. Never runs on a production world. */ public final class ArrakisFaunaSmoke extends JavaPlugin { private JerboaMobs fauna;private ItemStack held; - @Override public void onEnable(){fauna=new JerboaMobs(this,this::item,()->0);fauna.start();Bukkit.getScheduler().runTaskLater(this,()->{try{run();}catch(Throwable failure){getLogger().severe("FAUNA_SMOKE_FAIL "+failure);failure.printStackTrace();Bukkit.shutdown();}},50);} + @Override public void onEnable(){fauna=new JerboaMobs(this,this::item,()->1);fauna.start();Bukkit.getScheduler().runTaskLater(this,()->{try{run();}catch(Throwable failure){getLogger().severe("FAUNA_SMOKE_FAIL "+failure);failure.printStackTrace();Bukkit.shutdown();}},50);} private ItemStack item(String id){var stack=new ItemStack(id.contains("hide")?Material.RABBIT_HIDE:id.contains("vial")?Material.POTION:id.contains("cooked")?Material.COOKED_RABBIT:Material.RABBIT);var meta=stack.getItemMeta();meta.getPersistentDataContainer().set(new NamespacedKey("executableitems","ei-id"),PersistentDataType.STRING,id);stack.setItemMeta(meta);return stack;} private static void check(boolean condition,String message){if(!condition)throw new IllegalStateException(message);} private Object defaults(Method m){Class r=m.getReturnType();if(r==boolean.class)return false;if(r==int.class)return 0;if(r==float.class)return 0f;if(r==double.class)return 0d;if(r==long.class)return 0L;return null;} @@ -39,8 +39,10 @@ public final class ArrakisFaunaSmoke extends JavaPlugin { held=new ItemStack(Material.BRUSH);bridge.brush(new PlayerInteractEvent(player,Action.RIGHT_CLICK_BLOCK,held,block,BlockFace.UP,EquipmentSlot.HAND));check(block.getType()==Material.SAND,"Brush did not restore original sand"); var plain=world.getBlockAt(9,65,8);plain.setType(Material.SANDSTONE,false);bridge.brush(new PlayerInteractEvent(player,Action.RIGHT_CLICK_BLOCK,held,plain,BlockFace.UP,EquipmentSlot.HAND));check(plain.getType()==Material.SANDSTONE,"Brush altered ordinary construction"); Rabbit rabbit=world.spawn(new Location(world,2.5,65,2.5),Rabbit.class);fauna.replace(rabbit);check(!rabbit.isValid(),"Rabbit was not replaced"); - Cat adult=world.getEntitiesByClass(Cat.class).stream().filter(JerboaMobs::isJerboa).findFirst().orElseThrow();check(adult.getAttribute(Attribute.MAX_HEALTH).getValue()==3,"Jerboa health changed");check(Math.abs(adult.getAttribute(Attribute.MOVEMENT_SPEED).getValue()-.225)<1e-6,"Jerboa speed changed"); - int before=world.getEntitiesByClass(Cat.class).size();held=item("spice_block");fauna.feed(new PlayerInteractEntityEvent(player,adult,EquipmentSlot.HAND));check(world.getEntitiesByClass(Cat.class).size()==before+4,"One-parent block did not produce four babies"); - Bukkit.getScheduler().runTaskLater(this,()->{try{check(adult.isInvisible(),"Carrier remains visible");check(world.getEntitiesByClass(ItemDisplay.class).stream().anyMatch(d->d.getItemStack().getItemMeta().hasItemModel()),"Custom model display absent");getLogger().info("FAUNA_SMOKE_SUCCESS sandWear=true brushRestore=true ordinarySandstonePreserved=true catCarrier=true fourBabies=true realModelDisplay=true");}catch(Throwable failure){getLogger().severe("FAUNA_SMOKE_FAIL "+failure);failure.printStackTrace();}finally{Bukkit.shutdown();}},20); + Armadillo adult=world.getEntitiesByClass(Armadillo.class).stream().filter(e->JerboaMobs.isJerboa(e)&&e.isAdult()&&e.getLocation().distanceSquared(new Location(world,2.5,65,2.5))<.1).findFirst().orElseThrow();check(adult.getAttribute(Attribute.MAX_HEALTH).getValue()==3,"Jerboa health changed");check(Math.abs(adult.getAttribute(Attribute.MOVEMENT_SPEED).getValue()-.225)<1e-6,"Jerboa speed changed"); + Cat legacy=world.spawn(new Location(world,4.5,65,4.5),Cat.class);legacy.getPersistentDataContainer().set(JerboaMobs.KIND,PersistentDataType.BYTE,(byte)1);legacy.setAge(-1234);fauna.migrate(legacy);check(!legacy.isValid(),"Legacy cat not migrated");check(world.getEntitiesByClass(Armadillo.class).stream().anyMatch(a->a.getAge()==-1234),"Migration lost baby age"); + int before=world.getEntitiesByClass(Armadillo.class).size();held=item("spice_block");fauna.feed(new PlayerInteractEntityEvent(player,adult,EquipmentSlot.HAND));check(world.getEntitiesByClass(Armadillo.class).size()==before+4,"One-parent block did not produce four babies"); + Location start=adult.getLocation().clone();check(adult.getPathfinder().moveTo(new Location(world,12.5,65,2.5),1),"Native walking path unavailable"); + Bukkit.getScheduler().runTaskLater(this,()->{try{check(adult.getLocation().distanceSquared(start)>.04,"Native jerboa failed to walk");check(adult.isInvisible(),"Carrier remains visible");check(world.getEntitiesByClass(ItemDisplay.class).stream().anyMatch(d->d.getItemStack().getItemMeta().hasItemModel()),"Custom model display absent");adult.rollUp();check(adult.getState()!=Armadillo.State.IDLE,"Armadillo did not curl defensively");getLogger().info("FAUNA_SMOKE_SUCCESS sandWear=true brushRestore=true ordinarySandstonePreserved=true armadilloCarrier=true fourBabies=true realModelDisplay=true nativeWalking=true defensiveCurl=true");}catch(Throwable failure){getLogger().severe("FAUNA_SMOKE_FAIL "+failure);failure.printStackTrace();}finally{Bukkit.shutdown();}},40); } } diff --git a/tools/build-arrakis-fauna-pack.mjs b/tools/build-arrakis-fauna-pack.mjs index 35eed495..0e967f74 100644 --- a/tools/build-arrakis-fauna-pack.mjs +++ b/tools/build-arrakis-fauna-pack.mjs @@ -10,9 +10,13 @@ export function build(output){ entries.set(`assets/dunerealms/models/entity/${name}.json`,Buffer.from(JSON.stringify({ambientocclusion:false,...model}))); entries.set(`assets/dunerealms/items/entity/${name}.json`,Buffer.from(JSON.stringify({model:{type:'minecraft:model',model:`dunerealms:entity/${name}`}}))); } + entries.set('assets/dunerealms/textures/entity/jerboa.png',fs.readFileSync(path.join(path.dirname(fileURLToPath(import.meta.url)),'../DuneRealmsGUI/ecology/textures/jerboa.png'))); + for(const name of ['idle','hurt'])entries.set(`assets/dunerealms/sounds/jerboa_${name}.ogg`,fs.readFileSync(path.join(path.dirname(fileURLToPath(import.meta.url)),`../DuneRealmsGUI/ecology/sounds/jerboa_${name}.ogg`))); + entries.set('assets/dunerealms/sounds.json',Buffer.from(JSON.stringify(Object.fromEntries(['idle','hurt'].map(name=>[`jerboa.${name}`,{sounds:[`dunerealms:jerboa_${name}`]}]))))); + entries.set('licenses/Runes-and-Dunes-MIT.txt',fs.readFileSync(path.join(path.dirname(fileURLToPath(import.meta.url)),'../DuneRealmsGUI/ecology/vendor/runes-and-dunes/NOTICE.txt'))); // Local Windows checkouts and Linux release workers must produce equal bytes. for(const [name,bytes]of entries)if(/\.(?:txt|md)$/.test(name))entries.set(name,Buffer.from(bytes.toString('utf8').replaceAll('\r\n','\n'))); - const filename='DuneRealms-Materials-arrakis-v3.zip',bytes=zip(entries); + const filename='DuneRealms-Materials-arrakis-v4.zip',bytes=zip(entries); fs.mkdirSync(output,{recursive:true});fs.writeFileSync(path.join(output,filename),bytes); const digest=algorithm=>createHash(algorithm).update(bytes).digest('hex'); const record={filename,url:'https://www.dunerealms.com/downloads/'+filename,sha1:digest('sha1'),sha256:digest('sha256'),bytes:bytes.length,entries:entries.size}; diff --git a/tools/build-ecology-packs.py b/tools/build-ecology-packs.py index fd0bd5f8..7bac4339 100644 --- a/tools/build-ecology-packs.py +++ b/tools/build-ecology-packs.py @@ -24,11 +24,16 @@ def build(output, expanded=False): items[f'assets/dunerealms/textures/item/ecology/{item}.png'] = png(item, (32, 32)) items[f'assets/dunerealms/models/item/ecology/{item}.json'] = json.dumps({'parent': 'minecraft:item/generated', 'textures': {'layer0': f'dunerealms:item/ecology/{item}'}}).encode() items[f'assets/dunerealms/items/ecology/{item}.json'] = json.dumps({'model': {'type': 'minecraft:model', 'model': f'dunerealms:item/ecology/{item}'}}).encode() - for name in ('jerboa', 'tiny_worm'): + for name in ('jerboa', 'jerboa_walk_left', 'jerboa_walk_right', 'jerboa_curled', 'tiny_worm'): model = (ART / 'models' / (name + '.json')).read_bytes() assert json.loads(model)['elements'], 'Real custom geometry required' items[f'assets/dunerealms/models/entity/{name}.json'] = model items[f'assets/dunerealms/items/entity/{name}.json'] = json.dumps({'model': {'type': 'minecraft:model', 'model': f'dunerealms:entity/{name}'}}).encode() + items['assets/dunerealms/textures/entity/jerboa.png'] = (ART / 'textures/jerboa.png').read_bytes() + items['assets/dunerealms/sounds.json'] = json.dumps({f'jerboa.{name}': {'sounds': [f'dunerealms:jerboa_{name}']} for name in ('idle', 'hurt')}).encode() + for name in ('idle', 'hurt'): + items[f'assets/dunerealms/sounds/jerboa_{name}.ogg'] = (ART / 'sounds' / f'jerboa_{name}.ogg').read_bytes() + items['licenses/Runes-and-Dunes-MIT.txt'] = (ART / 'vendor/runes-and-dunes/NOTICE.txt').read_bytes() entities = dict(common) if expanded: texture=png('spice_block',(32,32)) diff --git a/tools/build-fauna-models.mjs b/tools/build-fauna-models.mjs index 81c8f0a8..c3a20e2c 100644 --- a/tools/build-fauna-models.mjs +++ b/tools/build-fauna-models.mjs @@ -2,26 +2,18 @@ import {mkdir,writeFile} from 'node:fs/promises'; import {fileURLToPath} from 'node:url'; import path from 'node:path'; +import {meerkatModels} from './build-jerboa-meerkat.mjs'; const root=fileURLToPath(new URL('../DuneRealmsGUI/ecology/models/',import.meta.url)); const faces=texture=>Object.fromEntries(['north','south','east','west','up','down'].map(face=>[face,{texture:'#'+texture,uv:[0,0,16,16]}])); const box=(from,to,texture)=>({from,to,faces:faces(texture)}); export function faunaModels(){ - const jerboa=[ - box([4,3,8],[12,10,18],'fur'),box([3,4,9],[13,9,16],'fur'),box([5,2.5,8],[11,5,18],'belly'), - box([3.5,6,2],[12.5,12,9],'fur'),box([5,6,0],[11,9,4],'belly'),box([7,7,-.5],[9,8.5,1],'nose'), - box([3,11,4],[6,16,6],'fur'),box([10,11,4],[13,16,6],'fur'),box([3.5,12,3.8],[5.5,15,4],'ear'),box([10.5,12,3.8],[12.5,15,4],'ear'), - box([3.3,9,2.5],[4.1,11,4.5],'eye'),box([11.9,9,2.5],[12.7,11,4.5],'eye'), - box([3.2,10,2.2],[4.2,10.8,2.6],'glint'),box([11.8,10,2.2],[12.8,10.8,2.6],'glint'), - box([3,1,12],[6,5,18],'fur'),box([10,1,12],[13,5,18],'fur'),box([2,0,8],[6,1.5,17],'belly'),box([10,0,8],[14,1.5,17],'belly'), - box([4.5,0,4],[6,6,7],'belly'),box([10,0,4],[11.5,6,7],'belly'), - box([7,3,17],[9,4.5,24],'tail'),box([8,3,23],[10,4.5,28],'tail'),box([9,3,27],[12,5,31],'eye') - ]; const worm=[]; for(let i=0;i<7;i++){const width=7-i*.55,z=4+i*3.2;worm.push(box([8-width/2,2+i*.08,z],[8+width/2,2+width,z+3.2],i%2?'ridge':'body'));} worm.push(box([3,2,0],[13,11,4],'body'),box([4,3,-.1],[12,10,.1],'mouth'),box([6,5,-.2],[10,8,0],'throat')); for(let i=0;i<4;i++){worm.push(box([4.5+i*1.8,3,-.4],[5.3+i*1.8,4.5,.1],'tooth'),box([4.5+i*1.8,8.5,-.4],[5.3+i*1.8,10,.1],'tooth'));} return { - jerboa:{textures:{fur:'minecraft:block/brown_terracotta',belly:'minecraft:block/terracotta',nose:'minecraft:block/pink_terracotta',ear:'minecraft:block/pink_terracotta',eye:'minecraft:block/black_concrete',glint:'minecraft:block/white_concrete',tail:'minecraft:block/terracotta'},elements:jerboa}, + ...meerkatModels(), + jerboa_curled:{textures:{fur:'dunerealms:entity/jerboa'},elements:[box([3,1,4],[13,10,15],'fur'),box([2,3,5],[14,8,14],'fur'),box([5,0,6],[11,2,13],'fur'),box([4,3,2],[12,8,6],'fur'),box([4,2,14],[12,4,17],'fur')].map(e=>({...e,faces:Object.fromEntries(Object.entries(e.faces).map(([face,data])=>[face,{...data,uv:[4,1,7,4].map(v=>v*16/36)}]))}))}, tiny_worm:{textures:{body:'minecraft:block/terracotta',ridge:'minecraft:block/brown_terracotta',mouth:'minecraft:block/black_concrete',throat:'minecraft:block/orange_terracotta',tooth:'minecraft:block/bone_block_side'},elements:worm} }; } diff --git a/tools/build-jerboa-meerkat.mjs b/tools/build-jerboa-meerkat.mjs new file mode 100644 index 00000000..7be9736d --- /dev/null +++ b/tools/build-jerboa-meerkat.mjs @@ -0,0 +1,30 @@ +// Runes and Dunes meerkat geometry, adapted for native item-display rendering. +// TheFluffycart55, MIT as declared by the author's Modrinth project. +import fs from 'node:fs'; +import path from 'node:path'; +import {fileURLToPath} from 'node:url'; +const root=path.resolve(path.dirname(fileURLToPath(import.meta.url)),'..'); +export function meerkatModels(){ + const source=fs.readFileSync(path.join(root,'DuneRealmsGUI/ecology/vendor/runes-and-dunes/MeerkatModel.java.txt'),'utf8'); + const parts=new Map([['partdefinition',{at:[0,0,0],rotation:[0,0,0]}]]),elements=[]; + const numbers=s=>s.split(',').map(x=>Number(x.trim().replace(/F$/,''))); + for(const statement of source.split(';')){ + const declaration=statement.match(/PartDefinition (\w+) = (\w+)\.addOrReplaceChild\("([^"]+)"/);if(!declaration)continue; + const [,name,parent]=declaration,pose=statement.match(/PartPose\.(offset(?:AndRotation)?)\(([^)]+)\)/);if(!pose)throw Error('Pose missing: '+name); + const values=numbers(pose[2]),ancestor=parts.get(parent);if(!ancestor)throw Error('Parent missing: '+parent); + const at=values.slice(0,3).map((v,i)=>v+ancestor.at[i]),angles=values.slice(3);parts.set(name,{at,rotation:angles}); + for(const box of statement.matchAll(/texOffs\((\d+), (\d+)\)\.addBox\(([-\d.F]+), ([-\d.F]+), ([-\d.F]+), ([-\d.F]+), ([-\d.F]+), ([-\d.F]+),/g)){ + const u=+box[1],v=+box[2],[x,y,z,w,h,d]=box.slice(3).map(n=>Number(n.replace('F',''))),uv=(a,b,c,e)=>[a,b,c,e].map(n=>n*16/36); + const faces={west:{uv:uv(u,v+d,u+d,v+d+h)},north:{uv:uv(u+d,v+d,u+d+w,v+d+h)},east:{uv:uv(u+d+w,v+d,u+2*d+w,v+d+h)},south:{uv:uv(u+2*d+w,v+d,u+2*d+2*w,v+d+h)},up:{uv:uv(u+d,v,u+d+w,v+d)},down:{uv:uv(u+d+w,v,u+d+2*w,v+d)}}; + for(const face of Object.values(faces))face.texture='#fur'; + const element={from:[8+at[0]+x,24-at[1]-y-h,8+at[2]+z],to:[8+at[0]+x+w,24-at[1]-y,8+at[2]+z+d],faces}; + if(angles.some(a=>a!==0))element.rotation={origin:[8+at[0],24-at[1],8+at[2]],axis:'x',angle:Math.round(-angles[0]*180/Math.PI/22.5)*22.5}; + elements.push({part:name,element,at}); + } + } + if(elements.length!==12)throw Error('Upstream model geometry changed: '+elements.length); + const make=frame=>({textures:{fur:'dunerealms:entity/jerboa'},elements:elements.map(({part,element,at})=>{ + const copy=structuredClone(element);if(frame&&/^(?:foot_left|foot_right|cube_r1|cube_r2)$/.test(part))copy.rotation={origin:[8+at[0],24-at[1],8+at[2]],axis:'x',angle:(part==='foot_left'||part==='cube_r2'?1:-1)*frame*22.5};return copy; + })}); + return {jerboa:make(0),jerboa_walk_left:make(1),jerboa_walk_right:make(-1)}; +} diff --git a/tools/patch-jerboa-motion.py b/tools/patch-jerboa-motion.py new file mode 100644 index 00000000..6bf19b43 --- /dev/null +++ b/tools/patch-jerboa-motion.py @@ -0,0 +1,21 @@ +"""Replace only fauna runtime classes in the hash-pinned current terrain JAR.""" +import pathlib,sys,hashlib,zipfile,json +source,classes,output=map(pathlib.Path,sys.argv[1:4]);expected=sys.argv[4] +assert not output.exists() and hashlib.sha256(source.read_bytes()).hexdigest()==expected +allowed=['com/example/duneterrain/'+name+'.class' for name in ('JerboaMobs','FaunaModels')] +with zipfile.ZipFile(source) as original: + entries={name:original.read(name) for name in original.namelist()} + assert len(entries)==len(original.namelist()) +before=dict(entries) +for name in allowed: + assert name in entries + data=(classes/name).read_bytes();assert data[:4]==b'\xca\xfe\xba\xbe' and int.from_bytes(data[6:8],'big')==65 + entries[name]=data +entries['plugin.yml']=entries['plugin.yml'].decode().replace('version: 1.0.12-arrakeen1-fauna2-trails1','version: 1.0.12-arrakeen1-fauna3-trails1').encode() +assert entries['plugin.yml']!=before['plugin.yml'] +with zipfile.ZipFile(output,'x',zipfile.ZIP_DEFLATED) as target: + for name,data in entries.items():target.writestr(name,data) +with zipfile.ZipFile(output) as target: + changed=[name for name in before if target.read(name)!=before[name]] + assert set(changed)==set(allowed+['plugin.yml']) +print(json.dumps({'sha256':hashlib.sha256(output.read_bytes()).hexdigest(),'changed':changed,'worldGenerationChanged':False}))