diff --git a/HOW_TO_PLAY_RU.md b/HOW_TO_PLAY_RU.md index 6905272e..03ec7251 100644 --- a/HOW_TO_PLAY_RU.md +++ b/HOW_TO_PLAY_RU.md @@ -72,7 +72,7 @@ - Захват бурь - Дайте пегасу облако, и у него будет вода на день, дайте пегасу банку, и он поймает облака и устроит дождь на всё лето. + Дайте пегасу облако, и у него будет вода на день, дайте пегасу банку, и он поймает облако и устроит дождь на всё лето. Кажется, так гласит поговорка? Так вот, с помощью банок можно собрать дождь в банку во время грозы. Это позволит и остановить дождь, и сохранить погоду в банке для последующего использования. diff --git a/assets/models/block_shell.bbmodel b/assets/models/block_shell.bbmodel new file mode 100644 index 00000000..c174edb6 --- /dev/null +++ b/assets/models/block_shell.bbmodel @@ -0,0 +1 @@ +{"meta":{"format_version":"4.5","model_format":"java_block","box_uv":false},"name":"block_shell","parent":"","ambientocclusion":true,"front_gui_light":false,"visible_box":[1,1,0],"variable_placeholders":"","variable_placeholder_buttons":[],"unhandled_root_fields":{},"resolution":{"width":16,"height":16},"elements":[{"name":"cube","box_uv":false,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[2.4000000000000004,0,0],"to":[10.399999999999999,0,8],"autouv":0,"color":9,"rotation":[0,45,0],"origin":[12,0,4],"faces":{"north":{"uv":[0,0,8,0],"texture":null},"east":{"uv":[0,0,8,0],"texture":null},"south":{"uv":[0,0,8,0],"texture":null},"west":{"uv":[0,0,8,0],"texture":null},"up":{"uv":[0,0,16,16],"texture":0},"down":{"uv":[0,0,0,0],"texture":null}},"type":"cube","uuid":"1c53fe40-1877-60c2-80b2-135dff0afe56"}],"outliner":["1c53fe40-1877-60c2-80b2-135dff0afe56"],"textures":[{"path":"/home/sollace/Documents/GitRepos/minecraft_mods/Unicopia/src/main/resources/assets/unicopia/textures/item/clam_shell.png","name":"clam_shell.png","folder":"item","namespace":"unicopia","id":"shell","particle":true,"render_mode":"default","render_sides":"auto","frame_time":1,"frame_order_type":"loop","frame_order":"","frame_interpolate":false,"visible":true,"mode":"bitmap","saved":true,"uuid":"1a1accdc-ffd7-c20a-9047-a5db72ecf496","relative_path":"../../../src/main/resources/assets/unicopia/textures/item/clam_shell.png","source":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAihJREFUOE+l09tL02Ecx/H3+C3XDr9y+21Yk9lhbWyyxYg8BFoXkXRYQlQEi6CCLosg6H+IoIu6CIoIDaKgjPJGwhBUQqVINHYo+0XqXB6mzsPSxm9PYLIQMwifywc+L57vh+erY51Ht848/wQaW9+LzFSaYrsDq8OBGo9y5VTdisxfgdtPW4Sy1UltbZBFQAJsQErT+BJXCQe8hdwq4O6LNrGnJkCp3U5/NFqYsAxILCwwPZ7j4uHqtYGXvb3CqGlYDAasPh8+SUJdZjpa33H+UMXaIzxq+yC8pp/YKyuxAKP9/ej1ejKZDB0D37l+7sSqF6+4eNYTFaEKPzpVJZ/P8zlnIZfLUb/bxafhEVre9uELedA0E0fLnUvZAvCks084t5WhzCRxuVykZBnt8iv8d+oLPWRuqLDRTKOzj9Id2zlZ4dUtATcfNgnbJoHX70dSdrHvwSBjCAzGzeApQj4ik23KoqkTsDiHGs4RzxYRqQksAw3PhVJiR7bacClGJIsFz60EmlFGMphB2gCzEwydMeJ2u3kTizEzJ3H2QOg30PC6RyhbrKRGktgUJwf3eoh3dzNtMuExm5mfnycYDNLV1cXO6mraexKcrvL96eBec7tIqgNYHSVcjRzTPe78KIptNjxuBf3kJD9kmfFEgrJQCPXbLIMDCS7UVa0s8X5zu7h0fH+h1O60EF9jUdyBckaHU4yNDIHIM5VOcy0SXvsj/e9yrXsbfwHRlcQRuWinHQAAAABJRU5ErkJggg=="}]} \ No newline at end of file diff --git a/assets/models/block_shell_2.bbmodel b/assets/models/block_shell_2.bbmodel new file mode 100644 index 00000000..aed1740d --- /dev/null +++ b/assets/models/block_shell_2.bbmodel @@ -0,0 +1 @@ +{"meta":{"format_version":"4.5","model_format":"java_block","box_uv":false},"name":"clam_shell_2","parent":"","ambientocclusion":true,"front_gui_light":false,"visible_box":[1,1,0],"variable_placeholders":"","variable_placeholder_buttons":[],"unhandled_root_fields":{},"resolution":{"width":16,"height":16},"elements":[{"name":"cube","box_uv":false,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[6.4,0,0],"to":[14.399999999999999,0,8],"autouv":0,"color":9,"rotation":[0,45,0],"origin":[12,0,4],"faces":{"north":{"uv":[0,0,8,0],"texture":null},"east":{"uv":[0,0,8,0],"texture":null},"south":{"uv":[0,0,8,0],"texture":null},"west":{"uv":[0,0,8,0],"texture":null},"up":{"uv":[0,0,16,16],"texture":0},"down":{"uv":[0,0,0,0],"texture":null}},"type":"cube","uuid":"1c53fe40-1877-60c2-80b2-135dff0afe56"},{"name":"cube","box_uv":false,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[1.2117749006091447,0,6.788225099390861],"to":[9.211774900609145,0,14.78822509939086],"autouv":0,"color":9,"rotation":[0,-22.5,0],"origin":[5.211774900609143,0,10.788225099390859],"faces":{"north":{"uv":[0,0,8,0],"texture":null},"east":{"uv":[0,0,8,0],"texture":null},"south":{"uv":[0,0,8,0],"texture":null},"west":{"uv":[0,0,8,0],"texture":null},"up":{"uv":[0,0,16,16],"rotation":90,"texture":0},"down":{"uv":[0,0,0,0],"rotation":270,"texture":null}},"type":"cube","uuid":"f8ee1a59-5c1f-ddd7-783f-bb14a40c36a2"}],"outliner":["1c53fe40-1877-60c2-80b2-135dff0afe56","f8ee1a59-5c1f-ddd7-783f-bb14a40c36a2"],"textures":[{"path":"/home/sollace/Documents/GitRepos/minecraft_mods/Unicopia/src/main/resources/assets/unicopia/textures/item/clam_shell.png","name":"clam_shell.png","folder":"item","namespace":"unicopia","id":"shell","particle":true,"render_mode":"default","render_sides":"auto","frame_time":1,"frame_order_type":"loop","frame_order":"","frame_interpolate":false,"visible":true,"mode":"bitmap","saved":true,"uuid":"1a1accdc-ffd7-c20a-9047-a5db72ecf496","relative_path":"../../../src/main/resources/assets/unicopia/textures/item/clam_shell.png","source":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAihJREFUOE+l09tL02Ecx/H3+C3XDr9y+21Yk9lhbWyyxYg8BFoXkXRYQlQEi6CCLosg6H+IoIu6CIoIDaKgjPJGwhBUQqVINHYo+0XqXB6mzsPSxm9PYLIQMwifywc+L57vh+erY51Ht848/wQaW9+LzFSaYrsDq8OBGo9y5VTdisxfgdtPW4Sy1UltbZBFQAJsQErT+BJXCQe8hdwq4O6LNrGnJkCp3U5/NFqYsAxILCwwPZ7j4uHqtYGXvb3CqGlYDAasPh8+SUJdZjpa33H+UMXaIzxq+yC8pp/YKyuxAKP9/ej1ejKZDB0D37l+7sSqF6+4eNYTFaEKPzpVJZ/P8zlnIZfLUb/bxafhEVre9uELedA0E0fLnUvZAvCks084t5WhzCRxuVykZBnt8iv8d+oLPWRuqLDRTKOzj9Id2zlZ4dUtATcfNgnbJoHX70dSdrHvwSBjCAzGzeApQj4ik23KoqkTsDiHGs4RzxYRqQksAw3PhVJiR7bacClGJIsFz60EmlFGMphB2gCzEwydMeJ2u3kTizEzJ3H2QOg30PC6RyhbrKRGktgUJwf3eoh3dzNtMuExm5mfnycYDNLV1cXO6mraexKcrvL96eBec7tIqgNYHSVcjRzTPe78KIptNjxuBf3kJD9kmfFEgrJQCPXbLIMDCS7UVa0s8X5zu7h0fH+h1O60EF9jUdyBckaHU4yNDIHIM5VOcy0SXvsj/e9yrXsbfwHRlcQRuWinHQAAAABJRU5ErkJggg=="}]} \ No newline at end of file diff --git a/assets/models/changeling.bbmodel b/assets/models/changeling.bbmodel new file mode 100644 index 00000000..3854a2c6 --- /dev/null +++ b/assets/models/changeling.bbmodel @@ -0,0 +1 @@ +{"meta":{"format_version":"4.5","model_format":"free","box_uv":true},"name":"minelittlepony:races/alex/changeling","model_identifier":"","visible_box":[1,1,0],"variable_placeholders":"","variable_placeholder_buttons":[],"timeline_setups":[],"unhandled_root_fields":{},"resolution":{"width":64,"height":64},"elements":[{"name":"right_arm","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-4,-24,0],"to":[-1,-12,4],"autouv":0,"color":9,"origin":[0,0,0],"uv_offset":[40,16],"faces":{"north":{"uv":[44,20,47,32]},"east":{"uv":[40,20,44,32]},"south":{"uv":[51,20,54,32]},"west":{"uv":[47,20,51,32]},"up":{"uv":[47,20,44,16]},"down":{"uv":[50,16,47,20]}},"type":"cube","uuid":"1d8264fe-4073-4137-b67f-755b78874f9a"},{"name":"left_leg","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[1,-24,9],"to":[4,-12,13],"autouv":0,"color":8,"origin":[0,0,0],"uv_offset":[16,48],"faces":{"north":{"uv":[20,52,23,64]},"east":{"uv":[16,52,20,64]},"south":{"uv":[27,52,30,64]},"west":{"uv":[23,52,27,64]},"up":{"uv":[23,52,20,48]},"down":{"uv":[26,48,23,52]}},"type":"cube","uuid":"2224c5bb-33a1-45aa-8df2-7b245faf572e"},{"name":"torso","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-4,-12,-2],"to":[4,-4,14],"autouv":0,"color":5,"origin":[0,0,0],"uv_offset":[4,4],"faces":{"north":{"uv":[20,20,28,28]},"east":{"uv":[4,20,20,28]},"south":{"uv":[44,20,52,28]},"west":{"uv":[28,20,44,28]},"up":{"uv":[28,20,20,4]},"down":{"uv":[36,4,28,20]}},"type":"cube","uuid":"0416c2d2-5521-4e77-85c1-ceb3224e34a1"},{"name":"head","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-4,-2,-6],"to":[4,6,2],"autouv":0,"color":6,"origin":[0,0,0],"faces":{"north":{"uv":[8,8,16,16]},"east":{"uv":[0,8,8,16]},"south":{"uv":[24,8,32,16]},"west":{"uv":[16,8,24,16]},"up":{"uv":[16,8,8,0]},"down":{"uv":[24,0,16,8]}},"type":"cube","uuid":"5398561f-992a-42d9-8aac-2359cb9f783e"},{"name":"left_ear","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[2,6,-1],"to":[4,8,1],"autouv":0,"color":5,"origin":[0,0,0],"uv_offset":[12,16],"faces":{"north":{"uv":[14,18,16,20]},"east":{"uv":[12,18,14,20]},"south":{"uv":[18,18,20,20]},"west":{"uv":[16,18,18,20]},"up":{"uv":[16,18,14,16]},"down":{"uv":[18,16,16,18]}},"type":"cube","uuid":"67772092-a7ec-4b41-9bc3-6d9c78303b33"},{"name":"right_ear","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-4,6,-1],"to":[-2,8,1],"autouv":0,"color":9,"origin":[0,0,0],"uv_offset":[12,16],"faces":{"north":{"uv":[14,18,16,20]},"east":{"uv":[12,18,14,20]},"south":{"uv":[18,18,20,20]},"west":{"uv":[16,18,18,20]},"up":{"uv":[16,18,14,16]},"down":{"uv":[18,16,16,18]}},"type":"cube","uuid":"a9803b7d-652c-4b9e-9360-850d3d32406e"},{"name":"bone","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-0.5,7,-3.5],"to":[0.5,11,-2.5],"autouv":0,"color":6,"rotation":[-25,0,0],"origin":[0,0,0],"uv_offset":[0,3],"faces":{"north":{"uv":[1,4,2,8]},"east":{"uv":[0,4,1,8]},"south":{"uv":[3,4,4,8]},"west":{"uv":[2,4,3,8]},"up":{"uv":[2,4,1,3]},"down":{"uv":[3,3,2,4]}},"type":"cube","uuid":"f495b1c9-8836-4873-9abf-e32119dfebdf"},{"name":"left_arm","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[1,-24,0],"to":[4,-12,4],"autouv":0,"color":5,"origin":[0,0,0],"uv_offset":[32,48],"faces":{"north":{"uv":[36,52,39,64]},"east":{"uv":[32,52,36,64]},"south":{"uv":[43,52,46,64]},"west":{"uv":[39,52,43,64]},"up":{"uv":[39,52,36,48]},"down":{"uv":[42,48,39,52]}},"type":"cube","uuid":"b6b07f07-21da-4a4f-98fb-b100c8ed3d49"},{"name":"right_leg","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-4,-24,9],"to":[-1,-12,13],"autouv":0,"color":2,"origin":[0,0,0],"uv_offset":[0,16],"faces":{"north":{"uv":[4,20,7,32]},"east":{"uv":[0,20,4,32]},"south":{"uv":[11,20,14,32]},"west":{"uv":[7,20,11,32]},"up":{"uv":[7,20,4,16]},"down":{"uv":[10,16,7,20]}},"type":"cube","uuid":"f21f6c04-9c32-48e3-b959-be34311f9d5f"},{"name":"hat","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-4.5,-2.5,-6.5],"to":[4.5,6.5,2.5],"autouv":0,"color":7,"visibility":false,"origin":[0,0,0],"uv_offset":[32,0],"faces":{"north":{"uv":[41,9,50,18]},"east":{"uv":[32,9,41,18]},"south":{"uv":[59,9,68,18]},"west":{"uv":[50,9,59,18]},"up":{"uv":[50,9,41,0]},"down":{"uv":[59,0,50,9]}},"type":"cube","uuid":"bb8858c3-14b6-4e16-a2de-745a8e65336e"},{"name":"tail","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-2,-17,16],"to":[2,-2,20],"autouv":1,"color":0,"origin":[0,-3,16],"uv_offset":[-2,-2],"faces":{"north":{"uv":[2,2,6,17]},"east":{"uv":[-2,2,2,17]},"south":{"uv":[10,2,14,17]},"west":{"uv":[6,2,10,17]},"up":{"uv":[6,2,2,-2]},"down":{"uv":[10,-2,6,2]}},"type":"cube","uuid":"5adca51a-e69d-9aab-9771-29d8b56ea43c"},{"name":"neck","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-2,-5,-2.75],"to":[2,-1,1.25],"autouv":1,"color":0,"rotation":[-9,0,0],"origin":[0,0,0],"uv_offset":[-2,-2],"faces":{"north":{"uv":[2,2,6,6]},"east":{"uv":[-2,2,2,6]},"south":{"uv":[10,2,14,6]},"west":{"uv":[6,2,10,6]},"up":{"uv":[6,2,2,-2]},"down":{"uv":[10,-2,6,2]}},"type":"cube","uuid":"10c33114-4039-f51d-26c8-d0eb1d84d00d"},{"name":"tail_stub","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-1,-13,8.75],"to":[1,-11,13.75],"autouv":1,"color":0,"rotation":[-29,0,0],"origin":[0,-1,-2.25],"uv_offset":[-3,-3],"faces":{"north":{"uv":[2,2,4,4]},"east":{"uv":[-3,2,2,4]},"south":{"uv":[9,2,11,4]},"west":{"uv":[4,2,9,4]},"up":{"uv":[4,2,2,-3]},"down":{"uv":[6,-3,4,2]}},"type":"cube","uuid":"caed00cb-bb23-d4d7-898a-f63b47e96948"},{"name":"cube","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-2,-2,-7],"to":[2,0,-6],"autouv":1,"color":0,"origin":[0,0,0],"uv_offset":[1,1],"faces":{"north":{"uv":[2,2,6,4]},"east":{"uv":[1,2,2,4]},"south":{"uv":[7,2,11,4]},"west":{"uv":[6,2,7,4]},"up":{"uv":[6,2,2,1]},"down":{"uv":[10,1,6,2]}},"type":"cube","uuid":"b29482ca-b64c-f284-64c9-569945a66b90"},{"name":"cube","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-1,0,-7],"to":[1,1,-6],"autouv":1,"color":0,"origin":[0,0,0],"uv_offset":[1,1],"faces":{"north":{"uv":[2,2,4,3]},"east":{"uv":[1,2,2,3]},"south":{"uv":[5,2,7,3]},"west":{"uv":[4,2,5,3]},"up":{"uv":[4,2,2,1]},"down":{"uv":[6,1,4,2]}},"type":"cube","uuid":"8f742406-4f87-ad08-d533-eda4374d7e6d"},{"name":"cube","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-2,-2,-7],"to":[2,1,-6],"autouv":1,"color":0,"visibility":false,"origin":[0,0,0],"uv_offset":[1,1],"faces":{"north":{"uv":[2,2,6,5]},"east":{"uv":[1,2,2,5]},"south":{"uv":[7,2,11,5]},"west":{"uv":[6,2,7,5]},"up":{"uv":[6,2,2,1]},"down":{"uv":[10,1,6,2]}},"type":"cube","uuid":"42084153-147e-681d-58b0-c6aada64e0c9"},{"name":"left","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[4,-5,4],"to":[16,-5,10],"autouv":1,"color":0,"rotation":[7.5,0,37.50000000000003],"origin":[4,-5,7],"uv_offset":[-4,-4],"faces":{"north":{"uv":[2,2,14,2]},"east":{"uv":[-4,2,2,2]},"south":{"uv":[20,2,32,2]},"west":{"uv":[14,2,20,2]},"up":{"uv":[14,2,2,-4]},"down":{"uv":[26,-4,14,2]}},"type":"cube","uuid":"295ecf47-5eb2-53a2-9a06-96ba0b864206"},{"name":"right","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-16,-4,4],"to":[-4,-4,10],"autouv":1,"color":0,"rotation":[7.5,3.578124016646456e-15,-37.500000000000064],"origin":[-4,-4,7],"uv_offset":[-4,-4],"faces":{"north":{"uv":[2,2,14,2]},"east":{"uv":[-4,2,2,2]},"south":{"uv":[20,2,32,2]},"west":{"uv":[14,2,20,2]},"up":{"uv":[14,2,2,-4]},"down":{"uv":[26,-4,14,2]}},"type":"cube","uuid":"4e372f3c-39b6-945c-1597-5ee203dd8fbe"},{"name":"left_comp","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[3,-5,4],"to":[15,-5,10],"autouv":1,"color":0,"rotation":[10,0,67.49999999999999],"origin":[3,-5,7],"uv_offset":[-4,-4],"faces":{"north":{"uv":[2,2,14,2]},"east":{"uv":[-4,2,2,2]},"south":{"uv":[20,2,32,2]},"west":{"uv":[14,2,20,2]},"up":{"uv":[14,2,2,-4]},"down":{"uv":[26,-4,14,2]}},"type":"cube","uuid":"7ad679d8-2c63-2f04-741c-f5156f12a98f"},{"name":"right_comp","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-15,-4,4],"to":[-3,-4,10],"autouv":1,"color":0,"rotation":[10,0,-67.49999999999999],"origin":[-3,-4,7],"uv_offset":[-4,-4],"faces":{"north":{"uv":[2,2,14,2]},"east":{"uv":[-4,2,2,2]},"south":{"uv":[20,2,32,2]},"west":{"uv":[14,2,20,2]},"up":{"uv":[14,2,2,-4]},"down":{"uv":[26,-4,14,2]}},"type":"cube","uuid":"d981e2c7-b1f1-035e-adb7-a82b9b83d4f3"}],"outliner":[{"name":"body","origin":[0,0,0],"color":0,"uuid":"b7f58495-d35a-49f7-9018-7cb0790d7e7d","export":true,"mirror_uv":false,"isOpen":true,"locked":false,"visibility":true,"autouv":0,"children":["0416c2d2-5521-4e77-85c1-ceb3224e34a1","10c33114-4039-f51d-26c8-d0eb1d84d00d",{"name":"tail","origin":[0,-5,13],"color":0,"uuid":"8c3663fd-66f3-4700-9b48-f40c53471614","export":true,"mirror_uv":false,"isOpen":false,"locked":false,"visibility":true,"autouv":0,"children":["caed00cb-bb23-d4d7-898a-f63b47e96948","5adca51a-e69d-9aab-9771-29d8b56ea43c"]},{"name":"wings","origin":[0,0,0],"color":0,"uuid":"ed904a49-16c2-f559-f0d4-46d57735e79d","export":true,"mirror_uv":false,"isOpen":true,"locked":false,"visibility":true,"autouv":0,"children":["295ecf47-5eb2-53a2-9a06-96ba0b864206","7ad679d8-2c63-2f04-741c-f5156f12a98f","4e372f3c-39b6-945c-1597-5ee203dd8fbe","d981e2c7-b1f1-035e-adb7-a82b9b83d4f3"]}]},{"name":"head","origin":[0,0,0],"color":0,"uuid":"4e4e43eb-6b25-4753-b192-48cbda23758e","export":true,"mirror_uv":false,"isOpen":false,"locked":false,"visibility":true,"autouv":0,"children":["5398561f-992a-42d9-8aac-2359cb9f783e","67772092-a7ec-4b41-9bc3-6d9c78303b33","a9803b7d-652c-4b9e-9360-850d3d32406e",{"name":"horn","origin":[0,0,0],"color":0,"uuid":"36833de9-990e-414f-881f-12cb96eb6cdc","export":true,"mirror_uv":false,"isOpen":false,"locked":false,"visibility":true,"autouv":0,"children":["f495b1c9-8836-4873-9abf-e32119dfebdf"]},{"name":"snout","origin":[0,0,0],"color":0,"uuid":"72d884c7-00a0-4508-9f8a-f2c3d89741f6","export":true,"mirror_uv":false,"isOpen":false,"locked":false,"visibility":true,"autouv":0,"children":[{"name":"mare","origin":[0,0,0],"color":0,"uuid":"804d414a-6eab-4af7-8ac3-0876598d2f2f","export":true,"mirror_uv":false,"isOpen":true,"locked":false,"visibility":true,"autouv":0,"children":["b29482ca-b64c-f284-64c9-569945a66b90","8f742406-4f87-ad08-d533-eda4374d7e6d"]},{"name":"stallion","origin":[0,0,0],"color":0,"uuid":"bf66d113-c543-4ec4-a176-3bd46ac4c161","export":true,"mirror_uv":false,"isOpen":true,"locked":false,"visibility":false,"autouv":0,"children":["42084153-147e-681d-58b0-c6aada64e0c9"]}]}]},"bb8858c3-14b6-4e16-a2de-745a8e65336e","b6b07f07-21da-4a4f-98fb-b100c8ed3d49","1d8264fe-4073-4137-b67f-755b78874f9a","2224c5bb-33a1-45aa-8df2-7b245faf572e","f21f6c04-9c32-48e3-b959-be34311f9d5f"],"textures":[]} \ No newline at end of file diff --git a/assets/models/clam_shell_3.bbmodel b/assets/models/clam_shell_3.bbmodel new file mode 100644 index 00000000..a7dee723 --- /dev/null +++ b/assets/models/clam_shell_3.bbmodel @@ -0,0 +1 @@ +{"meta":{"format_version":"4.5","model_format":"java_block","box_uv":false},"name":"clam_shell_3","parent":"","ambientocclusion":true,"front_gui_light":false,"visible_box":[1,1,0],"variable_placeholders":"","variable_placeholder_buttons":[],"unhandled_root_fields":{},"resolution":{"width":16,"height":16},"elements":[{"name":"cube","box_uv":false,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[6.100000000000001,0.4,0.6000000000000014],"to":[14.100000000000005,0.4,8.600000000000001],"autouv":0,"color":9,"rotation":[22.5,0,0],"origin":[10.100000000000005,0.4,3],"faces":{"north":{"uv":[0,0,8,0],"texture":null},"east":{"uv":[0,0,8,0],"texture":null},"south":{"uv":[0,0,8,0],"texture":null},"west":{"uv":[0,0,8,0],"texture":null},"up":{"uv":[0,0,16,16],"rotation":270,"texture":0},"down":{"uv":[0,0,0,0],"rotation":90,"texture":null}},"type":"cube","uuid":"1c53fe40-1877-60c2-80b2-135dff0afe56"},{"name":"cube","box_uv":false,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[0.3640158355865708,0,4.022858234660681],"to":[8.36401583558657,0,12.022858234660681],"autouv":0,"color":9,"rotation":[0,0,22.5],"origin":[4.364015835586571,0,8.022858234660681],"faces":{"north":{"uv":[0,0,8,0],"texture":null},"east":{"uv":[0,0,8,0],"texture":null},"south":{"uv":[0,0,8,0],"texture":null},"west":{"uv":[0,0,8,0],"texture":null},"up":{"uv":[0,0,16,16],"rotation":180,"texture":0},"down":{"uv":[0,0,0,0],"rotation":180,"texture":null}},"type":"cube","uuid":"f8ee1a59-5c1f-ddd7-783f-bb14a40c36a2"},{"name":"cube","box_uv":false,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[7.755052095676865,0,8.084325693581398],"to":[15.755052095676865,0,16.0843256935814],"autouv":0,"color":9,"rotation":[-22.5,0,0],"origin":[11.755052095676865,0,12.0843256935814],"faces":{"north":{"uv":[0,0,8,0],"texture":null},"east":{"uv":[0,0,8,0],"texture":null},"south":{"uv":[0,0,8,0],"texture":null},"west":{"uv":[0,0,8,0],"texture":null},"up":{"uv":[0,0,16,16],"rotation":90,"texture":0},"down":{"uv":[16,0,0,16],"rotation":90,"texture":0}},"type":"cube","uuid":"a13cf19e-6339-91b6-4d9b-0d3500abf734"}],"outliner":["1c53fe40-1877-60c2-80b2-135dff0afe56","f8ee1a59-5c1f-ddd7-783f-bb14a40c36a2","a13cf19e-6339-91b6-4d9b-0d3500abf734"],"textures":[{"path":"/home/sollace/Documents/GitRepos/minecraft_mods/Unicopia/src/main/resources/assets/unicopia/textures/item/clam_shell.png","name":"clam_shell.png","folder":"item","namespace":"unicopia","id":"shell","particle":true,"render_mode":"default","render_sides":"auto","frame_time":1,"frame_order_type":"loop","frame_order":"","frame_interpolate":false,"visible":true,"mode":"bitmap","saved":true,"uuid":"1a1accdc-ffd7-c20a-9047-a5db72ecf496","relative_path":"../../../src/main/resources/assets/unicopia/textures/item/clam_shell.png","source":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAihJREFUOE+l09tL02Ecx/H3+C3XDr9y+21Yk9lhbWyyxYg8BFoXkXRYQlQEi6CCLosg6H+IoIu6CIoIDaKgjPJGwhBUQqVINHYo+0XqXB6mzsPSxm9PYLIQMwifywc+L57vh+erY51Ht848/wQaW9+LzFSaYrsDq8OBGo9y5VTdisxfgdtPW4Sy1UltbZBFQAJsQErT+BJXCQe8hdwq4O6LNrGnJkCp3U5/NFqYsAxILCwwPZ7j4uHqtYGXvb3CqGlYDAasPh8+SUJdZjpa33H+UMXaIzxq+yC8pp/YKyuxAKP9/ej1ejKZDB0D37l+7sSqF6+4eNYTFaEKPzpVJZ/P8zlnIZfLUb/bxafhEVre9uELedA0E0fLnUvZAvCks084t5WhzCRxuVykZBnt8iv8d+oLPWRuqLDRTKOzj9Id2zlZ4dUtATcfNgnbJoHX70dSdrHvwSBjCAzGzeApQj4ik23KoqkTsDiHGs4RzxYRqQksAw3PhVJiR7bacClGJIsFz60EmlFGMphB2gCzEwydMeJ2u3kTizEzJ3H2QOg30PC6RyhbrKRGktgUJwf3eoh3dzNtMuExm5mfnycYDNLV1cXO6mraexKcrvL96eBec7tIqgNYHSVcjRzTPe78KIptNjxuBf3kJD9kmfFEgrJQCPXbLIMDCS7UVa0s8X5zu7h0fH+h1O60EF9jUdyBckaHU4yNDIHIM5VOcy0SXvsj/e9yrXsbfwHRlcQRuWinHQAAAABJRU5ErkJggg=="}]} \ No newline at end of file diff --git a/assets/models/clam_shell_4.bbmodel b/assets/models/clam_shell_4.bbmodel new file mode 100644 index 00000000..822daf6b --- /dev/null +++ b/assets/models/clam_shell_4.bbmodel @@ -0,0 +1 @@ +{"meta":{"format_version":"4.5","model_format":"java_block","box_uv":false},"name":"clam_shell_4","parent":"","ambientocclusion":true,"front_gui_light":false,"visible_box":[1,1,0],"variable_placeholders":"","variable_placeholder_buttons":[],"unhandled_root_fields":{},"resolution":{"width":16,"height":16},"elements":[{"name":"cube","box_uv":false,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[8,0.5,0.6000000000000014],"to":[16,0.5,8.600000000000001],"autouv":0,"color":9,"rotation":[22.5,0,0],"origin":[12,0.5,3],"faces":{"north":{"uv":[0,0,8,0],"texture":null},"east":{"uv":[0,0,8,0],"texture":null},"south":{"uv":[0,0,8,0],"texture":null},"west":{"uv":[0,0,8,0],"texture":null},"up":{"uv":[0,0,16,16],"rotation":270,"texture":0},"down":{"uv":[16,0,0,16],"rotation":270,"texture":0}},"type":"cube","uuid":"1c53fe40-1877-60c2-80b2-135dff0afe56"},{"name":"cube","box_uv":false,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[0.3640158355865708,0,7.022858234660681],"to":[8.36401583558657,0,15.022858234660681],"autouv":0,"color":9,"rotation":[22.5,0,0],"origin":[4.364015835586571,0,11.022858234660681],"faces":{"north":{"uv":[0,0,8,0],"texture":null},"east":{"uv":[0,0,8,0],"texture":null},"south":{"uv":[0,0,8,0],"texture":null},"west":{"uv":[0,0,8,0],"texture":null},"up":{"uv":[0,0,16,16],"rotation":270,"texture":0},"down":{"uv":[16,0,0,16],"rotation":270,"texture":0}},"type":"cube","uuid":"f8ee1a59-5c1f-ddd7-783f-bb14a40c36a2"},{"name":"cube","box_uv":false,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[7.755052095676865,0,8.084325693581398],"to":[15.755052095676865,0,16.0843256935814],"autouv":0,"color":9,"rotation":[-22.5,0,0],"origin":[11.755052095676865,0,12.0843256935814],"faces":{"north":{"uv":[0,0,8,0],"texture":null},"east":{"uv":[0,0,8,0],"texture":null},"south":{"uv":[0,0,8,0],"texture":null},"west":{"uv":[0,0,8,0],"texture":null},"up":{"uv":[0,0,16,16],"rotation":90,"texture":0},"down":{"uv":[0,16,16,0],"rotation":270,"texture":0}},"type":"cube","uuid":"a13cf19e-6339-91b6-4d9b-0d3500abf734"},{"name":"cube","box_uv":false,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[1.3640158355865708,0,0.022858234660681376],"to":[9.36401583558657,0,8.022858234660681],"autouv":0,"color":9,"rotation":[0,0,22.5],"origin":[5.364015835586571,0,4.022858234660681],"faces":{"north":{"uv":[0,0,8,0],"texture":null},"east":{"uv":[0,0,8,0],"texture":null},"south":{"uv":[0,0,8,0],"texture":null},"west":{"uv":[0,0,8,0],"texture":null},"up":{"uv":[0,0,16,16],"rotation":180,"texture":0},"down":{"uv":[0,16,16,0],"rotation":180,"texture":0}},"type":"cube","uuid":"60843fa4-6abd-3b89-20f7-67fc05e29ba3"}],"outliner":["1c53fe40-1877-60c2-80b2-135dff0afe56","f8ee1a59-5c1f-ddd7-783f-bb14a40c36a2","60843fa4-6abd-3b89-20f7-67fc05e29ba3","a13cf19e-6339-91b6-4d9b-0d3500abf734"],"textures":[{"path":"/home/sollace/Documents/GitRepos/minecraft_mods/Unicopia/src/main/resources/assets/unicopia/textures/item/clam_shell.png","name":"clam_shell.png","folder":"item","namespace":"unicopia","id":"shell","particle":true,"render_mode":"default","render_sides":"auto","frame_time":1,"frame_order_type":"loop","frame_order":"","frame_interpolate":false,"visible":true,"mode":"bitmap","saved":true,"uuid":"1a1accdc-ffd7-c20a-9047-a5db72ecf496","relative_path":"../../../src/main/resources/assets/unicopia/textures/item/clam_shell.png","source":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAihJREFUOE+l09tL02Ecx/H3+C3XDr9y+21Yk9lhbWyyxYg8BFoXkXRYQlQEi6CCLosg6H+IoIu6CIoIDaKgjPJGwhBUQqVINHYo+0XqXB6mzsPSxm9PYLIQMwifywc+L57vh+erY51Ht848/wQaW9+LzFSaYrsDq8OBGo9y5VTdisxfgdtPW4Sy1UltbZBFQAJsQErT+BJXCQe8hdwq4O6LNrGnJkCp3U5/NFqYsAxILCwwPZ7j4uHqtYGXvb3CqGlYDAasPh8+SUJdZjpa33H+UMXaIzxq+yC8pp/YKyuxAKP9/ej1ejKZDB0D37l+7sSqF6+4eNYTFaEKPzpVJZ/P8zlnIZfLUb/bxafhEVre9uELedA0E0fLnUvZAvCks084t5WhzCRxuVykZBnt8iv8d+oLPWRuqLDRTKOzj9Id2zlZ4dUtATcfNgnbJoHX70dSdrHvwSBjCAzGzeApQj4ik23KoqkTsDiHGs4RzxYRqQksAw3PhVJiR7bacClGJIsFz60EmlFGMphB2gCzEwydMeJ2u3kTizEzJ3H2QOg30PC6RyhbrKRGktgUJwf3eoh3dzNtMuExm5mfnycYDNLV1cXO6mraexKcrvL96eBec7tIqgNYHSVcjRzTPe78KIptNjxuBf3kJD9kmfFEgrJQCPXbLIMDCS7UVa0s8X5zu7h0fH+h1O60EF9jUdyBckaHU4yNDIHIM5VOcy0SXvsj/e9yrXsbfwHRlcQRuWinHQAAAABJRU5ErkJggg=="}]} \ No newline at end of file diff --git a/assets/models/cloud_chest.bbmodel b/assets/models/cloud_chest.bbmodel new file mode 100644 index 00000000..bdafb853 --- /dev/null +++ b/assets/models/cloud_chest.bbmodel @@ -0,0 +1 @@ +{"meta":{"format_version":"4.5","model_format":"modded_entity","box_uv":true},"name":"cloud_chest","model_identifier":"","modded_entity_version":"Fabric 1.17+","modded_entity_flip_y":true,"visible_box":[1,1,0],"variable_placeholders":"","variable_placeholder_buttons":[],"unhandled_root_fields":{},"resolution":{"width":64,"height":64},"elements":[{"name":"chest","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-7,0,-7],"to":[7,10,7],"autouv":0,"color":0,"origin":[0,0,0],"uv_offset":[0,19],"faces":{"north":{"uv":[14,33,28,43],"texture":0},"east":{"uv":[0,33,14,43],"texture":0},"south":{"uv":[42,33,56,43],"texture":0},"west":{"uv":[28,33,42,43],"texture":0},"up":{"uv":[28,33,14,19],"texture":0},"down":{"uv":[42,19,28,33],"texture":0}},"type":"cube","uuid":"980d20de-fc20-da45-2218-55df01317a6a"},{"name":"lock","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-1,6,6.800000000000001],"to":[1,10,7.800000000000001],"autouv":0,"color":0,"origin":[0,0,-0.20000000000000004],"faces":{"north":{"uv":[1,1,3,5],"texture":0},"east":{"uv":[0,1,1,5],"texture":0},"south":{"uv":[4,1,6,5],"texture":0},"west":{"uv":[3,1,4,5],"texture":0},"up":{"uv":[3,1,1,0],"texture":0},"down":{"uv":[5,0,3,1],"texture":0}},"type":"cube","uuid":"daa8bcc6-6f9e-aa77-77d6-a2132c7efdb0"},{"name":"lock","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-1,7,7],"to":[1,9,8],"autouv":0,"color":0,"origin":[0,0,0],"faces":{"north":{"uv":[1,1,3,3],"texture":0},"east":{"uv":[0,1,1,3],"texture":0},"south":{"uv":[4,1,6,3],"texture":0},"west":{"uv":[3,1,4,3],"texture":0},"up":{"uv":[3,1,1,0],"texture":0},"down":{"uv":[5,0,3,1],"texture":0}},"type":"cube","uuid":"3761dece-0deb-4f9f-03b8-7179e5d4230d"},{"name":"lock","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[2,7,6.8],"to":[4,11,7.8],"autouv":0,"color":0,"rotation":[0,0,90],"origin":[1.9999999999999998,7,7.300000000000001],"faces":{"north":{"uv":[1,1,3,5],"texture":0},"east":{"uv":[0,1,1,5],"texture":0},"south":{"uv":[4,1,6,5],"texture":0},"west":{"uv":[3,1,4,5],"texture":0},"up":{"uv":[3,1,1,0],"texture":0},"down":{"uv":[5,0,3,1],"texture":0}},"type":"cube","uuid":"2d515302-358d-138a-85df-aec20530862a"},{"name":"lid","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-7,8,-7],"to":[7,13,7],"autouv":0,"color":0,"inflate":0.3,"origin":[0,0,0],"faces":{"north":{"uv":[14,14,28,19],"texture":0},"east":{"uv":[0,14,14,19],"texture":0},"south":{"uv":[42,14,56,19],"texture":0},"west":{"uv":[28,14,42,19],"texture":0},"up":{"uv":[28,14,14,0],"texture":0},"down":{"uv":[42,0,28,14],"texture":0}},"type":"cube","uuid":"07486e85-57dd-1353-ef68-fd182245f73d"}],"outliner":["980d20de-fc20-da45-2218-55df01317a6a",{"name":"lid","origin":[0,8,-7],"rotation":[-62.5,0,0],"color":0,"uuid":"426e7ac7-0b4a-e1da-2265-dd376403fc38","export":true,"mirror_uv":false,"isOpen":true,"locked":false,"visibility":true,"autouv":0,"children":["daa8bcc6-6f9e-aa77-77d6-a2132c7efdb0","3761dece-0deb-4f9f-03b8-7179e5d4230d","2d515302-358d-138a-85df-aec20530862a","07486e85-57dd-1353-ef68-fd182245f73d"]}],"textures":[{"path":"/home/sollace/Documents/GitRepos/minecraft_mods/Unicopia/assets/models/cloud_chest.png","name":"cloud_chest.png","folder":"","namespace":"","id":"0","particle":false,"render_mode":"default","render_sides":"auto","frame_time":1,"frame_order_type":"loop","frame_order":"","frame_interpolate":false,"visible":true,"mode":"bitmap","saved":true,"uuid":"2a8b98ee-b258-1d91-ab10-ed99b792b5ed","relative_path":"../cloud_chest.png","source":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAAAXNSR0IArs4c6QAABTZJREFUeF7tWsuOG0UUvWbGscfjeDAzhAkwRApRUCQWkAhFSrJjwxo+gA1/gPgClog/YMOSBVmzYUeQAPFYIEWJAlKYvDMzThyPY489MTrdHHNdqe6ubtqOa+jatKv6VtU9p869XV3ukojIr/e7I1z/bD3GRT44uVoKfsSUj7+9FvSZVfn83ROJPmXxpQTwBH68uTQe4+0Xa7ETgoBavZ5qzm6nE9hf2Gim6vfdZkumRsDXV7fHK7mydEhWqwuy2x/KhVcbzgQsVw49BWi3vye6HfUkAl5rVOSvdl9wZUF9pgRUSyO52x0khgEVQJAAaBbcIxEmAW+u1aS9tz8BFMB7wydypFaWe91BcA/XmRGgASTlAU0AwZsrnkQAQRKwvhL81AlIFYzK2CRAK8EEzroOASgA4ACaYPXKcypvCNBEpiFA9zsQCiAgHftRCrCpj6qYWQ7IMwTMRBiXAyj9uPlh8/tWd7pJME8CbGPFPQV0nNvk7xUBcUTGJUH2M58EaPeGABcV2fYB+imgnwR6vLkPARfwtEnaCUaNNdWNUBoA2vbAvAx99sPmTN/qshIe1a8t4UaqIeHW2SyfnN2IfacpgYATzdq437VWV5LqzcqitPrDwM60tzlBG1x1X9q6zAlbm1+/tELgp5vlp3zBuIkEfPPHzuhwZVEe9YficsVktzr9CZwv1yvjNvzWNvoeO9HGdU7Yodj8047Yxnvv9RfiFXDpRjsIAYCiY0l1M3vb7KPatMNp5mQ/Wx/ci/L9fMJrfWnWySzvHJA0XtJBSuZjpq+u7GRKnj/e2Eny2Xo/CUimQUXkPxFwt/VAHvbC+NRlpbpobT95dE1AQK28IMcaVSefr7d70h3sT+9IzMkLixEUAAJQNAkAz8J2tr3UfD4g4NTqsgwH9seWOdViuSyXt3fnlwANMuo3SaICQIBLAUlzTcDV21sBDtuq20JCE0BwWgkAyzp/e0FAVA4wc0EUAQCpiyZn7gkwQVINCAfzt5kD9CrbVn7uQ4BJ0JYISYBOkHEK8JIA5ACtgKjHH9sPZAgwdm3SpzKiHoM66cF26bmRPH4Sbk28SYJRCrC12xQQ9zj0NgdEgTIJsNlRBd4qQO8Czf3BgdsKu+zmTJu5exny5XU47bcIJP7Ts+vxByIgQH+wgBNYW7HZ6Lbt7l7w0qIL9vyrtX+/HeDYWedzfYegDy4vUcGBiOnQ+28ckcF++N99eWFBLl65N/FVhw0Iz/X6g6FUyuEboXnWp/uBMJCDtqj5tA3GM78saT/qSKUavlb3ez1pHJ78YsXlOH1MgD64PPfKygQB3998OHEAqoEAMMpmZy+wYR0kYMyNeqgA1HW/rPNpheVOAAYHeBStANRBAgpAEsh6vTI+qdWrTRXoNvy+889hKlYS9bTz2b4tAgko5uqjLZUCKNl31u0fPv10pzMGi4ERj6fWlsfEkBxTAVwxEHt5azfIEwQCElzns4WANVmpRmcCsJIocAYxb1MAFAESULCSJIDzMUzMHEBFwY4EcD4z1Mx5qToqh/30/wM2Eqgu9Es6Syx98dvtEVYSAAFeXzG42YY6gKDofpoAxjwcIcioflnm40JEKYALCT8/euto/GMwigA9uElOHAG6XxoCXOejXRxxtHEi4Mufr2c63k6Kv3m5/+GZY/EKmBdHn5Ufmf8XeFYO5z1vQUDejPo2XqEA31Ysb38LBeTNqG/jFQrwbcXy9rdQQN6M+jZeoQDfVixvfwsF5M2ob+MVCvBtxfL2t1BA3oz6Nt7/XgF/A20YIoxeFupUAAAAAElFTkSuQmCC"}],"fabricOptions":{"header":"package com.example.mod;","entity":"Entity","render":"","members":""}} \ No newline at end of file diff --git a/assets/models/cloud_chest.java b/assets/models/cloud_chest.java new file mode 100644 index 00000000..87e684a2 --- /dev/null +++ b/assets/models/cloud_chest.java @@ -0,0 +1,32 @@ +// Made with Blockbench 4.8.3 +// Exported for Minecraft version 1.17+ for Yarn +// Paste this class into your mod and generate all required imports +public class cloud_chest extends EntityModel { + private final ModelPart lid; + private final ModelPart lock_r1; + private final ModelPart bb_main; + public cloud_chest(ModelPart root) { + this.lid = root.getChild("lid"); + this.bb_main = root.getChild("bb_main"); + } + public static TexturedModelData getTexturedModelData() { + ModelData modelData = new ModelData(); + ModelPartData modelPartData = modelData.getRoot(); + ModelPartData lid = modelPartData.addChild("lid", ModelPartBuilder.create().uv(0, 0).cuboid(-1.0F, -2.0F, 13.8F, 2.0F, 4.0F, 1.0F, new Dilation(0.0F)) + .uv(0, 0).cuboid(-1.0F, -1.0F, 14.0F, 2.0F, 2.0F, 1.0F, new Dilation(0.0F)) + .uv(0, 0).cuboid(-7.0F, -5.0F, 0.0F, 14.0F, 5.0F, 14.0F, new Dilation(0.3F)), ModelTransform.of(0.0F, 16.0F, -7.0F, 1.0908F, 0.0F, 0.0F)); + + ModelPartData lock_r1 = lid.addChild("lock_r1", ModelPartBuilder.create().uv(0, 0).cuboid(-2.0F, -4.0F, -0.5F, 2.0F, 4.0F, 1.0F, new Dilation(0.0F)), ModelTransform.of(-2.0F, 1.0F, 14.3F, 0.0F, 0.0F, 1.5708F)); + + ModelPartData bb_main = modelPartData.addChild("bb_main", ModelPartBuilder.create().uv(0, 19).cuboid(-7.0F, -10.0F, -7.0F, 14.0F, 10.0F, 14.0F, new Dilation(0.0F)), ModelTransform.pivot(0.0F, 24.0F, 0.0F)); + return TexturedModelData.of(modelData, 64, 64); + } + @Override + public void setAngles(Entity entity, float limbSwing, float limbSwingAmount, float ageInTicks, float netHeadYaw, float headPitch) { + } + @Override + public void render(MatrixStack matrices, VertexConsumer vertexConsumer, int light, int overlay, float red, float green, float blue, float alpha) { + lid.render(matrices, vertexConsumer, light, overlay, red, green, blue, alpha); + bb_main.render(matrices, vertexConsumer, light, overlay, red, green, blue, alpha); + } +} \ No newline at end of file diff --git a/assets/models/cloud_chest.png b/assets/models/cloud_chest.png new file mode 100644 index 00000000..e06ba84a Binary files /dev/null and b/assets/models/cloud_chest.png differ diff --git a/src/main/java/com/minelittlepony/unicopia/Availability.java b/src/main/java/com/minelittlepony/unicopia/Availability.java new file mode 100644 index 00000000..f24497a3 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/Availability.java @@ -0,0 +1,15 @@ +package com.minelittlepony.unicopia; + +public enum Availability { + DEFAULT, + COMMANDS, + NONE; + + public boolean isSelectable() { + return this == DEFAULT; + } + + public boolean isGrantable() { + return this != NONE; + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/Debug.java b/src/main/java/com/minelittlepony/unicopia/Debug.java index ff142889..2e5a9982 100644 --- a/src/main/java/com/minelittlepony/unicopia/Debug.java +++ b/src/main/java/com/minelittlepony/unicopia/Debug.java @@ -1,9 +1,11 @@ package com.minelittlepony.unicopia; +import com.minelittlepony.unicopia.ability.magic.spell.trait.SpellTraits; import com.minelittlepony.unicopia.entity.mob.AirBalloonEntity; import com.minelittlepony.unicopia.entity.mob.UEntities; import net.minecraft.entity.vehicle.BoatEntity; +import net.minecraft.registry.Registries; import net.minecraft.world.World; public interface Debug { @@ -18,6 +20,16 @@ public interface Debug { } TESTS_COMPLETE[0] = true; + try { + Registries.ITEM.getEntrySet().forEach(entry -> { + if (SpellTraits.of(entry.getValue()).isEmpty()) { + // Unicopia.LOGGER.warn("No traits registered for item {}", entry.getKey()); + } + }); + } catch (Throwable t) { + throw new IllegalStateException("Tests failed", t); + } + try { for (var type : BoatEntity.Type.values()) { var balloon = UEntities.AIR_BALLOON.create(world); diff --git a/src/main/java/com/minelittlepony/unicopia/EquinePredicates.java b/src/main/java/com/minelittlepony/unicopia/EquinePredicates.java index 0771db9d..be559b38 100644 --- a/src/main/java/com/minelittlepony/unicopia/EquinePredicates.java +++ b/src/main/java/com/minelittlepony/unicopia/EquinePredicates.java @@ -27,6 +27,7 @@ public interface EquinePredicates { Predicate PLAYER_CHANGELING = IS_PLAYER.and(ofRace(Race.CHANGELING)); Predicate PLAYER_KIRIN = IS_PLAYER.and(ofRace(Race.KIRIN)); Predicate PLAYER_PEGASUS = IS_PLAYER.and(e -> ((PlayerEntity)e).getAbilities().creativeMode || RACE_INTERACT_WITH_CLOUDS.test(e)); + Predicate PLAYER_SEAPONY = IS_PLAYER.and(raceMatches(Race::isFish)); Predicate PLAYER_CAN_USE_EARTH = IS_PLAYER.and(raceMatches(Race::canUseEarth)); Predicate IS_CASTER = e -> !e.isRemoved() && (e instanceof Caster || IS_PLAYER.test(e)); diff --git a/src/main/java/com/minelittlepony/unicopia/Race.java b/src/main/java/com/minelittlepony/unicopia/Race.java index e45fec10..ac63cfff 100644 --- a/src/main/java/com/minelittlepony/unicopia/Race.java +++ b/src/main/java/com/minelittlepony/unicopia/Race.java @@ -24,37 +24,44 @@ import net.minecraft.util.Identifier; import net.minecraft.registry.Registry; import net.minecraft.registry.RegistryKey; -public record Race (Supplier compositeSupplier, boolean canCast, FlightType flightType, boolean canUseEarth, boolean isNocturnal, boolean canHang) implements Affine { +public record Race (Supplier compositeSupplier, Availability availability, boolean canCast, FlightType flightType, boolean canUseEarth, boolean isNocturnal, boolean canHang) implements Affine { public static final String DEFAULT_ID = "unicopia:unset"; public static final Registry REGISTRY = RegistryUtils.createDefaulted(Unicopia.id("race"), DEFAULT_ID); + public static final Registry COMMAND_REGISTRY = RegistryUtils.createDefaulted(Unicopia.id("race/grantable"), DEFAULT_ID); public static final RegistryKey> REGISTRY_KEY = REGISTRY.getKey(); private static final DynamicCommandExceptionType UNKNOWN_RACE_EXCEPTION = new DynamicCommandExceptionType(id -> Text.translatable("race.unknown", id)); - public static Race register(String name, boolean magic, FlightType flight, boolean earth, boolean nocturnal, boolean canHang) { - return register(Unicopia.id(name), magic, flight, earth, nocturnal, canHang); + public static Race register(String name, Availability availability, boolean magic, FlightType flight, boolean earth, boolean nocturnal, boolean canHang) { + return register(Unicopia.id(name), availability, magic, flight, earth, nocturnal, canHang); } - public static Race register(Identifier id, boolean magic, FlightType flight, boolean earth, boolean nocturnal, boolean canHang) { - return Registry.register(REGISTRY, id, new Race(Suppliers.memoize(() -> new Composite(REGISTRY.get(id), null)), magic, flight, earth, nocturnal, canHang)); + public static Race register(Identifier id, Availability availability, boolean magic, FlightType flight, boolean earth, boolean nocturnal, boolean canHang) { + Race race = Registry.register(REGISTRY, id, new Race(Suppliers.memoize(() -> new Composite(REGISTRY.get(id), null, null)), availability, magic, flight, earth, nocturnal, canHang)); + if (availability.isGrantable()) { + Registry.register(COMMAND_REGISTRY, id, race); + } + return race; } public static RegistryKeyArgumentType argument() { - return RegistryKeyArgumentType.registryKey(REGISTRY_KEY); + return RegistryKeyArgumentType.registryKey(COMMAND_REGISTRY.getKey()); } /** * The default, unset race. * This is used if there are no other races. */ - public static final Race UNSET = register("unset", false, FlightType.NONE, false, false, false); - public static final Race HUMAN = register("human", false, FlightType.NONE, false, false, false); - public static final Race EARTH = register("earth", false, FlightType.NONE, true, false, false); - public static final Race UNICORN = register("unicorn", true, FlightType.NONE, false, false, false); - public static final Race PEGASUS = register("pegasus", false, FlightType.AVIAN, false, false, false); - public static final Race BAT = register("bat", false, FlightType.AVIAN, false, true, true); - public static final Race ALICORN = register("alicorn", true, FlightType.AVIAN, true, false, false); - public static final Race CHANGELING = register("changeling", false, FlightType.INSECTOID, false, false, true); - public static final Race KIRIN = register("kirin", true, FlightType.NONE, false, false, false); + public static final Race UNSET = register("unset", Availability.COMMANDS, false, FlightType.NONE, false, false, false); + public static final Race HUMAN = register("human", Availability.COMMANDS, false, FlightType.NONE, false, false, false); + public static final Race EARTH = register("earth", Availability.DEFAULT, false, FlightType.NONE, true, false, false); + public static final Race UNICORN = register("unicorn", Availability.DEFAULT, true, FlightType.NONE, false, false, false); + public static final Race PEGASUS = register("pegasus", Availability.DEFAULT, false, FlightType.AVIAN, false, false, false); + public static final Race BAT = register("bat", Availability.DEFAULT, false, FlightType.AVIAN, false, true, true); + public static final Race ALICORN = register("alicorn", Availability.COMMANDS, true, FlightType.AVIAN, true, false, false); + public static final Race CHANGELING = register("changeling", Availability.DEFAULT, false, FlightType.INSECTOID, false, false, true); + public static final Race KIRIN = register("kirin", Availability.DEFAULT, true, FlightType.NONE, false, false, false); + public static final Race HIPPOGRIFF = register("hippogriff", Availability.DEFAULT, false, FlightType.AVIAN, false, false, false); + public static final Race SEAPONY = register("seapony", Availability.NONE, false, FlightType.NONE, false, false, false); public static void bootstrap() {} @@ -62,8 +69,8 @@ public record Race (Supplier compositeSupplier, boolean canCast, Flig return compositeSupplier.get(); } - public Composite composite(@Nullable Race pseudo) { - return pseudo == null ? composite() : new Composite(this, pseudo); + public Composite composite(@Nullable Race pseudo, @Nullable Race potential) { + return pseudo == null && potential == null ? composite() : new Composite(this, pseudo, potential); } @Override @@ -83,6 +90,10 @@ public record Race (Supplier compositeSupplier, boolean canCast, Flig return !isHuman(); } + public boolean isFish() { + return this == SEAPONY; + } + public boolean isHuman() { return this == UNSET || this == HUMAN; } @@ -91,16 +102,12 @@ public record Race (Supplier compositeSupplier, boolean canCast, Flig return !isNocturnal(); } - public boolean isOp() { - return this == ALICORN; - } - public boolean canFly() { return !flightType().isGrounded(); } public boolean canInteractWithClouds() { - return canFly() && this != CHANGELING && this != BAT; + return canFly() && this != CHANGELING && this != BAT && this != HIPPOGRIFF; } public Identifier getId() { @@ -145,6 +152,10 @@ public record Race (Supplier compositeSupplier, boolean canCast, Flig return this; } + public Race or(Race other) { + return isEquine() ? this : other; + } + @Override public int hashCode() { return getId().hashCode(); @@ -192,7 +203,7 @@ public record Race (Supplier compositeSupplier, boolean canCast, Flig return REGISTRY.stream().filter(r -> r.isPermitted(player)).collect(Collectors.toSet()); } - public record Composite (Race physical, @Nullable Race pseudo) { + public record Composite (Race physical, @Nullable Race pseudo, @Nullable Race potential) { public Race collapsed() { return pseudo == null ? physical : pseudo; } diff --git a/src/main/java/com/minelittlepony/unicopia/UPOIs.java b/src/main/java/com/minelittlepony/unicopia/UPOIs.java new file mode 100644 index 00000000..3a7b07e4 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/UPOIs.java @@ -0,0 +1,16 @@ +package com.minelittlepony.unicopia; + +import net.fabricmc.fabric.api.object.builder.v1.world.poi.PointOfInterestHelper; +import net.minecraft.block.AbstractChestBlock; +import net.minecraft.block.Block; +import net.minecraft.registry.Registries; +import net.minecraft.world.poi.PointOfInterestType; + +public interface UPOIs { + PointOfInterestType CHESTS = PointOfInterestHelper.register(Unicopia.id("chests"), 1, 64, Registries.BLOCK.getEntrySet().stream() + .map(entry -> entry.getValue()) + .filter(b -> b instanceof AbstractChestBlock) + .toArray(Block[]::new)); + + static void bootstrap() { } +} diff --git a/src/main/java/com/minelittlepony/unicopia/USounds.java b/src/main/java/com/minelittlepony/unicopia/USounds.java index 34d9beff..23980e16 100644 --- a/src/main/java/com/minelittlepony/unicopia/USounds.java +++ b/src/main/java/com/minelittlepony/unicopia/USounds.java @@ -14,6 +14,8 @@ public interface USounds { SoundEvent ENTITY_PLAYER_CORRUPTION = PARTICLE_SOUL_ESCAPE; SoundEvent ENTITY_PLAYER_BATPONY_SCREECH = register("entity.player.batpony.screech"); + SoundEvent ENTITY_PLAYER_HIPPOGRIFF_SCREECH = register("entity.player.hippogriff.screech"); + SoundEvent ENTITY_PLAYER_HIPPOGRIFF_PECK = ENTITY_CHICKEN_STEP; SoundEvent ENTITY_PLAYER_REBOUND = register("entity.player.rebound"); SoundEvent ENTITY_PLAYER_PEGASUS_WINGSFLAP = register("entity.player.pegasus.wingsflap"); SoundEvent ENTITY_PLAYER_PEGASUS_FLYING = register("entity.player.pegasus.flying"); @@ -27,6 +29,7 @@ public interface USounds { SoundEvent ENTITY_PLAYER_UNICORN_TELEPORT = register("entity.player.unicorn.teleport"); SoundEvent ENTITY_PLAYER_KIRIN_RAGE = ENTITY_POLAR_BEAR_WARNING; SoundEvent ENTITY_PLAYER_KIRIN_RAGE_LOOP = register("entity.player.kirin.rage.loop"); + SoundEvent ENTITY_PLAYER_SEAPONY_SONAR = register("entity.player.seapony.sonar", 64); SoundEvent ENTITY_PLAYER_EARS_RINGING = register("entity.player.ears_ring"); SoundEvent ENTITY_PLAYER_HEARTBEAT = register("entity.player.heartbeat"); @@ -146,6 +149,11 @@ public interface USounds { return Registry.register(Registries.SOUND_EVENT, id, SoundEvent.of(id)); } + static SoundEvent register(String name, float range) { + Identifier id = Unicopia.id(name); + return Registry.register(Registries.SOUND_EVENT, id, SoundEvent.of(id, range)); + } + static void bootstrap() {} static final class Vanilla extends SoundEvents {} diff --git a/src/main/java/com/minelittlepony/unicopia/UTags.java b/src/main/java/com/minelittlepony/unicopia/UTags.java index c6ba480c..91b4fcae 100644 --- a/src/main/java/com/minelittlepony/unicopia/UTags.java +++ b/src/main/java/com/minelittlepony/unicopia/UTags.java @@ -1,7 +1,5 @@ package com.minelittlepony.unicopia; -import com.minelittlepony.unicopia.item.toxin.Toxics; - import net.minecraft.block.Block; import net.minecraft.entity.EntityType; import net.minecraft.entity.damage.DamageType; @@ -27,6 +25,7 @@ public interface UTags { TagKey SPOOKED_MOB_DROPS = item("spooked_mob_drops"); TagKey IS_DELIVERED_AGGRESSIVELY = item("is_delivered_aggressively"); TagKey FLOATS_ON_CLOUDS = item("floats_on_clouds"); + TagKey COOLS_OFF_KIRINS = item("cools_off_kirins"); TagKey POLEARMS = item("polearms"); TagKey HORSE_SHOES = item("horse_shoes"); @@ -78,8 +77,4 @@ public interface UTags { static TagKey dimension(String name) { return TagKey.of(RegistryKeys.DIMENSION_TYPE, new Identifier("c", name)); } - - static void bootstrap() { - Toxics.bootstrap(); - } } diff --git a/src/main/java/com/minelittlepony/unicopia/Unicopia.java b/src/main/java/com/minelittlepony/unicopia/Unicopia.java index 28922b79..03e48838 100644 --- a/src/main/java/com/minelittlepony/unicopia/Unicopia.java +++ b/src/main/java/com/minelittlepony/unicopia/Unicopia.java @@ -22,6 +22,8 @@ import com.minelittlepony.unicopia.command.Commands; import com.minelittlepony.unicopia.compat.trinkets.TrinketsDelegate; import com.minelittlepony.unicopia.container.SpellbookChapterLoader; import com.minelittlepony.unicopia.container.UScreenHandlers; +import com.minelittlepony.unicopia.diet.DietsLoader; +import com.minelittlepony.unicopia.diet.affliction.AfflictionType; import com.minelittlepony.unicopia.entity.damage.UDamageTypes; import com.minelittlepony.unicopia.entity.effect.UPotions; import com.minelittlepony.unicopia.entity.mob.UEntities; @@ -64,7 +66,6 @@ public class Unicopia implements ModInitializer { @Override public void onInitialize() { Channel.bootstrap(); - UTags.bootstrap(); UCriteria.bootstrap(); UEntities.bootstrap(); Commands.bootstrap(); @@ -83,20 +84,18 @@ public class Unicopia implements ModInitializer { }); NocturnalSleepManager.bootstrap(); - ResourceManagerHelper.get(ResourceType.SERVER_DATA).registerReloadListener(TreeTypeLoader.INSTANCE); - ResourceManagerHelper.get(ResourceType.SERVER_DATA).registerReloadListener(UEnchantments.POISONED_JOKE); - ResourceManagerHelper.get(ResourceType.SERVER_DATA).registerReloadListener(new TraitLoader()); - ResourceManagerHelper.get(ResourceType.SERVER_DATA).registerReloadListener(StateMapLoader.INSTANCE); - ResourceManagerHelper.get(ResourceType.SERVER_DATA).registerReloadListener(SpellbookChapterLoader.INSTANCE); + registerServerDataReloaders(ResourceManagerHelper.get(ResourceType.SERVER_DATA)); UGameEvents.bootstrap(); UBlocks.bootstrap(); + UPOIs.bootstrap(); UItems.bootstrap(); UPotions.bootstrap(); UParticles.bootstrap(); USounds.bootstrap(); Race.bootstrap(); SpellType.bootstrap(); + AfflictionType.bootstrap(); Abilities.bootstrap(); UScreenHandlers.bootstrap(); UWorldGen.bootstrap(); @@ -104,6 +103,15 @@ public class Unicopia implements ModInitializer { UDamageTypes.bootstrap(); } + private void registerServerDataReloaders(ResourceManagerHelper registry) { + registry.registerReloadListener(TreeTypeLoader.INSTANCE); + registry.registerReloadListener(UEnchantments.POISONED_JOKE); + registry.registerReloadListener(new TraitLoader()); + registry.registerReloadListener(StateMapLoader.INSTANCE); + registry.registerReloadListener(SpellbookChapterLoader.INSTANCE); + registry.registerReloadListener(new DietsLoader()); + } + public interface SidedAccess { Optional getPony(); diff --git a/src/main/java/com/minelittlepony/unicopia/UnicopiaMixinPlugin.java b/src/main/java/com/minelittlepony/unicopia/UnicopiaMixinPlugin.java index 48dcf6b7..df5394d9 100644 --- a/src/main/java/com/minelittlepony/unicopia/UnicopiaMixinPlugin.java +++ b/src/main/java/com/minelittlepony/unicopia/UnicopiaMixinPlugin.java @@ -35,6 +35,9 @@ public class UnicopiaMixinPlugin implements IMixinConfigPlugin { if (mixinClassName.indexOf("ad_astra") != -1) { return FabricLoader.getInstance().isModLoaded("ad_astra"); } + if (mixinClassName.indexOf("minelp") != -1) { + return FabricLoader.getInstance().isModLoaded("minelp"); + } } return true; } diff --git a/src/main/java/com/minelittlepony/unicopia/ability/Abilities.java b/src/main/java/com/minelittlepony/unicopia/ability/Abilities.java index 9dd0d724..39b66b8f 100644 --- a/src/main/java/com/minelittlepony/unicopia/ability/Abilities.java +++ b/src/main/java/com/minelittlepony/unicopia/ability/Abilities.java @@ -24,6 +24,9 @@ public interface Abilities { .toList(); }); + // all races + Ability CHANGE_FORM = register(new ChangeFormAbility(), "change_form", AbilitySlot.PRIMARY); + // unicorn / alicorn Ability CAST = register(new UnicornCastingAbility(), "cast", AbilitySlot.PRIMARY); Ability SHOOT = register(new UnicornProjectileAbility(), "shoot", AbilitySlot.PRIMARY); @@ -42,9 +45,14 @@ public interface Abilities { Ability RAINBOOM = register(new PegasusRainboomAbility(), "rainboom", AbilitySlot.PRIMARY); Ability CAPTURE_CLOUD = register(new PegasusCaptureStormAbility(), "capture_cloud", AbilitySlot.SECONDARY); - // pegasus / bat / alicorn / changeling + // hippogriff + Ability DASH = register(new FlyingDashAbility(), "dash", AbilitySlot.PRIMARY); + Ability SCREECH = register(new ScreechAbility(), "screech", AbilitySlot.SECONDARY); + Ability PECK = register(new PeckAbility(), "peck", AbilitySlot.SECONDARY); + + // pegasus / bat / alicorn / changeling / hippogriff Ability CARRY = register(new CarryAbility(), "carry", AbilitySlot.PRIMARY); - Ability TOGGLE_FLIGHT = register(new PegasusFlightToggleAbility(), "toggle_flight", AbilitySlot.TERTIARY); + Ability TOGGLE_FLIGHT = register(new ToggleFlightAbility(), "toggle_flight", AbilitySlot.TERTIARY); // changeling Ability DISGUISE = register(new ChangelingDisguiseAbility(), "disguise", AbilitySlot.SECONDARY); @@ -59,6 +67,9 @@ public interface Abilities { Ability NIRIK_BLAST = register(new NirikBlastAbility(), "nirik_blast", AbilitySlot.SECONDARY); Ability KIRIN_CAST = register(new KirinCastingAbility(), "kirin_cast", AbilitySlot.SECONDARY); + // seapony + Ability SONAR_PULSE = register(new SeaponySonarPulseAbility(), "sonar_pulse", AbilitySlot.SECONDARY); + static > T register(T power, String name, AbilitySlot slot) { Identifier id = Unicopia.id(name); BY_SLOT.computeIfAbsent(slot, s -> new LinkedHashSet<>()).add(power); diff --git a/src/main/java/com/minelittlepony/unicopia/ability/AbilityDispatcher.java b/src/main/java/com/minelittlepony/unicopia/ability/AbilityDispatcher.java index 14bb8370..d9a977b4 100644 --- a/src/main/java/com/minelittlepony/unicopia/ability/AbilityDispatcher.java +++ b/src/main/java/com/minelittlepony/unicopia/ability/AbilityDispatcher.java @@ -179,6 +179,10 @@ public class AbilityDispatcher implements Tickable, NbtSerialisable { return; } + if (cooldown > 100 && player.asEntity().isCreative()) { + cooldown = Math.max(10, cooldown - 100); + } + if (cooldown > 0 && cooldown-- > 0) { ability.coolDown(player, slot); diff --git a/src/main/java/com/minelittlepony/unicopia/ability/BatEeeeAbility.java b/src/main/java/com/minelittlepony/unicopia/ability/BatEeeeAbility.java index f2ad4e28..0b0d1b4e 100644 --- a/src/main/java/com/minelittlepony/unicopia/ability/BatEeeeAbility.java +++ b/src/main/java/com/minelittlepony/unicopia/ability/BatEeeeAbility.java @@ -1,55 +1,20 @@ package com.minelittlepony.unicopia.ability; -import java.util.Optional; - import com.minelittlepony.unicopia.AwaitTickQueue; -import com.minelittlepony.unicopia.EquinePredicates; import com.minelittlepony.unicopia.Race; import com.minelittlepony.unicopia.USounds; -import com.minelittlepony.unicopia.UTags; -import com.minelittlepony.unicopia.ability.data.Numeric; -import com.minelittlepony.unicopia.ability.magic.spell.effect.SpellType; import com.minelittlepony.unicopia.advancement.UCriteria; -import com.minelittlepony.unicopia.client.render.PlayerPoser.Animation; -import com.minelittlepony.unicopia.entity.Living; import com.minelittlepony.unicopia.entity.damage.UDamageTypes; import com.minelittlepony.unicopia.entity.player.Pony; -import com.minelittlepony.unicopia.util.RegistryUtils; -import com.minelittlepony.unicopia.util.VecHelper; -import net.minecraft.entity.LivingEntity; -import net.minecraft.particle.ParticleTypes; -import net.minecraft.util.math.MathHelper; -import net.minecraft.util.math.Vec3d; import net.minecraft.util.math.random.Random; +import net.minecraft.world.event.GameEvent; /** - * A magic casting ability for unicorns. - * (only shields for now) + * An ability to screeeeeeeeEeEeEeeee! */ -public class BatEeeeAbility implements Ability { +public class BatEeeeAbility extends ScreechAbility { public static final int SELF_SPOOK_PROBABILITY = 20000; - public static final int MOB_SPOOK_PROBABILITY = 1000; - - @Override - public int getWarmupTime(Pony player) { - return 30; - } - - @Override - public int getCooldownTime(Pony player) { - return 5; - } - - @Override - public double getCostEstimate(Pony player) { - return 0; - } - - @Override - public boolean activateOnEarlyRelease() { - return true; - } @Override public boolean canUse(Race race) { @@ -57,22 +22,7 @@ public class BatEeeeAbility implements Ability { } @Override - public Optional prepare(Pony player) { - return player.getAbilities().getActiveStat() - .map(stat -> (int)(stat.getWarmup() * getWarmupTime(player))) - .filter(i -> i >= 0) - .map(Numeric::new); - } - - @Override - public Numeric.Serializer getSerializer() { - return Numeric.SERIALIZER; - } - - @Override - public boolean apply(Pony player, Numeric data) { - float strength = 1 - MathHelper.clamp(data.type() / (float)getWarmupTime(player), 0, 1); - Random rng = player.asWorld().random; + protected void playSounds(Pony player, Random rng, float strength) { int count = 1 + rng.nextInt(10) + (int)(strength * 10); for (int i = 0; i < count; i++) { @@ -81,6 +31,7 @@ public class BatEeeeAbility implements Ability { 1.6F + (rng.nextFloat() - 0.5F) ); } + player.asWorld().emitGameEvent(player.asEntity(), GameEvent.ENTITY_ACTION, player.asEntity().getEyePos()); for (int j = 0; j < (int)(strength * 2); j++) { for (int k = 0; k < count; k++) { AwaitTickQueue.scheduleTask(player.asWorld(), w -> { @@ -88,59 +39,14 @@ public class BatEeeeAbility implements Ability { (0.9F + (rng.nextFloat() - 0.5F) / 2F) * strength, 1.6F + (rng.nextFloat() - 0.5F) ); + player.asWorld().emitGameEvent(player.asEntity(), GameEvent.ENTITY_ACTION, player.asEntity().getEyePos()); }, rng.nextInt(3)); } } - if (!player.getPhysics().isFlying()) { - player.setAnimation(Animation.SPREAD_WINGS, Animation.Recipient.ANYONE); - } - - Vec3d origin = player.getOriginVector(); - if (strength > 0.5F && rng.nextInt(SELF_SPOOK_PROBABILITY) == 0) { player.asEntity().damage(player.damageOf(UDamageTypes.BAT_SCREECH, player), 0.1F); UCriteria.SCREECH_SELF.trigger(player.asEntity()); } - - int total = player.findAllEntitiesInRange((int)Math.max(1, 8 * strength)).mapToInt(e -> { - if (e instanceof LivingEntity living && !SpellType.SHIELD.isOn(e)) { - boolean isEarthPony = EquinePredicates.PLAYER_EARTH.test(e); - e.damage(player.damageOf(UDamageTypes.BAT_SCREECH, player), isEarthPony ? 0.1F : 0.3F); - if (e.getWorld().random.nextInt(MOB_SPOOK_PROBABILITY) == 0) { - RegistryUtils.pickRandom(e.getWorld(), UTags.SPOOKED_MOB_DROPS).ifPresent(drop -> { - e.dropStack(drop.getDefaultStack()); - e.playSound(USounds.Vanilla.ENTITY_ITEM_PICKUP, 1, 0.1F); - UCriteria.SPOOK_MOB.trigger(player.asEntity()); - }); - } - - Vec3d knockVec = origin.subtract(e.getPos()).multiply(strength); - living.takeKnockback((isEarthPony ? 0.3F : 0.5F) * strength, knockVec.getX(), knockVec.getZ()); - if (!isEarthPony) { - e.addVelocity(0, 0.1 * strength, 0); - } - Living.updateVelocity(e); - return 1; - } - return 0; - }).sum(); - - if (total >= 20) { - UCriteria.SCREECH_TWENTY_MOBS.trigger(player.asEntity()); - } - - return true; - } - - @Override - public void warmUp(Pony player, AbilitySlot slot) { - } - - @Override - public void coolDown(Pony player, AbilitySlot slot) { - for (int i = 0; i < 20; i++) { - player.addParticle(ParticleTypes.BUBBLE_POP, player.getPhysics().getHeadPosition().toCenterPos(), VecHelper.supply(() -> player.asWorld().getRandom().nextGaussian() - 0.5)); - } } } diff --git a/src/main/java/com/minelittlepony/unicopia/ability/BatPonyHangAbility.java b/src/main/java/com/minelittlepony/unicopia/ability/BatPonyHangAbility.java index f7e75dc2..9237ab34 100644 --- a/src/main/java/com/minelittlepony/unicopia/ability/BatPonyHangAbility.java +++ b/src/main/java/com/minelittlepony/unicopia/ability/BatPonyHangAbility.java @@ -38,13 +38,13 @@ public class BatPonyHangAbility implements Ability { @Override public Optional prepare(Pony player) { - if (player.isHanging()) { + if (player.getAcrobatics().isHanging()) { return Optional.of(new Multi(BlockPos.ZERO, 0)); } return TraceHelper.findBlock(player.asEntity(), 5, 1) .map(BlockPos::down) - .filter(player::canHangAt) + .filter(player.getAcrobatics()::canHangAt) .map(pos -> new Multi(pos, 1)); } @@ -55,13 +55,13 @@ public class BatPonyHangAbility implements Ability { @Override public boolean apply(Pony player, Multi data) { - if (data.hitType() == 0 && player.isHanging()) { - player.stopHanging(); + if (data.hitType() == 0 && player.getAcrobatics().isHanging()) { + player.getAcrobatics().stopHanging(); return true; } - if (data.hitType() == 1 && player.canHangAt(data.pos().pos())) { - player.startHanging(data.pos().pos()); + if (data.hitType() == 1 && player.getAcrobatics().canHangAt(data.pos().pos())) { + player.getAcrobatics().startHanging(data.pos().pos()); } return true; diff --git a/src/main/java/com/minelittlepony/unicopia/ability/ChangeFormAbility.java b/src/main/java/com/minelittlepony/unicopia/ability/ChangeFormAbility.java new file mode 100644 index 00000000..4c841b1a --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/ability/ChangeFormAbility.java @@ -0,0 +1,112 @@ +package com.minelittlepony.unicopia.ability; + +import java.util.List; +import java.util.Optional; +import java.util.stream.Stream; + +import org.jetbrains.annotations.Nullable; + +import com.minelittlepony.unicopia.Race; +import com.minelittlepony.unicopia.USounds; +import com.minelittlepony.unicopia.ability.data.Hit; +import com.minelittlepony.unicopia.entity.player.Pony; +import com.minelittlepony.unicopia.item.FriendshipBraceletItem; + +import net.minecraft.particle.ParticleTypes; +import net.minecraft.sound.SoundCategory; +import net.minecraft.sound.SoundEvents; +import net.minecraft.util.Identifier; + +public class ChangeFormAbility implements Ability { + + @Override + public int getWarmupTime(Pony player) { + return 10; + } + + @Override + public int getCooldownTime(Pony player) { + return 1000; + } + + @Override + public boolean canUse(Race.Composite race) { + return race.potential() != null && race.potential() != race.physical(); + } + + @Override + public boolean canUse(Race race) { + return true; + } + + @Override + public Identifier getIcon(Pony player) { + Race potential = player.getCompositeRace().potential(); + if (potential == null) { + return Ability.super.getIcon(player); + } + return getId().withPath(p -> "textures/gui/ability/" + p + "_" + potential.getId().getPath() + ".png"); + } + + @Nullable + @Override + public Optional prepare(Pony player) { + return Hit.of(canUse(player.getCompositeRace())); + } + + @Override + public Hit.Serializer getSerializer() { + return Hit.SERIALIZER; + } + + @Override + public double getCostEstimate(Pony player) { + return 5; + } + + @Override + public boolean apply(Pony player, Hit data) { + if (prepare(player).isEmpty()) { + return false; + } + + List targets = getTargets(player).toList(); + player.subtractEnergyCost(5 * targets.size()); + boolean isTransforming = player.getSuppressedRace().isUnset(); + targets.forEach(target -> { + Race supressed = target.getSuppressedRace(); + if (target == player || supressed.isUnset() == isTransforming) { + Race actualRace = target.getSpecies(); + target.setSpecies(supressed.or(player.getCompositeRace().potential())); + target.setSuppressedRace(isTransforming ? actualRace : Race.UNSET); + } + }); + + return true; + } + + @Override + public void warmUp(Pony player, AbilitySlot slot) { + player.getMagicalReserves().getExertion().addPercent(6); + getTargets(player).forEach(target -> { + if (player.getAbilities().getStat(slot).getWarmup() % 5 == 0) { + player.asWorld().playSound(target.asEntity(), target.getOrigin(), SoundEvents.BLOCK_BUBBLE_COLUMN_WHIRLPOOL_INSIDE, SoundCategory.PLAYERS); + } + + if (player.asWorld().random.nextInt(5) == 0) { + player.asWorld().playSound(target.asEntity(), target.getOrigin(), USounds.Vanilla.BLOCK_BUBBLE_COLUMN_BUBBLE_POP, SoundCategory.PLAYERS); + } + + target.spawnParticles(ParticleTypes.BUBBLE_COLUMN_UP, 15); + target.spawnParticles(ParticleTypes.BUBBLE_POP, 15); + }); + } + + @Override + public void coolDown(Pony player, AbilitySlot slot) { + } + + private Stream getTargets(Pony player) { + return Stream.concat(Stream.of(player), FriendshipBraceletItem.getPartyMembers(player, 3)); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/ability/ChangelingDisguiseAbility.java b/src/main/java/com/minelittlepony/unicopia/ability/ChangelingDisguiseAbility.java index 33a67ac0..6f3e2c60 100644 --- a/src/main/java/com/minelittlepony/unicopia/ability/ChangelingDisguiseAbility.java +++ b/src/main/java/com/minelittlepony/unicopia/ability/ChangelingDisguiseAbility.java @@ -11,6 +11,7 @@ import com.minelittlepony.unicopia.ability.data.Hit; import com.minelittlepony.unicopia.ability.magic.spell.AbstractDisguiseSpell; import com.minelittlepony.unicopia.ability.magic.spell.CastingMethod; import com.minelittlepony.unicopia.ability.magic.spell.effect.SpellType; +import com.minelittlepony.unicopia.entity.behaviour.Disguise; import com.minelittlepony.unicopia.entity.player.Pony; import com.minelittlepony.unicopia.mixin.MixinFallingBlockEntity; import com.minelittlepony.unicopia.particle.UParticles; @@ -50,9 +51,13 @@ public class ChangelingDisguiseAbility extends ChangelingFeedAbility { player.getEntityWorld().playSound(null, player.getBlockPos(), USounds.ENTITY_PLAYER_CHANGELING_TRANSFORM, SoundCategory.PLAYERS, 1.4F, 0.4F); - iplayer.getSpellSlot().get(SpellType.CHANGELING_DISGUISE, true) - .orElseGet(() -> SpellType.CHANGELING_DISGUISE.withTraits().apply(iplayer, CastingMethod.INNATE)) - .setDisguise(looked); + Disguise currentDisguise = iplayer.getSpellSlot().get(SpellType.CHANGELING_DISGUISE, true) + .orElseGet(() -> SpellType.CHANGELING_DISGUISE.withTraits().apply(iplayer, CastingMethod.INNATE)); + + if (currentDisguise.isOf(looked)) { + looked = null; + } + currentDisguise.setDisguise(looked); if (!player.isCreative()) { iplayer.getMagicalReserves().getMana().multiply(0.1F); @@ -65,7 +70,7 @@ public class ChangelingDisguiseAbility extends ChangelingFeedAbility { @Override public void warmUp(Pony player, AbilitySlot slot) { - player.getMagicalReserves().getEnergy().add(20); + player.getMagicalReserves().getEnergy().add(2F); player.spawnParticles(UParticles.CHANGELING_MAGIC, 5); } diff --git a/src/main/java/com/minelittlepony/unicopia/ability/EarthPonyGrowAbility.java b/src/main/java/com/minelittlepony/unicopia/ability/EarthPonyGrowAbility.java index ef901a39..ee82de7d 100644 --- a/src/main/java/com/minelittlepony/unicopia/ability/EarthPonyGrowAbility.java +++ b/src/main/java/com/minelittlepony/unicopia/ability/EarthPonyGrowAbility.java @@ -5,10 +5,12 @@ import java.util.Optional; import com.minelittlepony.unicopia.Race; import com.minelittlepony.unicopia.ability.data.Hit; import com.minelittlepony.unicopia.ability.data.Pos; +import com.minelittlepony.unicopia.block.UBlocks; import com.minelittlepony.unicopia.entity.player.Pony; import com.minelittlepony.unicopia.particle.MagicParticleEffect; import com.minelittlepony.unicopia.util.TraceHelper; import net.minecraft.block.BlockState; +import net.minecraft.block.Blocks; import net.minecraft.item.BoneMealItem; import net.minecraft.item.ItemStack; import net.minecraft.item.Items; @@ -71,8 +73,21 @@ public class EarthPonyGrowAbility implements Ability { ItemStack stack = new ItemStack(Items.BONE_MEAL); - if (BoneMealItem.useOnFertilizable(stack, w, pos) - || BoneMealItem.useOnGround(stack, w, pos, Direction.UP)) { + if (state.getBlock() instanceof Growable growable) { + return growable.grow(w, state, pos) ? 1 : 0; + } + + if (BoneMealItem.useOnFertilizable(stack, w, pos)) { + if (w.random.nextInt(350) == 0) { + if (w.getBlockState(pos.down()).isOf(Blocks.FARMLAND)) { + w.setBlockState(pos.down(), Blocks.DIRT.getDefaultState()); + } + w.setBlockState(pos, UBlocks.PLUNDER_VINE_BUD.getDefaultState()); + } + return 1; + } + + if (BoneMealItem.useOnGround(stack, w, pos, Direction.UP)) { return 1; } @@ -92,4 +107,8 @@ public class EarthPonyGrowAbility implements Ability { public void coolDown(Pony player, AbilitySlot slot) { } + + public interface Growable { + boolean grow(World world, BlockState state, BlockPos pos); + } } diff --git a/src/main/java/com/minelittlepony/unicopia/ability/EarthPonyKickAbility.java b/src/main/java/com/minelittlepony/unicopia/ability/EarthPonyKickAbility.java index 086032bf..9f6bb09c 100644 --- a/src/main/java/com/minelittlepony/unicopia/ability/EarthPonyKickAbility.java +++ b/src/main/java/com/minelittlepony/unicopia/ability/EarthPonyKickAbility.java @@ -60,8 +60,7 @@ public class EarthPonyKickAbility implements Ability { @Override public Identifier getIcon(Pony player) { - Identifier id = Abilities.REGISTRY.getId(this); - return new Identifier(id.getNamespace(), "textures/gui/ability/" + id.getPath() + return getId().withPath(p -> "textures/gui/ability/" + p + "_" + player.getObservedSpecies().getId().getPath() + "_" + (getKickDirection(player) > 0 ? "forward" : "backward") + ".png"); diff --git a/src/main/java/com/minelittlepony/unicopia/ability/FlyingDashAbility.java b/src/main/java/com/minelittlepony/unicopia/ability/FlyingDashAbility.java new file mode 100644 index 00000000..0a9f5f6b --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/ability/FlyingDashAbility.java @@ -0,0 +1,76 @@ +package com.minelittlepony.unicopia.ability; + +import java.util.Optional; + +import org.jetbrains.annotations.Nullable; + +import com.minelittlepony.unicopia.Race; +import com.minelittlepony.unicopia.ability.data.Hit; +import com.minelittlepony.unicopia.entity.player.Pony; + +/** + * Dashing ability for flying creatures. + */ +public class FlyingDashAbility implements Ability { + + @Override + public int getWarmupTime(Pony player) { + return 19; + } + + @Override + public int getCooldownTime(Pony player) { + return 30; + } + + @Override + public boolean canUse(Race race) { + return race == Race.HIPPOGRIFF; + } + + @Nullable + @Override + public Optional prepare(Pony player) { + return Hit.of(player.getPhysics().isFlying()); + } + + @Override + public Hit.Serializer getSerializer() { + return Hit.SERIALIZER; + } + + @Override + public double getCostEstimate(Pony player) { + return 0; + } + + @Override + public boolean onQuickAction(Pony player, ActivationType type, Optional data) { + + if (type == ActivationType.TAP && !player.getMotion().isRainbooming() && player.getPhysics().isFlying() && player.getMagicalReserves().getMana().get() > 40) { + player.getPhysics().dashForward((float)player.asWorld().random.nextTriangular(2.5F, 0.3F)); + return true; + } + + return false; + } + + @Override + public boolean apply(Pony player, Hit data) { + player.getPhysics().dashForward((float)player.asWorld().random.nextTriangular(2.5F, 0.3F)); + player.subtractEnergyCost(2); + return true; + } + + @Override + public void warmUp(Pony player, AbilitySlot slot) { + player.getMagicalReserves().getExertion().addPercent(6); + } + + @Override + public void coolDown(Pony player, AbilitySlot slot) { + float velocityScale = player.getAbilities().getStat(slot).getCooldown(); + float multiplier = 1 + (0.02F * velocityScale); + player.asEntity().getVelocity().multiply(multiplier, 1, multiplier); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/ability/PeckAbility.java b/src/main/java/com/minelittlepony/unicopia/ability/PeckAbility.java new file mode 100644 index 00000000..849dbb4c --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/ability/PeckAbility.java @@ -0,0 +1,152 @@ +package com.minelittlepony.unicopia.ability; + +import java.util.Optional; + +import com.minelittlepony.unicopia.EquinePredicates; +import com.minelittlepony.unicopia.Race; +import com.minelittlepony.unicopia.USounds; +import com.minelittlepony.unicopia.ability.data.Hit; +import com.minelittlepony.unicopia.ability.data.Numeric; +import com.minelittlepony.unicopia.entity.Living; +import com.minelittlepony.unicopia.entity.damage.UDamageTypes; +import com.minelittlepony.unicopia.entity.player.Pony; +import com.minelittlepony.unicopia.util.TraceHelper; + +import net.minecraft.block.Block; +import net.minecraft.block.BlockState; +import net.minecraft.block.Blocks; +import net.minecraft.entity.LivingEntity; +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.item.ItemStack; +import net.minecraft.predicate.entity.EntityPredicates; +import net.minecraft.registry.tag.BlockTags; +import net.minecraft.server.world.ServerWorld; +import net.minecraft.text.Text; +import net.minecraft.util.math.BlockPos; +import net.minecraft.util.math.Vec3d; +import net.minecraft.util.math.random.Random; +import net.minecraft.world.World; +import net.minecraft.world.WorldEvents; +import net.minecraft.world.event.GameEvent; + +/** + * Hippogriff ability to use their beak as a weapon + */ +public class PeckAbility implements Ability { + + @Override + public int getWarmupTime(Pony player) { + return 1; + } + + @Override + public int getCooldownTime(Pony player) { + return 10; + } + + @Override + public double getCostEstimate(Pony player) { + return 0; + } + + @Override + public boolean activateOnEarlyRelease() { + return true; + } + + @Override + public boolean canUse(Race race) { + return race == Race.HIPPOGRIFF; + } + + @Override + public Optional prepare(Pony player) { + return Hit.INSTANCE; + } + + @Override + public Numeric.Serializer getSerializer() { + return Hit.SERIALIZER; + } + + protected LivingEntity findTarget(PlayerEntity player, World w) { + return TraceHelper.findEntity(player, 5, 1, hit -> { + return EntityPredicates.EXCEPT_CREATIVE_OR_SPECTATOR.test(hit) && !player.isConnectedThroughVehicle(hit); + }).orElse(null); + } + + @Override + public boolean apply(Pony player, Hit hit) { + LivingEntity target = findTarget(player.asEntity(), player.asWorld()); + + playSounds(player, player.asWorld().getRandom(), 1); + + if (target != null) { + spookMob(player, target, 1); + } else { + BlockPos pos = TraceHelper.findBlock(player.asEntity(), 5, 1).orElse(BlockPos.ORIGIN); + if (pos != BlockPos.ORIGIN) { + BlockState state = player.asWorld().getBlockState(pos); + if (state.isReplaceable()) { + player.asWorld().breakBlock(pos, true); + } else if (state.isIn(BlockTags.DIRT) || player.asWorld().random.nextInt(40000) == 0) { + player.asWorld().syncWorldEvent(WorldEvents.BLOCK_BROKEN, pos, Block.getRawIdFromState(state)); + pos = pos.up(); + World world = player.asWorld(); + + if (world instanceof ServerWorld sw) { + for (ItemStack stack : Block.getDroppedStacks(state, sw, pos, null)) { + if (Block.getBlockFromItem(stack.getItem()) == Blocks.AIR) { + Block.dropStack(world, pos, stack); + } + } + state.onStacksDropped(sw, pos, ItemStack.EMPTY, true); + + if (world.random.nextInt(20) == 0) { + world.breakBlock(pos.down(), false); + player.asEntity().sendMessage(Text.translatable("ability.unicopia.peck.block.fled"), true); + } + } + } else { + player.asEntity().sendMessage(Text.translatable("ability.unicopia.peck.block.unfased"), true); + } + } + } + + return true; + } + + protected void playSounds(Pony player, Random rng, float strength) { + player.getMagicalReserves().getExertion().addPercent(100); + player.getMagicalReserves().getEnergy().addPercent(10); + player.playSound(USounds.Vanilla.ENTITY_CHICKEN_HURT, + 1, + 0.9F + (rng.nextFloat() - 0.5F) + ); + player.asWorld().emitGameEvent(player.asEntity(), GameEvent.STEP, player.asEntity().getEyePos()); + } + + protected void spookMob(Pony player, LivingEntity living, float strength) { + boolean isEarthPony = EquinePredicates.PLAYER_EARTH.test(living); + boolean isBracing = isEarthPony && player.asEntity().isSneaking(); + + if (!isBracing) { + living.damage(player.damageOf(UDamageTypes.BAT_SCREECH, player), isEarthPony ? 0.1F : 0.3F); + } + + Vec3d knockVec = player.getOriginVector().subtract(living.getPos()).multiply(strength); + living.takeKnockback((isBracing ? 0.2F : isEarthPony ? 0.3F : 0.5F) * strength, knockVec.getX(), knockVec.getZ()); + if (!isEarthPony) { + living.addVelocity(0, 0.1 * strength, 0); + } + Living.updateVelocity(living); + } + + @Override + public void warmUp(Pony player, AbilitySlot slot) { + } + + @Override + public void coolDown(Pony player, AbilitySlot slot) { + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/ability/ScreechAbility.java b/src/main/java/com/minelittlepony/unicopia/ability/ScreechAbility.java new file mode 100644 index 00000000..e5500e2d --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/ability/ScreechAbility.java @@ -0,0 +1,141 @@ +package com.minelittlepony.unicopia.ability; + +import java.util.Optional; + +import com.minelittlepony.unicopia.EquinePredicates; +import com.minelittlepony.unicopia.Race; +import com.minelittlepony.unicopia.USounds; +import com.minelittlepony.unicopia.UTags; +import com.minelittlepony.unicopia.ability.data.Numeric; +import com.minelittlepony.unicopia.ability.magic.spell.effect.SpellType; +import com.minelittlepony.unicopia.advancement.UCriteria; +import com.minelittlepony.unicopia.client.render.PlayerPoser.Animation; +import com.minelittlepony.unicopia.entity.Living; +import com.minelittlepony.unicopia.entity.damage.UDamageTypes; +import com.minelittlepony.unicopia.entity.player.Pony; +import com.minelittlepony.unicopia.util.RegistryUtils; +import com.minelittlepony.unicopia.util.VecHelper; + +import net.minecraft.entity.LivingEntity; +import net.minecraft.particle.ParticleTypes; +import net.minecraft.util.math.MathHelper; +import net.minecraft.util.math.Vec3d; +import net.minecraft.util.math.random.Random; +import net.minecraft.world.event.GameEvent; + +/** + * An ability to scream very loud + */ +public class ScreechAbility implements Ability { + public static final int MOB_SPOOK_PROBABILITY = 1000; + + @Override + public int getWarmupTime(Pony player) { + return 30; + } + + @Override + public int getCooldownTime(Pony player) { + return 5; + } + + @Override + public double getCostEstimate(Pony player) { + return 0; + } + + @Override + public boolean activateOnEarlyRelease() { + return true; + } + + @Override + public boolean canUse(Race race) { + return race == Race.HIPPOGRIFF; + } + + @Override + public Optional prepare(Pony player) { + return player.getAbilities().getActiveStat() + .map(stat -> (int)(stat.getWarmup() * getWarmupTime(player))) + .filter(i -> i >= 0) + .map(Numeric::new); + } + + @Override + public Numeric.Serializer getSerializer() { + return Numeric.SERIALIZER; + } + + @Override + public boolean apply(Pony player, Numeric data) { + float strength = 1 - MathHelper.clamp(data.type() / (float)getWarmupTime(player), 0, 1); + Random rng = player.asWorld().random; + + playSounds(player, rng, strength); + + if (!player.getPhysics().isFlying()) { + player.setAnimation(Animation.SPREAD_WINGS, Animation.Recipient.ANYONE); + } + + int total = player.findAllEntitiesInRange((int)Math.max(1, 8 * strength)).mapToInt(e -> { + if (e instanceof LivingEntity living && !SpellType.SHIELD.isOn(e)) { + spookMob(player, living, strength); + return 1; + } + return 0; + }).sum(); + + if (total >= 20) { + UCriteria.SCREECH_TWENTY_MOBS.trigger(player.asEntity()); + } + + return true; + } + + protected void playSounds(Pony player, Random rng, float strength) { + player.playSound(USounds.ENTITY_PLAYER_HIPPOGRIFF_SCREECH, + (1.2F + (rng.nextFloat() - 0.5F) / 2F) * strength, + 1.1F + (rng.nextFloat() - 0.5F) + ); + player.asWorld().emitGameEvent(player.asEntity(), GameEvent.ENTITY_ACTION, player.asEntity().getEyePos()); + } + + protected void spookMob(Pony player, LivingEntity living, float strength) { + boolean isEarthPony = EquinePredicates.PLAYER_EARTH.test(living); + boolean isBracing = isEarthPony && player.asEntity().isSneaking(); + + if (!isBracing) { + living.damage(player.damageOf(UDamageTypes.BAT_SCREECH, player), isEarthPony ? 0.1F : 0.3F); + + + if (living.getWorld().random.nextInt(MOB_SPOOK_PROBABILITY) == 0) { + RegistryUtils.pickRandom(living.getWorld(), UTags.SPOOKED_MOB_DROPS).ifPresent(drop -> { + living.dropStack(drop.getDefaultStack()); + living.playSound(USounds.Vanilla.ENTITY_ITEM_PICKUP, 1, 0.1F); + UCriteria.SPOOK_MOB.trigger(player.asEntity()); + }); + } + } + + Vec3d knockVec = player.getOriginVector().subtract(living.getPos()).multiply(strength); + living.takeKnockback((isBracing ? 0.2F : isEarthPony ? 0.3F : 0.5F) * strength, knockVec.getX(), knockVec.getZ()); + if (!isEarthPony) { + living.addVelocity(0, 0.1 * strength, 0); + } + Living.updateVelocity(living); + } + + @Override + public void warmUp(Pony player, AbilitySlot slot) { + } + + @Override + public void coolDown(Pony player, AbilitySlot slot) { + for (int i = 0; i < 20; i++) { + player.addParticle(ParticleTypes.BUBBLE_POP, player.asEntity().getEyePos(), + VecHelper.supply(() -> (player.asWorld().getRandom().nextGaussian() - 0.5) * 0.3) + ); + } + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/ability/SeaponySonarPulseAbility.java b/src/main/java/com/minelittlepony/unicopia/ability/SeaponySonarPulseAbility.java new file mode 100644 index 00000000..c4df03a4 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/ability/SeaponySonarPulseAbility.java @@ -0,0 +1,112 @@ +package com.minelittlepony.unicopia.ability; + +import java.util.Comparator; +import java.util.Optional; +import org.jetbrains.annotations.Nullable; + +import com.minelittlepony.unicopia.AwaitTickQueue; +import com.minelittlepony.unicopia.Race; +import com.minelittlepony.unicopia.UPOIs; +import com.minelittlepony.unicopia.USounds; +import com.minelittlepony.unicopia.ability.data.Hit; +import com.minelittlepony.unicopia.client.render.PlayerPoser.Animation; +import com.minelittlepony.unicopia.entity.player.Pony; +import com.minelittlepony.unicopia.particle.ParticleUtils; +import com.minelittlepony.unicopia.particle.UParticles; +import net.minecraft.entity.Entity; +import net.minecraft.entity.EntityGroup; +import net.minecraft.entity.LivingEntity; +import net.minecraft.entity.mob.HostileEntity; +import net.minecraft.registry.tag.FluidTags; +import net.minecraft.server.world.ServerWorld; +import net.minecraft.sound.SoundCategory; +import net.minecraft.util.math.Vec3d; +import net.minecraft.world.event.GameEvent; +import net.minecraft.world.poi.PointOfInterestStorage.OccupationStatus; + +public class SeaponySonarPulseAbility implements Ability { + + @Override + public int getWarmupTime(Pony player) { + return 10; + } + + @Override + public int getCooldownTime(Pony player) { + return 100; + } + + @Override + public boolean canUse(Race race) { + return race == Race.SEAPONY; + } + + @Nullable + @Override + public Optional prepare(Pony player) { + return Hit.INSTANCE; + } + + @Override + public Hit.Serializer getSerializer() { + return Hit.SERIALIZER; + } + + @Override + public double getCostEstimate(Pony player) { + return 5; + } + + @Override + public boolean apply(Pony player, Hit data) { + player.setAnimation(Animation.ARMS_UP, Animation.Recipient.ANYONE); + + for (Entity target : player.findAllEntitiesInRange(64, e -> { + return (e instanceof LivingEntity && (e instanceof HostileEntity || ((LivingEntity)e).getGroup() == EntityGroup.AQUATIC)) && e.isSubmergedInWater(); + }).sorted(Comparator.comparing(e -> e.distanceTo(player.asEntity()))).toList()) { + Vec3d offset = target.getPos().subtract(player.getOriginVector()); + float distance = target.distanceTo(player.asEntity()); + if (distance < 4) { + float scale = 1 - (distance/10F); + ((LivingEntity)target).takeKnockback(0.7 * scale, -offset.x, -offset.z); + target.damage(target.getDamageSources().sonicBoom(player.asEntity()), 10 * scale); + } else { + emitPing(player, target.getPos(), 10, 1, 1.3F); + } + } + player.subtractEnergyCost(5); + + if (player.asWorld() instanceof ServerWorld sw) { + sw.getPointOfInterestStorage().getNearestPosition( + type -> type.value() == UPOIs.CHESTS, + pos -> player.asWorld().getFluidState(pos).isIn(FluidTags.WATER), player.getOrigin(), 64, OccupationStatus.ANY) + .ifPresent(chestPos -> { + emitPing(player, chestPos.toCenterPos(), 20, 0.5F, 2F); + }); + } + + player.playSound(USounds.ENTITY_PLAYER_SEAPONY_SONAR, 1); + player.spawnParticles(UParticles.SHOCKWAVE, 1); + player.asEntity().emitGameEvent(GameEvent.INSTRUMENT_PLAY); + + return true; + } + + private void emitPing(Pony player, Vec3d pos, int delay, float volume, float pitch) { + AwaitTickQueue.scheduleTask(player.asWorld(), w -> { + ParticleUtils.spawnParticle(w, UParticles.SHOCKWAVE, pos, Vec3d.ZERO); + float loudness = Math.max(0, 1.4F - (float)Math.log10(player.getOriginVector().distanceTo(pos))); + w.playSound(null, pos.x, pos.y, pos.z, USounds.ENTITY_PLAYER_SEAPONY_SONAR, SoundCategory.AMBIENT, volume * loudness, pitch); + w.emitGameEvent(player.asEntity(), GameEvent.INSTRUMENT_PLAY, pos); + }, delay + (int)player.getOriginVector().distanceTo(pos)); + } + + @Override + public void warmUp(Pony player, AbilitySlot slot) { + player.getMagicalReserves().getExertion().addPercent(6); + } + + @Override + public void coolDown(Pony player, AbilitySlot slot) { + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/ability/PegasusFlightToggleAbility.java b/src/main/java/com/minelittlepony/unicopia/ability/ToggleFlightAbility.java similarity index 97% rename from src/main/java/com/minelittlepony/unicopia/ability/PegasusFlightToggleAbility.java rename to src/main/java/com/minelittlepony/unicopia/ability/ToggleFlightAbility.java index c0736de0..d9811e74 100644 --- a/src/main/java/com/minelittlepony/unicopia/ability/PegasusFlightToggleAbility.java +++ b/src/main/java/com/minelittlepony/unicopia/ability/ToggleFlightAbility.java @@ -12,7 +12,7 @@ import com.minelittlepony.unicopia.entity.player.Pony; import net.minecraft.util.Identifier; -public class PegasusFlightToggleAbility implements Ability { +public class ToggleFlightAbility implements Ability { @Override public int getWarmupTime(Pony player) { diff --git a/src/main/java/com/minelittlepony/unicopia/ability/UnicornTeleportAbility.java b/src/main/java/com/minelittlepony/unicopia/ability/UnicornTeleportAbility.java index 79a85a3b..c14dc59d 100644 --- a/src/main/java/com/minelittlepony/unicopia/ability/UnicornTeleportAbility.java +++ b/src/main/java/com/minelittlepony/unicopia/ability/UnicornTeleportAbility.java @@ -8,6 +8,7 @@ import com.minelittlepony.unicopia.ability.data.Hit; import com.minelittlepony.unicopia.ability.data.Pos; import com.minelittlepony.unicopia.ability.magic.Caster; import com.minelittlepony.unicopia.ability.magic.spell.effect.SpellType; +import com.minelittlepony.unicopia.advancement.UCriteria; import com.minelittlepony.unicopia.block.state.StatePredicate; import com.minelittlepony.unicopia.entity.Living; import com.minelittlepony.unicopia.entity.player.Pony; @@ -163,16 +164,19 @@ public class UnicornTeleportAbility implements Ability { Vec3d dest = destination.vec().add(offset); - participant.teleport( - dest.x, - getTargetYPosition(participant.getEntityWorld(), BlockPos.ofFloored(dest), ShapeContext.of(participant)), - dest.z - ); + dest = new Vec3d(dest.x, getTargetYPosition(participant.getEntityWorld(), BlockPos.ofFloored(dest), ShapeContext.of(participant)), dest.z); + + participant.teleport(dest.x, dest.y, dest.z); teleporter.subtractEnergyCost(distance); participant.fallDistance /= distance; - participant.getWorld().playSound(null, destination.pos(), USounds.ENTITY_PLAYER_UNICORN_TELEPORT, SoundCategory.PLAYERS, 1, 1); + BlockPos blockPos = BlockPos.ofFloored(dest); + + participant.getWorld().playSound(null, blockPos, USounds.ENTITY_PLAYER_UNICORN_TELEPORT, SoundCategory.PLAYERS, 1, 1); + if (!participant.getEntityWorld().isInBuildLimit(blockPos)) { + UCriteria.TELEPORT_ABOVE_WORLD.trigger(teleporter.asEntity()); + } return true; } diff --git a/src/main/java/com/minelittlepony/unicopia/ability/magic/spell/RageAbilitySpell.java b/src/main/java/com/minelittlepony/unicopia/ability/magic/spell/RageAbilitySpell.java index 3edec65a..1f3e2ada 100644 --- a/src/main/java/com/minelittlepony/unicopia/ability/magic/spell/RageAbilitySpell.java +++ b/src/main/java/com/minelittlepony/unicopia/ability/magic/spell/RageAbilitySpell.java @@ -30,11 +30,17 @@ public class RageAbilitySpell extends AbstractSpell { private int age; private int ticksExtenguishing; + private int ticksToExtenguish; + public RageAbilitySpell(CustomisedSpellType type) { super(type); setHidden(true); } + public void setExtenguishing() { + ticksToExtenguish += 15; + } + @Override public boolean tick(Caster source, Situation situation) { @@ -42,7 +48,7 @@ public class RageAbilitySpell extends AbstractSpell { return false; } - if (source.asEntity().isInsideWaterOrBubbleColumn()) { + if (source.asEntity().isInsideWaterOrBubbleColumn() || source.asEntity().isFrozen() || ticksToExtenguish > 0) { ticksExtenguishing++; source.playSound(SoundEvents.ENTITY_GENERIC_EXTINGUISH_FIRE, 1); source.spawnParticles(ParticleTypes.CLOUD, 12); @@ -51,6 +57,10 @@ public class RageAbilitySpell extends AbstractSpell { ticksExtenguishing = 0; } + if (ticksToExtenguish > 0) { + ticksToExtenguish--; + } + if (ticksExtenguishing > 10) { return false; } @@ -94,7 +104,7 @@ public class RageAbilitySpell extends AbstractSpell { } if (source instanceof Pony pony) { - if (source.isClient() && pony.asEntity().getAttackCooldownProgress(0) == 0) { + if (pony.isClientPlayer() && pony.asEntity().getAttackCooldownProgress(0) == 0) { InteractionManager.instance().playLoopingSound(source.asEntity(), InteractionManager.SOUND_KIRIN_RAGE, source.asWorld().random.nextLong()); } Bar energyBar = pony.getMagicalReserves().getEnergy(); diff --git a/src/main/java/com/minelittlepony/unicopia/ability/magic/spell/trait/SpellTraits.java b/src/main/java/com/minelittlepony/unicopia/ability/magic/spell/trait/SpellTraits.java index d03288f6..58c24bc4 100644 --- a/src/main/java/com/minelittlepony/unicopia/ability/magic/spell/trait/SpellTraits.java +++ b/src/main/java/com/minelittlepony/unicopia/ability/magic/spell/trait/SpellTraits.java @@ -51,7 +51,7 @@ public final class SpellTraits implements Iterable> { ); public static void load(Map newRegistry) { - REGISTRY = new HashMap<>(newRegistry); + REGISTRY = newRegistry; ITEMS.clear(); REGISTRY.forEach((itemId, traits) -> { Registries.ITEM.getOrEmpty(itemId).ifPresent(item -> { @@ -228,10 +228,7 @@ public final class SpellTraits implements Iterable> { } public static Stream getItems(Trait trait) { - return REGISTRY.entrySet().stream() - .filter(e -> e.getValue().get(trait) > 0) - .map(Map.Entry::getKey) - .flatMap(id -> Registries.ITEM.getOrEmpty(id).stream()); + return ITEMS.getOrDefault(trait, List.of()).stream(); } public static Optional getEmbeddedTraits(ItemStack stack) { diff --git a/src/main/java/com/minelittlepony/unicopia/ability/magic/spell/trait/TraitLoader.java b/src/main/java/com/minelittlepony/unicopia/ability/magic/spell/trait/TraitLoader.java index 44e8560b..28dc19df 100644 --- a/src/main/java/com/minelittlepony/unicopia/ability/magic/spell/trait/TraitLoader.java +++ b/src/main/java/com/minelittlepony/unicopia/ability/magic/spell/trait/TraitLoader.java @@ -5,7 +5,9 @@ import java.io.InputStreamReader; import java.nio.charset.StandardCharsets; import java.util.Map; import java.util.Map.Entry; +import java.util.Objects; import java.util.Set; +import java.util.function.Predicate; import java.util.stream.Collectors; import java.util.stream.Stream; import java.util.stream.StreamSupport; @@ -26,7 +28,11 @@ import net.minecraft.resource.SinglePreparationResourceReloader; import net.minecraft.util.Identifier; import net.minecraft.util.JsonHelper; import net.minecraft.util.profiler.Profiler; +import net.minecraft.item.Item; +import net.minecraft.item.ItemConvertible; import net.minecraft.registry.Registries; +import net.minecraft.registry.RegistryKeys; +import net.minecraft.registry.tag.TagKey; public class TraitLoader extends SinglePreparationResourceReloader> implements IdentifiableResourceReloadListener { private static final Identifier ID = Unicopia.id("data/traits"); @@ -77,9 +83,24 @@ public class TraitLoader extends SinglePreparationResourceReloader prepared, ResourceManager manager, Profiler profiler) { profiler.startTick(); - SpellTraits.load(prepared.values().stream() + + Set> newRegistry = prepared.values().stream() .flatMap(TraitStream::entries) - .collect(Collectors.toMap(Map.Entry::getKey, Map.Entry::getValue, SpellTraits::union))); + .collect(Collectors.toMap(Map.Entry::getKey, Map.Entry::getValue, SpellTraits::union)) + .entrySet(); + + SpellTraits.load(Registries.ITEM.getEntrySet().stream() + .map(entry -> Map.entry( + entry.getKey().getValue(), + newRegistry.stream() + .filter(p -> p.getKey().test(entry.getValue())) + .map(Map.Entry::getValue) + .reduce(SpellTraits::union) + .orElse(SpellTraits.EMPTY) + )) + .filter(entry -> !entry.getValue().isEmpty()) + .collect(Collectors.toMap(Map.Entry::getKey, Map.Entry::getValue))); + profiler.endTick(); } @@ -88,14 +109,14 @@ public class TraitLoader extends SinglePreparationResourceReloader> entries(); + Stream> entries(); static TraitStream of(Identifier id, String pack, JsonObject json) { if (json.has("items") && json.get("items").isJsonObject()) { return new TraitMap(JsonHelper.getBoolean(json, "replace", false), Resources.GSON.getAdapter(TYPE).fromJsonTree(json.get("items")).entrySet().stream().collect(Collectors.toMap( - a -> Identifier.tryParse(a.getKey()), + a -> Key.of(a.getKey()), a -> SpellTraits.fromString(a.getValue()).orElse(SpellTraits.EMPTY) )) ); @@ -106,23 +127,16 @@ public class TraitLoader extends SinglePreparationResourceReloader { - if (item == null || !Registries.ITEM.containsId(item)) { - Unicopia.LOGGER.warn("Skipping unknown item {} in {}:{}", item, pack, id); - return false; - } - return true; - }) + .map(Key::of) .collect(Collectors.toSet()) ); } record TraitMap ( boolean replace, - Map items) implements TraitStream { + Map items) implements TraitStream { @Override - public Stream> entries() { + public Stream> entries() { return items.entrySet().stream(); } } @@ -130,12 +144,32 @@ public class TraitLoader extends SinglePreparationResourceReloader items) implements TraitStream { + Set items) implements TraitStream { @Override - public Stream> entries() { + public Stream> entries() { return items().stream().map(item -> Map.entry(item, traits())); } } - } + interface Key extends Predicate { + static Key of(String s) { + return s.startsWith("#") ? new Tag(TagKey.of(RegistryKeys.ITEM, Identifier.tryParse(s.substring(1)))) : new Id(Identifier.tryParse(s)); + } + record Tag(TagKey tag) implements Key { + + @SuppressWarnings("deprecation") + @Override + public boolean test(ItemConvertible item) { + return item.asItem().getRegistryEntry().isIn(tag); + } + } + + record Id(Identifier id) implements Key { + @Override + public boolean test(ItemConvertible item) { + return Objects.equals(id, Registries.ITEM.getId(item.asItem())); + } + } + } + } } diff --git a/src/main/java/com/minelittlepony/unicopia/advancement/UCriteria.java b/src/main/java/com/minelittlepony/unicopia/advancement/UCriteria.java index c2f92a12..9fba2670 100644 --- a/src/main/java/com/minelittlepony/unicopia/advancement/UCriteria.java +++ b/src/main/java/com/minelittlepony/unicopia/advancement/UCriteria.java @@ -27,6 +27,7 @@ public interface UCriteria { CustomEventCriterion.Trigger POWER_UP_HEART = CUSTOM_EVENT.createTrigger("power_up_heart"); CustomEventCriterion.Trigger SPLIT_SEA = CUSTOM_EVENT.createTrigger("split_sea"); CustomEventCriterion.Trigger RIDE_BALLOON = CUSTOM_EVENT.createTrigger("ride_balloon"); + CustomEventCriterion.Trigger TELEPORT_ABOVE_WORLD = CUSTOM_EVENT.createTrigger("teleport_above_world"); static void bootstrap() { } } diff --git a/src/main/java/com/minelittlepony/unicopia/block/BaseZapAppleLeavesBlock.java b/src/main/java/com/minelittlepony/unicopia/block/BaseZapAppleLeavesBlock.java index d59a56b0..0b56490b 100644 --- a/src/main/java/com/minelittlepony/unicopia/block/BaseZapAppleLeavesBlock.java +++ b/src/main/java/com/minelittlepony/unicopia/block/BaseZapAppleLeavesBlock.java @@ -41,6 +41,10 @@ public class BaseZapAppleLeavesBlock extends LeavesBlock implements TintedBlock @Override public BlockState getStateForNeighborUpdate(BlockState state, Direction direction, BlockState neighborState, WorldAccess world, BlockPos pos, BlockPos neighborPos) { + if (state.get(PERSISTENT)) { + return state; + } + if (world instanceof ServerWorld sw) { ZapAppleStageStore store = ZapAppleStageStore.get(sw); ZapAppleStageStore.Stage currentStage = store.getStage(); @@ -56,7 +60,9 @@ public class BaseZapAppleLeavesBlock extends LeavesBlock implements TintedBlock public void scheduledTick(BlockState state, ServerWorld world, BlockPos pos, Random random) { super.scheduledTick(state, world, pos, random); tryAdvanceStage(state, world, pos, random); - world.scheduleBlockTick(pos, this, 1); + if (!state.get(PERSISTENT)) { + world.scheduleBlockTick(pos, this, 1); + } } private void tryAdvanceStage(BlockState state, ServerWorld world, BlockPos pos, Random random) { diff --git a/src/main/java/com/minelittlepony/unicopia/block/CrystalDoorBlock.java b/src/main/java/com/minelittlepony/unicopia/block/CrystalDoorBlock.java new file mode 100644 index 00000000..c7690aa1 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/block/CrystalDoorBlock.java @@ -0,0 +1,64 @@ +package com.minelittlepony.unicopia.block; + +import org.jetbrains.annotations.Nullable; + +import com.minelittlepony.unicopia.EquineContext; +import com.minelittlepony.unicopia.Race; +import com.minelittlepony.unicopia.USounds; +import com.minelittlepony.unicopia.item.UItems; + +import net.minecraft.block.Block; +import net.minecraft.block.BlockSetType; +import net.minecraft.block.BlockState; +import net.minecraft.block.DoorBlock; +import net.minecraft.block.enums.DoubleBlockHalf; +import net.minecraft.entity.Entity; +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.sound.SoundCategory; +import net.minecraft.util.ActionResult; +import net.minecraft.util.Hand; +import net.minecraft.util.hit.BlockHitResult; +import net.minecraft.util.math.BlockPos; +import net.minecraft.util.math.Direction; +import net.minecraft.world.World; +import net.minecraft.world.event.GameEvent; + +public class CrystalDoorBlock extends DoorBlock { + + public CrystalDoorBlock(Settings settings, BlockSetType blockSet) { + super(settings, blockSet); + } + + @Override + public void neighborUpdate(BlockState state, World world, BlockPos pos, Block sourceBlock, BlockPos sourcePos, boolean notify) { + boolean powered = world.isReceivingRedstonePower(pos) || world.isReceivingRedstonePower(pos.offset(state.get(HALF) == DoubleBlockHalf.LOWER ? Direction.UP : Direction.DOWN)); + if (!getDefaultState().isOf(sourceBlock) && powered != state.get(POWERED)) { + if (powered) { + state = state.cycle(OPEN); + playOpenCloseSound(null, world, pos, state.get(OPEN)); + world.emitGameEvent(null, state.get(OPEN) ? GameEvent.BLOCK_OPEN : GameEvent.BLOCK_CLOSE, pos); + } + + world.setBlockState(pos, state.with(POWERED, powered), Block.NOTIFY_LISTENERS); + } + } + + @Override + public ActionResult onUse(BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockHitResult hit) { + if (!EquineContext.of(player).getCompositeRace().any(Race::canCast)) { + + if (!player.getStackInHand(hand).isOf(UItems.MEADOWBROOKS_STAFF)) { + playOpenCloseSound(player, world, pos, false); + return ActionResult.FAIL; + } else { + world.playSound(player, pos, USounds.ENTITY_CRYSTAL_SHARDS_AMBIENT, SoundCategory.BLOCKS, 1, world.getRandom().nextFloat() * 0.1F + 0.9F); + } + } + return super.onUse(state, world, pos, player, hand, hit); + } + + private void playOpenCloseSound(@Nullable Entity entity, World world, BlockPos pos, boolean open) { + world.playSound(entity, pos, open ? getBlockSetType().doorOpen() : getBlockSetType().doorClose(), SoundCategory.BLOCKS, 1, world.getRandom().nextFloat() * 0.1f + 0.9f); + } + +} diff --git a/src/main/java/com/minelittlepony/unicopia/block/FancyBedBlock.java b/src/main/java/com/minelittlepony/unicopia/block/FancyBedBlock.java new file mode 100644 index 00000000..c4a4f2ea --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/block/FancyBedBlock.java @@ -0,0 +1,182 @@ +package com.minelittlepony.unicopia.block; + +import java.util.List; +import java.util.Locale; +import java.util.function.Function; + +import org.jetbrains.annotations.Nullable; + +import com.minelittlepony.unicopia.item.BedsheetsItem; +import com.minelittlepony.unicopia.util.VoxelShapeUtil; + +import net.minecraft.block.BedBlock; +import net.minecraft.block.Block; +import net.minecraft.block.BlockState; +import net.minecraft.block.ShapeContext; +import net.minecraft.block.entity.BedBlockEntity; +import net.minecraft.block.entity.BlockEntity; +import net.minecraft.block.entity.BlockEntityType; +import net.minecraft.block.enums.BedPart; +import net.minecraft.item.ItemStack; +import net.minecraft.nbt.NbtCompound; +import net.minecraft.server.world.ServerWorld; +import net.minecraft.util.DyeColor; +import net.minecraft.util.StringIdentifiable; +import net.minecraft.util.math.BlockPos; +import net.minecraft.util.math.Direction; +import net.minecraft.util.shape.VoxelShape; +import net.minecraft.util.shape.VoxelShapes; +import net.minecraft.world.BlockView; +import net.minecraft.world.World; + +public class FancyBedBlock extends BedBlock { + private static final List> SHAPES = List.of( + VoxelShapeUtil.rotator(VoxelShapes.union( + createCuboidShape(0, 3, 1, 16, 9, 16), + createCuboidShape(-0.5, 0, 1, 1.5, 13, 4), + createCuboidShape(14.5, 0, 1, 16.5, 13, 4), + createCuboidShape(1.5, 1, 0, 14.5, 16, 3) + )), + VoxelShapeUtil.rotator(VoxelShapes.union( + createCuboidShape(0, 3, 0, 16, 9, 16), + createCuboidShape(-0.5, 0, -1, 2.5, 10, 2), + createCuboidShape(13.5, 0, -1, 16.5, 10, 2), + createCuboidShape(1.5, 1, -2, 14.5, 12, 1) + )) + ); + + private final String base; + + public FancyBedBlock(String base, Settings settings) { + super(DyeColor.WHITE, settings); + this.base = base; + } + + @Override + public VoxelShape getOutlineShape(BlockState state, BlockView world, BlockPos pos, ShapeContext context) { + return SHAPES.get(state.get(PART).ordinal()).apply(BedBlock.getOppositePartDirection(state)); + } + + @Override + public BlockEntity createBlockEntity(BlockPos pos, BlockState state) { + return new Tile(pos, state); + } + + public static void setBedPattern(World world, BlockPos pos, SheetPattern pattern) { + world.getBlockEntity(pos, UBlockEntities.FANCY_BED).ifPresent(tile -> { + ItemStack stack = BedsheetsItem.forPattern(tile.getPattern()).getDefaultStack(); + if (!stack.isEmpty()) { + Block.dropStack(world, pos, stack); + } + tile.setPattern(pattern); + BlockState state = tile.getCachedState(); + BlockPos other = pos.offset(getDirectionTowardsOtherPart(state.get(PART), state.get(FACING))); + world.getBlockEntity(other, UBlockEntities.FANCY_BED).ifPresent(tile2 -> { + tile2.setPattern(pattern); + }); + }); + } + + private static Direction getDirectionTowardsOtherPart(BedPart part, Direction direction) { + return part == BedPart.FOOT ? direction : direction.getOpposite(); + } + + public static class Tile extends BedBlockEntity { + private SheetPattern pattern = SheetPattern.NONE; + + public Tile(BlockPos pos, BlockState state) { + super(pos, state); + } + + @Override + public BlockEntityType getType() { + return UBlockEntities.FANCY_BED; + } + + @Override + public void readNbt(NbtCompound nbt) { + pattern = SheetPattern.byId(nbt.getString("pattern")); + } + + @Override + protected void writeNbt(NbtCompound nbt) { + nbt.putString("pattern", pattern.asString()); + } + + @Override + public NbtCompound toInitialChunkDataNbt() { + return createNbt(); + } + + public String getBase() { + return ((FancyBedBlock)getCachedState().getBlock()).base; + } + + public void setPattern(SheetPattern pattern) { + this.pattern = pattern; + markDirty(); + if (world instanceof ServerWorld sw) { + sw.getChunkManager().markForUpdate(getPos()); + } + } + + public SheetPattern getPattern() { + return pattern; + } + } + + public enum SheetPattern implements StringIdentifiable { + NONE(DyeColor.WHITE), + LIGHT_GRAY(DyeColor.LIGHT_GRAY), + GRAY(DyeColor.GRAY), + BLACK(DyeColor.BLACK), + BROWN(DyeColor.BROWN), + RED(DyeColor.RED), + ORANGE(DyeColor.ORANGE), + YELLOW(DyeColor.YELLOW), + LIME(DyeColor.LIME), + GREEN(DyeColor.GREEN), + CYAN(DyeColor.CYAN), + LIGHT_BLUE(DyeColor.LIGHT_BLUE), + BLUE(DyeColor.BLUE), + PURPLE(DyeColor.PURPLE), + MAGENTA(DyeColor.MAGENTA), + PINK(DyeColor.PINK), + + APPLE(null), + BARS(null), + CHECKER(null), + KELP(null), + RAINBOW(null), + RAINBOW_BPW(null), + RAINBOW_BPY(null), + RAINBOW_PBG(null), + RAINBOW_PWR(null); + + @SuppressWarnings("deprecation") + public static final EnumCodec CODEC = StringIdentifiable.createCodec(SheetPattern::values); + + private final String name = name().toLowerCase(Locale.ROOT); + @Nullable + private final DyeColor color; + + SheetPattern(@Nullable DyeColor color) { + this.color = color; + } + + @Nullable + public DyeColor getColor() { + return color; + } + + @Override + public String asString() { + return name; + } + + @SuppressWarnings("deprecation") + public static SheetPattern byId(String id) { + return CODEC.byId(id, NONE); + } + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/block/ShellsBlock.java b/src/main/java/com/minelittlepony/unicopia/block/ShellsBlock.java new file mode 100644 index 00000000..ec5053c8 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/block/ShellsBlock.java @@ -0,0 +1,74 @@ +package com.minelittlepony.unicopia.block; + +import org.jetbrains.annotations.Nullable; + +import net.minecraft.block.Block; +import net.minecraft.block.BlockState; +import net.minecraft.block.ShapeContext; +import net.minecraft.block.Waterloggable; +import net.minecraft.entity.ai.pathing.NavigationType; +import net.minecraft.fluid.FluidState; +import net.minecraft.fluid.Fluids; +import net.minecraft.item.ItemPlacementContext; +import net.minecraft.registry.tag.FluidTags; +import net.minecraft.state.StateManager; +import net.minecraft.state.property.BooleanProperty; +import net.minecraft.state.property.IntProperty; +import net.minecraft.state.property.Properties; +import net.minecraft.util.math.BlockPos; +import net.minecraft.util.math.Direction; +import net.minecraft.util.shape.VoxelShape; +import net.minecraft.world.BlockView; +import net.minecraft.world.WorldAccess; + +public class ShellsBlock extends Block implements Waterloggable { + public static final BooleanProperty WATERLOGGED = Properties.WATERLOGGED; + public static final IntProperty COUNT = IntProperty.of("count", 1, 4); + + private static final VoxelShape SHAPE = Block.createCuboidShape(0, 0, 0, 16, 1, 16); + + public ShellsBlock(Settings settings) { + super(settings); + } + + @Override + @Deprecated + public VoxelShape getOutlineShape(BlockState state, BlockView world, BlockPos pos, ShapeContext context) { + return SHAPE; + } + + @Override + protected void appendProperties(StateManager.Builder builder) { + super.appendProperties(builder); + builder.add(COUNT, WATERLOGGED); + } + + @Override + @Nullable + public BlockState getPlacementState(ItemPlacementContext ctx) { + return getDefaultState().with(WATERLOGGED, ctx.getWorld().getFluidState(ctx.getBlockPos()).getFluid() == Fluids.WATER); + } + + @Deprecated + @Override + public FluidState getFluidState(BlockState state) { + if (state.get(WATERLOGGED).booleanValue()) { + return Fluids.WATER.getStill(false); + } + return super.getFluidState(state); + } + + @Deprecated + @Override + public BlockState getStateForNeighborUpdate(BlockState state, Direction direction, BlockState neighborState, WorldAccess world, BlockPos pos, BlockPos neighborPos) { + if (state.get(WATERLOGGED).booleanValue()) { + world.scheduleFluidTick(pos, Fluids.WATER, Fluids.WATER.getTickRate(world)); + } + return super.getStateForNeighborUpdate(state, direction, neighborState, world, pos, neighborPos); + } + + @Override + public boolean canPathfindThrough(BlockState state, BlockView world, BlockPos pos, NavigationType type) { + return (type == NavigationType.WATER) == world.getFluidState(pos).isIn(FluidTags.WATER); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/block/SlimePustuleBlock.java b/src/main/java/com/minelittlepony/unicopia/block/SlimePustuleBlock.java index 8ce82add..a931844c 100644 --- a/src/main/java/com/minelittlepony/unicopia/block/SlimePustuleBlock.java +++ b/src/main/java/com/minelittlepony/unicopia/block/SlimePustuleBlock.java @@ -1,7 +1,10 @@ package com.minelittlepony.unicopia.block; +import java.util.Arrays; import java.util.Locale; +import org.joml.Vector3f; + import com.minelittlepony.unicopia.USounds; import net.minecraft.block.Block; @@ -14,11 +17,14 @@ import net.minecraft.entity.mob.SlimeEntity; import net.minecraft.entity.player.PlayerEntity; import net.minecraft.item.ItemPlacementContext; import net.minecraft.particle.BlockStateParticleEffect; +import net.minecraft.particle.DustParticleEffect; import net.minecraft.particle.ParticleTypes; import net.minecraft.server.world.ServerWorld; import net.minecraft.sound.SoundCategory; import net.minecraft.state.StateManager; +import net.minecraft.state.property.BooleanProperty; import net.minecraft.state.property.EnumProperty; +import net.minecraft.state.property.Properties; import net.minecraft.util.StringIdentifiable; import net.minecraft.util.math.BlockPos; import net.minecraft.util.math.Box; @@ -34,24 +40,29 @@ import net.minecraft.world.WorldAccess; import net.minecraft.world.WorldView; public class SlimePustuleBlock extends Block { - static final EnumProperty SHAPE = EnumProperty.of("shape", Shape.class); - static final VoxelShape SHAFT_SHAPE = Block.createCuboidShape(7.5, 0, 7.5, 8.5, 16, 8.5); - static final VoxelShape DRIP_SHAPE = VoxelShapes.union( + private static final EnumProperty SHAPE = EnumProperty.of("shape", Shape.class); + private static final BooleanProperty POWERED = Properties.POWERED; + private static final Direction[] DIRECTIONS = Arrays.stream(Direction.values()) + .filter(direction -> direction != Direction.UP) + .toArray(Direction[]::new); + private static final VoxelShape SHAFT_SHAPE = Block.createCuboidShape(7.5, 0, 7.5, 8.5, 16, 8.5); + private static final VoxelShape DRIP_SHAPE = VoxelShapes.union( Block.createCuboidShape(7, 10, 7, 9, 16, 9), Block.createCuboidShape(3, 15, 4, 9, 16, 10), Block.createCuboidShape(7, 15, 7, 12, 16, 12) ); - static final VoxelShape BULB_SHAPE = VoxelShapes.union( + private static final VoxelShape BULB_SHAPE = VoxelShapes.union( Block.createCuboidShape(4, 1, 4, 12, 10, 12), Block.createCuboidShape(5, 10, 5, 11, 13, 11), Block.createCuboidShape(6, 13, 6, 10, 15, 10), Block.createCuboidShape(7, 13, 7, 9, 20, 9) ); - static final VoxelShape CAP_SHAPE = VoxelShapes.union(SHAFT_SHAPE, DRIP_SHAPE); + private static final VoxelShape CAP_SHAPE = VoxelShapes.union(SHAFT_SHAPE, DRIP_SHAPE); + private static final Vector3f DUST_COLOR = new Vector3f(1, 0.2F, 0.1F); public SlimePustuleBlock(Settings settings) { super(settings.ticksRandomly()); - setDefaultState(getDefaultState().with(SHAPE, Shape.DRIP)); + setDefaultState(getDefaultState().with(SHAPE, Shape.DRIP).with(POWERED, false)); } @Override @@ -68,6 +79,17 @@ public class SlimePustuleBlock extends Block { public void randomDisplayTick(BlockState state, World world, BlockPos pos, Random random) { super.randomDisplayTick(state, world, pos, random); + if (state.get(POWERED)) { + + VoxelShape shape = state.getCullingShape(world, pos); + float x = (float)MathHelper.lerp(random.nextFloat(), shape.getMin(Axis.X), shape.getMax(Axis.X)); + float z = (float)MathHelper.lerp(random.nextFloat(), shape.getMin(Axis.Z), shape.getMax(Axis.Z)); + world.addParticle(new DustParticleEffect(DUST_COLOR, 1), + pos.getX() + x, + pos.getY() + random.nextDouble(), + pos.getZ() + z, 0, 0, 0); + } + if (random.nextInt(15) == 0) { VoxelShape shape = state.getCullingShape(world, pos); float x = (float)MathHelper.lerp(random.nextFloat(), shape.getMin(Axis.X), shape.getMax(Axis.X)); @@ -82,7 +104,7 @@ public class SlimePustuleBlock extends Block { @Deprecated @Override public void randomTick(BlockState state, ServerWorld world, BlockPos pos, Random random) { - if (state.get(SHAPE) == Shape.POD) { + if (state.get(SHAPE) == Shape.POD && random.nextInt(130) == 0) { SlimeEntity slime = EntityType.SLIME.create(world); slime.setSize(1, true); slime.setPosition(pos.toCenterPos()); @@ -132,7 +154,7 @@ public class SlimePustuleBlock extends Block { @Override protected void appendProperties(StateManager.Builder builder) { - builder.add(SHAPE); + builder.add(SHAPE, POWERED); } @Deprecated @@ -154,20 +176,66 @@ public class SlimePustuleBlock extends Block { Shape currentShape = state.get(SHAPE); if (direction == Direction.DOWN && (currentShape == Shape.CAP || currentShape == Shape.STRING)) { - return state; + return state.with(POWERED, getReceivedRedstonePower(world, pos) > 0); } Shape shape = determineShape(world, pos); - return state.with(SHAPE, shape); + return state.with(SHAPE, shape).with(POWERED, getReceivedRedstonePower(world, pos) > 0); } - return state; + return state.with(POWERED, getReceivedRedstonePower(world, pos) > 0); } @Override public BlockState getPlacementState(ItemPlacementContext ctx) { Shape shape = determineShape(ctx.getWorld(), ctx.getBlockPos()); - return super.getPlacementState(ctx).with(SHAPE, shape == Shape.STRING ? Shape.POD : shape); + return super.getPlacementState(ctx) + .with(SHAPE, shape == Shape.STRING ? Shape.POD : shape) + .with(POWERED, getReceivedRedstonePower(ctx.getWorld(), ctx.getBlockPos()) > 0); + } + + @Override + @Deprecated + public void onStateReplaced(BlockState state, World world, BlockPos pos, BlockState newState, boolean moved) { + super.onStateReplaced(state, world, pos, newState, moved); + if (state.isOf(this) && newState.isOf(this) && state.get(POWERED) != newState.get(POWERED)) { + world.updateNeighbor(pos.up(), this, pos); + } + } + + @Override + @Deprecated + public boolean emitsRedstonePower(BlockState state) { + return state.get(POWERED); + } + + @Override + @Deprecated + public int getWeakRedstonePower(BlockState state, BlockView world, BlockPos pos, Direction direction) { + if (direction == Direction.DOWN && emitsRedstonePower(state)) { + return 15; + } + return 0; + } + + @Override + @Deprecated + public int getStrongRedstonePower(BlockState state, BlockView world, BlockPos pos, Direction direction) { + if (direction == Direction.DOWN && emitsRedstonePower(state)) { + return 15; + } + return 0; + } + + private int getReceivedRedstonePower(BlockView world, BlockPos pos) { + int power = 0; + for (Direction direction : DIRECTIONS) { + power = Math.max(power, world.getBlockState(pos.offset(direction)).getStrongRedstonePower(world, pos, direction)); + if (power >= 15) { + return Math.min(15, power); + } + } + return Math.min(15, power); } private Shape determineShape(WorldAccess world, BlockPos pos) { diff --git a/src/main/java/com/minelittlepony/unicopia/block/StableDoorBlock.java b/src/main/java/com/minelittlepony/unicopia/block/StableDoorBlock.java index 20a4363c..f170da30 100644 --- a/src/main/java/com/minelittlepony/unicopia/block/StableDoorBlock.java +++ b/src/main/java/com/minelittlepony/unicopia/block/StableDoorBlock.java @@ -11,8 +11,8 @@ import net.minecraft.world.WorldAccess; public class StableDoorBlock extends DoorBlock { - public StableDoorBlock(Settings settings) { - super(settings, BlockSetType.OAK); + public StableDoorBlock(Settings settings, BlockSetType blockSet) { + super(settings, blockSet); } @Override @@ -21,6 +21,12 @@ public class StableDoorBlock extends DoorBlock { if (direction.getAxis() == Direction.Axis.Y && half == DoubleBlockHalf.LOWER == (direction == Direction.UP)) { if (neighborState.isOf(this) && neighborState.get(HALF) != half) { + state = state + .with(FACING, neighborState.get(FACING)) + .with(HINGE, neighborState.get(HINGE)); + if (half == DoubleBlockHalf.UPPER && direction == Direction.DOWN && !state.get(POWERED)) { + state = state.with(OPEN, neighborState.get(OPEN)); + } return state; } diff --git a/src/main/java/com/minelittlepony/unicopia/block/ThornBlock.java b/src/main/java/com/minelittlepony/unicopia/block/ThornBlock.java new file mode 100644 index 00000000..c8ce695f --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/block/ThornBlock.java @@ -0,0 +1,151 @@ +package com.minelittlepony.unicopia.block; + +import java.util.Collection; +import java.util.function.Supplier; +import com.minelittlepony.unicopia.ability.EarthPonyGrowAbility; +import com.minelittlepony.unicopia.entity.mob.UEntities; +import com.minelittlepony.unicopia.util.VecHelper; + +import net.minecraft.block.Block; +import net.minecraft.block.BlockState; +import net.minecraft.block.ConnectingBlock; +import net.minecraft.block.Fertilizable; +import net.minecraft.entity.SpawnReason; +import net.minecraft.particle.ParticleTypes; +import net.minecraft.registry.tag.BlockTags; +import net.minecraft.server.world.ServerWorld; +import net.minecraft.state.StateManager; +import net.minecraft.state.property.BooleanProperty; +import net.minecraft.state.property.DirectionProperty; +import net.minecraft.state.property.IntProperty; +import net.minecraft.state.property.Properties; +import net.minecraft.state.property.Property; +import net.minecraft.util.math.BlockPos; +import net.minecraft.util.math.Direction; +import net.minecraft.util.math.Vec3d; +import net.minecraft.util.math.random.Random; +import net.minecraft.world.World; +import net.minecraft.world.WorldAccess; +import net.minecraft.world.WorldView; + +public class ThornBlock extends ConnectingBlock implements EarthPonyGrowAbility.Growable, Fertilizable { + static final Collection PROPERTIES = FACING_PROPERTIES.values(); + static final DirectionProperty FACING = Properties.FACING; + static final int MAX_DISTANCE = 25; + static final int MAX_AGE = 4; + static final IntProperty DISTANCE = IntProperty.of("distance", 0, MAX_DISTANCE); + static final IntProperty AGE = IntProperty.of("age", 0, MAX_AGE); + + private final Supplier bud; + + public ThornBlock(Settings settings, Supplier bud) { + super(0.125F, settings); + this.bud = bud; + PROPERTIES.forEach(property -> setDefaultState(getDefaultState().with(property, false))); + setDefaultState(getDefaultState() + .with(FACING, Direction.DOWN) + .with(DISTANCE, 0) + .with(AGE, 0) + .with(DOWN, true) + ); + } + + @Override + protected void appendProperties(StateManager.Builder builder) { + builder.add(PROPERTIES.toArray(Property[]::new)); + builder.add(FACING, DISTANCE, AGE); + } + + @Override + @Deprecated + public void randomTick(BlockState state, ServerWorld world, BlockPos pos, Random random) { + if (state.get(AGE) == MAX_AGE + && random.nextInt(1200) == 0 + && world.isPlayerInRange(pos.getX(), pos.getY(), pos.getZ(), 3)) { + UEntities.LOOT_BUG.spawn(world, pos, SpawnReason.NATURAL); + } + } + + @Override + public void scheduledTick(BlockState state, ServerWorld world, BlockPos pos, Random random) { + if (!state.canPlaceAt(world, pos)) { + world.breakBlock(pos, true); + } + } + + @Override + public void randomDisplayTick(BlockState state, World world, BlockPos pos, Random random) { + if (state.get(AGE) == MAX_AGE && world.isPlayerInRange(pos.getX(), pos.getY(), pos.getZ(), 3)) { + Vec3d particlePos = pos.toCenterPos().add(VecHelper.supply(() -> random.nextTriangular(0, 0.5))); + world.addImportantParticle(ParticleTypes.ASH, particlePos.x, particlePos.y, particlePos.z, 0, 0, 0); + } + } + + @Override + public BlockState getStateForNeighborUpdate(BlockState state, Direction direction, BlockState neighborState, WorldAccess world, BlockPos pos, BlockPos neighborPos) { + if (direction == state.get(FACING) && !state.canPlaceAt(world, pos)) { + world.scheduleBlockTick(pos, this, 1); + } + return state; + } + + @Override + public boolean canPlaceAt(BlockState state, WorldView world, BlockPos pos) { + Direction facing = state.get(FACING); + BlockState neighborState = world.getBlockState(pos.offset(facing)); + return (facing == Direction.DOWN && state.get(DISTANCE) == 0 && neighborState.isIn(BlockTags.DIRT)) + || neighborState.isOf(this) + || neighborState.isOf(bud.get()); + } + + @Override + public boolean grow(World world, BlockState state, BlockPos pos) { + if (state.get(DISTANCE) >= MAX_DISTANCE) { + return false; + } + + world.setBlockState(pos, state.with(AGE, Math.min(state.get(AGE) + 1, MAX_AGE))); + return FACING_PROPERTIES.keySet().stream() + .filter(direction -> isConnected(state, world.getBlockState(pos.offset(direction)), direction)) + .map(direction -> { + BlockPos p = pos.offset(direction); + BlockState s = world.getBlockState(p); + if (s.isAir()) { + // sprout a new branch for cut off nodes + world.setBlockState(p, bud.get().getDefaultState() + .with(FACING, direction.getOpposite()) + .with(DISTANCE, state.get(DISTANCE) + 1) + ); + return true; + } + return ((EarthPonyGrowAbility.Growable)s.getBlock()).grow(world, s, p); + }).reduce(false, Boolean::logicalOr); + } + + @Override + public boolean isFertilizable(WorldView world, BlockPos pos, BlockState state) { + return true; + } + + @Override + public boolean canGrow(World world, Random random, BlockPos pos, BlockState state) { + return true; + } + + @Override + public void grow(ServerWorld world, Random random, BlockPos pos, BlockState state) { + grow(world, state, pos); + } + + private boolean isConnected(BlockState state, BlockState neighborState, Direction direction) { + if (!state.get(FACING_PROPERTIES.get(direction))) { + return false; + } + if (neighborState.isAir()) { + return true; + } + return neighborState.getBlock() instanceof EarthPonyGrowAbility.Growable + && (neighborState.isOf(this) || neighborState.isOf(bud.get())) + && neighborState.get(FACING) == direction.getOpposite(); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/block/ThornBudBlock.java b/src/main/java/com/minelittlepony/unicopia/block/ThornBudBlock.java new file mode 100644 index 00000000..5bce939d --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/block/ThornBudBlock.java @@ -0,0 +1,116 @@ +package com.minelittlepony.unicopia.block; + +import java.util.Optional; +import java.util.stream.Stream; + +import com.minelittlepony.unicopia.USounds; +import com.minelittlepony.unicopia.ability.EarthPonyGrowAbility; + +import net.minecraft.block.Block; +import net.minecraft.block.BlockState; +import net.minecraft.block.Blocks; +import net.minecraft.block.Fertilizable; +import net.minecraft.server.world.ServerWorld; +import net.minecraft.sound.SoundCategory; +import net.minecraft.state.StateManager; +import net.minecraft.state.property.DirectionProperty; +import net.minecraft.state.property.IntProperty; +import net.minecraft.state.property.Properties; +import net.minecraft.util.Util; +import net.minecraft.util.math.BlockPos; +import net.minecraft.util.math.Direction; +import net.minecraft.util.math.random.Random; +import net.minecraft.world.World; +import net.minecraft.world.WorldAccess; +import net.minecraft.world.WorldView; + +public class ThornBudBlock extends Block implements EarthPonyGrowAbility.Growable, Fertilizable { + static final DirectionProperty FACING = Properties.FACING; + static final int MAX_DISTANCE = 25; + static final IntProperty DISTANCE = IntProperty.of("distance", 0, MAX_DISTANCE); + + private final BlockState branchState; + + public ThornBudBlock(Settings settings, BlockState branchState) { + super(settings); + setDefaultState(getDefaultState().with(FACING, Direction.DOWN).with(DISTANCE, 0)); + this.branchState = branchState; + } + + @Override + protected void appendProperties(StateManager.Builder builder) { + builder.add(FACING, DISTANCE); + } + + @Override + public void scheduledTick(BlockState state, ServerWorld world, BlockPos pos, Random random) { + if (random.nextInt(50) == 0) { + grow(world, state, pos); + } + } + + @Override + public BlockState getStateForNeighborUpdate(BlockState state, Direction direction, BlockState neighborState, WorldAccess world, BlockPos pos, BlockPos neighborPos) { + if (direction == state.get(FACING) && !(neighborState.isOf(this) || neighborState.isOf(branchState.getBlock()))) { + return Blocks.AIR.getDefaultState(); + } + return state; + } + + @Override + public boolean grow(World world, BlockState state, BlockPos pos) { + if (state.get(DISTANCE) >= MAX_DISTANCE) { + return false; + } + return pickGrowthDirection(world, state, pos).map(randomDirection -> { + BlockPos p = pos.offset(randomDirection); + + if (!canReplace(world.getBlockState(p))) { + return false; + } + + world.playSound(null, pos, USounds.Vanilla.ITEM_BONE_MEAL_USE, SoundCategory.BLOCKS); + world.setBlockState(pos, branchState + .with(FACING, state.get(FACING)) + .with(ThornBlock.FACING_PROPERTIES.get(state.get(FACING)), true) + .with(ThornBlock.FACING_PROPERTIES.get(randomDirection), true)); + world.setBlockState(p, getDefaultState() + .with(FACING, randomDirection.getOpposite()) + .with(DISTANCE, state.get(DISTANCE) + 1) + ); + return true; + }).orElse(false); + } + + protected boolean canReplace(BlockState state) { + return state.isReplaceable(); + } + + private static Optional pickGrowthDirection(World world, BlockState state, BlockPos pos) { + Direction excluded = state.get(FACING); + return Util.getRandomOrEmpty(ThornBlock.FACING_PROPERTIES.keySet().stream() + .filter(direction -> direction != excluded) + .flatMap(direction -> getByWeight(direction, excluded)) + .toList(), world.getRandom()); + } + + private static Stream getByWeight(Direction input, Direction excluded) { + return Stream.generate(() -> input) + .limit(input.getAxis() == excluded.getAxis() ? 6L : input.getAxis() == Direction.Axis.Y ? 1L : 3L); + } + + @Override + public boolean isFertilizable(WorldView world, BlockPos pos, BlockState state) { + return true; + } + + @Override + public boolean canGrow(World world, Random random, BlockPos pos, BlockState state) { + return true; + } + + @Override + public void grow(ServerWorld world, Random random, BlockPos pos, BlockState state) { + grow(world, state, pos); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/block/UBlockEntities.java b/src/main/java/com/minelittlepony/unicopia/block/UBlockEntities.java index d525d275..570be63b 100644 --- a/src/main/java/com/minelittlepony/unicopia/block/UBlockEntities.java +++ b/src/main/java/com/minelittlepony/unicopia/block/UBlockEntities.java @@ -1,16 +1,19 @@ package com.minelittlepony.unicopia.block; import com.minelittlepony.unicopia.block.cloud.CloudBedBlock; +import com.minelittlepony.unicopia.block.cloud.CloudChestBlock; import net.minecraft.block.entity.BlockEntity; import net.minecraft.block.entity.BlockEntityType; import net.minecraft.block.entity.BlockEntityType.Builder; +import net.minecraft.block.entity.ChestBlockEntity; import net.minecraft.registry.Registry; import net.minecraft.registry.Registries; public interface UBlockEntities { BlockEntityType WEATHER_VANE = create("weather_vane", BlockEntityType.Builder.create(WeatherVaneBlock.WeatherVane::new, UBlocks.WEATHER_VANE)); - BlockEntityType CLOUD_BED = create("cloud_bed", BlockEntityType.Builder.create(CloudBedBlock.Tile::new, UBlocks.CLOUD_BED)); + BlockEntityType FANCY_BED = create("fancy_bed", BlockEntityType.Builder.create(CloudBedBlock.Tile::new, UBlocks.CLOTH_BED, UBlocks.CLOUD_BED)); + BlockEntityType CLOUD_CHEST = create("cloud_chest", BlockEntityType.Builder.create(CloudChestBlock.TileData::new, UBlocks.CLOUD_CHEST)); static BlockEntityType create(String id, Builder builder) { return Registry.register(Registries.BLOCK_ENTITY_TYPE, id, builder.build(null)); diff --git a/src/main/java/com/minelittlepony/unicopia/block/UBlocks.java b/src/main/java/com/minelittlepony/unicopia/block/UBlocks.java index 453889d2..b74d0566 100644 --- a/src/main/java/com/minelittlepony/unicopia/block/UBlocks.java +++ b/src/main/java/com/minelittlepony/unicopia/block/UBlocks.java @@ -10,10 +10,16 @@ import com.minelittlepony.unicopia.block.cloud.CloudSlabBlock; import com.minelittlepony.unicopia.block.cloud.CloudStairsBlock; import com.minelittlepony.unicopia.block.cloud.CompactedCloudBlock; import com.minelittlepony.unicopia.block.cloud.NaturalCloudBlock; +import com.minelittlepony.unicopia.block.cloud.OrientedCloudBlock; +import com.minelittlepony.unicopia.block.cloud.PoreousCloudStairsBlock; +import com.minelittlepony.unicopia.block.cloud.ShapingBenchBlock; import com.minelittlepony.unicopia.block.cloud.CloudBedBlock; -import com.minelittlepony.unicopia.block.cloud.CloudBlock; +import com.minelittlepony.unicopia.block.cloud.CloudChestBlock; +import com.minelittlepony.unicopia.block.cloud.CloudDoorBlock; +import com.minelittlepony.unicopia.block.cloud.CloudLike; import com.minelittlepony.unicopia.block.cloud.SoggyCloudBlock; import com.minelittlepony.unicopia.block.cloud.SoggyCloudSlabBlock; +import com.minelittlepony.unicopia.block.cloud.SoggyCloudStairsBlock; import com.minelittlepony.unicopia.block.cloud.UnstableCloudBlock; import com.minelittlepony.unicopia.item.UItems; import com.minelittlepony.unicopia.item.cloud.CloudBlockItem; @@ -130,6 +136,9 @@ public interface UBlocks { SegmentedCropBlock OATS_STEM = register("oats_stem", OATS.createNext(5)); SegmentedCropBlock OATS_CROWN = register("oats_crown", OATS_STEM.createNext(5)); + Block PLUNDER_VINE = register("plunder_vine", new ThornBlock(Settings.create().mapColor(MapColor.DARK_CRIMSON).hardness(1).ticksRandomly().sounds(BlockSoundGroup.WOOD).pistonBehavior(PistonBehavior.DESTROY), () -> UBlocks.PLUNDER_VINE_BUD)); + Block PLUNDER_VINE_BUD = register("plunder_vine_bud", new ThornBudBlock(Settings.create().mapColor(MapColor.DARK_CRIMSON).hardness(1).nonOpaque().ticksRandomly().sounds(BlockSoundGroup.GRASS).pistonBehavior(PistonBehavior.DESTROY), PLUNDER_VINE.getDefaultState())); + Block CHITIN = register("chitin", new SnowyBlock(Settings.create().mapColor(MapColor.PALE_PURPLE).hardness(5).requiresTool().ticksRandomly().sounds(BlockSoundGroup.CORAL)), ItemGroups.NATURAL); Block SURFACE_CHITIN = register("surface_chitin", new GrowableBlock(Settings.copy(CHITIN), () -> CHITIN), ItemGroups.NATURAL); Block CHISELLED_CHITIN = register("chiselled_chitin", new Block(Settings.create().mapColor(MapColor.PALE_PURPLE).hardness(5).requiresTool()), ItemGroups.BUILDING_BLOCKS); @@ -141,27 +150,61 @@ public interface UBlocks { Block MYSTERIOUS_EGG = register("mysterious_egg", new PileBlock(Settings.copy(Blocks.SLIME_BLOCK), PileBlock.MYSTERIOUS_EGG_SHAPES), ItemGroups.NATURAL); Block SLIME_PUSTULE = register("slime_pustule", new SlimePustuleBlock(Settings.copy(Blocks.SLIME_BLOCK)), ItemGroups.NATURAL); + Block SHAPING_BENCH = register("shaping_bench", new ShapingBenchBlock(Settings.create().mapColor(MapColor.OFF_WHITE).hardness(0.3F).resistance(0).sounds(BlockSoundGroup.WOOL)), ItemGroups.FUNCTIONAL); Block CLOUD = register("cloud", new NaturalCloudBlock(Settings.create().mapColor(MapColor.OFF_WHITE).hardness(0.3F).resistance(0).sounds(BlockSoundGroup.WOOL), true, () -> UBlocks.SOGGY_CLOUD, () -> UBlocks.COMPACTED_CLOUD), ItemGroups.NATURAL); + Block COMPACTED_CLOUD = register("compacted_cloud", new CompactedCloudBlock(CLOUD.getDefaultState())); Block CLOUD_SLAB = register("cloud_slab", new CloudSlabBlock(Settings.copy(CLOUD), true, () -> UBlocks.SOGGY_CLOUD_SLAB), ItemGroups.NATURAL); - Block CLOUD_STAIRS = register("cloud_stairs", new CloudStairsBlock(CLOUD.getDefaultState(), Settings.copy(CLOUD), () -> UBlocks.SOGGY_CLOUD_STAIRS), ItemGroups.NATURAL); - Block COMPACTED_CLOUD = register("compacted_cloud", new CompactedCloudBlock(Settings.copy(CLOUD))); - Block CLOUD_PLANKS = register("cloud_planks", new NaturalCloudBlock(Settings.copy(CLOUD).requiresTool(), false, + PoreousCloudStairsBlock CLOUD_STAIRS = register("cloud_stairs", new PoreousCloudStairsBlock(CLOUD.getDefaultState(), Settings.copy(CLOUD), () -> UBlocks.SOGGY_CLOUD_STAIRS), ItemGroups.NATURAL); + + Block CLOUD_PLANKS = register("cloud_planks", new NaturalCloudBlock(Settings.copy(CLOUD).hardness(0.4F).requiresTool().solid(), false, null, () -> UBlocks.COMPACTED_CLOUD_PLANKS), ItemGroups.BUILDING_BLOCKS); - Block CLOUD_PLANKS_SLAB = register("cloud_planks_slab", new CloudSlabBlock(Settings.copy(CLOUD_PLANKS), false, null), ItemGroups.BUILDING_BLOCKS); - Block CLOUD_PLANKS_STAIRS = register("cloud_planks_stairs", new CloudStairsBlock(CLOUD_PLANKS.getDefaultState(), Settings.copy(CLOUD_PLANKS), null), ItemGroups.BUILDING_BLOCKS); - Block COMPACTED_CLOUD_PLANKS = register("compacted_cloud_planks", new CompactedCloudBlock(Settings.copy(CLOUD_PLANKS))); + Block COMPACTED_CLOUD_PLANKS = register("compacted_cloud_planks", new CompactedCloudBlock(CLOUD_PLANKS.getDefaultState())); + Block CLOUD_PLANK_SLAB = register("cloud_plank_slab", new CloudSlabBlock(Settings.copy(CLOUD_PLANKS), false, null), ItemGroups.BUILDING_BLOCKS); + Block CLOUD_PLANK_STAIRS = register("cloud_plank_stairs", new CloudStairsBlock(CLOUD_PLANKS.getDefaultState(), Settings.copy(CLOUD_PLANKS)), ItemGroups.BUILDING_BLOCKS); + + Block CLOUD_BRICKS = register("cloud_bricks", new NaturalCloudBlock(Settings.copy(CLOUD).hardness(0.6F).requiresTool().solid(), false, + null, + () -> UBlocks.COMPACTED_CLOUD_BRICKS), ItemGroups.BUILDING_BLOCKS); + Block COMPACTED_CLOUD_BRICKS = register("compacted_cloud_bricks", new CompactedCloudBlock(CLOUD_BRICKS.getDefaultState())); + Block CLOUD_BRICK_SLAB = register("cloud_brick_slab", new CloudSlabBlock(Settings.copy(CLOUD_BRICKS), false, null), ItemGroups.BUILDING_BLOCKS); + Block CLOUD_BRICK_STAIRS = register("cloud_brick_stairs", new CloudStairsBlock(CLOUD_BRICKS.getDefaultState(), Settings.copy(CLOUD_PLANKS)), ItemGroups.BUILDING_BLOCKS); + + Block ETCHED_CLOUD = register("etched_cloud", new NaturalCloudBlock(Settings.copy(CLOUD_BRICKS), false, + null, + () -> UBlocks.COMPACTED_CLOUD_BRICKS), ItemGroups.BUILDING_BLOCKS); + Block COMPACTED_ETCHED_CLOUD = register("compacted_etched_cloud", new CompactedCloudBlock(ETCHED_CLOUD.getDefaultState())); + Block ETCHED_CLOUD_SLAB = register("etched_cloud_slab", new CloudSlabBlock(Settings.copy(ETCHED_CLOUD), false, null), ItemGroups.BUILDING_BLOCKS); + Block ETCHED_CLOUD_STAIRS = register("etched_cloud_stairs", new CloudStairsBlock(ETCHED_CLOUD.getDefaultState(), Settings.copy(CLOUD_PLANKS)), ItemGroups.BUILDING_BLOCKS); + + SoggyCloudBlock SOGGY_CLOUD = register("soggy_cloud", new SoggyCloudBlock(Settings.copy(CLOUD).hardness(0.7F), () -> UBlocks.CLOUD)); + SoggyCloudSlabBlock SOGGY_CLOUD_SLAB = register("soggy_cloud_slab", new SoggyCloudSlabBlock(Settings.copy(SOGGY_CLOUD), () -> UBlocks.CLOUD_SLAB)); + SoggyCloudStairsBlock SOGGY_CLOUD_STAIRS = register("soggy_cloud_stairs", new SoggyCloudStairsBlock(SOGGY_CLOUD.getDefaultState(), Settings.copy(CLOUD), () -> UBlocks.CLOUD_STAIRS)); + + Block DENSE_CLOUD = register("dense_cloud", new NaturalCloudBlock(Settings.create().mapColor(MapColor.GRAY).hardness(0.5F).resistance(0).sounds(BlockSoundGroup.WOOL).solid(), false, + null, + () -> UBlocks.COMPACTED_DENSE_CLOUD), ItemGroups.BUILDING_BLOCKS); + Block COMPACTED_DENSE_CLOUD = register("compacted_dense_cloud", new CompactedCloudBlock(DENSE_CLOUD.getDefaultState())); + Block DENSE_CLOUD_SLAB = register("dense_cloud_slab", new CloudSlabBlock(Settings.copy(DENSE_CLOUD), false, null), ItemGroups.BUILDING_BLOCKS); + Block DENSE_CLOUD_STAIRS = register("dense_cloud_stairs", new CloudStairsBlock(DENSE_CLOUD.getDefaultState(), Settings.copy(DENSE_CLOUD)), ItemGroups.BUILDING_BLOCKS); + + Block CARVED_CLOUD = register("carved_cloud", new OrientedCloudBlock(Settings.copy(CLOUD).hardness(0.4F).requiresTool().solid(), false), ItemGroups.BUILDING_BLOCKS); Block UNSTABLE_CLOUD = register("unstable_cloud", new UnstableCloudBlock(Settings.copy(CLOUD)), ItemGroups.NATURAL); - SoggyCloudBlock SOGGY_CLOUD = register("soggy_cloud", new SoggyCloudBlock(Settings.copy(CLOUD), () -> UBlocks.CLOUD)); - SoggyCloudSlabBlock SOGGY_CLOUD_SLAB = register("soggy_cloud_slab", new SoggyCloudSlabBlock(Settings.copy(CLOUD), () -> UBlocks.CLOUD_SLAB)); - CloudStairsBlock SOGGY_CLOUD_STAIRS = register("soggy_cloud_stairs", new CloudStairsBlock(SOGGY_CLOUD.getDefaultState(), Settings.copy(CLOUD), null)); - Block DENSE_CLOUD = register("dense_cloud", new CloudBlock(Settings.create().mapColor(MapColor.GRAY).hardness(0.5F).resistance(0).sounds(BlockSoundGroup.WOOL), false), ItemGroups.NATURAL); - Block DENSE_CLOUD_SLAB = register("dense_cloud_slab", new CloudSlabBlock(Settings.copy(DENSE_CLOUD), false, null), ItemGroups.NATURAL); - Block DENSE_CLOUD_STAIRS = register("dense_cloud_stairs", new CloudStairsBlock(DENSE_CLOUD.getDefaultState(), Settings.copy(DENSE_CLOUD), null), ItemGroups.NATURAL); - Block CLOUD_PILLAR = register("cloud_pillar", new CloudPillarBlock(Settings.create().mapColor(MapColor.GRAY).hardness(0.5F).resistance(0).sounds(BlockSoundGroup.WOOL)), ItemGroups.NATURAL); - Block CLOUD_BED = register("cloud_bed", new CloudBedBlock(CLOUD.getDefaultState(), Settings.copy(Blocks.WHITE_BED).sounds(BlockSoundGroup.WOOL))); + Block CLOUD_PILLAR = register("cloud_pillar", new CloudPillarBlock(Settings.create().mapColor(MapColor.GRAY).hardness(0.5F).resistance(0).sounds(BlockSoundGroup.WOOL).solid()), ItemGroups.NATURAL); + Block CLOUD_CHEST = register("cloud_chest", new CloudChestBlock(Settings.copy(DENSE_CLOUD).instrument(Instrument.BASS).strength(2.5f), DENSE_CLOUD.getDefaultState()), ItemGroups.FUNCTIONAL); + Block CLOTH_BED = register("cloth_bed", new FancyBedBlock("cloth", Settings.copy(Blocks.WHITE_BED).sounds(BlockSoundGroup.WOOD))); + Block CLOUD_BED = register("cloud_bed", new CloudBedBlock("cloud", CLOUD.getDefaultState(), Settings.copy(Blocks.WHITE_BED).sounds(BlockSoundGroup.WOOL))); + + Block CLAM_SHELL = register("clam_shell", new ShellsBlock(Settings.create().mapColor(MapColor.DULL_PINK).breakInstantly().nonOpaque())); + Block SCALLOP_SHELL = register("scallop_shell", new ShellsBlock(Settings.create().mapColor(MapColor.DULL_PINK).breakInstantly().nonOpaque())); + Block TURRET_SHELL = register("turret_shell", new ShellsBlock(Settings.create().mapColor(MapColor.DULL_PINK).breakInstantly().nonOpaque())); + + Block STABLE_DOOR = register("stable_door", new StableDoorBlock(Settings.copy(Blocks.OAK_DOOR), BlockSetType.OAK), ItemGroups.FUNCTIONAL); + Block DARK_OAK_DOOR = register("dark_oak_stable_door", new StableDoorBlock(Settings.copy(Blocks.OAK_DOOR), BlockSetType.OAK), ItemGroups.FUNCTIONAL); + Block CRYSTAL_DOOR = register("crystal_door", new CrystalDoorBlock(Settings.copy(Blocks.IRON_DOOR), UWoodTypes.CRYSTAL), ItemGroups.FUNCTIONAL); + Block CLOUD_DOOR = register("cloud_door", new CloudDoorBlock(Settings.copy(CLOUD), CLOUD.getDefaultState(), UWoodTypes.CLOUD), ItemGroups.FUNCTIONAL); private static T register(String name, T item) { return register(Unicopia.id(name), item); @@ -172,9 +215,7 @@ public interface UBlocks { } static T register(Identifier id, T block, RegistryKey group) { - ItemGroupRegistry.register(id, - CloudBlock.isCloudBlock(block) ? new CloudBlockItem(block, new Item.Settings()) : new BlockItem(block, new Item.Settings() - ), group); + ItemGroupRegistry.register(id, block instanceof CloudLike ? new CloudBlockItem(block, new Item.Settings()) : new BlockItem(block, new Item.Settings()), group); return register(id, block); } @@ -185,7 +226,7 @@ public interface UBlocks { if (block instanceof SaplingBlock || block instanceof SproutBlock || block instanceof FruitBlock || block instanceof CropBlock || block instanceof DoorBlock || block instanceof TrapdoorBlock) { TRANSLUCENT_BLOCKS.add(block); } - if (CloudBlock.isCloudBlock(block) || block instanceof SlimePustuleBlock || block instanceof PileBlock) { + if (block instanceof CloudLike || block instanceof SlimePustuleBlock || block instanceof PileBlock) { SEMI_TRANSPARENT_BLOCKS.add(block); } return Registry.register(Registries.BLOCK, id, block); @@ -199,7 +240,7 @@ public interface UBlocks { StrippableBlockRegistry.register(PALM_LOG, STRIPPED_PALM_LOG); StrippableBlockRegistry.register(ZAP_WOOD, STRIPPED_ZAP_WOOD); StrippableBlockRegistry.register(PALM_WOOD, STRIPPED_PALM_WOOD); - Collections.addAll(TRANSLUCENT_BLOCKS, WEATHER_VANE, CHITIN_SPIKES); + Collections.addAll(TRANSLUCENT_BLOCKS, WEATHER_VANE, CHITIN_SPIKES, PLUNDER_VINE, PLUNDER_VINE_BUD, CLAM_SHELL, SCALLOP_SHELL, TURRET_SHELL); TintedBlock.REGISTRY.add(PALM_LEAVES); FlammableBlockRegistry.getDefaultInstance().add(GREEN_APPLE_LEAVES, 30, 60); diff --git a/src/main/java/com/minelittlepony/unicopia/block/UWoodTypes.java b/src/main/java/com/minelittlepony/unicopia/block/UWoodTypes.java index 5f090ce9..0a44586e 100644 --- a/src/main/java/com/minelittlepony/unicopia/block/UWoodTypes.java +++ b/src/main/java/com/minelittlepony/unicopia/block/UWoodTypes.java @@ -1,25 +1,34 @@ package com.minelittlepony.unicopia.block; +import com.minelittlepony.unicopia.USounds; import com.minelittlepony.unicopia.Unicopia; import com.terraformersmc.terraform.boat.api.TerraformBoatType; import com.terraformersmc.terraform.boat.api.TerraformBoatTypeRegistry; import net.fabricmc.fabric.api.object.builder.v1.block.type.BlockSetTypeBuilder; import net.fabricmc.fabric.api.object.builder.v1.block.type.WoodTypeBuilder; +import net.minecraft.block.BlockSetType; import net.minecraft.block.WoodType; import net.minecraft.registry.RegistryKey; +import net.minecraft.sound.BlockSoundGroup; import net.minecraft.util.Identifier; public interface UWoodTypes { WoodType PALM = register("palm"); RegistryKey PALM_BOAT_TYPE = TerraformBoatTypeRegistry.createKey(Unicopia.id("palm")); + BlockSetType CLOUD = new BlockSetTypeBuilder() + .soundGroup(BlockSoundGroup.WOOL) + .doorCloseSound(USounds.Vanilla.BLOCK_WOOL_HIT) + .doorOpenSound(USounds.Vanilla.BLOCK_WOOL_BREAK) + .register(Unicopia.id("cloud")); + BlockSetType CRYSTAL = BlockSetTypeBuilder.copyOf(BlockSetType.IRON) + .soundGroup(BlockSoundGroup.AMETHYST_BLOCK) + .openableByHand(true) + .register(Unicopia.id("crystal")); + static WoodType register(String name) { Identifier id = Unicopia.id(name); return new WoodTypeBuilder().register(id, new BlockSetTypeBuilder().register(id)); } - - - - } diff --git a/src/main/java/com/minelittlepony/unicopia/block/ZapAppleLeavesBlock.java b/src/main/java/com/minelittlepony/unicopia/block/ZapAppleLeavesBlock.java index b036532a..4e83cbcf 100644 --- a/src/main/java/com/minelittlepony/unicopia/block/ZapAppleLeavesBlock.java +++ b/src/main/java/com/minelittlepony/unicopia/block/ZapAppleLeavesBlock.java @@ -3,6 +3,7 @@ package com.minelittlepony.unicopia.block; import com.minelittlepony.unicopia.server.world.ZapAppleStageStore; import net.minecraft.block.*; +import net.minecraft.item.ItemPlacementContext; import net.minecraft.server.world.ServerWorld; import net.minecraft.state.StateManager; import net.minecraft.state.property.*; @@ -13,12 +14,13 @@ public class ZapAppleLeavesBlock extends BaseZapAppleLeavesBlock { public static final EnumProperty STAGE = EnumProperty.of("stage", ZapAppleStageStore.Stage.class); ZapAppleLeavesBlock() { - setDefaultState(getDefaultState().with(STAGE, ZapAppleStageStore.Stage.HIBERNATING)); + setDefaultState(getDefaultState().with(STAGE, ZapAppleStageStore.Stage.GREENING)); } @Override public void onBlockAdded(BlockState state, World world, BlockPos pos, BlockState oldState, boolean notify) { - if (oldState.isOf(state.getBlock()) + if (state.get(PERSISTENT) + || oldState.isOf(state.getBlock()) || oldState.isOf(UBlocks.ZAP_LEAVES) || oldState.isOf(UBlocks.FLOWERING_ZAP_LEAVES) || oldState.isOf(UBlocks.ZAP_LEAVES_PLACEHOLDER) @@ -33,6 +35,11 @@ public class ZapAppleLeavesBlock extends BaseZapAppleLeavesBlock { } } + @Override + public BlockState getPlacementState(ItemPlacementContext ctx) { + return super.getPlacementState(ctx).with(STAGE, ZapAppleStageStore.Stage.GREENING); + } + @Override protected ZapAppleStageStore.Stage getStage(BlockState state) { return state.get(STAGE); diff --git a/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudBedBlock.java b/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudBedBlock.java index 33794c02..6ecc1497 100644 --- a/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudBedBlock.java +++ b/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudBedBlock.java @@ -3,20 +3,14 @@ package com.minelittlepony.unicopia.block.cloud; import org.jetbrains.annotations.Nullable; import com.minelittlepony.unicopia.EquineContext; -import com.minelittlepony.unicopia.block.UBlockEntities; - -import net.minecraft.block.BedBlock; +import com.minelittlepony.unicopia.block.FancyBedBlock; import net.minecraft.block.BlockState; import net.minecraft.block.ShapeContext; -import net.minecraft.block.entity.BedBlockEntity; -import net.minecraft.block.entity.BlockEntity; -import net.minecraft.block.entity.BlockEntityType; import net.minecraft.entity.Entity; import net.minecraft.entity.ai.pathing.NavigationType; import net.minecraft.entity.player.PlayerEntity; import net.minecraft.item.ItemPlacementContext; import net.minecraft.util.ActionResult; -import net.minecraft.util.DyeColor; import net.minecraft.util.Hand; import net.minecraft.util.hit.BlockHitResult; import net.minecraft.util.math.BlockPos; @@ -25,12 +19,12 @@ import net.minecraft.util.shape.VoxelShapes; import net.minecraft.world.BlockView; import net.minecraft.world.World; -public class CloudBedBlock extends BedBlock { +public class CloudBedBlock extends FancyBedBlock implements CloudLike { private final BlockState baseState; private final CloudBlock baseBlock; - public CloudBedBlock(BlockState baseState, Settings settings) { - super(DyeColor.WHITE, settings); + public CloudBedBlock(String base, BlockState baseState, Settings settings) { + super(base, settings); this.baseState = baseState; this.baseBlock = (CloudBlock)baseState.getBlock(); } @@ -83,20 +77,4 @@ public class CloudBedBlock extends BedBlock { public boolean canPathfindThrough(BlockState state, BlockView world, BlockPos pos, NavigationType type) { return true; } - - @Override - public BlockEntity createBlockEntity(BlockPos pos, BlockState state) { - return new Tile(pos, state); - } - - public static class Tile extends BedBlockEntity { - public Tile(BlockPos pos, BlockState state) { - super(pos, state); - } - - @Override - public BlockEntityType getType() { - return UBlockEntities.CLOUD_BED; - } - } } diff --git a/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudBlock.java b/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudBlock.java index 812f157a..490d7e4d 100644 --- a/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudBlock.java +++ b/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudBlock.java @@ -26,11 +26,7 @@ import net.minecraft.world.EmptyBlockView; import net.minecraft.world.LightType; import net.minecraft.world.World; -public class CloudBlock extends Block { - public static boolean isCloudBlock(Block block) { - return block instanceof CloudBlock || block instanceof CloudStairsBlock || block instanceof CloudBedBlock; - } - +public class CloudBlock extends Block implements CloudLike { protected final boolean meltable; public CloudBlock(Settings settings, boolean meltable) { @@ -59,7 +55,7 @@ public class CloudBlock extends Block { entity.handleFallDamage(fallDistance, 0, world.getDamageSources().fall()); generateSurfaceParticles(world, state, pos, ShapeContext.absent(), 9); - if (fallDistance > 7) { + if (!world.isClient && fallDistance > 7) { world.breakBlock(pos, true); } } diff --git a/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudChestBlock.java b/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudChestBlock.java new file mode 100644 index 00000000..cc6bb636 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudChestBlock.java @@ -0,0 +1,159 @@ +package com.minelittlepony.unicopia.block.cloud; + +import java.util.Optional; + +import org.jetbrains.annotations.Nullable; + +import com.minelittlepony.unicopia.EquineContext; +import com.minelittlepony.unicopia.block.UBlockEntities; +import net.minecraft.block.BlockState; +import net.minecraft.block.ChestBlock; +import net.minecraft.block.DoubleBlockProperties; +import net.minecraft.block.ShapeContext; +import net.minecraft.block.entity.BlockEntity; +import net.minecraft.block.entity.BlockEntityType; +import net.minecraft.block.entity.ChestBlockEntity; +import net.minecraft.entity.Entity; +import net.minecraft.entity.ai.pathing.NavigationType; +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.entity.player.PlayerInventory; +import net.minecraft.inventory.DoubleInventory; +import net.minecraft.item.ItemPlacementContext; +import net.minecraft.screen.GenericContainerScreenHandler; +import net.minecraft.screen.NamedScreenHandlerFactory; +import net.minecraft.screen.ScreenHandler; +import net.minecraft.text.Text; +import net.minecraft.util.ActionResult; +import net.minecraft.util.Hand; +import net.minecraft.util.hit.BlockHitResult; +import net.minecraft.util.math.BlockPos; +import net.minecraft.util.shape.VoxelShape; +import net.minecraft.util.shape.VoxelShapes; +import net.minecraft.world.BlockView; +import net.minecraft.world.World; + +public class CloudChestBlock extends ChestBlock implements CloudLike { + private final BlockState baseState; + private final CloudBlock baseBlock; + + private static final DoubleBlockProperties.PropertyRetriever> NAME_RETRIEVER = new DoubleBlockProperties.PropertyRetriever<>(){ + @Override + public Optional getFromBoth(final ChestBlockEntity first, final ChestBlockEntity second) { + final DoubleInventory inventory = new DoubleInventory(first, second); + return Optional.of(new NamedScreenHandlerFactory(){ + @Override + @Nullable + public ScreenHandler createMenu(int i, PlayerInventory playerInventory, PlayerEntity player) { + if (first.checkUnlocked(player) && second.checkUnlocked(player)) { + first.checkLootInteraction(playerInventory.player); + second.checkLootInteraction(playerInventory.player); + return GenericContainerScreenHandler.createGeneric9x6(i, playerInventory, inventory); + } + return null; + } + + @Override + public Text getDisplayName() { + if (first.hasCustomName()) { + return first.getDisplayName(); + } + if (second.hasCustomName()) { + return second.getDisplayName(); + } + return Text.translatable(first.getCachedState().getBlock().getTranslationKey() + ".double"); + } + }); + } + + @Override + public Optional getFrom(ChestBlockEntity chest) { + return Optional.of(chest); + } + + @Override + public Optional getFallback() { + return Optional.empty(); + } + }; + + public CloudChestBlock(Settings settings, BlockState baseState) { + super(settings, () -> UBlockEntities.CLOUD_CHEST); + this.baseState = baseState; + this.baseBlock = (CloudBlock)baseState.getBlock(); + } + + @Override + public BlockEntity createBlockEntity(BlockPos pos, BlockState state) { + return new TileData(pos, state); + } + + @Override + @Nullable + public NamedScreenHandlerFactory createScreenHandlerFactory(BlockState state, World world, BlockPos pos) { + return getBlockEntitySource(state, world, pos, false).apply(NAME_RETRIEVER).orElse(null); + } + + @Override + public final VoxelShape getOutlineShape(BlockState state, BlockView world, BlockPos pos, ShapeContext context) { + if (!baseBlock.canInteract(baseState, world, pos, EquineContext.of(context))) { + return VoxelShapes.empty(); + } + return super.getOutlineShape(state, world, pos, context); + } + + @Override + @Deprecated + public final VoxelShape getCullingShape(BlockState state, BlockView world, BlockPos pos) { + return super.getOutlineShape(state, world, pos, ShapeContext.absent()); + } + + @Override + @Deprecated + public VoxelShape getCollisionShape(BlockState state, BlockView world, BlockPos pos, ShapeContext context) { + return this.collidable ? state.getOutlineShape(world, pos, context) : VoxelShapes.empty(); + } + + @Override + @Nullable + public final BlockState getPlacementState(ItemPlacementContext context) { + if (!baseBlock.canInteract(baseState, context.getWorld(), context.getBlockPos(), EquineContext.of(context))) { + return null; + } + return super.getPlacementState(context); + } + + @Override + public ActionResult onUse(BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockHitResult hit) { + if (!baseBlock.canInteract(baseState, world, pos, EquineContext.of(player))) { + return ActionResult.PASS; + } + return super.onUse(state, world, pos, player, hand, hit); + } + + @Deprecated + @Override + public void onEntityCollision(BlockState state, World world, BlockPos pos, Entity entity) { + baseState.onEntityCollision(world, pos, entity); + } + + @Override + @Deprecated + public boolean canPathfindThrough(BlockState state, BlockView world, BlockPos pos, NavigationType type) { + return true; + } + + public static class TileData extends ChestBlockEntity { + protected TileData(BlockEntityType blockEntityType, BlockPos blockPos, BlockState blockState) { + super(blockEntityType, blockPos, blockState); + } + + public TileData(BlockPos pos, BlockState state) { + super(UBlockEntities.CLOUD_CHEST, pos, state); + } + + @Override + protected Text getContainerName() { + return getCachedState().getBlock().getName(); + } + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudDoorBlock.java b/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudDoorBlock.java new file mode 100644 index 00000000..be730174 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudDoorBlock.java @@ -0,0 +1,87 @@ +package com.minelittlepony.unicopia.block.cloud; + +import org.jetbrains.annotations.Nullable; + +import com.minelittlepony.unicopia.EquineContext; +import com.minelittlepony.unicopia.Race; + +import net.minecraft.block.BlockSetType; +import net.minecraft.block.BlockState; +import net.minecraft.block.DoorBlock; +import net.minecraft.block.ShapeContext; +import net.minecraft.entity.Entity; +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.item.ItemPlacementContext; +import net.minecraft.util.ActionResult; +import net.minecraft.util.Hand; +import net.minecraft.util.hit.BlockHitResult; +import net.minecraft.util.math.BlockPos; +import net.minecraft.util.shape.VoxelShape; +import net.minecraft.util.shape.VoxelShapes; +import net.minecraft.world.BlockView; +import net.minecraft.world.World; + +public class CloudDoorBlock extends DoorBlock implements CloudLike { + private final BlockState baseState; + private final CloudBlock baseBlock; + + public CloudDoorBlock(Settings settings, BlockState baseState, BlockSetType blockSet) { + super(settings, blockSet); + this.baseState = baseState; + this.baseBlock = (CloudBlock)baseState.getBlock(); + } + + + @Override + public final VoxelShape getOutlineShape(BlockState state, BlockView world, BlockPos pos, ShapeContext context) { + if (canPassThrough(state, world, pos, EquineContext.of(context))) { + return VoxelShapes.empty(); + } + return super.getOutlineShape(state, world, pos, context); + } + + protected boolean canPassThrough(BlockState state, BlockView world, BlockPos pos, EquineContext context) { + return context.getCompositeRace().any(Race::canUseEarth); + } + + @Override + @Deprecated + public final VoxelShape getCullingShape(BlockState state, BlockView world, BlockPos pos) { + return super.getOutlineShape(state, world, pos, ShapeContext.absent()); + } + + @Override + @Deprecated + public VoxelShape getCollisionShape(BlockState state, BlockView world, BlockPos pos, ShapeContext context) { + return this.collidable ? state.getOutlineShape(world, pos, context) : VoxelShapes.empty(); + } + + @Override + @Nullable + public final BlockState getPlacementState(ItemPlacementContext context) { + if (!baseBlock.canInteract(baseState, context.getWorld(), context.getBlockPos(), EquineContext.of(context))) { + return null; + } + return super.getPlacementState(context); + } + + @Override + public ActionResult onUse(BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockHitResult hit) { + if (!baseBlock.canInteract(baseState, world, pos, EquineContext.of(player))) { + return ActionResult.PASS; + } + return super.onUse(state, world, pos, player, hand, hit); + } + + @Deprecated + @Override + public void onEntityCollision(BlockState state, World world, BlockPos pos, Entity entity) { + baseState.onEntityCollision(world, pos, entity); + + EquineContext context = EquineContext.of(entity); + + if (!baseBlock.canInteract(baseState, world, pos, context)) { + entity.setVelocity(entity.getVelocity().multiply(0.5F, 1, 0.5F)); + } + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudLike.java b/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudLike.java new file mode 100644 index 00000000..ec9ef4fd --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudLike.java @@ -0,0 +1,5 @@ +package com.minelittlepony.unicopia.block.cloud; + +public interface CloudLike { + +} diff --git a/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudStairsBlock.java b/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudStairsBlock.java index c599ba70..bafd9e21 100644 --- a/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudStairsBlock.java +++ b/src/main/java/com/minelittlepony/unicopia/block/cloud/CloudStairsBlock.java @@ -1,7 +1,5 @@ package com.minelittlepony.unicopia.block.cloud; -import java.util.function.Supplier; - import org.jetbrains.annotations.Nullable; import com.minelittlepony.unicopia.EquineContext; @@ -18,15 +16,13 @@ import net.minecraft.util.shape.VoxelShapes; import net.minecraft.world.BlockView; import net.minecraft.world.World; -public class CloudStairsBlock extends StairsBlock implements Soakable { +public class CloudStairsBlock extends StairsBlock implements CloudLike { private final CloudBlock baseBlock; - private final @Nullable Supplier soggyBlock; - public CloudStairsBlock(BlockState baseState, Settings settings, @Nullable Supplier soggyBlock) { + public CloudStairsBlock(BlockState baseState, Settings settings) { super(baseState, settings); this.baseBlock = (CloudBlock)baseState.getBlock(); - this.soggyBlock = soggyBlock; } @Override @@ -92,15 +88,4 @@ public class CloudStairsBlock extends StairsBlock implements Soakable { public boolean canPathfindThrough(BlockState state, BlockView world, BlockPos pos, NavigationType type) { return true; } - - @Nullable - @Override - public BlockState getSoggyState(int moisture) { - return soggyBlock == null ? (baseBlock instanceof Soakable s ? s.getSoggyState(moisture) : null) : soggyBlock.get().getSoggyState(moisture); - } - - @Override - public int getMoisture(BlockState state) { - return baseBlock instanceof Soakable s ? s.getMoisture(state) : 0; - } } diff --git a/src/main/java/com/minelittlepony/unicopia/block/cloud/CompactedCloudBlock.java b/src/main/java/com/minelittlepony/unicopia/block/cloud/CompactedCloudBlock.java index 1d869d47..a9e6f727 100644 --- a/src/main/java/com/minelittlepony/unicopia/block/cloud/CompactedCloudBlock.java +++ b/src/main/java/com/minelittlepony/unicopia/block/cloud/CompactedCloudBlock.java @@ -19,6 +19,8 @@ import net.minecraft.state.StateManager; import net.minecraft.state.property.BooleanProperty; import net.minecraft.state.property.Property; import net.minecraft.util.ActionResult; +import net.minecraft.util.BlockMirror; +import net.minecraft.util.BlockRotation; import net.minecraft.util.Hand; import net.minecraft.util.Util; import net.minecraft.util.hit.BlockHitResult; @@ -43,13 +45,21 @@ public class CompactedCloudBlock extends CloudBlock { ); }); - public CompactedCloudBlock(Settings settings) { - super(settings, true); + private final BlockState baseState; + + public CompactedCloudBlock(BlockState baseState) { + super(Settings.copy(baseState.getBlock()).dropsLike(baseState.getBlock()), true); + this.baseState = baseState; PROPERTIES.forEach(property -> { setDefaultState(getDefaultState().with(property, true)); }); } + @Override + public ItemStack getPickStack(BlockView world, BlockPos pos, BlockState state) { + return baseState.getBlock().getPickStack(world, pos, baseState); + } + @Override protected VoxelShape getOutlineShape(BlockState state, BlockView world, BlockPos pos, ShapeContext context, EquineContext equineContext) { return SHAPE_CACHE.apply(state); @@ -76,4 +86,24 @@ public class CompactedCloudBlock extends CloudBlock { return ActionResult.PASS; } + + @Override + public BlockState rotate(BlockState state, BlockRotation rotation) { + return transform(state, rotation::rotate); + } + + @Override + public BlockState mirror(BlockState state, BlockMirror mirror) { + return transform(state, mirror::apply); + } + + private BlockState transform(BlockState state, Function transformation) { + BlockState result = state; + for (var property : FACING_PROPERTIES.entrySet()) { + if (property.getKey().getAxis() != Direction.Axis.Y) { + result = result.with(FACING_PROPERTIES.get(transformation.apply(property.getKey())), state.get(property.getValue())); + } + } + return result; + } } diff --git a/src/main/java/com/minelittlepony/unicopia/block/cloud/OrientedCloudBlock.java b/src/main/java/com/minelittlepony/unicopia/block/cloud/OrientedCloudBlock.java new file mode 100644 index 00000000..2d3886db --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/block/cloud/OrientedCloudBlock.java @@ -0,0 +1,42 @@ +package com.minelittlepony.unicopia.block.cloud; + +import com.minelittlepony.unicopia.EquineContext; + +import net.minecraft.block.Block; +import net.minecraft.block.BlockState; +import net.minecraft.item.ItemPlacementContext; +import net.minecraft.state.StateManager; +import net.minecraft.state.property.DirectionProperty; +import net.minecraft.state.property.Properties; +import net.minecraft.util.BlockMirror; +import net.minecraft.util.BlockRotation; +import net.minecraft.util.math.Direction; + +public class OrientedCloudBlock extends CloudBlock { + public static final DirectionProperty FACING = Properties.FACING; + + public OrientedCloudBlock(Settings settings, boolean meltable) { + super(settings, meltable); + this.setDefaultState(getDefaultState().with(FACING, Direction.UP)); + } + + @Override + protected void appendProperties(StateManager.Builder builder) { + builder.add(FACING); + } + + @Override + public BlockState rotate(BlockState state, BlockRotation rotation) { + return state.with(FACING, rotation.rotate(state.get(FACING))); + } + + @Override + public BlockState mirror(BlockState state, BlockMirror mirror) { + return state.rotate(mirror.getRotation(state.get(FACING))); + } + + @Override + public BlockState getPlacementState(ItemPlacementContext ctx, EquineContext equineContext) { + return getDefaultState().with(FACING, ctx.getSide().getOpposite()); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/block/cloud/PoreousCloudBlock.java b/src/main/java/com/minelittlepony/unicopia/block/cloud/PoreousCloudBlock.java index 591ea39e..5e17ca06 100644 --- a/src/main/java/com/minelittlepony/unicopia/block/cloud/PoreousCloudBlock.java +++ b/src/main/java/com/minelittlepony/unicopia/block/cloud/PoreousCloudBlock.java @@ -20,20 +20,22 @@ public class PoreousCloudBlock extends CloudBlock implements Soakable { @Nullable @Override - public BlockState getSoggyState(int moisture) { - return soggyBlock == null ? null : soggyBlock.get().getSoggyState(moisture); - } - - @Override - public int getMoisture(BlockState state) { - return 0; + public BlockState getStateWithMoisture(BlockState state, int moisture) { + if (moisture <= 0) { + return Soakable.copyProperties(state, getDefaultState()); + } + return soggyBlock == null ? null : soggyBlock.get().getStateWithMoisture(state, moisture); } @Override public void randomTick(BlockState state, ServerWorld world, BlockPos pos, Random random) { - if (soggyBlock != null && world.hasRain(pos) && world.isAir(pos.up())) { - world.setBlockState(pos, Soakable.copyProperties(state, soggyBlock.get().getSoggyState(random.nextBetween(1, 5)))); - return; + if (state.getBlock() instanceof Soakable soakable && world.hasRain(pos) && world.isAir(pos.up())) { + @Nullable + BlockState soggyState = soakable.getStateWithMoisture(state, random.nextBetween(1, 5)); + if (soggyState != null) { + world.setBlockState(pos, soggyState); + return; + } } super.randomTick(state, world, pos, random); diff --git a/src/main/java/com/minelittlepony/unicopia/block/cloud/PoreousCloudStairsBlock.java b/src/main/java/com/minelittlepony/unicopia/block/cloud/PoreousCloudStairsBlock.java new file mode 100644 index 00000000..6733ee2d --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/block/cloud/PoreousCloudStairsBlock.java @@ -0,0 +1,26 @@ +package com.minelittlepony.unicopia.block.cloud; + +import java.util.function.Supplier; + +import org.jetbrains.annotations.Nullable; + +import net.minecraft.block.BlockState; + +public class PoreousCloudStairsBlock extends CloudStairsBlock implements Soakable { + + protected final Supplier soggyBlock; + + public PoreousCloudStairsBlock(BlockState baseState, Settings settings, Supplier soggyBlock) { + super(baseState, settings); + this.soggyBlock = soggyBlock; + } + + @Nullable + @Override + public BlockState getStateWithMoisture(BlockState state, int moisture) { + if (moisture <= 0) { + return Soakable.copyProperties(state, getDefaultState()); + } + return soggyBlock.get().getStateWithMoisture(state, moisture); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/block/cloud/ShapingBenchBlock.java b/src/main/java/com/minelittlepony/unicopia/block/cloud/ShapingBenchBlock.java new file mode 100644 index 00000000..06c47ceb --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/block/cloud/ShapingBenchBlock.java @@ -0,0 +1,62 @@ +package com.minelittlepony.unicopia.block.cloud; + +import org.jetbrains.annotations.Nullable; + +import com.minelittlepony.unicopia.EquineContext; +import com.minelittlepony.unicopia.container.ShapingBenchScreenHandler; + +import net.minecraft.block.Block; +import net.minecraft.block.BlockState; +import net.minecraft.block.ShapeContext; +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.screen.NamedScreenHandlerFactory; +import net.minecraft.screen.ScreenHandlerContext; +import net.minecraft.screen.SimpleNamedScreenHandlerFactory; +import net.minecraft.stat.Stats; +import net.minecraft.util.ActionResult; +import net.minecraft.util.Hand; +import net.minecraft.util.hit.BlockHitResult; +import net.minecraft.util.math.BlockPos; +import net.minecraft.util.shape.VoxelShape; +import net.minecraft.util.shape.VoxelShapes; +import net.minecraft.world.BlockView; +import net.minecraft.world.World; + +public class ShapingBenchBlock extends CloudBlock { + private static final VoxelShape SHAPE = VoxelShapes.union( + Block.createCuboidShape(0, 13, 0, 3, 18, 3), + Block.createCuboidShape(13, 13, 0, 16, 18, 3), + Block.createCuboidShape(0, 13, 13, 3, 18, 16), + Block.createCuboidShape(13, 13, 13, 16, 18, 16), + Block.createCuboidShape(0, 13, 0, 16, 16, 16), + Block.createCuboidShape(2, 0, 2, 14, 17, 14), + Block.createCuboidShape(0, 0, 0, 16, 4, 16) + ); + + public ShapingBenchBlock(Settings settings) { + super(settings, false); + } + + @Override + protected VoxelShape getOutlineShape(BlockState state, BlockView world, BlockPos pos, ShapeContext context, EquineContext equineContext) { + return SHAPE; + } + + @Override + public ActionResult onUse(BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockHitResult hit) { + if (world.isClient) { + return ActionResult.SUCCESS; + } + player.openHandledScreen(state.createScreenHandlerFactory(world, pos)); + player.incrementStat(Stats.INTERACT_WITH_STONECUTTER); + return ActionResult.CONSUME; + } + + @Override + @Nullable + public NamedScreenHandlerFactory createScreenHandlerFactory(BlockState state, World world, BlockPos pos) { + return new SimpleNamedScreenHandlerFactory((syncId, playerInventory, player) -> { + return new ShapingBenchScreenHandler(syncId, playerInventory, ScreenHandlerContext.create(world, pos)); + }, getName()); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/block/cloud/Soakable.java b/src/main/java/com/minelittlepony/unicopia/block/cloud/Soakable.java index 4623e92a..e800bbf8 100644 --- a/src/main/java/com/minelittlepony/unicopia/block/cloud/Soakable.java +++ b/src/main/java/com/minelittlepony/unicopia/block/cloud/Soakable.java @@ -6,7 +6,6 @@ import org.jetbrains.annotations.Nullable; import com.minelittlepony.unicopia.USounds; -import net.minecraft.block.Block; import net.minecraft.block.BlockState; import net.minecraft.entity.player.PlayerEntity; import net.minecraft.item.ItemStack; @@ -31,9 +30,12 @@ public interface Soakable { IntProperty MOISTURE = IntProperty.of("moisture", 1, 7); Direction[] DIRECTIONS = Arrays.stream(Direction.values()).filter(d -> d != Direction.UP).toArray(Direction[]::new); - BlockState getSoggyState(int moisture); + @Nullable + BlockState getStateWithMoisture(BlockState state, int moisture); - int getMoisture(BlockState state); + default int getMoisture(BlockState state) { + return state.getOrEmpty(MOISTURE).orElse(0); + } static void addMoistureParticles(BlockState state, World world, BlockPos pos, Random random) { if (random.nextInt(5) == 0) { @@ -46,69 +48,71 @@ public interface Soakable { } } - static ActionResult tryCollectMoisture(Block dryBlock, BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockHitResult hit) { - ItemStack stack = player.getStackInHand(hand); - if (stack.getItem() == Items.GLASS_BOTTLE) { - if (!player.isCreative()) { - stack.split(1); - } - if (stack.isEmpty()) { - player.setStackInHand(hand, Items.POTION.getDefaultStack()); - } else { - player.giveItemStack(Items.POTION.getDefaultStack()); - } - world.playSound(player, player.getX(), player.getY(), player.getZ(), USounds.Vanilla.ITEM_BOTTLE_FILL, SoundCategory.NEUTRAL, 1, 1); - world.emitGameEvent(player, GameEvent.FLUID_PICKUP, pos); - updateMoisture(dryBlock, state, world, pos, state.get(MOISTURE) - 1); + static ActionResult tryCollectMoisture(BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockHitResult hit) { + if (state.getBlock() instanceof Soakable soakable) { + ItemStack stack = player.getStackInHand(hand); + if (stack.getItem() == Items.GLASS_BOTTLE) { + if (!player.isCreative()) { + stack.split(1); + } + if (stack.isEmpty()) { + player.setStackInHand(hand, Items.POTION.getDefaultStack()); + } else { + player.giveItemStack(Items.POTION.getDefaultStack()); + } + world.playSound(player, player.getX(), player.getY(), player.getZ(), USounds.Vanilla.ITEM_BOTTLE_FILL, SoundCategory.NEUTRAL, 1, 1); + world.emitGameEvent(player, GameEvent.FLUID_PICKUP, pos); + updateMoisture(soakable, state, world, pos, soakable.getMoisture(state) - 1); - return ActionResult.SUCCESS; + return ActionResult.SUCCESS; + } } return ActionResult.PASS; } - static void tickMoisture(Block dryBlock, BlockState state, ServerWorld world, BlockPos pos, Random random) { - int moisture = state.get(MOISTURE); + static void tickMoisture(BlockState state, ServerWorld world, BlockPos pos, Random random) { + if (state.getBlock() instanceof Soakable soakable) { + int moisture = soakable.getMoisture(state); - if (world.hasRain(pos) && world.isAir(pos.up())) { - if (moisture < 7) { - world.setBlockState(pos, state.with(MOISTURE, moisture + 1)); - } - } else { - if (moisture > 1) { - BlockPos neighborPos = pos.offset(Util.getRandom(Soakable.DIRECTIONS, random)); - BlockState neighborState = world.getBlockState(neighborPos); + if (world.hasRain(pos) && world.isAir(pos.up())) { + if (moisture < 7) { + world.setBlockState(pos, soakable.getStateWithMoisture(state, moisture + 1)); + } + } else { + if (moisture > 1) { + BlockPos neighborPos = pos.offset(Util.getRandom(Soakable.DIRECTIONS, random)); + BlockState neighborState = world.getBlockState(neighborPos); - if (neighborState.getBlock() instanceof Soakable soakable && soakable.getMoisture(neighborState) < moisture) { - int half = Math.max(1, moisture / 2); - @Nullable - BlockState newNeighborState = soakable.getSoggyState(half); - if (newNeighborState != null) { - updateMoisture(dryBlock, state, world, pos, moisture - half); - world.setBlockState(neighborPos, soakable.getSoggyState(half)); - world.emitGameEvent(null, GameEvent.BLOCK_CHANGE, neighborPos); - return; + if (neighborState.getBlock() instanceof Soakable neighborSoakable && neighborSoakable.getMoisture(neighborState) < moisture) { + int half = Math.max(1, moisture / 2); + @Nullable + BlockState newNeighborState = neighborSoakable.getStateWithMoisture(neighborState, half); + if (newNeighborState != null) { + updateMoisture(soakable, state, world, pos, moisture - half); + world.setBlockState(neighborPos, soakable.getStateWithMoisture(state, half)); + world.emitGameEvent(null, GameEvent.BLOCK_CHANGE, neighborPos); + return; + } } } + updateMoisture(soakable, state, world, pos, moisture - 1); } - updateMoisture(dryBlock, state, world, pos, moisture - 1); } } - private static void updateMoisture(Block dryBlock, BlockState state, World world, BlockPos pos, int newMoisture) { - if (newMoisture <= 0) { - world.setBlockState(pos, copyProperties(state, dryBlock.getDefaultState())); - } else { - world.setBlockState(pos, state.with(MOISTURE, newMoisture)); - } + private static void updateMoisture(Soakable soakable, BlockState state, World world, BlockPos pos, int newMoisture) { + world.setBlockState(pos, soakable.getStateWithMoisture(state, newMoisture)); world.playSound(null, pos, SoundEvents.ENTITY_SALMON_FLOP, SoundCategory.BLOCKS, 1, (float)world.random.nextTriangular(0.5, 0.3F)); } - + @Nullable @SuppressWarnings({ "rawtypes", "unchecked" }) - static BlockState copyProperties(BlockState from, BlockState to) { - for (Property property : from.getProperties()) { - to = to.withIfExists(property, from.get(property)); + static BlockState copyProperties(BlockState from, @Nullable BlockState to) { + if (to != null) { + for (Property property : from.getProperties()) { + to = to.withIfExists(property, from.get(property)); + } } return to; } diff --git a/src/main/java/com/minelittlepony/unicopia/block/cloud/SoggyCloudBlock.java b/src/main/java/com/minelittlepony/unicopia/block/cloud/SoggyCloudBlock.java index 36124dbc..e508b96a 100644 --- a/src/main/java/com/minelittlepony/unicopia/block/cloud/SoggyCloudBlock.java +++ b/src/main/java/com/minelittlepony/unicopia/block/cloud/SoggyCloudBlock.java @@ -2,9 +2,12 @@ package com.minelittlepony.unicopia.block.cloud; import java.util.function.Supplier; +import org.jetbrains.annotations.Nullable; + import net.minecraft.block.Block; import net.minecraft.block.BlockState; import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.item.ItemStack; import net.minecraft.server.world.ServerWorld; import net.minecraft.state.StateManager; import net.minecraft.util.ActionResult; @@ -12,6 +15,7 @@ import net.minecraft.util.Hand; import net.minecraft.util.hit.BlockHitResult; import net.minecraft.util.math.BlockPos; import net.minecraft.util.math.random.Random; +import net.minecraft.world.BlockView; import net.minecraft.world.World; public class SoggyCloudBlock extends CloudBlock implements Soakable { @@ -24,25 +28,30 @@ public class SoggyCloudBlock extends CloudBlock implements Soakable { this.dryBlock = dryBlock; } - @Override - public BlockState getSoggyState(int moisture) { - return getDefaultState().with(MOISTURE, moisture); - } - - @Override - public int getMoisture(BlockState state) { - return state.get(MOISTURE); - } - @Override protected void appendProperties(StateManager.Builder builder) { + super.appendProperties(builder); builder.add(MOISTURE); } + @Override + public ItemStack getPickStack(BlockView world, BlockPos pos, BlockState state) { + return dryBlock.get().getPickStack(world, pos, state); + } + + @Nullable + @Override + public BlockState getStateWithMoisture(BlockState state, int moisture) { + if (moisture <= 0) { + return Soakable.copyProperties(state, dryBlock.get().getDefaultState()); + } + return Soakable.copyProperties(state, getDefaultState()).with(MOISTURE, moisture); + } + @Override @Deprecated public ActionResult onUse(BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockHitResult hit) { - return Soakable.tryCollectMoisture(dryBlock.get(), state, world, pos, player, hand, hit); + return Soakable.tryCollectMoisture(state, world, pos, player, hand, hit); } @Override @@ -53,6 +62,6 @@ public class SoggyCloudBlock extends CloudBlock implements Soakable { @Override public void randomTick(BlockState state, ServerWorld world, BlockPos pos, Random random) { - Soakable.tickMoisture(dryBlock.get(), state, world, pos, random); + Soakable.tickMoisture(state, world, pos, random); } } diff --git a/src/main/java/com/minelittlepony/unicopia/block/cloud/SoggyCloudSlabBlock.java b/src/main/java/com/minelittlepony/unicopia/block/cloud/SoggyCloudSlabBlock.java index d9f604fe..d074b2cb 100644 --- a/src/main/java/com/minelittlepony/unicopia/block/cloud/SoggyCloudSlabBlock.java +++ b/src/main/java/com/minelittlepony/unicopia/block/cloud/SoggyCloudSlabBlock.java @@ -2,9 +2,12 @@ package com.minelittlepony.unicopia.block.cloud; import java.util.function.Supplier; +import org.jetbrains.annotations.Nullable; + import net.minecraft.block.Block; import net.minecraft.block.BlockState; import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.item.ItemStack; import net.minecraft.server.world.ServerWorld; import net.minecraft.state.StateManager; import net.minecraft.util.ActionResult; @@ -12,6 +15,7 @@ import net.minecraft.util.Hand; import net.minecraft.util.hit.BlockHitResult; import net.minecraft.util.math.BlockPos; import net.minecraft.util.math.random.Random; +import net.minecraft.world.BlockView; import net.minecraft.world.World; public class SoggyCloudSlabBlock extends CloudSlabBlock { @@ -24,26 +28,30 @@ public class SoggyCloudSlabBlock extends CloudSlabBlock { this.dryBlock = dryBlock; } - @Override - public BlockState getSoggyState(int moisture) { - return getDefaultState().with(MOISTURE, moisture); - } - - @Override - public int getMoisture(BlockState state) { - return state.get(MOISTURE); - } - @Override protected void appendProperties(StateManager.Builder builder) { super.appendProperties(builder); builder.add(MOISTURE); } + @Override + public ItemStack getPickStack(BlockView world, BlockPos pos, BlockState state) { + return dryBlock.get().getPickStack(world, pos, state); + } + + @Nullable + @Override + public BlockState getStateWithMoisture(BlockState state, int moisture) { + if (moisture <= 0) { + return Soakable.copyProperties(state, dryBlock.get().getDefaultState()); + } + return Soakable.copyProperties(state, getDefaultState()).with(MOISTURE, moisture); + } + @Override @Deprecated public ActionResult onUse(BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockHitResult hit) { - return Soakable.tryCollectMoisture(dryBlock.get(), state, world, pos, player, hand, hit); + return Soakable.tryCollectMoisture(state, world, pos, player, hand, hit); } @Override @@ -54,6 +62,6 @@ public class SoggyCloudSlabBlock extends CloudSlabBlock { @Override public void randomTick(BlockState state, ServerWorld world, BlockPos pos, Random random) { - Soakable.tickMoisture(dryBlock.get(), state, world, pos, random); + Soakable.tickMoisture(state, world, pos, random); } } diff --git a/src/main/java/com/minelittlepony/unicopia/block/cloud/SoggyCloudStairsBlock.java b/src/main/java/com/minelittlepony/unicopia/block/cloud/SoggyCloudStairsBlock.java new file mode 100644 index 00000000..495c0f37 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/block/cloud/SoggyCloudStairsBlock.java @@ -0,0 +1,43 @@ +package com.minelittlepony.unicopia.block.cloud; + +import java.util.function.Supplier; + +import org.jetbrains.annotations.Nullable; + +import net.minecraft.block.Block; +import net.minecraft.block.BlockState; +import net.minecraft.item.ItemStack; +import net.minecraft.state.StateManager; +import net.minecraft.util.math.BlockPos; +import net.minecraft.world.BlockView; + +public class SoggyCloudStairsBlock extends CloudStairsBlock implements Soakable { + + private final Supplier dryBlock; + + public SoggyCloudStairsBlock(BlockState baseState, Settings settings, Supplier dryBlock) { + super(baseState, settings); + setDefaultState(getDefaultState().with(MOISTURE, 7)); + this.dryBlock = dryBlock; + } + + @Override + protected void appendProperties(StateManager.Builder builder) { + super.appendProperties(builder); + builder.add(MOISTURE); + } + + @Override + public ItemStack getPickStack(BlockView world, BlockPos pos, BlockState state) { + return dryBlock.get().getPickStack(world, pos, state); + } + + @Nullable + @Override + public BlockState getStateWithMoisture(BlockState state, int moisture) { + if (moisture <= 0) { + return Soakable.copyProperties(state, dryBlock.get().getDefaultState()); + } + return Soakable.copyProperties(state, getDefaultState()).with(MOISTURE, moisture); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/block/cloud/UnstableCloudBlock.java b/src/main/java/com/minelittlepony/unicopia/block/cloud/UnstableCloudBlock.java index 554e20b6..30bf49c4 100644 --- a/src/main/java/com/minelittlepony/unicopia/block/cloud/UnstableCloudBlock.java +++ b/src/main/java/com/minelittlepony/unicopia/block/cloud/UnstableCloudBlock.java @@ -59,6 +59,10 @@ public class UnstableCloudBlock extends CloudBlock { } world.playSound(null, pos, SoundEvents.BLOCK_WOOL_HIT, SoundCategory.BLOCKS, 1, 1); + if (world.isClient) { + return; + } + if (fallDistance > 3) { world.breakBlock(pos, true); return; diff --git a/src/main/java/com/minelittlepony/unicopia/client/URenderers.java b/src/main/java/com/minelittlepony/unicopia/client/URenderers.java index 4e3cd4f1..5bf94a22 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/URenderers.java +++ b/src/main/java/com/minelittlepony/unicopia/client/URenderers.java @@ -1,7 +1,12 @@ package com.minelittlepony.unicopia.client; +import java.util.function.Supplier; + +import org.jetbrains.annotations.Nullable; + import com.minelittlepony.unicopia.Unicopia; import com.minelittlepony.unicopia.block.*; +import com.minelittlepony.unicopia.block.cloud.CloudChestBlock; import com.minelittlepony.unicopia.client.particle.ChangelingMagicParticle; import com.minelittlepony.unicopia.client.particle.CloudsEscapingParticle; import com.minelittlepony.unicopia.client.particle.DiskParticle; @@ -21,8 +26,8 @@ import com.minelittlepony.unicopia.client.render.spell.SpellRendererFactory; import com.minelittlepony.unicopia.entity.mob.UEntities; import com.minelittlepony.unicopia.item.ChameleonItem; import com.minelittlepony.unicopia.item.EnchantableItem; +import com.minelittlepony.unicopia.item.FancyBedItem; import com.minelittlepony.unicopia.item.UItems; -import com.minelittlepony.unicopia.item.cloud.CloudBedItem; import com.minelittlepony.unicopia.particle.UParticles; import com.terraformersmc.terraform.boat.api.client.TerraformBoatClientHelper; @@ -30,9 +35,11 @@ import net.fabricmc.fabric.api.blockrenderlayer.v1.BlockRenderLayerMap; import net.fabricmc.fabric.api.client.particle.v1.ParticleFactoryRegistry; import net.fabricmc.fabric.api.client.particle.v1.ParticleFactoryRegistry.PendingParticleFactory; import net.fabricmc.fabric.api.client.rendering.v1.*; +import net.fabricmc.fabric.api.client.rendering.v1.BuiltinItemRendererRegistry.DynamicItemRenderer; import net.minecraft.block.Block; +import net.minecraft.block.BlockState; +import net.minecraft.block.entity.BlockEntity; import net.minecraft.client.MinecraftClient; -import net.minecraft.client.color.block.BlockColorProvider; import net.minecraft.client.color.world.BiomeColors; import net.minecraft.client.color.world.FoliageColors; import net.minecraft.client.item.ModelPredicateProviderRegistry; @@ -43,13 +50,18 @@ import net.minecraft.client.render.block.entity.BlockEntityRendererFactories; import net.minecraft.client.render.entity.FlyingItemEntityRenderer; import net.minecraft.client.render.item.ItemRenderer; import net.minecraft.client.render.model.json.ModelTransformationMode; +import net.minecraft.client.util.math.MatrixStack; import net.minecraft.client.world.ClientWorld; import net.minecraft.fluid.Fluids; import net.minecraft.item.*; import net.minecraft.particle.ParticleEffect; import net.minecraft.util.Identifier; +import net.minecraft.util.math.BlockPos; +import net.minecraft.world.BlockRenderView; public interface URenderers { + BlockEntity CHEST_RENDER_ENTITY = new CloudChestBlock.TileData(BlockPos.ORIGIN, UBlocks.CLOUD_CHEST.getDefaultState()); + static void bootstrap() { ParticleFactoryRegistry.getInstance().register(UParticles.UNICORN_MAGIC, createFactory(MagicParticle::new)); ParticleFactoryRegistry.getInstance().register(UParticles.CHANGELING_MAGIC, createFactory(ChangelingMagicParticle::new)); @@ -65,14 +77,11 @@ public interface URenderers { ParticleFactoryRegistry.getInstance().register(UParticles.CLOUDS_ESCAPING, CloudsEscapingParticle::new); ParticleFactoryRegistry.getInstance().register(UParticles.LIGHTNING_BOLT, LightningBoltParticle::new); - AccessoryFeatureRenderer.register(BraceletFeatureRenderer::new); - AccessoryFeatureRenderer.register(AmuletFeatureRenderer::new); - AccessoryFeatureRenderer.register(WingsFeatureRenderer::new); - AccessoryFeatureRenderer.register(HornFeatureRenderer::new); - AccessoryFeatureRenderer.register(IcarusWingsFeatureRenderer::new); - AccessoryFeatureRenderer.register(BatWingsFeatureRenderer::new); - AccessoryFeatureRenderer.register(GlassesFeatureRenderer::new); - AccessoryFeatureRenderer.register(HeldEntityFeatureRenderer::new); + AccessoryFeatureRenderer.register( + BraceletFeatureRenderer::new, AmuletFeatureRenderer::new, GlassesFeatureRenderer::new, + WingsFeatureRenderer::new, HornFeatureRenderer::new, IcarusWingsFeatureRenderer::new, BatWingsFeatureRenderer::new, + HeldEntityFeatureRenderer::new + ); EntityRendererRegistry.register(UEntities.THROWN_ITEM, FlyingItemEntityRenderer::new); EntityRendererRegistry.register(UEntities.MUFFIN, FlyingItemEntityRenderer::new); @@ -87,98 +96,24 @@ public interface URenderers { EntityRendererRegistry.register(UEntities.STORM_CLOUD, StormCloudEntityRenderer::new); EntityRendererRegistry.register(UEntities.AIR_BALLOON, AirBalloonEntityRenderer::new); EntityRendererRegistry.register(UEntities.FRIENDLY_CREEPER, FriendlyCreeperEntityRenderer::new); + EntityRendererRegistry.register(UEntities.LOOT_BUG, LootBugEntityRenderer::new); BlockEntityRendererFactories.register(UBlockEntities.WEATHER_VANE, WeatherVaneBlockEntityRenderer::new); - BlockEntityRendererFactories.register(UBlockEntities.CLOUD_BED, CloudBedBlockEntityRenderer::new); + BlockEntityRendererFactories.register(UBlockEntities.FANCY_BED, CloudBedBlockEntityRenderer::new); + BlockEntityRendererFactories.register(UBlockEntities.CLOUD_CHEST, CloudChestBlockEntityRenderer::new); + register(URenderers::renderJarItem, UItems.FILLED_JAR); + register(URenderers::renderBedItem, UItems.CLOTH_BED, UItems.CLOUD_BED); + register(URenderers::renderChestItem, UBlocks.CLOUD_CHEST.asItem()); + PolearmRenderer.register(UItems.WOODEN_POLEARM, UItems.STONE_POLEARM, UItems.IRON_POLEARM, UItems.GOLDEN_POLEARM, UItems.DIAMOND_POLEARM, UItems.NETHERITE_POLEARM); + ModelPredicateProviderRegistry.register(UItems.GEMSTONE, new Identifier("affinity"), (stack, world, entity, seed) -> EnchantableItem.isEnchanted(stack) ? EnchantableItem.getSpellKey(stack).getAffinity().getAlignment() : 0); + ModelPredicateProviderRegistry.register(UItems.ROCK_CANDY, new Identifier("count"), (stack, world, entity, seed) -> stack.getCount() / (float)stack.getMaxCount()); + + ColorProviderRegistry.BLOCK.register(URenderers::getTintedBlockColor, TintedBlock.REGISTRY.stream().toArray(Block[]::new)); + ColorProviderRegistry.ITEM.register((stack, i) -> getTintedBlockColor(Block.getBlockFromItem(stack.getItem()).getDefaultState(), null, null, i), TintedBlock.REGISTRY.stream().map(Block::asItem).filter(i -> i != Items.AIR).toArray(Item[]::new)); ColorProviderRegistry.ITEM.register((stack, i) -> i > 0 ? -1 : ((DyeableItem)stack.getItem()).getColor(stack), UItems.FRIENDSHIP_BRACELET); - BuiltinItemRendererRegistry.INSTANCE.register(UItems.FILLED_JAR, (stack, mode, matrices, vertices, light, overlay) -> { - - ItemRenderer renderer = MinecraftClient.getInstance().getItemRenderer(); - - ChameleonItem item = (ChameleonItem)stack.getItem(); - - // Reset stuff done in the beforelands - matrices.pop(); - - if (mode == ModelTransformationMode.GUI) { - DiffuseLighting.disableGuiDepthLighting(); - } - - VertexConsumerProvider.Immediate immediate = MinecraftClient.getInstance().getBufferBuilders().getEntityVertexConsumers(); - ClientWorld world = MinecraftClient.getInstance().world; - - if (item.hasAppearance(stack)) { - matrices.push(); - if (mode.isFirstPerson()) { - matrices.translate(0.05, 0.06, 0.06); - } else if (mode == ModelTransformationMode.HEAD) { - matrices.translate(0, 0.4, 0); - } else if (mode == ModelTransformationMode.GROUND - || mode == ModelTransformationMode.THIRD_PERSON_LEFT_HAND || mode == ModelTransformationMode.THIRD_PERSON_RIGHT_HAND) { - matrices.translate(0, 0.06, 0); - } - // GUI, FIXED, NONE - translate(0, 0, 0) - //matrices.scale(0.5F, 0.5F, 0.5F); - - float scale = 0.5F; - matrices.scale(scale, scale, scale); - - ItemStack appearance = item.getAppearanceStack(stack); - renderer.renderItem(appearance, mode, light, overlay, matrices, immediate, world, 0); - matrices.pop(); - } - renderer.renderItem(item.createAppearanceStack(stack, UItems.EMPTY_JAR), mode, light, OverlayTexture.DEFAULT_UV, matrices, vertices, world, 0); - - if (mode == ModelTransformationMode.GUI) { - DiffuseLighting.enableGuiDepthLighting(); - } - matrices.push(); - - }); - BuiltinItemRendererRegistry.INSTANCE.register(UItems.CLOUD_BED, (stack, mode, matrices, vertices, light, overlay) -> { - MinecraftClient.getInstance().getBlockEntityRenderDispatcher().renderEntity(((CloudBedItem)stack.getItem()).getRenderEntity(), matrices, vertices, light, overlay); - }); - PolearmRenderer.register(UItems.WOODEN_POLEARM); - PolearmRenderer.register(UItems.STONE_POLEARM); - PolearmRenderer.register(UItems.IRON_POLEARM); - PolearmRenderer.register(UItems.GOLDEN_POLEARM); - PolearmRenderer.register(UItems.DIAMOND_POLEARM); - PolearmRenderer.register(UItems.NETHERITE_POLEARM); - ModelPredicateProviderRegistry.register(UItems.GEMSTONE, new Identifier("affinity"), (stack, world, entity, seed) -> { - return EnchantableItem.isEnchanted(stack) ? EnchantableItem.getSpellKey(stack).getAffinity().getAlignment() : 0; - }); - ModelPredicateProviderRegistry.register(UItems.ROCK_CANDY, new Identifier("count"), (stack, world, entity, seed) -> { - return stack.getCount() / (float)stack.getMaxCount(); - }); - ColorProviderRegistry.ITEM.register((stack, i) -> { - return i > 0 || !EnchantableItem.isEnchanted(stack) ? -1 : EnchantableItem.getSpellKey(stack).getColor(); - }, UItems.GEMSTONE); - ColorProviderRegistry.ITEM.register((stack, i) -> { - if (i == 1 && EnchantableItem.isEnchanted(stack)) { - return EnchantableItem.getSpellKey(stack).getColor(); - } - return -1; - }, UItems.MAGIC_STAFF); - - BlockColorProvider tintedProvider = (state, view, pos, color) -> { - if (view == null || pos == null) { - color = FoliageColors.getDefaultColor(); - } else { - color = BiomeColors.getFoliageColor(view, pos); - } - - if (state.getBlock() instanceof TintedBlock block) { - return block.getTint(state, view, pos, color); - } - - return color; - }; - - ColorProviderRegistry.BLOCK.register(tintedProvider, TintedBlock.REGISTRY.stream().toArray(Block[]::new)); - ColorProviderRegistry.ITEM.register((stack, i) -> { - return tintedProvider.getColor(Block.getBlockFromItem(stack.getItem()).getDefaultState(), null, null, i); - }, TintedBlock.REGISTRY.stream().map(Block::asItem).filter(i -> i != Items.AIR).toArray(Item[]::new)); + ColorProviderRegistry.ITEM.register((stack, i) -> i > 0 || !EnchantableItem.isEnchanted(stack) ? -1 : EnchantableItem.getSpellKey(stack).getColor(), UItems.GEMSTONE); + ColorProviderRegistry.ITEM.register((stack, i) -> i == 1 && EnchantableItem.isEnchanted(stack) ? EnchantableItem.getSpellKey(stack).getColor() : -1, UItems.MAGIC_STAFF); BlockRenderLayerMap.INSTANCE.putBlocks(RenderLayer.getCutout(), UBlocks.TRANSLUCENT_BLOCKS.stream().toArray(Block[]::new)); BlockRenderLayerMap.INSTANCE.putBlocks(RenderLayer.getTranslucent(), UBlocks.SEMI_TRANSPARENT_BLOCKS.stream().toArray(Block[]::new)); @@ -190,6 +125,80 @@ public interface URenderers { SpellRendererFactory.bootstrap(); } + private static void register(DynamicItemRenderer renderer, ItemConvertible...items) { + for (ItemConvertible item : items) { + BuiltinItemRendererRegistry.INSTANCE.register(item, renderer); + } + } + + @SuppressWarnings("unchecked") + private static void renderBedItem(ItemStack stack, ModelTransformationMode mode, MatrixStack matrices, VertexConsumerProvider vertices, int light, int overlay) { + BlockEntity entity = ((Supplier)stack.getItem()).get(); + ((FancyBedBlock.Tile)entity).setPattern(FancyBedItem.getPattern(stack)); + MinecraftClient.getInstance().getBlockEntityRenderDispatcher().renderEntity(entity, matrices, vertices, light, overlay); + } + + private static void renderChestItem(ItemStack stack, ModelTransformationMode mode, MatrixStack matrices, VertexConsumerProvider vertices, int light, int overlay) { + MinecraftClient.getInstance().getBlockEntityRenderDispatcher().renderEntity(CHEST_RENDER_ENTITY, matrices, vertices, light, overlay); + } + + private static void renderJarItem(ItemStack stack, ModelTransformationMode mode, MatrixStack matrices, VertexConsumerProvider vertices, int light, int overlay) { + ItemRenderer renderer = MinecraftClient.getInstance().getItemRenderer(); + + ChameleonItem item = (ChameleonItem)stack.getItem(); + + // Reset stuff done in the beforelands + matrices.pop(); + + if (mode == ModelTransformationMode.GUI) { + DiffuseLighting.disableGuiDepthLighting(); + } + + VertexConsumerProvider.Immediate immediate = MinecraftClient.getInstance().getBufferBuilders().getEntityVertexConsumers(); + ClientWorld world = MinecraftClient.getInstance().world; + + if (item.hasAppearance(stack)) { + matrices.push(); + if (mode.isFirstPerson()) { + matrices.translate(0.05, 0.06, 0.06); + } else if (mode == ModelTransformationMode.HEAD) { + matrices.translate(0, 0.4, 0); + } else if (mode == ModelTransformationMode.GROUND + || mode == ModelTransformationMode.THIRD_PERSON_LEFT_HAND || mode == ModelTransformationMode.THIRD_PERSON_RIGHT_HAND) { + matrices.translate(0, 0.06, 0); + } + // GUI, FIXED, NONE - translate(0, 0, 0) + //matrices.scale(0.5F, 0.5F, 0.5F); + + float scale = 0.5F; + matrices.scale(scale, scale, scale); + + ItemStack appearance = item.getAppearanceStack(stack); + renderer.renderItem(appearance, mode, light, overlay, matrices, immediate, world, 0); + matrices.pop(); + } + renderer.renderItem(item.createAppearanceStack(stack, UItems.EMPTY_JAR), mode, light, OverlayTexture.DEFAULT_UV, matrices, vertices, world, 0); + + if (mode == ModelTransformationMode.GUI) { + DiffuseLighting.enableGuiDepthLighting(); + } + matrices.push(); + } + + private static int getTintedBlockColor(BlockState state, @Nullable BlockRenderView view, @Nullable BlockPos pos, int color) { + if (view == null || pos == null) { + color = FoliageColors.getDefaultColor(); + } else { + color = BiomeColors.getFoliageColor(view, pos); + } + + if (state.getBlock() instanceof TintedBlock block) { + return block.getTint(state, view, pos, color); + } + + return color; + } + static PendingParticleFactory createFactory(ParticleSupplier supplier) { return provider -> (effect, world, x, y, z, dx, dy, dz) -> supplier.get(effect, provider, world, x, y, z, dx, dy, dz); } diff --git a/src/main/java/com/minelittlepony/unicopia/client/UnicopiaClient.java b/src/main/java/com/minelittlepony/unicopia/client/UnicopiaClient.java index fc89eaa0..32b01a8e 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/UnicopiaClient.java +++ b/src/main/java/com/minelittlepony/unicopia/client/UnicopiaClient.java @@ -11,6 +11,7 @@ import com.minelittlepony.unicopia.InteractionManager; import com.minelittlepony.unicopia.Race; import com.minelittlepony.unicopia.Unicopia; import com.minelittlepony.unicopia.client.gui.LanSettingsScreen; +import com.minelittlepony.unicopia.client.gui.ShapingBenchScreen; import com.minelittlepony.unicopia.client.gui.UHud; import com.minelittlepony.unicopia.client.gui.spellbook.SpellbookScreen; import com.minelittlepony.unicopia.client.minelittlepony.MineLPDelegate; @@ -101,6 +102,7 @@ public class UnicopiaClient implements ClientModInitializer { URenderers.bootstrap(); HandledScreens.register(UScreenHandlers.SPELL_BOOK, SpellbookScreen::new); + HandledScreens.register(UScreenHandlers.SHAPING_BENCH, ShapingBenchScreen::new); ClientTickEvents.END_CLIENT_TICK.register(this::onTick); ClientTickEvents.END_WORLD_TICK.register(this::onWorldTick); diff --git a/src/main/java/com/minelittlepony/unicopia/client/gui/HudEffects.java b/src/main/java/com/minelittlepony/unicopia/client/gui/HudEffects.java new file mode 100644 index 00000000..2188245d --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/client/gui/HudEffects.java @@ -0,0 +1,61 @@ +package com.minelittlepony.unicopia.client.gui; + +import java.util.HashSet; +import java.util.Set; + +import org.jetbrains.annotations.Nullable; + +import com.minelittlepony.unicopia.Race; +import com.minelittlepony.unicopia.entity.duck.EntityDuck; +import com.minelittlepony.unicopia.entity.effect.EffectUtils; +import com.minelittlepony.unicopia.entity.effect.UEffects; +import com.minelittlepony.unicopia.entity.player.Pony; + +import net.minecraft.entity.effect.StatusEffectInstance; +import net.minecraft.entity.effect.StatusEffects; +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.fluid.Fluid; +import net.minecraft.registry.tag.FluidTags; +import net.minecraft.registry.tag.TagKey; + +public class HudEffects { + + private static boolean addedHunger; + private static Set> originalTags = null; + + public static void tryApply(@Nullable PlayerEntity player, float tickDelta, boolean on) { + if (player != null) { + apply(Pony.of(player), tickDelta, on); + } + } + + private static void apply(Pony pony, float tickDelta, boolean on) { + if (on) { + if (!pony.asEntity().hasStatusEffect(StatusEffects.HUNGER) && EffectUtils.getAmplifier(pony.asEntity(), UEffects.FOOD_POISONING) > 0) { + addedHunger = true; + pony.asEntity().addStatusEffect(new StatusEffectInstance(StatusEffects.HUNGER, 1, 1, false, false)); + } + } else { + if (addedHunger) { + addedHunger = false; + pony.asEntity().removeStatusEffect(StatusEffects.HUNGER); + } + } + + if (pony.getCompositeRace().includes(Race.SEAPONY)) { + Set> fluidTags = ((EntityDuck)pony.asEntity()).getSubmergedFluidTags(); + if (on) { + originalTags = new HashSet<>(fluidTags); + if (fluidTags.contains(FluidTags.WATER)) { + fluidTags.clear(); + } else { + fluidTags.add(FluidTags.WATER); + } + } else if (originalTags != null) { + fluidTags.clear(); + fluidTags.addAll(originalTags); + originalTags = null; + } + } + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/client/gui/LanSettingsScreen.java b/src/main/java/com/minelittlepony/unicopia/client/gui/LanSettingsScreen.java index 79e34ca8..31aa7a90 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/gui/LanSettingsScreen.java +++ b/src/main/java/com/minelittlepony/unicopia/client/gui/LanSettingsScreen.java @@ -113,7 +113,7 @@ public class LanSettingsScreen extends GameGui { WHITELIST_GRID_PACKER.start(); for (Race race : Race.REGISTRY) { - if (!race.isUnset()) { + if (!race.isUnset() && race.availability().isGrantable()) { Bounds bound = WHITELIST_GRID_PACKER.next(); Button button = content.addButton(new Toggle(LEFT + bound.left + 10, row + bound.top, whitelist.contains(race.getId().toString()))) diff --git a/src/main/java/com/minelittlepony/unicopia/client/gui/ManaRingSlot.java b/src/main/java/com/minelittlepony/unicopia/client/gui/ManaRingSlot.java index c796e6d3..73ef3bdb 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/gui/ManaRingSlot.java +++ b/src/main/java/com/minelittlepony/unicopia/client/gui/ManaRingSlot.java @@ -13,7 +13,7 @@ import net.minecraft.client.util.math.MatrixStack; class ManaRingSlot extends Slot { public ManaRingSlot(UHud uHud, AbilitySlot normalSlot, AbilitySlot backupSlot, int x, int y) { - super(uHud, normalSlot, backupSlot, x, y, 8, UHud.PRIMARY_SLOT_SIZE, 33, 43, 42); + super(uHud, normalSlot, backupSlot, x, y, 8, UHud.PRIMARY_SLOT_SIZE, 33, 43, 30); background(0, 5); foreground(0, 59); } diff --git a/src/main/java/com/minelittlepony/unicopia/client/gui/ShapingBenchScreen.java b/src/main/java/com/minelittlepony/unicopia/client/gui/ShapingBenchScreen.java new file mode 100644 index 00000000..e38e96d7 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/client/gui/ShapingBenchScreen.java @@ -0,0 +1,12 @@ +package com.minelittlepony.unicopia.client.gui; + +import net.minecraft.client.gui.screen.ingame.StonecutterScreen; +import net.minecraft.entity.player.PlayerInventory; +import net.minecraft.screen.StonecutterScreenHandler; +import net.minecraft.text.Text; + +public class ShapingBenchScreen extends StonecutterScreen { + public ShapingBenchScreen(StonecutterScreenHandler handler, PlayerInventory inventory, Text title) { + super(handler, inventory, title); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/client/gui/Slot.java b/src/main/java/com/minelittlepony/unicopia/client/gui/Slot.java index e337ddf3..4117c7e1 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/gui/Slot.java +++ b/src/main/java/com/minelittlepony/unicopia/client/gui/Slot.java @@ -93,8 +93,9 @@ class Slot { AbilityDispatcher.Stat stat = abilities.getStat(bSwap ? bSlot : aSlot); + int iconPosition = ((size - iconSize + slotPadding + 1) / 2); int sz = iconSize - slotPadding; - uHud.renderAbilityIcon(context, stat, slotPadding, slotPadding, sz, sz, sz, sz); + uHud.renderAbilityIcon(context, stat, iconPosition, iconPosition, sz, sz, sz, sz); float cooldown = stat.getFillProgress(); diff --git a/src/main/java/com/minelittlepony/unicopia/client/gui/TextBlock.java b/src/main/java/com/minelittlepony/unicopia/client/gui/TextBlock.java index 8943da6e..b72f46fc 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/gui/TextBlock.java +++ b/src/main/java/com/minelittlepony/unicopia/client/gui/TextBlock.java @@ -13,13 +13,13 @@ public class TextBlock extends Label { public TextBlock(int x, int y, int width) { super(x, y); this.maxWidth = width; - this.render(null, x, y, width); } @Override public Bounds getBounds() { Bounds bounds = super.getBounds(); bounds.height = getFont().wrapLines(getStyle().getText(), maxWidth).size() * getFont().fontHeight; + bounds.width = 0; return bounds; } diff --git a/src/main/java/com/minelittlepony/unicopia/client/gui/TribeButton.java b/src/main/java/com/minelittlepony/unicopia/client/gui/TribeButton.java index 14523749..5219dc16 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/gui/TribeButton.java +++ b/src/main/java/com/minelittlepony/unicopia/client/gui/TribeButton.java @@ -41,10 +41,10 @@ public class TribeButton extends Button { MinecraftClient mc = MinecraftClient.getInstance(); context.drawTexture(TribeSelectionScreen.TEXTURE, getX() - 3, getY() - 13, 0, 0, 76, 69); - if (isHovered()) { + if (isSelected()) { context.drawTexture(TribeSelectionScreen.TEXTURE, getX() - 4, getY() - 14, 76, 0, 78, 71); - if (hovered && screenWidth > 0) { + if (isFocused() && screenWidth > 0) { Identifier id = Race.REGISTRY.getId(race); context.drawCenteredTextWithShadow(getFont(), Text.translatable("gui.unicopia.tribe_selection.describe." + id.getNamespace() + "." + id.getPath()), screenWidth / 2, getY() + height, 0xFFFFFFFF); } @@ -59,7 +59,7 @@ public class TribeButton extends Button { int foreColor = getStyle().getColor(); if (!active) { foreColor = 10526880; - } else if (isHovered()) { + } else if (isSelected()) { foreColor = 16777120; } diff --git a/src/main/java/com/minelittlepony/unicopia/client/gui/TribeConfirmationScreen.java b/src/main/java/com/minelittlepony/unicopia/client/gui/TribeConfirmationScreen.java index 813bd9ef..cccc04b8 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/gui/TribeConfirmationScreen.java +++ b/src/main/java/com/minelittlepony/unicopia/client/gui/TribeConfirmationScreen.java @@ -3,6 +3,7 @@ package com.minelittlepony.unicopia.client.gui; import org.lwjgl.glfw.GLFW; import com.minelittlepony.common.client.gui.GameGui; +import com.minelittlepony.common.client.gui.ScrollContainer; import com.minelittlepony.common.client.gui.element.Button; import com.minelittlepony.common.client.gui.element.Label; import com.minelittlepony.unicopia.Race; @@ -17,6 +18,8 @@ public class TribeConfirmationScreen extends GameGui implements HidesHud { private final BooleanConsumer callback; + private final ScrollContainer textBody = new ScrollContainer(); + public TribeConfirmationScreen(BooleanConsumer callback, Race selection) { super(Text.translatable("gui.unicopia.tribe_selection")); this.callback = callback; @@ -25,12 +28,26 @@ public class TribeConfirmationScreen extends GameGui implements HidesHud { @Override protected void init() { - final int columnHeight = 167; final int columnWidth = 310; final int padding = 15; int top = (height - columnHeight) / 2; + int left = (width - columnWidth) / 2 + 8; + int maxWidth = 295; + + textBody.verticalScrollbar.layoutToEnd = true; + textBody.margin.top = top + 43; + textBody.margin.left = left; + textBody.margin.right = width - (left + maxWidth); + textBody.margin.bottom = height - (textBody.margin.top + 130); + textBody.getContentPadding().top = 10; + textBody.getContentPadding().left = 8; + textBody.getContentPadding().bottom = 100; + textBody.getContentPadding().right = 0; + textBody.init(this::buildTextBody); + + getChildElements().add(textBody); addDrawableChild(new Button(width / 2 + 5, top + columnHeight + padding, 100, 20)) .onClick(b -> callback.accept(true)) @@ -42,38 +59,40 @@ public class TribeConfirmationScreen extends GameGui implements HidesHud { addDrawable(new Label(width / 2, top - 30).setCentered()).getStyle().setText(Text.translatable("gui.unicopia.tribe_selection.confirm", selection.getDisplayName().copy().formatted(Formatting.YELLOW))); addDrawable(new TribeButton((width - 70) / 2, top, 0, selection)); + } - top += 43; + private void buildTextBody() { + int top = 0; - int left = (width - columnWidth) / 2 + padding; + int left = 0; Text race = selection.getAltDisplayName().copy().formatted(Formatting.YELLOW); - addDrawable(new Label(left - 3, top += 10)).getStyle().setText(Text.translatable("gui.unicopia.tribe_selection.confirm.goods", race).formatted(Formatting.YELLOW)); + textBody.addButton(new Label(left - 3, top += 10)).getStyle().setText(Text.translatable("gui.unicopia.tribe_selection.confirm.goods", race).formatted(Formatting.YELLOW)); top += 15; - int maxWidth = 280; + int maxWidth = 270; Identifier id = Race.REGISTRY.getId(selection); - for (int i = 0; i < 5; i++) { + for (int i = 0; i < 10; i++) { String key = String.format("gui.unicopia.tribe_selection.confirm.goods.%d.%s.%s", i, id.getNamespace(), id.getPath()); if (Language.getInstance().hasTranslation(key)) { - TextBlock block = addDrawable(new TextBlock(left, top, maxWidth)); + TextBlock block = textBody.addButton(new TextBlock(left, top, maxWidth)); block.getStyle().setText(Text.translatable(key)); top += block.getBounds().height; } } - addDrawable(new Label(left - 3, top += 5)).getStyle().setText(Text.translatable("gui.unicopia.tribe_selection.confirm.bads", race).formatted(Formatting.YELLOW)); + textBody.addButton(new Label(left - 3, top += 5)).getStyle().setText(Text.translatable("gui.unicopia.tribe_selection.confirm.bads", race).formatted(Formatting.YELLOW)); top += 15; - for (int i = 0; i < 5; i++) { + for (int i = 0; i < 10; i++) { String key = String.format("gui.unicopia.tribe_selection.confirm.bads.%d.%s.%s", i, id.getNamespace(), id.getPath()); if (Language.getInstance().hasTranslation(key)) { - TextBlock block = addDrawable(new TextBlock(left, top, maxWidth)); + TextBlock block = textBody.addButton(new TextBlock(left, top, maxWidth)); block.getStyle().setText(Text.translatable(key)); top += block.getBounds().height; } @@ -81,9 +100,7 @@ public class TribeConfirmationScreen extends GameGui implements HidesHud { } @Override - public void renderBackground(DrawContext context, int mouseX, int mouseY, float delta) { - super.renderBackground(context, mouseX, mouseY, delta); - + public void render(DrawContext context, int mouseX, int mouseY, float delta) { final int columnHeight = 180; final int columnWidth = 310; final int segmentWidth = 123; @@ -91,7 +108,7 @@ public class TribeConfirmationScreen extends GameGui implements HidesHud { int top = (height - columnHeight) / 2; int left = (width - columnWidth) / 2; - top += 25; + top += 40; final int zOffset = 0; @@ -106,10 +123,16 @@ public class TribeConfirmationScreen extends GameGui implements HidesHud { left = width / 2; context.drawTexture(TribeSelectionScreen.TEXTURE, left - 55, top, 140, 70, 21, 50); - - context.drawTexture(TribeSelectionScreen.TEXTURE, left - 35, top, 10, 70, 69, 50); - context.drawTexture(TribeSelectionScreen.TEXTURE, left + 35, top, 148, 70, 21, 50); + + textBody.render(context, mouseX, mouseY, delta); + + context.getMatrices().push(); + context.getMatrices().translate(0, 0, 2); + context.drawTexture(TribeSelectionScreen.TEXTURE, left - 35, top - 5, 10, 70, 69, 50); + context.drawTexture(TribeSelectionScreen.TEXTURE, left - 35, top - 15, 10, 70, 69, 50); + super.render(context, mouseX, mouseY, delta); + context.getMatrices().pop(); } @Override @@ -120,7 +143,11 @@ public class TribeConfirmationScreen extends GameGui implements HidesHud { @Override public boolean keyPressed(int keyCode, int scanCode, int modifiers) { if (keyCode == GLFW.GLFW_KEY_ESCAPE) { - + callback.accept(false); + return true; + } + if (keyCode == GLFW.GLFW_KEY_ENTER) { + callback.accept(true); return true; } return super.keyPressed(keyCode, scanCode, modifiers); diff --git a/src/main/java/com/minelittlepony/unicopia/client/gui/TribeSelectionScreen.java b/src/main/java/com/minelittlepony/unicopia/client/gui/TribeSelectionScreen.java index a604fca5..1dca0030 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/gui/TribeSelectionScreen.java +++ b/src/main/java/com/minelittlepony/unicopia/client/gui/TribeSelectionScreen.java @@ -1,8 +1,11 @@ package com.minelittlepony.unicopia.client.gui; +import java.util.ArrayList; import java.util.List; import java.util.Set; +import org.lwjgl.glfw.GLFW; + import com.minelittlepony.common.client.gui.GameGui; import com.minelittlepony.common.client.gui.element.Label; import com.minelittlepony.unicopia.Race; @@ -10,9 +13,12 @@ import com.minelittlepony.unicopia.Unicopia; import com.minelittlepony.unicopia.network.Channel; import com.minelittlepony.unicopia.network.MsgRequestSpeciesChange; +import net.minecraft.client.gui.DrawContext; +import net.minecraft.sound.SoundEvents; import net.minecraft.text.Text; import net.minecraft.util.Formatting; import net.minecraft.util.Identifier; +import net.minecraft.util.math.MathHelper; public class TribeSelectionScreen extends GameGui implements HidesHud { static final Identifier TEXTURE = Unicopia.id("textures/gui/tribe_selection.png"); @@ -24,6 +30,13 @@ public class TribeSelectionScreen extends GameGui implements HidesHud { private boolean finished; + private final List options = new ArrayList<>(); + private static int SELECTION = -1; + + private int prevScrollPosition; + private int scrollPosition; + private int targetScroll; + public TribeSelectionScreen(Set allowedRaces, String baseString) { super(Text.translatable(baseString)); this.allowedRaces = allowedRaces; @@ -51,33 +64,26 @@ public class TribeSelectionScreen extends GameGui implements HidesHud { top += block.getBounds().height; top += 30; - final int itemWidth = 70 + 10; - - List options = Race.REGISTRY.stream().filter(race -> !race.isHuman() && !race.isOp()).toList(); - - int columns = Math.min(width / itemWidth, options.size()); - - int x = (width - (columns * itemWidth)) / 2; - int y = top; - - int column = 0; - int row = 0; + List options = Race.REGISTRY.stream().filter(race -> race.availability().isSelectable()).toList(); + this.options.clear(); for (Race race : options) { - addOption(race, x + (column * itemWidth), y + (row * itemWidth)); - column++; - if (column >= columns) { - column = 0; - row++; - } + addOption(race, top); } - top = height - 20; + if (SELECTION == -1) { + SELECTION = options.size() / 2; + } + scroll(SELECTION, false); } - private void addOption(Race race, int x, int y) { - addDrawableChild(new TribeButton(x, y, width, race)).onClick(b -> { + private void addOption(Race race, int y) { + var option = new TribeButton(0, y, width, race); + int index = options.size(); + options.add(addDrawableChild(option)); + option.onClick(b -> { finished = true; + scroll(index, false); client.setScreen(new TribeConfirmationScreen(result -> { finished = false; @@ -91,12 +97,88 @@ public class TribeSelectionScreen extends GameGui implements HidesHud { }).setEnabled(allowedRaces.contains(race)); } + @Override + public void tick() { + prevScrollPosition = scrollPosition; + if (scrollPosition < targetScroll) { + scrollPosition++; + } + if (scrollPosition > targetScroll) { + scrollPosition--; + } + } + + private void updateScolling() { + final int itemWidth = 70 + 10; + int x = (width - itemWidth) / 2; + float diff = MathHelper.lerp(client.getTickDelta(), prevScrollPosition, scrollPosition) / 4F; + + for (int i = 0; i < options.size(); i++) { + var option = options.get(i); + option.setX((int)(x + (i - diff) * itemWidth)); + option.setFocused(i == SELECTION); + } + } + + @Override + public void render(DrawContext context, int mouseX, int mouseY, float delta) { + updateScolling(); + super.render(context, mouseX, mouseY, delta); + + if (!options.isEmpty()) { + var element = options.get(0); + + float diff = (targetScroll - MathHelper.lerp(client.getTickDelta(), prevScrollPosition, scrollPosition)) * 7; + context.drawTexture(TEXTURE, (width / 2) + 40 + (scrollPosition < targetScroll ? (int)diff : 0), element.getY() - 20, 10, 165, 153, 30, 85, 312, 312); + context.drawTexture(TEXTURE, (width / 2) - 80 + (scrollPosition > targetScroll ? (int)diff : 0), element.getY() - 20, 10, 195, 153, 30, 85, 312, 312); + if (element.getBounds().left < 0) { + context.drawTexture(TEXTURE, 20, element.getY() - 10, 10, 188, 235, 24, 60, 312, 312); + } + element = options.get(options.size() - 1); + if (element.getBounds().right() > width) { + context.drawTexture(TEXTURE, width - 50, element.getY() - 10, 10, 164, 235, 24, 60, 312, 312); + } + } + } + @Override public void finish() { finished = true; close(); } + @Override + public boolean keyPressed(int keyCode, int scanCode, int modifiers) { + + if (keyCode == GLFW.GLFW_KEY_LEFT) { + scroll(Math.max(SELECTION - 1, 0), true); + return true; + } + if (keyCode == GLFW.GLFW_KEY_RIGHT) { + scroll(Math.min(SELECTION + 1, options.size() - 1), true); + return true; + } + if (keyCode == GLFW.GLFW_KEY_ENTER) { + options.get(SELECTION).onPress(); + } + + return super.keyPressed(keyCode, scanCode, modifiers); + } + + private void scroll(int target, boolean animate) { + if (target == SELECTION) { + return; + } + SELECTION = target; + targetScroll = SELECTION * 4; + if (!animate) { + scrollPosition = targetScroll; + prevScrollPosition = scrollPosition; + } else { + playSound(SoundEvents.UI_BUTTON_CLICK); + } + } + @Override public boolean shouldCloseOnEsc() { return false; diff --git a/src/main/java/com/minelittlepony/unicopia/client/minelittlepony/BodyPartGear.java b/src/main/java/com/minelittlepony/unicopia/client/minelittlepony/BodyPartGear.java index 4958a2cf..3ac7b62b 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/minelittlepony/BodyPartGear.java +++ b/src/main/java/com/minelittlepony/unicopia/client/minelittlepony/BodyPartGear.java @@ -15,6 +15,7 @@ import com.minelittlepony.client.model.entity.race.UnicornModel; import com.minelittlepony.client.model.part.UnicornHorn; import com.minelittlepony.mson.api.MsonModel; import com.minelittlepony.unicopia.EquinePredicates; +import com.minelittlepony.unicopia.FlightType; import com.minelittlepony.unicopia.Race; import com.minelittlepony.unicopia.Unicopia; import com.minelittlepony.unicopia.entity.AmuletSelectors; @@ -43,7 +44,7 @@ class BodyPartGear> implements Gear { public static final Predicate UNICORN_HORN_PREDICATE = MINE_LP_HAS_NO_HORN.and(AmuletSelectors.ALICORN_AMULET.or(EquinePredicates.raceMatches(Race::canCast))); public static final Identifier UNICORN_HORN = Unicopia.id("textures/models/horn/unicorn.png"); - public static final Predicate PEGA_WINGS_PREDICATE = MINE_LP_HAS_NO_WINGS.and(AmuletSelectors.PEGASUS_AMULET.or(EquinePredicates.raceMatches(Race::canInteractWithClouds))); + public static final Predicate PEGA_WINGS_PREDICATE = MINE_LP_HAS_NO_WINGS.and(AmuletSelectors.PEGASUS_AMULET.or(EquinePredicates.raceMatches(race -> race.flightType() == FlightType.AVIAN))); public static final Identifier PEGASUS_WINGS = Unicopia.id("textures/models/wings/pegasus_pony.png"); public static BodyPartGear pegasusWings() { diff --git a/src/main/java/com/minelittlepony/unicopia/client/minelittlepony/Main.java b/src/main/java/com/minelittlepony/unicopia/client/minelittlepony/Main.java index df9a306f..d28ef1a4 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/minelittlepony/Main.java +++ b/src/main/java/com/minelittlepony/unicopia/client/minelittlepony/Main.java @@ -54,9 +54,9 @@ public class Main extends MineLPDelegate implements ClientModInitializer { registerRaceMapping(com.minelittlepony.api.pony.meta.Race.CHANGEDLING, Race.CHANGELING); registerRaceMapping(com.minelittlepony.api.pony.meta.Race.ZEBRA, Race.EARTH); registerRaceMapping(com.minelittlepony.api.pony.meta.Race.GRYPHON, Race.PEGASUS); - registerRaceMapping(com.minelittlepony.api.pony.meta.Race.HIPPOGRIFF, Race.PEGASUS); + registerRaceMapping(com.minelittlepony.api.pony.meta.Race.HIPPOGRIFF, Race.HIPPOGRIFF); registerRaceMapping(com.minelittlepony.api.pony.meta.Race.BATPONY, Race.BAT); - registerRaceMapping(com.minelittlepony.api.pony.meta.Race.SEAPONY, Race.UNICORN); + registerRaceMapping(com.minelittlepony.api.pony.meta.Race.SEAPONY, Race.SEAPONY); } private void onPonyModelPrepared(Entity entity, PonyModel model, ModelAttributes.Mode mode) { diff --git a/src/main/java/com/minelittlepony/unicopia/client/render/AccessoryFeatureRenderer.java b/src/main/java/com/minelittlepony/unicopia/client/render/AccessoryFeatureRenderer.java index 94a0a77e..5ef86cf0 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/render/AccessoryFeatureRenderer.java +++ b/src/main/java/com/minelittlepony/unicopia/client/render/AccessoryFeatureRenderer.java @@ -24,8 +24,10 @@ public class AccessoryFeatureRenderer< private static final List> REGISTRY = new ArrayList<>(); - public static void register(FeatureFactory factory) { - REGISTRY.add(factory); + public static void register(FeatureFactory...factories) { + for (var factory : factories) { + REGISTRY.add(factory); + } } private final Iterable> features; diff --git a/src/main/java/com/minelittlepony/unicopia/client/render/ModelPartHooks.java b/src/main/java/com/minelittlepony/unicopia/client/render/ModelPartHooks.java index b892836b..21401622 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/render/ModelPartHooks.java +++ b/src/main/java/com/minelittlepony/unicopia/client/render/ModelPartHooks.java @@ -32,7 +32,6 @@ public class ModelPartHooks { final var bestCandidate = new EnqueudHeadRender(); - matrices.push(); part.forEachCuboid(matrices, (entry, name, index, cube) -> { float x = cube.maxX - cube.minX; float y = cube.maxY - cube.minY; @@ -47,7 +46,6 @@ public class ModelPartHooks { bestCandidate.maxSideLength = Math.max(Math.max(x, z), y); } }); - matrices.pop(); if (bestCandidate.transformation != null) { head.add(bestCandidate); @@ -75,8 +73,6 @@ public class ModelPartHooks { matrices.translate(x * PIXEL_SCALE, y * PIXEL_SCALE, z * PIXEL_SCALE); matrices.scale(scale, scale, scale); - //matrices.peek().getPositionMatrix().scaleAround(scale, x * PIXEL_SCALE, y * PIXEL_SCALE, z * PIXEL_SCALE); - //matrices.translate(cube.minX * PIXEL_SCALE, cube.minY * PIXEL_SCALE, cube.minZ * PIXEL_SCALE); } } } diff --git a/src/main/java/com/minelittlepony/unicopia/client/render/PolearmRenderer.java b/src/main/java/com/minelittlepony/unicopia/client/render/PolearmRenderer.java index bb78a379..73dc07f6 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/render/PolearmRenderer.java +++ b/src/main/java/com/minelittlepony/unicopia/client/render/PolearmRenderer.java @@ -4,33 +4,40 @@ import net.fabricmc.fabric.api.client.model.loading.v1.ModelLoadingPlugin; import net.fabricmc.fabric.api.client.rendering.v1.BuiltinItemRendererRegistry; import net.fabricmc.fabric.api.client.rendering.v1.BuiltinItemRendererRegistry.DynamicItemRenderer; import net.minecraft.client.MinecraftClient; +import net.minecraft.client.item.ClampedModelPredicateProvider; import net.minecraft.client.item.ModelPredicateProviderRegistry; import net.minecraft.client.model.*; +import net.minecraft.client.render.RenderLayer; import net.minecraft.client.render.VertexConsumerProvider; -import net.minecraft.client.render.entity.model.TridentEntityModel; import net.minecraft.client.render.item.ItemRenderer; import net.minecraft.client.render.model.BakedModel; import net.minecraft.client.render.model.json.ModelTransformationMode; import net.minecraft.client.util.ModelIdentifier; import net.minecraft.client.util.math.MatrixStack; +import net.minecraft.client.world.ClientWorld; +import net.minecraft.entity.LivingEntity; import net.minecraft.item.*; import net.minecraft.util.Identifier; import net.minecraft.util.math.RotationAxis; import net.minecraft.registry.Registries; -public class PolearmRenderer implements DynamicItemRenderer { +public class PolearmRenderer implements DynamicItemRenderer, ClampedModelPredicateProvider { private static final PolearmRenderer INSTANCE = new PolearmRenderer(); private static final Identifier THROWING = new Identifier("throwing"); - private final TridentEntityModel model = new TridentEntityModel(getTexturedModelData().createModel()); + private final ModelPart model = getTexturedModelData().createModel(); - public static void register(Item item) { - BuiltinItemRendererRegistry.INSTANCE.register(item, INSTANCE); - ModelPredicateProviderRegistry.register(item, THROWING, (stack, world, entity, seed) -> { - return entity != null && entity.isUsingItem() && entity.getActiveItem() == stack ? 1 : 0; + public static void register(Item...items) { + for (Item item : items) { + BuiltinItemRendererRegistry.INSTANCE.register(item, INSTANCE); + ModelPredicateProviderRegistry.register(item, THROWING, INSTANCE); + } + ModelLoadingPlugin.register(context -> { + for (Item item : items) { + context.addModels(getModelId(item)); + } }); - ModelLoadingPlugin.register(context -> context.addModels(getModelId(item))); } static ModelIdentifier getModelId(ItemConvertible item) { @@ -50,6 +57,11 @@ public class PolearmRenderer implements DynamicItemRenderer { return TexturedModelData.of(data, 32, 32); } + @Override + public float unclampedCall(ItemStack stack, ClientWorld world, LivingEntity entity, int seed) { + return entity != null && entity.isUsingItem() && entity.getActiveItem() == stack ? 1 : 0; + } + @Override public void render(ItemStack stack, ModelTransformationMode mode, MatrixStack matrices, VertexConsumerProvider vertexConsumers, int light, int overlay) { @@ -77,7 +89,7 @@ public class PolearmRenderer implements DynamicItemRenderer { } Identifier id = Registries.ITEM.getId(stack.getItem()); Identifier texture = new Identifier(id.getNamespace(), "textures/entity/polearm/" + id.getPath() + ".png"); - model.render(matrices, ItemRenderer.getDirectItemGlintConsumer(vertexConsumers, model.getLayer(texture), false, stack.hasGlint()), light, overlay, 1, 1, 1, 1); + model.render(matrices, ItemRenderer.getDirectItemGlintConsumer(vertexConsumers, RenderLayer.getEntitySolid(texture), false, stack.hasGlint()), light, overlay, 1, 1, 1, 1); matrices.pop(); } } diff --git a/src/main/java/com/minelittlepony/unicopia/client/render/SmittenEyesRenderer.java b/src/main/java/com/minelittlepony/unicopia/client/render/SmittenEyesRenderer.java index 2459266a..9fa33446 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/render/SmittenEyesRenderer.java +++ b/src/main/java/com/minelittlepony/unicopia/client/render/SmittenEyesRenderer.java @@ -1,7 +1,6 @@ package com.minelittlepony.unicopia.client.render; import com.minelittlepony.unicopia.Unicopia; -import com.minelittlepony.unicopia.client.minelittlepony.MineLPDelegate; import com.minelittlepony.unicopia.entity.Creature; import com.minelittlepony.unicopia.item.enchantment.WantItNeedItEnchantment; @@ -20,7 +19,6 @@ import net.minecraft.client.util.math.MatrixStack; import net.minecraft.util.Identifier; import net.minecraft.util.math.Box; import net.minecraft.util.math.MathHelper; -import net.minecraft.util.math.RotationAxis; public class SmittenEyesRenderer { private static final Identifier TEXTURE = Unicopia.id("textures/entity/smitten_eyes.png"); @@ -42,9 +40,6 @@ public class SmittenEyesRenderer { ModelPartHooks.stopCollecting().forEach(head -> { matrices.push(); head.transform(matrices, 0.95F); - if (MineLPDelegate.getInstance().getRace(pony.asEntity()).isEquine()) { - matrices.multiply(RotationAxis.POSITIVE_Z.rotationDegrees(-90), 0, 1.2F, 0); - } float scale = 1F + (1.3F + MathHelper.sin(pony.asEntity().age / 3F) * 0.06F); matrices.scale(scale, scale, scale); matrices.translate(0, 0.05F, 0); diff --git a/src/main/java/com/minelittlepony/unicopia/client/render/WingsFeatureRenderer.java b/src/main/java/com/minelittlepony/unicopia/client/render/WingsFeatureRenderer.java index b9d33535..10c8ecc3 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/render/WingsFeatureRenderer.java +++ b/src/main/java/com/minelittlepony/unicopia/client/render/WingsFeatureRenderer.java @@ -1,5 +1,6 @@ package com.minelittlepony.unicopia.client.render; +import com.minelittlepony.unicopia.FlightType; import com.minelittlepony.unicopia.Unicopia; import com.minelittlepony.unicopia.entity.player.Pony; @@ -50,7 +51,7 @@ public class WingsFeatureRenderer implements AccessoryFe } protected boolean canRender(E entity) { - return entity instanceof PlayerEntity && Pony.of((PlayerEntity)entity).getObservedSpecies().canInteractWithClouds(); + return entity instanceof PlayerEntity && Pony.of((PlayerEntity)entity).getObservedSpecies().flightType() == FlightType.AVIAN; } protected Identifier getTexture(E entity) { diff --git a/src/main/java/com/minelittlepony/unicopia/client/render/WorldRenderDelegate.java b/src/main/java/com/minelittlepony/unicopia/client/render/WorldRenderDelegate.java index 30472c2c..70a7c975 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/render/WorldRenderDelegate.java +++ b/src/main/java/com/minelittlepony/unicopia/client/render/WorldRenderDelegate.java @@ -4,16 +4,21 @@ import java.util.Optional; import com.minelittlepony.client.util.render.RenderLayerUtil; import com.minelittlepony.unicopia.EquinePredicates; +import com.minelittlepony.unicopia.Race; import com.minelittlepony.unicopia.Unicopia; +import com.minelittlepony.unicopia.client.minelittlepony.MineLPDelegate; +import com.minelittlepony.unicopia.client.render.model.SphereModel; import com.minelittlepony.unicopia.entity.Creature; import com.minelittlepony.unicopia.entity.Equine; import com.minelittlepony.unicopia.entity.ItemImpl; import com.minelittlepony.unicopia.entity.Living; import com.minelittlepony.unicopia.entity.duck.LavaAffine; import com.minelittlepony.unicopia.entity.player.Pony; +import com.mojang.blaze3d.systems.RenderSystem; import net.minecraft.client.MinecraftClient; import net.minecraft.client.render.*; +import net.minecraft.client.render.BackgroundRenderer.FogType; import net.minecraft.client.render.VertexConsumerProvider.Immediate; import net.minecraft.client.util.math.MatrixStack; import net.minecraft.entity.*; @@ -43,6 +48,20 @@ public class WorldRenderDelegate { return Optional.empty(); } + public void applyFog(Camera camera, FogType fogType, float viewDistance, boolean thickFog, float tickDelta) { + if (camera.getSubmersionType() == CameraSubmersionType.WATER) { + if (EquinePredicates.PLAYER_SEAPONY.test(MinecraftClient.getInstance().player)) { + RenderSystem.setShaderFogStart(RenderSystem.getShaderFogStart() - 30); + RenderSystem.setShaderFogEnd(RenderSystem.getShaderFogEnd() + 190); + } + } + if (camera.getSubmersionType() == CameraSubmersionType.NONE) { + if (EquinePredicates.PLAYER_SEAPONY.test(MinecraftClient.getInstance().player)) { + RenderSystem.setShaderFogStart(-130); + } + } + } + public boolean beforeEntityRender(Entity entity, double x, double y, double z, float yaw, float tickDelta, MatrixStack matrices, VertexConsumerProvider vertices, int light) { @@ -80,6 +99,27 @@ public class WorldRenderDelegate { smittenEyesRenderer.render(creature, matrices, immediate, light, 0); } + if (pony instanceof Pony p) { + if (p.getCompositeRace().includes(Race.SEAPONY) + && pony.asEntity().isSubmergedInWater() + && MineLPDelegate.getInstance().getPlayerPonyRace(p.asEntity()) != Race.SEAPONY) { + + for (var head : ModelPartHooks.stopCollecting()) { + matrices.push(); + head.transform(matrices, 1F); + + Immediate immediate = MinecraftClient.getInstance().getBufferBuilders().getEntityVertexConsumers(); + RenderLayer layer = RenderLayers.getMagicColored(); + float scale = 0.9F; + + SphereModel.SPHERE.render(matrices, immediate.getBuffer(layer), light, 0, scale, 0.5F, 0.5F, 0.5F, 0.1F); + SphereModel.SPHERE.render(matrices, immediate.getBuffer(layer), light, 0, scale + 0.2F, 0.5F, 0.5F, 0.5F, 0.1F); + + matrices.pop(); + } + } + } + if (pony instanceof ItemImpl || pony instanceof Living) { matrices.pop(); @@ -162,6 +202,13 @@ public class WorldRenderDelegate { roll -= 180; } + if (p.getAcrobatics().isFloppy()) { + matrices.translate(0, -0.5, 0); + p.asEntity().setBodyYaw(0); + p.asEntity().setYaw(0); + matrices.multiply(RotationAxis.NEGATIVE_X.rotationDegrees(90)); + } + matrices.multiply(RotationAxis.NEGATIVE_Y.rotationDegrees(yaw)); matrices.multiply(RotationAxis.POSITIVE_Z.rotationDegrees(roll)); @@ -169,6 +216,12 @@ public class WorldRenderDelegate { matrices.multiply(RotationAxis.POSITIVE_X.rotationDegrees(diveAngle)); matrices.multiply(RotationAxis.POSITIVE_Y.rotationDegrees(yaw)); + + if (p.getCompositeRace().includes(Race.SEAPONY) + && pony.asEntity().isSubmergedInWater() + && MineLPDelegate.getInstance().getPlayerPonyRace(p.asEntity()) != Race.SEAPONY) { + ModelPartHooks.startCollecting(); + } } else if (pony instanceof Creature creature && smittenEyesRenderer.isSmitten(creature)) { ModelPartHooks.startCollecting(); } diff --git a/src/main/java/com/minelittlepony/unicopia/client/render/entity/CloudBedBlockEntityRenderer.java b/src/main/java/com/minelittlepony/unicopia/client/render/entity/CloudBedBlockEntityRenderer.java index 1db8e63d..9d10611a 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/render/entity/CloudBedBlockEntityRenderer.java +++ b/src/main/java/com/minelittlepony/unicopia/client/render/entity/CloudBedBlockEntityRenderer.java @@ -3,6 +3,7 @@ package com.minelittlepony.unicopia.client.render.entity; import org.jetbrains.annotations.Nullable; import com.minelittlepony.unicopia.Unicopia; +import com.minelittlepony.unicopia.block.FancyBedBlock.SheetPattern; import com.minelittlepony.unicopia.block.cloud.CloudBedBlock; import com.minelittlepony.unicopia.client.render.RenderLayers; @@ -18,6 +19,7 @@ import net.minecraft.client.model.ModelPartBuilder; import net.minecraft.client.model.ModelPartData; import net.minecraft.client.model.ModelTransform; import net.minecraft.client.model.TexturedModelData; +import net.minecraft.client.render.VertexConsumer; import net.minecraft.client.render.VertexConsumerProvider; import net.minecraft.client.render.block.entity.BlockEntityRenderer; import net.minecraft.client.render.block.entity.BlockEntityRendererFactory; @@ -30,14 +32,19 @@ import net.minecraft.util.math.RotationAxis; import net.minecraft.world.World; public class CloudBedBlockEntityRenderer implements BlockEntityRenderer { - private static final Identifier TEXTURE = Unicopia.id("textures/entity/cloud_bed/white.png"); - - private final ModelPart bedHead; - private final ModelPart bedFoot; + private final ModelPart bedHead = getHeadTexturedModelData().createModel(); + private final ModelPart bedFoot = getFootTexturedModelData().createModel(); + private final ModelPart bedSheetsHead = getSheetsTexturedModelData(0, 3, 13).createModel(); + private final ModelPart bedSheetsFoot = getSheetsTexturedModelData(22, 0, 15).createModel(); public CloudBedBlockEntityRenderer(BlockEntityRendererFactory.Context ctx) { - this.bedHead = getHeadTexturedModelData().createModel(); - this.bedFoot = getFootTexturedModelData().createModel(); + } + + public static TexturedModelData getSheetsTexturedModelData(int v, int y, int height) { + ModelData data = new ModelData(); + ModelPartData root = data.getRoot(); + root.addChild("main", ModelPartBuilder.create().uv(0, v).cuboid(0, y, 0, 16, height, 6), ModelTransform.NONE); + return TexturedModelData.of(data, 64, 64); } public static TexturedModelData getHeadTexturedModelData() { @@ -66,9 +73,19 @@ public class CloudBedBlockEntityRenderer implements BlockEntityRenderer()).get(worldLight); } - private void renderModel(MatrixStack matrices, VertexConsumerProvider vertices, ModelPart part, Direction direction, Identifier texture, int light, int overlay, boolean translate) { + private void renderModel(MatrixStack matrices, VertexConsumerProvider vertices, ModelPart part, Direction direction, VertexConsumer buffer, int light, int overlay, boolean translate, boolean sheets) { matrices.push(); matrices.translate(0, 0.5625f, translate ? -1 : 0); matrices.multiply(RotationAxis.POSITIVE_X.rotationDegrees(90)); matrices.translate(0.5f, 0.5f, 0.5f); + if (sheets) { + float beddingScale = 1.002F; + matrices.scale(beddingScale, beddingScale, beddingScale); + } matrices.multiply(RotationAxis.POSITIVE_Z.rotationDegrees(180 + direction.asRotation())); matrices.translate(-0.5f, -0.5f, -0.5f); - part.render(matrices, vertices.getBuffer(RenderLayers.getEntityTranslucent(texture)), light, overlay); + part.render(matrices, buffer, light, overlay); matrices.pop(); } } diff --git a/src/main/java/com/minelittlepony/unicopia/client/render/entity/CloudChestBlockEntityRenderer.java b/src/main/java/com/minelittlepony/unicopia/client/render/entity/CloudChestBlockEntityRenderer.java new file mode 100644 index 00000000..20662111 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/client/render/entity/CloudChestBlockEntityRenderer.java @@ -0,0 +1,125 @@ +package com.minelittlepony.unicopia.client.render.entity; + +import com.minelittlepony.unicopia.Unicopia; +import net.minecraft.block.AbstractChestBlock; +import net.minecraft.block.BlockState; +import net.minecraft.block.Blocks; +import net.minecraft.block.ChestBlock; +import net.minecraft.block.DoubleBlockProperties; +import net.minecraft.block.entity.ChestBlockEntity; +import net.minecraft.block.enums.ChestType; +import net.minecraft.client.model.Dilation; +import net.minecraft.client.model.ModelData; +import net.minecraft.client.model.ModelPart; +import net.minecraft.client.model.ModelPartBuilder; +import net.minecraft.client.model.ModelPartData; +import net.minecraft.client.model.ModelTransform; +import net.minecraft.client.model.TexturedModelData; +import net.minecraft.client.render.RenderLayer; +import net.minecraft.client.render.VertexConsumer; +import net.minecraft.client.render.VertexConsumerProvider; +import net.minecraft.client.render.block.entity.BlockEntityRendererFactory.Context; +import net.minecraft.client.render.block.entity.ChestBlockEntityRenderer; +import net.minecraft.client.render.block.entity.LightmapCoordinatesRetriever; +import net.minecraft.client.util.math.MatrixStack; +import net.minecraft.util.Identifier; +import net.minecraft.util.math.Direction; +import net.minecraft.util.math.RotationAxis; + +public class CloudChestBlockEntityRenderer extends ChestBlockEntityRenderer { + private static final LightmapCoordinatesRetriever LIGHTING = new LightmapCoordinatesRetriever<>(); + private final Model[] models; + + public CloudChestBlockEntityRenderer(Context ctx) { + super(ctx); + models = new Model[] { + new Model(Model.getSingleChestModelData().createModel(), Unicopia.id("textures/entity/chest/cloud.png")), + new Model(Model.getLeftChestModelData().createModel(), Unicopia.id("textures/entity/chest/cloud_left.png")), + new Model(Model.getRightChestModelData().createModel(), Unicopia.id("textures/entity/chest/cloud_right.png")) + }; + } + + @Override + public void render(ChestBlockEntity entity, float tickDelta, MatrixStack matrices, VertexConsumerProvider vertexConsumers, int light, int overlay) { + BlockState state = entity.getWorld() != null ? entity.getCachedState() : Blocks.CHEST.getDefaultState().with(ChestBlock.FACING, Direction.SOUTH); + + if (!(state.getBlock() instanceof AbstractChestBlock)) { + return; + } + + Model model = models[state.getOrEmpty(ChestBlock.CHEST_TYPE).orElse(ChestType.SINGLE).ordinal()]; + var properties = getProperties(state, entity); + + matrices.push(); + matrices.translate(0.5f, 0.5f, 0.5f); + matrices.multiply(RotationAxis.POSITIVE_Y.rotationDegrees(-state.get(ChestBlock.FACING).asRotation())); + matrices.translate(-0.5f, -0.5f, -0.5f); + model.setAngles(1 - (float)Math.pow(1 - properties.apply(ChestBlock.getAnimationProgressRetriever(entity)).get(tickDelta), 3)); + model.render(matrices, vertexConsumers.getBuffer(RenderLayer.getEntityTranslucent(model.texture)), properties.apply(LIGHTING).applyAsInt(light), overlay); + matrices.pop(); + } + + private DoubleBlockProperties.PropertySource getProperties(BlockState state, ChestBlockEntity entity) { + return entity.getWorld() != null + ? ((AbstractChestBlock)state.getBlock()).getBlockEntitySource(state, entity.getWorld(), entity.getPos(), true) + : DoubleBlockProperties.PropertyRetriever::getFallback; + } + + static class Model { + private final ModelPart tree; + private final ModelPart lid; + + private final Identifier texture; + + public Model(ModelPart tree, Identifier texture) { + this.tree = tree; + this.lid = tree.getChild("lid"); + this.texture = texture; + } + + public static TexturedModelData getSingleChestModelData() { + ModelData data = new ModelData(); + ModelPartData root = data.getRoot(); + root.addChild("chest", ModelPartBuilder.create().uv(0, 19).cuboid(1, 0, 1, 14, 10, 14, Dilation.NONE), ModelTransform.NONE); + root.addChild("lid", ModelPartBuilder.create() + .uv(0, 0).cuboid(6, -2, 13.8F, 2, 4, 1, Dilation.NONE) + .uv(0, 0).cuboid(6, -1, 14, 2, 2, 1, Dilation.NONE) + .uv(0, 0).cuboid(0, 0, 0, 14, 5, 14, new Dilation(0.3F)), ModelTransform.pivot(1, 9, 1)) + .addChild("lock_r1", ModelPartBuilder.create() + .uv(0, 0).cuboid(-2, -4, -0.5F, 2, 4, 1, Dilation.NONE), ModelTransform.of(5, 1, 14.3F, 0, 0, 1.5708F)); + return TexturedModelData.of(data, 64, 64); + } + + public static TexturedModelData getLeftChestModelData() { + ModelData data = new ModelData(); + ModelPartData root = data.getRoot(); + root.addChild("chest", ModelPartBuilder.create().uv(0, 19).cuboid(0, 0, 1, 15, 10, 14, Dilation.NONE), ModelTransform.NONE); + root.addChild("lid", ModelPartBuilder.create() + .uv(0, 0).cuboid(6, -2, 13.8F, 2, 4, 1, Dilation.NONE) + .uv(0, 0).cuboid(6, -1, 14, 2, 2, 1, Dilation.NONE) + .uv(0, 0).cuboid(0, 0, 0, 15, 5, 14, new Dilation(0.3F)), ModelTransform.pivot(0, 9, 1)) + .addChild("lock_r1", ModelPartBuilder.create().uv(0, 0).cuboid(-2, -4, -0.5F, 2, 4, 1, Dilation.NONE), ModelTransform.of(5, 1, 14.3F, 0, 0, 1.5708F)); + return TexturedModelData.of(data, 64, 64); + } + + public static TexturedModelData getRightChestModelData() { + ModelData data = new ModelData(); + ModelPartData root = data.getRoot(); + root.addChild("chest", ModelPartBuilder.create().uv(0, 19).cuboid(1, 0, 1, 15, 10, 14, Dilation.NONE), ModelTransform.NONE); + root.addChild("lid", ModelPartBuilder.create() + .uv(0, 0).cuboid(7, -2, 13.8F, 2, 4, 1, Dilation.NONE) + .uv(0, 0).cuboid(7, -1, 14, 2, 2, 1, Dilation.NONE) + .uv(0, 0).cuboid(0, 0, 0, 15, 5, 14, new Dilation(0.3F)), ModelTransform.pivot(1, 9, 1)) + .addChild("lock_r1", ModelPartBuilder.create().uv(0, 0).cuboid(-2, -4, -0.5F, 2, 4, 1, Dilation.NONE), ModelTransform.of(6, 1, 14.3F, 0, 0, 1.5708F)); + return TexturedModelData.of(data, 64, 64); + } + + public void setAngles(float animationProgress) { + lid.pitch = -(animationProgress * 1.5707964f); + } + + public void render(MatrixStack matrices, VertexConsumer vertices, int light, int overlay) { + tree.render(matrices, vertices, light, overlay); + } + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/client/render/entity/LootBugEntityRenderer.java b/src/main/java/com/minelittlepony/unicopia/client/render/entity/LootBugEntityRenderer.java new file mode 100644 index 00000000..b8ffe426 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/client/render/entity/LootBugEntityRenderer.java @@ -0,0 +1,28 @@ +package com.minelittlepony.unicopia.client.render.entity; + +import com.minelittlepony.unicopia.Unicopia; + +import net.minecraft.client.render.entity.EntityRendererFactory.Context; +import net.minecraft.client.util.math.MatrixStack; +import net.minecraft.entity.mob.SilverfishEntity; +import net.minecraft.util.Identifier; +import net.minecraft.client.render.entity.SilverfishEntityRenderer; + +public class LootBugEntityRenderer extends SilverfishEntityRenderer { + private static final Identifier TEXTURE = Unicopia.id("textures/entity/loot_bug.png"); + + public LootBugEntityRenderer(Context context) { + super(context); + } + + @Override + public Identifier getTexture(SilverfishEntity entity) { + return TEXTURE; + } + + @Override + protected void scale(SilverfishEntity entity, MatrixStack matrices, float tickDelta) { + float scale = 2; + matrices.scale(scale, scale, scale); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/command/SpeciesCommand.java b/src/main/java/com/minelittlepony/unicopia/command/SpeciesCommand.java index 6f93995b..1363ee96 100644 --- a/src/main/java/com/minelittlepony/unicopia/command/SpeciesCommand.java +++ b/src/main/java/com/minelittlepony/unicopia/command/SpeciesCommand.java @@ -8,7 +8,6 @@ import com.minelittlepony.unicopia.network.MsgTribeSelect; import com.mojang.brigadier.builder.LiteralArgumentBuilder; import net.minecraft.command.argument.EntityArgumentType; -import net.minecraft.command.argument.RegistryKeyArgumentType; import net.minecraft.entity.player.PlayerEntity; import net.minecraft.server.command.CommandManager; import net.minecraft.server.command.CommandManager.RegistrationEnvironment; @@ -32,8 +31,6 @@ class SpeciesCommand { } } - RegistryKeyArgumentType raceArgument = Race.argument(); - return builder .then(CommandManager.literal("get") .executes(context -> get(context.getSource(), context.getSource().getPlayer(), true)) @@ -41,13 +38,13 @@ class SpeciesCommand { .executes(context -> get(context.getSource(), EntityArgumentType.getPlayer(context, "target"), false)) )) .then(CommandManager.literal("set") - .then(CommandManager.argument("race", raceArgument) + .then(CommandManager.argument("race", Race.argument()) .executes(context -> set(context.getSource(), context.getSource().getPlayer(), Race.fromArgument(context, "race"), true)) .then(CommandManager.argument("target", EntityArgumentType.player()) .executes(context -> set(context.getSource(), EntityArgumentType.getPlayer(context, "target"), Race.fromArgument(context, "race"), false))) )) .then(CommandManager.literal("describe") - .then(CommandManager.argument("race", raceArgument) + .then(CommandManager.argument("race", Race.argument()) .executes(context -> describe(context.getSource().getPlayer(), Race.fromArgument(context, "race"))) )) .then(CommandManager.literal("list") @@ -101,7 +98,7 @@ class SpeciesCommand { boolean first = true; for (Race i : Race.REGISTRY) { - if (!i.isUnset() && i.isPermitted(player)) { + if (i.availability().isGrantable() && !i.isUnset() && i.isPermitted(player)) { message.append(Text.literal((!first ? "\n" : "") + " - ")); message.append(i.getDisplayName()); first = false; diff --git a/src/main/java/com/minelittlepony/unicopia/compat/emi/Main.java b/src/main/java/com/minelittlepony/unicopia/compat/emi/Main.java index 943d6a23..6282866a 100644 --- a/src/main/java/com/minelittlepony/unicopia/compat/emi/Main.java +++ b/src/main/java/com/minelittlepony/unicopia/compat/emi/Main.java @@ -11,6 +11,7 @@ import com.minelittlepony.unicopia.ability.magic.spell.crafting.SpellEnhancingRe import com.minelittlepony.unicopia.ability.magic.spell.crafting.SpellShapedCraftingRecipe; import com.minelittlepony.unicopia.ability.magic.spell.trait.SpellTraits; import com.minelittlepony.unicopia.ability.magic.spell.trait.Trait; +import com.minelittlepony.unicopia.block.UBlocks; import com.minelittlepony.unicopia.item.EnchantableItem; import com.minelittlepony.unicopia.item.UItems; import com.minelittlepony.unicopia.item.URecipes; @@ -22,6 +23,7 @@ import dev.emi.emi.api.recipe.EmiRecipeCategory; import dev.emi.emi.api.render.EmiTexture; import dev.emi.emi.api.stack.Comparison; import dev.emi.emi.api.stack.EmiStack; +import dev.emi.emi.recipe.EmiStonecuttingRecipe; import net.minecraft.item.ItemStack; import net.minecraft.recipe.RecipeType; import net.minecraft.registry.DynamicRegistryManager; @@ -30,7 +32,9 @@ import net.minecraft.util.Identifier; public class Main implements EmiPlugin { static final EmiStack SPELL_BOOK_STATION = EmiStack.of(UItems.SPELLBOOK); + static final EmiStack CLOUD_SHAPING_STATION = EmiStack.of(UBlocks.SHAPING_BENCH); static final EmiRecipeCategory SPELL_BOOK_CATEGORY = new EmiRecipeCategory(Unicopia.id("spellbook"), SPELL_BOOK_STATION, SPELL_BOOK_STATION); + static final EmiRecipeCategory CLOUD_SHAPING_CATEGORY = new EmiRecipeCategory(Unicopia.id("cloud_shaping"), CLOUD_SHAPING_STATION, CLOUD_SHAPING_STATION); static final Identifier WIDGETS = Unicopia.id("textures/gui/widgets.png"); static final EmiTexture EMPTY_ARROW = new EmiTexture(WIDGETS, 44, 0, 24, 17); @@ -70,6 +74,17 @@ public class Main implements EmiPlugin { } }); + registry.addCategory(CLOUD_SHAPING_CATEGORY); + registry.addWorkstation(CLOUD_SHAPING_CATEGORY, CLOUD_SHAPING_STATION); + registry.getRecipeManager().listAllOfType(URecipes.CLOUD_SHAPING).forEach(recipe -> { + registry.addRecipe(new EmiStonecuttingRecipe(recipe.value()) { + @Override + public EmiRecipeCategory getCategory() { + return CLOUD_SHAPING_CATEGORY; + } + }); + }); + Stream.of(UItems.GEMSTONE, UItems.BOTCHED_GEM, UItems.MAGIC_STAFF, UItems.FILLED_JAR).forEach(item -> { registry.setDefaultComparison(item, comparison -> Comparison.compareNbt()); }); diff --git a/src/main/java/com/minelittlepony/unicopia/compat/trinkets/TrinketsDelegate.java b/src/main/java/com/minelittlepony/unicopia/compat/trinkets/TrinketsDelegate.java index beb2e98e..dfa184dc 100644 --- a/src/main/java/com/minelittlepony/unicopia/compat/trinkets/TrinketsDelegate.java +++ b/src/main/java/com/minelittlepony/unicopia/compat/trinkets/TrinketsDelegate.java @@ -6,6 +6,7 @@ import java.util.stream.Stream; import com.minelittlepony.unicopia.EntityConvertable; import com.minelittlepony.unicopia.container.SpellbookScreenHandler; + import net.fabricmc.loader.api.FabricLoader; import net.minecraft.entity.EquipmentSlot; import net.minecraft.entity.LivingEntity; @@ -67,7 +68,7 @@ public interface TrinketsDelegate { } default Set getAvailableTrinketSlots(LivingEntity entity, Set probedSlots) { - return probedSlots.stream().filter(slot -> getEquipped(entity, slot).count() == 0).collect(Collectors.toSet()); + return probedSlots.stream().filter(slot -> getEquipped(entity, slot).anyMatch(ItemStack::isEmpty)).collect(Collectors.toSet()); } default Stream getEquipped(LivingEntity entity, Identifier slot) { diff --git a/src/main/java/com/minelittlepony/unicopia/container/ShapingBenchScreenHandler.java b/src/main/java/com/minelittlepony/unicopia/container/ShapingBenchScreenHandler.java new file mode 100644 index 00000000..3ff1ac4a --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/container/ShapingBenchScreenHandler.java @@ -0,0 +1,96 @@ +package com.minelittlepony.unicopia.container; + +import com.minelittlepony.unicopia.block.UBlocks; +import com.minelittlepony.unicopia.item.URecipes; + +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.entity.player.PlayerInventory; +import net.minecraft.inventory.Inventory; +import net.minecraft.inventory.SimpleInventory; +import net.minecraft.item.Item; +import net.minecraft.item.ItemStack; +import net.minecraft.screen.ScreenHandlerContext; +import net.minecraft.screen.ScreenHandlerType; +import net.minecraft.screen.StonecutterScreenHandler; +import net.minecraft.screen.slot.Slot; +import net.minecraft.world.World; + +public class ShapingBenchScreenHandler extends StonecutterScreenHandler { + + private final ScreenHandlerContext context; + private final World world; + + private ItemStack inputStack = ItemStack.EMPTY; + + public ShapingBenchScreenHandler(int syncId, PlayerInventory playerInventory, ScreenHandlerContext context) { + super(syncId, playerInventory, context); + this.context = context; + this.world = playerInventory.player.getWorld(); + } + + public ShapingBenchScreenHandler(int syncId, PlayerInventory playerInventory) { + super(syncId, playerInventory); + this.context = ScreenHandlerContext.EMPTY; + this.world = playerInventory.player.getWorld(); + } + + @Override + public ScreenHandlerType getType() { + return UScreenHandlers.SHAPING_BENCH; + } + + @Override + public boolean canUse(PlayerEntity player) { + return canUse(context, player, UBlocks.SHAPING_BENCH); + } + + @Override + public void onContentChanged(Inventory inventory) { + ItemStack stack = slots.get(0).getStack(); + if (!stack.isOf(inputStack.getItem())) { + inputStack = stack.copy(); + getAvailableRecipes().clear(); + setProperty(0, -1); + slots.get(1).setStackNoCallbacks(ItemStack.EMPTY); + if (!stack.isEmpty()) { + getAvailableRecipes().addAll(world.getRecipeManager().getAllMatches(URecipes.CLOUD_SHAPING, input, world)); + } + } + } + + @Override + public ItemStack quickMove(PlayerEntity player, int slot) { + ItemStack originalStack = ItemStack.EMPTY; + Slot srcSlot = slots.get(slot); + if (srcSlot != null && srcSlot.hasStack()) { + ItemStack movingStack = srcSlot.getStack(); + Item item = movingStack.getItem(); + originalStack = movingStack.copy(); + if (slot == 1) { + item.onCraft(movingStack, player.getWorld(), player); + if (!insertItem(movingStack, 2, 38, true)) { + return ItemStack.EMPTY; + } + srcSlot.onQuickTransfer(movingStack, originalStack); + } else if (slot == 0 + ? !insertItem(movingStack, 2, 38, false) + : (world.getRecipeManager().getFirstMatch(URecipes.CLOUD_SHAPING, new SimpleInventory(movingStack), world).isPresent() + ? !insertItem(movingStack, 0, 1, false) + : (slot >= 2 && slot < 29 + ? !insertItem(movingStack, 29, 38, false) + : slot >= 29 && slot < 38 && !insertItem(movingStack, 2, 29, false)))) { + return ItemStack.EMPTY; + } + if (movingStack.isEmpty()) { + srcSlot.setStack(ItemStack.EMPTY); + } + srcSlot.markDirty(); + if (movingStack.getCount() == originalStack.getCount()) { + return ItemStack.EMPTY; + } + srcSlot.onTakeItem(player, movingStack); + this.sendContentUpdates(); + } + return originalStack; + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/container/UScreenHandlers.java b/src/main/java/com/minelittlepony/unicopia/container/UScreenHandlers.java index f2fba259..f62a097a 100644 --- a/src/main/java/com/minelittlepony/unicopia/container/UScreenHandlers.java +++ b/src/main/java/com/minelittlepony/unicopia/container/UScreenHandlers.java @@ -6,10 +6,12 @@ import net.fabricmc.fabric.api.screenhandler.v1.ExtendedScreenHandlerType; import net.minecraft.screen.ScreenHandler; import net.minecraft.screen.ScreenHandlerType; import net.minecraft.registry.Registry; +import net.minecraft.resource.featuretoggle.FeatureFlags; import net.minecraft.registry.Registries; public interface UScreenHandlers { ScreenHandlerType SPELL_BOOK = register("spell_book", new ExtendedScreenHandlerType<>(SpellbookScreenHandler::new)); + ScreenHandlerType SHAPING_BENCH = register("shaping_bench", new ScreenHandlerType<>(ShapingBenchScreenHandler::new, FeatureFlags.VANILLA_FEATURES)); static ScreenHandlerType register(String name, ScreenHandlerType type) { return Registry.register(Registries.SCREEN_HANDLER, Unicopia.id(name), type); diff --git a/src/main/java/com/minelittlepony/unicopia/diet/Ailment.java b/src/main/java/com/minelittlepony/unicopia/diet/Ailment.java new file mode 100644 index 00000000..9dadb1a8 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/diet/Ailment.java @@ -0,0 +1,22 @@ +package com.minelittlepony.unicopia.diet; + +import com.minelittlepony.unicopia.diet.affliction.Affliction; +import com.mojang.serialization.Codec; +import com.mojang.serialization.codecs.RecordCodecBuilder; + +import net.minecraft.network.PacketByteBuf; + +public record Ailment(Affliction effects) { + public static final Ailment EMPTY = new Ailment(Affliction.EMPTY); + public static final Codec CODEC = RecordCodecBuilder.create(instance -> instance.group( + Affliction.CODEC.fieldOf("effects").forGetter(Ailment::effects) + ).apply(instance, Ailment::new)); + + public Ailment(PacketByteBuf buffer) { + this(Affliction.read(buffer)); + } + + public void toBuffer(PacketByteBuf buffer) { + Affliction.write(buffer, effects); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/diet/DietProfile.java b/src/main/java/com/minelittlepony/unicopia/diet/DietProfile.java new file mode 100644 index 00000000..46900f8f --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/diet/DietProfile.java @@ -0,0 +1,157 @@ +package com.minelittlepony.unicopia.diet; + +import java.util.ArrayList; +import java.util.HashSet; +import java.util.List; +import java.util.Optional; +import java.util.Set; +import java.util.function.Predicate; +import java.util.stream.Collectors; + +import org.jetbrains.annotations.Nullable; + +import com.minelittlepony.unicopia.item.ItemDuck; +import com.mojang.datafixers.util.Pair; +import com.mojang.serialization.Codec; +import com.mojang.serialization.codecs.RecordCodecBuilder; + +import net.minecraft.client.item.TooltipContext; +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.item.FoodComponent; +import net.minecraft.item.Item; +import net.minecraft.item.ItemStack; +import net.minecraft.network.PacketByteBuf; +import net.minecraft.registry.RegistryKeys; +import net.minecraft.registry.tag.TagKey; +import net.minecraft.text.Text; +import net.minecraft.util.Formatting; +import net.minecraft.util.UseAction; + +public record DietProfile( + float defaultMultiplier, + float foragingMultiplier, + List multipliers, + List effects, + Optional defaultEffect + ) { + public static final DietProfile EMPTY = new DietProfile(1, 1, List.of(), List.of(), Optional.empty()); + public static final Codec CODEC = RecordCodecBuilder.create(instance -> instance.group( + Codec.FLOAT.fieldOf("default_multiplier").forGetter(DietProfile::defaultMultiplier), + Codec.FLOAT.fieldOf("foraging_multiplier").forGetter(DietProfile::foragingMultiplier), + Codec.list(Multiplier.CODEC).fieldOf("multipliers").forGetter(DietProfile::multipliers), + Codec.list(Effect.CODEC).fieldOf("effects").forGetter(DietProfile::effects), + Effect.CODEC.optionalFieldOf("default_effect").forGetter(DietProfile::defaultEffect) + ).apply(instance, DietProfile::new)); + + public DietProfile(PacketByteBuf buffer) { + this(buffer.readFloat(), buffer.readFloat(), buffer.readList(Multiplier::new), buffer.readList(Effect::new), buffer.readOptional(Effect::new)); + } + + public void toBuffer(PacketByteBuf buffer) { + buffer.writeFloat(defaultMultiplier); + buffer.writeFloat(foragingMultiplier); + buffer.writeCollection(multipliers, (b, t) -> t.toBuffer(b)); + buffer.writeCollection(effects, (b, t) -> t.toBuffer(b)); + buffer.writeOptional(defaultEffect, (b, t) -> t.toBuffer(b)); + } + + public Optional findMultiplier(ItemStack stack) { + return multipliers.stream().filter(m -> m.test(stack)).findFirst(); + } + + public Optional findEffect(ItemStack stack) { + return effects.stream().filter(m -> m.test(stack)).findFirst().or(this::defaultEffect); + } + + static boolean isForaged(ItemStack stack) { + return ((ItemDuck)stack.getItem()).getOriginalFoodComponent().isEmpty(); + } + + @Nullable + public FoodComponent getAdjustedFoodComponent(ItemStack stack) { + var food = stack.getItem().getFoodComponent(); + if (this == EMPTY) { + return food; + } + + var ratios = getRatios(stack); + if (isInedible(ratios)) { + return null; + } + + return FoodAttributes.copy(food) + .hunger(Math.max(1, (int)(food.getHunger() * ratios.getFirst()))) + .saturationModifier(food.getSaturationModifier() * ratios.getSecond()) + .build(); + } + + public boolean isInedible(ItemStack stack) { + return isInedible(getRatios(stack)); + } + + public boolean isInedible(Pair ratios) { + return ratios.getFirst() <= 0.01F && ratios.getSecond() <= 0.01F; + } + + public Pair getRatios(ItemStack stack) { + Optional multiplier = findMultiplier(stack); + + float baseMultiplier = (isForaged(stack) ? foragingMultiplier() : defaultMultiplier()); + float hungerMultiplier = multiplier.map(Multiplier::hunger).orElse(baseMultiplier); + float saturationMultiplier = multiplier.map(Multiplier::saturation).orElse(baseMultiplier); + return Pair.of(hungerMultiplier, saturationMultiplier); + } + + public void appendTooltip(ItemStack stack, @Nullable PlayerEntity user, List tooltip, TooltipContext context) { + var food = stack.getItem().getFoodComponent(); + var ratios = getRatios(stack); + if (food == null || isInedible(ratios)) { + if (stack.getUseAction() != UseAction.DRINK) { + tooltip.add(Text.literal(" ").append(Text.translatable("unicopia.diet.not_edible")).formatted(Formatting.DARK_GRAY)); + } + return; + } + + float baseMultiplier = (isForaged(stack) ? foragingMultiplier() : defaultMultiplier()); + + if (context.isAdvanced()) { + tooltip.add(Text.literal(" ").append(Text.translatable("unicopia.diet.base_multiplier", baseMultiplier).formatted(Formatting.DARK_GRAY))); + tooltip.add(Text.literal(" ").append(Text.translatable("unicopia.diet.hunger.detailed", Math.max(1, (int)(ratios.getFirst() * food.getHunger())), food.getHunger(), (int)(ratios.getFirst() * 100))).formatted(Formatting.DARK_GRAY)); + tooltip.add(Text.literal(" ").append(Text.translatable("unicopia.diet.saturation.detailed", String.format("%.2f", ratios.getSecond() * food.getSaturationModifier()), (int)(ratios.getSecond() * 100))).formatted(Formatting.DARK_GRAY)); + } else { + tooltip.add(Text.literal(" ").append(Text.translatable("unicopia.diet.hunger", (int)(ratios.getFirst() * 100))).formatted(Formatting.DARK_GRAY)); + tooltip.add(Text.literal(" ").append(Text.translatable("unicopia.diet.saturation", (int)(ratios.getSecond() * 100))).formatted(Formatting.DARK_GRAY)); + } + } + + public record Multiplier( + Set> tags, + float hunger, + float saturation + ) implements Predicate { + public static final Codec>> TAGS_CODEC = Codec.list(TagKey.unprefixedCodec(RegistryKeys.ITEM)).xmap( + l -> l.stream().distinct().collect(Collectors.toSet()), + set -> new ArrayList<>(set) + ); + public static final Codec CODEC = RecordCodecBuilder.create(instance -> instance.group( + TAGS_CODEC.fieldOf("tags").forGetter(Multiplier::tags), + Codec.FLOAT.fieldOf("hunger").forGetter(Multiplier::hunger), + Codec.FLOAT.fieldOf("saturation").forGetter(Multiplier::saturation) + ).apply(instance, Multiplier::new)); + + public Multiplier(PacketByteBuf buffer) { + this(buffer.readCollection(HashSet::new, p -> TagKey.of(RegistryKeys.ITEM, p.readIdentifier())), buffer.readFloat(), buffer.readFloat()); + } + + @Override + public boolean test(ItemStack stack) { + return tags.stream().anyMatch(tag -> stack.isIn(tag)); + } + + public void toBuffer(PacketByteBuf buffer) { + buffer.writeCollection(tags, (p, t) -> p.writeIdentifier(t.id())); + buffer.writeFloat(hunger); + buffer.writeFloat(saturation); + } + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/diet/DietView.java b/src/main/java/com/minelittlepony/unicopia/diet/DietView.java new file mode 100644 index 00000000..4d872462 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/diet/DietView.java @@ -0,0 +1,27 @@ +package com.minelittlepony.unicopia.diet; + +import java.util.List; +import org.jetbrains.annotations.Nullable; + +import net.minecraft.client.item.TooltipContext; +import net.minecraft.entity.LivingEntity; +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.item.ItemStack; +import net.minecraft.text.Text; +import net.minecraft.util.Hand; +import net.minecraft.util.TypedActionResult; +import net.minecraft.world.World; + +public interface DietView { + TypedActionResult startUsing(ItemStack stack, World world, PlayerEntity user, Hand hand); + + void finishUsing(ItemStack stack, World world, LivingEntity entity); + + void appendTooltip(ItemStack stack, @Nullable PlayerEntity user, List tooltip, TooltipContext context); + + interface Holder { + default DietView getDiets(ItemStack stack) { + return PonyDiets.getInstance(); + } + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/diet/DietsLoader.java b/src/main/java/com/minelittlepony/unicopia/diet/DietsLoader.java new file mode 100644 index 00000000..963efb77 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/diet/DietsLoader.java @@ -0,0 +1,85 @@ +package com.minelittlepony.unicopia.diet; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Optional; +import java.util.concurrent.CompletableFuture; +import java.util.concurrent.Executor; + +import org.slf4j.Logger; + +import com.google.gson.JsonElement; +import com.minelittlepony.unicopia.Race; +import com.minelittlepony.unicopia.Unicopia; +import com.minelittlepony.unicopia.util.Resources; +import com.mojang.logging.LogUtils; +import com.mojang.serialization.JsonOps; + +import net.fabricmc.fabric.api.resource.IdentifiableResourceReloadListener; +import net.minecraft.resource.JsonDataLoader; +import net.minecraft.resource.ResourceManager; +import net.minecraft.util.Identifier; +import net.minecraft.util.profiler.Profiler; + +public class DietsLoader implements IdentifiableResourceReloadListener { + private static final Logger LOGGER = LogUtils.getLogger(); + private static final Identifier ID = Unicopia.id("diets"); + + @Override + public Identifier getFabricId() { + return ID; + } + + @Override + public CompletableFuture reload(Synchronizer sync, ResourceManager manager, + Profiler prepareProfiler, Profiler applyProfiler, + Executor prepareExecutor, Executor applyExecutor) { + + var dietsLoadTask = loadData(manager, prepareExecutor, "diets/races").thenApplyAsync(data -> { + Map profiles = new HashMap<>(); + for (var entry : data.entrySet()) { + Identifier id = entry.getKey(); + try { + Race.REGISTRY.getOrEmpty(id).ifPresentOrElse(race -> { + DietProfile.CODEC.parse(JsonOps.INSTANCE, entry.getValue()) + .resultOrPartial(error -> LOGGER.error("Could not load diet profile {}: {}", id, error)) + .ifPresent(profile -> profiles.put(race, profile)); + }, () -> LOGGER.warn("Skipped diet for unknown race: " + id)); + } catch (Throwable t) { + LOGGER.error("Could not load diet profile {}", id, t); + } + } + return profiles; + }, prepareExecutor); + + var effectsLoadTask = loadData(manager, prepareExecutor, "diets/food_effects").thenApplyAsync(data -> data.entrySet().stream() + .map(entry -> { + try { + return Effect.CODEC.parse(JsonOps.INSTANCE, entry.getValue()) + .resultOrPartial(error -> LOGGER.error("Could not load food effect {}: {}", entry.getKey(), error)); + } catch (Throwable t) { + LOGGER.error("Could not load food effects {}", entry.getKey(), t); + } + return Optional.empty(); + }) + .filter(Optional::isPresent) + .map(Optional::get) + .toList(), prepareExecutor); + + return CompletableFuture.allOf(dietsLoadTask, effectsLoadTask).thenCompose(sync::whenPrepared).thenRunAsync(() -> { + PonyDiets.load(new PonyDiets( + dietsLoadTask.getNow(Map.of()), + effectsLoadTask.getNow(List.of()) + )); + }, applyExecutor); + } + + private static CompletableFuture> loadData(ResourceManager manager, Executor prepareExecutor, String path) { + return CompletableFuture.supplyAsync(() -> { + Map results = new HashMap<>(); + JsonDataLoader.load(manager, path, Resources.GSON, results); + return results; + }); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/diet/Effect.java b/src/main/java/com/minelittlepony/unicopia/diet/Effect.java new file mode 100644 index 00000000..4d0f1bb4 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/diet/Effect.java @@ -0,0 +1,76 @@ +package com.minelittlepony.unicopia.diet; + +import java.util.List; +import java.util.Optional; +import java.util.function.Predicate; + +import com.minelittlepony.unicopia.entity.player.Pony; +import com.mojang.serialization.Codec; +import com.mojang.serialization.codecs.RecordCodecBuilder; + +import net.minecraft.client.item.TooltipContext; +import net.minecraft.item.FoodComponent; +import net.minecraft.item.Item; +import net.minecraft.item.ItemStack; +import net.minecraft.network.PacketByteBuf; +import net.minecraft.registry.RegistryKeys; +import net.minecraft.registry.tag.TagKey; +import net.minecraft.text.Text; +import net.minecraft.util.Formatting; +import net.minecraft.util.UseAction; +import net.minecraft.util.Util; + +public record Effect( + List> tags, + Optional foodComponent, + Ailment ailment +) implements Predicate { + public static final Effect EMPTY = new Effect(List.of(), Optional.empty(), Ailment.EMPTY); + public static final Codec CODEC = RecordCodecBuilder.create(instance -> instance.group( + TagKey.unprefixedCodec(RegistryKeys.ITEM).listOf().fieldOf("tags").forGetter(Effect::tags), + FoodAttributes.CODEC.optionalFieldOf("food_component").forGetter(Effect::foodComponent), + Ailment.CODEC.fieldOf("ailment").forGetter(Effect::ailment) + ).apply(instance, Effect::new)); + + public Effect(PacketByteBuf buffer) { + this(buffer.readList(b -> TagKey.of(RegistryKeys.ITEM, b.readIdentifier())), buffer.readOptional(FoodAttributes::read), new Ailment(buffer)); + } + + public void afflict(Pony pony, ItemStack stack) { + ailment().effects().afflict(pony.asEntity(), stack); + } + + public void appendTooltip(ItemStack stack, List tooltip, TooltipContext context) { + int size = tooltip.size(); + tags.forEach(tag -> { + if (stack.isIn(tag)) { + tooltip.add(Text.literal(" ").append(Text.translatable(Util.createTranslationKey("tag", tag.id()))).formatted(Formatting.GRAY)); + } + }); + if (tooltip.size() == size) { + if (stack.isFood()) { + tooltip.add(Text.literal(" ").append(Text.translatable("tag.unicopia.food_types.fruits_and_vegetables")).formatted(Formatting.GRAY)); + } else if (stack.getUseAction() == UseAction.DRINK) { + tooltip.add(Text.literal(" ").append(Text.translatable("tag.unicopia.food_types.drinks")).formatted(Formatting.GRAY)); + } + } + + if (context.isAdvanced() && stack.isFood()) { + if (!ailment().effects().isEmpty()) { + tooltip.add(Text.translatable("unicopia.diet.side_effects").formatted(Formatting.DARK_PURPLE)); + ailment().effects().appendTooltip(tooltip); + } + } + } + + public void toBuffer(PacketByteBuf buffer) { + buffer.writeCollection(tags, (b, t) -> b.writeIdentifier(t.id())); + buffer.writeOptional(foodComponent, FoodAttributes::write); + ailment.toBuffer(buffer); + } + + @Override + public boolean test(ItemStack stack) { + return tags.stream().anyMatch(stack::isIn); + } +} \ No newline at end of file diff --git a/src/main/java/com/minelittlepony/unicopia/diet/FoodAttributes.java b/src/main/java/com/minelittlepony/unicopia/diet/FoodAttributes.java new file mode 100644 index 00000000..d1682982 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/diet/FoodAttributes.java @@ -0,0 +1,60 @@ +package com.minelittlepony.unicopia.diet; + +import java.util.List; + +import com.mojang.datafixers.util.Pair; +import com.mojang.serialization.Codec; +import com.mojang.serialization.codecs.RecordCodecBuilder; + +import net.minecraft.entity.effect.StatusEffectInstance; +import net.minecraft.item.FoodComponent; +import net.minecraft.network.PacketByteBuf; + +final class FoodAttributes { + static final Codec CODEC = RecordCodecBuilder.create(instance -> instance.group( + Codec.INT.fieldOf("hunger").forGetter(FoodComponent::getHunger), + Codec.FLOAT.fieldOf("saturation").forGetter(FoodComponent::getSaturationModifier), + Codec.BOOL.optionalFieldOf("petFood", false).forGetter(FoodComponent::isMeat), + Codec.BOOL.optionalFieldOf("fastFood", false).forGetter(FoodComponent::isAlwaysEdible), + Codec.BOOL.optionalFieldOf("eatenQuickly", false).forGetter(FoodComponent::isSnack) + ).apply(instance, FoodAttributes::create)); + + static FoodComponent create(int hunger, float saturation, boolean petFood, boolean fastFood, boolean eatenQuickly) { + return create(hunger, saturation, petFood, fastFood, eatenQuickly, List.of()).build(); + } + + static FoodComponent.Builder create(int hunger, float saturation, boolean petFood, boolean fastFood, boolean eatenQuickly, List> effects) { + var builder = new FoodComponent.Builder() + .hunger(hunger) + .saturationModifier(saturation); + if (petFood) { + builder.meat(); + } + if (fastFood) { + builder.alwaysEdible(); + } + if (eatenQuickly) { + builder.snack(); + } + for (var effect : effects) { + builder.statusEffect(effect.getFirst(), effect.getSecond()); + } + return builder; + } + + static FoodComponent.Builder copy(FoodComponent food) { + return create(food.getHunger(), food.getSaturationModifier(), food.isMeat(), food.isAlwaysEdible(), food.isSnack(), food.getStatusEffects()); + } + + static FoodComponent read(PacketByteBuf buffer) { + return create(buffer.readInt(), buffer.readFloat(), buffer.readBoolean(), buffer.readBoolean(), buffer.readBoolean()); + } + + static void write(PacketByteBuf buffer, FoodComponent food) { + buffer.writeInt(food.getHunger()); + buffer.writeFloat(food.getSaturationModifier()); + buffer.writeBoolean(food.isMeat()); + buffer.writeBoolean(food.isAlwaysEdible()); + buffer.writeBoolean(food.isSnack()); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/diet/PonyDiets.java b/src/main/java/com/minelittlepony/unicopia/diet/PonyDiets.java new file mode 100644 index 00000000..a9b5459b --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/diet/PonyDiets.java @@ -0,0 +1,109 @@ +package com.minelittlepony.unicopia.diet; + +import java.util.List; +import java.util.Map; +import java.util.Optional; + +import org.jetbrains.annotations.Nullable; + +import com.minelittlepony.unicopia.Race; +import com.minelittlepony.unicopia.entity.effect.FoodPoisoningStatusEffect; +import com.minelittlepony.unicopia.entity.player.Pony; +import com.minelittlepony.unicopia.item.ItemDuck; +import net.minecraft.client.item.TooltipContext; +import net.minecraft.entity.LivingEntity; +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.item.ItemStack; +import net.minecraft.network.PacketByteBuf; +import net.minecraft.text.Text; +import net.minecraft.util.Formatting; +import net.minecraft.util.Hand; +import net.minecraft.util.TypedActionResult; +import net.minecraft.world.World; + +public class PonyDiets implements DietView { + private final Map diets; + private final List effects; + + private static PonyDiets INSTANCE = new PonyDiets(Map.of(), List.of()); + + public static PonyDiets getInstance() { + return INSTANCE; + } + + public static void load(PonyDiets diets) { + INSTANCE = diets; + } + + PonyDiets(Map diets, List effects) { + this.diets = diets; + this.effects = effects; + } + + public PonyDiets(PacketByteBuf buffer) { + this(buffer.readMap(b -> b.readRegistryValue(Race.REGISTRY), DietProfile::new), buffer.readList(Effect::new)); + } + + public void toBuffer(PacketByteBuf buffer) { + buffer.writeMap(diets, (b, r) -> b.writeRegistryValue(Race.REGISTRY, r), (b, e) -> e.toBuffer(b)); + buffer.writeCollection(effects, (b, e) -> e.toBuffer(b)); + } + + private DietProfile getDiet(Pony pony) { + return Optional.ofNullable(diets.get(pony.getObservedSpecies())).orElse(DietProfile.EMPTY); + } + + private Effect getEffects(ItemStack stack) { + return effects.stream().filter(effect -> effect.test(stack)).findFirst().orElse(Effect.EMPTY); + } + + private Effect getEffects(ItemStack stack, Pony pony) { + return getDiet(pony).findEffect(stack).orElseGet(() -> getEffects(stack)); + } + + @Override + public TypedActionResult startUsing(ItemStack stack, World world, PlayerEntity user, Hand hand) { + return initEdibility(stack, user) + ? FoodPoisoningStatusEffect.apply(stack, user) + : TypedActionResult.fail(stack); + } + + @Override + public void finishUsing(ItemStack stack, World world, LivingEntity entity) { + if (initEdibility(stack, entity)) { + Pony.of(entity).ifPresent(pony -> getEffects(stack, pony).afflict(pony, stack)); + } + } + + @Override + public void appendTooltip(ItemStack stack, @Nullable PlayerEntity user, List tooltip, TooltipContext context) { + if (initEdibility(stack, user)) { + Pony pony = Pony.of(user); + + tooltip.add(Text.translatable("unicopia.diet.information").formatted(Formatting.DARK_PURPLE)); + getEffects(stack, pony).appendTooltip(stack, tooltip, context); + getDiet(pony).appendTooltip(stack, user, tooltip, context); + } + } + + private boolean initEdibility(ItemStack stack, LivingEntity user) { + ItemDuck item = (ItemDuck)stack.getItem(); + item.resetFoodComponent(); + return Pony.of(user).filter(pony -> { + DietProfile diet = getDiet(pony); + + if (!stack.isFood() && pony.getObservedSpecies().hasIronGut()) { + diet.findEffect(stack) + .flatMap(Effect::foodComponent) + .or(() -> getEffects(stack).foodComponent()) + .ifPresent(item::setFoodComponent); + } + + if (stack.isFood()) { + item.setFoodComponent(diet.getAdjustedFoodComponent(stack)); + } + + return true; + }).isPresent(); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/diet/affliction/Affliction.java b/src/main/java/com/minelittlepony/unicopia/diet/affliction/Affliction.java new file mode 100644 index 00000000..013d3f51 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/diet/affliction/Affliction.java @@ -0,0 +1,69 @@ +package com.minelittlepony.unicopia.diet.affliction; + +import java.util.List; + +import com.mojang.datafixers.util.Either; +import com.mojang.serialization.Codec; + +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.item.ItemStack; +import net.minecraft.network.PacketByteBuf; +import net.minecraft.text.Text; +import net.minecraft.util.Formatting; +import net.minecraft.util.dynamic.Codecs; + +public interface Affliction { + Affliction EMPTY = new Affliction() { + @Override + public void afflict(PlayerEntity player, ItemStack stack) { } + + @Override + public AfflictionType getType() { + return AfflictionType.EMPTY; + } + + @Override + public void toBuffer(PacketByteBuf buffer) { } + }; + Codec CODEC = Codecs.xor(AfflictionType.CODEC, Codec.list(AfflictionType.CODEC).xmap( + afflictions -> { + afflictions = afflictions.stream().filter(f -> !f.isEmpty()).toList(); + return switch (afflictions.size()) { + case 0 -> EMPTY; + case 1 -> afflictions.get(0); + default -> new CompoundAffliction(afflictions); + }; + }, + affliction -> ((CompoundAffliction)affliction).afflictions + )).xmap( + either -> either.left().or(either::right).get(), + affliction -> affliction instanceof CompoundAffliction ? Either.left(affliction) : Either.right(affliction) + ); + + void afflict(PlayerEntity player, ItemStack stack); + + default boolean isEmpty() { + return getType() == AfflictionType.EMPTY; + } + + default void appendTooltip(List tooltip) { + tooltip.add(Text.literal(" ").append(getName()).formatted(Formatting.DARK_GRAY)); + } + + default Text getName() { + return Text.translatable(getType().getTranslationKey()); + } + + AfflictionType getType(); + + void toBuffer(PacketByteBuf buffer); + + static void write(PacketByteBuf buffer, Affliction affliction) { + buffer.writeIdentifier(affliction.getType().id()); + affliction.toBuffer(buffer); + } + + static Affliction read(PacketByteBuf buffer) { + return AfflictionType.REGISTRY.get(buffer.readIdentifier()).reader().apply(buffer); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/diet/affliction/AfflictionType.java b/src/main/java/com/minelittlepony/unicopia/diet/affliction/AfflictionType.java new file mode 100644 index 00000000..6d9f405f --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/diet/affliction/AfflictionType.java @@ -0,0 +1,52 @@ +package com.minelittlepony.unicopia.diet.affliction; + +import com.minelittlepony.unicopia.Unicopia; +import com.minelittlepony.unicopia.util.RegistryUtils; +import com.mojang.serialization.Codec; +import com.mojang.serialization.DataResult; +import com.mojang.serialization.JsonOps; + +import net.minecraft.network.PacketByteBuf.PacketReader; +import net.minecraft.registry.Registry; +import net.minecraft.util.Identifier; +import net.minecraft.util.JsonHelper; +import net.minecraft.util.Util; +import net.minecraft.util.dynamic.Codecs; + +public record AfflictionType(Codec codec, Identifier id, PacketReader reader) { + public static final String DEFAULT_ID = "unicopia:apply_status_effect"; + public static final Registry> REGISTRY = RegistryUtils.createDefaulted(Unicopia.id("affliction_type"), DEFAULT_ID); + @SuppressWarnings("unchecked") + public static final Codec CODEC = Codecs.JSON_ELEMENT.flatXmap(json -> { + if (!json.isJsonObject()) { + return DataResult.error(() -> "Not a JSON object"); + } + return Identifier.validate(JsonHelper.getString(JsonHelper.asObject(json, "affliction"), "type", AfflictionType.DEFAULT_ID)) + .flatMap(type -> AfflictionType.REGISTRY.get(type).codec().parse(JsonOps.INSTANCE, json)); + }, thing -> { + AfflictionType type = thing.getType(); + return ((Codec)type.codec()).encodeStart(JsonOps.INSTANCE, thing).map(json -> { + if (json.isJsonObject()) { + json.getAsJsonObject().addProperty("type", type.id().toString()); + } + return json; + }); + }); + + public static final AfflictionType EMPTY = register("empty", Codec.unit(Affliction.EMPTY), buffer -> Affliction.EMPTY); + public static final AfflictionType MANY = register("many", CompoundAffliction.CODEC, CompoundAffliction::new); + public static final AfflictionType APPLY_STATUS_EFFECT = register("apply_status_effect", StatusEffectAffliction.CODEC, StatusEffectAffliction::new); + public static final AfflictionType LOSE_HUNGER = register("lose_hunger", LoseHungerAffliction.CODEC, LoseHungerAffliction::new); + public static final AfflictionType HEALING = register("healing", HealingAffliction.CODEC, HealingAffliction::new); + public static final AfflictionType CURE_LOVE_SICKNESS = register("cure_love_sickness", ClearLoveSicknessAffliction.CODEC, buffer -> ClearLoveSicknessAffliction.INSTANCE); + + static AfflictionType register(String name, Codec codec, PacketReader reader) { + return Registry.register(REGISTRY, Unicopia.id(name), new AfflictionType<>(codec, Unicopia.id(name), reader)); + } + + public String getTranslationKey() { + return Util.createTranslationKey("affliction", id()); + } + + public static void bootstrap() { } +} diff --git a/src/main/java/com/minelittlepony/unicopia/diet/affliction/ClearLoveSicknessAffliction.java b/src/main/java/com/minelittlepony/unicopia/diet/affliction/ClearLoveSicknessAffliction.java new file mode 100644 index 00000000..79343432 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/diet/affliction/ClearLoveSicknessAffliction.java @@ -0,0 +1,29 @@ +package com.minelittlepony.unicopia.diet.affliction; + +import com.minelittlepony.unicopia.entity.effect.UEffects; +import com.mojang.serialization.Codec; +import net.minecraft.entity.effect.StatusEffects; +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.item.ItemStack; +import net.minecraft.network.PacketByteBuf; + +final class ClearLoveSicknessAffliction implements Affliction { + public static final ClearLoveSicknessAffliction INSTANCE = new ClearLoveSicknessAffliction(); + public static final Codec CODEC = Codec.unit(INSTANCE); + + @Override + public AfflictionType getType() { + return AfflictionType.CURE_LOVE_SICKNESS; + } + + @Override + public void afflict(PlayerEntity player, ItemStack stack) { + player.heal(stack.isFood() ? stack.getItem().getFoodComponent().getHunger() : 1); + player.removeStatusEffect(StatusEffects.NAUSEA); + player.removeStatusEffect(UEffects.FOOD_POISONING); + } + + @Override + public void toBuffer(PacketByteBuf buffer) { + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/diet/affliction/CompoundAffliction.java b/src/main/java/com/minelittlepony/unicopia/diet/affliction/CompoundAffliction.java new file mode 100644 index 00000000..d41cf4ad --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/diet/affliction/CompoundAffliction.java @@ -0,0 +1,55 @@ +package com.minelittlepony.unicopia.diet.affliction; + +import java.util.List; + +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.item.ItemStack; +import net.minecraft.network.PacketByteBuf; +import net.minecraft.text.Text; + +class CompoundAffliction implements Affliction { + public final List afflictions; + private final Text name; + + public CompoundAffliction(List afflictions) { + this.afflictions = afflictions; + name = afflictions.stream().map(Affliction::getName).reduce(null, (a, b) -> { + return a == null ? b : a.copy().append(" + ").append(b); + }); + } + + public CompoundAffliction(PacketByteBuf buffer) { + this(buffer.readList(Affliction::read)); + } + + @Override + public void toBuffer(PacketByteBuf buffer) { + buffer.writeCollection(afflictions, Affliction::write); + } + + @Override + public AfflictionType getType() { + return AfflictionType.MANY; + } + + @Override + public boolean isEmpty() { + return afflictions.isEmpty(); + } + + @Override + public void appendTooltip(List tooltip) { + afflictions.forEach(i -> i.appendTooltip(tooltip)); + } + + @Override + public Text getName() { + return name; + } + + + @Override + public void afflict(PlayerEntity player, ItemStack stack) { + afflictions.forEach(i -> i.afflict(player, stack)); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/diet/affliction/HealingAffliction.java b/src/main/java/com/minelittlepony/unicopia/diet/affliction/HealingAffliction.java new file mode 100644 index 00000000..71590879 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/diet/affliction/HealingAffliction.java @@ -0,0 +1,39 @@ +package com.minelittlepony.unicopia.diet.affliction; + +import com.mojang.serialization.Codec; +import com.mojang.serialization.codecs.RecordCodecBuilder; + +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.item.ItemStack; +import net.minecraft.network.PacketByteBuf; +import net.minecraft.text.Text; + +record HealingAffliction(float health) implements Affliction { + public static final Codec CODEC = RecordCodecBuilder.create(instance -> instance.group( + Codec.FLOAT.fieldOf("health").forGetter(HealingAffliction::health) + ).apply(instance, HealingAffliction::new)); + + public HealingAffliction(PacketByteBuf buffer) { + this(buffer.readFloat()); + } + + @Override + public void toBuffer(PacketByteBuf buffer) { + buffer.writeFloat(health); + } + + @Override + public AfflictionType getType() { + return AfflictionType.HEALING; + } + + @Override + public void afflict(PlayerEntity player, ItemStack stack) { + player.heal(health()); + } + + @Override + public Text getName() { + return Text.translatable(getType().getTranslationKey(), health()); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/diet/affliction/LoseHungerAffliction.java b/src/main/java/com/minelittlepony/unicopia/diet/affliction/LoseHungerAffliction.java new file mode 100644 index 00000000..fe9ff84f --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/diet/affliction/LoseHungerAffliction.java @@ -0,0 +1,41 @@ +package com.minelittlepony.unicopia.diet.affliction; + +import com.mojang.serialization.Codec; +import com.mojang.serialization.codecs.RecordCodecBuilder; + +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.item.ItemStack; +import net.minecraft.network.PacketByteBuf; +import net.minecraft.text.Text; + +public record LoseHungerAffliction(float multiplier) implements Affliction { + public static final Codec CODEC = RecordCodecBuilder.create(instance -> instance.group( + Codec.FLOAT.fieldOf("multiplier").forGetter(LoseHungerAffliction::multiplier) + ).apply(instance, LoseHungerAffliction::new)); + + public LoseHungerAffliction(PacketByteBuf buffer) { + this(buffer.readFloat()); + } + + @Override + public void toBuffer(PacketByteBuf buffer) { + buffer.writeFloat(multiplier); + } + + @Override + public AfflictionType getType() { + return AfflictionType.LOSE_HUNGER; + } + + @Override + public void afflict(PlayerEntity player, ItemStack stack) { + var hunger = player.getHungerManager(); + hunger.setFoodLevel((int)(hunger.getFoodLevel() * multiplier)); + hunger.setSaturationLevel(hunger.getSaturationLevel() * multiplier); + } + + @Override + public Text getName() { + return Text.translatable(getType().getTranslationKey(), multiplier * 100); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/diet/affliction/Range.java b/src/main/java/com/minelittlepony/unicopia/diet/affliction/Range.java new file mode 100644 index 00000000..ed84ad97 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/diet/affliction/Range.java @@ -0,0 +1,39 @@ +package com.minelittlepony.unicopia.diet.affliction; + +import com.mojang.datafixers.util.Either; +import com.mojang.serialization.Codec; +import com.mojang.serialization.codecs.RecordCodecBuilder; + +import net.minecraft.network.PacketByteBuf; +import net.minecraft.util.dynamic.Codecs; + +record Range(int min, int max) { + public static final Codec CODEC = Codecs.xor( + Codec.INT.xmap(value -> Range.of(value, -1), range -> range.min()), + RecordCodecBuilder.create(instance -> instance.group( + Codec.INT.fieldOf("min").forGetter(Range::min), + Codec.INT.fieldOf("max").forGetter(Range::max) + ).apply(instance, Range::of)) + ).xmap(either -> either.left().or(either::right).get(), l -> Either.right(l)); + + public static Range of(int min, int max) { + return new Range(min, max); + } + + public static Range of(PacketByteBuf buffer) { + return of(buffer.readInt(), buffer.readInt()); + } + + public void toBuffer(PacketByteBuf buffer) { + buffer.writeInt(min); + buffer.writeInt(max); + } + + public int getClamped(int currentTicks, int multiplier) { + return clamp((min * multiplier) + currentTicks, multiplier); + } + + public int clamp(int value, int multiplier) { + return max > 0 ? Math.min(value, max * multiplier) : value; + } +} \ No newline at end of file diff --git a/src/main/java/com/minelittlepony/unicopia/diet/affliction/StatusEffectAffliction.java b/src/main/java/com/minelittlepony/unicopia/diet/affliction/StatusEffectAffliction.java new file mode 100644 index 00000000..d0c0b91c --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/diet/affliction/StatusEffectAffliction.java @@ -0,0 +1,79 @@ +package com.minelittlepony.unicopia.diet.affliction; + +import com.mojang.serialization.Codec; +import com.mojang.serialization.codecs.RecordCodecBuilder; + +import net.minecraft.entity.attribute.EntityAttributes; +import net.minecraft.entity.effect.StatusEffectInstance; +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.item.ItemStack; +import net.minecraft.network.PacketByteBuf; +import net.minecraft.registry.Registries; +import net.minecraft.text.MutableText; +import net.minecraft.text.Text; +import net.minecraft.util.Identifier; +import net.minecraft.util.StringHelper; +import net.minecraft.util.math.MathHelper; + +record StatusEffectAffliction(Identifier effect, Range seconds, Range amplifier, int chance) implements Affliction { + public static final Codec CODEC = RecordCodecBuilder.create(instance -> instance.group( + Identifier.CODEC.fieldOf("effect").forGetter(StatusEffectAffliction::effect), + Range.CODEC.fieldOf("seconds").forGetter(StatusEffectAffliction::seconds), + Range.CODEC.optionalFieldOf("amplifier", Range.of(0, -1)).forGetter(StatusEffectAffliction::amplifier), + Codec.INT.optionalFieldOf("chance", 0).forGetter(StatusEffectAffliction::chance) + ).apply(instance, StatusEffectAffliction::new)); + + public StatusEffectAffliction(PacketByteBuf buffer) { + this(buffer.readIdentifier(), Range.of(buffer), Range.of(buffer), buffer.readInt()); + } + + @Override + public void toBuffer(PacketByteBuf buffer) { + buffer.writeIdentifier(effect); + seconds.toBuffer(buffer); + amplifier.toBuffer(buffer); + buffer.writeInt(chance); + } + + @Override + public AfflictionType getType() { + return AfflictionType.APPLY_STATUS_EFFECT; + } + + @Override + public void afflict(PlayerEntity player, ItemStack stack) { + if (chance > 0 && player.getWorld().random.nextInt(chance) > 0) { + return; + } + Registries.STATUS_EFFECT.getOrEmpty(effect).ifPresent(effect -> { + float health = player.getHealth(); + StatusEffectInstance current = player.getStatusEffect(effect); + player.addStatusEffect(new StatusEffectInstance(effect, + seconds.getClamped(current == null ? 0 : current.getDuration(), 20), + amplifier.getClamped(current == null ? 0 : current.getAmplifier(), 1) + )); + // keep original health + if (effect.getAttributeModifiers().containsKey(EntityAttributes.GENERIC_MAX_HEALTH)) { + player.setHealth(MathHelper.clamp(health, 0, player.getMaxHealth())); + } + }); + } + + @Override + public Text getName() { + return Registries.STATUS_EFFECT.getOrEmpty(effect).map(effect -> { + MutableText text = effect.getName().copy(); + + if (amplifier.min() > 0) { + text = Text.translatable("potion.withAmplifier", text, Text.translatable("potion.potency." + (amplifier.min()))); + } + + text = Text.translatable("potion.withDuration", text, StringHelper.formatTicks(seconds.min() * 20)); + + if (chance > 0) { + text = Text.translatable("potion.withChance", chance, text); + } + return (Text)text; + }).orElse(EMPTY.getName()); + } +} \ No newline at end of file diff --git a/src/main/java/com/minelittlepony/unicopia/entity/AmuletSelectors.java b/src/main/java/com/minelittlepony/unicopia/entity/AmuletSelectors.java index 96fc930b..81211527 100644 --- a/src/main/java/com/minelittlepony/unicopia/entity/AmuletSelectors.java +++ b/src/main/java/com/minelittlepony/unicopia/entity/AmuletSelectors.java @@ -10,6 +10,7 @@ public interface AmuletSelectors { Predicate ALICORN_AMULET = UItems.ALICORN_AMULET::isApplicable; Predicate PEGASUS_AMULET = UItems.PEGASUS_AMULET::isApplicable; Predicate UNICORN_AMULET = UItems.UNICORN_AMULET::isApplicable; + Predicate PEARL_NECKLACE = UItems.PEARL_NECKLACE::isApplicable; Predicate ALICORN_AMULET_AFTER_1_DAYS = ALICORN_AMULET.and(ItemTracker.wearing(UItems.ALICORN_AMULET, ItemTracker.after(ItemTracker.DAYS))); Predicate ALICORN_AMULET_AFTER_2_DAYS = ALICORN_AMULET.and(ItemTracker.wearing(UItems.ALICORN_AMULET, ItemTracker.after(2 * ItemTracker.DAYS))); diff --git a/src/main/java/com/minelittlepony/unicopia/entity/behaviour/Disguise.java b/src/main/java/com/minelittlepony/unicopia/entity/behaviour/Disguise.java index 56ecd0eb..272cde97 100644 --- a/src/main/java/com/minelittlepony/unicopia/entity/behaviour/Disguise.java +++ b/src/main/java/com/minelittlepony/unicopia/entity/behaviour/Disguise.java @@ -46,6 +46,10 @@ public interface Disguise extends FlightType.Provider, PlayerDimensions.Provider return getAppearance().flatMap(d -> d.getTargetDimensions(player)); } + default boolean isOf(@Nullable Entity entity) { + return getDisguise().isOf(entity); + } + default Disguise setDisguise(@Nullable Entity entity) { if (entity == getDisguise().getAppearance()) { entity = null; diff --git a/src/main/java/com/minelittlepony/unicopia/entity/behaviour/EntityAppearance.java b/src/main/java/com/minelittlepony/unicopia/entity/behaviour/EntityAppearance.java index a6f2906a..b6cb7492 100644 --- a/src/main/java/com/minelittlepony/unicopia/entity/behaviour/EntityAppearance.java +++ b/src/main/java/com/minelittlepony/unicopia/entity/behaviour/EntityAppearance.java @@ -109,6 +109,10 @@ public class EntityAppearance implements NbtSerialisable, PlayerDimensions.Provi return entity != null; } + public boolean isOf(@Nullable Entity entity) { + return isPresent() && entity != null && EntityBehaviour.forEntity(this.entity).isEqual(this.entity, entity); + } + public NbtCompound getOrCreateTag() { if (tag == null) { tag = new NbtCompound(); @@ -127,7 +131,9 @@ public class EntityAppearance implements NbtSerialisable, PlayerDimensions.Provi entity = null; } if (blockEntity != null) { - blockEntity.markRemoved(); + try { + blockEntity.markRemoved(); + } catch (Throwable ignored) {} blockEntity = null; } } diff --git a/src/main/java/com/minelittlepony/unicopia/entity/behaviour/EntityBehaviour.java b/src/main/java/com/minelittlepony/unicopia/entity/behaviour/EntityBehaviour.java index 189ee33d..b37e06df 100644 --- a/src/main/java/com/minelittlepony/unicopia/entity/behaviour/EntityBehaviour.java +++ b/src/main/java/com/minelittlepony/unicopia/entity/behaviour/EntityBehaviour.java @@ -74,6 +74,10 @@ public class EntityBehaviour { entity.remove(RemovalReason.KILLED); } + public boolean isEqual(T a, Entity b) { + return a.getType() == b.getType(); + } + public Optional getCameraDistance(Entity entity, Pony player) { if (entity == null) { return Optional.empty(); diff --git a/src/main/java/com/minelittlepony/unicopia/entity/behaviour/FallingBlockBehaviour.java b/src/main/java/com/minelittlepony/unicopia/entity/behaviour/FallingBlockBehaviour.java index bc3fafd2..b9d440a4 100644 --- a/src/main/java/com/minelittlepony/unicopia/entity/behaviour/FallingBlockBehaviour.java +++ b/src/main/java/com/minelittlepony/unicopia/entity/behaviour/FallingBlockBehaviour.java @@ -53,6 +53,11 @@ public class FallingBlockBehaviour extends EntityBehaviour { } } + @Override + public boolean isEqual(FallingBlockEntity a, Entity b) { + return b instanceof FallingBlockEntity f && f.getBlockState() == a.getBlockState(); + } + private FallingBlockEntity configure(FallingBlockEntity entity, Block block) { if (block instanceof MixinFallingBlock) { ((MixinFallingBlock)block).invokeConfigureFallingBlockEntity(entity); diff --git a/src/main/java/com/minelittlepony/unicopia/entity/behaviour/PlayerBehaviour.java b/src/main/java/com/minelittlepony/unicopia/entity/behaviour/PlayerBehaviour.java index 612153bc..489248e6 100644 --- a/src/main/java/com/minelittlepony/unicopia/entity/behaviour/PlayerBehaviour.java +++ b/src/main/java/com/minelittlepony/unicopia/entity/behaviour/PlayerBehaviour.java @@ -4,6 +4,7 @@ import com.minelittlepony.unicopia.entity.Living; import com.minelittlepony.unicopia.entity.duck.*; import com.minelittlepony.unicopia.entity.player.Pony; +import net.minecraft.entity.Entity; import net.minecraft.entity.player.PlayerEntity; public class PlayerBehaviour extends EntityBehaviour { @@ -29,8 +30,12 @@ public class PlayerBehaviour extends EntityBehaviour { entity.setSwimming(source.asEntity().isSwimming()); } if (source.asEntity() instanceof LivingEntityDuck duck) { - // TODO: CopyAngles duck.copyLeaningAnglesFrom(((LivingEntityDuck)entity)); } } + + @Override + public boolean isEqual(PlayerEntity a, Entity b) { + return b instanceof PlayerEntity p && p.getUuid().equals(b.getUuid()); + } } diff --git a/src/main/java/com/minelittlepony/unicopia/entity/duck/EntityDuck.java b/src/main/java/com/minelittlepony/unicopia/entity/duck/EntityDuck.java index 0a61652d..659a3a24 100644 --- a/src/main/java/com/minelittlepony/unicopia/entity/duck/EntityDuck.java +++ b/src/main/java/com/minelittlepony/unicopia/entity/duck/EntityDuck.java @@ -1,12 +1,18 @@ package com.minelittlepony.unicopia.entity.duck; +import java.util.Set; + import com.minelittlepony.unicopia.compat.pehkui.PehkuiEntityExtensions; import net.minecraft.entity.Entity; import net.minecraft.entity.Entity.RemovalReason; +import net.minecraft.fluid.Fluid; +import net.minecraft.registry.tag.TagKey; public interface EntityDuck extends LavaAffine, PehkuiEntityExtensions { + Set> getSubmergedFluidTags(); + void setRemovalReason(RemovalReason reason); void setVehicle(Entity vehicle); diff --git a/src/main/java/com/minelittlepony/unicopia/entity/effect/FoodPoisoningStatusEffect.java b/src/main/java/com/minelittlepony/unicopia/entity/effect/FoodPoisoningStatusEffect.java index e8bd62a7..f216cc67 100644 --- a/src/main/java/com/minelittlepony/unicopia/entity/effect/FoodPoisoningStatusEffect.java +++ b/src/main/java/com/minelittlepony/unicopia/entity/effect/FoodPoisoningStatusEffect.java @@ -12,10 +12,8 @@ import net.minecraft.entity.effect.StatusEffectCategory; import net.minecraft.entity.effect.StatusEffects; import net.minecraft.entity.player.PlayerEntity; import net.minecraft.item.FoodComponent; -import net.minecraft.item.ItemConvertible; import net.minecraft.item.ItemStack; import net.minecraft.sound.SoundCategory; -import net.minecraft.util.Hand; import net.minecraft.util.TypedActionResult; public class FoodPoisoningStatusEffect extends StatusEffect { @@ -54,18 +52,18 @@ public class FoodPoisoningStatusEffect extends StatusEffect { return i <= 0 || duration % i == 0; } - public static TypedActionResult apply(ItemConvertible sender, PlayerEntity user, Hand hand) { + public static TypedActionResult apply(ItemStack stack, PlayerEntity user) { @Nullable - FoodComponent food = sender.asItem().getFoodComponent(); + FoodComponent food = stack.getItem().getFoodComponent(); if (food == null || !user.canConsume(food.isAlwaysEdible()) || !user.hasStatusEffect(UEffects.FOOD_POISONING)) { - return TypedActionResult.pass(user.getStackInHand(hand)); + return TypedActionResult.pass(stack); } user.getWorld().playSound(null, user.getX(), user.getY(), user.getZ(), USounds.Vanilla.ENTITY_PLAYER_BURP, SoundCategory.NEUTRAL, 1, 1 + (user.getWorld().random.nextFloat() - user.getWorld().random.nextFloat()) * 0.4f); user.addStatusEffect(new StatusEffectInstance(StatusEffects.NAUSEA, 100, 1, true, false, false)); - return TypedActionResult.fail(user.getStackInHand(hand)); + return TypedActionResult.fail(stack); } } diff --git a/src/main/java/com/minelittlepony/unicopia/entity/effect/RaceChangeStatusEffect.java b/src/main/java/com/minelittlepony/unicopia/entity/effect/RaceChangeStatusEffect.java index cc937f94..462936ad 100644 --- a/src/main/java/com/minelittlepony/unicopia/entity/effect/RaceChangeStatusEffect.java +++ b/src/main/java/com/minelittlepony/unicopia/entity/effect/RaceChangeStatusEffect.java @@ -3,19 +3,24 @@ package com.minelittlepony.unicopia.entity.effect; import org.jetbrains.annotations.Nullable; import com.minelittlepony.unicopia.Race; +import com.minelittlepony.unicopia.USounds; import com.minelittlepony.unicopia.ability.magic.Caster; import com.minelittlepony.unicopia.entity.Equine; import com.minelittlepony.unicopia.entity.Living; import com.minelittlepony.unicopia.entity.damage.UDamageTypes; import com.minelittlepony.unicopia.entity.player.MagicReserves; import com.minelittlepony.unicopia.entity.player.Pony; +import com.minelittlepony.unicopia.util.ExplosionUtil; + import net.minecraft.entity.Entity; import net.minecraft.entity.LivingEntity; import net.minecraft.entity.effect.*; +import net.minecraft.entity.player.HungerManager; import net.minecraft.entity.player.PlayerEntity; import net.minecraft.particle.ParticleTypes; import net.minecraft.text.Text; import net.minecraft.util.Identifier; +import net.minecraft.world.World.ExplosionSourceType; import net.minecraft.registry.Registry; import net.minecraft.registry.Registries; @@ -29,6 +34,7 @@ public class RaceChangeStatusEffect extends StatusEffect { public static final StatusEffect CHANGE_RACE_BAT = register(0x0FFF00, Race.BAT); public static final StatusEffect CHANGE_RACE_CHANGELING = register(0xFFFF00, Race.CHANGELING); public static final StatusEffect CHANGE_RACE_KIRIN = register(0xFF8800, Race.KIRIN); + public static final StatusEffect CHANGE_RACE_HIPPOGRIFF = register(0x00FFFF, Race.HIPPOGRIFF); private final Race race; @@ -49,11 +55,21 @@ public class RaceChangeStatusEffect extends StatusEffect { return race; } + private void removeEffect(LivingEntity entity) { + entity.removeStatusEffect(this); + resetTicks(entity); + } + + private void resetTicks(LivingEntity entity) { + Pony.of(entity).ifPresent(pony -> pony.setTicksmetamorphising(0)); + } + @Override public void applyUpdateEffect(LivingEntity entity, int amplifier) { StatusEffectInstance state = entity.getStatusEffect(this); - if (state == null) { + if (state == null || entity.isDead()) { + resetTicks(entity); return; } @@ -63,6 +79,13 @@ public class RaceChangeStatusEffect extends StatusEffect { return; } + int metaTicks = 0; + + if (eq instanceof Pony pony) { + metaTicks = pony.getTicksMetamorphising() + 1; + pony.setTicksmetamorphising(metaTicks); + } + int ticks = Math.max(0, MAX_DURATION - state.getDuration()); Stage stage = Stage.forDuration(ticks / STAGE_DURATION); @@ -77,7 +100,7 @@ public class RaceChangeStatusEffect extends StatusEffect { if (progression == 0 && entity instanceof PlayerEntity player && stage == Stage.CRAWLING) { player.sendMessage(Stage.INITIAL.getMessage(race), true); } - entity.removeStatusEffect(this); + removeEffect(entity); return; } @@ -85,42 +108,60 @@ public class RaceChangeStatusEffect extends StatusEffect { player.sendMessage(stage.getMessage(race), true); } - entity.setHealth(1); - if (eq instanceof Pony pony) { MagicReserves magic = pony.getMagicalReserves(); pony.setRespawnRace(race); - magic.getExertion().addPercent(5); - magic.getEnergy().add(3); + magic.getExertion().add(5); + if (magic.getEnergy().get() < 1) { + magic.getEnergy().add(1.1F); + entity.playSound(USounds.BLOCK_CHITIN_AMBIENCE, 0.1F, 2F); + } magic.getExhaustion().add(3); if (state.shouldShowParticles()) { - pony.spawnParticles(ParticleTypes.TOTEM_OF_UNDYING, 5); + pony.spawnParticles(ParticleTypes.TOTEM_OF_UNDYING, 1); } } if (stage == Stage.DEATH) { - entity.removeStatusEffect(this); + removeEffect(entity); if (eq instanceof Caster) { ((Caster)eq).getSpellSlot().clear(); } - if (eq instanceof Pony pony) { + if (eq instanceof Pony pony && metaTicks > 200) { MagicReserves magic = pony.getMagicalReserves(); magic.getEnergy().set(0.6F); magic.getExhaustion().set(0); magic.getExertion().set(0); - if (!pony.asEntity().isCreative()) { + if (pony.asEntity().isCreative() || entity.getWorld().getDifficulty().getId() < 2 || entity.getWorld().getLevelProperties().isHardcore()) { + + if (!pony.asEntity().isCreative()) { + float cost = entity.getWorld().getLevelProperties().isHardcore() ? 0.75F : switch (entity.getWorld().getDifficulty()) { + case PEACEFUL -> 0.125F; + case EASY -> 0.25F; + default -> 0.5F; + }; + + entity.setHealth(Math.max(1, entity.getHealth() * cost)); + HungerManager hunger = pony.asEntity().getHungerManager(); + int food = hunger.getFoodLevel(); + pony.asEntity().getHungerManager().setFoodLevel(Math.max(Math.min(1, food), (int)(food * cost))); + } + pony.setSpecies(race); + } else if (!pony.asEntity().isCreative()) { if (!entity.damage(Living.living(entity).damageOf(UDamageTypes.TRIBE_SWAP), Float.MAX_VALUE)) { entity.setHealth(0); pony.setRespawnRace(Race.UNSET); pony.setSpecies(race); } } + entity.getWorld().createExplosion(entity, null, ExplosionUtil.NON_DESTRUCTIVE, entity.getPos(), 5, true, ExplosionSourceType.MOB); } else { eq.setSpecies(race); + entity.getWorld().createExplosion(entity, null, ExplosionUtil.NON_DESTRUCTIVE, entity.getPos(), 5, true, ExplosionSourceType.MOB); } } } diff --git a/src/main/java/com/minelittlepony/unicopia/entity/effect/UPotions.java b/src/main/java/com/minelittlepony/unicopia/entity/effect/UPotions.java index 2ff93a59..82f5a0b3 100644 --- a/src/main/java/com/minelittlepony/unicopia/entity/effect/UPotions.java +++ b/src/main/java/com/minelittlepony/unicopia/entity/effect/UPotions.java @@ -18,6 +18,8 @@ public interface UPotions { Potion TRIBE_SWAP_PEGASUS = register("tribe_swap_pegasus", new Potion("unicopia.tribe_swap_pegasus", new StatusEffectInstance(RaceChangeStatusEffect.CHANGE_RACE_PEGASUS, RaceChangeStatusEffect.MAX_DURATION))); Potion TRIBE_SWAP_BAT = register("tribe_swap_bat", new Potion("unicopia.tribe_swap_bat", new StatusEffectInstance(RaceChangeStatusEffect.CHANGE_RACE_BAT, RaceChangeStatusEffect.MAX_DURATION))); Potion TRIBE_SWAP_CHANGELING = register("tribe_swap_changeling", new Potion("unicopia.tribe_swap_changeling", new StatusEffectInstance(RaceChangeStatusEffect.CHANGE_RACE_CHANGELING, RaceChangeStatusEffect.MAX_DURATION))); + Potion TRIBE_SWAP_KIRIN = register("tribe_swap_kirin", new Potion("unicopia.tribe_swap_kirin", new StatusEffectInstance(RaceChangeStatusEffect.CHANGE_RACE_KIRIN, RaceChangeStatusEffect.MAX_DURATION))); + Potion TRIBE_SWAP_HIPPOGRIFF = register("tribe_swap_hippogriff", new Potion("unicopia.tribe_swap_hippogriff", new StatusEffectInstance(RaceChangeStatusEffect.CHANGE_RACE_HIPPOGRIFF, RaceChangeStatusEffect.MAX_DURATION))); static Potion register(String name, Potion potion) { REGISTRY.add(potion); diff --git a/src/main/java/com/minelittlepony/unicopia/entity/mob/LootBugEntity.java b/src/main/java/com/minelittlepony/unicopia/entity/mob/LootBugEntity.java new file mode 100644 index 00000000..1c475e3d --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/entity/mob/LootBugEntity.java @@ -0,0 +1,22 @@ +package com.minelittlepony.unicopia.entity.mob; + +import net.minecraft.entity.EntityType; +import net.minecraft.entity.mob.SilverfishEntity; +import net.minecraft.particle.ParticleTypes; +import net.minecraft.world.World; + +public class LootBugEntity extends SilverfishEntity { + public LootBugEntity(EntityType entityType, World world) { + super(entityType, world); + } + + @Override + public void tick() { + super.tick(); + + getWorld().addParticle(ParticleTypes.ELECTRIC_SPARK, + getParticleX(1), this.getEyeY(), getParticleZ(1), + random.nextFloat() - 0.5F, random.nextFloat(), random.nextFloat() - 0.5F + ); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/entity/mob/StormCloudEntity.java b/src/main/java/com/minelittlepony/unicopia/entity/mob/StormCloudEntity.java index 828b2593..d7f1054f 100644 --- a/src/main/java/com/minelittlepony/unicopia/entity/mob/StormCloudEntity.java +++ b/src/main/java/com/minelittlepony/unicopia/entity/mob/StormCloudEntity.java @@ -6,29 +6,42 @@ import java.util.function.Consumer; import org.jetbrains.annotations.Nullable; +import com.minelittlepony.unicopia.EquineContext; import com.minelittlepony.unicopia.USounds; import com.minelittlepony.unicopia.entity.MagicImmune; import com.minelittlepony.unicopia.particle.UParticles; import com.minelittlepony.unicopia.server.world.WeatherConditions; import net.minecraft.entity.Entity; +import net.minecraft.entity.EntityStatuses; import net.minecraft.entity.EntityType; +import net.minecraft.entity.ItemEntity; import net.minecraft.entity.LightningEntity; import net.minecraft.entity.boss.ServerBossBar; import net.minecraft.entity.damage.DamageSource; +import net.minecraft.entity.damage.DamageTypes; import net.minecraft.entity.data.DataTracker; import net.minecraft.entity.data.TrackedData; import net.minecraft.entity.data.TrackedDataHandlerRegistry; +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.item.ItemStack; +import net.minecraft.loot.context.LootContextParameterSet; +import net.minecraft.loot.context.LootContextParameters; +import net.minecraft.loot.context.LootContextTypes; import net.minecraft.nbt.NbtCompound; +import net.minecraft.nbt.NbtElement; +import net.minecraft.particle.ParticleTypes; import net.minecraft.predicate.entity.EntityPredicates; import net.minecraft.server.network.ServerPlayerEntity; import net.minecraft.server.world.ServerWorld; import net.minecraft.text.Text; import net.minecraft.util.Formatting; +import net.minecraft.util.Identifier; import net.minecraft.util.math.BlockPos; import net.minecraft.util.math.Direction; import net.minecraft.util.math.MathHelper; import net.minecraft.util.math.Vec3d; +import net.minecraft.world.GameRules; import net.minecraft.world.Heightmap.Type; import net.minecraft.world.World; @@ -135,10 +148,11 @@ public class StormCloudEntity extends Entity implements MagicImmune { } if (isLogicalSideForUpdatingMovement()) { - float groundY = getWorld().getTopY(Type.MOTION_BLOCKING_NO_LEAVES, (int)getX(), (int)getZ()); - float cloudY = (float)getY() - (isStormy() ? STORMY_TARGET_ALTITUDE : CLEAR_TARGET_ALTITUDE); + float groundY = findSurfaceBelow(getWorld(), getBlockPos()).getY(); + float targetY = isStormy() ? STORMY_TARGET_ALTITUDE : CLEAR_TARGET_ALTITUDE; + float cloudY = (float)getY() - targetY; - addVelocity(0, 0.03F * (groundY - cloudY), 0); + addVelocity(0, 0.0003F * (groundY - cloudY), 0); if (!cursed && !isStormy()) { Vec3d wind = WeatherConditions.get(getWorld()).getWindDirection(); @@ -264,7 +278,7 @@ public class StormCloudEntity extends Entity implements MagicImmune { public static BlockPos findSurfaceBelow(World world, BlockPos pos) { BlockPos.Mutable mutable = new BlockPos.Mutable(); mutable.set(pos); - while (world.isInBuildLimit(mutable) && world.isAir(mutable)) { + while (mutable.getY() > world.getBottomY() && world.isAir(mutable)) { mutable.move(Direction.DOWN); } while (world.isInBuildLimit(mutable) && !world.isAir(mutable)) { @@ -289,10 +303,46 @@ public class StormCloudEntity extends Entity implements MagicImmune { } @Override - public void onDamaged(DamageSource damageSource) { - if (random.nextInt(35) == 0) { - split(2 + random.nextInt(4)); + public boolean damage(DamageSource source, float amount) { + super.damage(source, amount); + if (!cursed) { + if (random.nextInt(35) == 0 || (source.isOf(DamageTypes.PLAYER_ATTACK) && EquineContext.of(source.getAttacker()).collidesWithClouds())) { + if (getSize(1) < 2) { + if (!getWorld().isClient() && getWorld().getGameRules().getBoolean(GameRules.DO_MOB_LOOT)) { + Identifier identifier = getType().getLootTableId(); + LootContextParameterSet.Builder builder = new LootContextParameterSet.Builder((ServerWorld)this.getWorld()) + .add(LootContextParameters.THIS_ENTITY, this) + .add(LootContextParameters.ORIGIN, this.getPos()) + .add(LootContextParameters.DAMAGE_SOURCE, source) + .addOptional(LootContextParameters.KILLER_ENTITY, source.getAttacker()) + .addOptional(LootContextParameters.DIRECT_KILLER_ENTITY, source.getSource()); + if (source.getAttacker() instanceof PlayerEntity player) { + builder = builder.add(LootContextParameters.LAST_DAMAGE_PLAYER, player).luck(player.getLuck()); + } + getWorld().getServer().getLootManager().getLootTable(identifier) + .generateLoot(builder.build(LootContextTypes.ENTITY), 0L, this::dropStack); + } + kill(); + getWorld().sendEntityStatus(this, EntityStatuses.ADD_DEATH_PARTICLES); + } else { + split(2 + random.nextInt(4)); + } + } } + return false; + } + + @Override + @Nullable + public ItemEntity dropStack(ItemStack stack) { + stack = stack.copy(); + while (!stack.isEmpty()) { + ItemEntity drop = super.dropStack(stack.split(1)); + if (drop != null) { + drop.addVelocity(random.nextTriangular(0, 0.3), 0, random.nextTriangular(0, 0.3)); + } + } + return null; } public void split(int splitCount) { @@ -322,7 +372,29 @@ public class StormCloudEntity extends Entity implements MagicImmune { @Override public void handleStatus(byte status) { - super.handleStatus(status); + switch (status) { + case EntityStatuses.ADD_DEATH_PARTICLES: + for (int i = 0; i < 20; ++i) { + double d = random.nextGaussian() * 0.02; + double e = random.nextGaussian() * 0.02; + double f = random.nextGaussian() * 0.02; + getWorld().addParticle(ParticleTypes.POOF, getParticleX(1), getRandomBodyY(), getParticleZ(1), d, e, f); + } + break; + default: + super.handleStatus(status); + } + + } + + @Override + public boolean canBeHitByProjectile() { + return false; + } + + @Override + public final boolean canHit() { + return true; } private ServerBossBar getBossBar() { @@ -348,7 +420,9 @@ public class StormCloudEntity extends Entity implements MagicImmune { public void readCustomDataFromNbt(NbtCompound nbt) { setStormTicks(nbt.getInt("stormTicks")); setClearTicks(nbt.getInt("clearTicks")); - setSize(currentSize = nbt.getFloat("size")); + if (nbt.contains("size", NbtElement.FLOAT_TYPE)) { + setSize(currentSize = nbt.getFloat("size")); + } cursed = nbt.getBoolean("cursed"); phase = nbt.getInt("phase"); nextPhase = nbt.getInt("nextPhase"); diff --git a/src/main/java/com/minelittlepony/unicopia/entity/mob/UEntities.java b/src/main/java/com/minelittlepony/unicopia/entity/mob/UEntities.java index d369e99c..3e4b122b 100644 --- a/src/main/java/com/minelittlepony/unicopia/entity/mob/UEntities.java +++ b/src/main/java/com/minelittlepony/unicopia/entity/mob/UEntities.java @@ -46,7 +46,7 @@ public interface UEntities { .trackRangeBlocks(200) .dimensions(EntityDimensions.fixed(0.1F, 0.1F))); EntityType FRIENDLY_CREEPER = register("friendly_creeper", FabricEntityTypeBuilder.create(SpawnGroup.MISC, FriendlyCreeperEntity::new) - .trackRangeBlocks(8) + .trackRangeChunks(8) .dimensions(EntityDimensions.fixed(0.6f, 1.7f)) ); EntityType SPELLBOOK = register("spellbook", FabricEntityTypeBuilder.create(SpawnGroup.MISC, SpellbookEntity::new) @@ -64,6 +64,9 @@ public interface UEntities { EntityType AIR_BALLOON = register("air_balloon", FabricEntityTypeBuilder.create(SpawnGroup.MISC, AirBalloonEntity::new) .trackRangeBlocks(1000) .dimensions(EntityDimensions.changing(2.5F, 0.1F))); + EntityType LOOT_BUG = register("loot_bug", FabricEntityTypeBuilder.create(SpawnGroup.MONSTER, LootBugEntity::new) + .trackRangeChunks(8) + .dimensions(EntityDimensions.fixed(0.8F, 0.6F))); static EntityType register(String name, FabricEntityTypeBuilder builder) { EntityType type = builder.build(); @@ -77,6 +80,7 @@ public interface UEntities { FabricDefaultAttributeRegistry.register(AIR_BALLOON, FlyingEntity.createMobAttributes()); FabricDefaultAttributeRegistry.register(SOMBRA, SombraEntity.createMobAttributes()); FabricDefaultAttributeRegistry.register(FRIENDLY_CREEPER, FriendlyCreeperEntity.createCreeperAttributes()); + FabricDefaultAttributeRegistry.register(LOOT_BUG, LootBugEntity.createSilverfishAttributes()); if (!Unicopia.getConfig().disableButterflySpawning.get()) { final Predicate butterflySpawnable = BiomeSelectors.foundInOverworld() diff --git a/src/main/java/com/minelittlepony/unicopia/entity/player/Acrobatics.java b/src/main/java/com/minelittlepony/unicopia/entity/player/Acrobatics.java new file mode 100644 index 00000000..1607c64a --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/entity/player/Acrobatics.java @@ -0,0 +1,202 @@ +package com.minelittlepony.unicopia.entity.player; + +import java.util.Optional; + +import com.minelittlepony.unicopia.Race; +import com.minelittlepony.unicopia.USounds; +import com.minelittlepony.unicopia.client.render.PlayerPoser.Animation; +import com.minelittlepony.unicopia.client.render.PlayerPoser.Animation.Recipient; +import com.minelittlepony.unicopia.entity.duck.LivingEntityDuck; +import com.minelittlepony.unicopia.entity.mob.StormCloudEntity; +import com.minelittlepony.unicopia.util.NbtSerialisable; +import com.minelittlepony.unicopia.util.Tickable; + +import net.minecraft.block.BlockState; +import net.minecraft.block.SideShapeType; +import net.minecraft.entity.data.DataTracker; +import net.minecraft.entity.data.TrackedData; +import net.minecraft.entity.data.TrackedDataHandlerRegistry; +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.nbt.NbtCompound; +import net.minecraft.sound.SoundCategory; +import net.minecraft.sound.SoundEvents; +import net.minecraft.util.math.BlockPos; +import net.minecraft.util.math.Direction; +import net.minecraft.util.math.Vec3d; +import net.minecraft.world.World; + +public class Acrobatics implements Tickable, NbtSerialisable { + static final TrackedData> HANGING_POSITION = DataTracker.registerData(PlayerEntity.class, TrackedDataHandlerRegistry.OPTIONAL_BLOCK_POS); + + private int ticksHanging; + + private Direction attachDirection; + double distanceClimbed; + + private final Pony pony; + private final PlayerEntity entity; + + public Acrobatics(Pony pony) { + this.pony = pony; + this.entity = pony.asEntity(); + + entity.getDataTracker().startTracking(HANGING_POSITION, Optional.empty()); + + pony.addTicker(this::checkDislodge); + } + + public boolean isImmobile() { + return isFloppy() && entity.isOnGround(); + } + + public boolean isFloppy() { + if (entity.isCreative() && entity.getAbilities().flying) { + return false; + } + return pony.getCompositeRace().any(Race::isFish) && !entity.isTouchingWater() && !entity.getWorld().isWater(StormCloudEntity.findSurfaceBelow(entity.getWorld(), entity.getBlockPos())); + } + + @Override + public void tick() { + BlockPos climbingPos = entity.getClimbingPos().orElse(null); + + if (!pony.getPhysics().isFlying() && !entity.getAbilities().flying + && climbingPos != null + && pony.getObservedSpecies() == Race.CHANGELING) { + Vec3d vel = entity.getVelocity(); + if (entity.isSneaking()) { + entity.setVelocity(vel.x, 0, vel.z); + } + + distanceClimbed += Math.abs(pony.getMotion().getClientVelocity().y); + BlockPos hangingPos = entity.getBlockPos().up(); + boolean canhangHere = canHangAt(hangingPos); + + if (distanceClimbed > 1.5) { + if (vel.length() > 0.08F && entity.age % (3 + entity.getRandom().nextInt(5)) == 0) { + entity.playSound(USounds.ENTITY_PLAYER_CHANGELING_CLIMB, + (float)entity.getRandom().nextTriangular(0.5, 0.3), + entity.getSoundPitch() + ); + } + + boolean skipHangCheck = false; + Direction newAttachDirection = entity.getHorizontalFacing(); + if (isFaceClimbable(entity.getWorld(), entity.getBlockPos(), newAttachDirection) && (newAttachDirection != attachDirection)) { + attachDirection = newAttachDirection; + skipHangCheck = true; + } + + if (!skipHangCheck && canhangHere) { + if (!isHanging()) { + startHanging(hangingPos); + } else { + if (((LivingEntityDuck)entity).isJumping()) { + // Jump to let go + return; + } + entity.setVelocity(entity.getVelocity().multiply(1, 0, 1)); + entity.setSneaking(false); + } + } else if (attachDirection != null) { + if (isFaceClimbable(entity.getWorld(), entity.getBlockPos(), attachDirection)) { + entity.setBodyYaw(attachDirection.asRotation()); + entity.prevBodyYaw = attachDirection.asRotation(); + } else { + entity.setVelocity(vel); + entity.isClimbing(); + } + } + } + + if (canhangHere) { + pony.setAnimation(Animation.HANG, Recipient.ANYONE); + } else if (distanceClimbed > 1.5) { + pony.setAnimation(Animation.CLIMB, Recipient.ANYONE); + } + } else { + distanceClimbed = 0; + attachDirection = null; + } + } + + private void checkDislodge() { + if (isHanging()) { + ((LivingEntityDuck)entity).setLeaningPitch(0); + if (!pony.isClient() && !canKeepHanging()) { + stopHanging(); + } + } else { + ticksHanging = 0; + } + + + if (pony.getCompositeRace().includes(Race.SEAPONY) && !entity.isSubmergedInWater() && pony.landedChanged()) { + entity.getWorld().playSound(null, entity.getBlockPos(), SoundEvents.ENTITY_GUARDIAN_FLOP, SoundCategory.PLAYERS, 1, 1); + } + } + + boolean isFaceClimbable(World world, BlockPos pos, Direction direction) { + pos = pos.offset(direction); + return world.getBlockState(pos).isSideSolid(world, pos, direction, SideShapeType.CENTER); + } + + public Optional getHangingPosition() { + return entity.getDataTracker().get(HANGING_POSITION); + } + + public boolean isHanging() { + return getHangingPosition().isPresent(); + } + + public void stopHanging() { + entity.getDataTracker().set(HANGING_POSITION, Optional.empty()); + entity.calculateDimensions(); + ticksHanging = 0; + } + + public void startHanging(BlockPos pos) { + entity.getDataTracker().set(HANGING_POSITION, Optional.of(pos)); + entity.teleport(pos.getX() + 0.5, pos.getY() - 1, pos.getZ() + 0.5); + entity.setVelocity(Vec3d.ZERO); + entity.setSneaking(false); + entity.stopFallFlying(); + pony.getPhysics().cancelFlight(true); + } + + public boolean canHangAt(BlockPos pos) { + if (!pony.asWorld().isAir(pos) || !pony.asWorld().isAir(pos.down())) { + return false; + } + + pos = pos.up(); + BlockState state = pony.asWorld().getBlockState(pos); + + return state.isSolidSurface(pony.asWorld(), pos, entity, Direction.DOWN) && entity.getWorld().isAir(entity.getBlockPos().down()); + } + + private boolean canKeepHanging() { + Race race = pony.getObservedSpecies(); + if (!race.canHang()) { + return false; + } + if (ticksHanging++ <= 2) { + return true; + } + return getHangingPosition().filter(hangingPos -> { + return (race != Race.BAT || hangingPos.equals(pony.getOrigin().down())) && canHangAt(hangingPos); + }).isPresent(); + } + + @Override + public void toNBT(NbtCompound compound) { + compound.putInt("ticksHanging", ticksHanging); + BLOCK_POS.writeOptional("hangingPosition", compound, getHangingPosition()); + } + + @Override + public void fromNBT(NbtCompound compound) { + ticksHanging = compound.getInt("ticksHanging"); + pony.asEntity().getDataTracker().set(HANGING_POSITION, NbtSerialisable.BLOCK_POS.readOptional("hangingPosition", compound)); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/entity/player/PlayerAttributes.java b/src/main/java/com/minelittlepony/unicopia/entity/player/PlayerAttributes.java index 0a3d1da3..ad647427 100644 --- a/src/main/java/com/minelittlepony/unicopia/entity/player/PlayerAttributes.java +++ b/src/main/java/com/minelittlepony/unicopia/entity/player/PlayerAttributes.java @@ -36,12 +36,23 @@ public class PlayerAttributes implements Tickable { new ToggleableAttribute( new EntityAttributeModifier(UUID.fromString("9e2699fc-3b8d-4f71-9d2d-fb92ee19b4f7"), "Pegasus Speed", 0.2, Operation.MULTIPLY_TOTAL), List.of(EntityAttributes.GENERIC_MOVEMENT_SPEED, EntityAttributes.GENERIC_ATTACK_SPEED), - pony -> pony.getCompositeRace().canFly() + pony -> pony.getCompositeRace().canFly() && !pony.getCompositeRace().includes(Race.HIPPOGRIFF) ), new ToggleableAttribute( new EntityAttributeModifier(UUID.fromString("707b50a8-03e8-40f4-8553-ecf67025fd6d"), "Pegasus Reach", 1.5, Operation.ADDITION), List.of(UEntityAttributes.EXTENDED_REACH_DISTANCE), - pony -> pony.getCompositeRace().canFly() + pony -> pony.getCompositeRace().canFly() && !pony.getCompositeRace().includes(Race.HIPPOGRIFF) + ), + + new ToggleableAttribute( + new EntityAttributeModifier(UUID.fromString("9e2699fc-3b8d-4f71-92dd-bef19b92e4f7"), "Hippogriff Speed", 0.1, Operation.MULTIPLY_TOTAL), + List.of(EntityAttributes.GENERIC_MOVEMENT_SPEED, EntityAttributes.GENERIC_ATTACK_SPEED), + pony -> pony.getCompositeRace().includes(Race.HIPPOGRIFF) + ), + new ToggleableAttribute( + new EntityAttributeModifier(UUID.fromString("707b50a8-03e8-40f4-5853-fc7e0f625d6d"), "Hippogriff Reach", 1.3, Operation.ADDITION), + List.of(UEntityAttributes.EXTENDED_REACH_DISTANCE), + pony -> pony.getCompositeRace().includes(Race.HIPPOGRIFF) ), new ToggleableAttribute( diff --git a/src/main/java/com/minelittlepony/unicopia/entity/player/PlayerCamera.java b/src/main/java/com/minelittlepony/unicopia/entity/player/PlayerCamera.java index bd070bd7..11b71c2e 100644 --- a/src/main/java/com/minelittlepony/unicopia/entity/player/PlayerCamera.java +++ b/src/main/java/com/minelittlepony/unicopia/entity/player/PlayerCamera.java @@ -35,6 +35,11 @@ public class PlayerCamera extends MotionCompositor { roll = player.getInterpolator().interpolate("roll", (float)roll, 15); } + + if (player.getAcrobatics().isFloppy()) { + roll += 90; + } + return (float)roll; } diff --git a/src/main/java/com/minelittlepony/unicopia/entity/player/PlayerPhysics.java b/src/main/java/com/minelittlepony/unicopia/entity/player/PlayerPhysics.java index 045dbfdb..bb9b68e9 100644 --- a/src/main/java/com/minelittlepony/unicopia/entity/player/PlayerPhysics.java +++ b/src/main/java/com/minelittlepony/unicopia/entity/player/PlayerPhysics.java @@ -115,7 +115,7 @@ public class PlayerPhysics extends EntityPhysics implements Tickab @Override public float getGravityModifier() { float modifier = getPersistantGravityModifier(); - if (pony.isHanging() && pony.getObservedSpecies() == Race.BAT) { + if (pony.getAcrobatics().isHanging() && pony.getObservedSpecies() == Race.BAT) { modifier *= -0.05F; } return modifier; @@ -385,7 +385,7 @@ public class PlayerPhysics extends EntityPhysics implements Tickab entity.setVelocity(velocity.toImmutable()); - if (isFlying() && !entity.isFallFlying() && !pony.isHanging() && pony.isClient()) { + if (isFlying() && !entity.isFallFlying() && !pony.getAcrobatics().isHanging() && pony.isClient()) { if (!MineLPDelegate.getInstance().getPlayerPonyRace(entity).isEquine() && getHorizontalMotion() > 0.03) { float pitch = ((LivingEntityDuck)entity).getLeaningPitch(); if (pitch < 1) { @@ -414,7 +414,7 @@ public class PlayerPhysics extends EntityPhysics implements Tickab if (type.isAvian()) { if (pony.getObservedSpecies() != Race.BAT && entity.getWorld().random.nextInt(9000) == 0) { - entity.dropItem(UItems.PEGASUS_FEATHER); + entity.dropItem(pony.getObservedSpecies() == Race.HIPPOGRIFF ? UItems.GRYPHON_FEATHER : UItems.PEGASUS_FEATHER); playSound(USounds.ENTITY_PLAYER_PEGASUS_MOLT, 0.3F, 1); UCriteria.SHED_FEATHER.trigger(entity); } @@ -513,7 +513,9 @@ public class PlayerPhysics extends EntityPhysics implements Tickab if (entity.getWorld().random.nextInt(110) == 1 && !pony.isClient()) { pony.getLevel().add(1); - pony.getMagicalReserves().getCharge().addPercent(4); + if (Abilities.RAINBOOM.canUse(pony.getCompositeRace())) { + pony.getMagicalReserves().getCharge().addPercent(4); + } pony.getMagicalReserves().getExertion().set(0); pony.getMagicalReserves().getExhaustion().set(0); mana.set(mana.getMax() * 100); @@ -533,7 +535,7 @@ public class PlayerPhysics extends EntityPhysics implements Tickab && pony.getJumpingHeuristic().hasChanged(Heuristic.TWICE); boolean fallingTakeOffCondition = !entity.isOnGround() && velocity.y < -1.6 * getGravitySignum() && entity.fallDistance > 1; - if ((takeOffCondition || fallingTakeOffCondition) && !pony.isHanging() && !isCancelled) { + if ((takeOffCondition || fallingTakeOffCondition) && !pony.getAcrobatics().isHanging() && !isCancelled) { initiateTakeoff(velocity); } } diff --git a/src/main/java/com/minelittlepony/unicopia/entity/player/Pony.java b/src/main/java/com/minelittlepony/unicopia/entity/player/Pony.java index 98e99aa4..6a12cabe 100644 --- a/src/main/java/com/minelittlepony/unicopia/entity/player/Pony.java +++ b/src/main/java/com/minelittlepony/unicopia/entity/player/Pony.java @@ -6,7 +6,6 @@ import java.util.stream.Stream; import org.jetbrains.annotations.Nullable; import com.minelittlepony.unicopia.client.render.PlayerPoser.Animation; -import com.minelittlepony.unicopia.client.render.PlayerPoser.Animation.Recipient; import com.minelittlepony.unicopia.compat.trinkets.TrinketsDelegate; import com.minelittlepony.unicopia.client.render.PlayerPoser.AnimationInstance; import com.minelittlepony.unicopia.*; @@ -14,6 +13,7 @@ import com.minelittlepony.unicopia.ability.*; import com.minelittlepony.unicopia.ability.magic.*; import com.minelittlepony.unicopia.ability.magic.spell.AbstractDisguiseSpell; import com.minelittlepony.unicopia.ability.magic.spell.CastingMethod; +import com.minelittlepony.unicopia.ability.magic.spell.RageAbilitySpell; import com.minelittlepony.unicopia.ability.magic.spell.Spell; import com.minelittlepony.unicopia.ability.magic.spell.effect.SpellType; import com.minelittlepony.unicopia.ability.magic.spell.trait.TraitDiscovery; @@ -37,9 +37,9 @@ import com.google.common.collect.Streams; import com.minelittlepony.common.util.animation.Interpolator; import com.mojang.authlib.GameProfile; -import net.minecraft.block.BlockState; -import net.minecraft.block.SideShapeType; +import net.minecraft.enchantment.Enchantment; import net.minecraft.enchantment.EnchantmentHelper; +import net.minecraft.enchantment.Enchantments; import net.minecraft.entity.*; import net.minecraft.entity.attribute.DefaultAttributeContainer; import net.minecraft.entity.damage.DamageSource; @@ -54,24 +54,27 @@ import net.minecraft.entity.player.PlayerInventory; import net.minecraft.item.ItemStack; import net.minecraft.nbt.NbtCompound; import net.minecraft.particle.ParticleTypes; +import net.minecraft.potion.PotionUtil; +import net.minecraft.potion.Potions; import net.minecraft.registry.tag.DamageTypeTags; +import net.minecraft.registry.tag.FluidTags; import net.minecraft.server.network.ServerPlayerEntity; import net.minecraft.server.world.ServerWorld; +import net.minecraft.sound.SoundEvents; import net.minecraft.text.Text; import net.minecraft.util.ActionResult; import net.minecraft.util.Hand; import net.minecraft.util.math.*; import net.minecraft.world.GameMode; import net.minecraft.world.GameRules; -import net.minecraft.world.World; public class Pony extends Living implements Copyable, UpdateCallback { private static final TrackedData RACE = DataTracker.registerData(PlayerEntity.class, TrackedDataHandlerRegistry.STRING); + private static final TrackedData SUPPRESSED_RACE = DataTracker.registerData(PlayerEntity.class, TrackedDataHandlerRegistry.STRING); static final TrackedData ENERGY = DataTracker.registerData(PlayerEntity.class, TrackedDataHandlerRegistry.FLOAT); static final TrackedData EXHAUSTION = DataTracker.registerData(PlayerEntity.class, TrackedDataHandlerRegistry.FLOAT); static final TrackedData EXERTION = DataTracker.registerData(PlayerEntity.class, TrackedDataHandlerRegistry.FLOAT); - static final TrackedData> HANGING_POSITION = DataTracker.registerData(PlayerEntity.class, TrackedDataHandlerRegistry.OPTIONAL_BLOCK_POS); static final TrackedData MANA = DataTracker.registerData(PlayerEntity.class, TrackedDataHandlerRegistry.FLOAT); static final TrackedData XP = DataTracker.registerData(PlayerEntity.class, TrackedDataHandlerRegistry.FLOAT); static final TrackedData CHARGE = DataTracker.registerData(PlayerEntity.class, TrackedDataHandlerRegistry.FLOAT); @@ -87,6 +90,7 @@ public class Pony extends Living implements Copyable, Update private final PlayerCharmTracker charms = new PlayerCharmTracker(this); private final PlayerCamera camera = new PlayerCamera(this); private final TraitDiscovery discoveries = new TraitDiscovery(this); + private final Acrobatics acrobatics = new Acrobatics(this); private final Map advancementProgress = new HashMap<>(); @@ -101,19 +105,15 @@ public class Pony extends Living implements Copyable, Update private boolean dirty; - private int ticksHanging; - private float magicExhaustion = 0; private int ticksInvulnerable; + private int ticksMetamorphising; private int ticksInSun; private boolean hasShades; private int ticksSunImmunity = INITIAL_SUN_IMMUNITY; - private Direction attachDirection; - private double distanceClimbed; - private AnimationInstance animation = new AnimationInstance(Animation.NONE, Animation.Recipient.ANYONE); private int animationMaxDuration; private int animationDuration; @@ -125,7 +125,7 @@ public class Pony extends Living implements Copyable, Update this.mana = addTicker(new ManaContainer(this)); player.getDataTracker().startTracking(RACE, Race.DEFAULT_ID); - player.getDataTracker().startTracking(HANGING_POSITION, Optional.empty()); + player.getDataTracker().startTracking(SUPPRESSED_RACE, Race.DEFAULT_ID); addTicker(this::updateAnimations); addTicker(this::updateBatPonyAbilities); @@ -229,8 +229,13 @@ public class Pony extends Living implements Copyable, Update @Override public void setSpecies(Race race) { race = race.validate(entity); + Race current = getSpecies(); + entity.getDataTracker().set(RACE, Race.REGISTRY.getId(race.validate(entity)).toString()); + if (race != current) { + clearSuppressedRace(); + } + ticksInSun = 0; - entity.getDataTracker().set(RACE, Race.REGISTRY.getId(race).toString()); gravity.updateFlightState(); entity.sendAbilitiesUpdate(); @@ -238,6 +243,18 @@ public class Pony extends Living implements Copyable, Update UCriteria.PLAYER_CHANGE_RACE.trigger(entity); } + public void setSuppressedRace(Race race) { + entity.getDataTracker().set(SUPPRESSED_RACE, Race.REGISTRY.getId(race.validate(entity)).toString()); + } + + public void clearSuppressedRace() { + setSuppressedRace(Race.UNSET); + } + + public Race getSuppressedRace() { + return Race.fromName(entity.getDataTracker().get(SUPPRESSED_RACE), Race.UNSET); + } + public TraitDiscovery getDiscoveries() { return discoveries; } @@ -250,6 +267,10 @@ public class Pony extends Living implements Copyable, Update return charms; } + public Acrobatics getAcrobatics() { + return acrobatics; + } + @Override public LevelStore getLevel() { return levels; @@ -281,6 +302,14 @@ public class Pony extends Living implements Copyable, Update this.ticksInvulnerable = Math.max(0, ticks); } + public int getTicksMetamorphising() { + return ticksMetamorphising; + } + + public void setTicksmetamorphising(int ticks) { + ticksMetamorphising = ticks; + } + @Override public Affinity getAffinity() { return getSpecies().getAffinity(); @@ -335,11 +364,12 @@ public class Pony extends Living implements Copyable, Update } public void onSpawn() { - if (entity.getWorld() instanceof ServerWorld sw - && getObservedSpecies() == Race.BAT - && sw.getServer().getSaveProperties().getGameMode() != GameMode.ADVENTURE - && MeteorlogicalUtil.isPositionExposedToSun(sw, getOrigin())) { - SpawnLocator.selectSpawnPosition(sw, entity); + if (entity.getWorld() instanceof ServerWorld sw && sw.getServer().getSaveProperties().getGameMode() != GameMode.ADVENTURE) { + boolean mustAvoidSun = getObservedSpecies() == Race.BAT && MeteorlogicalUtil.isPositionExposedToSun(sw, getOrigin()); + boolean mustAvoidAir = getCompositeRace().includes(Race.SEAPONY) && !sw.getFluidState(getOrigin()).isIn(FluidTags.WATER); + if (mustAvoidSun || mustAvoidAir) { + SpawnLocator.selectSpawnPosition(sw, entity, mustAvoidAir, mustAvoidSun); + } } ticksSunImmunity = INITIAL_SUN_IMMUNITY; } @@ -347,16 +377,19 @@ public class Pony extends Living implements Copyable, Update @Override public boolean beforeUpdate() { if (compositeRace.includes(Race.UNSET) || entity.age % 2 == 0) { + Race intrinsicRace = getSpecies(); + Race suppressedRace = getSuppressedRace(); compositeRace = getSpellSlot() .get(SpellPredicate.IS_MIMIC, true) .map(AbstractDisguiseSpell::getDisguise) .map(EntityAppearance::getAppearance) .flatMap(Pony::of) .map(Pony::getSpecies) - .orElseGet(this::getSpecies).composite( + .orElse(intrinsicRace).composite( AmuletSelectors.UNICORN_AMULET.test(entity) ? Race.UNICORN : AmuletSelectors.ALICORN_AMULET.test(entity) ? Race.ALICORN - : null + : null, + AmuletSelectors.PEARL_NECKLACE.test(entity) ? suppressedRace.or(Race.SEAPONY) : null ); } @@ -393,69 +426,12 @@ public class Pony extends Living implements Copyable, Update magicExhaustion = ManaConsumptionUtil.burnFood(entity, magicExhaustion); powers.tick(); - - BlockPos climbingPos = entity.getClimbingPos().orElse(null); - - if (!getPhysics().isFlying() && !entity.getAbilities().flying && climbingPos != null && getObservedSpecies() == Race.CHANGELING) { - Vec3d vel = entity.getVelocity(); - if (entity.isSneaking()) { - entity.setVelocity(vel.x, 0, vel.z); - } - - distanceClimbed += vel.length(); - BlockPos hangingPos = entity.getBlockPos().up(); - boolean canhangHere = canHangAt(hangingPos); - - if (distanceClimbed > 1.5) { - if (vel.length() > 0.08F && entity.age % (3 + entity.getRandom().nextInt(5)) == 0) { - entity.playSound(USounds.ENTITY_PLAYER_CHANGELING_CLIMB, - (float)entity.getRandom().nextTriangular(0.5, 0.3), - entity.getSoundPitch() - ); - } - - boolean skipHangCheck = false; - Direction newAttachDirection = entity.getHorizontalFacing(); - if (isFaceClimbable(entity.getWorld(), entity.getBlockPos(), newAttachDirection) && (newAttachDirection != attachDirection)) { - attachDirection = newAttachDirection; - skipHangCheck = true; - } - - if (!skipHangCheck && canhangHere) { - if (!isHanging()) { - startHanging(hangingPos); - } else { - if (((LivingEntityDuck)entity).isJumping()) { - // Jump to let go - return false; - } - entity.setVelocity(entity.getVelocity().multiply(1, 0, 1)); - entity.setSneaking(false); - } - } else if (attachDirection != null) { - if (isFaceClimbable(entity.getWorld(), entity.getBlockPos(), attachDirection)) { - entity.setBodyYaw(attachDirection.asRotation()); - entity.prevBodyYaw = attachDirection.asRotation(); - } else { - entity.setVelocity(vel); - entity.isClimbing(); - } - } - } - - if (canhangHere) { - setAnimation(Animation.HANG, Recipient.ANYONE); - } else if (distanceClimbed > 1.5) { - setAnimation(Animation.CLIMB, Recipient.ANYONE); - } - } else { - distanceClimbed = 0; - } + acrobatics.tick(); if (getObservedSpecies() == Race.KIRIN) { var charge = getMagicalReserves().getCharge(); - if (entity.isTouchingWater()) { + if (entity.isTouchingWater() || entity.isFrozen()) { charge.multiply(0.5F); } @@ -482,52 +458,34 @@ public class Pony extends Living implements Copyable, Update } } - return super.beforeUpdate(); - } + if (getCompositeRace().includes(Race.SEAPONY)) { + if (entity.isSubmergedInWater()) { + if (entity.getVelocity().lengthSquared() > 0.02) { + spawnParticles(ParticleTypes.BUBBLE, 4); + } + } else { + if (entity.getAir() == entity.getMaxAir()) { + entity.setAir(entity.getAir() - 1); + } - private boolean isFaceClimbable(World world, BlockPos pos, Direction direction) { - pos = pos.offset(direction); - return world.getBlockState(pos).isSideSolid(world, pos, direction, SideShapeType.CENTER); - } + if (entity.age % 60 == 0) { + entity.playSound(SoundEvents.ENTITY_TURTLE_AMBIENT_LAND, 1, 1); + } - public Optional getHangingPosition() { - return entity.getDataTracker().get(HANGING_POSITION); - } - - public boolean isHanging() { - return getHangingPosition().isPresent(); - } - - public void stopHanging() { - entity.getDataTracker().set(HANGING_POSITION, Optional.empty()); - entity.calculateDimensions(); - ticksHanging = 0; - } - - public void startHanging(BlockPos pos) { - entity.getDataTracker().set(HANGING_POSITION, Optional.of(pos)); - entity.teleport(pos.getX() + 0.5, pos.getY() - 1, pos.getZ() + 0.5); - entity.setVelocity(Vec3d.ZERO); - entity.setSneaking(false); - entity.stopFallFlying(); - getPhysics().cancelFlight(true); - } - - public boolean canHangAt(BlockPos pos) { - if (!asWorld().isAir(pos) || !asWorld().isAir(pos.down())) { - return false; + if (entity.getAir() == -20) { + entity.setAir(0); + entity.damage(entity.getDamageSources().dryOut(), 2); + } + } } - pos = pos.up(); - BlockState state = asWorld().getBlockState(pos); - - return state.isSolidSurface(asWorld(), pos, entity, Direction.DOWN); + return super.beforeUpdate(); } @Override public Optional chooseClimbingPos() { if (getObservedSpecies() == Race.CHANGELING && getSpellSlot().get(SpellPredicate.IS_DISGUISE, false).isEmpty()) { - if (isFaceClimbable(entity.getWorld(), entity.getBlockPos(), entity.getHorizontalFacing()) || canHangAt(entity.getBlockPos())) { + if (acrobatics.isFaceClimbable(entity.getWorld(), entity.getBlockPos(), entity.getHorizontalFacing()) || acrobatics.canHangAt(entity.getBlockPos())) { return Optional.of(entity.getBlockPos()); } } @@ -536,7 +494,7 @@ public class Pony extends Living implements Copyable, Update private void updateAnimations() { - if (distanceClimbed > 0 + if (acrobatics.distanceClimbed > 0 && ((animation.isOf(Animation.CLIMB) && entity.isSneaking()) || animation.isOf(Animation.HANG)) && entity.getClimbingPos().isPresent() && entity.getVelocity().length() < 0.08F) { @@ -548,7 +506,7 @@ public class Pony extends Living implements Copyable, Update if (animationDuration > 0 && --animationDuration <= 0) { - if (animation.renderBothArms() && distanceClimbed > 0) { + if (animation.renderBothArms() && acrobatics.distanceClimbed > 0) { return; } @@ -561,17 +519,6 @@ public class Pony extends Living implements Copyable, Update ticksSunImmunity--; } - if (isHanging()) { - ((LivingEntityDuck)entity).setLeaningPitch(0); - if (!getObservedSpecies().canHang() || (ticksHanging++ > 2 && getHangingPosition().filter(getOrigin().down()::equals).filter(this::canHangAt).isEmpty())) { - if (!isClient()) { - stopHanging(); - } - } - } else { - ticksHanging = 0; - } - if (getObservedSpecies() == Race.BAT && !entity.hasPortalCooldown()) { boolean hasShades = TrinketsDelegate.getInstance().getEquipped(entity, TrinketsDelegate.FACE).anyMatch(s -> s.isIn(UTags.SHADES)); if (!this.hasShades && hasShades && getObservedSpecies() == Race.BAT) { @@ -672,6 +619,15 @@ public class Pony extends Living implements Copyable, Update if (getObservedSpecies() == Race.KIRIN) { return Optional.of(speed.multiply(0.5, 1, 0.5)); } + if (getCompositeRace().includes(Race.SEAPONY)) { + float factor = entity.isSwimming() ? 1.132F : 1.0232F; + float max = 0.6F; + return Optional.of(new Vec3d( + MathHelper.clamp(speed.x * factor, -max, max), + speed.y * ((speed.y * getPhysics().getGravitySignum()) > 0 ? 1.2 : 1.101), + MathHelper.clamp(speed.z * factor, -max, max) + )); + } return Optional.empty(); } @@ -699,6 +655,18 @@ public class Pony extends Living implements Copyable, Update return false; } + public int getImplicitEnchantmentLevel(Enchantment enchantment, int initial) { + + if ((enchantment == Enchantments.AQUA_AFFINITY + || enchantment == Enchantments.DEPTH_STRIDER + || enchantment == Enchantments.LUCK_OF_THE_SEA + || enchantment == Enchantments.LURE) && getCompositeRace().includes(Race.SEAPONY)) { + return MathHelper.clamp(initial + 3, enchantment.getMinLevel(), enchantment.getMaxLevel()); + } + + return initial; + } + public Optional modifyDamage(DamageSource cause, float amount) { if (getObservedSpecies() == Race.KIRIN) { @@ -769,6 +737,18 @@ public class Pony extends Living implements Copyable, Update return Optional.empty(); } + public void onEat(ItemStack stack) { + if (isClient()) { + return; + } + + if (getObservedSpecies() == Race.KIRIN + && (stack.isIn(UTags.COOLS_OFF_KIRINS) || PotionUtil.getPotion(stack) == Potions.WATER)) { + getMagicalReserves().getCharge().multiply(0.5F); + getSpellSlot().get(SpellType.RAGE, false).ifPresent(RageAbilitySpell::setExtenguishing); + } + } + @SuppressWarnings("deprecation") @Override protected void handleFall(float distance, float damageMultiplier, DamageSource cause) { @@ -855,11 +835,11 @@ public class Pony extends Living implements Copyable, Update public void toSyncronisedNbt(NbtCompound compound) { super.toSyncronisedNbt(compound); compound.putString("playerSpecies", Race.REGISTRY.getId(getSpecies()).toString()); + compound.putString("suppressedSpecies", Race.REGISTRY.getId(getSuppressedRace()).toString()); compound.putFloat("magicExhaustion", magicExhaustion); - compound.putInt("ticksHanging", ticksHanging); - BLOCK_POS.writeOptional("hangingPosition", compound, getHangingPosition()); compound.putInt("ticksInSun", ticksInSun); compound.putBoolean("hasShades", hasShades); + compound.put("acrobatics", acrobatics.toNBT()); compound.put("powers", powers.toNBT()); compound.put("gravity", gravity.toNBT()); compound.put("charms", charms.toNBT()); @@ -868,6 +848,7 @@ public class Pony extends Living implements Copyable, Update compound.putInt("levels", levels.get()); compound.putInt("corruption", corruption.get()); compound.putInt("ticksInvulnerable", ticksInvulnerable); + compound.putInt("ticksMetamorphising", ticksMetamorphising); NbtCompound progress = new NbtCompound(); advancementProgress.forEach((key, count) -> { @@ -880,6 +861,7 @@ public class Pony extends Living implements Copyable, Update public void fromSynchronizedNbt(NbtCompound compound) { super.fromSynchronizedNbt(compound); setSpecies(Race.fromName(compound.getString("playerSpecies"), Race.HUMAN)); + setSuppressedRace(Race.fromName(compound.getString("suppressedSpecies"), Race.UNSET)); powers.fromNBT(compound.getCompound("powers")); gravity.fromNBT(compound.getCompound("gravity")); charms.fromNBT(compound.getCompound("charms")); @@ -887,13 +869,12 @@ public class Pony extends Living implements Copyable, Update levels.set(compound.getInt("levels")); corruption.set(compound.getInt("corruption")); mana.fromNBT(compound.getCompound("mana")); - + acrobatics.fromNBT(compound.getCompound("acrobatics")); magicExhaustion = compound.getFloat("magicExhaustion"); - ticksHanging = compound.getInt("ticksHanging"); ticksInvulnerable = compound.getInt("ticksInvulnerable"); - entity.getDataTracker().set(HANGING_POSITION, NbtSerialisable.BLOCK_POS.readOptional("hangingPosition", compound)); ticksInSun = compound.getInt("ticksInSun"); hasShades = compound.getBoolean("hasShades"); + ticksMetamorphising = compound.getInt("ticksMetamorphising"); NbtCompound progress = compound.getCompound("advancementProgress"); advancementProgress.clear(); @@ -911,10 +892,13 @@ public class Pony extends Living implements Copyable, Update && oldPlayer.respawnRace.isUnset()) || oldPlayer.getSpecies().isUnset(); + Race oldSuppressedRace = oldPlayer.getSuppressedRace(); + if (alive) { oldPlayer.getSpellSlot().stream(true).forEach(getSpellSlot()::put); } else { if (forcedSwap) { + oldSuppressedRace = Race.UNSET; Channel.SERVER_SELECT_TRIBE.sendToPlayer(new MsgTribeSelect(Race.allPermitted(entity), "gui.unicopia.tribe_selection.respawn"), (ServerPlayerEntity)entity); } else { oldPlayer.getSpellSlot().stream(true).filter(SpellPredicate.IS_PLACED).forEach(getSpellSlot()::put); @@ -933,6 +917,7 @@ public class Pony extends Living implements Copyable, Update } setSpecies(oldPlayer.respawnRace != Race.UNSET && !alive ? oldPlayer.respawnRace : oldPlayer.getSpecies()); + setSuppressedRace(oldSuppressedRace); getDiscoveries().copyFrom(oldPlayer.getDiscoveries(), alive); getPhysics().copyFrom(oldPlayer.getPhysics(), alive); if (!forcedSwap) { diff --git a/src/main/java/com/minelittlepony/unicopia/entity/player/SpawnLocator.java b/src/main/java/com/minelittlepony/unicopia/entity/player/SpawnLocator.java index 4c49f017..13d30bf3 100644 --- a/src/main/java/com/minelittlepony/unicopia/entity/player/SpawnLocator.java +++ b/src/main/java/com/minelittlepony/unicopia/entity/player/SpawnLocator.java @@ -1,37 +1,68 @@ package com.minelittlepony.unicopia.entity.player; -import java.util.Optional; - import com.minelittlepony.unicopia.util.MeteorlogicalUtil; -import net.minecraft.entity.ai.FuzzyPositions; +import net.minecraft.block.Block; +import net.minecraft.block.BlockState; import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.fluid.FluidState; +import net.minecraft.registry.tag.FluidTags; import net.minecraft.server.network.SpawnLocating; import net.minecraft.server.world.ServerWorld; import net.minecraft.util.math.*; import net.minecraft.util.math.random.Random; +import net.minecraft.world.Heightmap; +import net.minecraft.world.chunk.WorldChunk; public class SpawnLocator extends SpawnLocating { - - public static BlockPos findSafeSpawnLocation(ServerWorld world, int x, int z) { - return SpawnLocating.findOverworldSpawn(world, x, z); - } - - public static Optional fuzz(ServerWorld world, BlockPos pos, int horizontal, int vertical) { - - for (int attempt = 0; attempt < 6; attempt++) { - BlockPos target = FuzzyPositions.localFuzz(world.random, horizontal, vertical); - target = findSafeSpawnLocation(world, target.getX(), target.getZ()); - - if (target != null) { - return Optional.of(target); - } + private static BlockPos findSafeSpawnLocation(ServerWorld world, int x, int z, boolean avoidAir) { + if (!avoidAir) { + return findOverworldSpawn(world, x, z); } - return Optional.empty(); + boolean hasCeiling = world.getDimension().hasCeiling(); + WorldChunk chunk = world.getChunk(ChunkSectionPos.getSectionCoord(x), ChunkSectionPos.getSectionCoord(z)); + int startHeight = hasCeiling + ? world.getChunkManager().getChunkGenerator().getSpawnHeight(world) + : chunk.sampleHeightmap(Heightmap.Type.MOTION_BLOCKING, x & 0xF, z & 0xF); + if (startHeight < world.getBottomY()) { + return null; + } + + int terrainHeight = chunk.sampleHeightmap(Heightmap.Type.WORLD_SURFACE, x & 0xF, z & 0xF); + if (terrainHeight <= startHeight && terrainHeight > chunk.sampleHeightmap(Heightmap.Type.OCEAN_FLOOR, x & 0xF, z & 0xF)) { + return null; + } + + BlockPos.Mutable mutable = new BlockPos.Mutable(); + for (int y = startHeight + 1; y >= world.getBottomY(); --y) { + mutable.set(x, y, z); + BlockState state = world.getBlockState(mutable); + FluidState fluid = state.getFluidState(); + if (fluid.isEmpty()) { + continue; + } + if (!fluid.isIn(FluidTags.WATER)) { + break; + } + if (!Block.isFaceFullSquare(state.getCollisionShape(world, mutable), Direction.UP)) { + continue; + } + + return mutable.up().toImmutable(); + } + return null; } - public static void selectSpawnPosition(ServerWorld world, PlayerEntity entity) { + private static boolean checkAtmosphere(ServerWorld world, BlockPos pos, boolean avoidAir) { + if (avoidAir) { + return world.getFluidState(pos).isIn(FluidTags.WATER); + + } + return world.getFluidState(pos).isEmpty(); + } + + public static void selectSpawnPosition(ServerWorld world, PlayerEntity entity, boolean avoidAir, boolean avoidSun) { BlockPos spawnPos = world.getSpawnPos(); int spawnRadius = Math.min( MathHelper.floor(world.getWorldBorder().getDistanceInsideBorder(spawnPos.getX(), spawnPos.getZ())), @@ -53,7 +84,8 @@ public class SpawnLocator extends SpawnLocating { BlockPos candidatePos = findSafeSpawnLocation(world, spawnPos.getX() + x - spawnRadius, - spawnPos.getZ() + z - spawnRadius + spawnPos.getZ() + z - spawnRadius, + avoidAir ); if (candidatePos == null) { @@ -70,7 +102,7 @@ public class SpawnLocator extends SpawnLocating { mutable.move(0, -1, 0); } - if (!world.getFluidState(mutable).isEmpty()) { + if (!checkAtmosphere(world, mutable, avoidAir)) { continue; } @@ -78,13 +110,17 @@ public class SpawnLocator extends SpawnLocating { mutable.move(0, 1, 0); } - if (!world.getFluidState(mutable).isEmpty()) { + if (!checkAtmosphere(world, mutable, avoidAir)) { continue; } entity.refreshPositionAndAngles(mutable, 0, 0); - if (!world.isSpaceEmpty(entity) || MeteorlogicalUtil.isPositionExposedToSun(world, mutable)) { + if (!world.isSpaceEmpty(entity)) { + continue; + } + + if (avoidSun && MeteorlogicalUtil.isPositionExposedToSun(world, mutable)) { continue; } diff --git a/src/main/java/com/minelittlepony/unicopia/item/BedsheetsItem.java b/src/main/java/com/minelittlepony/unicopia/item/BedsheetsItem.java new file mode 100644 index 00000000..ddd94336 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/item/BedsheetsItem.java @@ -0,0 +1,52 @@ +package com.minelittlepony.unicopia.item; + +import java.util.HashMap; +import java.util.Map; + +import com.minelittlepony.unicopia.block.FancyBedBlock; +import com.minelittlepony.unicopia.block.cloud.CloudBedBlock; + +import net.minecraft.block.BlockState; +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.item.Item; +import net.minecraft.item.ItemUsageContext; +import net.minecraft.item.Items; +import net.minecraft.sound.SoundCategory; +import net.minecraft.sound.SoundEvents; +import net.minecraft.util.ActionResult; +import net.minecraft.util.math.BlockPos; +import net.minecraft.world.World; + +public class BedsheetsItem extends Item { + private static final Map ITEMS = new HashMap<>(); + + private final CloudBedBlock.SheetPattern pattern; + + public static Item forPattern(CloudBedBlock.SheetPattern pattern) { + return ITEMS.getOrDefault(pattern, Items.AIR); + } + + public BedsheetsItem(CloudBedBlock.SheetPattern pattern, Settings settings) { + super(settings); + this.pattern = pattern; + ITEMS.put(pattern, this); + } + + @Override + public ActionResult useOnBlock(ItemUsageContext context) { + World world = context.getWorld(); + BlockPos pos = context.getBlockPos(); + BlockState state = world.getBlockState(pos); + + if (state.getBlock() instanceof FancyBedBlock) { + FancyBedBlock.setBedPattern(world, context.getBlockPos(), pattern); + context.getStack().decrement(1); + PlayerEntity player = context.getPlayer(); + world.playSound(player, pos, SoundEvents.ITEM_ARMOR_EQUIP_GENERIC, SoundCategory.BLOCKS, 1, 1); + + return ActionResult.success(world.isClient); + } + + return ActionResult.PASS; + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/item/DrinkableItem.java b/src/main/java/com/minelittlepony/unicopia/item/DrinkableItem.java index a9394c3c..23fa0dd1 100644 --- a/src/main/java/com/minelittlepony/unicopia/item/DrinkableItem.java +++ b/src/main/java/com/minelittlepony/unicopia/item/DrinkableItem.java @@ -2,11 +2,8 @@ package com.minelittlepony.unicopia.item; import java.util.Optional; -import com.minelittlepony.unicopia.item.toxin.ToxicHolder; - import net.minecraft.advancement.criterion.Criteria; import net.minecraft.entity.LivingEntity; -import net.minecraft.entity.player.PlayerEntity; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import net.minecraft.server.network.ServerPlayerEntity; @@ -21,18 +18,13 @@ public class DrinkableItem extends Item { @Override public ItemStack finishUsing(ItemStack stack, World world, LivingEntity user) { + super.finishUsing(stack, world, user); if (user instanceof ServerPlayerEntity) { ServerPlayerEntity serverPlayerEntity = (ServerPlayerEntity)user; Criteria.CONSUME_ITEM.trigger(serverPlayerEntity, stack); serverPlayerEntity.incrementStat(Stats.USED.getOrCreateStat(this)); } - ((ToxicHolder)this).getToxic(stack).finishUsing(stack, world, user); - - if (user instanceof PlayerEntity && !((PlayerEntity)user).getAbilities().creativeMode) { - stack.decrement(1); - } - return stack.isEmpty() ? Optional.ofNullable(getRecipeRemainder()).map(Item::getDefaultStack).orElse(ItemStack.EMPTY) : stack; } diff --git a/src/main/java/com/minelittlepony/unicopia/item/FancyBedItem.java b/src/main/java/com/minelittlepony/unicopia/item/FancyBedItem.java new file mode 100644 index 00000000..cc63ea79 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/item/FancyBedItem.java @@ -0,0 +1,41 @@ +package com.minelittlepony.unicopia.item; + +import java.util.function.Supplier; + +import org.jetbrains.annotations.Nullable; + +import com.google.common.base.Suppliers; +import com.minelittlepony.unicopia.block.FancyBedBlock; + +import net.minecraft.block.Block; +import net.minecraft.block.BlockEntityProvider; +import net.minecraft.block.entity.BlockEntity; +import net.minecraft.item.BedItem; +import net.minecraft.item.ItemStack; +import net.minecraft.nbt.NbtCompound; +import net.minecraft.nbt.NbtElement; +import net.minecraft.util.math.BlockPos; + +public class FancyBedItem extends BedItem implements Supplier { + + private final Supplier renderEntity; + + public FancyBedItem(Block block, Settings settings) { + super(block, settings); + this.renderEntity = Suppliers.memoize(() -> ((BlockEntityProvider)block).createBlockEntity(BlockPos.ORIGIN, block.getDefaultState())); + } + + @Override + public BlockEntity get() { + return renderEntity.get(); + } + + public static FancyBedBlock.SheetPattern getPattern(ItemStack stack) { + @Nullable + NbtCompound blockEntityNbt = getBlockEntityNbt(stack); + if (blockEntityNbt == null || !blockEntityNbt.contains("pattern", NbtElement.STRING_TYPE)) { + return FancyBedBlock.SheetPattern.NONE; + } + return FancyBedBlock.SheetPattern.byId(blockEntityNbt.getString("pattern")); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/item/FriendshipBraceletItem.java b/src/main/java/com/minelittlepony/unicopia/item/FriendshipBraceletItem.java index 5575d357..326ddd43 100644 --- a/src/main/java/com/minelittlepony/unicopia/item/FriendshipBraceletItem.java +++ b/src/main/java/com/minelittlepony/unicopia/item/FriendshipBraceletItem.java @@ -10,6 +10,7 @@ import com.minelittlepony.unicopia.EquinePredicates; import com.minelittlepony.unicopia.USounds; import com.minelittlepony.unicopia.ability.magic.Caster; import com.minelittlepony.unicopia.compat.trinkets.TrinketsDelegate; +import com.minelittlepony.unicopia.entity.AmuletSelectors; import com.minelittlepony.unicopia.entity.player.Pony; import net.fabricmc.api.EnvType; @@ -37,7 +38,7 @@ public class FriendshipBraceletItem extends WearableItem implements DyeableItem, public TypedActionResult use(World world, PlayerEntity player, Hand hand) { ItemStack stack = player.getStackInHand(hand); - if (!isSigned(stack) && EquinePredicates.PLAYER_UNICORN.test(player)) { + if (!isSigned(stack) && (EquinePredicates.PLAYER_UNICORN.test(player) || AmuletSelectors.PEARL_NECKLACE.test(player))) { player.setCurrentHand(hand); ItemStack result = stack.copy(); diff --git a/src/main/java/com/minelittlepony/unicopia/item/ItemDuck.java b/src/main/java/com/minelittlepony/unicopia/item/ItemDuck.java new file mode 100644 index 00000000..ee280da5 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/item/ItemDuck.java @@ -0,0 +1,16 @@ +package com.minelittlepony.unicopia.item; + +import java.util.Optional; + +import com.minelittlepony.unicopia.entity.ItemImpl; +import net.minecraft.item.*; + +public interface ItemDuck extends ItemConvertible, ItemImpl.TickableItem { + void setFoodComponent(FoodComponent food); + + Optional getOriginalFoodComponent(); + + default void resetFoodComponent() { + setFoodComponent(getOriginalFoodComponent().orElse(null)); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/item/toxin/UFoodComponents.java b/src/main/java/com/minelittlepony/unicopia/item/UFoodComponents.java similarity index 93% rename from src/main/java/com/minelittlepony/unicopia/item/toxin/UFoodComponents.java rename to src/main/java/com/minelittlepony/unicopia/item/UFoodComponents.java index d690af7c..24dcf544 100644 --- a/src/main/java/com/minelittlepony/unicopia/item/toxin/UFoodComponents.java +++ b/src/main/java/com/minelittlepony/unicopia/item/UFoodComponents.java @@ -1,4 +1,4 @@ -package com.minelittlepony.unicopia.item.toxin; +package com.minelittlepony.unicopia.item; import net.minecraft.entity.effect.StatusEffectInstance; import net.minecraft.entity.effect.StatusEffects; @@ -23,7 +23,9 @@ public interface UFoodComponents { FoodComponent JUICE = builder(2, 1.8F).alwaysEdible().build(); FoodComponent BURNED_JUICE = builder(3, 1).build(); + @Deprecated FoodComponent RANDOM_FOLIAGE = builder(2, 1).build(); + @Deprecated FoodComponent RANDOM_FOLIAGE_FILLING = builder(18, 1).build(); FoodComponent WORMS = builder(1, 1.5F).alwaysEdible().meat().build(); FoodComponent INSECTS = builder(1, 0).alwaysEdible().build(); @@ -51,6 +53,11 @@ public interface UFoodComponents { FoodComponent CANDY = builder(7, 0.9F).alwaysEdible().build(); FoodComponent SALT_CUBE = builder(0, 2.9F).alwaysEdible().build(); + @Deprecated + FoodComponent SHELL = builder(3, 5).build(); + @Deprecated + FoodComponent SHELLY = builder(6, 7).build(); + static FoodComponent.Builder builder(int hunger, float saturation) { return new FoodComponent.Builder() .hunger(hunger) diff --git a/src/main/java/com/minelittlepony/unicopia/item/UItems.java b/src/main/java/com/minelittlepony/unicopia/item/UItems.java index 8da9d346..e9863be6 100644 --- a/src/main/java/com/minelittlepony/unicopia/item/UItems.java +++ b/src/main/java/com/minelittlepony/unicopia/item/UItems.java @@ -2,15 +2,16 @@ package com.minelittlepony.unicopia.item; import com.google.common.collect.ImmutableMultimap; import com.minelittlepony.unicopia.*; +import com.minelittlepony.unicopia.block.FancyBedBlock.SheetPattern; import com.minelittlepony.unicopia.block.UBlocks; import com.minelittlepony.unicopia.block.UWoodTypes; +import com.minelittlepony.unicopia.block.cloud.CloudBedBlock; import com.minelittlepony.unicopia.entity.mob.AirBalloonEntity; import com.minelittlepony.unicopia.entity.mob.UEntities; import com.minelittlepony.unicopia.item.cloud.CloudBedItem; import com.minelittlepony.unicopia.item.enchantment.UEnchantments; import com.minelittlepony.unicopia.item.group.ItemGroupRegistry; import com.minelittlepony.unicopia.item.group.UItemGroups; -import com.minelittlepony.unicopia.item.toxin.UFoodComponents; import com.terraformersmc.terraform.boat.api.TerraformBoatType; import com.terraformersmc.terraform.boat.api.TerraformBoatTypeRegistry; import com.terraformersmc.terraform.boat.api.item.TerraformBoatItemHelper; @@ -139,7 +140,8 @@ public interface UItems { Item DIAMOND_POLEARM = register("diamond_polearm", new PolearmItem(ToolMaterials.DIAMOND, 2, -3.6F, 5, new Item.Settings()), ItemGroups.COMBAT); Item NETHERITE_POLEARM = register("netherite_polearm", new PolearmItem(ToolMaterials.NETHERITE, 2, -3.6F, 5, new Item.Settings().fireproof()), ItemGroups.COMBAT); - Item BUTTERFLY_SPAWN_EGG = register("butterfly_spawn_egg", new SpawnEggItem(UEntities.BUTTERFLY, 0x222200, 0xaaeeff, new Item.Settings()), ItemGroups.SPAWN_EGGS); + Item LOOT_BUG_SPAWN_EGG = register("loot_bug_spawn_egg", new SpawnEggItem(UEntities.LOOT_BUG, 0x3C9D14, 0xE66F16, new Item.Settings()), ItemGroups.SPAWN_EGGS); + Item BUTTERFLY_SPAWN_EGG = register("butterfly_spawn_egg", new SpawnEggItem(UEntities.BUTTERFLY, 0x222200, 0xAAEEFF, new Item.Settings()), ItemGroups.SPAWN_EGGS); Item BUTTERFLY = register("butterfly", new Item(new Item.Settings().food(UFoodComponents.INSECTS)), ItemGroups.FOOD_AND_DRINK); Item PALM_BOAT = ItemGroupRegistry.register(TerraformBoatItemHelper.registerBoatItem(Unicopia.id("palm_boat"), UWoodTypes.PALM_BOAT_TYPE, false), ItemGroups.FUNCTIONAL); @@ -160,6 +162,32 @@ public interface UItems { Item GIANT_BALLOON = register("giant_balloon", new HotAirBalloonItem(new Item.Settings().maxCount(1)), ItemGroups.TOOLS); + Item LIGHT_GRAY_BED_SHEETS = register(CloudBedBlock.SheetPattern.LIGHT_GRAY); + Item GRAY_BED_SHEETS = register(CloudBedBlock.SheetPattern.GRAY); + Item BLACK_BED_SHEETS = register(CloudBedBlock.SheetPattern.BLACK); + Item BROWN_BED_SHEETS = register(CloudBedBlock.SheetPattern.BROWN); + Item RED_BED_SHEETS = register(CloudBedBlock.SheetPattern.RED); + Item ORANGE_BED_SHEETS = register(CloudBedBlock.SheetPattern.ORANGE); + Item YELLOW_BED_SHEETS = register(CloudBedBlock.SheetPattern.YELLOW); + Item LIME_BED_SHEETS = register(CloudBedBlock.SheetPattern.LIME); + Item GREEN_BED_SHEETS = register(CloudBedBlock.SheetPattern.GREEN); + Item CYAN_BED_SHEETS = register(CloudBedBlock.SheetPattern.CYAN); + Item LIGHT_BLUE_BED_SHEETS = register(CloudBedBlock.SheetPattern.LIGHT_BLUE); + Item BLUE_SHEETS = register(CloudBedBlock.SheetPattern.BLUE); + Item PURPLE_BED_SHEETS = register(CloudBedBlock.SheetPattern.PURPLE); + Item MAGENTA_BED_SHEETS = register(CloudBedBlock.SheetPattern.MAGENTA); + Item PINK_BED_SHEETS = register(CloudBedBlock.SheetPattern.PINK); + + Item APPLE_BED_SHEETS = register(CloudBedBlock.SheetPattern.APPLE); + Item BARRED_BED_SHEETS = register("barred_bed_sheets", new BedsheetsItem(CloudBedBlock.SheetPattern.BARS, new Item.Settings().maxCount(1)), ItemGroups.FUNCTIONAL); + Item CHECKERED_BED_SHEETS = register("checkered_bed_sheets", new BedsheetsItem(CloudBedBlock.SheetPattern.CHECKER, new Item.Settings().maxCount(1)), ItemGroups.FUNCTIONAL); + Item KELP_BED_SHEETS = register(CloudBedBlock.SheetPattern.KELP); + Item RAINBOW_BED_SHEETS = register(CloudBedBlock.SheetPattern.RAINBOW); + Item RAINBOW_BPW_BED_SHEETS = register(CloudBedBlock.SheetPattern.RAINBOW_BPW); + Item RAINBOW_BPY_BED_SHEETS = register(CloudBedBlock.SheetPattern.RAINBOW_BPY); + Item RAINBOW_PBG_BED_SHEETS = register(CloudBedBlock.SheetPattern.RAINBOW_PBG); + Item RAINBOW_PWR_BED_SHEETS = register(CloudBedBlock.SheetPattern.RAINBOW_PWR); + AmuletItem PEGASUS_AMULET = register("pegasus_amulet", new PegasusAmuletItem(new FabricItemSettings() .maxCount(1) .maxDamage(890) @@ -173,13 +201,22 @@ public interface UItems { .maxCount(1) .maxDamage(890) .rarity(Rarity.UNCOMMON), 0), ItemGroups.TOOLS); + AmuletItem PEARL_NECKLACE = register("pearl_necklace", new AmuletItem(new FabricItemSettings() + .maxCount(1) + .rarity(Rarity.UNCOMMON), 0), ItemGroups.TOOLS); GlassesItem SUNGLASSES = register("sunglasses", new GlassesItem(new FabricItemSettings().maxCount(1)), ItemGroups.COMBAT); GlassesItem BROKEN_SUNGLASSES = register("broken_sunglasses", new GlassesItem(new FabricItemSettings().maxCount(1)), ItemGroups.COMBAT); + Item CLAM_SHELL = register("clam_shell", new Item(new Item.Settings()), ItemGroups.INGREDIENTS); + Item SCALLOP_SHELL = register("scallop_shell", new Item(new Item.Settings()), ItemGroups.INGREDIENTS); + Item TURRET_SHELL = register("turret_shell", new Item(new Item.Settings()), ItemGroups.INGREDIENTS); + Item SHELLY = register("shelly", new Item(new Item.Settings()), ItemGroups.INGREDIENTS); Item CARAPACE = register("carapace", new Item(new Item.Settings()), ItemGroups.INGREDIENTS); + Item CLOTH_BED = register("cloth_bed", new FancyBedItem(UBlocks.CLOTH_BED, new Item.Settings().maxCount(1)), ItemGroups.FUNCTIONAL); Item CLOUD_BED = register("cloud_bed", new CloudBedItem(UBlocks.CLOUD_BED, new Item.Settings().maxCount(1)), ItemGroups.FUNCTIONAL); + Item CLOUD_LUMP = register("cloud_lump", new Item(new Item.Settings()), ItemGroups.NATURAL); Item ALICORN_BADGE = register(Race.ALICORN); Item PEGASUS_BADGE = register(Race.PEGASUS); @@ -188,6 +225,7 @@ public interface UItems { Item BAT_BADGE = register(Race.BAT); Item CHANGELING_BADGE = register(Race.CHANGELING); Item KIRIN_BADGE = register(Race.KIRIN); + Item HIPPOGRIFF_BADGE = register(Race.HIPPOGRIFF); private static T register(String name, T item, RegistryKey group) { return ItemGroupRegistry.register(Unicopia.id(name), item, group); @@ -208,6 +246,10 @@ public interface UItems { return Registry.register(Registries.ITEM, race.getId().withPath(p -> p + "_badge"), new Item(new Settings())); } + static Item register(SheetPattern pattern) { + return register(pattern.asString() + "_bed_sheets", new BedsheetsItem(pattern, new Item.Settings().maxCount(1)), ItemGroups.FUNCTIONAL); + } + static void bootstrap() { AppleItem.registerTickCallback(Items.APPLE); FuelRegistry.INSTANCE.add(WOODEN_POLEARM, 200); diff --git a/src/main/java/com/minelittlepony/unicopia/item/URecipes.java b/src/main/java/com/minelittlepony/unicopia/item/URecipes.java index 14648158..c85ddd22 100644 --- a/src/main/java/com/minelittlepony/unicopia/item/URecipes.java +++ b/src/main/java/com/minelittlepony/unicopia/item/URecipes.java @@ -3,16 +3,19 @@ package com.minelittlepony.unicopia.item; import com.minelittlepony.unicopia.ability.magic.spell.crafting.*; import com.mojang.serialization.Codec; import com.mojang.serialization.DataResult; +import com.minelittlepony.unicopia.item.cloud.CloudShapingRecipe; import net.fabricmc.fabric.api.loot.v2.LootTableEvents; import net.minecraft.loot.LootPool; import net.minecraft.loot.LootTable; import net.minecraft.loot.context.LootContextTypes; +import net.minecraft.recipe.CuttingRecipe; import net.minecraft.recipe.Ingredient; import net.minecraft.recipe.RecipeSerializer; import net.minecraft.recipe.RecipeType; import net.minecraft.recipe.ShapedRecipe; import net.minecraft.recipe.SpecialRecipeSerializer; +import net.minecraft.recipe.StonecuttingRecipe; import net.minecraft.util.Identifier; import net.minecraft.util.collection.DefaultedList; @@ -29,6 +32,7 @@ public interface URecipes { }, DataResult::success); RecipeType SPELLBOOK = RecipeType.register("unicopia:spellbook"); + RecipeType CLOUD_SHAPING = RecipeType.register("unicopia:cloud_shaping"); RecipeSerializer ZAP_APPLE_SERIALIZER = RecipeSerializer.register("unicopia:crafting_zap_apple", new ZapAppleRecipe.Serializer()); RecipeSerializer GLOWING_SERIALIZER = RecipeSerializer.register("unicopia:crafting_glowing", new SpecialRecipeSerializer<>(GlowingRecipe::new)); @@ -38,6 +42,7 @@ public interface URecipes { RecipeSerializer TRAIT_REQUIREMENT = RecipeSerializer.register("unicopia:spellbook/crafting", new SpellCraftingRecipe.Serializer()); RecipeSerializer TRAIT_COMBINING = RecipeSerializer.register("unicopia:spellbook/combining", new SpellEnhancingRecipe.Serializer()); RecipeSerializer SPELL_DUPLICATING = RecipeSerializer.register("unicopia:spellbook/duplicating", new SpellDuplicatingRecipe.Serializer()); + RecipeSerializer CLOUD_SHAPING_SERIALIZER = RecipeSerializer.register("unicopia:cloud_shaping", new CuttingRecipe.Serializer<>(CloudShapingRecipe::new) {}); static void bootstrap() { LootTableEvents.MODIFY.register((res, manager, id, supplier, setter) -> { diff --git a/src/main/java/com/minelittlepony/unicopia/item/WearableItem.java b/src/main/java/com/minelittlepony/unicopia/item/WearableItem.java index d830e558..23150589 100644 --- a/src/main/java/com/minelittlepony/unicopia/item/WearableItem.java +++ b/src/main/java/com/minelittlepony/unicopia/item/WearableItem.java @@ -51,11 +51,11 @@ public abstract class WearableItem extends Item implements Equipment { @Override public final EquipmentSlot getSlotType() { - return EquipmentSlot.OFFHAND; + return getSlotType(getDefaultStack()); } public EquipmentSlot getSlotType(ItemStack stack) { - return getSlotType(); + return EquipmentSlot.OFFHAND; } public static boolean dispenseArmor(BlockPointer pointer, ItemStack armor) { diff --git a/src/main/java/com/minelittlepony/unicopia/item/ZapAppleItem.java b/src/main/java/com/minelittlepony/unicopia/item/ZapAppleItem.java index e2e60e79..711cbec8 100644 --- a/src/main/java/com/minelittlepony/unicopia/item/ZapAppleItem.java +++ b/src/main/java/com/minelittlepony/unicopia/item/ZapAppleItem.java @@ -9,7 +9,6 @@ import com.minelittlepony.unicopia.entity.Living; import com.minelittlepony.unicopia.entity.damage.UDamageTypes; import com.minelittlepony.unicopia.entity.player.Pony; import com.minelittlepony.unicopia.item.group.MultiItem; -import com.minelittlepony.unicopia.item.toxin.*; import com.minelittlepony.unicopia.particle.LightningBoltParticleEffect; import com.minelittlepony.unicopia.particle.ParticleUtils; import com.minelittlepony.unicopia.util.TraceHelper; @@ -36,7 +35,7 @@ import net.minecraft.registry.Registries; import net.minecraft.world.World; import net.minecraft.world.event.GameEvent; -public class ZapAppleItem extends Item implements ChameleonItem, ToxicHolder, MultiItem { +public class ZapAppleItem extends Item implements ChameleonItem, MultiItem { public ZapAppleItem(Settings settings) { super(settings); } @@ -117,11 +116,6 @@ public class ZapAppleItem extends Item implements ChameleonItem, ToxicHolder, Mu return hasAppearance(stack) ? getAppearanceStack(stack).getName() : super.getName(stack); } - @Override - public Toxic getToxic(ItemStack stack) { - return hasAppearance(stack) ? Toxics.SEVERE_INNERT : Toxics.FORAGE_EDIBLE; - } - @Override public Rarity getRarity(ItemStack stack) { if (hasAppearance(stack)) { diff --git a/src/main/java/com/minelittlepony/unicopia/item/cloud/CloudBedItem.java b/src/main/java/com/minelittlepony/unicopia/item/cloud/CloudBedItem.java index 70ddf324..50602d41 100644 --- a/src/main/java/com/minelittlepony/unicopia/item/cloud/CloudBedItem.java +++ b/src/main/java/com/minelittlepony/unicopia/item/cloud/CloudBedItem.java @@ -11,7 +11,7 @@ import net.minecraft.block.entity.BlockEntity; import net.minecraft.item.ItemPlacementContext; import net.minecraft.util.math.BlockPos; -public class CloudBedItem extends CloudBlockItem { +public class CloudBedItem extends CloudBlockItem implements Supplier { private final Supplier renderEntity; @@ -25,7 +25,8 @@ public class CloudBedItem extends CloudBlockItem { return context.getWorld().setBlockState(context.getBlockPos(), state, Block.NOTIFY_LISTENERS | Block.REDRAW_ON_MAIN_THREAD | Block.FORCE_STATE); } - public BlockEntity getRenderEntity() { + @Override + public BlockEntity get() { return renderEntity.get(); } } diff --git a/src/main/java/com/minelittlepony/unicopia/item/cloud/CloudShapingRecipe.java b/src/main/java/com/minelittlepony/unicopia/item/cloud/CloudShapingRecipe.java new file mode 100644 index 00000000..048f98e1 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/item/cloud/CloudShapingRecipe.java @@ -0,0 +1,31 @@ +package com.minelittlepony.unicopia.item.cloud; + +import com.minelittlepony.unicopia.block.UBlocks; +import com.minelittlepony.unicopia.item.URecipes; + +import net.minecraft.item.ItemStack; +import net.minecraft.recipe.Ingredient; +import net.minecraft.recipe.RecipeSerializer; +import net.minecraft.recipe.RecipeType; +import net.minecraft.recipe.StonecuttingRecipe; + +public class CloudShapingRecipe extends StonecuttingRecipe { + public CloudShapingRecipe(String group, Ingredient input, ItemStack output) { + super(group, input, output); + } + + @Override + public RecipeType getType() { + return URecipes.CLOUD_SHAPING; + } + + @Override + public RecipeSerializer getSerializer() { + return URecipes.CLOUD_SHAPING_SERIALIZER; + } + + @Override + public ItemStack createIcon() { + return new ItemStack(UBlocks.SHAPING_BENCH); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/item/group/UItemGroups.java b/src/main/java/com/minelittlepony/unicopia/item/group/UItemGroups.java index 9fe298f6..a1f0efae 100644 --- a/src/main/java/com/minelittlepony/unicopia/item/group/UItemGroups.java +++ b/src/main/java/com/minelittlepony/unicopia/item/group/UItemGroups.java @@ -17,6 +17,7 @@ public interface UItemGroups { RegistryKey UNICORN_ITEMS = ItemGroupRegistry.createGroupFromTag("unicorn", UItems.UNICORN_BADGE::getDefaultStack); RegistryKey PEGASUS_ITEMS = ItemGroupRegistry.createGroupFromTag("pegasus", UItems.PEGASUS_BADGE::getDefaultStack); RegistryKey BAT_PONY_ITEMS = ItemGroupRegistry.createGroupFromTag("bat_pony", UItems.BAT_BADGE::getDefaultStack); + RegistryKey SEA_PON_ITEMS = ItemGroupRegistry.createGroupFromTag("sea_pony", UItems.PEARL_NECKLACE::getDefaultStack); RegistryKey CHANGELING_ITEMS = ItemGroupRegistry.createGroupFromTag("changeling", UItems.CHANGELING_BADGE::getDefaultStack); static void bootstrap() { diff --git a/src/main/java/com/minelittlepony/unicopia/item/toxin/Affliction.java b/src/main/java/com/minelittlepony/unicopia/item/toxin/Affliction.java deleted file mode 100644 index f2350be5..00000000 --- a/src/main/java/com/minelittlepony/unicopia/item/toxin/Affliction.java +++ /dev/null @@ -1,12 +0,0 @@ -package com.minelittlepony.unicopia.item.toxin; - -import net.minecraft.entity.player.PlayerEntity; -import net.minecraft.item.ItemStack; - -public interface Affliction { - void afflict(PlayerEntity player, ItemStack stack); - - interface Predicate { - boolean test(PlayerEntity player, ItemStack stack); - } -} diff --git a/src/main/java/com/minelittlepony/unicopia/item/toxin/Ailment.java b/src/main/java/com/minelittlepony/unicopia/item/toxin/Ailment.java deleted file mode 100644 index 0433df21..00000000 --- a/src/main/java/com/minelittlepony/unicopia/item/toxin/Ailment.java +++ /dev/null @@ -1,63 +0,0 @@ -package com.minelittlepony.unicopia.item.toxin; - -import java.util.*; - -import com.minelittlepony.unicopia.Race; -import com.minelittlepony.unicopia.entity.player.Pony; - -import net.minecraft.client.item.TooltipContext; -import net.minecraft.entity.LivingEntity; -import net.minecraft.entity.player.PlayerEntity; -import net.minecraft.item.ItemStack; -import net.minecraft.text.Text; -import net.minecraft.util.Hand; -import net.minecraft.util.TypedActionResult; -import net.minecraft.world.World; - -public record Ailment ( - Toxicity toxicity, - Toxin effect - ) { - public static final Ailment INNERT = of(Toxicity.SAFE, Toxin.INNERT); - - public static Ailment of(Toxicity toxicity, Toxin effect) { - return new Ailment(toxicity, effect); - } - - public void appendTooltip(List tooltip, TooltipContext context) { - tooltip.add(toxicity().getTooltip()); - if (context.isAdvanced()) { - effect().appendTooltip(tooltip); - } - } - - public ItemStack finishUsing(ItemStack stack, World world, LivingEntity entity) { - effect().afflict((PlayerEntity)entity, stack); - return stack; - } - - public TypedActionResult use(World world, PlayerEntity player, Hand hand) { - if (!Pony.of(player).getObservedSpecies().hasIronGut()) { - return TypedActionResult.fail(player.getStackInHand(hand)); - } - return null; - } - - public interface Set { - Set EMPTY = e -> Optional.empty(); - - Optional get(LivingEntity entity); - - static Ailment.Set of(Ailment def, Map map) { - if (map.isEmpty()) { - return of(def); - } - return entity -> Optional.of(entity instanceof PlayerEntity player ? map.getOrDefault(Pony.of(player).getObservedSpecies(), def) : def); - } - - static Ailment.Set of(Ailment ailment) { - final Optional value = Optional.of(ailment); - return entity -> value; - } - } -} diff --git a/src/main/java/com/minelittlepony/unicopia/item/toxin/ItemDuck.java b/src/main/java/com/minelittlepony/unicopia/item/toxin/ItemDuck.java deleted file mode 100644 index 4ff27425..00000000 --- a/src/main/java/com/minelittlepony/unicopia/item/toxin/ItemDuck.java +++ /dev/null @@ -1,9 +0,0 @@ -package com.minelittlepony.unicopia.item.toxin; - -import com.minelittlepony.unicopia.entity.ItemImpl; - -import net.minecraft.item.*; - -public interface ItemDuck extends ItemConvertible, ToxicHolder, ItemImpl.TickableItem { - void setFoodComponent(FoodComponent food); -} diff --git a/src/main/java/com/minelittlepony/unicopia/item/toxin/Toxic.java b/src/main/java/com/minelittlepony/unicopia/item/toxin/Toxic.java deleted file mode 100644 index 2395e8ba..00000000 --- a/src/main/java/com/minelittlepony/unicopia/item/toxin/Toxic.java +++ /dev/null @@ -1,68 +0,0 @@ -package com.minelittlepony.unicopia.item.toxin; - -import java.util.*; - -import com.minelittlepony.unicopia.Race; -import net.minecraft.client.item.TooltipContext; -import net.minecraft.entity.LivingEntity; -import net.minecraft.entity.player.PlayerEntity; -import net.minecraft.item.FoodComponent; -import net.minecraft.item.ItemStack; -import net.minecraft.text.Text; -import net.minecraft.util.UseAction; -import net.minecraft.world.World; - -public record Toxic ( - Optional useAction, - Optional component, - Ailment.Set ailment - ) { - public void appendTooltip(PlayerEntity player, List tooltip, TooltipContext context) { - ailment.get(player).ifPresent(ailment -> ailment.appendTooltip(tooltip, context)); - } - - public ItemStack finishUsing(ItemStack stack, World world, LivingEntity entity) { - if (entity instanceof PlayerEntity player) { - ailment.get(entity).ifPresent(ailment -> ailment.effect().afflict(player, stack)); - } - return stack; - } - - public static Toxic innert(Toxicity toxicity) { - return new Builder(Ailment.of(toxicity, Toxin.INNERT)).build(); - } - - public static class Builder { - private final Ailment def; - private final Map overrides = new HashMap<>(); - private Optional action = Optional.of(UseAction.EAT); - private Optional component = Optional.empty(); - - public Builder(Ailment def) { - this.def = def; - } - - public Builder action(UseAction action) { - this.action = Optional.of(action); - return this; - } - - public Builder food(FoodComponent food) { - component = Optional.ofNullable(food); - return this; - } - - public Builder with(Race race, Ailment ailment) { - overrides.put(race, ailment); - return this; - } - - public Toxic build() { - return new Toxic(action, component, Ailment.Set.of(def, overrides)); - } - - public Optional buildOptional() { - return Optional.of(build()); - } - } -} diff --git a/src/main/java/com/minelittlepony/unicopia/item/toxin/ToxicHolder.java b/src/main/java/com/minelittlepony/unicopia/item/toxin/ToxicHolder.java deleted file mode 100644 index 466b7b15..00000000 --- a/src/main/java/com/minelittlepony/unicopia/item/toxin/ToxicHolder.java +++ /dev/null @@ -1,7 +0,0 @@ -package com.minelittlepony.unicopia.item.toxin; - -import net.minecraft.item.*; - -public interface ToxicHolder { - Toxic getToxic(ItemStack stack); -} diff --git a/src/main/java/com/minelittlepony/unicopia/item/toxin/ToxicRegistryEntry.java b/src/main/java/com/minelittlepony/unicopia/item/toxin/ToxicRegistryEntry.java deleted file mode 100644 index 2db1d93f..00000000 --- a/src/main/java/com/minelittlepony/unicopia/item/toxin/ToxicRegistryEntry.java +++ /dev/null @@ -1,16 +0,0 @@ -package com.minelittlepony.unicopia.item.toxin; - -import net.minecraft.item.Item; -import net.minecraft.registry.tag.TagKey; - -public record ToxicRegistryEntry ( - Toxic value, - TagKey tag - ) { - - @SuppressWarnings("deprecation") - public boolean matches(Item item) { - return item.getRegistryEntry().isIn(tag); - } - -} diff --git a/src/main/java/com/minelittlepony/unicopia/item/toxin/Toxicity.java b/src/main/java/com/minelittlepony/unicopia/item/toxin/Toxicity.java deleted file mode 100644 index f901adac..00000000 --- a/src/main/java/com/minelittlepony/unicopia/item/toxin/Toxicity.java +++ /dev/null @@ -1,37 +0,0 @@ -package com.minelittlepony.unicopia.item.toxin; - -import java.util.Arrays; -import java.util.Map; -import java.util.function.Function; -import java.util.stream.Collectors; - -import net.minecraft.text.Text; -import net.minecraft.util.Formatting; - -public enum Toxicity { - SAFE(Formatting.GRAY), - MILD(Formatting.DARK_AQUA), - FAIR(Formatting.DARK_BLUE), - SEVERE(Formatting.DARK_PURPLE), - LETHAL(Formatting.RED); - - private static final Map REGISTRY = Arrays.stream(values()).collect(Collectors.toMap(Toxicity::name, Function.identity())); - - private final Formatting color; - - Toxicity(Formatting color) { - this.color = color; - } - - public String getTranslationKey() { - return String.format("toxicity.%s.name", name().toLowerCase()); - } - - public Text getTooltip() { - return Text.translatable(getTranslationKey()).formatted(color); - } - - public static Toxicity byName(String name) { - return REGISTRY.get(name.toUpperCase()); - } -} diff --git a/src/main/java/com/minelittlepony/unicopia/item/toxin/Toxics.java b/src/main/java/com/minelittlepony/unicopia/item/toxin/Toxics.java deleted file mode 100644 index 051b9f73..00000000 --- a/src/main/java/com/minelittlepony/unicopia/item/toxin/Toxics.java +++ /dev/null @@ -1,156 +0,0 @@ -package com.minelittlepony.unicopia.item.toxin; - -import com.minelittlepony.unicopia.*; -import com.minelittlepony.unicopia.util.RegistryUtils; - -import net.minecraft.item.FoodComponent; -import net.minecraft.registry.Registry; - -import static com.minelittlepony.unicopia.item.toxin.Toxicity.*; -import static com.minelittlepony.unicopia.item.toxin.Ailment.*; -import static com.minelittlepony.unicopia.item.toxin.Toxin.*; - -import java.util.Optional; -import org.jetbrains.annotations.Nullable; - -public interface Toxics { - Registry REGISTRY = RegistryUtils.createSimple(Unicopia.id("toxic")); - - Toxic EMPTY = new Toxic(Optional.empty(), Optional.empty(), Ailment.Set.EMPTY); - - Toxic SEVERE_INNERT = Toxic.innert(Toxicity.SEVERE); - - Toxic EDIBLE = register("edible", new Toxic.Builder(Ailment.INNERT) - .with(Race.CHANGELING, of(FAIR, LOVE_SICKNESS)) - ); - - Toxic FORAGE_EDIBLE = register("forage_edible", new Toxic.Builder(Ailment.INNERT) - .food(UFoodComponents.RANDOM_FOLIAGE) - .with(Race.HUMAN, of(LETHAL, FOOD_POISONING)) - .with(Race.CHANGELING, of(FAIR, LOVE_SICKNESS)) - ); - - Toxic FORAGE_EDIBLE_FILLING = register("forage_edible_filling", new Toxic.Builder(Ailment.INNERT) - .food(UFoodComponents.RANDOM_FOLIAGE_FILLING) - .with(Race.HUMAN, of(LETHAL, FOOD_POISONING)) - .with(Race.CHANGELING, of(FAIR, LOVE_SICKNESS)) - ); - - Toxic FORAGE_RISKY = register("forage_risky", new Toxic.Builder(of(FAIR, FOOD_POISONING.withChance(20))) - .food(UFoodComponents.RANDOM_FOLIAGE) - .with(Race.HUMAN, of(LETHAL, FOOD_POISONING)) - ); - Toxic FORAGE_MODERATE = register("forage_moderate", new Toxic.Builder(of(MILD, FOOD_POISONING)) - .food(UFoodComponents.RANDOM_FOLIAGE) - .with(Race.HUMAN, of(LETHAL, STRONG_FOOD_POISONING)) - ); - Toxic FORAGE_DANGEROUS = register("forage_dangerous", new Toxic.Builder(of(SEVERE, FOOD_POISONING)) - .food(UFoodComponents.RANDOM_FOLIAGE) - .with(Race.HUMAN, of(LETHAL, FOOD_POISONING)) - ); - Toxic FORAGE_NAUSEATING = register("forage_nauseating", new Toxic.Builder(of(SAFE, FOOD_POISONING.and(WEAKNESS.withChance(30)))) - .food(UFoodComponents.RANDOM_FOLIAGE) - .with(Race.HUMAN, of(LETHAL, FOOD_POISONING)) - ); - Toxic FORAGE_RADIOACTIVE = register("forage_radioactive", new Toxic.Builder(of(SAFE, FOOD_POISONING.and(GLOWING.withChance(30)))) - .food(UFoodComponents.RANDOM_FOLIAGE) - .with(Race.HUMAN, of(LETHAL, FOOD_POISONING)) - ); - Toxic FORAGE_PRICKLY = register("forage_prickly", new Toxic.Builder(of(SAFE, INSTANT_DAMAGE.withChance(30))) - .food(UFoodComponents.RANDOM_FOLIAGE) - .with(Race.HUMAN, of(LETHAL, FOOD_POISONING)) - .with(Race.KIRIN, Ailment.INNERT) - ); - Toxic FORAGE_STRENGHTENING = register("forage_strengthening", new Toxic.Builder(of(SEVERE, STRENGTH.and(FOOD_POISONING))) - .food(UFoodComponents.RANDOM_FOLIAGE) - .with(Race.HUMAN, of(LETHAL, FOOD_POISONING.and(WEAKNESS))) - .with(Race.KIRIN, Ailment.INNERT) - ); - Toxic FORAGE_SEVERELY_NAUSEATING = register("forage_severely_nauseating", new Toxic.Builder(of(SEVERE, FOOD_POISONING.and(WEAKNESS))) - .food(UFoodComponents.RANDOM_FOLIAGE) - .with(Race.HUMAN, of(LETHAL, FOOD_POISONING.and(WEAKNESS))) - ); - Toxic FORAGE_BLINDING = register("forage_blinding", new Toxic.Builder(of(SEVERE, BLINDNESS.and(FOOD_POISONING))) - .food(UFoodComponents.RANDOM_FOLIAGE) - .with(Race.HUMAN, of(LETHAL, FOOD_POISONING)) - .with(Race.KIRIN, Ailment.INNERT) - ); - Toxic FORAGE_SEVERELY_PRICKLY = register("forage_severely_prickly", new Toxic.Builder(of(SEVERE, FOOD_POISONING.and(INSTANT_DAMAGE))) - .food(UFoodComponents.RANDOM_FOLIAGE) - .with(Race.HUMAN, of(LETHAL, FOOD_POISONING)) - .with(Race.KIRIN, Ailment.INNERT) - ); - Toxic RAW_MEAT = register("raw_meat", new Toxic.Builder(of(SEVERE, FOOD_POISONING.withChance(5).and(CHANCE_OF_POISON))) - .with(Race.HUMAN, Ailment.INNERT) - .with(Race.CHANGELING, Ailment.INNERT) - .with(Race.BAT, of(MILD, FOOD_POISONING)) - .with(Race.KIRIN, Ailment.INNERT) - ); - Toxic ROTTEN_MEAT = register("rotten_meat", new Toxic.Builder(of(SEVERE, STRONG_FOOD_POISONING)) - .with(Race.HUMAN, Ailment.INNERT) - .with(Race.BAT, of(MILD, FOOD_POISONING)) - .with(Race.CHANGELING, Ailment.INNERT) - ); - Toxic COOKED_MEAT = register("cooked_meat", new Toxic.Builder(of(FAIR, FOOD_POISONING)) - .with(Race.HUMAN, Ailment.INNERT) - .with(Race.CHANGELING, Ailment.INNERT) - .with(Race.BAT, Ailment.INNERT) - .with(Race.KIRIN, Ailment.INNERT) - ); - - Toxic RAW_FISH = register("raw_fish", new Toxic.Builder(of(FAIR, FOOD_POISONING.and(CHANCE_OF_POISON))) - .with(Race.HUMAN, Ailment.INNERT) - .with(Race.PEGASUS, of(MILD, FOOD_POISONING)) - .with(Race.ALICORN, Ailment.INNERT) - .with(Race.CHANGELING, of(FAIR, LOVE_SICKNESS)) - ); - Toxic COOKED_FISH = register("cooked_fish", new Toxic.Builder(of(MILD, FOOD_POISONING)) - .with(Race.HUMAN, Ailment.INNERT) - .with(Race.PEGASUS, Ailment.INNERT) - .with(Race.ALICORN, Ailment.INNERT) - .with(Race.CHANGELING, of(FAIR, LOVE_SICKNESS)) - ); - - Toxic RAW_INSECT = register("raw_insect", new Toxic.Builder(of(LETHAL, FOOD_POISONING)) - .with(Race.BAT, of(MILD, WEAK_FOOD_POISONING)) - .with(Race.CHANGELING, Ailment.INNERT) - ); - - Toxic COOKED_INSECT = register("cooked_insect", new Toxic.Builder(of(LETHAL, FOOD_POISONING)) - .food(UFoodComponents.INSECTS) - .with(Race.CHANGELING, Ailment.INNERT) - .with(Race.KIRIN, Ailment.INNERT) - .with(Race.BAT, Ailment.INNERT) - ); - - Toxic LOVE = register("love", new Toxic.Builder(Ailment.INNERT) - .with(Race.CHANGELING, of(Toxicity.SAFE, Toxin.LOVE_CONSUMPTION)) - ); - - Toxic PINECONE = register("pinecone", new Toxic.Builder(of(Toxicity.SAFE, Toxin.healing(1))) - .with(Race.HUMAN, Ailment.INNERT) - ); - - Toxic BAT_PONYS_DELIGHT = register("bat_ponys_delight", new Toxic.Builder(Ailment.INNERT) - .with(Race.BAT, of(Toxicity.SAFE, Toxin.BAT_PONY_INTOXICATION)) - ); - - static void bootstrap() {} - - static Toxic register(String name, Toxic.Builder builder) { - return Registry.register(REGISTRY, Unicopia.id(name), new ToxicRegistryEntry(builder.build(), UTags.item("food_types/" + name))).value(); - } - - static Toxic lookup(ItemDuck item) { - @Nullable FoodComponent food = item.asItem().getFoodComponent(); - return REGISTRY.stream() - .filter(i -> i.matches(item.asItem())) - .map(ToxicRegistryEntry::value) - .map(t -> { - if (food == null) { - t.component().ifPresent(item::setFoodComponent); - } - return t; - }).findFirst().orElse(food == null ? Toxics.EMPTY : Toxics.EDIBLE); - } -} diff --git a/src/main/java/com/minelittlepony/unicopia/item/toxin/Toxin.java b/src/main/java/com/minelittlepony/unicopia/item/toxin/Toxin.java deleted file mode 100644 index 041dbe0d..00000000 --- a/src/main/java/com/minelittlepony/unicopia/item/toxin/Toxin.java +++ /dev/null @@ -1,171 +0,0 @@ -package com.minelittlepony.unicopia.item.toxin; - -import java.util.List; - -import com.minelittlepony.unicopia.entity.effect.UEffects; - -import net.minecraft.entity.attribute.EntityAttributes; -import net.minecraft.entity.effect.StatusEffect; -import net.minecraft.entity.effect.StatusEffectInstance; -import net.minecraft.entity.effect.StatusEffects; -import net.minecraft.entity.player.PlayerEntity; -import net.minecraft.item.FoodComponent; -import net.minecraft.item.ItemStack; -import net.minecraft.text.MutableText; -import net.minecraft.text.Text; -import net.minecraft.util.StringHelper; -import net.minecraft.util.math.MathHelper; -import net.minecraft.world.Difficulty; - -public interface Toxin extends Affliction { - Predicate IF_NOT_PEACEFUL = Predicate.of(Text.of("when not in peaceful "), (player, stack) -> player.getWorld().getDifficulty() != Difficulty.PEACEFUL); - - Toxin INNERT = of(Text.of("No Effect"), (player, stack) -> {}); - - Toxin INSTANT_DAMAGE = of(StatusEffects.INSTANT_DAMAGE, 1, 0); - Toxin GLOWING = of(StatusEffects.GLOWING, 15, 0); - - Toxin WEAKNESS = of(StatusEffects.WEAKNESS, 200, 1); - - Toxin STRENGTH = of(StatusEffects.STRENGTH, 30, 0); - Toxin BLINDNESS = of(StatusEffects.BLINDNESS, 30, 0); - Toxin CHANCE_OF_POISON = of(StatusEffects.POISON, 45, 2).withChance(80); - Toxin FOOD_POISONING = of(UEffects.FOOD_POISONING, 100, 2); - Toxin WEAK_FOOD_POISONING = of(UEffects.FOOD_POISONING, 50, 1); - Toxin STRONG_FOOD_POISONING = of(UEffects.FOOD_POISONING, 400, 3); - - Toxin LOVE_SICKNESS = of(Text.of("Love Sickness "), (player, stack) -> { - FoodComponent food = stack.getItem().getFoodComponent(); - player.getHungerManager().add(-food.getHunger()/2, -food.getSaturationModifier()/2); - }).and(FOOD_POISONING).and(IF_NOT_PEACEFUL.then(WEAK_FOOD_POISONING.withChance(20))).and(WEAKNESS); - - Toxin LOVE_CONSUMPTION = of(Text.literal("Love"), (player, stack) -> { - player.heal(stack.isFood() ? stack.getItem().getFoodComponent().getHunger() : 1); - player.removeStatusEffect(StatusEffects.NAUSEA); - player.removeStatusEffect(UEffects.FOOD_POISONING); - }); - - Toxin BAT_PONY_INTOXICATION = Toxin.of(StatusEffects.HEALTH_BOOST, 30, 60, 2, 6) - .and(Toxin.of(StatusEffects.JUMP_BOOST, 30, 60, 1, 6)) - .and(Toxin.of(StatusEffects.SPEED, 30, 30, 1, 6)) - .and(Toxin.of(StatusEffects.REGENERATION, 3, 30, 3, 6)); - - static Toxin healing(int hearts) { - return of(Text.literal("Healing " + hearts + " Hearts"), (player, stack) -> player.heal(hearts)); - } - - default void appendTooltip(List tooltip) { - tooltip.add(getName()); - } - - default Toxin withChance(int max) { - return Predicate.of(Text.of("1 in " + max + " chance of "), (player, stack) -> player.getWorld().random.nextInt(max) == 0).then(this); - } - - Text getName(); - - default Toxin and(Toxin other) { - Toxin self = this; - return new Toxin() { - @Override - public void afflict(PlayerEntity player, ItemStack stack) { - self.afflict(player, stack); - other.afflict(player, stack); - } - - @Override - public void appendTooltip(List tooltip) { - self.appendTooltip(tooltip); - other.appendTooltip(tooltip); - } - - @Override - public Text getName() { - return self.getName().copy().append(" + ").append(other.getName()); - } - }; - } - - static Toxin of(Text name, Affliction affliction) { - return new Toxin() { - @Override - public void afflict(PlayerEntity player, ItemStack stack) { - affliction.afflict(player, stack); - } - - @Override - public Text getName() { - return name; - } - }; - } - - static Toxin of(StatusEffect effect, int seconds, int amplifier) { - return of(effect, seconds, -1, amplifier, -1); - } - - static Toxin of(StatusEffect effect, int seconds, int maxSeconds, int amplifier, int maxAmplifier) { - final int ticks = seconds * 20; - final int maxTicks = maxSeconds * 20; - - MutableText text = effect.getName().copy(); - - if (amplifier > 0) { - text = Text.translatable("potion.withAmplifier", text, Text.translatable("potion.potency." + amplifier)); - } - - text = Text.translatable("potion.withDuration", text, StringHelper.formatTicks(ticks)); - - return of(text, (player, stack) -> { - float health = player.getHealth(); - StatusEffectInstance current = player.getStatusEffect(effect); - int t = applyLimit(ticks + (current == null ? 0 : current.getDuration()), maxTicks); - int a = applyLimit(amplifier + (current == null ? 0 : current.getAmplifier()), maxAmplifier); - player.addStatusEffect(new StatusEffectInstance(effect, t, a)); - // keep original health - if (effect.getAttributeModifiers().containsKey(EntityAttributes.GENERIC_MAX_HEALTH)) { - player.setHealth(MathHelper.clamp(health, 0, player.getMaxHealth())); - } - }); - } - - private static int applyLimit(int value, int max) { - return max > 0 ? Math.min(value, max) : value; - } - - interface Predicate { - static Predicate of(Text name, Affliction.Predicate predicate) { - return new Predicate() { - @Override - public boolean test(PlayerEntity player, ItemStack stack) { - return predicate.test(player, stack); - } - - @Override - public Text getName() { - return name; - } - }; - } - - boolean test(PlayerEntity player, ItemStack stack); - - Text getName(); - - default Toxin then(Toxin toxin) { - return new Toxin() { - @Override - public void afflict(PlayerEntity player, ItemStack stack) { - if (test(player, stack)) { - toxin.afflict(player, stack); - } - } - - @Override - public Text getName() { - return Predicate.this.getName().copy().append(toxin.getName()); - } - }; - } - } -} diff --git a/src/main/java/com/minelittlepony/unicopia/mixin/MixinBlockItem.java b/src/main/java/com/minelittlepony/unicopia/mixin/MixinBlockItem.java index 06382199..c7970a50 100644 --- a/src/main/java/com/minelittlepony/unicopia/mixin/MixinBlockItem.java +++ b/src/main/java/com/minelittlepony/unicopia/mixin/MixinBlockItem.java @@ -1,31 +1,28 @@ package com.minelittlepony.unicopia.mixin; import org.spongepowered.asm.mixin.Mixin; +import org.spongepowered.asm.mixin.injection.At; +import org.spongepowered.asm.mixin.injection.Inject; +import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; -import com.minelittlepony.unicopia.item.toxin.ToxicHolder; +import com.minelittlepony.unicopia.server.world.WaterLoggingManager; -import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.block.BlockState; import net.minecraft.item.BlockItem; import net.minecraft.item.Item; -import net.minecraft.item.ItemStack; -import net.minecraft.util.Hand; -import net.minecraft.util.TypedActionResult; -import net.minecraft.util.UseAction; -import net.minecraft.world.World; +import net.minecraft.item.ItemPlacementContext; @Mixin(BlockItem.class) -abstract class MixinBlockItem extends Item implements ToxicHolder { +abstract class MixinBlockItem extends Item { MixinBlockItem() {super(null); } - @Override + /*@Override public UseAction getUseAction(ItemStack stack) { - return getToxic(stack).useAction().orElseGet(() -> super.getUseAction(stack)); - } + return PonyDiets.getinstance().getUseAction(stack).orElseGet(() -> super.getUseAction(stack)); + }*/ - @Override - public TypedActionResult use(World world, PlayerEntity player, Hand hand) { - return getToxic(player.getStackInHand(hand)).ailment().get(player) - .map(t -> t.use(world, player, hand)) - .orElseGet(() -> super.use(world, player, hand)); + @Inject(method = "getPlacementState", at = @At("RETURN"), cancellable = true) + private void onGetPlacementState(ItemPlacementContext context, CallbackInfoReturnable info) { + WaterLoggingManager.getInstance().getPlacementState(context, info); } } diff --git a/src/main/java/com/minelittlepony/unicopia/mixin/MixinEnchantmentHelper.java b/src/main/java/com/minelittlepony/unicopia/mixin/MixinEnchantmentHelper.java new file mode 100644 index 00000000..4458399c --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/mixin/MixinEnchantmentHelper.java @@ -0,0 +1,26 @@ +package com.minelittlepony.unicopia.mixin; + +import org.spongepowered.asm.mixin.Mixin; +import org.spongepowered.asm.mixin.injection.At; +import org.spongepowered.asm.mixin.injection.Inject; +import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; + +import com.minelittlepony.unicopia.entity.player.Pony; + +import net.minecraft.enchantment.Enchantment; +import net.minecraft.enchantment.EnchantmentHelper; +import net.minecraft.entity.LivingEntity; + +@Mixin(EnchantmentHelper.class) +abstract class MixinEnchantmentHelper { + @Inject(method = "getEquipmentLevel", at = @At("RETURN"), cancellable = true) + private static void getEquipmentLevel(Enchantment enchantment, LivingEntity entity, CallbackInfoReturnable info) { + Pony.of(entity).ifPresent(pony -> { + int initial = info.getReturnValue(); + int implicitLevel = pony.getImplicitEnchantmentLevel(enchantment, initial); + if (implicitLevel != initial) { + info.setReturnValue(implicitLevel); + } + }); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/mixin/MixinEntity.java b/src/main/java/com/minelittlepony/unicopia/mixin/MixinEntity.java index a522b101..90febf2d 100644 --- a/src/main/java/com/minelittlepony/unicopia/mixin/MixinEntity.java +++ b/src/main/java/com/minelittlepony/unicopia/mixin/MixinEntity.java @@ -1,5 +1,7 @@ package com.minelittlepony.unicopia.mixin; +import java.util.Set; + import org.spongepowered.asm.mixin.Mixin; import org.spongepowered.asm.mixin.gen.Accessor; import org.spongepowered.asm.mixin.injection.At; @@ -17,9 +19,15 @@ import com.minelittlepony.unicopia.entity.duck.EntityDuck; import net.minecraft.entity.Entity; import net.minecraft.entity.Entity.PositionUpdater; import net.minecraft.entity.Entity.RemovalReason; +import net.minecraft.fluid.Fluid; +import net.minecraft.registry.tag.TagKey; @Mixin(Entity.class) abstract class MixinEntity implements EntityDuck { + @Override + @Accessor("submergedFluidTag") + public abstract Set> getSubmergedFluidTags(); + @Override @Accessor public abstract void setRemovalReason(RemovalReason reason); diff --git a/src/main/java/com/minelittlepony/unicopia/mixin/MixinGuardianTargetPredicate.java b/src/main/java/com/minelittlepony/unicopia/mixin/MixinGuardianTargetPredicate.java new file mode 100644 index 00000000..b7beed91 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/mixin/MixinGuardianTargetPredicate.java @@ -0,0 +1,21 @@ +package com.minelittlepony.unicopia.mixin; + +import org.jetbrains.annotations.Nullable; +import org.spongepowered.asm.mixin.Mixin; +import org.spongepowered.asm.mixin.injection.At; +import org.spongepowered.asm.mixin.injection.Inject; +import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; + +import com.minelittlepony.unicopia.EquinePredicates; + +import net.minecraft.entity.LivingEntity; + +@Mixin(targets = "net.minecraft.entity.mob.GuardianEntity$GuardianTargetPredicate") +abstract class MixinGuardianTargetPredicate { + @Inject(method = "test", at = @At("HEAD"), cancellable = true) + private void test(@Nullable LivingEntity livingEntity, CallbackInfoReturnable info) { + if (EquinePredicates.PLAYER_SEAPONY.test(livingEntity)) { + info.setReturnValue(false); + } + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/mixin/MixinItem.java b/src/main/java/com/minelittlepony/unicopia/mixin/MixinItem.java index d4924f25..cad3a18e 100644 --- a/src/main/java/com/minelittlepony/unicopia/mixin/MixinItem.java +++ b/src/main/java/com/minelittlepony/unicopia/mixin/MixinItem.java @@ -2,35 +2,26 @@ package com.minelittlepony.unicopia.mixin; import java.util.ArrayList; import java.util.List; +import java.util.Optional; import java.util.function.Supplier; import org.spongepowered.asm.mixin.Mixin; import org.spongepowered.asm.mixin.Mutable; import org.spongepowered.asm.mixin.gen.Accessor; -import org.spongepowered.asm.mixin.injection.At; -import org.spongepowered.asm.mixin.injection.Inject; -import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; - import com.google.common.base.Suppliers; +import com.minelittlepony.unicopia.diet.DietView; import com.minelittlepony.unicopia.entity.ItemImpl; import com.minelittlepony.unicopia.entity.ItemImpl.GroundTickCallback; -import com.minelittlepony.unicopia.entity.effect.FoodPoisoningStatusEffect; -import com.minelittlepony.unicopia.item.toxin.*; - -import net.minecraft.entity.LivingEntity; -import net.minecraft.entity.player.PlayerEntity; +import com.minelittlepony.unicopia.item.ItemDuck; import net.minecraft.item.FoodComponent; import net.minecraft.item.Item; -import net.minecraft.item.ItemStack; -import net.minecraft.util.ActionResult; -import net.minecraft.util.Hand; -import net.minecraft.util.TypedActionResult; -import net.minecraft.world.World; @Mixin(Item.class) -abstract class MixinItem implements ItemDuck { +abstract class MixinItem implements ItemDuck, DietView.Holder { private final List tickCallbacks = new ArrayList<>(); - private final Supplier originalFoodComponent = Suppliers.memoize(((Item)(Object)this)::getFoodComponent); + private final Supplier> originalFoodComponent = Suppliers.memoize(() -> { + return Optional.ofNullable(((Item)(Object)this).getFoodComponent()); + }); @Override public List getCallbacks() { @@ -43,21 +34,7 @@ abstract class MixinItem implements ItemDuck { public abstract void setFoodComponent(FoodComponent food); @Override - public Toxic getToxic(ItemStack stack) { - setFoodComponent(originalFoodComponent.get()); - return Toxics.lookup(this); - } - - @Inject(method = "finishUsing", at = @At("HEAD"), cancellable = true) - private void finishUsing(ItemStack stack, World world, LivingEntity entity, CallbackInfoReturnable info) { - getToxic(stack).finishUsing(stack, world, entity); - } - - @Inject(method = "use", at = @At("HEAD"), cancellable = true) - private void use(World world, PlayerEntity user, Hand hand, CallbackInfoReturnable> info) { - TypedActionResult result = FoodPoisoningStatusEffect.apply(this, user, hand); - if (result.getResult() != ActionResult.PASS) { - info.setReturnValue(result); - } + public Optional getOriginalFoodComponent() { + return originalFoodComponent.get(); } } diff --git a/src/main/java/com/minelittlepony/unicopia/mixin/MixinItemStack.java b/src/main/java/com/minelittlepony/unicopia/mixin/MixinItemStack.java new file mode 100644 index 00000000..35658fea --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/mixin/MixinItemStack.java @@ -0,0 +1,33 @@ +package com.minelittlepony.unicopia.mixin; + +import org.spongepowered.asm.mixin.Mixin; +import org.spongepowered.asm.mixin.injection.At; +import org.spongepowered.asm.mixin.injection.Inject; +import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; + +import com.minelittlepony.unicopia.diet.DietView; +import net.minecraft.entity.LivingEntity; +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.item.ItemStack; +import net.minecraft.util.ActionResult; +import net.minecraft.util.Hand; +import net.minecraft.util.TypedActionResult; +import net.minecraft.world.World; + +@Mixin(ItemStack.class) +abstract class MixinItemStack { + @Inject(method = "use", at = @At("HEAD"), cancellable = true) + private void onUse(World world, PlayerEntity user, Hand hand, CallbackInfoReturnable> info) { + ItemStack self = (ItemStack)(Object)this; + TypedActionResult result = ((DietView.Holder)self.getItem()).getDiets(self).startUsing(self, world, user, hand); + if (result.getResult() != ActionResult.PASS) { + info.setReturnValue(result); + } + } + + @Inject(method = "finishUsing", at = @At("HEAD")) + private void onFinishUsing(World world, LivingEntity user, CallbackInfoReturnable info) { + ItemStack self = (ItemStack)(Object)this; + ((DietView.Holder)self.getItem()).getDiets(self).finishUsing(self, world, user); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/mixin/MixinPlayerEntity.java b/src/main/java/com/minelittlepony/unicopia/mixin/MixinPlayerEntity.java index 9d96e9c1..d61ad769 100644 --- a/src/main/java/com/minelittlepony/unicopia/mixin/MixinPlayerEntity.java +++ b/src/main/java/com/minelittlepony/unicopia/mixin/MixinPlayerEntity.java @@ -11,6 +11,7 @@ import org.spongepowered.asm.mixin.injection.Redirect; import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; import com.minelittlepony.unicopia.entity.duck.PlayerEntityDuck; +import com.minelittlepony.unicopia.EquinePredicates; import com.minelittlepony.unicopia.entity.Equine; import com.minelittlepony.unicopia.entity.player.Pony; import com.mojang.datafixers.util.Either; @@ -28,6 +29,7 @@ import net.minecraft.server.network.ServerPlayerEntity; import net.minecraft.stat.Stats; import net.minecraft.util.Unit; import net.minecraft.util.math.BlockPos; +import net.minecraft.world.World; @Mixin(PlayerEntity.class) abstract class MixinPlayerEntity extends LivingEntity implements Equine.Container, PlayerEntityDuck { @@ -41,6 +43,11 @@ abstract class MixinPlayerEntity extends LivingEntity implements Equine.Containe return new Pony((PlayerEntity)(Object)this); } + @Inject(method = "createPlayerAttributes()Lnet/minecraft/entity/attribute/DefaultAttributeContainer$Builder;", at = @At("RETURN")) + private static void onCreateAttributes(CallbackInfoReturnable info) { + Pony.registerAttributes(info.getReturnValue()); + } + @ModifyVariable(method = "applyDamage(Lnet/minecraft/entity/damage/DamageSource;F)V", at = @At("HEAD"), ordinal = 0) protected float modifyDamageAmount(float amount, DamageSource source) { return get().modifyDamage(source, amount).orElse(amount); @@ -59,9 +66,9 @@ abstract class MixinPlayerEntity extends LivingEntity implements Equine.Containe }); } - @Inject(method = "createPlayerAttributes()Lnet/minecraft/entity/attribute/DefaultAttributeContainer$Builder;", at = @At("RETURN")) - private static void onCreateAttributes(CallbackInfoReturnable info) { - Pony.registerAttributes(info.getReturnValue()); + @Inject(method = "eatFood(Lnet/minecraft/world/World;Lnet/minecraft/item/ItemStack;)Lnet/minecraft/item/ItemStack;", at = @At("HEAD")) + private void onEatFood(World world, ItemStack stack, CallbackInfoReturnable info) { + get().onEat(stack); } @Inject(method = "trySleep(Lnet/minecraft/util/math/BlockPos;)Lcom/mojang/datafixers/util/Either;", @@ -114,4 +121,20 @@ abstract class MixinPlayerEntity extends LivingEntity implements Equine.Containe private void onGetBlockBreakingSpeed(BlockState state, CallbackInfoReturnable info) { info.setReturnValue(info.getReturnValue() * get().getBlockBreakingSpeed()); } + + @Override + protected int getNextAirUnderwater(int air) { + if (EquinePredicates.PLAYER_SEAPONY.test(this)) { + return super.getNextAirOnLand(air); + } + return super.getNextAirUnderwater(air); + } + + @Override + protected int getNextAirOnLand(int air) { + if (EquinePredicates.PLAYER_SEAPONY.test(this)) { + return super.getNextAirUnderwater(air); + } + return super.getNextAirOnLand(air); + } } diff --git a/src/main/java/com/minelittlepony/unicopia/mixin/MixinPufferfishEntity.java b/src/main/java/com/minelittlepony/unicopia/mixin/MixinPufferfishEntity.java new file mode 100644 index 00000000..ecadb831 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/mixin/MixinPufferfishEntity.java @@ -0,0 +1,25 @@ +package com.minelittlepony.unicopia.mixin; + +import org.spongepowered.asm.mixin.Mixin; +import org.spongepowered.asm.mixin.injection.At; +import org.spongepowered.asm.mixin.injection.Inject; +import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; + +import com.minelittlepony.unicopia.Race; +import com.minelittlepony.unicopia.entity.player.Pony; + +import net.minecraft.entity.LivingEntity; +import net.minecraft.entity.passive.FishEntity; +import net.minecraft.entity.passive.PufferfishEntity; + +@Mixin(PufferfishEntity.class) +abstract class MixinPufferfishEntity extends FishEntity { + MixinPufferfishEntity() { super(null, null); } + + @Inject(method = "method_6591(Lnet/minecraft/class_1309;)Z", at = @At("HEAD"), cancellable = true) + private static void onShouldTarget(LivingEntity entity, CallbackInfoReturnable info) { + Pony.of(entity).filter(pony -> pony.getCompositeRace().includes(Race.SEAPONY)).ifPresent(pony -> { + info.setReturnValue(false); + }); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/mixin/MixinStateManager.java b/src/main/java/com/minelittlepony/unicopia/mixin/MixinStateManager.java index c31f2822..ff62db5f 100644 --- a/src/main/java/com/minelittlepony/unicopia/mixin/MixinStateManager.java +++ b/src/main/java/com/minelittlepony/unicopia/mixin/MixinStateManager.java @@ -69,4 +69,4 @@ abstract class MixinBlockState extends State { private void onGetStateForNeighborUpdate(Direction direction, BlockState neighborState, WorldAccess world, BlockPos pos, BlockPos neighborPos, CallbackInfoReturnable info) { WaterLoggingManager.getInstance().getUpdatedState(world, pos, asBlockState(), info); } -} \ No newline at end of file +} diff --git a/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinBackgroundRenderer.java b/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinBackgroundRenderer.java new file mode 100644 index 00000000..566236f5 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinBackgroundRenderer.java @@ -0,0 +1,20 @@ +package com.minelittlepony.unicopia.mixin.client; + +import org.spongepowered.asm.mixin.Mixin; +import org.spongepowered.asm.mixin.injection.At; +import org.spongepowered.asm.mixin.injection.Inject; +import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; + +import com.minelittlepony.unicopia.client.render.WorldRenderDelegate; + +import net.minecraft.client.render.BackgroundRenderer; +import net.minecraft.client.render.Camera; +import net.minecraft.client.render.BackgroundRenderer.FogType; + +@Mixin(BackgroundRenderer.class) +abstract class MixinBackgroundRenderer { + @Inject(method = "applyFog", at = @At("RETURN")) + private static void onApplyFog(Camera camera, FogType fogType, float viewDistance, boolean thickFog, float tickDelta, CallbackInfo info) { + WorldRenderDelegate.INSTANCE.applyFog(camera, fogType, viewDistance, thickFog, tickDelta); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinInGameHud.java b/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinInGameHud.java index fa02c81d..e4306cbd 100644 --- a/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinInGameHud.java +++ b/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinInGameHud.java @@ -6,43 +6,27 @@ import org.spongepowered.asm.mixin.injection.Inject; import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; +import com.minelittlepony.unicopia.client.gui.HudEffects; import com.minelittlepony.unicopia.client.gui.UHud; -import com.minelittlepony.unicopia.entity.effect.EffectUtils; -import com.minelittlepony.unicopia.entity.effect.UEffects; - import net.minecraft.client.gui.DrawContext; import net.minecraft.client.gui.hud.InGameHud; -import net.minecraft.entity.effect.StatusEffectInstance; -import net.minecraft.entity.effect.StatusEffects; import net.minecraft.entity.player.PlayerEntity; @Mixin(InGameHud.class) abstract class MixinInGameHud { - private boolean addedHunger; - @Shadow abstract PlayerEntity getCameraPlayer(); @Inject(method = "render(Lnet/minecraft/client/gui/DrawContext;F)V", at = @At("HEAD")) private void onRender(DrawContext context, float tickDelta, CallbackInfo info) { - PlayerEntity player = getCameraPlayer(); - if (player != null && !player.hasStatusEffect(StatusEffects.HUNGER) && EffectUtils.getAmplifier(player, UEffects.FOOD_POISONING) > 0) { - addedHunger = true; - player.addStatusEffect(new StatusEffectInstance(StatusEffects.HUNGER, 1, 1, false, false)); - } + HudEffects.tryApply(getCameraPlayer(), tickDelta, true); UHud.INSTANCE.render((InGameHud)(Object)this, context, tickDelta); } @Inject(method = "render(Lnet/minecraft/client/gui/DrawContext;F)V", at = @At("RETURN")) private void afterRender(DrawContext context, float tickDelta, CallbackInfo info) { - if (addedHunger) { - addedHunger = false; - PlayerEntity player = getCameraPlayer(); - if (player != null) { - player.removeStatusEffect(StatusEffects.HUNGER); - } - } + HudEffects.tryApply(getCameraPlayer(), tickDelta, false); } } diff --git a/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinItem.java b/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinItem.java deleted file mode 100644 index 5196f529..00000000 --- a/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinItem.java +++ /dev/null @@ -1,26 +0,0 @@ -package com.minelittlepony.unicopia.mixin.client; - -import java.util.List; -import org.jetbrains.annotations.Nullable; - -import org.spongepowered.asm.mixin.Mixin; -import org.spongepowered.asm.mixin.injection.At; -import org.spongepowered.asm.mixin.injection.Inject; -import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; - -import com.minelittlepony.unicopia.item.toxin.ToxicHolder; - -import net.minecraft.client.MinecraftClient; -import net.minecraft.client.item.TooltipContext; -import net.minecraft.item.Item; -import net.minecraft.item.ItemStack; -import net.minecraft.text.Text; -import net.minecraft.world.World; - -@Mixin(Item.class) -abstract class MixinItem implements ToxicHolder { - @Inject(method = "appendTooltip", at = @At("RETURN")) - private void onAppendTooltip(ItemStack stack, @Nullable World world, List tooltip, TooltipContext context, CallbackInfo into) { - getToxic(stack).appendTooltip(MinecraftClient.getInstance().player, tooltip, context); - } -} diff --git a/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinItemStack.java b/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinItemStack.java new file mode 100644 index 00000000..81a3b67f --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinItemStack.java @@ -0,0 +1,24 @@ +package com.minelittlepony.unicopia.mixin.client; + +import java.util.List; +import org.jetbrains.annotations.Nullable; + +import org.spongepowered.asm.mixin.Mixin; +import org.spongepowered.asm.mixin.injection.At; +import org.spongepowered.asm.mixin.injection.Inject; +import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; + +import com.minelittlepony.unicopia.diet.DietView; +import net.minecraft.client.item.TooltipContext; +import net.minecraft.entity.player.PlayerEntity; +import net.minecraft.item.ItemStack; +import net.minecraft.text.Text; + +@Mixin(ItemStack.class) +abstract class MixinItemStack { + @Inject(method = "getTooltip", at = @At("RETURN")) + private void onGetTooltip(@Nullable PlayerEntity player, TooltipContext context, CallbackInfoReturnable> info) { + ItemStack self = (ItemStack)(Object)this; + ((DietView.Holder)self.getItem()).getDiets(self).appendTooltip(self, player, info.getReturnValue(), context); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinKeyboardInput.java b/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinKeyboardInput.java index c0fd45da..7bc83f17 100644 --- a/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinKeyboardInput.java +++ b/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinKeyboardInput.java @@ -40,6 +40,11 @@ abstract class MixinKeyboardInput extends Input { movementForward = 0; jumping = false; } + + if (player.getAcrobatics().isImmobile()) { + movementSideways = 0; + movementForward = 0; + } } } } diff --git a/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinModelPart.java b/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinModelPart.java index 4fb5cd9a..aef4d87d 100644 --- a/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinModelPart.java +++ b/src/main/java/com/minelittlepony/unicopia/mixin/client/MixinModelPart.java @@ -39,7 +39,7 @@ abstract class MixinModelPart implements Hookable { isHeadPart = true; } - @Inject(method = "render(Lnet/minecraft/client/util/math/MatrixStack;Lnet/minecraft/client/render/VertexConsumer;IIFFFF)V", at = @At("RETURN")) + @Inject(method = "render(Lnet/minecraft/client/util/math/MatrixStack;Lnet/minecraft/client/render/VertexConsumer;IIFFFF)V", at = @At("HEAD")) public void render(MatrixStack matrices, VertexConsumer vertices, int light, int overlay, float red, float green, float blue, float alpha, CallbackInfo info) { if (visible && isHeadPart) { ModelPartHooks.onHeadRendered((ModelPart)(Object)this, matrices); diff --git a/src/main/java/com/minelittlepony/unicopia/mixin/client/minelp/MixinPonyPosture.java b/src/main/java/com/minelittlepony/unicopia/mixin/client/minelp/MixinPonyPosture.java new file mode 100644 index 00000000..faaa44bc --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/mixin/client/minelp/MixinPonyPosture.java @@ -0,0 +1,20 @@ +package com.minelittlepony.unicopia.mixin.client.minelp; + +import org.spongepowered.asm.mixin.Mixin; +import org.spongepowered.asm.mixin.injection.At; +import org.spongepowered.asm.mixin.injection.Inject; +import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; + +import com.minelittlepony.api.pony.PonyPosture; +import com.minelittlepony.unicopia.EquinePredicates; +import net.minecraft.entity.LivingEntity; + +@Mixin(PonyPosture.class) +abstract class MixinPonyPosture { + @Inject(method = "isPartiallySubmerged", at = @At("HEAD"), cancellable = true) + private static void isPartiallySubmerged(LivingEntity entity, CallbackInfoReturnable info) { + if (EquinePredicates.PLAYER_SEAPONY.test(entity)) { + info.setReturnValue(true); + } + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/network/MsgServerResources.java b/src/main/java/com/minelittlepony/unicopia/network/MsgServerResources.java index 8b672465..f2199c00 100644 --- a/src/main/java/com/minelittlepony/unicopia/network/MsgServerResources.java +++ b/src/main/java/com/minelittlepony/unicopia/network/MsgServerResources.java @@ -6,6 +6,7 @@ import com.minelittlepony.unicopia.InteractionManager; import com.minelittlepony.unicopia.ability.data.tree.TreeTypeLoader; import com.minelittlepony.unicopia.ability.magic.spell.trait.SpellTraits; import com.minelittlepony.unicopia.container.SpellbookChapterLoader; +import com.minelittlepony.unicopia.diet.PonyDiets; import com.sollace.fabwork.api.packets.Packet; import net.minecraft.network.PacketByteBuf; @@ -14,13 +15,15 @@ import net.minecraft.util.Identifier; public record MsgServerResources ( Map traits, Map chapters, - Map treeTypes + Map treeTypes, + PonyDiets diets ) implements Packet { public MsgServerResources() { this( SpellTraits.all(), SpellbookChapterLoader.INSTANCE.getChapters(), - TreeTypeLoader.INSTANCE.getEntries() + TreeTypeLoader.INSTANCE.getEntries(), + PonyDiets.getInstance() ); } @@ -28,7 +31,8 @@ public record MsgServerResources ( this( buffer.readMap(PacketByteBuf::readIdentifier, SpellTraits::fromPacket), InteractionManager.instance().readChapters(buffer), - buffer.readMap(PacketByteBuf::readIdentifier, TreeTypeLoader.TreeTypeDef::new) + buffer.readMap(PacketByteBuf::readIdentifier, TreeTypeLoader.TreeTypeDef::new), + new PonyDiets(buffer) ); } @@ -37,5 +41,6 @@ public record MsgServerResources ( buffer.writeMap(traits, PacketByteBuf::writeIdentifier, (r, v) -> v.write(r)); buffer.writeMap(chapters, PacketByteBuf::writeIdentifier, (r, v) -> ((SpellbookChapterLoader.Chapter)v).write(r)); buffer.writeMap(treeTypes, PacketByteBuf::writeIdentifier, (r, v) -> v.write(r)); + diets.toBuffer(buffer); } } diff --git a/src/main/java/com/minelittlepony/unicopia/network/handler/ClientNetworkHandlerImpl.java b/src/main/java/com/minelittlepony/unicopia/network/handler/ClientNetworkHandlerImpl.java index 6b67b4a2..889191a3 100644 --- a/src/main/java/com/minelittlepony/unicopia/network/handler/ClientNetworkHandlerImpl.java +++ b/src/main/java/com/minelittlepony/unicopia/network/handler/ClientNetworkHandlerImpl.java @@ -15,6 +15,7 @@ import com.minelittlepony.unicopia.client.UnicopiaClient; import com.minelittlepony.unicopia.client.gui.TribeSelectionScreen; import com.minelittlepony.unicopia.client.gui.spellbook.ClientChapters; import com.minelittlepony.unicopia.client.gui.spellbook.SpellbookChapterList.Chapter; +import com.minelittlepony.unicopia.diet.PonyDiets; import com.minelittlepony.unicopia.entity.mob.UEntities; import com.minelittlepony.unicopia.entity.player.Pony; import com.minelittlepony.unicopia.network.*; @@ -98,6 +99,7 @@ public class ClientNetworkHandlerImpl { SpellTraits.load(packet.traits()); ClientChapters.load((Map)packet.chapters()); TreeTypes.load(packet.treeTypes()); + PonyDiets.load(packet.diets()); } private void handlePlayerAnimation(PlayerEntity sender, MsgPlayerAnimationChange packet) { diff --git a/src/main/java/com/minelittlepony/unicopia/server/world/UWorldGen.java b/src/main/java/com/minelittlepony/unicopia/server/world/UWorldGen.java index cd1ae14f..097fdc9f 100644 --- a/src/main/java/com/minelittlepony/unicopia/server/world/UWorldGen.java +++ b/src/main/java/com/minelittlepony/unicopia/server/world/UWorldGen.java @@ -3,19 +3,36 @@ package com.minelittlepony.unicopia.server.world; import java.util.List; import com.minelittlepony.unicopia.Unicopia; +import com.minelittlepony.unicopia.block.ShellsBlock; +import com.minelittlepony.unicopia.block.UBlocks; import net.fabricmc.fabric.api.biome.v1.BiomeModifications; import net.fabricmc.fabric.api.biome.v1.BiomeSelectors; +import net.minecraft.block.BlockState; +import net.minecraft.block.Blocks; import net.minecraft.registry.Registries; import net.minecraft.registry.Registry; import net.minecraft.registry.RegistryKey; import net.minecraft.registry.tag.BiomeTags; +import net.minecraft.util.collection.DataPool; +import net.minecraft.util.math.Direction; +import net.minecraft.util.math.Vec3i; +import net.minecraft.util.math.intprovider.UniformIntProvider; +import net.minecraft.world.biome.BiomeKeys; import net.minecraft.world.gen.GenerationStep; +import net.minecraft.world.gen.blockpredicate.BlockPredicate; +import net.minecraft.world.gen.feature.ConfiguredFeatures; +import net.minecraft.world.gen.feature.Feature; import net.minecraft.world.gen.feature.PlacedFeature; import net.minecraft.world.gen.feature.PlacedFeatures; +import net.minecraft.world.gen.feature.RandomPatchFeature; +import net.minecraft.world.gen.feature.RandomPatchFeatureConfig; +import net.minecraft.world.gen.feature.SimpleBlockFeatureConfig; import net.minecraft.world.gen.placementmodifier.BiomePlacementModifier; import net.minecraft.world.gen.placementmodifier.RarityFilterPlacementModifier; import net.minecraft.world.gen.placementmodifier.SquarePlacementModifier; +import net.minecraft.world.gen.stateprovider.RandomizedIntBlockStateProvider; +import net.minecraft.world.gen.stateprovider.WeightedBlockStateProvider; public interface UWorldGen { PineapplePlantFeature PINEAPPLE_PLANT_FEATURE = Registry.register(Registries.FEATURE, Unicopia.id("pineapple_plant"), new PineapplePlantFeature()); @@ -26,8 +43,37 @@ public interface UWorldGen { BiomePlacementModifier.of() )); + RandomPatchFeature SHELLS_FEATURE = Registry.register(Registries.FEATURE, Unicopia.id("shells"), new RandomPatchFeature(RandomPatchFeatureConfig.CODEC)); + RegistryKey SHELLS_PLACED_FEATURE = FeatureRegistry.registerPlaceableFeature(Unicopia.id("shells"), SHELLS_FEATURE, ConfiguredFeatures.createRandomPatchFeatureConfig( + 25, + PlacedFeatures.createEntry(Feature.SIMPLE_BLOCK, new SimpleBlockFeatureConfig( + new RandomizedIntBlockStateProvider( + new WeightedBlockStateProvider(DataPool.builder() + .add(UBlocks.CLAM_SHELL.getDefaultState(), 1) + .add(UBlocks.SCALLOP_SHELL.getDefaultState(), 2) + .add(UBlocks.TURRET_SHELL.getDefaultState(), 2) + ), + ShellsBlock.COUNT, + UniformIntProvider.create(1, 4) + ) + ), BlockPredicate.allOf( + BlockPredicate.matchingBlocks(Blocks.WATER), + BlockPredicate.hasSturdyFace(new Vec3i(0, -1, 0), Direction.UP) + ))), List.of( + RarityFilterPlacementModifier.of(1), + SquarePlacementModifier.of(), + PlacedFeatures.OCEAN_FLOOR_WG_HEIGHTMAP, + BiomePlacementModifier.of() + )); + static void bootstrap() { BiomeModifications.addFeature(BiomeSelectors.tag(BiomeTags.IS_JUNGLE), GenerationStep.Feature.VEGETAL_DECORATION, PINEAPPLE_PLANT_PLACED_FEATURE); + BiomeModifications.addFeature( + BiomeSelectors.tag(BiomeTags.IS_OCEAN) + .or(BiomeSelectors.tag(BiomeTags.IS_DEEP_OCEAN) + .or(BiomeSelectors.tag(BiomeTags.IS_RIVER)) + .or(BiomeSelectors.includeByKey(BiomeKeys.STONY_SHORE)) + ), GenerationStep.Feature.VEGETAL_DECORATION, SHELLS_PLACED_FEATURE); UTreeGen.bootstrap(); } } diff --git a/src/main/java/com/minelittlepony/unicopia/server/world/WaterLoggingManager.java b/src/main/java/com/minelittlepony/unicopia/server/world/WaterLoggingManager.java index 2372a3bb..5b2b57f4 100644 --- a/src/main/java/com/minelittlepony/unicopia/server/world/WaterLoggingManager.java +++ b/src/main/java/com/minelittlepony/unicopia/server/world/WaterLoggingManager.java @@ -8,6 +8,8 @@ import net.minecraft.block.*; import net.minecraft.block.enums.DoubleBlockHalf; import net.minecraft.fluid.FluidState; import net.minecraft.fluid.Fluids; +import net.minecraft.item.ItemPlacementContext; +import net.minecraft.registry.tag.FluidTags; import net.minecraft.state.State; import net.minecraft.state.property.Properties; import net.minecraft.state.property.Property; @@ -36,7 +38,15 @@ public class WaterLoggingManager> { public void getDefaultState(O owner, CallbackInfoReturnable info) { if (appliesTo(owner, info.getReturnValue())) { - info.setReturnValue(info.getReturnValue().with(Properties.WATERLOGGED, true)); + info.setReturnValue(info.getReturnValue().with(Properties.WATERLOGGED, !(owner instanceof BedBlock))); + } + } + + @SuppressWarnings("unchecked") + public void getPlacementState(ItemPlacementContext context, CallbackInfoReturnable info) { + BlockState state = info.getReturnValue(); + if (state != null && appliesTo((O)state.getBlock(), (S)state)) { + info.setReturnValue(state.with(Properties.WATERLOGGED, context.getWorld().getFluidState(context.getBlockPos()).isIn(FluidTags.WATER))); } } @@ -61,7 +71,8 @@ public class WaterLoggingManager> { && (block instanceof SeagrassBlock || block instanceof TallSeagrassBlock || block instanceof KelpBlock - || block instanceof KelpPlantBlock); + || block instanceof KelpPlantBlock + || block instanceof BedBlock); } public boolean shouldPreventRemoval(WorldAccess world, BlockPos pos, AbstractBlock.AbstractBlockState oldState, AbstractBlock.AbstractBlockState newState) { diff --git a/src/main/java/com/minelittlepony/unicopia/server/world/ZapAppleStageStore.java b/src/main/java/com/minelittlepony/unicopia/server/world/ZapAppleStageStore.java index 4111a432..e1460494 100644 --- a/src/main/java/com/minelittlepony/unicopia/server/world/ZapAppleStageStore.java +++ b/src/main/java/com/minelittlepony/unicopia/server/world/ZapAppleStageStore.java @@ -171,7 +171,7 @@ public class ZapAppleStageStore extends PersistentState implements Tickable { if (this == ZapAppleStageStore.Stage.FLOWERING) { return UBlocks.FLOWERING_ZAP_LEAVES.getDefaultState(); } - return UBlocks.FLOWERING_ZAP_LEAVES.getDefaultState().withIfExists(ZapAppleLeavesBlock.STAGE, this); + return UBlocks.ZAP_LEAVES.getDefaultState().with(ZapAppleLeavesBlock.STAGE, this); } @Override diff --git a/src/main/java/com/minelittlepony/unicopia/util/VoxelShapeUtil.java b/src/main/java/com/minelittlepony/unicopia/util/VoxelShapeUtil.java new file mode 100644 index 00000000..adff046a --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/util/VoxelShapeUtil.java @@ -0,0 +1,52 @@ +package com.minelittlepony.unicopia.util; + +import net.minecraft.util.math.Box; +import net.minecraft.util.math.Direction; +import net.minecraft.util.math.MathHelper; +import net.minecraft.util.math.Vec3d; +import net.minecraft.util.math.Direction.Axis; +import net.minecraft.util.shape.VoxelShape; +import net.minecraft.util.shape.VoxelShapes; + +import java.util.function.Function; + +public interface VoxelShapeUtil { + Vec3d CENTER = new Vec3d(0.5, 0, 0.5); + + static Function rotator(VoxelShape base) { + return d -> rotate(base, d); + } + + static VoxelShape rotate(VoxelShape shape, Direction direction) { + if (direction.asRotation() == 0) { + return shape; + } + if (direction.getAxis() == Axis.X) { + direction = direction.getOpposite(); + } + float angle = direction.asRotation() * MathHelper.RADIANS_PER_DEGREE; + return VoxelShapes.union(VoxelShapes.empty(), shape.getBoundingBoxes().stream() + .map(box -> { + //These first two are enough for orthogonal rotations + Vec3d a = rotate(box.minX, box.minZ, angle); + Vec3d b = rotate(box.maxX, box.maxZ, angle); + //These cover odd angles + Vec3d c = rotate(box.minX, box.maxZ, angle); + Vec3d d = rotate(box.maxX, box.minZ, angle); + + return VoxelShapes.cuboid(new Box( + Math.min(Math.min(a.x, b.x), Math.min(c.x, d.x)), + box.minY, + Math.min(Math.min(a.z, b.z), Math.min(c.z, d.z)), + Math.max(Math.max(a.x, b.x), Math.max(c.x, d.x)), + box.maxY, + Math.max(Math.max(a.z, b.z), Math.max(c.z, d.z)) + )); + }) + .toArray(VoxelShape[]::new)); + } + + static Vec3d rotate(double x, double z, float angle) { + return new Vec3d(x, 0, z).subtract(CENTER).rotateY(angle).add(CENTER); + } +} diff --git a/src/main/resources/assets/unicopia/blockstates/carved_cloud.json b/src/main/resources/assets/unicopia/blockstates/carved_cloud.json new file mode 100644 index 00000000..e2a29a8c --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/carved_cloud.json @@ -0,0 +1,10 @@ +{ + "variants": { + "facing=up": { "model": "unicopia:block/carved_cloud" }, + "facing=down": { "model": "unicopia:block/carved_cloud", "x": 180 }, + "facing=north": { "model": "unicopia:block/carved_cloud", "x": 90 }, + "facing=south": { "model": "unicopia:block/carved_cloud", "x": -90 }, + "facing=east": { "model": "unicopia:block/carved_cloud", "x": 90, "y": 90 }, + "facing=west": { "model": "unicopia:block/carved_cloud", "x": 90, "y": -90 } + } +} diff --git a/src/main/resources/assets/unicopia/blockstates/clam_shell.json b/src/main/resources/assets/unicopia/blockstates/clam_shell.json new file mode 100644 index 00000000..9efb55d9 --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/clam_shell.json @@ -0,0 +1,8 @@ +{ + "variants": { + "count=1": { "model": "unicopia:block/clam_shell_1" }, + "count=2": { "model": "unicopia:block/clam_shell_2" }, + "count=3": { "model": "unicopia:block/clam_shell_3" }, + "count=4": { "model": "unicopia:block/clam_shell_4" } + } +} diff --git a/src/main/resources/assets/unicopia/blockstates/cloth_bed.json b/src/main/resources/assets/unicopia/blockstates/cloth_bed.json new file mode 100644 index 00000000..a86c636b --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/cloth_bed.json @@ -0,0 +1,5 @@ +{ + "variants": { + "": { "model": "unicopia:block/cloth_bed" } + } +} diff --git a/src/main/resources/assets/unicopia/blockstates/cloud_brick_slab.json b/src/main/resources/assets/unicopia/blockstates/cloud_brick_slab.json new file mode 100644 index 00000000..1ef1dad5 --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/cloud_brick_slab.json @@ -0,0 +1,7 @@ +{ + "variants": { + "type=double": { "model": "unicopia:block/cloud_bricks" }, + "type=bottom": { "model": "unicopia:block/cloud_brick_slab" }, + "type=top": { "model": "unicopia:block/cloud_brick_slab_top" } + } +} diff --git a/src/main/resources/assets/unicopia/blockstates/cloud_planks_stairs.json b/src/main/resources/assets/unicopia/blockstates/cloud_brick_stairs.json similarity index 62% rename from src/main/resources/assets/unicopia/blockstates/cloud_planks_stairs.json rename to src/main/resources/assets/unicopia/blockstates/cloud_brick_stairs.json index c28c2304..270e717e 100644 --- a/src/main/resources/assets/unicopia/blockstates/cloud_planks_stairs.json +++ b/src/main/resources/assets/unicopia/blockstates/cloud_brick_stairs.json @@ -1,206 +1,206 @@ { "variants": { "facing=east,half=bottom,shape=inner_left": { - "model": "unicopia:block/cloud_planks_stairs_inner", + "model": "unicopia:block/cloud_brick_stairs_inner", "uvlock": true, "y": 270 }, "facing=east,half=bottom,shape=inner_right": { - "model": "unicopia:block/cloud_planks_stairs_inner" + "model": "unicopia:block/cloud_brick_stairs_inner" }, "facing=east,half=bottom,shape=outer_left": { - "model": "unicopia:block/cloud_planks_stairs_outer", + "model": "unicopia:block/cloud_brick_stairs_outer", "uvlock": true, "y": 270 }, "facing=east,half=bottom,shape=outer_right": { - "model": "unicopia:block/cloud_planks_stairs_outer" + "model": "unicopia:block/cloud_brick_stairs_outer" }, "facing=east,half=bottom,shape=straight": { - "model": "unicopia:block/cloud_planks_stairs" + "model": "unicopia:block/cloud_brick_stairs" }, "facing=east,half=top,shape=inner_left": { - "model": "unicopia:block/cloud_planks_stairs_inner", + "model": "unicopia:block/cloud_brick_stairs_inner", "uvlock": true, "x": 180 }, "facing=east,half=top,shape=inner_right": { - "model": "unicopia:block/cloud_planks_stairs_inner", + "model": "unicopia:block/cloud_brick_stairs_inner", "uvlock": true, "x": 180, "y": 90 }, "facing=east,half=top,shape=outer_left": { - "model": "unicopia:block/cloud_planks_stairs_outer", + "model": "unicopia:block/cloud_brick_stairs_outer", "uvlock": true, "x": 180 }, "facing=east,half=top,shape=outer_right": { - "model": "unicopia:block/cloud_planks_stairs_outer", + "model": "unicopia:block/cloud_brick_stairs_outer", "uvlock": true, "x": 180, "y": 90 }, "facing=east,half=top,shape=straight": { - "model": "unicopia:block/cloud_planks_stairs", + "model": "unicopia:block/cloud_brick_stairs", "uvlock": true, "x": 180 }, "facing=north,half=bottom,shape=inner_left": { - "model": "unicopia:block/cloud_planks_stairs_inner", + "model": "unicopia:block/cloud_brick_stairs_inner", "uvlock": true, "y": 180 }, "facing=north,half=bottom,shape=inner_right": { - "model": "unicopia:block/cloud_planks_stairs_inner", + "model": "unicopia:block/cloud_brick_stairs_inner", "uvlock": true, "y": 270 }, "facing=north,half=bottom,shape=outer_left": { - "model": "unicopia:block/cloud_planks_stairs_outer", + "model": "unicopia:block/cloud_brick_stairs_outer", "uvlock": true, "y": 180 }, "facing=north,half=bottom,shape=outer_right": { - "model": "unicopia:block/cloud_planks_stairs_outer", + "model": "unicopia:block/cloud_brick_stairs_outer", "uvlock": true, "y": 270 }, "facing=north,half=bottom,shape=straight": { - "model": "unicopia:block/cloud_planks_stairs", + "model": "unicopia:block/cloud_brick_stairs", "uvlock": true, "y": 270 }, "facing=north,half=top,shape=inner_left": { - "model": "unicopia:block/cloud_planks_stairs_inner", + "model": "unicopia:block/cloud_brick_stairs_inner", "uvlock": true, "x": 180, "y": 270 }, "facing=north,half=top,shape=inner_right": { - "model": "unicopia:block/cloud_planks_stairs_inner", + "model": "unicopia:block/cloud_brick_stairs_inner", "uvlock": true, "x": 180 }, "facing=north,half=top,shape=outer_left": { - "model": "unicopia:block/cloud_planks_stairs_outer", + "model": "unicopia:block/cloud_brick_stairs_outer", "uvlock": true, "x": 180, "y": 270 }, "facing=north,half=top,shape=outer_right": { - "model": "unicopia:block/cloud_planks_stairs_outer", + "model": "unicopia:block/cloud_brick_stairs_outer", "uvlock": true, "x": 180 }, "facing=north,half=top,shape=straight": { - "model": "unicopia:block/cloud_planks_stairs", + "model": "unicopia:block/cloud_brick_stairs", "uvlock": true, "x": 180, "y": 270 }, "facing=south,half=bottom,shape=inner_left": { - "model": "unicopia:block/cloud_planks_stairs_inner" + "model": "unicopia:block/cloud_brick_stairs_inner" }, "facing=south,half=bottom,shape=inner_right": { - "model": "unicopia:block/cloud_planks_stairs_inner", + "model": "unicopia:block/cloud_brick_stairs_inner", "uvlock": true, "y": 90 }, "facing=south,half=bottom,shape=outer_left": { - "model": "unicopia:block/cloud_planks_stairs_outer" + "model": "unicopia:block/cloud_brick_stairs_outer" }, "facing=south,half=bottom,shape=outer_right": { - "model": "unicopia:block/cloud_planks_stairs_outer", + "model": "unicopia:block/cloud_brick_stairs_outer", "uvlock": true, "y": 90 }, "facing=south,half=bottom,shape=straight": { - "model": "unicopia:block/cloud_planks_stairs", + "model": "unicopia:block/cloud_brick_stairs", "uvlock": true, "y": 90 }, "facing=south,half=top,shape=inner_left": { - "model": "unicopia:block/cloud_planks_stairs_inner", + "model": "unicopia:block/cloud_brick_stairs_inner", "uvlock": true, "x": 180, "y": 90 }, "facing=south,half=top,shape=inner_right": { - "model": "unicopia:block/cloud_planks_stairs_inner", + "model": "unicopia:block/cloud_brick_stairs_inner", "uvlock": true, "x": 180, "y": 180 }, "facing=south,half=top,shape=outer_left": { - "model": "unicopia:block/cloud_planks_stairs_outer", + "model": "unicopia:block/cloud_brick_stairs_outer", "uvlock": true, "x": 180, "y": 90 }, "facing=south,half=top,shape=outer_right": { - "model": "unicopia:block/cloud_planks_stairs_outer", + "model": "unicopia:block/cloud_brick_stairs_outer", "uvlock": true, "x": 180, "y": 180 }, "facing=south,half=top,shape=straight": { - "model": "unicopia:block/cloud_planks_stairs", + "model": "unicopia:block/cloud_brick_stairs", "uvlock": true, "x": 180, "y": 90 }, "facing=west,half=bottom,shape=inner_left": { - "model": "unicopia:block/cloud_planks_stairs_inner", + "model": "unicopia:block/cloud_brick_stairs_inner", "uvlock": true, "y": 90 }, "facing=west,half=bottom,shape=inner_right": { - "model": "unicopia:block/cloud_planks_stairs_inner", + "model": "unicopia:block/cloud_brick_stairs_inner", "uvlock": true, "y": 180 }, "facing=west,half=bottom,shape=outer_left": { - "model": "unicopia:block/cloud_planks_stairs_outer", + "model": "unicopia:block/cloud_brick_stairs_outer", "uvlock": true, "y": 90 }, "facing=west,half=bottom,shape=outer_right": { - "model": "unicopia:block/cloud_planks_stairs_outer", + "model": "unicopia:block/cloud_brick_stairs_outer", "uvlock": true, "y": 180 }, "facing=west,half=bottom,shape=straight": { - "model": "unicopia:block/cloud_planks_stairs", + "model": "unicopia:block/cloud_brick_stairs", "uvlock": true, "y": 180 }, "facing=west,half=top,shape=inner_left": { - "model": "unicopia:block/cloud_planks_stairs_inner", + "model": "unicopia:block/cloud_brick_stairs_inner", "uvlock": true, "x": 180, "y": 180 }, "facing=west,half=top,shape=inner_right": { - "model": "unicopia:block/cloud_planks_stairs_inner", + "model": "unicopia:block/cloud_brick_stairs_inner", "uvlock": true, "x": 180, "y": 270 }, "facing=west,half=top,shape=outer_left": { - "model": "unicopia:block/cloud_planks_stairs_outer", + "model": "unicopia:block/cloud_brick_stairs_outer", "uvlock": true, "x": 180, "y": 180 }, "facing=west,half=top,shape=outer_right": { - "model": "unicopia:block/cloud_planks_stairs_outer", + "model": "unicopia:block/cloud_brick_stairs_outer", "uvlock": true, "x": 180, "y": 270 }, "facing=west,half=top,shape=straight": { - "model": "unicopia:block/cloud_planks_stairs", + "model": "unicopia:block/cloud_brick_stairs", "uvlock": true, "x": 180, "y": 180 diff --git a/src/main/resources/assets/unicopia/blockstates/cloud_bricks.json b/src/main/resources/assets/unicopia/blockstates/cloud_bricks.json new file mode 100644 index 00000000..01037815 --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/cloud_bricks.json @@ -0,0 +1,5 @@ +{ + "variants": { + "": { "model": "unicopia:block/cloud_bricks" } + } +} diff --git a/src/main/resources/assets/unicopia/blockstates/cloud_chest.json b/src/main/resources/assets/unicopia/blockstates/cloud_chest.json new file mode 100644 index 00000000..aa6b3edb --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/cloud_chest.json @@ -0,0 +1,5 @@ +{ + "variants": { + "": { "model": "unicopia:block/cloud_chest" } + } +} diff --git a/src/main/resources/assets/unicopia/blockstates/library_door.json b/src/main/resources/assets/unicopia/blockstates/cloud_door.json similarity index 50% rename from src/main/resources/assets/unicopia/blockstates/library_door.json rename to src/main/resources/assets/unicopia/blockstates/cloud_door.json index aec9f468..e837d7f0 100644 --- a/src/main/resources/assets/unicopia/blockstates/library_door.json +++ b/src/main/resources/assets/unicopia/blockstates/cloud_door.json @@ -1,68 +1,68 @@ { "variants": { - "facing=east,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:door/library_bottom" }, - "facing=south,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:door/library_bottom", "y": 90 }, - "facing=west,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:door/library_bottom", "y": 180 }, - "facing=north,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:door/library_bottom", "y": 270 }, - "facing=east,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:door/library_bottom_rh" }, - "facing=south,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:door/library_bottom_rh", "y": 90 }, - "facing=west,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:door/library_bottom_rh", "y": 180 }, - "facing=north,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:door/library_bottom_rh", "y": 270 }, - "facing=east,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:door/library_bottom_rh", "y": 90 }, - "facing=south,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:door/library_bottom_rh", "y": 180 }, - "facing=west,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:door/library_bottom_rh", "y": 270 }, - "facing=north,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:door/library_bottom_rh" }, - "facing=east,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:door/library_bottom", "y": 270 }, - "facing=south,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:door/library_bottom" }, - "facing=west,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:door/library_bottom", "y": 90 }, - "facing=north,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:door/library_bottom", "y": 180 }, - "facing=east,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:door/library_top" }, - "facing=south,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:door/library_top", "y": 90 }, - "facing=west,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:door/library_top", "y": 180 }, - "facing=north,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:door/library_top", "y": 270 }, - "facing=east,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:door/library_top_rh" }, - "facing=south,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:door/library_top_rh", "y": 90 }, - "facing=west,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:door/library_top_rh", "y": 180 }, - "facing=north,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:door/library_top_rh", "y": 270 }, - "facing=east,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:door/library_top_rh", "y": 90 }, - "facing=south,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:door/library_top_rh", "y": 180 }, - "facing=west,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:door/library_top_rh", "y": 270 }, - "facing=north,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:door/library_top_rh" }, - "facing=east,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:door/library_top", "y": 270 }, - "facing=south,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:door/library_top" }, - "facing=west,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:door/library_top", "y": 90 }, - "facing=north,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:door/library_top", "y": 180 }, - "facing=east,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:door/library_bottom" }, - "facing=south,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:door/library_bottom", "y": 90 }, - "facing=west,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:door/library_bottom", "y": 180 }, - "facing=north,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:door/library_bottom", "y": 270 }, - "facing=east,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:door/library_bottom_rh" }, - "facing=south,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:door/library_bottom_rh", "y": 90 }, - "facing=west,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:door/library_bottom_rh", "y": 180 }, - "facing=north,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:door/library_bottom_rh", "y": 270 }, - "facing=east,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:door/library_bottom_rh", "y": 90 }, - "facing=south,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:door/library_bottom_rh", "y": 180 }, - "facing=west,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:door/library_bottom_rh", "y": 270 }, - "facing=north,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:door/library_bottom_rh" }, - "facing=east,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:door/library_bottom", "y": 270 }, - "facing=south,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:door/library_bottom" }, - "facing=west,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:door/library_bottom", "y": 90 }, - "facing=north,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:door/library_bottom", "y": 180 }, - "facing=east,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:door/library_top" }, - "facing=south,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:door/library_top", "y": 90 }, - "facing=west,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:door/library_top", "y": 180 }, - "facing=north,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:door/library_top", "y": 270 }, - "facing=east,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:door/library_top_rh" }, - "facing=south,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:door/library_top_rh", "y": 90 }, - "facing=west,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:door/library_top_rh", "y": 180 }, - "facing=north,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:door/library_top_rh", "y": 270 }, - "facing=east,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:door/library_top_rh", "y": 90 }, - "facing=south,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:door/library_top_rh", "y": 180 }, - "facing=west,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:door/library_top_rh", "y": 270 }, - "facing=north,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:door/library_top_rh" }, - "facing=east,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:door/library_top", "y": 270 }, - "facing=south,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:door/library_top" }, - "facing=west,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:door/library_top", "y": 90 }, - "facing=north,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:door/library_top", "y": 180 } + "facing=east,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/cloud_bottom" }, + "facing=south,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/cloud_bottom", "y": 90 }, + "facing=west,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/cloud_bottom", "y": 180 }, + "facing=north,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/cloud_bottom", "y": 270 }, + "facing=east,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/cloud_bottom_rh" }, + "facing=south,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/cloud_bottom_rh", "y": 90 }, + "facing=west,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/cloud_bottom_rh", "y": 180 }, + "facing=north,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/cloud_bottom_rh", "y": 270 }, + "facing=east,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/cloud_bottom_rh", "y": 90 }, + "facing=south,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/cloud_bottom_rh", "y": 180 }, + "facing=west,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/cloud_bottom_rh", "y": 270 }, + "facing=north,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/cloud_bottom_rh" }, + "facing=east,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/cloud_bottom", "y": 270 }, + "facing=south,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/cloud_bottom" }, + "facing=west,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/cloud_bottom", "y": 90 }, + "facing=north,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/cloud_bottom", "y": 180 }, + "facing=east,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/cloud_top" }, + "facing=south,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/cloud_top", "y": 90 }, + "facing=west,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/cloud_top", "y": 180 }, + "facing=north,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/cloud_top", "y": 270 }, + "facing=east,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/cloud_top_rh" }, + "facing=south,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/cloud_top_rh", "y": 90 }, + "facing=west,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/cloud_top_rh", "y": 180 }, + "facing=north,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/cloud_top_rh", "y": 270 }, + "facing=east,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/cloud_top_rh", "y": 90 }, + "facing=south,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/cloud_top_rh", "y": 180 }, + "facing=west,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/cloud_top_rh", "y": 270 }, + "facing=north,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/cloud_top_rh" }, + "facing=east,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/cloud_top", "y": 270 }, + "facing=south,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/cloud_top" }, + "facing=west,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/cloud_top", "y": 90 }, + "facing=north,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/cloud_top", "y": 180 }, + "facing=east,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/cloud_bottom" }, + "facing=south,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/cloud_bottom", "y": 90 }, + "facing=west,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/cloud_bottom", "y": 180 }, + "facing=north,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/cloud_bottom", "y": 270 }, + "facing=east,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/cloud_bottom_rh" }, + "facing=south,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/cloud_bottom_rh", "y": 90 }, + "facing=west,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/cloud_bottom_rh", "y": 180 }, + "facing=north,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/cloud_bottom_rh", "y": 270 }, + "facing=east,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/cloud_bottom_rh", "y": 90 }, + "facing=south,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/cloud_bottom_rh", "y": 180 }, + "facing=west,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/cloud_bottom_rh", "y": 270 }, + "facing=north,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/cloud_bottom_rh" }, + "facing=east,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/cloud_bottom", "y": 270 }, + "facing=south,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/cloud_bottom" }, + "facing=west,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/cloud_bottom", "y": 90 }, + "facing=north,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/cloud_bottom", "y": 180 }, + "facing=east,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/cloud_top" }, + "facing=south,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/cloud_top", "y": 90 }, + "facing=west,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/cloud_top", "y": 180 }, + "facing=north,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/cloud_top", "y": 270 }, + "facing=east,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/cloud_top_rh" }, + "facing=south,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/cloud_top_rh", "y": 90 }, + "facing=west,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/cloud_top_rh", "y": 180 }, + "facing=north,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/cloud_top_rh", "y": 270 }, + "facing=east,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/cloud_top_rh", "y": 90 }, + "facing=south,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/cloud_top_rh", "y": 180 }, + "facing=west,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/cloud_top_rh", "y": 270 }, + "facing=north,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/cloud_top_rh" }, + "facing=east,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/cloud_top", "y": 270 }, + "facing=south,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/cloud_top" }, + "facing=west,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/cloud_top", "y": 90 }, + "facing=north,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/cloud_top", "y": 180 } } } diff --git a/src/main/resources/assets/unicopia/blockstates/cloud_plank_slab.json b/src/main/resources/assets/unicopia/blockstates/cloud_plank_slab.json new file mode 100644 index 00000000..67564af0 --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/cloud_plank_slab.json @@ -0,0 +1,7 @@ +{ + "variants": { + "type=double": { "model": "unicopia:block/cloud_planks" }, + "type=bottom": { "model": "unicopia:block/cloud_plank_slab" }, + "type=top": { "model": "unicopia:block/cloud_plank_slab_top" } + } +} diff --git a/src/main/resources/assets/unicopia/blockstates/cloud_plank_stairs.json b/src/main/resources/assets/unicopia/blockstates/cloud_plank_stairs.json new file mode 100644 index 00000000..1e0882f0 --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/cloud_plank_stairs.json @@ -0,0 +1,209 @@ +{ + "variants": { + "facing=east,half=bottom,shape=inner_left": { + "model": "unicopia:block/cloud_plank_stairs_inner", + "uvlock": true, + "y": 270 + }, + "facing=east,half=bottom,shape=inner_right": { + "model": "unicopia:block/cloud_plank_stairs_inner" + }, + "facing=east,half=bottom,shape=outer_left": { + "model": "unicopia:block/cloud_plank_stairs_outer", + "uvlock": true, + "y": 270 + }, + "facing=east,half=bottom,shape=outer_right": { + "model": "unicopia:block/cloud_plank_stairs_outer" + }, + "facing=east,half=bottom,shape=straight": { + "model": "unicopia:block/cloud_plank_stairs" + }, + "facing=east,half=top,shape=inner_left": { + "model": "unicopia:block/cloud_plank_stairs_inner", + "uvlock": true, + "x": 180 + }, + "facing=east,half=top,shape=inner_right": { + "model": "unicopia:block/cloud_plank_stairs_inner", + "uvlock": true, + "x": 180, + "y": 90 + }, + "facing=east,half=top,shape=outer_left": { + "model": "unicopia:block/cloud_plank_stairs_outer", + "uvlock": true, + "x": 180 + }, + "facing=east,half=top,shape=outer_right": { + "model": "unicopia:block/cloud_plank_stairs_outer", + "uvlock": true, + "x": 180, + "y": 90 + }, + "facing=east,half=top,shape=straight": { + "model": "unicopia:block/cloud_plank_stairs", + "uvlock": true, + "x": 180 + }, + "facing=north,half=bottom,shape=inner_left": { + "model": "unicopia:block/cloud_plank_stairs_inner", + "uvlock": true, + "y": 180 + }, + "facing=north,half=bottom,shape=inner_right": { + "model": "unicopia:block/cloud_plank_stairs_inner", + "uvlock": true, + "y": 270 + }, + "facing=north,half=bottom,shape=outer_left": { + "model": "unicopia:block/cloud_plank_stairs_outer", + "uvlock": true, + "y": 180 + }, + "facing=north,half=bottom,shape=outer_right": { + "model": "unicopia:block/cloud_plank_stairs_outer", + "uvlock": true, + "y": 270 + }, + "facing=north,half=bottom,shape=straight": { + "model": "unicopia:block/cloud_plank_stairs", + "uvlock": true, + "y": 270 + }, + "facing=north,half=top,shape=inner_left": { + "model": "unicopia:block/cloud_plank_stairs_inner", + "uvlock": true, + "x": 180, + "y": 270 + }, + "facing=north,half=top,shape=inner_right": { + "model": "unicopia:block/cloud_plank_stairs_inner", + "uvlock": true, + "x": 180 + }, + "facing=north,half=top,shape=outer_left": { + "model": "unicopia:block/cloud_plank_stairs_outer", + "uvlock": true, + "x": 180, + "y": 270 + }, + "facing=north,half=top,shape=outer_right": { + "model": "unicopia:block/cloud_plank_stairs_outer", + "uvlock": true, + "x": 180 + }, + "facing=north,half=top,shape=straight": { + "model": "unicopia:block/cloud_plank_stairs", + "uvlock": true, + "x": 180, + "y": 270 + }, + "facing=south,half=bottom,shape=inner_left": { + "model": "unicopia:block/cloud_plank_stairs_inner" + }, + "facing=south,half=bottom,shape=inner_right": { + "model": "unicopia:block/cloud_plank_stairs_inner", + "uvlock": true, + "y": 90 + }, + "facing=south,half=bottom,shape=outer_left": { + "model": "unicopia:block/cloud_plank_stairs_outer" + }, + "facing=south,half=bottom,shape=outer_right": { + "model": "unicopia:block/cloud_plank_stairs_outer", + "uvlock": true, + "y": 90 + }, + "facing=south,half=bottom,shape=straight": { + "model": "unicopia:block/cloud_plank_stairs", + "uvlock": true, + "y": 90 + }, + "facing=south,half=top,shape=inner_left": { + "model": "unicopia:block/cloud_plank_stairs_inner", + "uvlock": true, + "x": 180, + "y": 90 + }, + "facing=south,half=top,shape=inner_right": { + "model": "unicopia:block/cloud_plank_stairs_inner", + "uvlock": true, + "x": 180, + "y": 180 + }, + "facing=south,half=top,shape=outer_left": { + "model": "unicopia:block/cloud_plank_stairs_outer", + "uvlock": true, + "x": 180, + "y": 90 + }, + "facing=south,half=top,shape=outer_right": { + "model": "unicopia:block/cloud_plank_stairs_outer", + "uvlock": true, + "x": 180, + "y": 180 + }, + "facing=south,half=top,shape=straight": { + "model": "unicopia:block/cloud_plank_stairs", + "uvlock": true, + "x": 180, + "y": 90 + }, + "facing=west,half=bottom,shape=inner_left": { + "model": "unicopia:block/cloud_plank_stairs_inner", + "uvlock": true, + "y": 90 + }, + "facing=west,half=bottom,shape=inner_right": { + "model": "unicopia:block/cloud_plank_stairs_inner", + "uvlock": true, + "y": 180 + }, + "facing=west,half=bottom,shape=outer_left": { + "model": "unicopia:block/cloud_plank_stairs_outer", + "uvlock": true, + "y": 90 + }, + "facing=west,half=bottom,shape=outer_right": { + "model": "unicopia:block/cloud_plank_stairs_outer", + "uvlock": true, + "y": 180 + }, + "facing=west,half=bottom,shape=straight": { + "model": "unicopia:block/cloud_plank_stairs", + "uvlock": true, + "y": 180 + }, + "facing=west,half=top,shape=inner_left": { + "model": "unicopia:block/cloud_plank_stairs_inner", + "uvlock": true, + "x": 180, + "y": 180 + }, + "facing=west,half=top,shape=inner_right": { + "model": "unicopia:block/cloud_plank_stairs_inner", + "uvlock": true, + "x": 180, + "y": 270 + }, + "facing=west,half=top,shape=outer_left": { + "model": "unicopia:block/cloud_plank_stairs_outer", + "uvlock": true, + "x": 180, + "y": 180 + }, + "facing=west,half=top,shape=outer_right": { + "model": "unicopia:block/cloud_plank_stairs_outer", + "uvlock": true, + "x": 180, + "y": 270 + }, + "facing=west,half=top,shape=straight": { + "model": "unicopia:block/cloud_plank_stairs", + "uvlock": true, + "x": 180, + "y": 180 + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/blockstates/cloud_planks_slab.json b/src/main/resources/assets/unicopia/blockstates/cloud_planks_slab.json deleted file mode 100644 index c4f11fb2..00000000 --- a/src/main/resources/assets/unicopia/blockstates/cloud_planks_slab.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "variants": { - "type=double": { "model": "unicopia:block/cloud_planks" }, - "type=bottom": { "model": "unicopia:block/cloud_planks_slab" }, - "type=top": { "model": "unicopia:block/cloud_planks_slab_top" } - } -} diff --git a/src/main/resources/assets/unicopia/blockstates/compacted_cloud_bricks.json b/src/main/resources/assets/unicopia/blockstates/compacted_cloud_bricks.json new file mode 100644 index 00000000..6406a516 --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/compacted_cloud_bricks.json @@ -0,0 +1,268 @@ +{ + "multipart": [ + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_full", "uvlock": true }, + "when": { "down": true, "north": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_x", "uvlock": true }, + "when": { "down": true, "north": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_y", "uvlock": true }, + "when": { "down": false, "north": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_z", "uvlock": true }, + "when": { "down": true, "north": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xz", "uvlock": true }, + "when": { "down": true, "north": false, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xy", "uvlock": true }, + "when": { "down": false, "north": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_yz", "uvlock": true }, + "when": { "down": false, "north": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xyz", "uvlock": true }, + "when": { "down": false, "north": false, "east": false } + }, + + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_full", "uvlock": true, "y": 90 }, + "when": { "down": true, "south": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_z", "uvlock": true, "y": 90 }, + "when": { "down": true, "south": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_y", "uvlock": true, "y": 90 }, + "when": { "down": false, "south": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_x", "uvlock": true, "y": 90 }, + "when": { "down": true, "south": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xz", "uvlock": true, "y": 90 }, + "when": { "down": true, "south": false, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_yz", "uvlock": true, "y": 90 }, + "when": { "down": false, "south": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xy", "uvlock": true, "y": 90 }, + "when": { "down": false, "south": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xyz", "uvlock": true, "y": 90 }, + "when": { "down": false, "south": false, "east": false } + }, + + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_full", "uvlock": true, "y": 180 }, + "when": { "down": true, "south": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_x", "uvlock": true, "y": 180 }, + "when": { "down": true, "south": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_y", "uvlock": true, "y": 180 }, + "when": { "down": false, "south": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_z", "uvlock": true, "y": 180 }, + "when": { "down": true, "south": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xz", "uvlock": true, "y": 180 }, + "when": { "down": true, "south": false, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xy", "uvlock": true, "y": 180 }, + "when": { "down": false, "south": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_yz", "uvlock": true, "y": 180 }, + "when": { "down": false, "south": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xyz", "uvlock": true, "y": 180 }, + "when": { "down": false, "south": false, "west": false } + }, + + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_full", "uvlock": true, "y": 270 }, + "when": { "down": true, "north": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_z", "uvlock": true, "y": 270 }, + "when": { "down": true, "north": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_y", "uvlock": true, "y": 270 }, + "when": { "down": false, "north": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_x", "uvlock": true, "y": 270 }, + "when": { "down": true, "north": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xz", "uvlock": true, "y": 270 }, + "when": { "down": true, "north": false, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_yz", "uvlock": true, "y": 270 }, + "when": { "down": false, "north": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xy", "uvlock": true, "y": 270 }, + "when": { "down": false, "north": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xyz", "uvlock": true, "y": 270 }, + "when": { "down": false, "north": false, "west": false } + }, + + + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_full", "uvlock": true, "x": 180 }, + "when": { "up": true, "south": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_x", "uvlock": true, "x": 180 }, + "when": { "up": true, "south": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_y", "uvlock": true, "x": 180 }, + "when": { "up": false, "south": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_z", "uvlock": true, "x": 180 }, + "when": { "up": true, "south": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xz", "uvlock": true, "x": 180 }, + "when": { "up": true, "south": false, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xy", "uvlock": true, "x": 180 }, + "when": { "up": false, "south": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_yz", "uvlock": true, "x": 180 }, + "when": { "up": false, "south": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xyz", "uvlock": true, "x": 180 }, + "when": { "up": false, "south": false, "east": false } + }, + + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_full", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": true, "south": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_z", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": true, "south": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_y", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": false, "south": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_x", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": true, "south": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xz", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": true, "south": false, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_yz", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": false, "south": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xy", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": false, "south": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xyz", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": false, "south": false, "west": false } + }, + + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_full", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": true, "north": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_x", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": true, "north": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_y", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": false, "north": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_z", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": true, "north": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xz", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": true, "north": false, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xy", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": false, "north": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_yz", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": false, "north": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xyz", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": false, "north": false, "west": false } + }, + + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_full", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": true, "north": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_z", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": true, "north": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_y", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": false, "north": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_x", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": true, "north": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xz", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": true, "north": false, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_yz", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": false, "north": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xy", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": false, "north": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_cloud_bricks_corner_xyz", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": false, "north": false, "east": false } + } + ] +} diff --git a/src/main/resources/assets/unicopia/blockstates/compacted_dense_cloud.json b/src/main/resources/assets/unicopia/blockstates/compacted_dense_cloud.json new file mode 100644 index 00000000..087d05e7 --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/compacted_dense_cloud.json @@ -0,0 +1,268 @@ +{ + "multipart": [ + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_full", "uvlock": true }, + "when": { "down": true, "north": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_x", "uvlock": true }, + "when": { "down": true, "north": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_y", "uvlock": true }, + "when": { "down": false, "north": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_z", "uvlock": true }, + "when": { "down": true, "north": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xz", "uvlock": true }, + "when": { "down": true, "north": false, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xy", "uvlock": true }, + "when": { "down": false, "north": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_yz", "uvlock": true }, + "when": { "down": false, "north": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xyz", "uvlock": true }, + "when": { "down": false, "north": false, "east": false } + }, + + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_full", "uvlock": true, "y": 90 }, + "when": { "down": true, "south": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_z", "uvlock": true, "y": 90 }, + "when": { "down": true, "south": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_y", "uvlock": true, "y": 90 }, + "when": { "down": false, "south": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_x", "uvlock": true, "y": 90 }, + "when": { "down": true, "south": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xz", "uvlock": true, "y": 90 }, + "when": { "down": true, "south": false, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_yz", "uvlock": true, "y": 90 }, + "when": { "down": false, "south": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xy", "uvlock": true, "y": 90 }, + "when": { "down": false, "south": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xyz", "uvlock": true, "y": 90 }, + "when": { "down": false, "south": false, "east": false } + }, + + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_full", "uvlock": true, "y": 180 }, + "when": { "down": true, "south": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_x", "uvlock": true, "y": 180 }, + "when": { "down": true, "south": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_y", "uvlock": true, "y": 180 }, + "when": { "down": false, "south": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_z", "uvlock": true, "y": 180 }, + "when": { "down": true, "south": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xz", "uvlock": true, "y": 180 }, + "when": { "down": true, "south": false, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xy", "uvlock": true, "y": 180 }, + "when": { "down": false, "south": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_yz", "uvlock": true, "y": 180 }, + "when": { "down": false, "south": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xyz", "uvlock": true, "y": 180 }, + "when": { "down": false, "south": false, "west": false } + }, + + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_full", "uvlock": true, "y": 270 }, + "when": { "down": true, "north": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_z", "uvlock": true, "y": 270 }, + "when": { "down": true, "north": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_y", "uvlock": true, "y": 270 }, + "when": { "down": false, "north": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_x", "uvlock": true, "y": 270 }, + "when": { "down": true, "north": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xz", "uvlock": true, "y": 270 }, + "when": { "down": true, "north": false, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_yz", "uvlock": true, "y": 270 }, + "when": { "down": false, "north": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xy", "uvlock": true, "y": 270 }, + "when": { "down": false, "north": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xyz", "uvlock": true, "y": 270 }, + "when": { "down": false, "north": false, "west": false } + }, + + + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_full", "uvlock": true, "x": 180 }, + "when": { "up": true, "south": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_x", "uvlock": true, "x": 180 }, + "when": { "up": true, "south": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_y", "uvlock": true, "x": 180 }, + "when": { "up": false, "south": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_z", "uvlock": true, "x": 180 }, + "when": { "up": true, "south": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xz", "uvlock": true, "x": 180 }, + "when": { "up": true, "south": false, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xy", "uvlock": true, "x": 180 }, + "when": { "up": false, "south": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_yz", "uvlock": true, "x": 180 }, + "when": { "up": false, "south": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xyz", "uvlock": true, "x": 180 }, + "when": { "up": false, "south": false, "east": false } + }, + + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_full", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": true, "south": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_z", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": true, "south": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_y", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": false, "south": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_x", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": true, "south": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xz", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": true, "south": false, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_yz", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": false, "south": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xy", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": false, "south": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xyz", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": false, "south": false, "west": false } + }, + + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_full", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": true, "north": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_x", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": true, "north": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_y", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": false, "north": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_z", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": true, "north": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xz", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": true, "north": false, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xy", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": false, "north": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_yz", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": false, "north": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xyz", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": false, "north": false, "west": false } + }, + + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_full", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": true, "north": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_z", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": true, "north": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_y", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": false, "north": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_x", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": true, "north": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xz", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": true, "north": false, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_yz", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": false, "north": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xy", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": false, "north": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_dense_cloud_corner_xyz", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": false, "north": false, "east": false } + } + ] +} diff --git a/src/main/resources/assets/unicopia/blockstates/compacted_etched_cloud.json b/src/main/resources/assets/unicopia/blockstates/compacted_etched_cloud.json new file mode 100644 index 00000000..7490f4f6 --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/compacted_etched_cloud.json @@ -0,0 +1,268 @@ +{ + "multipart": [ + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_full", "uvlock": true }, + "when": { "down": true, "north": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_x", "uvlock": true }, + "when": { "down": true, "north": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_y", "uvlock": true }, + "when": { "down": false, "north": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_z", "uvlock": true }, + "when": { "down": true, "north": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xz", "uvlock": true }, + "when": { "down": true, "north": false, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xy", "uvlock": true }, + "when": { "down": false, "north": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_yz", "uvlock": true }, + "when": { "down": false, "north": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xyz", "uvlock": true }, + "when": { "down": false, "north": false, "east": false } + }, + + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_full", "uvlock": true, "y": 90 }, + "when": { "down": true, "south": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_z", "uvlock": true, "y": 90 }, + "when": { "down": true, "south": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_y", "uvlock": true, "y": 90 }, + "when": { "down": false, "south": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_x", "uvlock": true, "y": 90 }, + "when": { "down": true, "south": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xz", "uvlock": true, "y": 90 }, + "when": { "down": true, "south": false, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_yz", "uvlock": true, "y": 90 }, + "when": { "down": false, "south": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xy", "uvlock": true, "y": 90 }, + "when": { "down": false, "south": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xyz", "uvlock": true, "y": 90 }, + "when": { "down": false, "south": false, "east": false } + }, + + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_full", "uvlock": true, "y": 180 }, + "when": { "down": true, "south": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_x", "uvlock": true, "y": 180 }, + "when": { "down": true, "south": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_y", "uvlock": true, "y": 180 }, + "when": { "down": false, "south": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_z", "uvlock": true, "y": 180 }, + "when": { "down": true, "south": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xz", "uvlock": true, "y": 180 }, + "when": { "down": true, "south": false, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xy", "uvlock": true, "y": 180 }, + "when": { "down": false, "south": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_yz", "uvlock": true, "y": 180 }, + "when": { "down": false, "south": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xyz", "uvlock": true, "y": 180 }, + "when": { "down": false, "south": false, "west": false } + }, + + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_full", "uvlock": true, "y": 270 }, + "when": { "down": true, "north": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_z", "uvlock": true, "y": 270 }, + "when": { "down": true, "north": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_y", "uvlock": true, "y": 270 }, + "when": { "down": false, "north": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_x", "uvlock": true, "y": 270 }, + "when": { "down": true, "north": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xz", "uvlock": true, "y": 270 }, + "when": { "down": true, "north": false, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_yz", "uvlock": true, "y": 270 }, + "when": { "down": false, "north": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xy", "uvlock": true, "y": 270 }, + "when": { "down": false, "north": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xyz", "uvlock": true, "y": 270 }, + "when": { "down": false, "north": false, "west": false } + }, + + + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_full", "uvlock": true, "x": 180 }, + "when": { "up": true, "south": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_x", "uvlock": true, "x": 180 }, + "when": { "up": true, "south": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_y", "uvlock": true, "x": 180 }, + "when": { "up": false, "south": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_z", "uvlock": true, "x": 180 }, + "when": { "up": true, "south": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xz", "uvlock": true, "x": 180 }, + "when": { "up": true, "south": false, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xy", "uvlock": true, "x": 180 }, + "when": { "up": false, "south": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_yz", "uvlock": true, "x": 180 }, + "when": { "up": false, "south": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xyz", "uvlock": true, "x": 180 }, + "when": { "up": false, "south": false, "east": false } + }, + + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_full", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": true, "south": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_z", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": true, "south": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_y", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": false, "south": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_x", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": true, "south": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xz", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": true, "south": false, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_yz", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": false, "south": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xy", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": false, "south": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xyz", "uvlock": true, "x": 180, "y": 90 }, + "when": { "up": false, "south": false, "west": false } + }, + + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_full", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": true, "north": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_x", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": true, "north": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_y", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": false, "north": true, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_z", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": true, "north": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xz", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": true, "north": false, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xy", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": false, "north": true, "west": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_yz", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": false, "north": false, "west": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xyz", "uvlock": true, "x": 180, "y": 180 }, + "when": { "up": false, "north": false, "west": false } + }, + + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_full", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": true, "north": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_z", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": true, "north": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_y", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": false, "north": true, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_x", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": true, "north": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xz", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": true, "north": false, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_yz", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": false, "north": true, "east": false } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xy", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": false, "north": false, "east": true } + }, + { + "apply": { "model": "unicopia:block/flattened_etched_cloud_corner_xyz", "uvlock": true, "x": 180, "y": 270 }, + "when": { "up": false, "north": false, "east": false } + } + ] +} diff --git a/src/main/resources/assets/unicopia/blockstates/crystal_door.json b/src/main/resources/assets/unicopia/blockstates/crystal_door.json new file mode 100644 index 00000000..15184fa7 --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/crystal_door.json @@ -0,0 +1,68 @@ +{ + "variants": { + "facing=east,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/crystal_bottom" }, + "facing=south,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/crystal_bottom", "y": 90 }, + "facing=west,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/crystal_bottom", "y": 180 }, + "facing=north,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/crystal_bottom", "y": 270 }, + "facing=east,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/crystal_bottom_rh" }, + "facing=south,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/crystal_bottom_rh", "y": 90 }, + "facing=west,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/crystal_bottom_rh", "y": 180 }, + "facing=north,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/crystal_bottom_rh", "y": 270 }, + "facing=east,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/crystal_bottom_rh", "y": 90 }, + "facing=south,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/crystal_bottom_rh", "y": 180 }, + "facing=west,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/crystal_bottom_rh", "y": 270 }, + "facing=north,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/crystal_bottom_rh" }, + "facing=east,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/crystal_bottom", "y": 270 }, + "facing=south,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/crystal_bottom" }, + "facing=west,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/crystal_bottom", "y": 90 }, + "facing=north,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/crystal_bottom", "y": 180 }, + "facing=east,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/crystal_top" }, + "facing=south,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/crystal_top", "y": 90 }, + "facing=west,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/crystal_top", "y": 180 }, + "facing=north,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/crystal_top", "y": 270 }, + "facing=east,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/crystal_top_rh" }, + "facing=south,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/crystal_top_rh", "y": 90 }, + "facing=west,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/crystal_top_rh", "y": 180 }, + "facing=north,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/crystal_top_rh", "y": 270 }, + "facing=east,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/crystal_top_rh", "y": 90 }, + "facing=south,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/crystal_top_rh", "y": 180 }, + "facing=west,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/crystal_top_rh", "y": 270 }, + "facing=north,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/crystal_top_rh" }, + "facing=east,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/crystal_top", "y": 270 }, + "facing=south,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/crystal_top" }, + "facing=west,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/crystal_top", "y": 90 }, + "facing=north,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/crystal_top", "y": 180 }, + "facing=east,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/crystal_bottom" }, + "facing=south,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/crystal_bottom", "y": 90 }, + "facing=west,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/crystal_bottom", "y": 180 }, + "facing=north,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/crystal_bottom", "y": 270 }, + "facing=east,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/crystal_bottom_rh" }, + "facing=south,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/crystal_bottom_rh", "y": 90 }, + "facing=west,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/crystal_bottom_rh", "y": 180 }, + "facing=north,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/crystal_bottom_rh", "y": 270 }, + "facing=east,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/crystal_bottom_rh", "y": 90 }, + "facing=south,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/crystal_bottom_rh", "y": 180 }, + "facing=west,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/crystal_bottom_rh", "y": 270 }, + "facing=north,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/crystal_bottom_rh" }, + "facing=east,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/crystal_bottom", "y": 270 }, + "facing=south,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/crystal_bottom" }, + "facing=west,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/crystal_bottom", "y": 90 }, + "facing=north,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/crystal_bottom", "y": 180 }, + "facing=east,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/crystal_top" }, + "facing=south,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/crystal_top", "y": 90 }, + "facing=west,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/crystal_top", "y": 180 }, + "facing=north,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/crystal_top", "y": 270 }, + "facing=east,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/crystal_top_rh" }, + "facing=south,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/crystal_top_rh", "y": 90 }, + "facing=west,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/crystal_top_rh", "y": 180 }, + "facing=north,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/crystal_top_rh", "y": 270 }, + "facing=east,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/crystal_top_rh", "y": 90 }, + "facing=south,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/crystal_top_rh", "y": 180 }, + "facing=west,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/crystal_top_rh", "y": 270 }, + "facing=north,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/crystal_top_rh" }, + "facing=east,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/crystal_top", "y": 270 }, + "facing=south,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/crystal_top" }, + "facing=west,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/crystal_top", "y": 90 }, + "facing=north,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/crystal_top", "y": 180 } + } +} diff --git a/src/main/resources/assets/unicopia/blockstates/dark_oak_stable_door.json b/src/main/resources/assets/unicopia/blockstates/dark_oak_stable_door.json new file mode 100644 index 00000000..7cc92f37 --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/dark_oak_stable_door.json @@ -0,0 +1,68 @@ +{ + "variants": { + "facing=east,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/dark_oak_stable_bottom" }, + "facing=south,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/dark_oak_stable_bottom", "y": 90 }, + "facing=west,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/dark_oak_stable_bottom", "y": 180 }, + "facing=north,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/dark_oak_stable_bottom", "y": 270 }, + "facing=east,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/dark_oak_stable_bottom_rh" }, + "facing=south,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/dark_oak_stable_bottom_rh", "y": 90 }, + "facing=west,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/dark_oak_stable_bottom_rh", "y": 180 }, + "facing=north,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/dark_oak_stable_bottom_rh", "y": 270 }, + "facing=east,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/dark_oak_stable_bottom_rh", "y": 90 }, + "facing=south,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/dark_oak_stable_bottom_rh", "y": 180 }, + "facing=west,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/dark_oak_stable_bottom_rh", "y": 270 }, + "facing=north,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/dark_oak_stable_bottom_rh" }, + "facing=east,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/dark_oak_stable_bottom", "y": 270 }, + "facing=south,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/dark_oak_stable_bottom" }, + "facing=west,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/dark_oak_stable_bottom", "y": 90 }, + "facing=north,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/dark_oak_stable_bottom", "y": 180 }, + "facing=east,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/dark_oak_stable_top" }, + "facing=south,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/dark_oak_stable_top", "y": 90 }, + "facing=west,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/dark_oak_stable_top", "y": 180 }, + "facing=north,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/dark_oak_stable_top", "y": 270 }, + "facing=east,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/dark_oak_stable_top_rh" }, + "facing=south,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/dark_oak_stable_top_rh", "y": 90 }, + "facing=west,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/dark_oak_stable_top_rh", "y": 180 }, + "facing=north,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/dark_oak_stable_top_rh", "y": 270 }, + "facing=east,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/dark_oak_stable_top_rh", "y": 90 }, + "facing=south,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/dark_oak_stable_top_rh", "y": 180 }, + "facing=west,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/dark_oak_stable_top_rh", "y": 270 }, + "facing=north,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/dark_oak_stable_top_rh" }, + "facing=east,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/dark_oak_stable_top", "y": 270 }, + "facing=south,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/dark_oak_stable_top" }, + "facing=west,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/dark_oak_stable_top", "y": 90 }, + "facing=north,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/dark_oak_stable_top", "y": 180 }, + "facing=east,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/dark_oak_stable_bottom" }, + "facing=south,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/dark_oak_stable_bottom", "y": 90 }, + "facing=west,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/dark_oak_stable_bottom", "y": 180 }, + "facing=north,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/dark_oak_stable_bottom", "y": 270 }, + "facing=east,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/dark_oak_stable_bottom_rh" }, + "facing=south,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/dark_oak_stable_bottom_rh", "y": 90 }, + "facing=west,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/dark_oak_stable_bottom_rh", "y": 180 }, + "facing=north,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/dark_oak_stable_bottom_rh", "y": 270 }, + "facing=east,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/dark_oak_stable_bottom_rh", "y": 90 }, + "facing=south,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/dark_oak_stable_bottom_rh", "y": 180 }, + "facing=west,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/dark_oak_stable_bottom_rh", "y": 270 }, + "facing=north,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/dark_oak_stable_bottom_rh" }, + "facing=east,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/dark_oak_stable_bottom", "y": 270 }, + "facing=south,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/dark_oak_stable_bottom" }, + "facing=west,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/dark_oak_stable_bottom", "y": 90 }, + "facing=north,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/dark_oak_stable_bottom", "y": 180 }, + "facing=east,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/dark_oak_stable_top" }, + "facing=south,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/dark_oak_stable_top", "y": 90 }, + "facing=west,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/dark_oak_stable_top", "y": 180 }, + "facing=north,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/dark_oak_stable_top", "y": 270 }, + "facing=east,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/dark_oak_stable_top_rh" }, + "facing=south,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/dark_oak_stable_top_rh", "y": 90 }, + "facing=west,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/dark_oak_stable_top_rh", "y": 180 }, + "facing=north,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/dark_oak_stable_top_rh", "y": 270 }, + "facing=east,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/dark_oak_stable_top_rh", "y": 90 }, + "facing=south,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/dark_oak_stable_top_rh", "y": 180 }, + "facing=west,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/dark_oak_stable_top_rh", "y": 270 }, + "facing=north,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/dark_oak_stable_top_rh" }, + "facing=east,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/dark_oak_stable_top", "y": 270 }, + "facing=south,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/dark_oak_stable_top" }, + "facing=west,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/dark_oak_stable_top", "y": 90 }, + "facing=north,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/dark_oak_stable_top", "y": 180 } + } +} diff --git a/src/main/resources/assets/unicopia/blockstates/etched_cloud.json b/src/main/resources/assets/unicopia/blockstates/etched_cloud.json new file mode 100644 index 00000000..89ffa3ff --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/etched_cloud.json @@ -0,0 +1,5 @@ +{ + "variants": { + "": { "model": "unicopia:block/etched_cloud" } + } +} diff --git a/src/main/resources/assets/unicopia/blockstates/etched_cloud_slab.json b/src/main/resources/assets/unicopia/blockstates/etched_cloud_slab.json new file mode 100644 index 00000000..faaf5c94 --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/etched_cloud_slab.json @@ -0,0 +1,7 @@ +{ + "variants": { + "type=double": { "model": "unicopia:block/etched_cloud" }, + "type=bottom": { "model": "unicopia:block/etched_cloud_slab" }, + "type=top": { "model": "unicopia:block/etched_cloud_slab_top" } + } +} diff --git a/src/main/resources/assets/unicopia/blockstates/etched_cloud_stairs.json b/src/main/resources/assets/unicopia/blockstates/etched_cloud_stairs.json new file mode 100644 index 00000000..e8a09622 --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/etched_cloud_stairs.json @@ -0,0 +1,209 @@ +{ + "variants": { + "facing=east,half=bottom,shape=inner_left": { + "model": "unicopia:block/etched_cloud_stairs_inner", + "uvlock": true, + "y": 270 + }, + "facing=east,half=bottom,shape=inner_right": { + "model": "unicopia:block/etched_cloud_stairs_inner" + }, + "facing=east,half=bottom,shape=outer_left": { + "model": "unicopia:block/etched_cloud_stairs_outer", + "uvlock": true, + "y": 270 + }, + "facing=east,half=bottom,shape=outer_right": { + "model": "unicopia:block/etched_cloud_stairs_outer" + }, + "facing=east,half=bottom,shape=straight": { + "model": "unicopia:block/etched_cloud_stairs" + }, + "facing=east,half=top,shape=inner_left": { + "model": "unicopia:block/etched_cloud_stairs_inner", + "uvlock": true, + "x": 180 + }, + "facing=east,half=top,shape=inner_right": { + "model": "unicopia:block/etched_cloud_stairs_inner", + "uvlock": true, + "x": 180, + "y": 90 + }, + "facing=east,half=top,shape=outer_left": { + "model": "unicopia:block/etched_cloud_stairs_outer", + "uvlock": true, + "x": 180 + }, + "facing=east,half=top,shape=outer_right": { + "model": "unicopia:block/etched_cloud_stairs_outer", + "uvlock": true, + "x": 180, + "y": 90 + }, + "facing=east,half=top,shape=straight": { + "model": "unicopia:block/etched_cloud_stairs", + "uvlock": true, + "x": 180 + }, + "facing=north,half=bottom,shape=inner_left": { + "model": "unicopia:block/etched_cloud_stairs_inner", + "uvlock": true, + "y": 180 + }, + "facing=north,half=bottom,shape=inner_right": { + "model": "unicopia:block/etched_cloud_stairs_inner", + "uvlock": true, + "y": 270 + }, + "facing=north,half=bottom,shape=outer_left": { + "model": "unicopia:block/etched_cloud_stairs_outer", + "uvlock": true, + "y": 180 + }, + "facing=north,half=bottom,shape=outer_right": { + "model": "unicopia:block/etched_cloud_stairs_outer", + "uvlock": true, + "y": 270 + }, + "facing=north,half=bottom,shape=straight": { + "model": "unicopia:block/etched_cloud_stairs", + "uvlock": true, + "y": 270 + }, + "facing=north,half=top,shape=inner_left": { + "model": "unicopia:block/etched_cloud_stairs_inner", + "uvlock": true, + "x": 180, + "y": 270 + }, + "facing=north,half=top,shape=inner_right": { + "model": "unicopia:block/etched_cloud_stairs_inner", + "uvlock": true, + "x": 180 + }, + "facing=north,half=top,shape=outer_left": { + "model": "unicopia:block/etched_cloud_stairs_outer", + "uvlock": true, + "x": 180, + "y": 270 + }, + "facing=north,half=top,shape=outer_right": { + "model": "unicopia:block/etched_cloud_stairs_outer", + "uvlock": true, + "x": 180 + }, + "facing=north,half=top,shape=straight": { + "model": "unicopia:block/etched_cloud_stairs", + "uvlock": true, + "x": 180, + "y": 270 + }, + "facing=south,half=bottom,shape=inner_left": { + "model": "unicopia:block/etched_cloud_stairs_inner" + }, + "facing=south,half=bottom,shape=inner_right": { + "model": "unicopia:block/etched_cloud_stairs_inner", + "uvlock": true, + "y": 90 + }, + "facing=south,half=bottom,shape=outer_left": { + "model": "unicopia:block/etched_cloud_stairs_outer" + }, + "facing=south,half=bottom,shape=outer_right": { + "model": "unicopia:block/etched_cloud_stairs_outer", + "uvlock": true, + "y": 90 + }, + "facing=south,half=bottom,shape=straight": { + "model": "unicopia:block/etched_cloud_stairs", + "uvlock": true, + "y": 90 + }, + "facing=south,half=top,shape=inner_left": { + "model": "unicopia:block/etched_cloud_stairs_inner", + "uvlock": true, + "x": 180, + "y": 90 + }, + "facing=south,half=top,shape=inner_right": { + "model": "unicopia:block/etched_cloud_stairs_inner", + "uvlock": true, + "x": 180, + "y": 180 + }, + "facing=south,half=top,shape=outer_left": { + "model": "unicopia:block/etched_cloud_stairs_outer", + "uvlock": true, + "x": 180, + "y": 90 + }, + "facing=south,half=top,shape=outer_right": { + "model": "unicopia:block/etched_cloud_stairs_outer", + "uvlock": true, + "x": 180, + "y": 180 + }, + "facing=south,half=top,shape=straight": { + "model": "unicopia:block/etched_cloud_stairs", + "uvlock": true, + "x": 180, + "y": 90 + }, + "facing=west,half=bottom,shape=inner_left": { + "model": "unicopia:block/etched_cloud_stairs_inner", + "uvlock": true, + "y": 90 + }, + "facing=west,half=bottom,shape=inner_right": { + "model": "unicopia:block/etched_cloud_stairs_inner", + "uvlock": true, + "y": 180 + }, + "facing=west,half=bottom,shape=outer_left": { + "model": "unicopia:block/etched_cloud_stairs_outer", + "uvlock": true, + "y": 90 + }, + "facing=west,half=bottom,shape=outer_right": { + "model": "unicopia:block/etched_cloud_stairs_outer", + "uvlock": true, + "y": 180 + }, + "facing=west,half=bottom,shape=straight": { + "model": "unicopia:block/etched_cloud_stairs", + "uvlock": true, + "y": 180 + }, + "facing=west,half=top,shape=inner_left": { + "model": "unicopia:block/etched_cloud_stairs_inner", + "uvlock": true, + "x": 180, + "y": 180 + }, + "facing=west,half=top,shape=inner_right": { + "model": "unicopia:block/etched_cloud_stairs_inner", + "uvlock": true, + "x": 180, + "y": 270 + }, + "facing=west,half=top,shape=outer_left": { + "model": "unicopia:block/etched_cloud_stairs_outer", + "uvlock": true, + "x": 180, + "y": 180 + }, + "facing=west,half=top,shape=outer_right": { + "model": "unicopia:block/etched_cloud_stairs_outer", + "uvlock": true, + "x": 180, + "y": 270 + }, + "facing=west,half=top,shape=straight": { + "model": "unicopia:block/etched_cloud_stairs", + "uvlock": true, + "x": 180, + "y": 180 + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/blockstates/plunder_vine.json b/src/main/resources/assets/unicopia/blockstates/plunder_vine.json new file mode 100644 index 00000000..87b7ee61 --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/plunder_vine.json @@ -0,0 +1,128 @@ +{ + "multipart": [ + { + "apply": { "model": "unicopia:block/plunder_vine_branch" }, + "when": { "age": 0, "down": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch", "x": 180 }, + "when": { "age": 0, "up": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch", "x": 90 }, + "when": { "age": 0, "south": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch", "x": 90, "y": 90 }, + "when": { "age": 0, "west": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch", "x": 90, "y": 180 }, + "when": { "age": 0, "north": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch", "x": 90, "y": 270 }, + "when": { "age": 0, "east": true } + }, + + { + "apply": { "model": "unicopia:block/plunder_vine_branch_2" }, + "when": { "age": 1, "down": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_2", "x": 180 }, + "when": { "age": 1, "up": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_2", "x": 90 }, + "when": { "age": 1, "south": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_2", "x": 90, "y": 90 }, + "when": { "age": 1, "west": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_2", "x": 90, "y": 180 }, + "when": { "age": 1, "north": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_2", "x": 90, "y": 270 }, + "when": { "age": 1, "east": true } + }, + + { + "apply": { "model": "unicopia:block/plunder_vine_branch_3" }, + "when": { "age": 2, "down": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_3", "x": 180 }, + "when": { "age": 2, "up": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_3", "x": 90 }, + "when": { "age": 2, "south": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_3", "x": 90, "y": 90 }, + "when": { "age": 2, "west": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_3", "x": 90, "y": 180 }, + "when": { "age": 2, "north": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_3", "x": 90, "y": 270 }, + "when": { "age": 2, "east": true } + }, + + { + "apply": { "model": "unicopia:block/plunder_vine_branch_4" }, + "when": { "age": 3, "down": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_4", "x": 180 }, + "when": { "age": 3, "up": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_4", "x": 90 }, + "when": { "age": 3, "south": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_4", "x": 90, "y": 90 }, + "when": { "age": 3, "west": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_4", "x": 90, "y": 180 }, + "when": { "age": 3, "north": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_4", "x": 90, "y": 270 }, + "when": { "age": 3, "east": true } + }, + + { + "apply": { "model": "unicopia:block/plunder_vine_branch_4" }, + "when": { "age": 4, "down": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_4", "x": 180 }, + "when": { "age": 4, "up": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_4", "x": 90 }, + "when": { "age": 4, "south": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_4", "x": 90, "y": 90 }, + "when": { "age": 4, "west": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_4", "x": 90, "y": 180 }, + "when": { "age": 4, "north": true } + }, + { + "apply": { "model": "unicopia:block/plunder_vine_branch_4", "x": 90, "y": 270 }, + "when": { "age": 4, "east": true } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/blockstates/plunder_vine_bud.json b/src/main/resources/assets/unicopia/blockstates/plunder_vine_bud.json new file mode 100644 index 00000000..bf21be63 --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/plunder_vine_bud.json @@ -0,0 +1,10 @@ +{ + "variants": { + "facing=down": { "model": "unicopia:block/plunder_vine_bud" }, + "facing=up": { "model": "unicopia:block/plunder_vine_bud", "x": 180 }, + "facing=south": { "model": "unicopia:block/plunder_vine_bud", "x": 90 }, + "facing=west": { "model": "unicopia:block/plunder_vine_bud", "x": 90, "y": 90 }, + "facing=north": { "model": "unicopia:block/plunder_vine_bud", "x": 90, "y": 180 }, + "facing=east": { "model": "unicopia:block/plunder_vine_bud", "x": 90, "y": 270 } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/blockstates/scallop_shell.json b/src/main/resources/assets/unicopia/blockstates/scallop_shell.json new file mode 100644 index 00000000..92a7659f --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/scallop_shell.json @@ -0,0 +1,8 @@ +{ + "variants": { + "count=1": { "model": "unicopia:block/scallop_shell_1" }, + "count=2": { "model": "unicopia:block/scallop_shell_2" }, + "count=3": { "model": "unicopia:block/scallop_shell_3" }, + "count=4": { "model": "unicopia:block/scallop_shell_4" } + } +} diff --git a/src/main/resources/assets/unicopia/blockstates/shaping_bench.json b/src/main/resources/assets/unicopia/blockstates/shaping_bench.json new file mode 100644 index 00000000..fb0ebd3e --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/shaping_bench.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "unicopia:block/shaping_bench" + } + } +} diff --git a/src/main/resources/assets/unicopia/blockstates/bakery_door.json b/src/main/resources/assets/unicopia/blockstates/stable_door.json similarity index 50% rename from src/main/resources/assets/unicopia/blockstates/bakery_door.json rename to src/main/resources/assets/unicopia/blockstates/stable_door.json index 72faabed..01d4ec97 100644 --- a/src/main/resources/assets/unicopia/blockstates/bakery_door.json +++ b/src/main/resources/assets/unicopia/blockstates/stable_door.json @@ -1,68 +1,68 @@ { "variants": { - "facing=east,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:door/bakery_bottom" }, - "facing=south,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:door/bakery_bottom", "y": 90 }, - "facing=west,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:door/bakery_bottom", "y": 180 }, - "facing=north,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:door/bakery_bottom", "y": 270 }, - "facing=east,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:door/bakery_bottom_rh" }, - "facing=south,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:door/bakery_bottom_rh", "y": 90 }, - "facing=west,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:door/bakery_bottom_rh", "y": 180 }, - "facing=north,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:door/bakery_bottom_rh", "y": 270 }, - "facing=east,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:door/bakery_bottom_rh", "y": 90 }, - "facing=south,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:door/bakery_bottom_rh", "y": 180 }, - "facing=west,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:door/bakery_bottom_rh", "y": 270 }, - "facing=north,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:door/bakery_bottom_rh" }, - "facing=east,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:door/bakery_bottom", "y": 270 }, - "facing=south,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:door/bakery_bottom" }, - "facing=west,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:door/bakery_bottom", "y": 90 }, - "facing=north,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:door/bakery_bottom", "y": 180 }, - "facing=east,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:door/bakery_top" }, - "facing=south,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:door/bakery_top", "y": 90 }, - "facing=west,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:door/bakery_top", "y": 180 }, - "facing=north,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:door/bakery_top", "y": 270 }, - "facing=east,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:door/bakery_top_rh" }, - "facing=south,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:door/bakery_top_rh", "y": 90 }, - "facing=west,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:door/bakery_top_rh", "y": 180 }, - "facing=north,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:door/bakery_top_rh", "y": 270 }, - "facing=east,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:door/bakery_top_rh", "y": 90 }, - "facing=south,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:door/bakery_top_rh", "y": 180 }, - "facing=west,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:door/bakery_top_rh", "y": 270 }, - "facing=north,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:door/bakery_top_rh" }, - "facing=east,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:door/bakery_top", "y": 270 }, - "facing=south,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:door/bakery_top" }, - "facing=west,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:door/bakery_top", "y": 90 }, - "facing=north,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:door/bakery_top", "y": 180 }, - "facing=east,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:door/bakery_bottom" }, - "facing=south,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:door/bakery_bottom", "y": 90 }, - "facing=west,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:door/bakery_bottom", "y": 180 }, - "facing=north,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:door/bakery_bottom", "y": 270 }, - "facing=east,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:door/bakery_bottom_rh" }, - "facing=south,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:door/bakery_bottom_rh", "y": 90 }, - "facing=west,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:door/bakery_bottom_rh", "y": 180 }, - "facing=north,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:door/bakery_bottom_rh", "y": 270 }, - "facing=east,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:door/bakery_bottom_rh", "y": 90 }, - "facing=south,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:door/bakery_bottom_rh", "y": 180 }, - "facing=west,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:door/bakery_bottom_rh", "y": 270 }, - "facing=north,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:door/bakery_bottom_rh" }, - "facing=east,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:door/bakery_bottom", "y": 270 }, - "facing=south,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:door/bakery_bottom" }, - "facing=west,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:door/bakery_bottom", "y": 90 }, - "facing=north,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:door/bakery_bottom", "y": 180 }, - "facing=east,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:door/bakery_top" }, - "facing=south,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:door/bakery_top", "y": 90 }, - "facing=west,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:door/bakery_top", "y": 180 }, - "facing=north,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:door/bakery_top", "y": 270 }, - "facing=east,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:door/bakery_top_rh" }, - "facing=south,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:door/bakery_top_rh", "y": 90 }, - "facing=west,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:door/bakery_top_rh", "y": 180 }, - "facing=north,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:door/bakery_top_rh", "y": 270 }, - "facing=east,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:door/bakery_top_rh", "y": 90 }, - "facing=south,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:door/bakery_top_rh", "y": 180 }, - "facing=west,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:door/bakery_top_rh", "y": 270 }, - "facing=north,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:door/bakery_top_rh" }, - "facing=east,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:door/bakery_top", "y": 270 }, - "facing=south,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:door/bakery_top" }, - "facing=west,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:door/bakery_top", "y": 90 }, - "facing=north,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:door/bakery_top", "y": 180 } + "facing=east,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/stable_bottom" }, + "facing=south,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/stable_bottom", "y": 90 }, + "facing=west,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/stable_bottom", "y": 180 }, + "facing=north,half=lower,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/stable_bottom", "y": 270 }, + "facing=east,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/stable_bottom_rh" }, + "facing=south,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/stable_bottom_rh", "y": 90 }, + "facing=west,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/stable_bottom_rh", "y": 180 }, + "facing=north,half=lower,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/stable_bottom_rh", "y": 270 }, + "facing=east,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/stable_bottom_rh", "y": 90 }, + "facing=south,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/stable_bottom_rh", "y": 180 }, + "facing=west,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/stable_bottom_rh", "y": 270 }, + "facing=north,half=lower,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/stable_bottom_rh" }, + "facing=east,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/stable_bottom", "y": 270 }, + "facing=south,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/stable_bottom" }, + "facing=west,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/stable_bottom", "y": 90 }, + "facing=north,half=lower,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/stable_bottom", "y": 180 }, + "facing=east,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/stable_top" }, + "facing=south,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/stable_top", "y": 90 }, + "facing=west,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/stable_top", "y": 180 }, + "facing=north,half=upper,hinge=left,open=false,powered=false": { "model": "unicopia:block/door/stable_top", "y": 270 }, + "facing=east,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/stable_top_rh" }, + "facing=south,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/stable_top_rh", "y": 90 }, + "facing=west,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/stable_top_rh", "y": 180 }, + "facing=north,half=upper,hinge=right,open=false,powered=false": { "model": "unicopia:block/door/stable_top_rh", "y": 270 }, + "facing=east,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/stable_top_rh", "y": 90 }, + "facing=south,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/stable_top_rh", "y": 180 }, + "facing=west,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/stable_top_rh", "y": 270 }, + "facing=north,half=upper,hinge=left,open=true,powered=false": { "model": "unicopia:block/door/stable_top_rh" }, + "facing=east,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/stable_top", "y": 270 }, + "facing=south,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/stable_top" }, + "facing=west,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/stable_top", "y": 90 }, + "facing=north,half=upper,hinge=right,open=true,powered=false": { "model": "unicopia:block/door/stable_top", "y": 180 }, + "facing=east,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/stable_bottom" }, + "facing=south,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/stable_bottom", "y": 90 }, + "facing=west,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/stable_bottom", "y": 180 }, + "facing=north,half=lower,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/stable_bottom", "y": 270 }, + "facing=east,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/stable_bottom_rh" }, + "facing=south,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/stable_bottom_rh", "y": 90 }, + "facing=west,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/stable_bottom_rh", "y": 180 }, + "facing=north,half=lower,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/stable_bottom_rh", "y": 270 }, + "facing=east,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/stable_bottom_rh", "y": 90 }, + "facing=south,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/stable_bottom_rh", "y": 180 }, + "facing=west,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/stable_bottom_rh", "y": 270 }, + "facing=north,half=lower,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/stable_bottom_rh" }, + "facing=east,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/stable_bottom", "y": 270 }, + "facing=south,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/stable_bottom" }, + "facing=west,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/stable_bottom", "y": 90 }, + "facing=north,half=lower,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/stable_bottom", "y": 180 }, + "facing=east,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/stable_top" }, + "facing=south,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/stable_top", "y": 90 }, + "facing=west,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/stable_top", "y": 180 }, + "facing=north,half=upper,hinge=left,open=false,powered=true": { "model": "unicopia:block/door/stable_top", "y": 270 }, + "facing=east,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/stable_top_rh" }, + "facing=south,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/stable_top_rh", "y": 90 }, + "facing=west,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/stable_top_rh", "y": 180 }, + "facing=north,half=upper,hinge=right,open=false,powered=true": { "model": "unicopia:block/door/stable_top_rh", "y": 270 }, + "facing=east,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/stable_top_rh", "y": 90 }, + "facing=south,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/stable_top_rh", "y": 180 }, + "facing=west,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/stable_top_rh", "y": 270 }, + "facing=north,half=upper,hinge=left,open=true,powered=true": { "model": "unicopia:block/door/stable_top_rh" }, + "facing=east,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/stable_top", "y": 270 }, + "facing=south,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/stable_top" }, + "facing=west,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/stable_top", "y": 90 }, + "facing=north,half=upper,hinge=right,open=true,powered=true": { "model": "unicopia:block/door/stable_top", "y": 180 } } } diff --git a/src/main/resources/assets/unicopia/blockstates/turret_shell.json b/src/main/resources/assets/unicopia/blockstates/turret_shell.json new file mode 100644 index 00000000..e7388398 --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/turret_shell.json @@ -0,0 +1,8 @@ +{ + "variants": { + "count=1": { "model": "unicopia:block/turret_shell_1" }, + "count=2": { "model": "unicopia:block/turret_shell_2" }, + "count=3": { "model": "unicopia:block/turret_shell_3" }, + "count=4": { "model": "unicopia:block/turret_shell_4" } + } +} diff --git a/src/main/resources/assets/unicopia/lang/en_us.json b/src/main/resources/assets/unicopia/lang/en_us.json index 59154b94..41f63712 100644 --- a/src/main/resources/assets/unicopia/lang/en_us.json +++ b/src/main/resources/assets/unicopia/lang/en_us.json @@ -21,6 +21,7 @@ "itemGroup.unicopia.unicorn": "Unicopia - Canterlot", "itemGroup.unicopia.pegasus": "Unicopia - Cloudsdale", "itemGroup.unicopia.bat_pony": "Unicopia - Hollow Shades", + "itemGroup.unicopia.sea_pony": "Unicopia - From The Depths", "itemGroup.unicopia.changeling": "Unicopia - Cheese Cliffs", "item.unicopia.friendship_bracelet": "Bangle of Comradery", @@ -44,6 +45,7 @@ "item.unicopia.spellbook": "Spellbook", "emi.category.unicopia.spellbook": "Spellbook", + "emi.category.unicopia.cloud_shaping": "Shaping", "item.unicopia.alicorn_badge": "Alicorn Emblem", "item.unicopia.unicorn_badge": "Unicorn Emblem", @@ -52,9 +54,12 @@ "item.unicopia.changeling_badge": "Changeling Emblem", "item.unicopia.bat_badge": "Bat Pony Emblem", "item.unicopia.kirin_badge": "Kirin Emblem", + "item.unicopia.hippogriff_badge": "Hippogriff Emblem", "item.unicopia.butterfly_spawn_egg": "Butterfly Spawn Egg", "item.unicopia.butterfly": "Butterfly", + "item.unicopia.loot_bug_spawn_egg": "Loot Bug Spawn Egg", + "item.unicopia.loot_bug": "Loot bug", "item.unicopia.green_apple": "Granny Smith Apple", "item.unicopia.sweet_apple": "Sweet Apple Acres Apple", @@ -141,13 +146,20 @@ "item.unicopia.alicorn_amulet": "Alicorn Amulet", "item.unicopia.alicorn_amulet.lore": "Time worn: %d", + "item.unicopia.pearl_necklace": "Pearl Necklace", + "item.unicopia.pearl_necklace.lore": "Gives underwater abilities to the wearer", + "item.unicopia.clam_shell": "Clam Shell", + "item.unicopia.scallop_shell": "Scallop Shell", + "item.unicopia.turret_shell": "Turret Shell", + "item.unicopia.shelly": "Shelly", + "item.unicopia.horse_shoe.accuracy": "Accuracy: %d%%", "item.unicopia.horse_shoe.speed": "Speed: %d", "item.unicopia.iron_horse_shoe": "Iron Horse Shoe", "item.unicopia.golden_horse_shoe": "Golden Horse Shoe", "item.unicopia.copper_horse_shoe": "Copper Horse Shoe", "item.unicopia.netherite_horse_shoe": "Netherite Horse Shoe", - + "item.unicopia.broken_alicorn_amulet": "Broken Alicorn Amulet", "item.unicopia.unicorn_amulet": "Unicorn Amulet", "item.unicopia.unicorn_amulet.lore": "Grants magical abilities to whoever wears it", @@ -175,8 +187,36 @@ "item.unicopia.music_disc_crusade.desc": "Danial Ingram - crusade", "item.unicopia.music_disc_funk": "Music Disc", "item.unicopia.music_disc_funk.desc": "funk, just funk", + + "item.unicopia.cloud_lump": "Cloud Lump", + "item.unicopia.light_gray_bed_sheets": "Light Gray Bed Sheets", + "item.unicopia.gray_bed_sheets": "Gray Bed Sheets", + "item.unicopia.black_bed_sheets": "Black Bed Sheets", + "item.unicopia.brown_bed_sheets": "Brown Bed Sheets", + "item.unicopia.red_bed_sheets": "Red Bed Sheets", + "item.unicopia.orange_bed_sheets": "Orange Bed Sheets", + "item.unicopia.yellow_bed_sheets": "Yellow Bed Sheets", + "item.unicopia.lime_bed_sheets": "Lime Bed Sheets", + "item.unicopia.green_bed_sheets": "Green Bed Sheets", + "item.unicopia.cyan_bed_sheets": "Cyan Bed Sheets", + "item.unicopia.light_blue_bed_sheets": "Light Blue Bed Sheets", + "item.unicopia.blue_bed_sheets": "Blue Bed Sheets", + "item.unicopia.purple_bed_sheets": "Purple Bed Sheets", + "item.unicopia.magenta_bed_sheets": "Magenta Bed Sheets", + "item.unicopia.pink_bed_sheets": "Pink Bed Sheets", + "item.unicopia.apple_bed_sheets": "Apple Patterned Bed Sheets", + "item.unicopia.barred_bed_sheets": "Bar Patterned Bed Sheets", + "item.unicopia.checkered_bed_sheets": "Checker Patterned Bed Sheets", + "item.unicopia.kelp_bed_sheets": "Kelp Bed Sheets", + "item.unicopia.rainbow_bed_sheets": "Rainbow Patterned Bed Sheets", + "item.unicopia.rainbow_bpw_bed_sheets": "BPW Rainbow Patterned Bed Sheets", + "item.unicopia.rainbow_bpy_bed_sheets": "BPY Rainbow Patterned Bed Sheets", + "item.unicopia.rainbow_pbg_bed_sheets": "PGB Rainbow Patterned Bed Sheets", + "item.unicopia.rainbow_pwr_bed_sheets": "PWR Rainbow Patterned Bed Sheets", "block.unicopia.rocks": "Rocks", + "block.unicopia.plunder_vine": "Plunder Vine", + "block.unicopia.plunder_vine_bud": "Plunder Vine Bud", "block.unicopia.bananas": "Bananas", "block.unicopia.zapling": "Zapling", "block.unicopia.zap_log": "Zap Apple Log", @@ -211,6 +251,10 @@ "block.unicopia.mango_sapling": "Mango Sapling", "block.unicopia.pineapple": "Pineapple Plant", + "block.unicopia.clam_shell": "Clam Shell", + "block.unicopia.scallop_shell": "Scallop Shell", + "block.unicopia.turret_shell": "Turret Shell", + "block.unicopia.green_apple_leaves": "Granny Smith Leaves", "block.unicopia.green_apple_sapling": "Granny Smith Sapling", "block.unicopia.green_apple_sprout": "Granny Smith Sprout", @@ -231,7 +275,8 @@ "block.unicopia.chiselled_chitin_hull": "Chiselled Chitin Hull", "block.unicopia.chiselled_chitin_slab": "Chiselled Chitin Slab", "block.unicopia.chiselled_chitin_stairs": "Chiselled Chitin Stairs", - + + "block.unicopia.shaping_bench": "Shaping Bench", "block.unicopia.cloud": "Cloud", "block.unicopia.cloud_slab": "Cloud Slab", "block.unicopia.cloud_stairs": "Cloud Stairs", @@ -240,15 +285,28 @@ "block.unicopia.soggy_cloud_slab": "Soggy Cloud Slab", "block.unicopia.soggy_cloud_stairs": "Soggy Cloud Stairs", "block.unicopia.cloud_planks": "Cloud Planks", - "block.unicopia.cloud_planks_slab": "Cloud Plank Slab", - "block.unicopia.cloud_planks_stairs": "Cloud Plank Stairs", + "block.unicopia.cloud_plank_slab": "Cloud Plank Slab", + "block.unicopia.cloud_plank_stairs": "Cloud Plank Stairs", + "block.unicopia.cloud_bricks": "Cloud Bricks", + "block.unicopia.cloud_brick_slab": "Cloud Brick Slab", + "block.unicopia.cloud_brick_stairs": "Cloud Brick Stairs", + "block.unicopia.carved_cloud": "Carved Cloud", + "block.unicopia.compacted_cloud_bricks": "Cloud Bricks", "block.unicopia.compacted_cloud_planks": "Cloud Planks", "block.unicopia.unstable_cloud": "Unstable Cloud", "block.unicopia.dense_cloud": "Dense Cloud", "block.unicopia.dense_cloud_slab": "Dense Cloud Slab", "block.unicopia.dense_cloud_stairs": "Dense Cloud Stairs", + "block.unicopia.compacted_dense_cloud": "Dense Cloud", + "block.unicopia.etched_cloud": "Etched Cloud", + "block.unicopia.etched_cloud_slab": "Etched Cloud Slab", + "block.unicopia.etched_cloud_stairs": "Etched Cloud Stairs", + "block.unicopia.compacted_etched_cloud": "Cloud Etched Cloud", "block.unicopia.cloud_pillar": "Cloud Pillar", + "block.unicopia.cloth_bed": "Fancy Cloth Bed", "block.unicopia.cloud_bed": "Cloud Bed", + "block.unicopia.cloud_chest": "Cloudsdale Chest", + "block.unicopia.cloud_chest.double": "Large Cloudsdale Chest", "block.unicopia.oats": "Oats", "block.unicopia.oats_stem": "Oats", @@ -316,6 +374,13 @@ "item.minecraft.lingering_potion.effect.unicopia.tribe_swap_kirin": "Lingering Potion of Kirin Metamorphosis", "item.minecraft.tipped_arrow.effect.unicopia.tribe_swap_kirin": "Arrow of Kirin Metamorphosis", + "effect.unicopia.change_race_hippogriff": "Hippogriff Metamorphosis", + "item.minecraft.potion.effect.unicopia.tribe_swap_hippogriff": "Potion of Hippogriff Metamorphosis", + "item.minecraft.splash_potion.effect.unicopia.tribe_swap_hippogriff": "Splash Potion of Hippogriff Metamorphosis", + "item.minecraft.lingering_potion.effect.unicopia.tribe_swap_hippogriff": "Lingering Potion of Hippogriff Metamorphosis", + "item.minecraft.tipped_arrow.effect.unicopia.tribe_swap_hippogriff": "Arrow of Hippogriff Metamorphosis", + + "potion.withChance": "1 in %s chance of %s", "potion.potency.6": "VII", "spell.unicopia.frost": "Frost", @@ -410,11 +475,57 @@ "trait.unicopia.poison.name": "Poison", "trait.unicopia.poison.description": "A deadly dart kill a beast.", + "unicopia.diet.information": "Diet Information:", + "unicopia.diet.side_effects": "Side-Effects:", + "unicopia.diet.not_edible": "Item is not edible", + "unicopia.diet.base_multiplier": "Base Multiplier: %s%%", + "unicopia.diet.hunger.detailed": "Hunger gained: %s of %s (%s%%)", + "unicopia.diet.saturation.detailed": "Saturation gained: %s (%s%%)", + "unicopia.diet.hunger": "Hunger Ratio: %s%%", + "unicopia.diet.saturation": "Saturation Ratio: %s%%", + + "tag.unicopia.food_types.rotten_meat": "Rotting Meat", + "tag.unicopia.food_types.raw_meat": "Fresh Meat", + "tag.unicopia.food_types.cooked_meat": "Prepared Meat", + "tag.unicopia.food_types.raw_fish": "Fresh Fish", + "tag.unicopia.food_types.cooked_fish": "Prepared Fish", + "tag.unicopia.food_types.raw_insect": "Bugs & Insects", + "tag.unicopia.food_types.cooked_insect": "Cooked Bugs & Insects", + "tag.unicopia.food_types.love": "Love", + "tag.unicopia.food_types.rocks": "Rocks", + "tag.unicopia.food_types.pinecone": "Nuts & Seeds", + "tag.unicopia.food_types.bat_ponys_delight": "Bat Pony Treats", + "tag.unicopia.food_types.cooked_sea_vegitables": "Prepared Fish Food", + "tag.unicopia.food_types.raw_sea_vegitables": "Fresh Fish Food", + "tag.unicopia.food_types.shells": "Sea Shells", + "tag.unicopia.food_types.shelly": "Sea Shells", + "tag.unicopia.food_types.candy": "Candy", + "tag.unicopia.food_types.desserts": "Desserts", + "tag.unicopia.food_types.fruits_and_vegetables": "Fruits & Vegetables", + "tag.unicopia.food_types.drinks": "Drinks", + + "tag.unicopia.food_types.forage_edible_filling": "Bulky Plant Matter", + "tag.unicopia.food_types.forage_edible": "Plant Matter", + "tag.unicopia.food_types.forage_nauseating": "Nauseating", + "tag.unicopia.food_types.forage_prickly": "Prickly", + "tag.unicopia.food_types.forage_risky": "Unsafe", + "tag.unicopia.food_types.forage_strengthening": "Strength Enhancing", + "tag.unicopia.food_types.forage_severely_prickly": "Very Prickly", + "tag.unicopia.food_types.forage_severely_nauseating": "Sickening", + "tag.unicopia.food_types.forage_radioactive": "Glowy", + "tag.unicopia.food_types.forage_dangerous": "Dangerous", + "tag.unicopia.food_types.forage_blinding": "Toxic", + "toxicity.safe.name": "Safe", "toxicity.mild.name": "Mildly Toxic", "toxicity.fair.name": "Fairly Toxic", "toxicity.severe.name": "Toxic", "toxicity.lethal.name": "Lethal", + + "affliction.unicopia.empty": "No Effect", + "affliction.unicopia.healing": "Gain %s%% health", + "affliction.unicopia.cure_love_sickness": "Cure Love Sickness", + "affliction.unicopia.lose_hunger": "Lose %s%% hunger", "ability.unicopia.shoot": "Shoot Magic", "ability.unicopia.shoot.with_spell": "Shoot %s", @@ -452,6 +563,13 @@ "ability.unicopia.rainboom": "Sonic Rainboom", "ability.unicopia.rage": "Rage", "ability.unicopia.nirik_blast": "Nirik Blast", + "ability.unicopia.screech": "Screech", + "ability.unicopia.peck": "Peck/Squawk", + "ability.unicopia.peck.block.fled": "The block has fled", + "ability.unicopia.peck.block.unfased": "The block is unfazed by your threats", + "ability.unicopia.dash": "Flying Dash", + "ability.unicopia.change_form": "Change Form", + "ability.unicopia.sonar_pulse": "Sonar Pulse", "gui.unicopia.trait.label": "Element of %s", "gui.unicopia.trait.group": "\n %s", @@ -483,6 +601,7 @@ "gui.unicopia.tribe_selection.describe.unicopia.pegasus": "Join the Pegasus Tribe, soar with the Wonderbolts", "gui.unicopia.tribe_selection.describe.unicopia.bat": "Join the Bat Tribe, become the darkest night", "gui.unicopia.tribe_selection.describe.unicopia.kirin": "Join the Kirin's Village, take the vow of silence", + "gui.unicopia.tribe_selection.describe.unicopia.hippogriff": "Join Hippogriff Tribe, screech at your neighbors", "gui.unicopia.tribe_selection.describe.unicopia.changeling": "Join the Changeling Hive, your Queen demands it", "gui.unicopia.tribe_selection.confirm": "You have selected %s", @@ -491,12 +610,14 @@ "gui.unicopia.tribe_selection.confirm.goods.1.unicopia.human": " - Are omnivores and can eat all types of food except for love", "gui.unicopia.tribe_selection.confirm.goods.2.unicopia.human": " - Opposable thumbs", "gui.unicopia.tribe_selection.confirm.goods.3.unicopia.human": " - Walking upright", - "gui.unicopia.tribe_selection.confirm.goods.4.unicopia.human": "", "gui.unicopia.tribe_selection.confirm.goods.1.unicopia.earth": " - Stronger knockback and resistance to magic", "gui.unicopia.tribe_selection.confirm.goods.2.unicopia.earth": " - Have extra weight makes them effective against magic and brute force", "gui.unicopia.tribe_selection.confirm.goods.3.unicopia.earth": " - A special connection to the earth that makes farming 10,000% more effective!", - "gui.unicopia.tribe_selection.confirm.goods.4.unicopia.earth": " - Cute floppy pony ears", + "gui.unicopia.tribe_selection.confirm.goods.4.unicopia.earth": " - Has powerful punches, kicks, and stomps that they can use to defend or attack their environment", + "gui.unicopia.tribe_selection.confirm.goods.5.unicopia.earth": " - Is the only one that can hug creepers and survive", + "gui.unicopia.tribe_selection.confirm.goods.6.unicopia.earth": " - Can eat rocks", + "gui.unicopia.tribe_selection.confirm.goods.7.unicopia.earth": " - Cute floppy pony ears", "gui.unicopia.tribe_selection.confirm.goods.1.unicopia.unicorn": " - Teleportation and magic spells", "gui.unicopia.tribe_selection.confirm.goods.2.unicopia.unicorn": " - Research and craft magical artefacts that enhance their abilities", @@ -506,7 +627,8 @@ "gui.unicopia.tribe_selection.confirm.goods.1.unicopia.pegasus": " - Flight and the ability to train to build endurace", "gui.unicopia.tribe_selection.confirm.goods.2.unicopia.pegasus": " - Use stored mana to dash in short bursts or build it up to perform a powerful rainboom", "gui.unicopia.tribe_selection.confirm.goods.3.unicopia.pegasus": " - Moves faster and takes less fall damage", - "gui.unicopia.tribe_selection.confirm.goods.4.unicopia.pegasus": " - Can eat vegetables and certain types of fish", + "gui.unicopia.tribe_selection.confirm.goods.4.unicopia.pegasus": " - Can interact directly with cloud items and blocks", + "gui.unicopia.tribe_selection.confirm.goods.5.unicopia.pegasus": " - Can eat vegetables and certain types of fish", "gui.unicopia.tribe_selection.confirm.goods.1.unicopia.bat": " - Flight and the ability to train to build endurance", "gui.unicopia.tribe_selection.confirm.goods.2.unicopia.bat": " - Sees better in the night", @@ -515,24 +637,32 @@ "gui.unicopia.tribe_selection.confirm.goods.1.unicopia.changeling": " - Able to fly and hover in place", "gui.unicopia.tribe_selection.confirm.goods.2.unicopia.changeling": " - Shapeshift and morph into nearly anyone or anyling", - "gui.unicopia.tribe_selection.confirm.goods.3.unicopia.changeling": " - Is carnivorous. Can eat anything that doesn't make them sick", - "gui.unicopia.tribe_selection.confirm.goods.4.unicopia.changeling": "", + "gui.unicopia.tribe_selection.confirm.goods.3.unicopia.changeling": " - Sticks to walls and can climb over almost enything", + "gui.unicopia.tribe_selection.confirm.goods.4.unicopia.changeling": " - Is carnivorous. Can eat anything that doesn't make them sick", "gui.unicopia.tribe_selection.confirm.goods.1.unicopia.kirin": " - Immune to all types of fire damage", "gui.unicopia.tribe_selection.confirm.goods.2.unicopia.kirin": " - Can unlock a rage ability by taking damage", "gui.unicopia.tribe_selection.confirm.goods.3.unicopia.kirin": " - Is silent in their default state, and can move freely around the warden", "gui.unicopia.tribe_selection.confirm.goods.4.unicopia.kirin": " - Can eat fruits and vegetables, red meats, and some foraged items normally toxic to other races", + "gui.unicopia.tribe_selection.confirm.goods.1.unicopia.hippogriff": " - Flight and the ability to train to build endurance", + "gui.unicopia.tribe_selection.confirm.goods.2.unicopia.hippogriff": " - Can dash whilst flying", + "gui.unicopia.tribe_selection.confirm.goods.3.unicopia.hippogriff": " - Has a sharp and noisy beak for screeching and pecking", + "gui.unicopia.tribe_selection.confirm.goods.4.unicopia.hippogriff": " - Can eat raw and cooked fish, cooked meat", + "gui.unicopia.tribe_selection.confirm.goods.5.unicopia.hippogriff": " - Heals extra hearts when eating pinecones", + "gui.unicopia.tribe_selection.confirm.goods.6.unicopia.hippogriff": " - Loves stairs", + "gui.unicopia.tribe_selection.confirm.bads": "but they...", "gui.unicopia.tribe_selection.confirm.bads.1.unicopia.human": " - Have no magical abilities what-so-ever", - "gui.unicopia.tribe_selection.confirm.bads.2.unicopia.human": " - Need an Elytra to fly", + "gui.unicopia.tribe_selection.confirm.bads.2.unicopia.human": " - Needs an Elytra to fly", "gui.unicopia.tribe_selection.confirm.bads.3.unicopia.human": " - Must grow food the old fashioned way, through hard work and manual labour", "gui.unicopia.tribe_selection.confirm.bads.4.unicopia.human": " - No floppy ears", "gui.unicopia.tribe_selection.confirm.bads.1.unicopia.earth": " - Cannot fly", "gui.unicopia.tribe_selection.confirm.bads.2.unicopia.earth": " - Are weak to certain types of magic", "gui.unicopia.tribe_selection.confirm.bads.3.unicopia.earth": " - Can only eat plants and vegetables", + "gui.unicopia.tribe_selection.confirm.bads.4.unicopia.earth": " - Heavier and moves slower than the other ponies", "gui.unicopia.tribe_selection.confirm.bads.1.unicopia.unicorn": " - Cannot fly", "gui.unicopia.tribe_selection.confirm.bads.2.unicopia.unicorn": " - Are weak to brute force attacks", @@ -541,23 +671,26 @@ "gui.unicopia.tribe_selection.confirm.bads.1.unicopia.pegasus": " - Light weight makes them the weakest to brute force", "gui.unicopia.tribe_selection.confirm.bads.2.unicopia.pegasus": " - Must rest between flights to regain their strength", "gui.unicopia.tribe_selection.confirm.bads.3.unicopia.pegasus": " - Cannot use magic without aid from others", - "gui.unicopia.tribe_selection.confirm.bads.4.unicopia.pegasus": "", "gui.unicopia.tribe_selection.confirm.bads.1.unicopia.bat": " - Light weight makes them weak to brute force attacks", "gui.unicopia.tribe_selection.confirm.bads.2.unicopia.bat": " - Must rest between flights to regain their strength", "gui.unicopia.tribe_selection.confirm.bads.3.unicopia.bat": " - Is sometimes scared of even themselves", - "gui.unicopia.tribe_selection.confirm.bads.4.unicopia.bat": " - Is carnivorous. Can eat anything that doesn't make them sick", + "gui.unicopia.tribe_selection.confirm.bads.4.unicopia.bat": " - Is carnivorous. Can eat raw and cooked meat, or sustain themselved purely on stolen love.", "gui.unicopia.tribe_selection.confirm.bads.1.unicopia.changeling": " - Are always starving", "gui.unicopia.tribe_selection.confirm.bads.2.unicopia.changeling": " - Requires love, collected from ponies or other hostile mobs to subsidise their diet", - "gui.unicopia.tribe_selection.confirm.bads.3.unicopia.changeling": " - Becomes sick from eating regular food and must eat love to hasten a cure", - "gui.unicopia.tribe_selection.confirm.bads.4.unicopia.changeling": "", + "gui.unicopia.tribe_selection.confirm.bads.3.unicopia.changeling": " - Becomes sick from eating most regular food and must harvest love to hasten a cure", "gui.unicopia.tribe_selection.confirm.bads.1.unicopia.kirin": " - Are no longer quiet whilst raging", "gui.unicopia.tribe_selection.confirm.bads.2.unicopia.kirin": " - Has a tendency to burn things, especially when close to raging", "gui.unicopia.tribe_selection.confirm.bads.3.unicopia.kirin": " - Lighter than other ponies, and might take increased knockback", "gui.unicopia.tribe_selection.confirm.bads.4.unicopia.kirin": " - Doesn't like water", + "gui.unicopia.tribe_selection.confirm.bads.1.unicopia.hippogriff": " - Weak to brute force attacks", + "gui.unicopia.tribe_selection.confirm.bads.2.unicopia.hippogriff": " - Cannot interact with clouds", + "gui.unicopia.tribe_selection.confirm.bads.3.unicopia.hippogriff": " - Must rest between flights to regain their strength", + "gui.unicopia.tribe_selection.confirm.bads.4.unicopia.hippogriff": " - Has a bird brain", + "gui.unicopia.tribe_selection.join": "Join Tribe", "gui.unicopia.tribe_selection.cancel": "Go Back", @@ -783,6 +916,10 @@ "unicopia.race.bat.alt": "Bat Ponies", "unicopia.race.kirin": "Kirin", "unicopia.race.kirin.alt": "Kirins", + "unicopia.race.hippogriff": "Hippogriff", + "unicopia.race.hippogriff.alt": "Hippogriffs", + "unicopia.race.seapony": "Sea Pony", + "unicopia.race.seapony.alt": "Sea Ponies", "death.attack.unicopia.generic.and_also": "%1$s and %2$s", "death.attack.unicopia.generic.whilst_flying": "%1$s whilst flying", @@ -895,8 +1032,10 @@ "unicopia.subtitle.wind_rush": "Wind gusts", "unicopia.subtitle.insects": "Insects Scurrying", "unicopia.subtitle.changeling_buzz": "Drone buzzing", - "unicopia.subtitle.batpony_eeee": "Batpony screeches", + "unicopia.subtitle.batpony_eeee": "Batpony Screeches", + "unicopia.subtitle.sonar": "Sonar Pulses", "unicopia.subtitle.changeling.transform": "Changeling transforms", + "unicopia.subtitle.screech": "Hippogriff Screeches", "unicopia.subtitle.pegasus.molt": "Pegasus loses feather", "unicopia.subtitle.unicorn.teleport": "Magic pops", "unicopia.subtitle.player.wololo": "Wololo!", @@ -904,6 +1043,7 @@ "unicopia.subtitle.entity.player.kick": "Player kicks", "unicopia.subtitle.magic_aura": "Magic humming", "unicopia.subtitle.player.rebound": "Player Bounces Off Wall", + "unicopia.subtitle.screech": "Player Screeches", "unicopia.subtitle.ears_ringing": "Ears ringing", "unicopia.subtitle.heartbeat": "Heart beats", "unicopia.subtitle.entity.artefact.ambient": "Magic hums", @@ -980,10 +1120,10 @@ "advancements.unicopia.apple_route.description": "Start your journey towards the apple of legend", "advancements.unicopia.juice.title": "Refreshing", "advancements.unicopia.juice.description": "Finally a use for all these apples", - "advancements.unicopia.toast.title": "He Crispy and delicious!", + "advancements.unicopia.toast.title": "He's Crispy and delicious!", "advancements.unicopia.toast.description": "Make a toasted companion", - "advancements.unicopia.burned_toast.title": "Toasty NOOOOOOO!", - "advancements.unicopia.burned_toast.description": "Burn Toasty", + "advancements.unicopia.burn_toast.title": "Toasty NOOOOOOO!", + "advancements.unicopia.burn_toast.description": "Burn Toasty", "advancements.unicopia.lucky.title": "As seen on TV", "advancements.unicopia.lucky.description": "Make some lucky horse shoe fries", "advancements.unicopia.sweet_apple_acres.title": "Sweet Apple Acres", @@ -1040,6 +1180,8 @@ "advancements.unicopia.tempted.description": "Put on the alicorn amulet", "advancements.unicopia.hello_darkness_my_old_friend.title": "Hello Darkness...", "advancements.unicopia.hello_darkness_my_old_friend.description": "Delve further into the powers of the dark side", + "advancements.unicopia.a_falling_wizard.title": "A Falling Wizard", + "advancements.unicopia.a_falling_wizard.description": "A unicorn tried to perform an unsuccessful flying spell", "advancements.unicopia.split_the_sea.title": "Who are you? Moses?", "advancements.unicopia.split_the_sea.description": "Use magic to displace over 100 blocks of water in one go", diff --git a/src/main/resources/assets/unicopia/lang/ru_ru.json b/src/main/resources/assets/unicopia/lang/ru_ru.json index ac299b9d..d7ce9dc2 100644 --- a/src/main/resources/assets/unicopia/lang/ru_ru.json +++ b/src/main/resources/assets/unicopia/lang/ru_ru.json @@ -10,6 +10,10 @@ "ability.unicopia.indoors": "Я не вижу отсюда неба", "ability.unicopia.too_low": "Мне нужно подняться повыше", "ability.unicopia.clear_skies": "Небо и так выглядит довольно чистым", + "ability.unicopia.too_calm.1": "Мне нужно разозлиться...", + "ability.unicopia.too_calm.2": "Я не чувствую злости...", + "ability.unicopia.too_calm.3": "У Брюса это выглядело проще...", + "ability.unicopia.too_calm.4": "Селестия, дай мне силы...", "itemGroup.unicopia.items": "Unicopia", "itemGroup.unicopia.foraging": "Unicopia - Корм", @@ -17,6 +21,7 @@ "itemGroup.unicopia.unicorn": "Unicopia - Кантерлот", "itemGroup.unicopia.pegasus": "Unicopia - Клаудсдейл", "itemGroup.unicopia.bat_pony": "Unicopia - Лощина Теней", + "itemGroup.unicopia.sea_pony": "Unicopia - Из глубин", "itemGroup.unicopia.changeling": "Unicopia - Сырные Холмы", "item.unicopia.friendship_bracelet": "Браслет товарищества", @@ -40,6 +45,7 @@ "item.unicopia.spellbook": "Книга заклинаний", "emi.category.unicopia.spellbook": "Книга заклинаний", + "emi.category.unicopia.cloud_shaping": "Формоизменение", "item.unicopia.alicorn_badge": "Эмблема аликорна", "item.unicopia.unicorn_badge": "Эмблема единорога", @@ -47,9 +53,13 @@ "item.unicopia.earth_badge": "Эмблема земного пони", "item.unicopia.changeling_badge": "Эмблема чейнджлинга", "item.unicopia.bat_badge": "Эмблема бэтпони", + "item.unicopia.kirin_badge": "Эмблема кирина", + "item.unicopia.hippogriff_badge": "Эмблема гиппогрифа", "item.unicopia.butterfly_spawn_egg": "Яйцо призыва бабочки", "item.unicopia.butterfly": "Бабочка", + "item.unicopia.loot_bug_spawn_egg": "Яйцо призыва жука-сборщика", + "item.unicopia.loot_bug": "Жук-сборщик", "item.unicopia.green_apple": "Яблоко Гренни Смит", "item.unicopia.sweet_apple": "Яблоко Яблочной Аллеи", @@ -70,6 +80,10 @@ "item.unicopia.lightning_jar": "Молния в банке", "item.unicopia.zap_apple_jam_jar": "Джем из зап-яблока", + "item.unicopia.toast": "Тост", + "item.unicopia.burned_toast": "Подгоревший тост", + "item.unicopia.jam_toast": "Тост с зап-яблочным джемом", + "item.unicopia.crystal_heart": "Кристальное сердце", "item.unicopia.crystal_shard": "Осколок кристалла", "item.unicopia.dragon_breath_scroll": "Свиток дыхания дракона", @@ -95,11 +109,15 @@ "item.unicopia.sunglasses": "Солнцезащитные очки", "item.unicopia.broken_sunglasses": "Сломанные солнцезащитные очки", + "item.unicopia.carapace": "Панцырь", + "item.unicopia.pebbles": "Галька", "item.unicopia.rock": "Камень", "item.unicopia.weird_rock": "Странный камень", "item.unicopia.tom": "Том", - "item.unicopia.rock_stew": "Рагу из камня", + "item.unicopia.rock_stew": "Каменное рагу", + "item.unicopia.rock_candy": "Каменная конфета", + "item.unicopia.salt_cube": "Кубик соли", "item.unicopia.pinecone": "Шишка", "item.unicopia.acorn": "Жёлудь", "item.unicopia.green_apple_seeds": "Семена яблони Гренни Смит", @@ -107,6 +125,7 @@ "item.unicopia.sour_apple_seeds": "Семена кислой яблони", "item.unicopia.apple_pie_hoof": "Яблочный пирог с отпечатком копыта", "item.unicopia.apple_pie_slice": "Кусочек яблочного пирога", + "item.unicopia.candied_apple": "Засахаренное яблоко", "item.unicopia.oats": "Овёс", "item.unicopia.imported_oats": "Шикарный импортный овёс", @@ -116,19 +135,34 @@ "item.unicopia.hay_burger": "Сенобургер", "item.unicopia.hay_fries": "Картофель фри", "item.unicopia.crispy_hay_fries": "Хрустящий картофель фри", + "item.unicopia.horse_shoe_fries": "Подкова из картофеля фри", "item.unicopia.wheat_worms": "Пшеничные черви", "item.unicopia.muffin": "Маффин", "item.unicopia.pegasus_amulet": "Крылья Икара", "item.unicopia.pegasus_amulet.lore": "Дарует временный полёт тому, кто носит его", "item.unicopia.amulet.energy": "Энергия: %d / %d", - + "item.unicopia.alicorn_amulet": "Амулет аликорна", "item.unicopia.alicorn_amulet.lore": "Время ношения: %d", + "item.unicopia.pearl_necklace": "Жемчужное ожерелье", + "item.unicopia.pearl_necklace.lore": "Наделяет владельца подводными способностями", + "item.unicopia.clam_shell": "Раковина моллюска", + "item.unicopia.scallop_shell": "Раковина гребешка", + "item.unicopia.turret_shell": "Раковина туррителлы", + "item.unicopia.shelly": "Шелли", + + "item.unicopia.horse_shoe.accuracy": "Точность: %d%%", + "item.unicopia.horse_shoe.speed": "Скорость: %d", + "item.unicopia.iron_horse_shoe": "Железная подкова", + "item.unicopia.golden_horse_shoe": "Золотая подкова", + "item.unicopia.copper_horse_shoe": "Медная подкова", + "item.unicopia.netherite_horse_shoe": "Незеритовая подкова", + "item.unicopia.broken_alicorn_amulet": "Сломанный амулет аликорна", "item.unicopia.unicorn_amulet": "Амулет единорога", - "item.unicopia.unicorn_amulet.lore": "Наделяет носящего магическими способностями", + "item.unicopia.unicorn_amulet.lore": "Наделяет носящего магическими способностями", "item.unicopia.grogars_bell": "Колокольчик Грогара", "item.unicopia.grogars_bell.charges": "Заряды: %d / %d", @@ -154,7 +188,35 @@ "item.unicopia.music_disc_funk": "Пластинка", "item.unicopia.music_disc_funk.desc": "Фанк, просто фанк", + "item.unicopia.cloud_lump": "Облачный ком", + "item.unicopia.light_gray_bed_sheets": "Светло-серая простынь", + "item.unicopia.gray_bed_sheets": "Серая простынь", + "item.unicopia.black_bed_sheets": "Черная простынь", + "item.unicopia.brown_bed_sheets": "Коричневая простынь", + "item.unicopia.red_bed_sheets": "Красная простынь", + "item.unicopia.orange_bed_sheets": "Оранжевая простынь", + "item.unicopia.yellow_bed_sheets": "Желтая простынь", + "item.unicopia.lime_bed_sheets": "Лаймовая простынь", + "item.unicopia.green_bed_sheets": "Зелёная простынь", + "item.unicopia.cyan_bed_sheets": "Голубая простынь", + "item.unicopia.light_blue_bed_sheets": "Светло-голубая простынь", + "item.unicopia.blue_bed_sheets": "Синяя простынь", + "item.unicopia.purple_bed_sheets": "Фиолетовая простынь", + "item.unicopia.magenta_bed_sheets": "Пурпурная простынь", + "item.unicopia.pink_bed_sheets": "Розовая простынь", + "item.unicopia.apple_bed_sheets": "Яблочная простынь", + "item.unicopia.barred_bed_sheets": "Простынь в полоску", + "item.unicopia.checkered_bed_sheets": "Простынь в клетку", + "item.unicopia.kelp_bed_sheets": "Простынь из ламинарии", + "item.unicopia.rainbow_bed_sheets": "Радужная простынь", + "item.unicopia.rainbow_bpw_bed_sheets": "Простынь с радужным СРБ узором", + "item.unicopia.rainbow_bpy_bed_sheets": "Простынь с радужным СРЖ узором", + "item.unicopia.rainbow_pbg_bed_sheets": "Простынь с радужным ФСЧ узором", + "item.unicopia.rainbow_pwr_bed_sheets": "Простынь с радужным РБК узором", + "block.unicopia.rocks": "Камни", + "block.unicopia.plunder_vine": "Чёрная лоза", + "block.unicopia.plunder_vine_bud": "Бутон чёрной лозы", "block.unicopia.bananas": "Бананы", "block.unicopia.zapling": "Саженец зап-яблони", "block.unicopia.zap_log": "Бревно зап-яблони", @@ -188,7 +250,11 @@ "block.unicopia.mango_leaves": "Листья мангового дерева", "block.unicopia.mango_sapling": "Саженец мангового дерева", "block.unicopia.pineapple": "Ананас", - + + "block.unicopia.clam_shell": "Раковина моллюска", + "block.unicopia.scallop_shell": "Раковина гребешка", + "block.unicopia.turret_shell": "Раковина туррителлы", + "block.unicopia.green_apple_leaves": "Листья яблони Гренни Смит", "block.unicopia.green_apple_sapling": "Саженец яблони Гренни Смит", "block.unicopia.green_apple_sprout": "Росток яблони Гренни Смит", @@ -199,6 +265,43 @@ "block.unicopia.sour_apple_sapling": "Саженец кислой яблони", "block.unicopia.sour_apple_sprout": "Росток кислой яблони", + "block.unicopia.surface_chitin": "Поверхностный хитин", + "block.unicopia.mysterious_egg": "Загадочное яйцо", + "block.unicopia.hive": "Улей", + "block.unicopia.slime_pustule": "Пустула со слизью", + "block.unicopia.chitin": "Хитиновый блок", + "block.unicopia.chitin_spikes": "Хитиновые шипы", + "block.unicopia.chiselled_chitin": "Резной хитиновый блок", + "block.unicopia.chiselled_chitin_hull": "Резной хитиновый остов", + "block.unicopia.chiselled_chitin_slab": "Резная хитиновая плита", + "block.unicopia.chiselled_chitin_stairs": "Резные хитиновые ступеньки", + + "block.unicopia.shaping_bench": "Стенд формоизменения", + "block.unicopia.cloud": "Облако", + "block.unicopia.cloud_slab": "Плита из облака", + "block.unicopia.cloud_stairs": "Ступеньки из облака", + "block.unicopia.compacted_cloud": "Облако", + "block.unicopia.soggy_cloud": "Мокрое облако", + "block.unicopia.soggy_cloud_slab": "Плита из мокрого облака", + "block.unicopia.soggy_cloud_stairs": "Ступеньки из мокрого блока", + "block.unicopia.cloud_planks": "Облачные доски", + "block.unicopia.cloud_plank_slab": "Плита из облачных досок", + "block.unicopia.cloud_plank_stairs": "Ступеньки из облачных досок", + "block.unicopia.cloud_bricks": "Кирпичный блок из облака", + "block.unicopia.cloud_brick_slab": "Плита из облачных кирпичей", + "block.unicopia.cloud_brick_stairs": "Ступеньки из облачных кирпичей", + "block.unicopia.carved_cloud": "Резное облако", + "block.unicopia.compacted_cloud_bricks": "Кирпичный блок из облака", + "block.unicopia.compacted_cloud_planks": "Облачные доски", + "block.unicopia.unstable_cloud": "Нестабильное облако", + "block.unicopia.dense_cloud": "Плотное облако", + "block.unicopia.dense_cloud_slab": "Плита из плотного облака", + "block.unicopia.dense_cloud_stairs": "Ступеньки из плотного облака", + "block.unicopia.compacted_dense_cloud": "Плотное облако", + "block.unicopia.cloud_pillar": "Колонна из облака", + "block.unicopia.cloth_bed": "Кровать из шикарной ткани", + "block.unicopia.cloud_bed": "Кровать из облака", + "block.unicopia.oats": "Овёс", "block.unicopia.oats_stem": "Овёс", "block.unicopia.oats_crown": "Овёс", @@ -259,6 +362,18 @@ "item.minecraft.lingering_potion.effect.unicopia.tribe_swap_bat": "Туманное зелье метаморфоз бэтпони", "item.minecraft.tipped_arrow.effect.unicopia.tribe_swap_bat": "Стрела метаморфоз бэтпони", + "effect.unicopia.change_race_kirin": "Метаморфозы кирина", + "item.minecraft.potion.effect.unicopia.tribe_swap_kirin": "Зелье метаморфоз кирина", + "item.minecraft.splash_potion.effect.unicopia.tribe_swap_kirin": "Взрывное зелье метаморфоз кирина", + "item.minecraft.lingering_potion.effect.unicopia.tribe_swap_kirin": "Туманное зелье метаморфоз кирина", + "item.minecraft.tipped_arrow.effect.unicopia.tribe_swap_kirin": "Стрела метаморфоз кирина", + + "effect.unicopia.change_race_hippogriff": "Метаморфозы гиппогрифа", + "item.minecraft.potion.effect.unicopia.tribe_swap_hippogriff": "Зелье метаморфоз гиппогрифа", + "item.minecraft.splash_potion.effect.unicopia.tribe_swap_hippogriff": "Взрывное зелье метаморфоз гиппогрифа", + "item.minecraft.lingering_potion.effect.unicopia.tribe_swap_hippogriff": "Туманное зелье метаморфоз гиппогрифа", + "item.minecraft.tipped_arrow.effect.unicopia.tribe_swap_hippogriff": "Стрела метаморфоз гиппогрифа", + "potion.potency.6": "VII", "spell.unicopia.frost": "Заморозка", @@ -369,6 +484,11 @@ "ability.unicopia.cast.with_spell.active": "Наложение \"%s\"", "ability.unicopia.cast.with_spell.hand": "Наложение \"%s\" с руки", "ability.unicopia.cast.with_spell.replacing": "Заменить \"%s\" на \"%s\"", + "ability.unicopia.kirin_cast": "Наложить заклинание", + "ability.unicopia.kirin_cast.with_spell": "Наложить \"%s\"", + "ability.unicopia.kirin_cast.with_spell.active": "Наложение \"%s\"", + "ability.unicopia.kirin_cast.with_spell.hand": "Наложение \"%s\" с руки", + "ability.unicopia.kirin_cast.with_spell.replacing": "Заменить \"%s\" на \"%s\"", "ability.unicopia.dispell": "Рассеять магию", "ability.unicopia.teleport": "Телепорт", "ability.unicopia.teleport.far": "Телепорт (далеко)", @@ -377,6 +497,7 @@ "ability.unicopia.grow": "Удобрить землю", "ability.unicopia.stomp": "Удар по земле", "ability.unicopia.kick": "Сокрушительный удар", + "ability.unicopia.hug": "Обнять", "ability.unicopia.pummel": "Сокрушительный удар", "ability.unicopia.carry": "Поднять/Высадить пассажира", "ability.unicopia.toggle_flight": "Взлететь/Приземлиться", @@ -387,6 +508,15 @@ "ability.unicopia.capture_cloud": "Захватить облако", "ability.unicopia.disguise": "Изменить форму", "ability.unicopia.rainboom": "Звуковая радуга", + "ability.unicopia.rage": "Ярость", + "ability.unicopia.nirik_blast": "Заряд нирика", + "ability.unicopia.screech": "Кричать", + "ability.unicopia.peck": "Клевать", + "ability.unicopia.peck.block.fled": "Блок сбежал", + "ability.unicopia.peck.block.unfased": "Блок не обращает внимания на ваши угрозы", + "ability.unicopia.dash": "Рывок", + "ability.unicopia.change_form": "Изменить форму", + "ability.unicopia.sonar_pulse": "Сонарный импульс", "gui.unicopia.trait.label": "Элемент %s", "gui.unicopia.trait.group": "\n %s", @@ -417,7 +547,9 @@ "gui.unicopia.tribe_selection.describe.unicopia.unicorn": "Присоединитесь к племени единорогов, овладейте магическими искусствами", "gui.unicopia.tribe_selection.describe.unicopia.pegasus": "Присоединяйтесь к племени пегасов, парите вместе с Вондерболтами", "gui.unicopia.tribe_selection.describe.unicopia.bat": "Присоединяйтесь к племени бэтпони, станьте самой темной ночью", - "gui.unicopia.tribe_selection.describe.unicopia.changeling": "Присоединяйтесь к улью чейнджлингов, ваша королева требует этого", + "gui.unicopia.tribe_selection.describe.unicopia.kirin": "Присоединяйтесь к Деревне Киринов, дайте обет молчания", + "gui.unicopia.tribe_selection.describe.unicopia.hippogriff": "Присоединяйтесь к племени гиппогрифов, кричите на своих соседей", + "gui.unicopia.tribe_selection.describe.unicopia.changeling": "Присоединяйтесь к Улью Чейнджлингов, ваша королева требует этого", "gui.unicopia.tribe_selection.confirm": "Вы выбрали племя \"%s\"", "gui.unicopia.tribe_selection.confirm.goods": "%s имеют следующие преимущества:", @@ -425,31 +557,47 @@ "gui.unicopia.tribe_selection.confirm.goods.1.unicopia.human": " - Всеядны и могут есть все виды пищи, кроме любви", "gui.unicopia.tribe_selection.confirm.goods.2.unicopia.human": " - Противоположные большие пальцы", "gui.unicopia.tribe_selection.confirm.goods.3.unicopia.human": " - Ходят прямо", - "gui.unicopia.tribe_selection.confirm.goods.4.unicopia.human": "", "gui.unicopia.tribe_selection.confirm.goods.1.unicopia.earth": " - Более сильная отдача и сопротивление магии", "gui.unicopia.tribe_selection.confirm.goods.2.unicopia.earth": " - Дополнительный вес делает их эффективными против магии и грубой силы", - "gui.unicopia.tribe_selection.confirm.goods.3.unicopia.earth": " - Особая связь с землей, которая делает земледелие на 10,000% эффективнее!", - "gui.unicopia.tribe_selection.confirm.goods.4.unicopia.earth": " - Милые висячие пони-ушки", + "gui.unicopia.tribe_selection.confirm.goods.3.unicopia.earth": " - Особая связь с землёй, которая делает земледелие на 10,000% эффективнее!", + "gui.unicopia.tribe_selection.confirm.goods.4.unicopia.earth": " - Обладают мощными ударами, пинками и топтанием, которые они могут использовать для защиты или нападения на окружающую среду", + "gui.unicopia.tribe_selection.confirm.goods.5.unicopia.earth": " - Единственные, кто может обняться с крипером и выжить", + "gui.unicopia.tribe_selection.confirm.goods.6.unicopia.earth": " - Могут есть камни", + "gui.unicopia.tribe_selection.confirm.goods.7.unicopia.earth": " - Милые висячие пони-ушки", "gui.unicopia.tribe_selection.confirm.goods.1.unicopia.unicorn": " - Телепортация и магические заклинания", "gui.unicopia.tribe_selection.confirm.goods.2.unicopia.unicorn": " - Исследуют и создают магические артефакты, усиливающие их способности", "gui.unicopia.tribe_selection.confirm.goods.3.unicopia.unicorn": " - Могут использовать магию для обнаружения или раскрытия находящихся поблизости чейнджлингов", "gui.unicopia.tribe_selection.confirm.goods.4.unicopia.unicorn": " - Имеют заостренные палки на голове", - "gui.unicopia.tribe_selection.confirm.goods.1.unicopia.pegasus": " - Могут летать", + "gui.unicopia.tribe_selection.confirm.goods.1.unicopia.pegasus": " - Полёт и способность к тренировкам для повышения выносливости", "gui.unicopia.tribe_selection.confirm.goods.2.unicopia.pegasus": " - Используют накопленную ману для выполнения мощной звуковой радуги", "gui.unicopia.tribe_selection.confirm.goods.3.unicopia.pegasus": " - Двигаются быстрее и получают меньше урона от падения", - "gui.unicopia.tribe_selection.confirm.goods.4.unicopia.pegasus": " - Могут есть овощи и некоторые виды рыбы", + "gui.unicopia.tribe_selection.confirm.goods.4.unicopia.pegasus": " - Можно напрямую взаимодействовать с облачными предметами и блоками", + "gui.unicopia.tribe_selection.confirm.goods.5.unicopia.pegasus": " - Могут есть овощи и некоторые виды рыбы", - "gui.unicopia.tribe_selection.confirm.goods.1.unicopia.bat": " - Могут летать", + "gui.unicopia.tribe_selection.confirm.goods.1.unicopia.bat": " - Полёт и способность к тренировкам для повышения выносливости", "gui.unicopia.tribe_selection.confirm.goods.2.unicopia.bat": " - Лучше видят ночью", "gui.unicopia.tribe_selection.confirm.goods.3.unicopia.bat": " - Способность цепляться за нижнюю часть блоков", "gui.unicopia.tribe_selection.confirm.goods.4.unicopia.bat": " - Имеют ужасающий, но очаровательный (и слегка раздражающий) визг", "gui.unicopia.tribe_selection.confirm.goods.1.unicopia.changeling": " - Могут летать и зависать на месте", "gui.unicopia.tribe_selection.confirm.goods.2.unicopia.changeling": " - Перевоплощаются практически в кого и что угодно", - "gui.unicopia.tribe_selection.confirm.goods.3.unicopia.changeling": " - Плотоядны. Могут есть всё, от чего не тошнит", + "gui.unicopia.tribe_selection.confirm.goods.3.unicopia.changeling": " - Прилипают к стенам и могут перелезть практически через всё", + "gui.unicopia.tribe_selection.confirm.goods.4.unicopia.changeling": " - Плотоядны. Могут есть всё, от чего не тошнит", + + "gui.unicopia.tribe_selection.confirm.goods.1.unicopia.kirin": " - Невосприимчивы ко всем видам огненного урона", + "gui.unicopia.tribe_selection.confirm.goods.2.unicopia.kirin": " - Могут открыть способность ярости, получая урон", + "gui.unicopia.tribe_selection.confirm.goods.3.unicopia.kirin": " - В обычном состоянии бесшумны и могут спокойно ходить рядом с Хранителем", + "gui.unicopia.tribe_selection.confirm.goods.4.unicopia.kirin": " - Могут есть фрукты и овощи, мясо и некоторые виды кормов, обычно ядовитые для других рас", + + "gui.unicopia.tribe_selection.confirm.goods.1.unicopia.hippogriff": " - Полёт и способность к тренировкам для повышения выносливости", + "gui.unicopia.tribe_selection.confirm.goods.2.unicopia.hippogriff": " - Могут совершать рывки в полёте", + "gui.unicopia.tribe_selection.confirm.goods.3.unicopia.hippogriff": " - Имеют острый и шумный клюв для кричания и клевания", + "gui.unicopia.tribe_selection.confirm.goods.4.unicopia.hippogriff": " - Могут употреблять сырую и варёную рыбу, варёное мясо", + "gui.unicopia.tribe_selection.confirm.goods.5.unicopia.hippogriff": " - При поедании шишек восстанавливают здоровье", + "gui.unicopia.tribe_selection.confirm.goods.6.unicopia.hippogriff": " - Любят лестницы", "gui.unicopia.tribe_selection.confirm.bads": "но они...", @@ -461,25 +609,34 @@ "gui.unicopia.tribe_selection.confirm.bads.1.unicopia.earth": " - Не могут летать", "gui.unicopia.tribe_selection.confirm.bads.2.unicopia.earth": " - Слабы к некоторым видам магии", "gui.unicopia.tribe_selection.confirm.bads.3.unicopia.earth": " - Могут есть только растения и овощи", + "gui.unicopia.tribe_selection.confirm.bads.4.unicopia.earth": " - Тяжелее и передвигаются медленнее, чем другие пони", "gui.unicopia.tribe_selection.confirm.bads.1.unicopia.unicorn": " - Не могут летать", - "gui.unicopia.tribe_selection.confirm.bads.2.unicopia.unicorn": " - Слабы к атакам грубой силы", + "gui.unicopia.tribe_selection.confirm.bads.2.unicopia.unicorn": " - Слабы к грубым атакам", "gui.unicopia.tribe_selection.confirm.bads.3.unicopia.unicorn": " - Могут есть только растения и овощи", - "gui.unicopia.tribe_selection.confirm.bads.1.unicopia.pegasus": " - Слабы к атакам грубой силы", + "gui.unicopia.tribe_selection.confirm.bads.1.unicopia.pegasus": " - Слабы к грубым атакам", "gui.unicopia.tribe_selection.confirm.bads.2.unicopia.pegasus": " - Должны отдыхать между полётами", "gui.unicopia.tribe_selection.confirm.bads.3.unicopia.pegasus": " - Не могут использовать магию без помощи", - "gui.unicopia.tribe_selection.confirm.bads.4.unicopia.pegasus": "", - "gui.unicopia.tribe_selection.confirm.bads.1.unicopia.bat": " - Слабы к атакам грубой силы", + "gui.unicopia.tribe_selection.confirm.bads.1.unicopia.bat": " - Слабы к грубым атакам", "gui.unicopia.tribe_selection.confirm.bads.2.unicopia.bat": " - Должны отдыхать между полётами", "gui.unicopia.tribe_selection.confirm.bads.3.unicopia.bat": " - Иногда боятся даже самих себя", - "gui.unicopia.tribe_selection.confirm.bads.4.unicopia.bat": " - Плотоядны. Могут есть всё, от чего не тошнит", + "gui.unicopia.tribe_selection.confirm.bads.4.unicopia.bat": " - Плотоядны. Могут есть сырое и варёное мясо или питаться исключительно ворованной любовью", "gui.unicopia.tribe_selection.confirm.bads.1.unicopia.changeling": " - Постоянно голодают", "gui.unicopia.tribe_selection.confirm.bads.2.unicopia.changeling": " - Требуют любви, которую собирают с пони или других мобов для поддержания своего рациона", - "gui.unicopia.tribe_selection.confirm.bads.3.unicopia.changeling": " - Становятся больными от обычной пищи и должны питаться любовью, чтобы ускорить излечение", - "gui.unicopia.tribe_selection.confirm.bads.4.unicopia.changeling": "", + "gui.unicopia.tribe_selection.confirm.bads.3.unicopia.changeling": " - Становятся больными от употребления самой обычной пищи и должны собирать любовь, чтобы ускорить излечение", + + "gui.unicopia.tribe_selection.confirm.bads.1.unicopia.kirin": " - Теряют свою бесшумность в состоянии ярости", + "gui.unicopia.tribe_selection.confirm.bads.2.unicopia.kirin": " - Поджигают вещи, особенно когда близки к ярости", + "gui.unicopia.tribe_selection.confirm.bads.3.unicopia.kirin": " - Легче, чем другие пони, и сильнее оттакливаются", + "gui.unicopia.tribe_selection.confirm.bads.4.unicopia.kirin": " - Не любят воду", + + "gui.unicopia.tribe_selection.confirm.bads.1.unicopia.hippogriff": " - Слабы к грубым атакам", + "gui.unicopia.tribe_selection.confirm.bads.2.unicopia.hippogriff": " - Не могут взаимодействовать с облаками", + "gui.unicopia.tribe_selection.confirm.bads.3.unicopia.hippogriff": " - Должны отдыхать между полётами, чтобы восстановить силы", + "gui.unicopia.tribe_selection.confirm.bads.4.unicopia.hippogriff": " - Имеют куриный мозг", "gui.unicopia.tribe_selection.join": "Присоединиться", "gui.unicopia.tribe_selection.cancel": "Назад", @@ -604,7 +761,7 @@ "experience.unicopia.twisted.faustian_legend": "Тёмная личность легенды", "experience.unicopia.corrupt.faustian_legend": "Старый Бог", "experience.unicopia.monstrous.faustian_legend": "Потусторонний ужас", - + "unicopia.category.name": "Способности пони", "key.unicopia.primary": "Первичная способность", @@ -704,24 +861,39 @@ "unicopia.race.changeling.alt": "Чейнджлинги", "unicopia.race.bat": "Бэтпони", "unicopia.race.bat.alt": "Бэтпони", + "unicopia.race.kirin": "Кирин", + "unicopia.race.kirin.alt": "Кирины", + "unicopia.race.hippogriff": "Гиппогриф", + "unicopia.race.hippogriff.alt": "Гиппогрифы", + "unicopia.race.seapony": "Морской пони", + "unicopia.race.seapony.alt": "Морские пони", "death.attack.unicopia.generic.and_also": "%1$s и %2$s", "death.attack.unicopia.generic.whilst_flying": "%1$s во время полёта", "death.attack.unicopia.tribe_swap": "%1$s был перерождён в другое племя", + "death.attack.unicopia.tribe_swap.self": "%1$s обрёк себя на перерождение в другое племя", "death.attack.unicopia.tribe_swap.player": "%1$s был обречён на перерождение в другое племя %2$s", "death.attack.unicopia.sun": "%1$ уставился на солнце", + "death.attack.unicopia.sun.self": "%1$s уставился на солнце", "death.attack.unicopia.sun.player": "%1$s уставился на солнце пока боролся с %2$s", "death.attack.unicopia.sunlight": "%1$s был сожжён солнцем", + "death.attack.unicopia.sunlight.self": "%1$s был сожжён солнцем", "death.attack.unicopia.sunlight.player": "%1$s был сожжён солнцем пока боролся с %2$s", "death.attack.unicopia.petrified": "%1$s превратился в камень", + "death.attack.unicopia.petrified.self": "%1$s превратился в камень", "death.attack.unicopia.petrified.player": "%1$s превратился в камень пока боролся с %2$s", "death.attack.unicopia.magical_exhaustion": "%1$s исчерпал себя", + "death.attack.unicopia.magical_exhaustion.self": "%1$s исчерпал себя", "death.attack.unicopia.magical_exhaustion.player": "%1$s исчерпал себя пока боролся с %2$s", "death.attack.unicopia.alicorn_amulet": "%1$s был сведён с ума", + "death.attack.unicopia.alicorn_amulet.self": "%1$s свёл себя с ума", "death.attack.unicopia.alicorn_amulet.player": "%1$s сошёл с ума пока боролся с %2$s", "death.attack.unicopia.darkness": "%1$s пропал без вести", - "death.attack.unicopia.love_draining": "%1$s был лишён всего живого", - "death.attack.unicopia.love_draining.player": "%1$s умер, чтобы накормить %2$s", + "death.attack.unicopia.darkness.self": "%1$s пропал без вести", + "death.attack.unicopia.darkness.player": "%1$s пропал без вести пока боролся с %2$s", + "death.attack.unicopia.love_draining": "%1$s был лишён всей любви", + "death.attack.unicopia.love_draining.self": "%1$s лишил себя всей своей любви", + "death.attack.unicopia.love_draining.player": "%2$s лишил %1$s всей любви", "death.attack.unicopia.life_draining": "%1$s был лишён всего живого", "death.attack.unicopia.life_draining.self": "%1$s был убит своим собственным заклинанием", "death.attack.unicopia.life_draining.player": "%1$s был убит заклинанием, созданным %2$s", @@ -734,22 +906,30 @@ "death.attack.unicopia.gravity_well_recoil.item": "%1$s превращён в спагетти заклинанием, созданным %2$s с помощью %3$s", "death.attack.unicopia.gravity_well_recoil.self": "%1$ произнёс заклинание, которое превратило его в спагетти", "death.attack.unicopia.smash": "%1$s был раздавлен копытом", + "death.attack.unicopia.smash.self": "%1$s раздавил себя копытом", "death.attack.unicopia.smash.player": "%1$s был раздавлен %2$s", "death.attack.unicopia.zap": "%1$s укусил зап-яблоко", + "death.attack.unicopia.zap.self": "%1$s укусил зап-яблоко", "death.attack.unicopia.zap.player": "%1$s укусил зап-яблоко пока боролся с %2$s", "death.attack.unicopia.paradox": "%1$s взорвался", + "death.attack.unicopia.paradox.self": "%1$s взорвал самого себя", "death.attack.unicopia.paradox.player": "%1$s взорвался с некоторой помощью %2$s", "death.attack.unicopia.food_poisoning": "%1$s умер от пищевого отравления", + "death.attack.unicopia.food_poisoning.self": "%1$s умер от пищевого отравления", "death.attack.unicopia.food_poisoning.player": "%2$s отравил %1$s до смерти", "death.attack.unicopia.black_hole": "%1$s был засосан в чёрную дыру", + "death.attack.unicopia.black_hole.self": "%1$s был засосан в чёрную дыру", "death.attack.unicopia.black_hole.player": "%1$s засосало в чёрную дыру %2$s", "death.attack.unicopia.kick": "%1$s был пнут очень сильно", + "death.attack.unicopia.kick.self": "%1$s пнул себя очень сильно", "death.attack.unicopia.kick.player": "%2$s очень сильно пнул %1$s", "death.attack.unicopia.steamroller": "%1$s был расплющен", + "death.attack.unicopia.steamroller.self": "%1$s был расплющен", "death.attack.unicopia.steamroller.player": "%2$s рассправился с %1$s", "death.attack.unicopia.stalagmite.pegasus": "%1$s пытался устроиться на сталагмите", - "death.attack.unicopia.stalagmite.pegasus.player": "%1$s влетел в сталагмит во время боя с %2$s", + "death.attack.unicopia.stalagmite.pegasus.player": "%1$s влетел в сталагмит пока боролся %2$s", "death.attack.unicopia.rock": "%1$s был избит", + "death.attack.unicopia.rock.self": "%1$s был избит", "death.attack.unicopia.rock.item": "%1$s был избит %2$s используя %3$s", "death.attack.unicopia.rock.player": "%1$s был избит %2$s", @@ -800,7 +980,9 @@ "unicopia.subtitle.insects": "Насекомые снуют", "unicopia.subtitle.changeling_buzz": "Жужжание дронов", "unicopia.subtitle.batpony_eeee": "Бэтпони кричит", + "unicopia.subtitle.sonar": "Сонарные импульсы", "unicopia.subtitle.changeling.transform": "Чейнджлинг трансформируется", + "unicopia.subtitle.screech": "Гиппогриф кричит", "unicopia.subtitle.pegasus.molt": "Пегас теряет перо", "unicopia.subtitle.unicorn.teleport": "Звук магии", "unicopia.subtitle.player.wololo": "Вололо!", @@ -808,6 +990,7 @@ "unicopia.subtitle.entity.player.kick": "Игрок бьёт", "unicopia.subtitle.magic_aura": "Магическое гудение", "unicopia.subtitle.player.rebound": "Игрок отскакивает от стены", + "unicopia.subtitle.screech": "Игрок кричит", "unicopia.subtitle.ears_ringing": "Звон в ушах", "unicopia.subtitle.heartbeat": "Стук сердца", "unicopia.subtitle.entity.artefact.ambient": "Магическое гудение", @@ -831,6 +1014,8 @@ "unicopia.subtitle.item.alicorn_amulet.ambient": "Гул амулета Аликорна", "unicopia.subtitle.item.apple.rot": "Яблоко гниёт", "unicopia.subtitle.item.bracelet.sign": "Подписание браслета", + "unicopia.subtitle.block.chitin.ambience": "Трещание", + "unicopia.subtitle.block.slime_pustule.pop": "Пустула со слизью разбивается", "unicopia.subtitle.spell.cast.fail": "Заклинание не удалось", "unicopia.subtitle.spell.cast.success": "Заклинание накладывается", "unicopia.subtitle.spell.cast.shoot": "Единорог стреляет", @@ -852,7 +1037,7 @@ "advancements.unicopia.lightning_bug.title": "Ошибка молнии", "advancements.unicopia.lightning_bug.description": "Привлеките 10 ударов молний", "advancements.unicopia.jar.title": "О, ничего себе. Что это?", - "advancements.unicopia.jar.description": "Найдите пустую банку", + "advancements.unicopia.jar.description": "Найдите пустую банку", "advancements.unicopia.gotcha.title": "Попался!", "advancements.unicopia.gotcha.description": "Захватите бурю", "advancements.unicopia.trick_apple.title": "Яблоко раздора", @@ -882,6 +1067,12 @@ "advancements.unicopia.apple_route.description": "Начните свой путь к яблоку легенды", "advancements.unicopia.juice.title": "Освежающий", "advancements.unicopia.juice.description": "Наконец-то нашлось применение всем этим яблокам", + "advancements.unicopia.toast.title": "Он хрустящий и вкусный!", + "advancements.unicopia.toast.description": "Сделать тостового компаньона", + "advancements.unicopia.burn_toast.title": "Тости НЕЕЕЕЕЕЕТ!", + "advancements.unicopia.burn_toast.description": "Поджарь Тости", + "advancements.unicopia.lucky.title": "Как на ТВ", + "advancements.unicopia.lucky.description": "Сделать несколько счастливых подков из картофеля фри", "advancements.unicopia.sweet_apple_acres.title": "Яблочная Аллея", "advancements.unicopia.sweet_apple_acres.description": "Получите по одному яблоку каждого сорта", "advancements.unicopia.brew_cider.title": "Лучшее от Эпплджек", diff --git a/src/main/resources/assets/unicopia/models/block/carved_cloud.json b/src/main/resources/assets/unicopia/models/block/carved_cloud.json new file mode 100644 index 00000000..3865501f --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/carved_cloud.json @@ -0,0 +1,8 @@ +{ + "parent": "minecraft:block/cube_bottom_top", + "textures": { + "bottom": "unicopia:block/carved_cloud_top", + "top": "unicopia:block/carved_cloud_top", + "side": "unicopia:block/carved_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/clam_shell_1.json b/src/main/resources/assets/unicopia/models/block/clam_shell_1.json new file mode 100644 index 00000000..281bf5ee --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/clam_shell_1.json @@ -0,0 +1,17 @@ +{ + "textures": { + "particle": "#shell", + "shell": "unicopia:item/clam_shell" + }, + "elements": [ + { + "from": [4, 1.1, 3.6], + "to": [12, 1.1, 11.6], + "rotation": {"angle": -22.5, "axis": "x", "origin": [12, 0.1, 9.6]}, + "faces": { + "up": {"uv": [0, 0, 16, 16], "rotation": 270, "texture": "#shell"}, + "down": {"uv": [16, 0, 0, 16], "rotation": 270, "texture": "#shell"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/clam_shell_2.json b/src/main/resources/assets/unicopia/models/block/clam_shell_2.json new file mode 100644 index 00000000..fb31088b --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/clam_shell_2.json @@ -0,0 +1,26 @@ +{ + "textures": { + "particle": "#shell", + "shell": "unicopia:item/clam_shell" + }, + "elements": [ + { + "from": [6.4, 0.1, 0], + "to": [14.4, 0.1, 8], + "rotation": {"angle": 22.5, "axis": "x", "origin": [12, 0, 4]}, + "faces": { + "up": {"uv": [0, 0, 16, 16], "texture": "#shell"}, + "down": {"uv": [0, 16, 16, 0], "texture": "#shell"} + } + }, + { + "from": [1.21177, -0.3, 6.78823], + "to": [9.21177, -0.3, 14.78823], + "rotation": {"angle": -22.5, "axis": "x", "origin": [5.21177, -0.4, 10.78823]}, + "faces": { + "up": {"uv": [0, 0, 16, 16], "rotation": 90, "texture": "#shell"}, + "down": {"uv": [16, 0, 0, 16], "rotation": 90, "texture": "#shell"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/clam_shell_3.json b/src/main/resources/assets/unicopia/models/block/clam_shell_3.json new file mode 100644 index 00000000..14cadc84 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/clam_shell_3.json @@ -0,0 +1,33 @@ +{ + "textures": { + "particle": "#shell", + "shell": "unicopia:item/clam_shell" + }, + "elements": [ + { + "from": [6.1, 0.4, 0.6], + "to": [14.1, 0.4, 8.6], + "rotation": {"angle": 22.5, "axis": "x", "origin": [10.1, 0.4, 3]}, + "faces": { + "up": {"uv": [0, 0, 16, 16], "rotation": 270, "texture": "#shell"} + } + }, + { + "from": [0.36402, 0, 4.02286], + "to": [8.36402, 0, 12.02286], + "rotation": {"angle": 22.5, "axis": "z", "origin": [4.36402, 0, 8.02286]}, + "faces": { + "up": {"uv": [0, 0, 16, 16], "rotation": 180, "texture": "#shell"} + } + }, + { + "from": [7.75505, 0, 8.08433], + "to": [15.75505, 0, 16.08433], + "rotation": {"angle": -22.5, "axis": "x", "origin": [11.75505, 0, 12.08433]}, + "faces": { + "up": {"uv": [0, 0, 16, 16], "rotation": 90, "texture": "#shell"}, + "down": {"uv": [16, 0, 0, 16], "rotation": 90, "texture": "#shell"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/clam_shell_4.json b/src/main/resources/assets/unicopia/models/block/clam_shell_4.json new file mode 100644 index 00000000..e269cd5a --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/clam_shell_4.json @@ -0,0 +1,44 @@ +{ + "textures": { + "particle": "#shell", + "shell": "unicopia:item/clam_shell" + }, + "elements": [ + { + "from": [8, 0.5, 0.6], + "to": [16, 0.5, 8.6], + "rotation": {"angle": 22.5, "axis": "x", "origin": [12, 0.5, 3]}, + "faces": { + "up": {"uv": [0, 0, 16, 16], "rotation": 270, "texture": "#shell"}, + "down": {"uv": [16, 0, 0, 16], "rotation": 270, "texture": "#shell"} + } + }, + { + "from": [0.36402, 0, 7.02286], + "to": [8.36402, 0, 15.02286], + "rotation": {"angle": 22.5, "axis": "x", "origin": [4.36402, 0, 11.02286]}, + "faces": { + "up": {"uv": [0, 0, 16, 16], "rotation": 270, "texture": "#shell"}, + "down": {"uv": [16, 0, 0, 16], "rotation": 270, "texture": "#shell"} + } + }, + { + "from": [1.36402, 0, 0.02286], + "to": [9.36402, 0, 8.02286], + "rotation": {"angle": 22.5, "axis": "z", "origin": [5.36402, 0, 4.02286]}, + "faces": { + "up": {"uv": [0, 0, 16, 16], "rotation": 180, "texture": "#shell"}, + "down": {"uv": [0, 16, 16, 0], "rotation": 180, "texture": "#shell"} + } + }, + { + "from": [7.75505, 0, 8.08433], + "to": [15.75505, 0, 16.08433], + "rotation": {"angle": -22.5, "axis": "x", "origin": [11.75505, 0, 12.08433]}, + "faces": { + "up": {"uv": [0, 0, 16, 16], "rotation": 90, "texture": "#shell"}, + "down": {"uv": [0, 16, 16, 0], "rotation": 270, "texture": "#shell"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/cloth_bed.json b/src/main/resources/assets/unicopia/models/block/cloth_bed.json new file mode 100644 index 00000000..91a36d8c --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/cloth_bed.json @@ -0,0 +1,5 @@ +{ + "textures": { + "particle": "minecraft:block/spruce_planks" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/cloud_brick_slab.json b/src/main/resources/assets/unicopia/models/block/cloud_brick_slab.json new file mode 100644 index 00000000..eca5f0be --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/cloud_brick_slab.json @@ -0,0 +1,8 @@ +{ + "parent": "minecraft:block/slab", + "textures": { + "bottom": "unicopia:block/cloud_bricks", + "side": "unicopia:block/cloud_bricks", + "top": "unicopia:block/cloud_bricks" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/cloud_brick_slab_top.json b/src/main/resources/assets/unicopia/models/block/cloud_brick_slab_top.json new file mode 100644 index 00000000..728c135f --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/cloud_brick_slab_top.json @@ -0,0 +1,8 @@ +{ + "parent": "minecraft:block/slab_top", + "textures": { + "bottom": "unicopia:block/cloud_bricks", + "side": "unicopia:block/cloud_bricks", + "top": "unicopia:block/cloud_bricks" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/cloud_brick_stairs.json b/src/main/resources/assets/unicopia/models/block/cloud_brick_stairs.json new file mode 100644 index 00000000..83922596 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/cloud_brick_stairs.json @@ -0,0 +1,8 @@ +{ + "parent": "unicopia:block/cloud_stairs", + "textures": { + "bottom": "unicopia:block/cloud_bricks", + "side": "unicopia:block/cloud_bricks", + "top": "unicopia:block/cloud_bricks" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/cloud_brick_stairs_inner.json b/src/main/resources/assets/unicopia/models/block/cloud_brick_stairs_inner.json new file mode 100644 index 00000000..b523f247 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/cloud_brick_stairs_inner.json @@ -0,0 +1,8 @@ +{ + "parent": "unicopia:block/cloud_stairs_inner", + "textures": { + "bottom": "unicopia:block/cloud_bricks", + "side": "unicopia:block/cloud_bricks", + "top": "unicopia:block/cloud_bricks" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/cloud_brick_stairs_outer.json b/src/main/resources/assets/unicopia/models/block/cloud_brick_stairs_outer.json new file mode 100644 index 00000000..adecbca0 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/cloud_brick_stairs_outer.json @@ -0,0 +1,8 @@ +{ + "parent": "unicopia:block/cloud_stairs_outer", + "textures": { + "bottom": "unicopia:block/cloud_bricks", + "side": "unicopia:block/cloud_bricks", + "top": "unicopia:block/cloud_bricks" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/cloud_bricks.json b/src/main/resources/assets/unicopia/models/block/cloud_bricks.json new file mode 100644 index 00000000..6f81c05e --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/cloud_bricks.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "unicopia:block/cloud_bricks" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/cloud_chest.json b/src/main/resources/assets/unicopia/models/block/cloud_chest.json new file mode 100644 index 00000000..e30e3f72 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/cloud_chest.json @@ -0,0 +1,5 @@ +{ + "textures": { + "particle": "unicopia:block/cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/cloud_planks_slab.json b/src/main/resources/assets/unicopia/models/block/cloud_plank_slab.json similarity index 100% rename from src/main/resources/assets/unicopia/models/block/cloud_planks_slab.json rename to src/main/resources/assets/unicopia/models/block/cloud_plank_slab.json diff --git a/src/main/resources/assets/unicopia/models/block/cloud_planks_slab_top.json b/src/main/resources/assets/unicopia/models/block/cloud_plank_slab_top.json similarity index 100% rename from src/main/resources/assets/unicopia/models/block/cloud_planks_slab_top.json rename to src/main/resources/assets/unicopia/models/block/cloud_plank_slab_top.json diff --git a/src/main/resources/assets/unicopia/models/block/cloud_planks_stairs.json b/src/main/resources/assets/unicopia/models/block/cloud_plank_stairs.json similarity index 100% rename from src/main/resources/assets/unicopia/models/block/cloud_planks_stairs.json rename to src/main/resources/assets/unicopia/models/block/cloud_plank_stairs.json diff --git a/src/main/resources/assets/unicopia/models/block/cloud_planks_stairs_inner.json b/src/main/resources/assets/unicopia/models/block/cloud_plank_stairs_inner.json similarity index 100% rename from src/main/resources/assets/unicopia/models/block/cloud_planks_stairs_inner.json rename to src/main/resources/assets/unicopia/models/block/cloud_plank_stairs_inner.json diff --git a/src/main/resources/assets/unicopia/models/block/cloud_planks_stairs_outer.json b/src/main/resources/assets/unicopia/models/block/cloud_plank_stairs_outer.json similarity index 100% rename from src/main/resources/assets/unicopia/models/block/cloud_planks_stairs_outer.json rename to src/main/resources/assets/unicopia/models/block/cloud_plank_stairs_outer.json diff --git a/src/main/resources/assets/unicopia/models/block/door/bakery_bottom.json b/src/main/resources/assets/unicopia/models/block/door/bakery_bottom.json deleted file mode 100644 index 20af668b..00000000 --- a/src/main/resources/assets/unicopia/models/block/door/bakery_bottom.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "unicopia:block/door/bottom", - "textures": { - "bottom": "unicopia:blocks/door_bakery_lower", - "top": "unicopia:blocks/door_bakery_upper" - } -} diff --git a/src/main/resources/assets/unicopia/models/block/door/bakery_bottom_rh.json b/src/main/resources/assets/unicopia/models/block/door/bakery_bottom_rh.json deleted file mode 100644 index f82e8191..00000000 --- a/src/main/resources/assets/unicopia/models/block/door/bakery_bottom_rh.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "unicopia:block/door/bottom_rh", - "textures": { - "bottom": "unicopia:blocks/door_bakery_lower", - "top": "unicopia:blocks/door_bakery_upper" - } -} diff --git a/src/main/resources/assets/unicopia/models/block/door/bakery_top.json b/src/main/resources/assets/unicopia/models/block/door/bakery_top.json deleted file mode 100644 index ea3a51b0..00000000 --- a/src/main/resources/assets/unicopia/models/block/door/bakery_top.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "unicopia:block/door/top", - "textures": { - "bottom": "unicopia:blocks/door_bakery_lower", - "top": "unicopia:blocks/door_bakery_upper" - } -} diff --git a/src/main/resources/assets/unicopia/models/block/door/bakery_top_rh.json b/src/main/resources/assets/unicopia/models/block/door/bakery_top_rh.json deleted file mode 100644 index 38cc28ce..00000000 --- a/src/main/resources/assets/unicopia/models/block/door/bakery_top_rh.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "unicopia:block/door/top_rh", - "textures": { - "bottom": "unicopia:blocks/door_bakery_lower", - "top": "unicopia:blocks/door_bakery_upper" - } -} diff --git a/src/main/resources/assets/unicopia/models/block/door/cloud_bottom.json b/src/main/resources/assets/unicopia/models/block/door/cloud_bottom.json new file mode 100644 index 00000000..b5afc313 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/door/cloud_bottom.json @@ -0,0 +1,7 @@ +{ + "parent": "unicopia:block/door/bottom", + "textures": { + "bottom": "unicopia:block/cloud_door_lower", + "top": "unicopia:block/cloud_door_upper" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/door/cloud_bottom_rh.json b/src/main/resources/assets/unicopia/models/block/door/cloud_bottom_rh.json new file mode 100644 index 00000000..575b5941 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/door/cloud_bottom_rh.json @@ -0,0 +1,7 @@ +{ + "parent": "unicopia:block/door/bottom_rh", + "textures": { + "bottom": "unicopia:block/cloud_door_lower", + "top": "unicopia:block/cloud_door_upper" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/door/cloud_top.json b/src/main/resources/assets/unicopia/models/block/door/cloud_top.json new file mode 100644 index 00000000..41bed4d6 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/door/cloud_top.json @@ -0,0 +1,7 @@ +{ + "parent": "unicopia:block/door/top", + "textures": { + "bottom": "unicopia:block/cloud_door_lower", + "top": "unicopia:block/cloud_door_upper" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/door/cloud_top_rh.json b/src/main/resources/assets/unicopia/models/block/door/cloud_top_rh.json new file mode 100644 index 00000000..fb1c6ad9 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/door/cloud_top_rh.json @@ -0,0 +1,7 @@ +{ + "parent": "unicopia:block/door/top_rh", + "textures": { + "bottom": "unicopia:block/cloud_door_lower", + "top": "unicopia:block/cloud_door_upper" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/door/crystal_bottom.json b/src/main/resources/assets/unicopia/models/block/door/crystal_bottom.json new file mode 100644 index 00000000..ef81dfb9 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/door/crystal_bottom.json @@ -0,0 +1,7 @@ +{ + "parent": "unicopia:block/door/bottom", + "textures": { + "bottom": "unicopia:block/crystal_door_lower", + "top": "unicopia:block/crystal_door_upper" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/door/crystal_bottom_rh.json b/src/main/resources/assets/unicopia/models/block/door/crystal_bottom_rh.json new file mode 100644 index 00000000..5919da7d --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/door/crystal_bottom_rh.json @@ -0,0 +1,7 @@ +{ + "parent": "unicopia:block/door/bottom_rh", + "textures": { + "bottom": "unicopia:block/crystal_door_lower", + "top": "unicopia:block/crystal_door_upper" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/door/crystal_top.json b/src/main/resources/assets/unicopia/models/block/door/crystal_top.json new file mode 100644 index 00000000..f7ab0700 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/door/crystal_top.json @@ -0,0 +1,7 @@ +{ + "parent": "unicopia:block/door/top", + "textures": { + "bottom": "unicopia:block/crystal_door_lower", + "top": "unicopia:block/crystal_door_upper" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/door/crystal_top_rh.json b/src/main/resources/assets/unicopia/models/block/door/crystal_top_rh.json new file mode 100644 index 00000000..9e7f150c --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/door/crystal_top_rh.json @@ -0,0 +1,7 @@ +{ + "parent": "unicopia:block/door/top_rh", + "textures": { + "bottom": "unicopia:block/crystal_door_lower", + "top": "unicopia:block/crystal_door_upper" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/door/dark_oak_stable_bottom.json b/src/main/resources/assets/unicopia/models/block/door/dark_oak_stable_bottom.json new file mode 100644 index 00000000..80964112 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/door/dark_oak_stable_bottom.json @@ -0,0 +1,7 @@ +{ + "parent": "unicopia:block/door/bottom", + "textures": { + "bottom": "unicopia:block/door_library_lower", + "top": "unicopia:block/door_library_upper" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/door/dark_oak_stable_bottom_rh.json b/src/main/resources/assets/unicopia/models/block/door/dark_oak_stable_bottom_rh.json new file mode 100644 index 00000000..2304df0e --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/door/dark_oak_stable_bottom_rh.json @@ -0,0 +1,7 @@ +{ + "parent": "unicopia:block/door/bottom_rh", + "textures": { + "bottom": "unicopia:block/door_library_lower", + "top": "unicopia:block/door_library_upper" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/door/dark_oak_stable_top.json b/src/main/resources/assets/unicopia/models/block/door/dark_oak_stable_top.json new file mode 100644 index 00000000..f4b0fc2f --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/door/dark_oak_stable_top.json @@ -0,0 +1,7 @@ +{ + "parent": "unicopia:block/door/top", + "textures": { + "bottom": "unicopia:block/door_library_lower", + "top": "unicopia:block/door_library_upper" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/door/dark_oak_stable_top_rh.json b/src/main/resources/assets/unicopia/models/block/door/dark_oak_stable_top_rh.json new file mode 100644 index 00000000..669abb48 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/door/dark_oak_stable_top_rh.json @@ -0,0 +1,7 @@ +{ + "parent": "unicopia:block/door/top_rh", + "textures": { + "bottom": "unicopia:block/door_library_lower", + "top": "unicopia:block/door_library_upper" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/door/diamond_bottom.json b/src/main/resources/assets/unicopia/models/block/door/diamond_bottom.json deleted file mode 100644 index 02d76d21..00000000 --- a/src/main/resources/assets/unicopia/models/block/door/diamond_bottom.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "unicopia:block/door/bottom", - "textures": { - "bottom": "unicopia:blocks/door_diamond_lower", - "top": "unicopia:blocks/door_diamond_upper" - } -} diff --git a/src/main/resources/assets/unicopia/models/block/door/diamond_bottom_rh.json b/src/main/resources/assets/unicopia/models/block/door/diamond_bottom_rh.json deleted file mode 100644 index 8556b6d7..00000000 --- a/src/main/resources/assets/unicopia/models/block/door/diamond_bottom_rh.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "unicopia:block/door/bottom_rh", - "textures": { - "bottom": "unicopia:blocks/door_diamond_lower", - "top": "unicopia:blocks/door_diamond_upper" - } -} diff --git a/src/main/resources/assets/unicopia/models/block/door/diamond_top.json b/src/main/resources/assets/unicopia/models/block/door/diamond_top.json deleted file mode 100644 index 19212184..00000000 --- a/src/main/resources/assets/unicopia/models/block/door/diamond_top.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "unicopia:block/door/top", - "textures": { - "bottom": "unicopia:blocks/door_diamond_lower", - "top": "unicopia:blocks/door_diamond_upper" - } -} diff --git a/src/main/resources/assets/unicopia/models/block/door/diamond_top_rh.json b/src/main/resources/assets/unicopia/models/block/door/diamond_top_rh.json deleted file mode 100644 index ad3be532..00000000 --- a/src/main/resources/assets/unicopia/models/block/door/diamond_top_rh.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "unicopia:block/door/top_rh", - "textures": { - "bottom": "unicopia:blocks/door_diamond_lower", - "top": "unicopia:blocks/door_diamond_upper" - } -} diff --git a/src/main/resources/assets/unicopia/models/block/door/library_bottom.json b/src/main/resources/assets/unicopia/models/block/door/library_bottom.json deleted file mode 100644 index 9696a7f6..00000000 --- a/src/main/resources/assets/unicopia/models/block/door/library_bottom.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "unicopia:block/door/bottom", - "textures": { - "bottom": "unicopia:blocks/door_library_lower", - "top": "unicopia:blocks/door_library_upper" - } -} diff --git a/src/main/resources/assets/unicopia/models/block/door/library_bottom_rh.json b/src/main/resources/assets/unicopia/models/block/door/library_bottom_rh.json deleted file mode 100644 index b06d234d..00000000 --- a/src/main/resources/assets/unicopia/models/block/door/library_bottom_rh.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "unicopia:block/door/bottom_rh", - "textures": { - "bottom": "unicopia:blocks/door_library_lower", - "top": "unicopia:blocks/door_library_upper" - } -} diff --git a/src/main/resources/assets/unicopia/models/block/door/library_top.json b/src/main/resources/assets/unicopia/models/block/door/library_top.json deleted file mode 100644 index e230b4df..00000000 --- a/src/main/resources/assets/unicopia/models/block/door/library_top.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "unicopia:block/door/top", - "textures": { - "bottom": "unicopia:blocks/door_library_lower", - "top": "unicopia:blocks/door_library_upper" - } -} diff --git a/src/main/resources/assets/unicopia/models/block/door/library_top_rh.json b/src/main/resources/assets/unicopia/models/block/door/library_top_rh.json deleted file mode 100644 index 13422e83..00000000 --- a/src/main/resources/assets/unicopia/models/block/door/library_top_rh.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "unicopia:block/door/top_rh", - "textures": { - "bottom": "unicopia:blocks/door_library_lower", - "top": "unicopia:blocks/door_library_upper" - } -} diff --git a/src/main/resources/assets/unicopia/models/block/door/mist_bottom.json b/src/main/resources/assets/unicopia/models/block/door/mist_bottom.json deleted file mode 100644 index 9d342f67..00000000 --- a/src/main/resources/assets/unicopia/models/block/door/mist_bottom.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "minecraft:block/door_bottom", - "textures": { - "bottom": "unicopia:blocks/door_mist_lower", - "top": "unicopia:blocks/door_mist_upper" - } -} diff --git a/src/main/resources/assets/unicopia/models/block/door/mist_bottom_rh.json b/src/main/resources/assets/unicopia/models/block/door/mist_bottom_rh.json deleted file mode 100644 index babde1e1..00000000 --- a/src/main/resources/assets/unicopia/models/block/door/mist_bottom_rh.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "block/door_bottom_rh", - "textures": { - "bottom": "unicopia:blocks/door_mist_lower", - "top": "unicopia:blocks/door_mist_upper" - } -} diff --git a/src/main/resources/assets/unicopia/models/block/door/mist_top.json b/src/main/resources/assets/unicopia/models/block/door/mist_top.json deleted file mode 100644 index cc1bbbb4..00000000 --- a/src/main/resources/assets/unicopia/models/block/door/mist_top.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "block/door_top", - "textures": { - "bottom": "unicopia:blocks/door_mist_lower", - "top": "unicopia:blocks/door_mist_upper" - } -} diff --git a/src/main/resources/assets/unicopia/models/block/door/mist_top_rh.json b/src/main/resources/assets/unicopia/models/block/door/mist_top_rh.json deleted file mode 100644 index f75c8761..00000000 --- a/src/main/resources/assets/unicopia/models/block/door/mist_top_rh.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "block/door_top_rh", - "textures": { - "bottom": "unicopia:blocks/door_mist_lower", - "top": "unicopia:blocks/door_mist_upper" - } -} diff --git a/src/main/resources/assets/unicopia/models/block/door/stable_bottom.json b/src/main/resources/assets/unicopia/models/block/door/stable_bottom.json new file mode 100644 index 00000000..efbfa9c1 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/door/stable_bottom.json @@ -0,0 +1,7 @@ +{ + "parent": "unicopia:block/door/bottom", + "textures": { + "bottom": "unicopia:block/stable_door_lower", + "top": "unicopia:block/stable_door_upper" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/door/stable_bottom_rh.json b/src/main/resources/assets/unicopia/models/block/door/stable_bottom_rh.json new file mode 100644 index 00000000..857535ec --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/door/stable_bottom_rh.json @@ -0,0 +1,7 @@ +{ + "parent": "unicopia:block/door/bottom_rh", + "textures": { + "bottom": "unicopia:block/stable_door_lower", + "top": "unicopia:block/stable_door_upper" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/door/stable_top.json b/src/main/resources/assets/unicopia/models/block/door/stable_top.json new file mode 100644 index 00000000..18822b0b --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/door/stable_top.json @@ -0,0 +1,7 @@ +{ + "parent": "unicopia:block/door/top", + "textures": { + "bottom": "unicopia:block/stable_door_lower", + "top": "unicopia:block/stable_door_upper" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/door/stable_top_rh.json b/src/main/resources/assets/unicopia/models/block/door/stable_top_rh.json new file mode 100644 index 00000000..29559c4d --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/door/stable_top_rh.json @@ -0,0 +1,7 @@ +{ + "parent": "unicopia:block/door/top_rh", + "textures": { + "bottom": "unicopia:block/stable_door_lower", + "top": "unicopia:block/stable_door_upper" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/etched_cloud.json b/src/main/resources/assets/unicopia/models/block/etched_cloud.json new file mode 100644 index 00000000..3bc4dc53 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/etched_cloud.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "unicopia:block/etched_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/etched_cloud_slab.json b/src/main/resources/assets/unicopia/models/block/etched_cloud_slab.json new file mode 100644 index 00000000..3e08552c --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/etched_cloud_slab.json @@ -0,0 +1,8 @@ +{ + "parent": "minecraft:block/slab", + "textures": { + "bottom": "unicopia:block/etched_cloud", + "side": "unicopia:block/etched_cloud", + "top": "unicopia:block/etched_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/etched_cloud_slab_top.json b/src/main/resources/assets/unicopia/models/block/etched_cloud_slab_top.json new file mode 100644 index 00000000..1e3a94a8 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/etched_cloud_slab_top.json @@ -0,0 +1,8 @@ +{ + "parent": "minecraft:block/slab_top", + "textures": { + "bottom": "unicopia:block/etched_cloud", + "side": "unicopia:block/etched_cloud", + "top": "unicopia:block/etched_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/etched_cloud_stairs.json b/src/main/resources/assets/unicopia/models/block/etched_cloud_stairs.json new file mode 100644 index 00000000..13559128 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/etched_cloud_stairs.json @@ -0,0 +1,8 @@ +{ + "parent": "unicopia:block/cloud_stairs", + "textures": { + "bottom": "unicopia:block/etched_cloud", + "side": "unicopia:block/etched_cloud", + "top": "unicopia:block/etched_cloud" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/etched_cloud_stairs_inner.json b/src/main/resources/assets/unicopia/models/block/etched_cloud_stairs_inner.json new file mode 100644 index 00000000..e54dae19 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/etched_cloud_stairs_inner.json @@ -0,0 +1,8 @@ +{ + "parent": "unicopia:block/cloud_stairs_inner", + "textures": { + "bottom": "unicopia:block/etched_cloud", + "side": "unicopia:block/etched_cloud", + "top": "unicopia:block/etched_cloud" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/etched_cloud_stairs_outer.json b/src/main/resources/assets/unicopia/models/block/etched_cloud_stairs_outer.json new file mode 100644 index 00000000..8ee25113 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/etched_cloud_stairs_outer.json @@ -0,0 +1,8 @@ +{ + "parent": "unicopia:block/cloud_stairs_outer", + "textures": { + "bottom": "unicopia:block/etched_cloud", + "side": "unicopia:block/etched_cloud", + "top": "unicopia:block/etched_cloud" + } +} diff --git a/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_full.json b/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_full.json new file mode 100644 index 00000000..15e12a24 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_full.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_full", + "textures": { + "all": "unicopia:block/cloud_bricks" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_x.json b/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_x.json new file mode 100644 index 00000000..4797b3d6 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_x.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_x", + "textures": { + "all": "unicopia:block/cloud_bricks" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_xy.json b/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_xy.json new file mode 100644 index 00000000..ae763e79 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_xy.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_xy", + "textures": { + "all": "unicopia:block/cloud_bricks" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_xyz.json b/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_xyz.json new file mode 100644 index 00000000..a8233437 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_xyz.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_xyz", + "textures": { + "all": "unicopia:block/cloud_bricks" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_xz.json b/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_xz.json new file mode 100644 index 00000000..74099462 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_xz.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_xz", + "textures": { + "all": "unicopia:block/cloud_bricks" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_y.json b/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_y.json new file mode 100644 index 00000000..01ac9a03 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_y.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_y", + "textures": { + "all": "unicopia:block/cloud_bricks" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_yz.json b/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_yz.json new file mode 100644 index 00000000..000225a7 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_yz.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_yz", + "textures": { + "all": "unicopia:block/cloud_bricks" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_z.json b/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_z.json new file mode 100644 index 00000000..9aa4eacb --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_cloud_bricks_corner_z.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_z", + "textures": { + "all": "unicopia:block/cloud_bricks" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_full.json b/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_full.json new file mode 100644 index 00000000..96ed79e2 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_full.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_full", + "textures": { + "all": "unicopia:block/dense_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_x.json b/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_x.json new file mode 100644 index 00000000..a0e2924d --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_x.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_x", + "textures": { + "all": "unicopia:block/dense_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_xy.json b/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_xy.json new file mode 100644 index 00000000..f38b7250 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_xy.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_xy", + "textures": { + "all": "unicopia:block/dense_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_xyz.json b/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_xyz.json new file mode 100644 index 00000000..382df9ab --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_xyz.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_xyz", + "textures": { + "all": "unicopia:block/dense_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_xz.json b/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_xz.json new file mode 100644 index 00000000..bad87c59 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_xz.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_xz", + "textures": { + "all": "unicopia:block/dense_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_y.json b/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_y.json new file mode 100644 index 00000000..2e2572a5 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_y.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_y", + "textures": { + "all": "unicopia:block/dense_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_yz.json b/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_yz.json new file mode 100644 index 00000000..b4e0a676 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_yz.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_yz", + "textures": { + "all": "unicopia:block/dense_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_z.json b/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_z.json new file mode 100644 index 00000000..fa657f3b --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_dense_cloud_corner_z.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_z", + "textures": { + "all": "unicopia:block/dense_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_full.json b/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_full.json new file mode 100644 index 00000000..96ed79e2 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_full.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_full", + "textures": { + "all": "unicopia:block/dense_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_x.json b/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_x.json new file mode 100644 index 00000000..a0e2924d --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_x.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_x", + "textures": { + "all": "unicopia:block/dense_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_xy.json b/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_xy.json new file mode 100644 index 00000000..f38b7250 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_xy.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_xy", + "textures": { + "all": "unicopia:block/dense_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_xyz.json b/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_xyz.json new file mode 100644 index 00000000..382df9ab --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_xyz.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_xyz", + "textures": { + "all": "unicopia:block/dense_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_xz.json b/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_xz.json new file mode 100644 index 00000000..bad87c59 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_xz.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_xz", + "textures": { + "all": "unicopia:block/dense_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_y.json b/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_y.json new file mode 100644 index 00000000..2e2572a5 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_y.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_y", + "textures": { + "all": "unicopia:block/dense_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_yz.json b/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_yz.json new file mode 100644 index 00000000..b4e0a676 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_yz.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_yz", + "textures": { + "all": "unicopia:block/dense_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_z.json b/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_z.json new file mode 100644 index 00000000..fa657f3b --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/flattened_etched_cloud_corner_z.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/flattened_cloud_corner_z", + "textures": { + "all": "unicopia:block/dense_cloud" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/plunder_vine_branch.json b/src/main/resources/assets/unicopia/models/block/plunder_vine_branch.json new file mode 100644 index 00000000..0c51be21 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/plunder_vine_branch.json @@ -0,0 +1,75 @@ +{ + "textures": { + "particle": "unicopia:block/plunder_vine", + "stem": "unicopia:block/plunder_vine", + "leaf": "unicopia:block/plunder_leaf" + }, + "elements": [ + { + "from": [7.3, 0, 7.3], + "to": [8.7, 9, 8.7], + "faces": { + "north": {"uv": [0, 2, 2, 11], "texture": "#stem"}, + "east": {"uv": [0, 2, 2, 11], "texture": "#stem"}, + "south": {"uv": [0, 2, 2, 11], "texture": "#stem"}, + "west": {"uv": [0, 2, 2, 11], "texture": "#stem"}, + "up": {"uv": [2, 2, 0, 0], "texture": "#stem"}, + "down": {"uv": [2, 0, 0, 2], "texture": "#stem"} + } + }, + { + "from": [4, 0, 8], + "to": [12, 8, 8], + "rotation": {"angle": 45, "axis": "y", "origin": [8, 11, 8]}, + "faces": { + "north": {"uv": [0, 0, 16, 16], "texture": "#leaf"}, + "south": {"uv": [0, 0, 16, 16], "texture": "#leaf"} + } + }, + { + "from": [4, 5, 8], + "to": [12, 13, 8], + "rotation": {"angle": -45, "axis": "y", "origin": [8, 11, 8]}, + "faces": { + "north": {"uv": [0, 0, 16, 16], "texture": "#leaf"}, + "south": {"uv": [0, 0, 16, 16], "texture": "#leaf"} + } + }, + { + "from": [6, 3.95, 8.1], + "to": [7, 4.95, 8.1], + "rotation": {"angle": -45, "axis": "z", "origin": [7, 4, 8]}, + "faces": { + "north": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "south": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + }, + { + "from": [6, 6.95, 8.1], + "to": [7, 7.95, 8.1], + "rotation": {"angle": -45, "axis": "z", "origin": [7, 4, 8]}, + "faces": { + "north": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "south": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + }, + { + "from": [8, 2.35, 10.1], + "to": [8, 3.35, 11.1], + "rotation": {"angle": 45, "axis": "x", "origin": [7, 4, 8]}, + "faces": { + "east": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "west": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + }, + { + "from": [8, 5.35, 4.1], + "to": [8, 6.35, 5.1], + "rotation": {"angle": 45, "axis": "x", "origin": [7, 4, 8]}, + "faces": { + "east": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "west": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/plunder_vine_branch_2.json b/src/main/resources/assets/unicopia/models/block/plunder_vine_branch_2.json new file mode 100644 index 00000000..ce94fc6c --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/plunder_vine_branch_2.json @@ -0,0 +1,75 @@ +{ + "textures": { + "particle": "unicopia:block/plunder_vine", + "stem": "unicopia:block/plunder_vine", + "leaf": "unicopia:block/plunder_leaf" + }, + "elements": [ + { + "from": [7, 0, 7], + "to": [9, 9, 9], + "faces": { + "north": {"uv": [0, 2, 2, 11], "texture": "#stem"}, + "east": {"uv": [0, 2, 2, 11], "texture": "#stem"}, + "south": {"uv": [0, 2, 2, 11], "texture": "#stem"}, + "west": {"uv": [0, 2, 2, 11], "texture": "#stem"}, + "up": {"uv": [2, 2, 0, 0], "texture": "#stem"}, + "down": {"uv": [2, 0, 0, 2], "texture": "#stem"} + } + }, + { + "from": [4, 0, 8], + "to": [12, 8, 8], + "rotation": {"angle": 45, "axis": "y", "origin": [8, 11, 8]}, + "faces": { + "north": {"uv": [0, 0, 16, 16], "texture": "#leaf"}, + "south": {"uv": [0, 0, 16, 16], "texture": "#leaf"} + } + }, + { + "from": [4, 5, 8], + "to": [12, 13, 8], + "rotation": {"angle": -45, "axis": "y", "origin": [8, 11, 8]}, + "faces": { + "north": {"uv": [0, 0, 16, 16], "texture": "#leaf"}, + "south": {"uv": [0, 0, 16, 16], "texture": "#leaf"} + } + }, + { + "from": [6, 3.95, 8.1], + "to": [7, 4.95, 8.1], + "rotation": {"angle": -45, "axis": "z", "origin": [7, 4, 8]}, + "faces": { + "north": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "south": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + }, + { + "from": [6, 6.95, 8.1], + "to": [7, 7.95, 8.1], + "rotation": {"angle": -45, "axis": "z", "origin": [7, 4, 8]}, + "faces": { + "north": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "south": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + }, + { + "from": [8, 2.35, 10.1], + "to": [8, 3.35, 11.1], + "rotation": {"angle": 45, "axis": "x", "origin": [7, 4, 8]}, + "faces": { + "east": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "west": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + }, + { + "from": [8, 5.35, 4.1], + "to": [8, 6.35, 5.1], + "rotation": {"angle": 45, "axis": "x", "origin": [7, 4, 8]}, + "faces": { + "east": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "west": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/plunder_vine_branch_3.json b/src/main/resources/assets/unicopia/models/block/plunder_vine_branch_3.json new file mode 100644 index 00000000..4aae794e --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/plunder_vine_branch_3.json @@ -0,0 +1,75 @@ +{ + "textures": { + "particle": "unicopia:block/plunder_vine", + "stem": "unicopia:block/plunder_vine", + "leaf": "unicopia:block/plunder_leaf" + }, + "elements": [ + { + "from": [6.5, 0, 6.5], + "to": [9.5, 9, 9.5], + "faces": { + "north": {"uv": [0, 2, 4, 11], "texture": "#stem"}, + "east": {"uv": [0, 2, 4, 11], "texture": "#stem"}, + "south": {"uv": [0, 2, 4, 11], "texture": "#stem"}, + "west": {"uv": [0, 2, 4, 11], "texture": "#stem"}, + "up": {"uv": [2, 2, 0, 0], "texture": "#stem"}, + "down": {"uv": [2, 0, 0, 2], "texture": "#stem"} + } + }, + { + "from": [3, 0, 8], + "to": [13, 8, 8], + "rotation": {"angle": 45, "axis": "y", "origin": [8, 11, 8]}, + "faces": { + "north": {"uv": [0, 0, 16, 16], "texture": "#leaf"}, + "south": {"uv": [0, 0, 16, 16], "texture": "#leaf"} + } + }, + { + "from": [3, 5, 8], + "to": [13, 13, 8], + "rotation": {"angle": -45, "axis": "y", "origin": [8, 11, 8]}, + "faces": { + "north": {"uv": [0, 0, 16, 16], "texture": "#leaf"}, + "south": {"uv": [0, 0, 16, 16], "texture": "#leaf"} + } + }, + { + "from": [5.6, 3.95, 8.1], + "to": [6.6, 4.95, 8.1], + "rotation": {"angle": -45, "axis": "z", "origin": [6.6, 4, 8]}, + "faces": { + "north": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "south": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + }, + { + "from": [6.4, 6.95, 8.1], + "to": [7.4, 7.95, 8.1], + "rotation": {"angle": -45, "axis": "z", "origin": [7.4, 4, 8]}, + "faces": { + "north": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "south": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + }, + { + "from": [8, 2.35, 10.6], + "to": [8, 3.35, 11.6], + "rotation": {"angle": 45, "axis": "x", "origin": [7, 4, 8.5]}, + "faces": { + "east": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "west": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + }, + { + "from": [8, 5.35, 3.8], + "to": [8, 6.35, 4.8], + "rotation": {"angle": 45, "axis": "x", "origin": [7, 4, 7.7]}, + "faces": { + "east": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "west": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/plunder_vine_branch_4.json b/src/main/resources/assets/unicopia/models/block/plunder_vine_branch_4.json new file mode 100644 index 00000000..d8d8c7d1 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/plunder_vine_branch_4.json @@ -0,0 +1,75 @@ +{ + "textures": { + "particle": "unicopia:block/plunder_vine", + "stem": "unicopia:block/plunder_vine", + "leaf": "unicopia:block/plunder_leaf" + }, + "elements": [ + { + "from": [6, 0, 6], + "to": [10, 9, 10], + "faces": { + "north": {"uv": [0, 2, 4, 11], "texture": "#stem"}, + "east": {"uv": [0, 2, 4, 11], "texture": "#stem"}, + "south": {"uv": [0, 2, 4, 11], "texture": "#stem"}, + "west": {"uv": [0, 2, 4, 11], "texture": "#stem"}, + "up": {"uv": [2, 2, 0, 0], "texture": "#stem"}, + "down": {"uv": [2, 0, 0, 2], "texture": "#stem"} + } + }, + { + "from": [3, 0, 8], + "to": [13, 8, 8], + "rotation": {"angle": 45, "axis": "y", "origin": [8, 11, 8]}, + "faces": { + "north": {"uv": [0, 0, 16, 16], "texture": "#leaf"}, + "south": {"uv": [0, 0, 16, 16], "texture": "#leaf"} + } + }, + { + "from": [3, 5, 8], + "to": [13, 13, 8], + "rotation": {"angle": -45, "axis": "y", "origin": [8, 11, 8]}, + "faces": { + "north": {"uv": [0, 0, 16, 16], "texture": "#leaf"}, + "south": {"uv": [0, 0, 16, 16], "texture": "#leaf"} + } + }, + { + "from": [4.8, 3.95, 8.1], + "to": [5.8, 4.95, 8.1], + "rotation": {"angle": -45, "axis": "z", "origin": [5.8, 4, 8]}, + "faces": { + "north": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "south": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + }, + { + "from": [7.8, 6.95, 8.1], + "to": [8.8, 7.95, 8.1], + "rotation": {"angle": -45, "axis": "z", "origin": [8.8, 4, 8]}, + "faces": { + "north": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "south": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + }, + { + "from": [8, 2.35, 11.4], + "to": [8, 3.35, 12.4], + "rotation": {"angle": 45, "axis": "x", "origin": [7, 4, 9.3]}, + "faces": { + "east": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "west": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + }, + { + "from": [8, 5.35, 2.9], + "to": [8, 6.35, 3.9], + "rotation": {"angle": 45, "axis": "x", "origin": [7, 4, 6.8]}, + "faces": { + "east": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "west": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/plunder_vine_bud.json b/src/main/resources/assets/unicopia/models/block/plunder_vine_bud.json new file mode 100644 index 00000000..9721c814 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/plunder_vine_bud.json @@ -0,0 +1,145 @@ +{ + "textures": { + "particle": "unicopia:block/plunder_vine", + "stem": "unicopia:block/plunder_vine", + "leaf": "unicopia:block/plunder_leaf" + }, + "elements": [ + { + "from": [7.3, 0, 7.3], + "to": [8.7, 5, 8.7], + "faces": { + "north": {"uv": [0, 6, 2, 11], "texture": "#stem"}, + "east": {"uv": [0, 6, 2, 11], "texture": "#stem"}, + "south": {"uv": [0, 6, 2, 11], "texture": "#stem"}, + "west": {"uv": [0, 6, 2, 11], "texture": "#stem"}, + "up": {"uv": [2, 2, 0, 0], "texture": "#stem"}, + "down": {"uv": [2, 0, 0, 2], "texture": "#stem"} + } + }, + { + "from": [7.3, 5, 7.3], + "to": [8.7, 13, 8.7], + "rotation": {"angle": 22.5, "axis": "z", "origin": [8, 5.5, 8]}, + "faces": { + "north": {"uv": [0, 3, 2, 11], "texture": "#stem"}, + "east": {"uv": [0, 3, 2, 11], "texture": "#stem"}, + "south": {"uv": [0, 3, 2, 11], "texture": "#stem"}, + "west": {"uv": [0, 3, 2, 11], "texture": "#stem"}, + "up": {"uv": [2, 2, 0, 0], "texture": "#stem"}, + "down": {"uv": [2, 0, 0, 2], "texture": "#stem"} + } + }, + { + "from": [7.3, 5, 7.3], + "to": [8.7, 13, 8.7], + "rotation": {"angle": -22.5, "axis": "z", "origin": [8, 5.5, 8]}, + "faces": { + "north": {"uv": [0, 3, 2, 11], "texture": "#stem"}, + "east": {"uv": [0, 3, 2, 11], "texture": "#stem"}, + "south": {"uv": [0, 3, 2, 11], "texture": "#stem"}, + "west": {"uv": [0, 3, 2, 11], "texture": "#stem"}, + "up": {"uv": [2, 2, 0, 0], "texture": "#stem"}, + "down": {"uv": [2, 0, 0, 2], "texture": "#stem"} + } + }, + { + "from": [7.3, 5, 7.3], + "to": [8.7, 13, 8.7], + "rotation": {"angle": 22.5, "axis": "x", "origin": [8, 5.5, 8]}, + "faces": { + "north": {"uv": [0, 3, 2, 11], "texture": "#stem"}, + "east": {"uv": [0, 3, 2, 11], "texture": "#stem"}, + "south": {"uv": [0, 3, 2, 11], "texture": "#stem"}, + "west": {"uv": [0, 3, 2, 11], "texture": "#stem"}, + "up": {"uv": [2, 2, 0, 0], "texture": "#stem"}, + "down": {"uv": [2, 0, 0, 2], "texture": "#stem"} + } + }, + { + "from": [7.3, 5, 7.3], + "to": [8.7, 13, 8.7], + "rotation": {"angle": -22.5, "axis": "x", "origin": [8, 5.5, 8]}, + "faces": { + "north": {"uv": [0, 3, 2, 11], "texture": "#stem"}, + "east": {"uv": [0, 3, 2, 11], "texture": "#stem"}, + "south": {"uv": [0, 3, 2, 11], "texture": "#stem"}, + "west": {"uv": [0, 3, 2, 11], "texture": "#stem"}, + "up": {"uv": [2, 2, 0, 0], "texture": "#stem"}, + "down": {"uv": [2, 0, 0, 2], "texture": "#stem"} + } + }, + { + "from": [0, 5, 8], + "to": [16, 19, 8], + "rotation": {"angle": 45, "axis": "y", "origin": [8, 11, 8]}, + "faces": { + "north": {"uv": [0, 0, 16, 16], "texture": "#leaf"}, + "south": {"uv": [0, 0, 16, 16], "texture": "#leaf"} + } + }, + { + "from": [8, -0.7, 2], + "to": [8, 10.3, 14], + "rotation": {"angle": 0, "axis": "y", "origin": [8, 11, 8]}, + "faces": { + "east": {"uv": [0, 0, 16, 16], "texture": "#leaf"}, + "west": {"uv": [0, 0, 16, 16], "texture": "#leaf"} + } + }, + { + "from": [0, 3, 8], + "to": [16, 19, 8], + "rotation": {"angle": -45, "axis": "y", "origin": [8, 11, 8]}, + "faces": { + "north": {"uv": [0, 0, 16, 16], "texture": "#leaf"}, + "south": {"uv": [0, 0, 16, 16], "texture": "#leaf"} + } + }, + { + "from": [2.3, -0.8, 8], + "to": [14.3, 13.2, 8], + "rotation": {"angle": 0, "axis": "y", "origin": [8, 11, 8]}, + "faces": { + "north": {"uv": [0, 0, 16, 16], "texture": "#leaf"}, + "south": {"uv": [0, 0, 16, 16], "texture": "#leaf"} + } + }, + { + "from": [6, 3.95, 8.1], + "to": [7, 4.95, 8.1], + "rotation": {"angle": -45, "axis": "z", "origin": [7, 4, 8]}, + "faces": { + "north": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "south": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + }, + { + "from": [6, 6.95, 8.1], + "to": [7, 7.95, 8.1], + "rotation": {"angle": -45, "axis": "z", "origin": [7, 4, 8]}, + "faces": { + "north": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "south": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + }, + { + "from": [8, 2.35, 10.1], + "to": [8, 3.35, 11.1], + "rotation": {"angle": 45, "axis": "x", "origin": [7, 4, 8]}, + "faces": { + "east": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "west": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + }, + { + "from": [8, 5.35, 4.1], + "to": [8, 6.35, 5.1], + "rotation": {"angle": 45, "axis": "x", "origin": [7, 4, 8]}, + "faces": { + "east": {"uv": [2, 0, 3, 1], "texture": "#stem"}, + "west": {"uv": [2, 0, 3, 1], "texture": "#stem"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/scallop_shell_1.json b/src/main/resources/assets/unicopia/models/block/scallop_shell_1.json new file mode 100644 index 00000000..dc24de27 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/scallop_shell_1.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/clam_shell_1", + "textures": { + "shell": "unicopia:item/scallop_shell" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/scallop_shell_2.json b/src/main/resources/assets/unicopia/models/block/scallop_shell_2.json new file mode 100644 index 00000000..31cb6d3a --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/scallop_shell_2.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/clam_shell_2", + "textures": { + "shell": "unicopia:item/scallop_shell" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/scallop_shell_3.json b/src/main/resources/assets/unicopia/models/block/scallop_shell_3.json new file mode 100644 index 00000000..e1568583 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/scallop_shell_3.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/clam_shell_3", + "textures": { + "shell": "unicopia:item/scallop_shell" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/scallop_shell_4.json b/src/main/resources/assets/unicopia/models/block/scallop_shell_4.json new file mode 100644 index 00000000..d3b086a3 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/scallop_shell_4.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/clam_shell_4", + "textures": { + "shell": "unicopia:item/scallop_shell" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/shaping_bench.json b/src/main/resources/assets/unicopia/models/block/shaping_bench.json new file mode 100644 index 00000000..55eb5b56 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/shaping_bench.json @@ -0,0 +1,130 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "3": "unicopia:block/shaping_bench_rim", + "4": "unicopia:block/shaping_bench_inside", + "side": "unicopia:block/shaping_bench_side", + "bottom": "unicopia:block/shaping_bench_bottom", + "particle": "unicopia:block/shaping_bench_top", + "top": "unicopia:block/shaping_bench_top" + }, + "elements": [ + { + "from": [0, 0, 0], + "to": [16, 4, 16], + "faces": { + "north": {"uv": [0, 12, 16, 16], "texture": "#side"}, + "east": {"uv": [0, 12, 16, 16], "texture": "#side"}, + "south": {"uv": [0, 12, 16, 16], "texture": "#side"}, + "west": {"uv": [0, 12, 16, 16], "texture": "#side"}, + "up": {"uv": [0, 0, 16, 16], "texture": "#3"}, + "down": {"uv": [0, 0, 16, 16], "texture": "#bottom"} + } + }, + { + "from": [2, 4, 2], + "to": [14, 13, 14], + "faces": { + "north": {"uv": [2, 3, 14, 12], "texture": "#side"}, + "east": {"uv": [2, 3, 14, 12], "texture": "#side"}, + "south": {"uv": [2, 3, 14, 12], "texture": "#side"}, + "west": {"uv": [2, 3, 14, 12], "texture": "#side"} + } + }, + { + "from": [2, 16, 2], + "to": [14, 17, 14], + "faces": { + "north": {"uv": [2, 2, 14, 3], "texture": "#top"}, + "east": {"uv": [2, 2, 14, 3], "texture": "#top"}, + "south": {"uv": [2, 2, 14, 3], "texture": "#top"}, + "west": {"uv": [2, 2, 14, 3], "texture": "#top"}, + "up": {"uv": [2, 2, 14, 14], "texture": "#top"} + } + }, + { + "from": [0, 13, 14], + "to": [16, 16, 16], + "faces": { + "east": {"uv": [0, 2, 2, 5], "texture": "#side"}, + "south": {"uv": [0, 2, 16, 5], "texture": "#side"}, + "west": {"uv": [14, 2, 16, 5], "texture": "#side"}, + "up": {"uv": [0, 14, 16, 16], "texture": "#top"}, + "down": {"uv": [0, 0, 16, 2], "texture": "#3"} + } + }, + { + "from": [0, 13, 0], + "to": [16, 16, 2], + "faces": { + "north": {"uv": [0, 2, 16, 5], "texture": "#side"}, + "east": {"uv": [14, 2, 16, 5], "texture": "#side"}, + "west": {"uv": [0, 2, 2, 5], "texture": "#side"}, + "up": {"uv": [0, 1, 16, 3], "texture": "#top"}, + "down": {"uv": [0, 14, 16, 16], "texture": "#3"} + } + }, + { + "from": [0, 13, 2], + "to": [2, 16, 14], + "faces": { + "west": {"uv": [2, 2, 14, 5], "texture": "#side"}, + "up": {"uv": [1, 2, 3, 14], "texture": "#top"}, + "down": {"uv": [0, 2, 2, 14], "texture": "#3"} + } + }, + { + "from": [14, 13, 2], + "to": [16, 16, 14], + "faces": { + "east": {"uv": [2, 2, 14, 5], "texture": "#side"}, + "up": {"uv": [13, 2, 15, 14], "texture": "#top"}, + "down": {"uv": [14, 2, 16, 14], "texture": "#3"} + } + }, + { + "from": [13, 16, 0], + "to": [16, 18, 3], + "faces": { + "north": {"uv": [0, 0, 3, 2], "texture": "#side"}, + "east": {"uv": [13, 0, 16, 2], "texture": "#side"}, + "south": {"uv": [2, 12, 5, 14], "texture": "#top"}, + "west": {"uv": [11, 12, 14, 14], "texture": "#top"}, + "up": {"uv": [13, 0, 16, 3], "texture": "#4"} + } + }, + { + "from": [0, 16, 0], + "to": [3, 18, 3], + "faces": { + "north": {"uv": [13, 0, 16, 2], "texture": "#side"}, + "east": {"uv": [2, 12, 5, 14], "texture": "#top"}, + "south": {"uv": [11, 12, 14, 14], "texture": "#top"}, + "west": {"uv": [0, 0, 3, 2], "texture": "#side"}, + "up": {"uv": [0, 0, 3, 3], "texture": "#4"} + } + }, + { + "from": [13, 16, 13], + "to": [16, 18, 16], + "faces": { + "north": {"uv": [11, 12, 14, 14], "texture": "#top"}, + "east": {"uv": [0, 0, 3, 2], "texture": "#side"}, + "south": {"uv": [13, 0, 16, 2], "texture": "#side"}, + "west": {"uv": [2, 12, 5, 14], "texture": "#top"}, + "up": {"uv": [13, 13, 16, 16], "texture": "#4"} + } + }, + { + "from": [0, 16, 13], + "to": [3, 18, 16], + "faces": { + "north": {"uv": [2, 12, 5, 14], "texture": "#top"}, + "east": {"uv": [11, 12, 14, 14], "texture": "#top"}, + "south": {"uv": [0, 0, 3, 2], "texture": "#side"}, + "west": {"uv": [13, 0, 16, 2], "texture": "#side"}, + "up": {"uv": [0, 13, 3, 16], "texture": "#4"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/turret_shell_1.json b/src/main/resources/assets/unicopia/models/block/turret_shell_1.json new file mode 100644 index 00000000..1357d241 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/turret_shell_1.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/clam_shell_1", + "textures": { + "shell": "unicopia:item/turret_shell" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/turret_shell_2.json b/src/main/resources/assets/unicopia/models/block/turret_shell_2.json new file mode 100644 index 00000000..3d0cdd97 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/turret_shell_2.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/clam_shell_2", + "textures": { + "shell": "unicopia:item/turret_shell" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/turret_shell_3.json b/src/main/resources/assets/unicopia/models/block/turret_shell_3.json new file mode 100644 index 00000000..90abe4d6 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/turret_shell_3.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/clam_shell_3", + "textures": { + "shell": "unicopia:item/turret_shell" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/block/turret_shell_4.json b/src/main/resources/assets/unicopia/models/block/turret_shell_4.json new file mode 100644 index 00000000..f25b45cc --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/turret_shell_4.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:block/clam_shell_4", + "textures": { + "shell": "unicopia:item/turret_shell" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/item/apple_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/apple_bed_sheets.json new file mode 100644 index 00000000..bc1ac46a --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/apple_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/apple_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/barred_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/barred_bed_sheets.json new file mode 100644 index 00000000..259f1242 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/barred_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/barred_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/black_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/black_bed_sheets.json new file mode 100644 index 00000000..bc7f7ba1 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/black_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/black_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/blue_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/blue_bed_sheets.json new file mode 100644 index 00000000..bebc30f4 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/blue_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/blue_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/brown_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/brown_bed_sheets.json new file mode 100644 index 00000000..e731713b --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/brown_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/brown_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/carved_cloud.json b/src/main/resources/assets/unicopia/models/item/carved_cloud.json new file mode 100644 index 00000000..239a7eac --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/carved_cloud.json @@ -0,0 +1,3 @@ +{ + "parent": "unicopia:block/carved_cloud" +} diff --git a/src/main/resources/assets/unicopia/models/item/checkered_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/checkered_bed_sheets.json new file mode 100644 index 00000000..caa3851c --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/checkered_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/checkered_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/clam_shell.json b/src/main/resources/assets/unicopia/models/item/clam_shell.json new file mode 100644 index 00000000..cde6769f --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/clam_shell.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/clam_shell" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/cloth_bed.json b/src/main/resources/assets/unicopia/models/item/cloth_bed.json new file mode 100644 index 00000000..5d06b91c --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/cloth_bed.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/template_bed", + "textures": { + "particle": "minecraft:item/white_wool" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/cloud_brick_slab.json b/src/main/resources/assets/unicopia/models/item/cloud_brick_slab.json new file mode 100644 index 00000000..d6177fa3 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/cloud_brick_slab.json @@ -0,0 +1,3 @@ +{ + "parent": "unicopia:block/cloud_brick_slab" +} diff --git a/src/main/resources/assets/unicopia/models/item/cloud_brick_stairs.json b/src/main/resources/assets/unicopia/models/item/cloud_brick_stairs.json new file mode 100644 index 00000000..1ad15fea --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/cloud_brick_stairs.json @@ -0,0 +1,3 @@ +{ + "parent": "unicopia:block/cloud_brick_stairs" +} diff --git a/src/main/resources/assets/unicopia/models/item/cloud_bricks.json b/src/main/resources/assets/unicopia/models/item/cloud_bricks.json new file mode 100644 index 00000000..1cc14a14 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/cloud_bricks.json @@ -0,0 +1,3 @@ +{ + "parent": "unicopia:block/cloud_bricks" +} diff --git a/src/main/resources/assets/unicopia/models/item/cloud_chest.json b/src/main/resources/assets/unicopia/models/item/cloud_chest.json new file mode 100644 index 00000000..74aedb05 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/cloud_chest.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/chest", + "textures": { + "particle": "minecraft:item/white_wool" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/cloud_door.json b/src/main/resources/assets/unicopia/models/item/cloud_door.json new file mode 100644 index 00000000..6c3e3edb --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/cloud_door.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "unicopia:item/cloud_door" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/item/cloud_lump.json b/src/main/resources/assets/unicopia/models/item/cloud_lump.json new file mode 100644 index 00000000..c8ca05f3 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/cloud_lump.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/cloud_lump" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/cloud_plank_slab.json b/src/main/resources/assets/unicopia/models/item/cloud_plank_slab.json new file mode 100644 index 00000000..4ebd9c55 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/cloud_plank_slab.json @@ -0,0 +1,3 @@ +{ + "parent": "unicopia:block/cloud_plank_slab" +} diff --git a/src/main/resources/assets/unicopia/models/item/cloud_plank_stairs.json b/src/main/resources/assets/unicopia/models/item/cloud_plank_stairs.json new file mode 100644 index 00000000..3de5b6ca --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/cloud_plank_stairs.json @@ -0,0 +1,3 @@ +{ + "parent": "unicopia:block/cloud_plank_stairs" +} diff --git a/src/main/resources/assets/unicopia/models/item/cloud_planks_slab.json b/src/main/resources/assets/unicopia/models/item/cloud_planks_slab.json deleted file mode 100644 index 4494177a..00000000 --- a/src/main/resources/assets/unicopia/models/item/cloud_planks_slab.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "unicopia:block/cloud_planks_slab" -} diff --git a/src/main/resources/assets/unicopia/models/item/cloud_planks_stairs.json b/src/main/resources/assets/unicopia/models/item/cloud_planks_stairs.json deleted file mode 100644 index b559040a..00000000 --- a/src/main/resources/assets/unicopia/models/item/cloud_planks_stairs.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "parent": "unicopia:block/cloud_planks_stairs" -} diff --git a/src/main/resources/assets/unicopia/models/item/crystal_door.json b/src/main/resources/assets/unicopia/models/item/crystal_door.json new file mode 100644 index 00000000..2ff46655 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/crystal_door.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "unicopia:item/crystal_door" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/item/cyan_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/cyan_bed_sheets.json new file mode 100644 index 00000000..21cbb8fd --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/cyan_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/cyan_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/dark_oak_stable_door.json b/src/main/resources/assets/unicopia/models/item/dark_oak_stable_door.json new file mode 100644 index 00000000..6e363cb1 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/dark_oak_stable_door.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "unicopia:item/dark_oak_stable_door" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/item/etched_cloud.json b/src/main/resources/assets/unicopia/models/item/etched_cloud.json new file mode 100644 index 00000000..3ed47a0c --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/etched_cloud.json @@ -0,0 +1,3 @@ +{ + "parent": "unicopia:block/etched_cloud" +} diff --git a/src/main/resources/assets/unicopia/models/item/etched_cloud_slab.json b/src/main/resources/assets/unicopia/models/item/etched_cloud_slab.json new file mode 100644 index 00000000..fb4023b6 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/etched_cloud_slab.json @@ -0,0 +1,3 @@ +{ + "parent": "unicopia:block/etched_cloud_slab" +} diff --git a/src/main/resources/assets/unicopia/models/item/etched_cloud_stairs.json b/src/main/resources/assets/unicopia/models/item/etched_cloud_stairs.json new file mode 100644 index 00000000..a8728434 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/etched_cloud_stairs.json @@ -0,0 +1,3 @@ +{ + "parent": "unicopia:block/etched_cloud_stairs" +} diff --git a/src/main/resources/assets/unicopia/models/item/gray_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/gray_bed_sheets.json new file mode 100644 index 00000000..d14789b7 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/gray_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/gray_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/green_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/green_bed_sheets.json new file mode 100644 index 00000000..6675e779 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/green_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/green_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/hippogriff_badge.json b/src/main/resources/assets/unicopia/models/item/hippogriff_badge.json new file mode 100644 index 00000000..c37d99ce --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/hippogriff_badge.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/hippogriff_badge" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/kelp_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/kelp_bed_sheets.json new file mode 100644 index 00000000..8234a2b0 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/kelp_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/kelp_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/light_blue_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/light_blue_bed_sheets.json new file mode 100644 index 00000000..362dbebd --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/light_blue_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/light_blue_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/light_gray_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/light_gray_bed_sheets.json new file mode 100644 index 00000000..e5aa977e --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/light_gray_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/light_gray_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/lime_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/lime_bed_sheets.json new file mode 100644 index 00000000..0b5188f0 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/lime_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/lime_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/loot_bug_spawn_egg.json b/src/main/resources/assets/unicopia/models/item/loot_bug_spawn_egg.json new file mode 100644 index 00000000..d1aaa9d6 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/loot_bug_spawn_egg.json @@ -0,0 +1,3 @@ +{ + "parent": "minecraft:item/template_spawn_egg" +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/item/magenta_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/magenta_bed_sheets.json new file mode 100644 index 00000000..3af7061c --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/magenta_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/magenta_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/orange_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/orange_bed_sheets.json new file mode 100644 index 00000000..3744c6d5 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/orange_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/orange_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/pearl_necklace.json b/src/main/resources/assets/unicopia/models/item/pearl_necklace.json new file mode 100644 index 00000000..8716891e --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/pearl_necklace.json @@ -0,0 +1,6 @@ +{ + "parent": "unicopia:item/amulet", + "textures": { + "layer0": "unicopia:item/pearl_necklace" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/pink_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/pink_bed_sheets.json new file mode 100644 index 00000000..e5a20bc3 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/pink_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/pink_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/purple_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/purple_bed_sheets.json new file mode 100644 index 00000000..19c466aa --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/purple_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/purple_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/rainbow_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/rainbow_bed_sheets.json new file mode 100644 index 00000000..2cea2b40 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/rainbow_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/rainbow_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/rainbow_bpw_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/rainbow_bpw_bed_sheets.json new file mode 100644 index 00000000..7930b725 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/rainbow_bpw_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/rainbow_bpw_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/rainbow_bpy_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/rainbow_bpy_bed_sheets.json new file mode 100644 index 00000000..50c3f6c4 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/rainbow_bpy_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/rainbow_bpy_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/rainbow_pbg_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/rainbow_pbg_bed_sheets.json new file mode 100644 index 00000000..0b4d249f --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/rainbow_pbg_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/rainbow_pbg_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/rainbow_pwr_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/rainbow_pwr_bed_sheets.json new file mode 100644 index 00000000..94dd563f --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/rainbow_pwr_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/rainbow_pwr_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/red_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/red_bed_sheets.json new file mode 100644 index 00000000..7594a935 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/red_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/red_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/scallop_shell.json b/src/main/resources/assets/unicopia/models/item/scallop_shell.json new file mode 100644 index 00000000..779ff3eb --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/scallop_shell.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/scallop_shell" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/shaping_bench.json b/src/main/resources/assets/unicopia/models/item/shaping_bench.json new file mode 100644 index 00000000..4ad37e87 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/shaping_bench.json @@ -0,0 +1,3 @@ +{ + "parent": "unicopia:block/shaping_bench" +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/item/shelly.json b/src/main/resources/assets/unicopia/models/item/shelly.json new file mode 100644 index 00000000..9d5976c3 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/shelly.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/shelly" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/stable_door.json b/src/main/resources/assets/unicopia/models/item/stable_door.json new file mode 100644 index 00000000..91dffae0 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/stable_door.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "unicopia:item/stable_door" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/item/turret_shell.json b/src/main/resources/assets/unicopia/models/item/turret_shell.json new file mode 100644 index 00000000..24bf2c41 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/turret_shell.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/turret_shell" + } +} diff --git a/src/main/resources/assets/unicopia/models/item/yellow_bed_sheets.json b/src/main/resources/assets/unicopia/models/item/yellow_bed_sheets.json new file mode 100644 index 00000000..28d94756 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/yellow_bed_sheets.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "unicopia:item/yellow_bed_sheets" + } +} diff --git a/src/main/resources/assets/unicopia/sounds.json b/src/main/resources/assets/unicopia/sounds.json index 86d150a5..f914ffea 100644 --- a/src/main/resources/assets/unicopia/sounds.json +++ b/src/main/resources/assets/unicopia/sounds.json @@ -29,6 +29,21 @@ } ] }, + "entity.player.hippogriff.screech": { + "category": "player", + "subtitle": "unicopia.subtitle.screech", + "sounds": [ + "unicopia:screech/screech1", + "unicopia:screech/screech2" + ] + }, + "entity.player.seapony.sonar": { + "category": "player", + "subtitle": "unicopia.subtitle.sonar", + "sounds": [ + "unicopia:sonar/sonar0" + ] + }, "item.magic.aura": { "category": "player", "subtitle": "unicopia.subtitle.magic_aura", diff --git a/src/main/resources/assets/unicopia/sounds/screech/screech0.ogg b/src/main/resources/assets/unicopia/sounds/screech/screech0.ogg new file mode 100644 index 00000000..1343c5e5 Binary files /dev/null and b/src/main/resources/assets/unicopia/sounds/screech/screech0.ogg differ diff --git a/src/main/resources/assets/unicopia/sounds/screech/screech1.ogg b/src/main/resources/assets/unicopia/sounds/screech/screech1.ogg new file mode 100644 index 00000000..d7d9d38b Binary files /dev/null and b/src/main/resources/assets/unicopia/sounds/screech/screech1.ogg differ diff --git a/src/main/resources/assets/unicopia/sounds/screech/screech2.ogg b/src/main/resources/assets/unicopia/sounds/screech/screech2.ogg new file mode 100644 index 00000000..b60cb9bd Binary files /dev/null and b/src/main/resources/assets/unicopia/sounds/screech/screech2.ogg differ diff --git a/src/main/resources/assets/unicopia/sounds/sonar/sonar0.ogg b/src/main/resources/assets/unicopia/sounds/sonar/sonar0.ogg new file mode 100644 index 00000000..7b61c0b3 Binary files /dev/null and b/src/main/resources/assets/unicopia/sounds/sonar/sonar0.ogg differ diff --git a/src/main/resources/assets/unicopia/textures/block/carved_cloud.png b/src/main/resources/assets/unicopia/textures/block/carved_cloud.png new file mode 100644 index 00000000..4c194433 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/carved_cloud.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/carved_cloud_bottom.png b/src/main/resources/assets/unicopia/textures/block/carved_cloud_bottom.png new file mode 100644 index 00000000..8169379d Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/carved_cloud_bottom.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/carved_cloud_top.png b/src/main/resources/assets/unicopia/textures/block/carved_cloud_top.png new file mode 100644 index 00000000..90855c4e Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/carved_cloud_top.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/cloud_bricks.png b/src/main/resources/assets/unicopia/textures/block/cloud_bricks.png new file mode 100644 index 00000000..53ff5c76 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/cloud_bricks.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/cloud_door_lower.png b/src/main/resources/assets/unicopia/textures/block/cloud_door_lower.png new file mode 100644 index 00000000..e6abc40d Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/cloud_door_lower.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/cloud_door_upper.png b/src/main/resources/assets/unicopia/textures/block/cloud_door_upper.png new file mode 100644 index 00000000..5f399b3f Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/cloud_door_upper.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/cloud_pillar_side.png b/src/main/resources/assets/unicopia/textures/block/cloud_pillar_side.png index e53aaa0e..22337da9 100644 Binary files a/src/main/resources/assets/unicopia/textures/block/cloud_pillar_side.png and b/src/main/resources/assets/unicopia/textures/block/cloud_pillar_side.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/cloud_pillar_top.png b/src/main/resources/assets/unicopia/textures/block/cloud_pillar_top.png index 2210ff1e..9a8d4e0d 100644 Binary files a/src/main/resources/assets/unicopia/textures/block/cloud_pillar_top.png and b/src/main/resources/assets/unicopia/textures/block/cloud_pillar_top.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/cloud_planks.png b/src/main/resources/assets/unicopia/textures/block/cloud_planks.png index b984504f..ea02f32c 100644 Binary files a/src/main/resources/assets/unicopia/textures/block/cloud_planks.png and b/src/main/resources/assets/unicopia/textures/block/cloud_planks.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/crystal_door_lower.png b/src/main/resources/assets/unicopia/textures/block/crystal_door_lower.png new file mode 100644 index 00000000..d249aba7 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/crystal_door_lower.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/crystal_door_upper.png b/src/main/resources/assets/unicopia/textures/block/crystal_door_upper.png new file mode 100644 index 00000000..d8aed207 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/crystal_door_upper.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/crystal_door_upper.png.mcmeta b/src/main/resources/assets/unicopia/textures/block/crystal_door_upper.png.mcmeta new file mode 100644 index 00000000..66de2f42 --- /dev/null +++ b/src/main/resources/assets/unicopia/textures/block/crystal_door_upper.png.mcmeta @@ -0,0 +1,11 @@ +{ + "animation": { + "frametime": 200, + "frames": [ + 0, 1, 2, 3, + 1, 2, 3, 0, + 2, 3, 0, 1, + 3, 0, 1, 2 + ] + } +} diff --git a/src/main/resources/assets/unicopia/textures/block/dark_oak_stable_door_lower.png b/src/main/resources/assets/unicopia/textures/block/dark_oak_stable_door_lower.png new file mode 100644 index 00000000..e044dc31 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/dark_oak_stable_door_lower.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/dark_oak_stable_door_upper.png b/src/main/resources/assets/unicopia/textures/block/dark_oak_stable_door_upper.png new file mode 100644 index 00000000..b558a995 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/dark_oak_stable_door_upper.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/etched_cloud.png b/src/main/resources/assets/unicopia/textures/block/etched_cloud.png new file mode 100644 index 00000000..0f1fe67e Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/etched_cloud.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/plunder_leaf.png b/src/main/resources/assets/unicopia/textures/block/plunder_leaf.png new file mode 100644 index 00000000..c39d84e5 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/plunder_leaf.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/plunder_vine.png b/src/main/resources/assets/unicopia/textures/block/plunder_vine.png new file mode 100644 index 00000000..bbb80a1c Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/plunder_vine.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/shaping_bench_bottom.png b/src/main/resources/assets/unicopia/textures/block/shaping_bench_bottom.png new file mode 100644 index 00000000..c7793827 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/shaping_bench_bottom.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/shaping_bench_inside.png b/src/main/resources/assets/unicopia/textures/block/shaping_bench_inside.png new file mode 100644 index 00000000..92c9b36d Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/shaping_bench_inside.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/shaping_bench_rim.png b/src/main/resources/assets/unicopia/textures/block/shaping_bench_rim.png new file mode 100644 index 00000000..0873c673 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/shaping_bench_rim.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/shaping_bench_side.png b/src/main/resources/assets/unicopia/textures/block/shaping_bench_side.png new file mode 100644 index 00000000..5ff82a57 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/shaping_bench_side.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/shaping_bench_top.png b/src/main/resources/assets/unicopia/textures/block/shaping_bench_top.png new file mode 100644 index 00000000..07c51185 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/shaping_bench_top.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/stable_door_lower.png b/src/main/resources/assets/unicopia/textures/block/stable_door_lower.png new file mode 100644 index 00000000..cf8b541b Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/stable_door_lower.png differ diff --git a/src/main/resources/assets/unicopia/textures/block/stable_door_upper.png b/src/main/resources/assets/unicopia/textures/block/stable_door_upper.png new file mode 100644 index 00000000..69ef5b6a Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/block/stable_door_upper.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/cloth.png b/src/main/resources/assets/unicopia/textures/entity/bed/cloth.png new file mode 100644 index 00000000..7f562d9e Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/cloth.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/cloud_bed/white.png b/src/main/resources/assets/unicopia/textures/entity/bed/cloud.png similarity index 100% rename from src/main/resources/assets/unicopia/textures/entity/cloud_bed/white.png rename to src/main/resources/assets/unicopia/textures/entity/bed/cloud.png diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/apple.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/apple.png new file mode 100644 index 00000000..b04c408b Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/apple.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/bars.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/bars.png new file mode 100644 index 00000000..b8a635d6 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/bars.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/black.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/black.png new file mode 100644 index 00000000..b055496d Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/black.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/blue.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/blue.png new file mode 100644 index 00000000..ed8facde Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/blue.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/brown.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/brown.png new file mode 100644 index 00000000..a00db061 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/brown.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/checker.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/checker.png new file mode 100644 index 00000000..db0a9f60 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/checker.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/cyan.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/cyan.png new file mode 100644 index 00000000..ec48566a Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/cyan.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/gray.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/gray.png new file mode 100644 index 00000000..b3777282 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/gray.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/green.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/green.png new file mode 100644 index 00000000..6fb4c944 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/green.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/kelp.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/kelp.png new file mode 100644 index 00000000..02fbc460 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/kelp.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/light_blue.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/light_blue.png new file mode 100644 index 00000000..340a7f54 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/light_blue.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/light_gray.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/light_gray.png new file mode 100644 index 00000000..34741a57 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/light_gray.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/lime.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/lime.png new file mode 100644 index 00000000..b6d78004 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/lime.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/magenta.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/magenta.png new file mode 100644 index 00000000..c5d66408 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/magenta.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/orange.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/orange.png new file mode 100644 index 00000000..9bb93f14 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/orange.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/original_cyan.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/original_cyan.png new file mode 100644 index 00000000..6b8e44e0 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/original_cyan.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/original_pink.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/original_pink.png new file mode 100644 index 00000000..073cd3e3 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/original_pink.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/original_purple.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/original_purple.png new file mode 100644 index 00000000..66e8a0f2 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/original_purple.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/original_yellow.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/original_yellow.png new file mode 100644 index 00000000..ba42e9c4 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/original_yellow.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/pink.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/pink.png new file mode 100644 index 00000000..c706cb90 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/pink.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/purple.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/purple.png new file mode 100644 index 00000000..4db0dbfe Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/purple.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/rainbow.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/rainbow.png new file mode 100644 index 00000000..33b0efba Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/rainbow.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/rainbow_bpw.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/rainbow_bpw.png new file mode 100644 index 00000000..8a846140 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/rainbow_bpw.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/rainbow_bpy.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/rainbow_bpy.png new file mode 100644 index 00000000..8c6cf39c Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/rainbow_bpy.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/rainbow_pbg.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/rainbow_pbg.png new file mode 100644 index 00000000..c0785122 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/rainbow_pbg.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/rainbow_pwr.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/rainbow_pwr.png new file mode 100644 index 00000000..69312e52 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/rainbow_pwr.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/red.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/red.png new file mode 100644 index 00000000..8f210bc9 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/red.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/bed/sheets/yellow.png b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/yellow.png new file mode 100644 index 00000000..5cdd2a85 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/bed/sheets/yellow.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/chest/cloud.png b/src/main/resources/assets/unicopia/textures/entity/chest/cloud.png new file mode 100644 index 00000000..b321284f Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/chest/cloud.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/chest/cloud_left.png b/src/main/resources/assets/unicopia/textures/entity/chest/cloud_left.png new file mode 100644 index 00000000..a240805d Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/chest/cloud_left.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/chest/cloud_right.png b/src/main/resources/assets/unicopia/textures/entity/chest/cloud_right.png new file mode 100644 index 00000000..5652a775 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/chest/cloud_right.png differ diff --git a/src/main/resources/assets/unicopia/textures/entity/loot_bug.png b/src/main/resources/assets/unicopia/textures/entity/loot_bug.png new file mode 100644 index 00000000..0c1d56ec Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/entity/loot_bug.png differ diff --git a/src/main/resources/assets/unicopia/textures/gui/ability/change_form_alicorn.png b/src/main/resources/assets/unicopia/textures/gui/ability/change_form_alicorn.png new file mode 100644 index 00000000..798eca4c Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/gui/ability/change_form_alicorn.png differ diff --git a/src/main/resources/assets/unicopia/textures/gui/ability/change_form_bat.png b/src/main/resources/assets/unicopia/textures/gui/ability/change_form_bat.png new file mode 100644 index 00000000..791a3755 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/gui/ability/change_form_bat.png differ diff --git a/src/main/resources/assets/unicopia/textures/gui/ability/change_form_changeling.png b/src/main/resources/assets/unicopia/textures/gui/ability/change_form_changeling.png new file mode 100644 index 00000000..ef67059e Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/gui/ability/change_form_changeling.png differ diff --git a/src/main/resources/assets/unicopia/textures/gui/ability/change_form_earth.png b/src/main/resources/assets/unicopia/textures/gui/ability/change_form_earth.png new file mode 100644 index 00000000..a0ef8a73 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/gui/ability/change_form_earth.png differ diff --git a/src/main/resources/assets/unicopia/textures/gui/ability/change_form_hippogriff.png b/src/main/resources/assets/unicopia/textures/gui/ability/change_form_hippogriff.png new file mode 100644 index 00000000..f0a9a694 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/gui/ability/change_form_hippogriff.png differ diff --git a/src/main/resources/assets/unicopia/textures/gui/ability/change_form_kirin.png b/src/main/resources/assets/unicopia/textures/gui/ability/change_form_kirin.png new file mode 100644 index 00000000..51cd0f73 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/gui/ability/change_form_kirin.png differ diff --git a/src/main/resources/assets/unicopia/textures/gui/ability/change_form_pegasus.png b/src/main/resources/assets/unicopia/textures/gui/ability/change_form_pegasus.png new file mode 100644 index 00000000..8a460f54 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/gui/ability/change_form_pegasus.png differ diff --git a/src/main/resources/assets/unicopia/textures/gui/ability/change_form_seapony.png b/src/main/resources/assets/unicopia/textures/gui/ability/change_form_seapony.png new file mode 100644 index 00000000..8950414d Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/gui/ability/change_form_seapony.png differ diff --git a/src/main/resources/assets/unicopia/textures/gui/ability/change_form_unicorn.png b/src/main/resources/assets/unicopia/textures/gui/ability/change_form_unicorn.png new file mode 100644 index 00000000..b212aa39 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/gui/ability/change_form_unicorn.png differ diff --git a/src/main/resources/assets/unicopia/textures/gui/ability/dash.png b/src/main/resources/assets/unicopia/textures/gui/ability/dash.png new file mode 100644 index 00000000..a2f3938a Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/gui/ability/dash.png differ diff --git a/src/main/resources/assets/unicopia/textures/gui/ability/dash_old.png b/src/main/resources/assets/unicopia/textures/gui/ability/dash_old.png new file mode 100644 index 00000000..029293fe Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/gui/ability/dash_old.png differ diff --git a/src/main/resources/assets/unicopia/textures/gui/ability/peck.png b/src/main/resources/assets/unicopia/textures/gui/ability/peck.png new file mode 100644 index 00000000..a89a7cb3 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/gui/ability/peck.png differ diff --git a/src/main/resources/assets/unicopia/textures/gui/ability/screech.png b/src/main/resources/assets/unicopia/textures/gui/ability/screech.png new file mode 100644 index 00000000..acf51ad5 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/gui/ability/screech.png differ diff --git a/src/main/resources/assets/unicopia/textures/gui/ability/sonar_pulse.png b/src/main/resources/assets/unicopia/textures/gui/ability/sonar_pulse.png new file mode 100644 index 00000000..fa9f923a Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/gui/ability/sonar_pulse.png differ diff --git a/src/main/resources/assets/unicopia/textures/gui/ability/toggle_flight_land_hippogriff.png b/src/main/resources/assets/unicopia/textures/gui/ability/toggle_flight_land_hippogriff.png new file mode 100644 index 00000000..4d981f1e Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/gui/ability/toggle_flight_land_hippogriff.png differ diff --git a/src/main/resources/assets/unicopia/textures/gui/ability/toggle_flight_takeoff_hippogriff.png b/src/main/resources/assets/unicopia/textures/gui/ability/toggle_flight_takeoff_hippogriff.png new file mode 100644 index 00000000..46068f0d Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/gui/ability/toggle_flight_takeoff_hippogriff.png differ diff --git a/src/main/resources/assets/unicopia/textures/gui/race/hippogriff.png b/src/main/resources/assets/unicopia/textures/gui/race/hippogriff.png new file mode 100644 index 00000000..057c2240 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/gui/race/hippogriff.png differ diff --git a/src/main/resources/assets/unicopia/textures/gui/tribe_selection.png b/src/main/resources/assets/unicopia/textures/gui/tribe_selection.png index 51ae0fb0..445d6dfe 100644 Binary files a/src/main/resources/assets/unicopia/textures/gui/tribe_selection.png and b/src/main/resources/assets/unicopia/textures/gui/tribe_selection.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/apple_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/apple_bed_sheets.png new file mode 100644 index 00000000..8e30e71a Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/apple_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/barred_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/barred_bed_sheets.png new file mode 100644 index 00000000..518f6c9e Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/barred_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/black_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/black_bed_sheets.png new file mode 100644 index 00000000..74361347 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/black_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/blue_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/blue_bed_sheets.png new file mode 100644 index 00000000..3c0ed9cc Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/blue_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/brown_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/brown_bed_sheets.png new file mode 100644 index 00000000..10b61d7d Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/brown_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/checkered_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/checkered_bed_sheets.png new file mode 100644 index 00000000..fd3575d9 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/checkered_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/clam_shell.png b/src/main/resources/assets/unicopia/textures/item/clam_shell.png new file mode 100644 index 00000000..f1b2e222 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/clam_shell.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/cloud_door.png b/src/main/resources/assets/unicopia/textures/item/cloud_door.png new file mode 100644 index 00000000..c7839077 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/cloud_door.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/cloud_lump.png b/src/main/resources/assets/unicopia/textures/item/cloud_lump.png new file mode 100644 index 00000000..1ee645c1 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/cloud_lump.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/crystal_door.png b/src/main/resources/assets/unicopia/textures/item/crystal_door.png new file mode 100644 index 00000000..96e93768 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/crystal_door.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/cyan_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/cyan_bed_sheets.png new file mode 100644 index 00000000..6c2d1c9e Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/cyan_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/dark_oak_stable_door.png b/src/main/resources/assets/unicopia/textures/item/dark_oak_stable_door.png new file mode 100644 index 00000000..a9bbe2ea Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/dark_oak_stable_door.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/gray_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/gray_bed_sheets.png new file mode 100644 index 00000000..5bcc7853 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/gray_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/green_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/green_bed_sheets.png new file mode 100644 index 00000000..cb6e2fe2 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/green_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/hippogriff_badge.png b/src/main/resources/assets/unicopia/textures/item/hippogriff_badge.png new file mode 100644 index 00000000..057c2240 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/hippogriff_badge.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/kelp_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/kelp_bed_sheets.png new file mode 100644 index 00000000..05670937 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/kelp_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/light_blue_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/light_blue_bed_sheets.png new file mode 100644 index 00000000..85ce04d7 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/light_blue_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/light_gray_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/light_gray_bed_sheets.png new file mode 100644 index 00000000..b0d359ee Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/light_gray_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/lime_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/lime_bed_sheets.png new file mode 100644 index 00000000..cfef75e1 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/lime_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/magenta_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/magenta_bed_sheets.png new file mode 100644 index 00000000..4c8e7161 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/magenta_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/orange_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/orange_bed_sheets.png new file mode 100644 index 00000000..2ff37969 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/orange_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/pearl_necklace.png b/src/main/resources/assets/unicopia/textures/item/pearl_necklace.png new file mode 100644 index 00000000..057c2240 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/pearl_necklace.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/pink_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/pink_bed_sheets.png new file mode 100644 index 00000000..0b10d4ad Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/pink_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/purple_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/purple_bed_sheets.png new file mode 100644 index 00000000..23f6224c Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/purple_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/rainbow_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/rainbow_bed_sheets.png new file mode 100644 index 00000000..442523e7 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/rainbow_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/rainbow_bpw_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/rainbow_bpw_bed_sheets.png new file mode 100644 index 00000000..0f361335 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/rainbow_bpw_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/rainbow_bpy_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/rainbow_bpy_bed_sheets.png new file mode 100644 index 00000000..357aabab Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/rainbow_bpy_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/rainbow_pbg_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/rainbow_pbg_bed_sheets.png new file mode 100644 index 00000000..65c3c3f6 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/rainbow_pbg_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/rainbow_pwr_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/rainbow_pwr_bed_sheets.png new file mode 100644 index 00000000..88f4a338 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/rainbow_pwr_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/red_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/red_bed_sheets.png new file mode 100644 index 00000000..000f493a Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/red_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/scallop_shell.png b/src/main/resources/assets/unicopia/textures/item/scallop_shell.png new file mode 100644 index 00000000..ed2d68f5 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/scallop_shell.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/shelly.png b/src/main/resources/assets/unicopia/textures/item/shelly.png new file mode 100644 index 00000000..784cbb1e Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/shelly.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/stable_door.png b/src/main/resources/assets/unicopia/textures/item/stable_door.png new file mode 100644 index 00000000..d3db43a8 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/stable_door.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/turret_shell.png b/src/main/resources/assets/unicopia/textures/item/turret_shell.png new file mode 100644 index 00000000..a68cdb80 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/turret_shell.png differ diff --git a/src/main/resources/assets/unicopia/textures/item/yellow_bed_sheets.png b/src/main/resources/assets/unicopia/textures/item/yellow_bed_sheets.png new file mode 100644 index 00000000..744a1fdf Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/item/yellow_bed_sheets.png differ diff --git a/src/main/resources/assets/unicopia/textures/models/armor/pearl_necklace.png b/src/main/resources/assets/unicopia/textures/models/armor/pearl_necklace.png new file mode 100644 index 00000000..5d15b0f7 Binary files /dev/null and b/src/main/resources/assets/unicopia/textures/models/armor/pearl_necklace.png differ diff --git a/src/main/resources/data/c/tags/items/coral_blocks.json b/src/main/resources/data/c/tags/items/coral_blocks.json new file mode 100644 index 00000000..e907eedc --- /dev/null +++ b/src/main/resources/data/c/tags/items/coral_blocks.json @@ -0,0 +1,10 @@ +{ + "replace": false, + "values": [ + "minecraft:tube_coral_block", + "minecraft:brain_coral_block", + "minecraft:bubble_coral_block", + "minecraft:fire_coral_block", + "minecraft:horn_coral_block" + ] +} diff --git a/src/main/resources/data/c/tags/items/coral_fans.json b/src/main/resources/data/c/tags/items/coral_fans.json new file mode 100644 index 00000000..531d24c9 --- /dev/null +++ b/src/main/resources/data/c/tags/items/coral_fans.json @@ -0,0 +1,10 @@ +{ + "replace": false, + "values": [ + "minecraft:tube_coral_fan", + "minecraft:brain_coral_fan", + "minecraft:bubble_coral_fan", + "minecraft:fire_coral_fan", + "minecraft:horn_coral_fan" + ] +} diff --git a/src/main/resources/data/c/tags/items/corals.json b/src/main/resources/data/c/tags/items/corals.json new file mode 100644 index 00000000..cec1b08e --- /dev/null +++ b/src/main/resources/data/c/tags/items/corals.json @@ -0,0 +1,10 @@ +{ + "replace": false, + "values": [ + "minecraft:tube_coral", + "minecraft:brain_coral", + "minecraft:bubble_coral", + "minecraft:fire_coral", + "minecraft:horn_coral" + ] +} diff --git a/src/main/resources/data/c/tags/items/fruit.json b/src/main/resources/data/c/tags/items/fruit.json deleted file mode 100644 index 6cd22ee2..00000000 --- a/src/main/resources/data/c/tags/items/fruit.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "replace": false, - "values": [ - "unicopia:mango", - "unicopia:banana", - "unicopia:pineapple" - ] -} diff --git a/src/main/resources/data/minecraft/tags/blocks/mineable/axe.json b/src/main/resources/data/minecraft/tags/blocks/mineable/axe.json index 92d7bbc8..b8bbd23c 100644 --- a/src/main/resources/data/minecraft/tags/blocks/mineable/axe.json +++ b/src/main/resources/data/minecraft/tags/blocks/mineable/axe.json @@ -2,7 +2,8 @@ "replace": false, "values": [ "unicopia:cloud_planks", - "unicopia:cloud_planks_slab", - "unicopia:cloud_planks_stairs" + "unicopia:cloud_plank_slab", + "unicopia:cloud_plank_stairs", + "unicopia:compacted_cloud_planks" ] } diff --git a/src/main/resources/data/minecraft/tags/blocks/mineable/pickaxe.json b/src/main/resources/data/minecraft/tags/blocks/mineable/pickaxe.json index 4716ddcc..46d67b80 100644 --- a/src/main/resources/data/minecraft/tags/blocks/mineable/pickaxe.json +++ b/src/main/resources/data/minecraft/tags/blocks/mineable/pickaxe.json @@ -8,6 +8,11 @@ "unicopia:chiselled_chitin", "unicopia:chiselled_chitin_slab", "unicopia:chiselled_chitin_stairs", - "unicopia:chiselled_chitin_hull" + "unicopia:chiselled_chitin_hull", + "unicopia:cloud_bricks", + "unicopia:cloud_brick_slab", + "unicopia:cloud_brick_stairs", + "unicopia:compacted_cloud_bricks", + "unicopia:carved_cloud" ] } diff --git a/src/main/resources/data/minecraft/tags/items/beds.json b/src/main/resources/data/minecraft/tags/items/beds.json new file mode 100644 index 00000000..0ec4b6cd --- /dev/null +++ b/src/main/resources/data/minecraft/tags/items/beds.json @@ -0,0 +1,7 @@ +{ + "replace": false, + "values": [ + "#unicopia:cloud_beds", + "unicopia:cloth_bed" + ] +} diff --git a/src/main/resources/data/minecraft/traits/items/overworld/refined_rocks_and_rock_derived.json b/src/main/resources/data/minecraft/traits/items/overworld/refined_rocks_and_rock_derived.json index 38704cac..7a3c23ed 100644 --- a/src/main/resources/data/minecraft/traits/items/overworld/refined_rocks_and_rock_derived.json +++ b/src/main/resources/data/minecraft/traits/items/overworld/refined_rocks_and_rock_derived.json @@ -6,7 +6,7 @@ "minecraft:quartz": "earth:-1.3 strength:-1 darkness:1", "minecraft:amethyst_shard": "earth:-0.1 order:9", - "minecraft:lapis_lazuli": "order:2 power:4 order:5", + "minecraft:lapis_lazuli": "power:4 order:5", "minecraft:raw_iron": "focus:2 earth:-0.7 strength:4", "minecraft:raw_copper": "focus:1.5 earth:-0.7 strength:4", diff --git a/src/main/resources/data/trinkets/tags/items/chest/necklace.json b/src/main/resources/data/trinkets/tags/items/chest/necklace.json index 675082d4..6b3f0e07 100644 --- a/src/main/resources/data/trinkets/tags/items/chest/necklace.json +++ b/src/main/resources/data/trinkets/tags/items/chest/necklace.json @@ -3,6 +3,7 @@ "values": [ "unicopia:alicorn_amulet", "unicopia:pegasus_amulet", - "unicopia:unicorn_amulet" + "unicopia:unicorn_amulet", + "unicopia:pearl_necklace" ] } \ No newline at end of file diff --git a/src/main/resources/data/unicopia/advancements/recipes/blocks/cloud_brick_slab.json b/src/main/resources/data/unicopia/advancements/recipes/blocks/cloud_brick_slab.json new file mode 100644 index 00000000..88c40580 --- /dev/null +++ b/src/main/resources/data/unicopia/advancements/recipes/blocks/cloud_brick_slab.json @@ -0,0 +1,30 @@ +{ + "parent": "minecraft:recipes/root", + "rewards": { + "recipes": [ + "unicopia:blocks/cloud_brick_slab" + ] + }, + "criteria": { + "has_ingredients": { + "trigger": "minecraft:inventory_changed", + "conditions": { + "items": [ + { "item": "unicopia:cloud_bricks" } + ] + } + }, + "has_the_recipe": { + "trigger": "minecraft:recipe_unlocked", + "conditions": { + "recipe": "unicopia:blocks/cloud_brick_slab" + } + } + }, + "requirements": [ + [ + "has_ingredients", + "has_the_recipe" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/advancements/recipes/blocks/cloud_brick_stairs.json b/src/main/resources/data/unicopia/advancements/recipes/blocks/cloud_brick_stairs.json new file mode 100644 index 00000000..25aed1f6 --- /dev/null +++ b/src/main/resources/data/unicopia/advancements/recipes/blocks/cloud_brick_stairs.json @@ -0,0 +1,30 @@ +{ + "parent": "minecraft:recipes/root", + "rewards": { + "recipes": [ + "unicopia:blocks/cloud_brick_stairs" + ] + }, + "criteria": { + "has_ingredients": { + "trigger": "minecraft:inventory_changed", + "conditions": { + "items": [ + { "item": "unicopia:cloud_bricks" } + ] + } + }, + "has_the_recipe": { + "trigger": "minecraft:recipe_unlocked", + "conditions": { + "recipe": "unicopia:blocks/cloud_brick_stairs" + } + } + }, + "requirements": [ + [ + "has_ingredients", + "has_the_recipe" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/advancements/recipes/cloud_lump.json b/src/main/resources/data/unicopia/advancements/recipes/cloud_lump.json new file mode 100644 index 00000000..39ec6b06 --- /dev/null +++ b/src/main/resources/data/unicopia/advancements/recipes/cloud_lump.json @@ -0,0 +1,30 @@ +{ + "parent": "minecraft:recipes/root", + "rewards": { + "recipes": [ + "unicopia:cloud_lump" + ] + }, + "criteria": { + "has_ingredients": { + "trigger": "minecraft:inventory_changed", + "conditions": { + "items": [ + { "tag": "unicopia:cloud_jars" } + ] + } + }, + "has_the_recipe": { + "trigger": "minecraft:recipe_unlocked", + "conditions": { + "recipe": "unicopia:cloud_lump" + } + } + }, + "requirements": [ + [ + "has_ingredients", + "has_the_recipe" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/advancements/recipes/shelly.json b/src/main/resources/data/unicopia/advancements/recipes/shelly.json new file mode 100644 index 00000000..08119d10 --- /dev/null +++ b/src/main/resources/data/unicopia/advancements/recipes/shelly.json @@ -0,0 +1,30 @@ +{ + "parent": "minecraft:recipes/root", + "rewards": { + "recipes": [ + "unicopia:shelly" + ] + }, + "criteria": { + "has_ingredients": { + "trigger": "minecraft:inventory_changed", + "conditions": { + "items": [ + { "items": [ "unicopia:clam_shell", "unicopia:rock_candy" ] } + ] + } + }, + "has_the_recipe": { + "trigger": "minecraft:recipe_unlocked", + "conditions": { + "recipe": "unicopia:shelly" + } + } + }, + "requirements": [ + [ + "has_ingredients", + "has_the_recipe" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/advancements/unicopia/unicorn/a_falling_wizard.json b/src/main/resources/data/unicopia/advancements/unicopia/unicorn/a_falling_wizard.json new file mode 100644 index 00000000..bb6eada4 --- /dev/null +++ b/src/main/resources/data/unicopia/advancements/unicopia/unicorn/a_falling_wizard.json @@ -0,0 +1,29 @@ +{ + "parent": "unicopia:unicopia/unicorn/magical_route", + "display": { + "icon": { + "item": "unicopia:pegasus_amulet" + }, + "title": { + "translate": "advancements.unicopia.a_falling_wizard.title" + }, + "description": { + "translate": "advancements.unicopia.a_falling_wizard.description" + }, + "frame": "challenge", + "show_toast": true, + "announce_to_chat": true, + "hidden": true + }, + "criteria": { + "teleport_above_world": { + "trigger": "unicopia:custom", + "conditions": { + "event": "teleport_above_world" + } + } + }, + "requirements": [ + [ "teleport_above_world" ] + ] +} diff --git a/src/main/resources/data/unicopia/diets/food_effects/fish/cooked.json b/src/main/resources/data/unicopia/diets/food_effects/fish/cooked.json new file mode 100644 index 00000000..423e578f --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/fish/cooked.json @@ -0,0 +1,16 @@ +{ + "tags": [ "unicopia:food_types/cooked_fish" ], + "food_component": { + "hunger": 1, + "saturation": 0.1 + }, + "ailment": { + "effects": [ + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2 + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/fish/raw.json b/src/main/resources/data/unicopia/diets/food_effects/fish/raw.json new file mode 100644 index 00000000..40368a26 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/fish/raw.json @@ -0,0 +1,22 @@ +{ + "tags": [ "unicopia:food_types/raw_fish" ], + "food_component": { + "hunger": 1, + "saturation": 0.1 + }, + "ailment": { + "effects": [ + { + "effect": "minecraft:poison", + "seconds": 45, + "amplifier": 2, + "chance": 80 + }, + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2 + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/fish/rotten.json b/src/main/resources/data/unicopia/diets/food_effects/fish/rotten.json new file mode 100644 index 00000000..4259828b --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/fish/rotten.json @@ -0,0 +1,23 @@ +{ + "tags": [ "unicopia:food_types/rotten_fish" ], + "food_component": { + "hunger": 1, + "saturation": 0.1 + }, + "ailment": { + "effects": [ + { + "effect": "minecraft:poison", + "seconds": 45, + "amplifier": 2, + "chance": 80 + }, + { + "effect": "unicopia:food_poisoning", + "seconds": 400, + "amplifier": 3, + "chance": 5 + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/foraging/blinding.json b/src/main/resources/data/unicopia/diets/food_effects/foraging/blinding.json new file mode 100644 index 00000000..ca392e74 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/foraging/blinding.json @@ -0,0 +1,21 @@ +{ + "tags": [ "unicopia:food_types/forage_blinding" ], + "food_component": { + "hunger": 2, + "saturation": 1 + }, + "ailment": { + "effects": [ + { + "effect": "minecraft:blindness", + "seconds": 30, + "amplifier": 0 + }, + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2 + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/foraging/dangerous.json b/src/main/resources/data/unicopia/diets/food_effects/foraging/dangerous.json new file mode 100644 index 00000000..372abede --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/foraging/dangerous.json @@ -0,0 +1,17 @@ +{ + "tags": [ "unicopia:food_types/forage_dangerous" ], + "food_component": { + "hunger": 2, + "saturation": 1 + }, + "ailment": { + "effects": [ + { + "effect": "unicopia:food_poisoning", + "seconds": 250, + "amplifier": 2, + "chance": 4 + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/foraging/edible.json b/src/main/resources/data/unicopia/diets/food_effects/foraging/edible.json new file mode 100644 index 00000000..33887410 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/foraging/edible.json @@ -0,0 +1,10 @@ +{ + "tags": [ "unicopia:food_types/forage_edible" ], + "food_component": { + "hunger": 2, + "saturation": 1 + }, + "ailment": { + "effects": [] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/foraging/edible_filling.json b/src/main/resources/data/unicopia/diets/food_effects/foraging/edible_filling.json new file mode 100644 index 00000000..b6721b3f --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/foraging/edible_filling.json @@ -0,0 +1,10 @@ +{ + "tags": [ "unicopia:food_types/forage_edible_filling" ], + "food_component": { + "hunger": 18, + "saturation": 9 + }, + "ailment": { + "effects": [] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/foraging/moderate.json b/src/main/resources/data/unicopia/diets/food_effects/foraging/moderate.json new file mode 100644 index 00000000..4d7a238a --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/foraging/moderate.json @@ -0,0 +1,17 @@ +{ + "tags": [ "unicopia:food_types/forage_moderate" ], + "food_component": { + "hunger": 2, + "saturation": 1 + }, + "ailment": { + "effects": [ + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2, + "chance": 40 + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/foraging/nauseating.json b/src/main/resources/data/unicopia/diets/food_effects/foraging/nauseating.json new file mode 100644 index 00000000..e79628a0 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/foraging/nauseating.json @@ -0,0 +1,22 @@ +{ + "tags": [ "unicopia:food_types/forage_nauseating" ], + "food_component": { + "hunger": 2, + "saturation": 1 + }, + "ailment": { + "effects": [ + { + "effect": "minecraft:weakness", + "seconds": 200, + "amplifier": 1, + "chance": 30 + }, + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2 + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/foraging/prickly.json b/src/main/resources/data/unicopia/diets/food_effects/foraging/prickly.json new file mode 100644 index 00000000..d3c61180 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/foraging/prickly.json @@ -0,0 +1,17 @@ +{ + "tags": [ "unicopia:food_types/forage_prickly" ], + "food_component": { + "hunger": 2, + "saturation": 1 + }, + "ailment": { + "effects": [ + { + "effect": "minecraft:instant_damage", + "seconds": 1, + "amplifier": 0, + "chance": 30 + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/foraging/radioactive.json b/src/main/resources/data/unicopia/diets/food_effects/foraging/radioactive.json new file mode 100644 index 00000000..7a023788 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/foraging/radioactive.json @@ -0,0 +1,22 @@ +{ + "tags": [ "unicopia:food_types/forage_radioactive" ], + "food_component": { + "hunger": 2, + "saturation": 1 + }, + "ailment": { + "effects": [ + { + "effect": "minecraft:glowing", + "seconds": 15, + "amplifier": 0, + "chance": 30 + }, + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2 + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/foraging/risky.json b/src/main/resources/data/unicopia/diets/food_effects/foraging/risky.json new file mode 100644 index 00000000..9ee5d1dc --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/foraging/risky.json @@ -0,0 +1,17 @@ +{ + "tags": [ "unicopia:food_types/forage_risky" ], + "food_component": { + "hunger": 2, + "saturation": 1 + }, + "ailment": { + "effects": [ + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2, + "chance": 80 + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/foraging/severely_nauseating.json b/src/main/resources/data/unicopia/diets/food_effects/foraging/severely_nauseating.json new file mode 100644 index 00000000..7f4ef36e --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/foraging/severely_nauseating.json @@ -0,0 +1,21 @@ +{ + "tags": [ "unicopia:food_types/forage_severely_nauseating" ], + "food_component": { + "hunger": 2, + "saturation": 1 + }, + "ailment": { + "effects": [ + { + "effect": "minecraft:weakness", + "seconds": 200, + "amplifier": 1 + }, + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2 + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/foraging/severely_prickly.json b/src/main/resources/data/unicopia/diets/food_effects/foraging/severely_prickly.json new file mode 100644 index 00000000..3b5a1cd6 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/foraging/severely_prickly.json @@ -0,0 +1,21 @@ +{ + "tags": [ "unicopia:food_types/forage_severely_prickly" ], + "food_component": { + "hunger": 2, + "saturation": 1 + }, + "ailment": { + "effects": [ + { + "effect": "minecraft:instant_damage", + "seconds": 1, + "amplifier": 0 + }, + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2 + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/foraging/strengthening.json b/src/main/resources/data/unicopia/diets/food_effects/foraging/strengthening.json new file mode 100644 index 00000000..11477833 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/foraging/strengthening.json @@ -0,0 +1,22 @@ +{ + "tags": [ "unicopia:food_types/forage_strengthening" ], + "food_component": { + "hunger": 2, + "saturation": 1 + }, + "ailment": { + "effects": [ + { + "effect": "minecraft:strength", + "seconds": 30, + "amplifier": 0 + }, + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2, + "chance": 10 + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/insect/cooked.json b/src/main/resources/data/unicopia/diets/food_effects/insect/cooked.json new file mode 100644 index 00000000..9dbdc566 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/insect/cooked.json @@ -0,0 +1,16 @@ +{ + "tags": [ "unicopia:food_types/cooked_insect" ], + "food_component": { + "hunger": 1, + "saturation": 0.1 + }, + "ailment": { + "effects": [ + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2 + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/insect/raw.json b/src/main/resources/data/unicopia/diets/food_effects/insect/raw.json new file mode 100644 index 00000000..8683f240 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/insect/raw.json @@ -0,0 +1,16 @@ +{ + "tags": [ "unicopia:food_types/raw_insect" ], + "food_component": { + "hunger": 1, + "saturation": 0.1 + }, + "ailment": { + "effects": [ + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2 + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/meat/cooked.json b/src/main/resources/data/unicopia/diets/food_effects/meat/cooked.json new file mode 100644 index 00000000..80b1e542 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/meat/cooked.json @@ -0,0 +1,16 @@ +{ + "tags": [ "unicopia:food_types/cooked_meat" ], + "food_component": { + "hunger": 12, + "saturation": 1.2 + }, + "ailment": { + "effects": [ + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2 + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/meat/raw.json b/src/main/resources/data/unicopia/diets/food_effects/meat/raw.json new file mode 100644 index 00000000..f2c547d9 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/meat/raw.json @@ -0,0 +1,23 @@ +{ + "tags": [ "unicopia:food_types/raw_meat" ], + "food_component": { + "hunger": 1, + "saturation": 1 + }, + "ailment": { + "effects": [ + { + "effect": "minecraft:poison", + "seconds": 45, + "amplifier": 2, + "chance": 80 + }, + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2, + "chance": 5 + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/meat/rotten.json b/src/main/resources/data/unicopia/diets/food_effects/meat/rotten.json new file mode 100644 index 00000000..72faee0e --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/meat/rotten.json @@ -0,0 +1,23 @@ +{ + "tags": [ "unicopia:food_types/rotten_meat" ], + "food_component": { + "hunger": 1, + "saturation": 1 + }, + "ailment": { + "effects": [ + { + "effect": "minecraft:poison", + "seconds": 45, + "amplifier": 2, + "chance": 80 + }, + { + "effect": "unicopia:food_poisoning", + "seconds": 400, + "amplifier": 3, + "chance": 5 + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/pinecone.json b/src/main/resources/data/unicopia/diets/food_effects/pinecone.json new file mode 100644 index 00000000..75f92718 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/pinecone.json @@ -0,0 +1,15 @@ +{ + "tags": [ "unicopia:food_types/pinecone" ], + "food_component": { + "hunger": 1, + "saturation": 0.1 + }, + "ailment": { + "effects": [ + { + "type": "unicopia:healing", + "health": 1 + } + ] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/food_effects/rocks.json b/src/main/resources/data/unicopia/diets/food_effects/rocks.json new file mode 100644 index 00000000..ebe7b986 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/food_effects/rocks.json @@ -0,0 +1,10 @@ +{ + "tags": [ "unicopia:food_types/rocks" ], + "food_component": { + "hunger": 1, + "saturation": 0.1 + }, + "ailment": { + "effects": [] + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/diets/races/alicorn.json b/src/main/resources/data/unicopia/diets/races/alicorn.json new file mode 100644 index 00000000..d318454c --- /dev/null +++ b/src/main/resources/data/unicopia/diets/races/alicorn.json @@ -0,0 +1,57 @@ +{ + "default_multiplier": 0.8, + "foraging_multiplier": 1, + "multipliers": [ + { + "tags": [ "unicopia:food_types/cooked_fish" ], + "hunger": 1.5, + "saturation": 1.5 + }, + { + "tags": [ "unicopia:food_types/raw_fish" ], + "hunger": 0.5, + "saturation": 0.6 + }, + { + "tags": [ + "unicopia:food_types/cooked_insect", + "unicopia:food_types/cooked_meat" + ], + "hunger": 0.1, + "saturation": 0.1 + }, + { + "tags": [ + "unicopia:food_types/love", + "unicopia:food_types/raw_insect", + "unicopia:food_types/raw_meat", + "unicopia:food_types/rotten_meat" + ], + "hunger": 0, + "saturation": 0 + }, + { + "tags": [ "unicopia:food_types/pinecone" ], + "hunger": 0.9, + "saturation": 0.9 + } + ], + "effects": [ + { + "tags": [ "unicopia:food_types/cooked_fish" ], + "food_component": { + "hunger": 2, + "saturation": 1 + }, + "ailment": { + "effects": [ ] + } + }, + { + "tags": [ "unicopia:food_types/raw_fish" ], + "ailment": { + "effects": [ ] + } + } + ] +} diff --git a/src/main/resources/data/unicopia/diets/races/bat.json b/src/main/resources/data/unicopia/diets/races/bat.json new file mode 100644 index 00000000..2aedf250 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/races/bat.json @@ -0,0 +1,130 @@ +{ + "default_multiplier": 0.5, + "foraging_multiplier": 0.9, + "multipliers": [ + { + "tags": [ "unicopia:food_types/cooked_fish" ], + "hunger": 0.75, + "saturation": 0.75 + }, + { + "tags": [ "unicopia:food_types/raw_fish" ], + "hunger": 0.5, + "saturation": 0.6 + }, + { + "tags": [ "unicopia:food_types/cooked_insect" ], + "hunger": 1.75, + "saturation": 1.75 + }, + { + "tags": [ "unicopia:food_types/cooked_meat" ], + "hunger": 1.15, + "saturation": 1.15 + }, + { + "tags": [ "unicopia:food_types/raw_insect" ], + "hunger": 1, + "saturation": 1 + }, + { + "tags": [ "unicopia:food_types/raw_meat" ], + "hunger": 0.25, + "saturation": 0.25 + }, + { + "tags": [ "unicopia:food_types/rotten_meat" ], + "hunger": 0.2, + "saturation": 0.2 + }, + { + "tags": [ "unicopia:food_types/love" ], + "hunger": 0, + "saturation": 0 + }, + { + "tags": [ "unicopia:food_types/pinecone" ], + "hunger": 0.9, + "saturation": 0.9 + } + ], + "effects": [ + { + "tags": [ "unicopia:food_types/rotten_fish" ], + "ailment": { + "effects": [ + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2, + "chance": 5 + } + ] + } + }, + { + "tags": [ + "unicopia:food_types/cooked_insect", + "unicopia:food_types/cooked_meat" + ], + "ailment": { + "effects": [ ] + } + }, + { + "tags": [ "unicopia:food_types/raw_insect" ], + "ailment": { + "effects": [ + { + "effect": "unicopia:food_poisoning", + "seconds": 50, + "amplifier": 1 + } + ] + } + }, + { + "tags": [ + "unicopia:food_types/raw_meat", + "unicopia:food_types/rotten_meat" + ], + "ailment": { + "effects": [ + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2, + "chance": 5 + } + ] + } + }, + { + "tags": [ "unicopia:food_types/bat_ponys_delight" ], + "ailment": { + "effects": [ + { + "effect": "minecraft:health_boost", + "seconds": { "min": 30, "max": 60 }, + "amplifier": { "min": 2, "max": 6 } + }, + { + "effect": "minecraft:jump_boost", + "seconds": { "min": 30, "max": 60 }, + "amplifier": { "min": 1, "max": 6 } + }, + { + "effect": "minecraft:health_boost", + "seconds": 30, + "amplifier": { "min": 1, "max": 6 } + }, + { + "effect": "minecraft:regeneration", + "seconds": { "min": 3, "max": 30 }, + "amplifier": { "min": 3, "max": 6 } + } + ] + } + } + ] +} diff --git a/src/main/resources/data/unicopia/diets/races/changeling.json b/src/main/resources/data/unicopia/diets/races/changeling.json new file mode 100644 index 00000000..e6255344 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/races/changeling.json @@ -0,0 +1,132 @@ +{ + "default_multiplier": 0.15, + "foraging_multiplier": 0, + "multipliers": [ + { + "tags": [ "unicopia:food_types/cooked_insect" ], + "hunger": 0.3, + "saturation": 0.3 + }, + { + "tags": [ "unicopia:food_types/cooked_meat" ], + "hunger": 0.1, + "saturation": 0.1 + }, + { + "tags": [ "unicopia:food_types/raw_insect" ], + "hunger": 1, + "saturation": 1 + }, + { + "tags": [ "unicopia:food_types/raw_meat" ], + "hunger": 0.25, + "saturation": 0.25 + }, + { + "tags": [ "unicopia:food_types/rotten_meat" ], + "hunger": 0.6, + "saturation": 0.6 + }, + { + "tags": [ "unicopia:food_types/love" ], + "hunger": 1, + "saturation": 1 + } + ], + "default_effects": { + "effects": [ + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2 + }, + { + "effect": "minecraft:weakness", + "seconds": 200, + "amplifier": 1 + }, + { + "type": "unicopia:multiply_hunger", + "multiplier": 0.5 + } + ] + }, + "effects": [ + { + "tags": [ "unicopia:food_types/love" ], + "food_component": { + "hunger": 2, + "saturation": 1 + }, + "ailment": { + "effects": [ + { + "name": "Love Consumption", + "type": "unicopia:clear_love_sickness" + } + ] + } + }, + { + "tags": [ + "unicopia:food_types/cooked_fish", + "unicopia:food_types/raw_fish" + ], + "ailment": { + "effects": [ + { + "effect": "unicopia:food_poisoning", + "seconds": 50, + "amplifier": 2 + }, + { + "name": "unicopia.affliction.love_sickness", + "type": "unicopia:multiply_hunger", + "multiplier": 0.5 + } + ] + } + }, + { + "tags": [ + "unicopia:food_types/rotten_fish", + "unicopia:food_types/cooked_insect", + "unicopia:food_types/raw_insect", + "unicopia:food_types/cooked_meat", + "unicopia:food_types/raw_meat", + "unicopia:food_types/rotten_meat" + ], + "ailment": { + "effects": [ ] + } + }, + { + "tags": [ + "unicopia:food_types/forage_edible", + "unicopia:food_types/forage_edible_filling" + ], + "food_component": { + "hunger": 18, + "saturation": 9 + }, + "ailment": { + "effects": [ + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2 + }, + { + "effect": "minecraft:weakness", + "seconds": 200, + "amplifier": 1 + }, + { + "type": "unicopia:multiply_hunger", + "multiplier": 0.5 + } + ] + } + } + ] +} diff --git a/src/main/resources/data/unicopia/diets/races/earth.json b/src/main/resources/data/unicopia/diets/races/earth.json new file mode 100644 index 00000000..a8b48e87 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/races/earth.json @@ -0,0 +1,74 @@ +{ + "default_multiplier": 1, + "foraging_multiplier": 1, + "multipliers": [ + { + "tags": [ + "unicopia:food_types/candy", + "unicopia:food_types/desserts", + "unicopia:food_types/rocks" + ], + "hunger": 2.5, + "saturation": 1.7 + }, + { + "tags": [ "unicopia:food_types/cooked_fish" ], + "hunger": 0.2, + "saturation": 0.2 + }, + { + "tags": [ + "unicopia:food_types/cooked_insect", + "unicopia:food_types/cooked_meat" + ], + "hunger": 0.1, + "saturation": 0.1 + }, + { + "tags": [ + "unicopia:food_types/love", + "unicopia:food_types/raw_fish", + "unicopia:food_types/raw_insect", + "unicopia:food_types/raw_meat", + "unicopia:food_types/rotten_meat" + ], + "hunger": 0, + "saturation": 0 + }, + { + "tags": [ "unicopia:food_types/pinecone" ], + "hunger": 1, + "saturation": 1 + } + ], + "effects": [ + { + "tags": [ + "unicopia:food_types/candy", + "unicopia:food_types/rocks" + ], + "food_component": { + "hunger": 5, + "saturation": 12, + "fastFood": true + }, + "ailment": { + "effects": [ ] + } + }, + { + "tags": [ + "unicopia:food_types/desserts" + ], + "food_component": { + "hunger": 12, + "saturation": 32, + "eatenQuickly": true, + "fastFood": true + }, + "ailment": { + "effects": [ ] + } + } + ] +} diff --git a/src/main/resources/data/unicopia/diets/races/hippogriff.json b/src/main/resources/data/unicopia/diets/races/hippogriff.json new file mode 100644 index 00000000..8ecea1ad --- /dev/null +++ b/src/main/resources/data/unicopia/diets/races/hippogriff.json @@ -0,0 +1,83 @@ +{ + "default_multiplier": 0.3, + "foraging_multiplier": 0.8, + "multipliers": [ + { + "tags": [ + "unicopia:food_types/cooked_meat", + "unicopia:food_types/cooked_fish" + ], + "hunger": 1.6, + "saturation": 1.6 + }, + { + "tags": [ + "unicopia:food_types/raw_meat", + "unicopia:food_types/raw_fish" + ], + "hunger": 0.6, + "saturation": 0.6 + }, + { + "tags": [ "unicopia:food_types/rotten_meat" ], + "hunger": 0.3, + "saturation": 0.3 + }, + { + "tags": [ + "unicopia:food_types/love", + "unicopia:food_types/raw_insect", + "unicopia:food_types/cooked_insect" + ], + "hunger": 0, + "saturation": 0 + }, + { + "tags": [ "unicopia:food_types/pinecone" ], + "hunger": 1, + "saturation": 1 + } + ], + "effects": [ + { + "tags": [ "unicopia:food_types/cooked_fish" ], + "food_component": { + "hunger": 2, + "saturation": 1 + }, + "ailment": { + "effects": [ ] + } + }, + { + "tags": [ "unicopia:food_types/raw_fish" ], + "ailment": { + "effects": [ ] + } + }, + { + "tags": [ + "unicopia:food_types/forage_prickly", + "unicopia:food_types/forage_severely_prickly" + ], + "food_component": { + "hunger": 2, + "saturation": 1 + }, + "ailment": { + "effects": [ ] + } + }, + { + "tags": [ "unicopia:food_types/pinecone" ], + "ailment": { + "effects": [ + { + "type": "unicopia:healing", + "health": 3 + } + ] + } + } + ] +} diff --git a/src/main/resources/data/unicopia/diets/races/human.json b/src/main/resources/data/unicopia/diets/races/human.json new file mode 100644 index 00000000..ddf024b3 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/races/human.json @@ -0,0 +1,21 @@ +{ + "default_multiplier": 1, + "foraging_multiplier": 0, + "multipliers": [ ], + "effects": [ + { + "tags": [ + "unicopia:food_types/cooked_fish", + "unicopia:food_types/raw_fish", + "unicopia:food_types/rotten_fish", + "unicopia:food_types/cooked_meat", + "unicopia:food_types/raw_meat", + "unicopia:food_types/rotten_meat", + "unicopia:food_types/pinecone" + ], + "ailment": { + "effects": [ ] + } + } + ] +} diff --git a/src/main/resources/data/unicopia/diets/races/kirin.json b/src/main/resources/data/unicopia/diets/races/kirin.json new file mode 100644 index 00000000..2f2f4172 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/races/kirin.json @@ -0,0 +1,61 @@ +{ + "default_multiplier": 0, + "foraging_multiplier": 0.9, + "multipliers": [ + { + "tags": [ "unicopia:food_types/cooked_meat" ], + "hunger": 1.5, + "saturation": 1.5 + }, + { + "tags": [ "unicopia:food_types/raw_meat" ], + "hunger": 0.5, + "saturation": 0.6 + }, + { + "tags": [ + "unicopia:food_types/cooked_insect", + "unicopia:food_types/cooked_fish" + ], + "hunger": 0.1, + "saturation": 0.1 + }, + { + "tags": [ + "unicopia:food_types/love", + "unicopia:food_types/raw_insect", + "unicopia:food_types/raw_fish", + "unicopia:food_types/rotten_meat" + ], + "hunger": 0, + "saturation": 0 + }, + { + "tags": [ "unicopia:food_types/pinecone" ], + "hunger": 0.9, + "saturation": 0.9 + } + ], + "effects": [ + { + "tags": [ + "unicopia:food_types/rotten_fish", + "unicopia:food_types/cooked_insect", + "unicopia:food_types/cooked_meat", + "unicopia:food_types/raw_meat", + "unicopia:food_types/rotten_meat", + "unicopia:food_types/forage_blinding", + "unicopia:food_types/forage_prickly", + "unicopia:food_types/forage_severely_prickly", + "unicopia:food_types/forage_strengthening" + ], + "food_component": { + "hunger": 2, + "saturation": 1 + }, + "ailment": { + "effects": [ ] + } + } + ] +} diff --git a/src/main/resources/data/unicopia/diets/races/pegasus.json b/src/main/resources/data/unicopia/diets/races/pegasus.json new file mode 100644 index 00000000..da8220b7 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/races/pegasus.json @@ -0,0 +1,59 @@ +{ + "default_multiplier": 0.5, + "foraging_multiplier": 1, + "multipliers": [ + { + "tags": [ "unicopia:food_types/cooked_fish" ], + "hunger": 1.5, + "saturation": 1.5 + }, + { + "tags": [ "unicopia:food_types/raw_fish" ], + "hunger": 0.5, + "saturation": 0.6 + }, + { + "tags": [ + "unicopia:food_types/cooked_insect", + "unicopia:food_types/cooked_meat" + ], + "hunger": 0.1, + "saturation": 0.1 + }, + { + "tags": [ + "unicopia:food_types/love", + "unicopia:food_types/raw_insect", + "unicopia:food_types/raw_meat", + "unicopia:food_types/rotten_meat" + ], + "hunger": 0, + "saturation": 0 + }, + { + "tags": [ "unicopia:food_types/pinecone" ], + "hunger": 0.9, + "saturation": 0.9 + } + ], + "effects": [ + { + "tags": [ "unicopia:food_types/cooked_fish" ], + "ailment": { + "effects": [ ] + } + }, + { + "tags": [ "unicopia:food_types/raw_fish" ], + "ailment": { + "effects": [ + { + "effect": "unicopia:food_poisoning", + "seconds": 50, + "amplifier": 2 + } + ] + } + } + ] +} diff --git a/src/main/resources/data/unicopia/diets/races/seapony.json b/src/main/resources/data/unicopia/diets/races/seapony.json new file mode 100644 index 00000000..4bf9a4cb --- /dev/null +++ b/src/main/resources/data/unicopia/diets/races/seapony.json @@ -0,0 +1,101 @@ +{ + "default_multiplier": 0.5, + "foraging_multiplier": 0.7, + "multipliers": [ + { + "tags": [ "unicopia:food_types/raw_sea_vegitable" ], + "hunger": 1, + "saturation": 1 + }, + { + "tags": [ + "unicopia:food_types/shells", + "unicopia:food_types/shelly" + ], + "hunger": 1, + "saturation": 1 + } + ], + "default_effects": { + "effects": [ + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2 + } + ] + }, + "effects": [ + { + "tags": [ "unicopia:food_types/cooked_fish" ], + "ailment": { + "effects": [ ] + } + }, + { + "tags": [ "unicopia:food_types/raw_fish" ], + "ailment": { + "effects": [ ] + } + }, + { + "tags": [ + "unicopia:food_types/forage_edible", + "unicopia:food_types/forage_edible_filling" + ], + "food_component": { + "hunger": 18, + "saturation": 9 + }, + "ailment": { + "effects": [ + { + "effect": "unicopia:food_poisoning", + "seconds": 100, + "amplifier": 2 + } + ] + } + }, + { + "tags": [ "unicopia:food_types/raw_sea_vegitable" ], + "food_component": { + "hunger": 2, + "saturation": 1 + }, + "ailment": { + "effects": [ ] + } + }, + { + "tags": [ "unicopia:food_types/cooked_sea_vegitable" ], + "food_component": { + "hunger": 6, + "saturation": 2 + }, + "ailment": { + "effects": [ ] + } + }, + { + "tags": [ "unicopia:food_types/shells" ], + "food_component": { + "hunger": 3, + "saturation": 5 + }, + "ailment": { + "effects": [ ] + } + }, + { + "tags": [ "unicopia:food_types/shelly" ], + "food_component": { + "hunger": 6, + "saturation": 7 + }, + "ailment": { + "effects": [ ] + } + } + ] +} diff --git a/src/main/resources/data/unicopia/diets/races/unicorn.json b/src/main/resources/data/unicopia/diets/races/unicorn.json new file mode 100644 index 00000000..866ba9e2 --- /dev/null +++ b/src/main/resources/data/unicopia/diets/races/unicorn.json @@ -0,0 +1,32 @@ +{ + "default_multiplier": 0.7, + "foraging_multiplier": 1, + "multipliers": [ + { + "tags": [ + "unicopia:food_types/cooked_insect", + "unicopia:food_types/cooked_meat", + "unicopia:food_types/cooked_fish" + ], + "hunger": 0.1, + "saturation": 0.1 + }, + { + "tags": [ + "unicopia:food_types/love", + "unicopia:food_types/raw_insect", + "unicopia:food_types/raw_meat", + "unicopia:food_types/raw_fish", + "unicopia:food_types/rotten_meat" + ], + "hunger": 0, + "saturation": 0 + }, + { + "tags": [ "unicopia:food_types/pinecone" ], + "hunger": 0.9, + "saturation": 0.9 + } + ], + "effects": [] +} diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/compacted_cloud.json b/src/main/resources/data/unicopia/loot_tables/blocks/carved_cloud.json similarity index 87% rename from src/main/resources/data/unicopia/loot_tables/blocks/compacted_cloud.json rename to src/main/resources/data/unicopia/loot_tables/blocks/carved_cloud.json index a63862dc..5457ca18 100644 --- a/src/main/resources/data/unicopia/loot_tables/blocks/compacted_cloud.json +++ b/src/main/resources/data/unicopia/loot_tables/blocks/carved_cloud.json @@ -7,7 +7,7 @@ "entries": [ { "type": "minecraft:item", - "name": "unicopia:cloud" + "name": "unicopia:carved_cloud" } ], "conditions": [ diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/clam_shell.json b/src/main/resources/data/unicopia/loot_tables/blocks/clam_shell.json new file mode 100644 index 00000000..f21c580e --- /dev/null +++ b/src/main/resources/data/unicopia/loot_tables/blocks/clam_shell.json @@ -0,0 +1,96 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "rolls": 1.0, + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "name": "unicopia:clam_shell", + "conditions": [ + { + "block": "unicopia:clam_shell", + "condition": "minecraft:block_state_property", + "properties": { + "count": "1" + } + } + ], + "functions": [ + { + "add": false, + "count": 1, + "function": "minecraft:set_count" + } + ] + }, + { + "type": "minecraft:item", + "name": "unicopia:clam_shell", + "conditions": [ + { + "block": "unicopia:clam_shell", + "condition": "minecraft:block_state_property", + "properties": { + "count": "2" + } + } + ], + "functions": [ + { + "add": false, + "count": 2, + "function": "minecraft:set_count" + } + ] + }, + { + "type": "minecraft:item", + "name": "unicopia:clam_shell", + "conditions": [ + { + "block": "unicopia:clam_shell", + "condition": "minecraft:block_state_property", + "properties": { + "count": "3" + } + } + ], + "functions": [ + { + "add": false, + "count": 3, + "function": "minecraft:set_count" + } + ] + }, + { + "type": "minecraft:item", + "name": "unicopia:clam_shell", + "conditions": [ + { + "block": "unicopia:clam_shell", + "condition": "minecraft:block_state_property", + "properties": { + "count": "4" + } + } + ], + "functions": [ + { + "add": false, + "count": 4, + "function": "minecraft:set_count" + } + ] + } + ], + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ] + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/cloth_bed.json b/src/main/resources/data/unicopia/loot_tables/blocks/cloth_bed.json new file mode 100644 index 00000000..a962ce67 --- /dev/null +++ b/src/main/resources/data/unicopia/loot_tables/blocks/cloth_bed.json @@ -0,0 +1,29 @@ +{ + "type": "minecraft:block", + "functions": [ + { + "function": "minecraft:explosion_decay" + } + ], + "pools": [ + { + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "conditions": [ + { + "block": "unicopia:cloth_bed", + "condition": "minecraft:block_state_property", + "properties": { + "part": "head" + } + } + ], + "name": "unicopia:cloth_bed" + } + ], + "rolls": 1.0 + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/cloud.json b/src/main/resources/data/unicopia/loot_tables/blocks/cloud.json index a63862dc..282d5ec9 100644 --- a/src/main/resources/data/unicopia/loot_tables/blocks/cloud.json +++ b/src/main/resources/data/unicopia/loot_tables/blocks/cloud.json @@ -7,7 +7,14 @@ "entries": [ { "type": "minecraft:item", - "name": "unicopia:cloud" + "name": "unicopia:cloud_lump", + "functions": [ + { + "add": false, + "count": 4, + "function": "minecraft:set_count" + } + ] } ], "conditions": [ diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/cloud_planks_slab.json b/src/main/resources/data/unicopia/loot_tables/blocks/cloud_brick_slab.json similarity index 86% rename from src/main/resources/data/unicopia/loot_tables/blocks/cloud_planks_slab.json rename to src/main/resources/data/unicopia/loot_tables/blocks/cloud_brick_slab.json index ae08d3ec..84bc3447 100644 --- a/src/main/resources/data/unicopia/loot_tables/blocks/cloud_planks_slab.json +++ b/src/main/resources/data/unicopia/loot_tables/blocks/cloud_brick_slab.json @@ -7,7 +7,7 @@ "entries": [ { "type": "minecraft:item", - "name": "unicopia:cloud_planks_slab", + "name": "unicopia:cloud_brick_slab", "functions": [ { "add": false, @@ -15,7 +15,7 @@ "function": "minecraft:set_count", "conditions": [ { - "block": "unicopia:cloud_planks_slab", + "block": "unicopia:cloud_brick_slab", "condition": "minecraft:block_state_property", "properties": { "type": "double" diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/cloud_planks_stairs.json b/src/main/resources/data/unicopia/loot_tables/blocks/cloud_brick_stairs.json similarity index 85% rename from src/main/resources/data/unicopia/loot_tables/blocks/cloud_planks_stairs.json rename to src/main/resources/data/unicopia/loot_tables/blocks/cloud_brick_stairs.json index 29999dd7..cd3e6120 100644 --- a/src/main/resources/data/unicopia/loot_tables/blocks/cloud_planks_stairs.json +++ b/src/main/resources/data/unicopia/loot_tables/blocks/cloud_brick_stairs.json @@ -7,7 +7,7 @@ "entries": [ { "type": "minecraft:item", - "name": "unicopia:cloud_planks_stairs" + "name": "unicopia:cloud_brick_stairs" } ], "conditions": [ diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/cloud_bricks.json b/src/main/resources/data/unicopia/loot_tables/blocks/cloud_bricks.json new file mode 100644 index 00000000..bd4602d9 --- /dev/null +++ b/src/main/resources/data/unicopia/loot_tables/blocks/cloud_bricks.json @@ -0,0 +1,20 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "rolls": 1.0, + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "name": "unicopia:cloud_bricks" + } + ], + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ] + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/cloud_door.json b/src/main/resources/data/unicopia/loot_tables/blocks/cloud_door.json new file mode 100644 index 00000000..2d948321 --- /dev/null +++ b/src/main/resources/data/unicopia/loot_tables/blocks/cloud_door.json @@ -0,0 +1,29 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "bonus_rolls": 0.0, + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ], + "entries": [ + { + "type": "minecraft:item", + "conditions": [ + { + "block": "unicopia:cloud_door", + "condition": "minecraft:block_state_property", + "properties": { + "half": "lower" + } + } + ], + "name": "unicopia:cloud_door" + } + ], + "rolls": 1.0 + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/cloud_plank_slab.json b/src/main/resources/data/unicopia/loot_tables/blocks/cloud_plank_slab.json new file mode 100644 index 00000000..64b9de8c --- /dev/null +++ b/src/main/resources/data/unicopia/loot_tables/blocks/cloud_plank_slab.json @@ -0,0 +1,36 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "rolls": 1.0, + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "name": "unicopia:cloud_plank_slab", + "functions": [ + { + "add": false, + "count": 2, + "function": "minecraft:set_count", + "conditions": [ + { + "block": "unicopia:cloud_plank_slab", + "condition": "minecraft:block_state_property", + "properties": { + "type": "double" + } + } + ] + } + ] + } + ], + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ] + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/cloud_plank_stairs.json b/src/main/resources/data/unicopia/loot_tables/blocks/cloud_plank_stairs.json new file mode 100644 index 00000000..3fa584df --- /dev/null +++ b/src/main/resources/data/unicopia/loot_tables/blocks/cloud_plank_stairs.json @@ -0,0 +1,20 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "rolls": 1.0, + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "name": "unicopia:cloud_plank_stairs" + } + ], + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ] + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/cloud_slab.json b/src/main/resources/data/unicopia/loot_tables/blocks/cloud_slab.json index b805f097..6926e7fe 100644 --- a/src/main/resources/data/unicopia/loot_tables/blocks/cloud_slab.json +++ b/src/main/resources/data/unicopia/loot_tables/blocks/cloud_slab.json @@ -7,12 +7,26 @@ "entries": [ { "type": "minecraft:item", - "name": "unicopia:cloud", + "name": "unicopia:cloud_lump", "functions": [ { "add": false, - "count": 3, + "count": 2, "function": "minecraft:set_count" + }, + { + "add": false, + "count": 4, + "function": "minecraft:set_count", + "conditions": [ + { + "block": "unicopia:cloud_slab", + "condition": "minecraft:block_state_property", + "properties": { + "type": "double" + } + } + ] } ] } diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/cloud_stairs.json b/src/main/resources/data/unicopia/loot_tables/blocks/cloud_stairs.json index 25c27a93..2259e860 100644 --- a/src/main/resources/data/unicopia/loot_tables/blocks/cloud_stairs.json +++ b/src/main/resources/data/unicopia/loot_tables/blocks/cloud_stairs.json @@ -7,7 +7,7 @@ "entries": [ { "type": "minecraft:item", - "name": "unicopia:cloud", + "name": "unicopia:cloud_lump", "functions": [ { "add": false, diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/crystal_door.json b/src/main/resources/data/unicopia/loot_tables/blocks/crystal_door.json new file mode 100644 index 00000000..15fd1392 --- /dev/null +++ b/src/main/resources/data/unicopia/loot_tables/blocks/crystal_door.json @@ -0,0 +1,29 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "bonus_rolls": 0.0, + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ], + "entries": [ + { + "type": "minecraft:item", + "conditions": [ + { + "block": "unicopia:crystal_door", + "condition": "minecraft:block_state_property", + "properties": { + "half": "lower" + } + } + ], + "name": "unicopia:crystal_door" + } + ], + "rolls": 1.0 + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/darK_oak_stable_door.json b/src/main/resources/data/unicopia/loot_tables/blocks/darK_oak_stable_door.json new file mode 100644 index 00000000..f758c3e2 --- /dev/null +++ b/src/main/resources/data/unicopia/loot_tables/blocks/darK_oak_stable_door.json @@ -0,0 +1,29 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "bonus_rolls": 0.0, + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ], + "entries": [ + { + "type": "minecraft:item", + "conditions": [ + { + "block": "unicopia:darK_oak_stable_door", + "condition": "minecraft:block_state_property", + "properties": { + "half": "lower" + } + } + ], + "name": "unicopia:darK_oak_stable_door" + } + ], + "rolls": 1.0 + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/dense_cloud.json b/src/main/resources/data/unicopia/loot_tables/blocks/dense_cloud.json index a63862dc..163e3667 100644 --- a/src/main/resources/data/unicopia/loot_tables/blocks/dense_cloud.json +++ b/src/main/resources/data/unicopia/loot_tables/blocks/dense_cloud.json @@ -7,7 +7,14 @@ "entries": [ { "type": "minecraft:item", - "name": "unicopia:cloud" + "name": "unicopia:cloud_lump", + "functions": [ + { + "add": false, + "count": 9, + "function": "minecraft:set_count" + } + ] } ], "conditions": [ diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/dense_cloud_slab.json b/src/main/resources/data/unicopia/loot_tables/blocks/dense_cloud_slab.json index dcd9199d..e9d1f0e2 100644 --- a/src/main/resources/data/unicopia/loot_tables/blocks/dense_cloud_slab.json +++ b/src/main/resources/data/unicopia/loot_tables/blocks/dense_cloud_slab.json @@ -7,12 +7,26 @@ "entries": [ { "type": "minecraft:item", - "name": "unicopia:dense_cloud", + "name": "unicopia:cloud_lump", "functions": [ { "add": false, - "count": 3, + "count": 4, "function": "minecraft:set_count" + }, + { + "add": false, + "count": 8, + "function": "minecraft:set_count", + "conditions": [ + { + "block": "unicopia:dense_cloud_slab", + "condition": "minecraft:block_state_property", + "properties": { + "type": "double" + } + } + ] } ] } diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/dense_cloud_stairs.json b/src/main/resources/data/unicopia/loot_tables/blocks/dense_cloud_stairs.json index 15b99d8c..80ba3be4 100644 --- a/src/main/resources/data/unicopia/loot_tables/blocks/dense_cloud_stairs.json +++ b/src/main/resources/data/unicopia/loot_tables/blocks/dense_cloud_stairs.json @@ -7,11 +7,11 @@ "entries": [ { "type": "minecraft:item", - "name": "unicopia:dense_cloud", + "name": "unicopia:cloud_lump", "functions": [ { "add": false, - "count": 6, + "count": 13, "function": "minecraft:set_count" } ] diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/etched_cloud.json b/src/main/resources/data/unicopia/loot_tables/blocks/etched_cloud.json new file mode 100644 index 00000000..163e3667 --- /dev/null +++ b/src/main/resources/data/unicopia/loot_tables/blocks/etched_cloud.json @@ -0,0 +1,27 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "rolls": 1.0, + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "name": "unicopia:cloud_lump", + "functions": [ + { + "add": false, + "count": 9, + "function": "minecraft:set_count" + } + ] + } + ], + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ] + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/etched_cloud_slab.json b/src/main/resources/data/unicopia/loot_tables/blocks/etched_cloud_slab.json new file mode 100644 index 00000000..4465e094 --- /dev/null +++ b/src/main/resources/data/unicopia/loot_tables/blocks/etched_cloud_slab.json @@ -0,0 +1,41 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "rolls": 1.0, + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "name": "unicopia:cloud_lump", + "functions": [ + { + "add": false, + "count": 4, + "function": "minecraft:set_count" + }, + { + "add": false, + "count": 8, + "function": "minecraft:set_count", + "conditions": [ + { + "block": "unicopia:etched_cloud_slab", + "condition": "minecraft:block_state_property", + "properties": { + "type": "double" + } + } + ] + } + ] + } + ], + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ] + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/etched_cloud_stairs.json b/src/main/resources/data/unicopia/loot_tables/blocks/etched_cloud_stairs.json new file mode 100644 index 00000000..80ba3be4 --- /dev/null +++ b/src/main/resources/data/unicopia/loot_tables/blocks/etched_cloud_stairs.json @@ -0,0 +1,27 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "rolls": 1.0, + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "name": "unicopia:cloud_lump", + "functions": [ + { + "add": false, + "count": 13, + "function": "minecraft:set_count" + } + ] + } + ], + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ] + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/plunder_vine.json b/src/main/resources/data/unicopia/loot_tables/blocks/plunder_vine.json new file mode 100644 index 00000000..857d1f4c --- /dev/null +++ b/src/main/resources/data/unicopia/loot_tables/blocks/plunder_vine.json @@ -0,0 +1,42 @@ +{ + "type": "minecraft:block", + "functions": [ + { + "function": "minecraft:explosion_decay" + } + ], + "pools": [ + { + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "name": "minecraft:stick" + }, + { + "type": "minecraft:item", + "name": "minecraft:dead_bush" + } + ], + "rolls": 4.0 + }, + { + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "name": "minecraft:stick" + }, + { + "type": "minecraft:item", + "name": "minecraft:dead_bush" + }, + { + "type": "minecraft:item", + "name": "unicopia:gryphon_feather" + } + ], + "rolls": 1.0 + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/scallop_shell.json b/src/main/resources/data/unicopia/loot_tables/blocks/scallop_shell.json new file mode 100644 index 00000000..c1e002b1 --- /dev/null +++ b/src/main/resources/data/unicopia/loot_tables/blocks/scallop_shell.json @@ -0,0 +1,96 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "rolls": 1.0, + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "name": "unicopia:scallop_shell", + "conditions": [ + { + "block": "unicopia:scallop_shell", + "condition": "minecraft:block_state_property", + "properties": { + "count": "1" + } + } + ], + "functions": [ + { + "add": false, + "count": 1, + "function": "minecraft:set_count" + } + ] + }, + { + "type": "minecraft:item", + "name": "unicopia:scallop_shell", + "conditions": [ + { + "block": "unicopia:scallop_shell", + "condition": "minecraft:block_state_property", + "properties": { + "count": "2" + } + } + ], + "functions": [ + { + "add": false, + "count": 2, + "function": "minecraft:set_count" + } + ] + }, + { + "type": "minecraft:item", + "name": "unicopia:scallop_shell", + "conditions": [ + { + "block": "unicopia:scallop_shell", + "condition": "minecraft:block_state_property", + "properties": { + "count": "3" + } + } + ], + "functions": [ + { + "add": false, + "count": 3, + "function": "minecraft:set_count" + } + ] + }, + { + "type": "minecraft:item", + "name": "unicopia:scallop_shell", + "conditions": [ + { + "block": "unicopia:scallop_shell", + "condition": "minecraft:block_state_property", + "properties": { + "count": "4" + } + } + ], + "functions": [ + { + "add": false, + "count": 4, + "function": "minecraft:set_count" + } + ] + } + ], + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ] + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/stable_door.json b/src/main/resources/data/unicopia/loot_tables/blocks/stable_door.json new file mode 100644 index 00000000..edeff07c --- /dev/null +++ b/src/main/resources/data/unicopia/loot_tables/blocks/stable_door.json @@ -0,0 +1,29 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "bonus_rolls": 0.0, + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ], + "entries": [ + { + "type": "minecraft:item", + "conditions": [ + { + "block": "unicopia:stable_door", + "condition": "minecraft:block_state_property", + "properties": { + "half": "lower" + } + } + ], + "name": "unicopia:stable_door" + } + ], + "rolls": 1.0 + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/loot_tables/blocks/turret_shell.json b/src/main/resources/data/unicopia/loot_tables/blocks/turret_shell.json new file mode 100644 index 00000000..b300a2d4 --- /dev/null +++ b/src/main/resources/data/unicopia/loot_tables/blocks/turret_shell.json @@ -0,0 +1,96 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "rolls": 1.0, + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "name": "unicopia:turret_shell", + "conditions": [ + { + "block": "unicopia:turret_shell", + "condition": "minecraft:block_state_property", + "properties": { + "count": "1" + } + } + ], + "functions": [ + { + "add": false, + "count": 1, + "function": "minecraft:set_count" + } + ] + }, + { + "type": "minecraft:item", + "name": "unicopia:turret_shell", + "conditions": [ + { + "block": "unicopia:turret_shell", + "condition": "minecraft:block_state_property", + "properties": { + "count": "2" + } + } + ], + "functions": [ + { + "add": false, + "count": 2, + "function": "minecraft:set_count" + } + ] + }, + { + "type": "minecraft:item", + "name": "unicopia:turret_shell", + "conditions": [ + { + "block": "unicopia:turret_shell", + "condition": "minecraft:block_state_property", + "properties": { + "count": "3" + } + } + ], + "functions": [ + { + "add": false, + "count": 3, + "function": "minecraft:set_count" + } + ] + }, + { + "type": "minecraft:item", + "name": "unicopia:turret_shell", + "conditions": [ + { + "block": "unicopia:turret_shell", + "condition": "minecraft:block_state_property", + "properties": { + "count": "4" + } + } + ], + "functions": [ + { + "add": false, + "count": 4, + "function": "minecraft:set_count" + } + ] + } + ], + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ] + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/loot_tables/entities/loot_bug.json b/src/main/resources/data/unicopia/loot_tables/entities/loot_bug.json new file mode 100644 index 00000000..7e8ec0ae --- /dev/null +++ b/src/main/resources/data/unicopia/loot_tables/entities/loot_bug.json @@ -0,0 +1,87 @@ +{ + "type": "minecraft:entity", + "pools": [ + { + "rolls": 11, + "bonus_rolls": 0, + "entries": [ + { + "type": "minecraft:item", + "functions": [ + { + "add": false, + "count": { + "type": "minecraft:uniform", + "max": 12.0, + "min": 6.0 + }, + "function": "minecraft:set_count" + }, + { + "function": "minecraft:looting_enchant", + "count": { + "type": "minecraft:uniform", + "min": 0.0, + "max": 3.0 + } + } + ], + "name": "minecraft:gold_nugget" + }, + { + "type": "minecraft:item", + "functions": [ + { + "add": false, + "count": { + "type": "minecraft:uniform", + "max": 12.0, + "min": 6.0 + }, + "function": "minecraft:set_count" + }, + { + "function": "minecraft:looting_enchant", + "count": { + "type": "minecraft:uniform", + "min": 0.0, + "max": 3.0 + } + } + ], + "name": "minecraft:iron_nugget" + } + ] + }, + { + "rolls": 1, + "bonus_rolls": 0, + "entries": [ + { + "type": "minecraft:tag", + "functions": [ + { + "add": false, + "count": { + "type": "minecraft:uniform", + "max": 3.0, + "min": 1.0 + }, + "function": "minecraft:set_count" + }, + { + "function": "minecraft:looting_enchant", + "count": { + "type": "minecraft:uniform", + "min": 0.0, + "max": 6.0 + } + } + ], + "name": "unicopia:loot_bug_high_value_drops", + "expand": true + } + ] + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/loot_tables/entities/storm_cloud.json b/src/main/resources/data/unicopia/loot_tables/entities/storm_cloud.json new file mode 100644 index 00000000..8d599d1a --- /dev/null +++ b/src/main/resources/data/unicopia/loot_tables/entities/storm_cloud.json @@ -0,0 +1,34 @@ +{ + "type": "minecraft:entity", + "pools": [ + { + "rolls": 1, + "bonus_rolls": 0, + "entries": [ + { + "type": "minecraft:item", + "functions": [ + { + "add": false, + "count": { + "type": "minecraft:uniform", + "max": 12.0, + "min": 6.0 + }, + "function": "minecraft:set_count" + }, + { + "function": "minecraft:looting_enchant", + "count": { + "type": "minecraft:uniform", + "min": 0.0, + "max": 1.0 + } + } + ], + "name": "unicopia:cloud_lump" + } + ] + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/apple.json b/src/main/resources/data/unicopia/recipes/bed_sheets/apple.json new file mode 100644 index 00000000..59c07b8a --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/apple.json @@ -0,0 +1,21 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "#%#", + "% %", + " %#" + ], + "key": { + "#": { + "item": "minecraft:green_wool" + }, + "%": { + "item": "minecraft:lime_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:apple_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/bar.json b/src/main/resources/data/unicopia/recipes/bed_sheets/bar.json new file mode 100644 index 00000000..c851297e --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/bar.json @@ -0,0 +1,21 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "#%#", + "% %", + " %#" + ], + "key": { + "#": { + "item": "minecraft:light_blue_wool" + }, + "%": { + "item": "minecraft:white_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:barred_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/black.json b/src/main/resources/data/unicopia/recipes/bed_sheets/black.json new file mode 100644 index 00000000..9bc645a0 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/black.json @@ -0,0 +1,18 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "###", + "# #", + " ##" + ], + "key": { + "#": { + "item": "minecraft:black_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:black_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/blue.json b/src/main/resources/data/unicopia/recipes/bed_sheets/blue.json new file mode 100644 index 00000000..a327c38e --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/blue.json @@ -0,0 +1,18 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "###", + "# #", + " ##" + ], + "key": { + "#": { + "item": "minecraft:blue_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:blue_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/brown.json b/src/main/resources/data/unicopia/recipes/bed_sheets/brown.json new file mode 100644 index 00000000..873eee0a --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/brown.json @@ -0,0 +1,18 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "###", + "# #", + " ##" + ], + "key": { + "#": { + "item": "minecraft:brown_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:brown_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/checker.json b/src/main/resources/data/unicopia/recipes/bed_sheets/checker.json new file mode 100644 index 00000000..eb41d549 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/checker.json @@ -0,0 +1,21 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "#%#", + "% %", + " %#" + ], + "key": { + "#": { + "item": "minecraft:green_wool" + }, + "%": { + "item": "minecraft:brown_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:checkered_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/cyan.json b/src/main/resources/data/unicopia/recipes/bed_sheets/cyan.json new file mode 100644 index 00000000..55d27f39 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/cyan.json @@ -0,0 +1,18 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "###", + "# #", + " ##" + ], + "key": { + "#": { + "item": "minecraft:cyan_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:cyan_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/gray.json b/src/main/resources/data/unicopia/recipes/bed_sheets/gray.json new file mode 100644 index 00000000..c22908d1 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/gray.json @@ -0,0 +1,18 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "###", + "# #", + " ##" + ], + "key": { + "#": { + "item": "minecraft:gray_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:gray_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/green.json b/src/main/resources/data/unicopia/recipes/bed_sheets/green.json new file mode 100644 index 00000000..44cefb48 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/green.json @@ -0,0 +1,18 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "###", + "# #", + " ##" + ], + "key": { + "#": { + "item": "minecraft:green_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:green_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/kelp.json b/src/main/resources/data/unicopia/recipes/bed_sheets/kelp.json new file mode 100644 index 00000000..31590054 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/kelp.json @@ -0,0 +1,18 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "###", + "# #", + " ##" + ], + "key": { + "#": { + "item": "minecraft:kelp" + } + }, + "result": { + "count": 1, + "item": "unicopia:kelp_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/light_blue.json b/src/main/resources/data/unicopia/recipes/bed_sheets/light_blue.json new file mode 100644 index 00000000..7da12483 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/light_blue.json @@ -0,0 +1,18 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "###", + "# #", + " ##" + ], + "key": { + "#": { + "item": "minecraft:light_blue_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:light_blue_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/light_gray.json b/src/main/resources/data/unicopia/recipes/bed_sheets/light_gray.json new file mode 100644 index 00000000..2762e0a7 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/light_gray.json @@ -0,0 +1,18 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "###", + "# #", + " ##" + ], + "key": { + "#": { + "item": "minecraft:light_gray_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:light_gray_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/lime.json b/src/main/resources/data/unicopia/recipes/bed_sheets/lime.json new file mode 100644 index 00000000..88734f2c --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/lime.json @@ -0,0 +1,18 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "###", + "# #", + " ##" + ], + "key": { + "#": { + "item": "minecraft:lime_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:lime_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/magenta.json b/src/main/resources/data/unicopia/recipes/bed_sheets/magenta.json new file mode 100644 index 00000000..eb70f444 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/magenta.json @@ -0,0 +1,18 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "###", + "# #", + " ##" + ], + "key": { + "#": { + "item": "minecraft:magenta_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:magenta_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/orange.json b/src/main/resources/data/unicopia/recipes/bed_sheets/orange.json new file mode 100644 index 00000000..3fa98370 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/orange.json @@ -0,0 +1,18 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "###", + "# #", + " ##" + ], + "key": { + "#": { + "item": "minecraft:orange_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:orange_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/pink.json b/src/main/resources/data/unicopia/recipes/bed_sheets/pink.json new file mode 100644 index 00000000..2d93ece3 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/pink.json @@ -0,0 +1,18 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "###", + "# #", + " ##" + ], + "key": { + "#": { + "item": "minecraft:pink_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:pink_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/purple.json b/src/main/resources/data/unicopia/recipes/bed_sheets/purple.json new file mode 100644 index 00000000..ab41e3ad --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/purple.json @@ -0,0 +1,18 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "###", + "# #", + " ##" + ], + "key": { + "#": { + "item": "minecraft:purple_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:purple_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/rainbow.json b/src/main/resources/data/unicopia/recipes/bed_sheets/rainbow.json new file mode 100644 index 00000000..16b2493b --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/rainbow.json @@ -0,0 +1,36 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "ROY", + "L B", + " PG" + ], + "key": { + "Y": { + "item": "minecraft:yellow_wool" + }, + "O": { + "item": "minecraft:orange_wool" + }, + "R": { + "item": "minecraft:red_wool" + }, + "G": { + "item": "minecraft:green_wool" + }, + "B": { + "item": "minecraft:blue_wool" + }, + "P": { + "item": "minecraft:purple_wool" + }, + "L": { + "item": "minecraft:light_blue_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:rainbow_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/rainbow_bpw.json b/src/main/resources/data/unicopia/recipes/bed_sheets/rainbow_bpw.json new file mode 100644 index 00000000..431b5bad --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/rainbow_bpw.json @@ -0,0 +1,24 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "PWP", + "B B", + " WP" + ], + "key": { + "B": { + "item": "minecraft:light_blue_wool" + }, + "P": { + "item": "minecraft:pink_wool" + }, + "W": { + "item": "minecraft:white_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:rainbow_bpw_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/rainbow_bpy.json b/src/main/resources/data/unicopia/recipes/bed_sheets/rainbow_bpy.json new file mode 100644 index 00000000..f67eb380 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/rainbow_bpy.json @@ -0,0 +1,24 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "PBP", + "Y Y", + " BP" + ], + "key": { + "P": { + "item": "minecraft:pink_wool" + }, + "B": { + "item": "minecraft:light_blue_wool" + }, + "Y": { + "item": "minecraft:yellow_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:rainbow_bpy_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/rainbow_pgb.json b/src/main/resources/data/unicopia/recipes/bed_sheets/rainbow_pgb.json new file mode 100644 index 00000000..3e61b550 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/rainbow_pgb.json @@ -0,0 +1,27 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "WGB", + "P G", + " PW" + ], + "key": { + "P": { + "item": "minecraft:purple_wool" + }, + "W": { + "item": "minecraft:white_wool" + }, + "G": { + "item": "minecraft:light_gray_wool" + }, + "B": { + "item": "minecraft:black_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:rainbow_pbg_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/rainbow_pwr.json b/src/main/resources/data/unicopia/recipes/bed_sheets/rainbow_pwr.json new file mode 100644 index 00000000..ba2c76df --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/rainbow_pwr.json @@ -0,0 +1,24 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "WRW", + "P P", + " RW" + ], + "key": { + "P": { + "item": "minecraft:pink_wool" + }, + "W": { + "item": "minecraft:white_wool" + }, + "R": { + "item": "minecraft:red_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:rainbow_pwr_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/red.json b/src/main/resources/data/unicopia/recipes/bed_sheets/red.json new file mode 100644 index 00000000..ef489f95 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/red.json @@ -0,0 +1,18 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "###", + "# #", + " ##" + ], + "key": { + "#": { + "item": "minecraft:red_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:red_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/bed_sheets/yellow.json b/src/main/resources/data/unicopia/recipes/bed_sheets/yellow.json new file mode 100644 index 00000000..84bdbe03 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/bed_sheets/yellow.json @@ -0,0 +1,18 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed_sheets", + "pattern": [ + "###", + "# #", + " ##" + ], + "key": { + "#": { + "item": "minecraft:yellow_wool" + } + }, + "result": { + "count": 1, + "item": "unicopia:yellow_bed_sheets" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/blocks/carving/carved_cloud_cutting.json b/src/main/resources/data/unicopia/recipes/blocks/carving/carved_cloud_cutting.json new file mode 100644 index 00000000..4a933c98 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/carving/carved_cloud_cutting.json @@ -0,0 +1,6 @@ +{ + "type": "unicopia:cloud_shaping", + "ingredient": { "item": "unicopia:cloud" }, + "result": "unicopia:carved_cloud", + "count": 1 +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_brick_slab_cutting.json b/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_brick_slab_cutting.json new file mode 100644 index 00000000..80f2e283 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_brick_slab_cutting.json @@ -0,0 +1,6 @@ +{ + "type": "unicopia:cloud_shaping", + "ingredient": { "item": "unicopia:cloud_bricks" }, + "result": "unicopia:cloud_brick_slab", + "count": 2 +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_brick_stairs_cutting.json b/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_brick_stairs_cutting.json new file mode 100644 index 00000000..536622ad --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_brick_stairs_cutting.json @@ -0,0 +1,6 @@ +{ + "type": "unicopia:cloud_shaping", + "ingredient": { "item": "unicopia:cloud_bricks" }, + "result": "unicopia:cloud_brick_stairs", + "count": 1 +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_bricks_cutting.json b/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_bricks_cutting.json new file mode 100644 index 00000000..fde1cb89 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_bricks_cutting.json @@ -0,0 +1,6 @@ +{ + "type": "unicopia:cloud_shaping", + "ingredient": { "item": "unicopia:cloud" }, + "result": "unicopia:cloud_bricks", + "count": 1 +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_pillar_cutting.json b/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_pillar_cutting.json new file mode 100644 index 00000000..1d60c72d --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_pillar_cutting.json @@ -0,0 +1,6 @@ +{ + "type": "unicopia:cloud_shaping", + "ingredient": { "item": "unicopia:cloud" }, + "result": "unicopia:cloud_pillar", + "count": 1 +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_plank_slab_cutting.json b/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_plank_slab_cutting.json new file mode 100644 index 00000000..0ab285b9 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_plank_slab_cutting.json @@ -0,0 +1,6 @@ +{ + "type": "unicopia:cloud_shaping", + "ingredient": { "item": "unicopia:cloud_planks" }, + "result": "unicopia:cloud_plank_slab", + "count": 2 +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_plank_stairs_cutting.json b/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_plank_stairs_cutting.json new file mode 100644 index 00000000..77eed444 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_plank_stairs_cutting.json @@ -0,0 +1,6 @@ +{ + "type": "unicopia:cloud_shaping", + "ingredient": { "item": "unicopia:cloud_planks" }, + "result": "unicopia:cloud_plank_stairs", + "count": 1 +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_planks_cutting.json b/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_planks_cutting.json new file mode 100644 index 00000000..97e40db7 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_planks_cutting.json @@ -0,0 +1,6 @@ +{ + "type": "unicopia:cloud_shaping", + "ingredient": { "item": "unicopia:cloud" }, + "result": "unicopia:cloud_planks", + "count": 1 +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_slab_cutting.json b/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_slab_cutting.json new file mode 100644 index 00000000..03a75d8e --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_slab_cutting.json @@ -0,0 +1,6 @@ +{ + "type": "unicopia:cloud_shaping", + "ingredient": { "item": "unicopia:cloud" }, + "result": "unicopia:cloud_slab", + "count": 2 +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_stairs_cutting.json b/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_stairs_cutting.json new file mode 100644 index 00000000..a43df56c --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/carving/cloud_stairs_cutting.json @@ -0,0 +1,6 @@ +{ + "type": "unicopia:cloud_shaping", + "ingredient": { "item": "unicopia:cloud" }, + "result": "unicopia:cloud_stairs", + "count": 1 +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/carving/dense_cloud_slab_cutting.json b/src/main/resources/data/unicopia/recipes/blocks/carving/dense_cloud_slab_cutting.json new file mode 100644 index 00000000..45688bd5 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/carving/dense_cloud_slab_cutting.json @@ -0,0 +1,6 @@ +{ + "type": "unicopia:cloud_shaping", + "ingredient": { "item": "unicopia:dense_cloud" }, + "result": "unicopia:dense_cloud_slab", + "count": 2 +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/carving/dense_cloud_stairs_cutting.json b/src/main/resources/data/unicopia/recipes/blocks/carving/dense_cloud_stairs_cutting.json new file mode 100644 index 00000000..13b6e197 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/carving/dense_cloud_stairs_cutting.json @@ -0,0 +1,6 @@ +{ + "type": "unicopia:cloud_shaping", + "ingredient": { "item": "unicopia:dense_cloud" }, + "result": "unicopia:dense_cloud_stairs", + "count": 1 +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/carving/etched_cloud_cutting.json b/src/main/resources/data/unicopia/recipes/blocks/carving/etched_cloud_cutting.json new file mode 100644 index 00000000..9f8b76ff --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/carving/etched_cloud_cutting.json @@ -0,0 +1,6 @@ +{ + "type": "unicopia:cloud_shaping", + "ingredient": { "item": "unicopia:dense_cloud" }, + "result": "unicopia:etched_cloud", + "count": 1 +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/carving/etched_cloud_slab_cutting.json b/src/main/resources/data/unicopia/recipes/blocks/carving/etched_cloud_slab_cutting.json new file mode 100644 index 00000000..951b6f70 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/carving/etched_cloud_slab_cutting.json @@ -0,0 +1,6 @@ +{ + "type": "unicopia:cloud_shaping", + "ingredient": { "item": "unicopia:etched_cloud" }, + "result": "unicopia:etched_cloud_slab", + "count": 2 +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/carving/etched_cloud_stairs_cutting.json b/src/main/resources/data/unicopia/recipes/blocks/carving/etched_cloud_stairs_cutting.json new file mode 100644 index 00000000..85ddf8e0 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/carving/etched_cloud_stairs_cutting.json @@ -0,0 +1,6 @@ +{ + "type": "unicopia:cloud_shaping", + "ingredient": { "item": "unicopia:etched_cloud" }, + "result": "unicopia:etched_cloud_stairs", + "count": 1 +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/cloud_block.json b/src/main/resources/data/unicopia/recipes/blocks/cloud_block.json new file mode 100644 index 00000000..949938df --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/cloud_block.json @@ -0,0 +1,13 @@ +{ + "type": "minecraft:crafting_shaped", + "pattern": [ + "##", + "##" + ], + "key": { + "#": [ + { "item": "unicopia:cloud_lump" } + ] + }, + "result": { "item": "unicopia:cloud", "count": 1 } +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/cloud_brick_slab.json b/src/main/resources/data/unicopia/recipes/blocks/cloud_brick_slab.json new file mode 100644 index 00000000..9b4480e8 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/cloud_brick_slab.json @@ -0,0 +1,12 @@ +{ + "type": "minecraft:crafting_shaped", + "pattern": [ + "###" + ], + "key": { + "#": [ + { "item": "unicopia:cloud_bricks" } + ] + }, + "result": { "item": "unicopia:cloud_brick_slab", "count": 6 } +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/cloud_brick_stairs.json b/src/main/resources/data/unicopia/recipes/blocks/cloud_brick_stairs.json new file mode 100644 index 00000000..01d2cea2 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/cloud_brick_stairs.json @@ -0,0 +1,14 @@ +{ + "type": "minecraft:crafting_shaped", + "pattern": [ + "# ", + "## ", + "###" + ], + "key": { + "#": [ + { "item": "unicopia:cloud_bricks" } + ] + }, + "result": { "item": "unicopia:cloud_brick_stairs", "count": 4 } +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/cloud_chest.json b/src/main/resources/data/unicopia/recipes/blocks/cloud_chest.json new file mode 100644 index 00000000..5373f56c --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/cloud_chest.json @@ -0,0 +1,14 @@ +{ + "type": "minecraft:crafting_shaped", + "pattern": [ + "###", + "# #", + "###" + ], + "key": { + "#": [ + { "item": "unicopia:cloud_planks" } + ] + }, + "result": { "item": "unicopia:cloud_chest", "count": 1 } +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/cloud_plank_slab.json b/src/main/resources/data/unicopia/recipes/blocks/cloud_plank_slab.json index f6f99b84..4eca09e0 100644 --- a/src/main/resources/data/unicopia/recipes/blocks/cloud_plank_slab.json +++ b/src/main/resources/data/unicopia/recipes/blocks/cloud_plank_slab.json @@ -8,5 +8,5 @@ { "item": "unicopia:cloud_planks" } ] }, - "result": { "item": "unicopia:cloud_planks_slab", "count": 6 } + "result": { "item": "unicopia:cloud_plank_slab", "count": 6 } } diff --git a/src/main/resources/data/unicopia/recipes/blocks/cloud_plank_stairs.json b/src/main/resources/data/unicopia/recipes/blocks/cloud_plank_stairs.json index 0ff48eb1..82295d31 100644 --- a/src/main/resources/data/unicopia/recipes/blocks/cloud_plank_stairs.json +++ b/src/main/resources/data/unicopia/recipes/blocks/cloud_plank_stairs.json @@ -10,5 +10,5 @@ { "item": "unicopia:cloud_planks" } ] }, - "result": { "item": "unicopia:cloud_planks_stairs", "count": 4 } + "result": { "item": "unicopia:cloud_plank_stairs", "count": 4 } } diff --git a/src/main/resources/data/unicopia/recipes/blocks/shaping_bench.json b/src/main/resources/data/unicopia/recipes/blocks/shaping_bench.json new file mode 100644 index 00000000..98263612 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/shaping_bench.json @@ -0,0 +1,13 @@ +{ + "type": "minecraft:crafting_shaped", + "pattern": [ + "##", + "##" + ], + "key": { + "#": [ + { "item": "unicopia:dense_cloud" } + ] + }, + "result": { "item": "unicopia:shaping_bench", "count": 1 } +} diff --git a/src/main/resources/data/unicopia/recipes/blocks/unstable_cloud.json b/src/main/resources/data/unicopia/recipes/blocks/unstable_cloud.json new file mode 100644 index 00000000..6ccbf5d4 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/blocks/unstable_cloud.json @@ -0,0 +1,18 @@ +{ + "type": "minecraft:crafting_shaped", + "pattern": [ + "###", + "#O#", + "###" + ], + "key": { + "#": [ + { "item": "unicopia:cloud" } + ], + "O": [ + { "item": "unicopia:lightning_jar" }, + { "item": "unicopia:zap_apple_jam_jar" } + ] + }, + "result": { "item": "unicopia:unstable_cloud", "count": 8 } +} diff --git a/src/main/resources/data/unicopia/recipes/cloth_bed.json b/src/main/resources/data/unicopia/recipes/cloth_bed.json new file mode 100644 index 00000000..54ba7a7f --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/cloth_bed.json @@ -0,0 +1,20 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed", + "pattern": [ + "^^^", + "###" + ], + "key": { + "^": { + "tag": "minecraft:wool" + }, + "#": { + "tag": "minecraft:logs" + } + }, + "result": { + "count": 1, + "item": "unicopia:cloth_bed" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/cloud_bed.json b/src/main/resources/data/unicopia/recipes/cloud_bed.json new file mode 100644 index 00000000..93b131a8 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/cloud_bed.json @@ -0,0 +1,20 @@ +{ + "type": "minecraft:crafting_shaped", + "group": "bed", + "pattern": [ + "^^^", + "###" + ], + "key": { + "^": { + "item": "unicopia:cloud" + }, + "#": { + "item": "unicopia:cloud_planks" + } + }, + "result": { + "count": 1, + "item": "unicopia:cloud_bed" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/cloud_lump.json b/src/main/resources/data/unicopia/recipes/cloud_lump.json new file mode 100644 index 00000000..6890547d --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/cloud_lump.json @@ -0,0 +1,7 @@ +{ + "type": "minecraft:crafting_shapeless", + "ingredients": [ + { "tag": "unicopia:cloud_jars" } + ], + "result": { "item": "unicopia:cloud_lump", "count": 4 } +} diff --git a/src/main/resources/data/unicopia/recipes/crystal_door.json b/src/main/resources/data/unicopia/recipes/crystal_door.json new file mode 100644 index 00000000..0d952926 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/crystal_door.json @@ -0,0 +1,16 @@ +{ + "type": "minecraft:crafting_shaped", + "pattern": [ + "**", + "**", + "**" + ], + "key": { + "*": { + "item": "unicopia:crystal_shard" + } + }, + "result": { + "item": "unicopia:crystal_door" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/dark_oak_stable_door.json b/src/main/resources/data/unicopia/recipes/dark_oak_stable_door.json new file mode 100644 index 00000000..21aef6a2 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/dark_oak_stable_door.json @@ -0,0 +1,19 @@ +{ + "type": "minecraft:crafting_shaped", + "pattern": [ + "*#*", + "*#*", + "*#*" + ], + "key": { + "*": { + "item": "unicopia:rock" + }, + "#": { + "tag": "minecraft:planks" + } + }, + "result": { + "item": "unicopia:dark_oak_stable_door" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/pearl_necklace.json b/src/main/resources/data/unicopia/recipes/pearl_necklace.json new file mode 100644 index 00000000..4b9a4db6 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/pearl_necklace.json @@ -0,0 +1,15 @@ +{ + "type": "minecraft:crafting_shaped", + "pattern": [ + "# #", + "# #", + "~#~" + ], + "key": { + "#": { "tag": "unicopia:food_types/shells" }, + "~": { "item": "minecraft:string" } + }, + "result": { + "item": "unicopia:pearl_necklace" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/shelly.json b/src/main/resources/data/unicopia/recipes/shelly.json new file mode 100644 index 00000000..54c4a93d --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/shelly.json @@ -0,0 +1,14 @@ +{ + "type": "minecraft:crafting_shaped", + "pattern": [ + "o o", + " C " + ], + "key": { + "C": { "item": "unicopia:clam_shell" }, + "o": { "item": "unicopia:rock_candy" } + }, + "result": { + "item": "unicopia:shelly" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/recipes/stable_door.json b/src/main/resources/data/unicopia/recipes/stable_door.json new file mode 100644 index 00000000..c1acd242 --- /dev/null +++ b/src/main/resources/data/unicopia/recipes/stable_door.json @@ -0,0 +1,19 @@ +{ + "type": "minecraft:crafting_shaped", + "pattern": [ + "*#*", + "*#*", + "*#*" + ], + "key": { + "*": { + "item": "unicopia:rock_candy" + }, + "#": { + "tag": "minecraft:planks" + } + }, + "result": { + "item": "unicopia:stable_door" + } +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/structures/cloud_islands/blobs/blob_1.nbt b/src/main/resources/data/unicopia/structures/cloud_islands/blobs/blob_1.nbt new file mode 100644 index 00000000..dcd83aa1 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/cloud_islands/blobs/blob_1.nbt differ diff --git a/src/main/resources/data/unicopia/structures/cloud_islands/continent/a.nbt b/src/main/resources/data/unicopia/structures/cloud_islands/continent/a.nbt new file mode 100644 index 00000000..7dfe8f15 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/cloud_islands/continent/a.nbt differ diff --git a/src/main/resources/data/unicopia/structures/cloud_islands/continent/b.nbt b/src/main/resources/data/unicopia/structures/cloud_islands/continent/b.nbt new file mode 100644 index 00000000..51a2c534 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/cloud_islands/continent/b.nbt differ diff --git a/src/main/resources/data/unicopia/structures/cloud_islands/continent/c.nbt b/src/main/resources/data/unicopia/structures/cloud_islands/continent/c.nbt new file mode 100644 index 00000000..08a639d6 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/cloud_islands/continent/c.nbt differ diff --git a/src/main/resources/data/unicopia/structures/cloud_islands/continent/d.nbt b/src/main/resources/data/unicopia/structures/cloud_islands/continent/d.nbt new file mode 100644 index 00000000..7962a5d7 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/cloud_islands/continent/d.nbt differ diff --git a/src/main/resources/data/unicopia/structures/cloud_islands/continent/e.nbt b/src/main/resources/data/unicopia/structures/cloud_islands/continent/e.nbt new file mode 100644 index 00000000..2a395b97 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/cloud_islands/continent/e.nbt differ diff --git a/src/main/resources/data/unicopia/structures/cloud_islands/continent/f.nbt b/src/main/resources/data/unicopia/structures/cloud_islands/continent/f.nbt new file mode 100644 index 00000000..4756ff6d Binary files /dev/null and b/src/main/resources/data/unicopia/structures/cloud_islands/continent/f.nbt differ diff --git a/src/main/resources/data/unicopia/structures/cloud_islands/continent/g.nbt b/src/main/resources/data/unicopia/structures/cloud_islands/continent/g.nbt new file mode 100644 index 00000000..adaba3c2 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/cloud_islands/continent/g.nbt differ diff --git a/src/main/resources/data/unicopia/structures/cloud_islands/surfaces/surface_1.nbt b/src/main/resources/data/unicopia/structures/cloud_islands/surfaces/surface_1.nbt new file mode 100644 index 00000000..0bec5ff5 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/cloud_islands/surfaces/surface_1.nbt differ diff --git a/src/main/resources/data/unicopia/structures/cloud_islands/surfaces/surface_2.nbt b/src/main/resources/data/unicopia/structures/cloud_islands/surfaces/surface_2.nbt new file mode 100644 index 00000000..7585f7a7 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/cloud_islands/surfaces/surface_2.nbt differ diff --git a/src/main/resources/data/unicopia/structures/cloud_islands/surfaces/surface_3.nbt b/src/main/resources/data/unicopia/structures/cloud_islands/surfaces/surface_3.nbt new file mode 100644 index 00000000..16daa971 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/cloud_islands/surfaces/surface_3.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/junction_1.nbt b/src/main/resources/data/unicopia/structures/clouds/junction_1.nbt new file mode 100644 index 00000000..68165f68 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/junction_1.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/junction_2.nbt b/src/main/resources/data/unicopia/structures/clouds/junction_2.nbt new file mode 100644 index 00000000..0a20fb6c Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/junction_2.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/junction_3.nbt b/src/main/resources/data/unicopia/structures/clouds/junction_3.nbt new file mode 100644 index 00000000..075dab3a Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/junction_3.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/junction_4.nbt b/src/main/resources/data/unicopia/structures/clouds/junction_4.nbt new file mode 100644 index 00000000..81303639 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/junction_4.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/junction_5.nbt b/src/main/resources/data/unicopia/structures/clouds/junction_5.nbt new file mode 100644 index 00000000..76a97088 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/junction_5.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/large_1.nbt b/src/main/resources/data/unicopia/structures/clouds/large_1.nbt new file mode 100644 index 00000000..8cce28fa Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/large_1.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/large_2.nbt b/src/main/resources/data/unicopia/structures/clouds/large_2.nbt new file mode 100644 index 00000000..992440e4 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/large_2.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/large_3.nbt b/src/main/resources/data/unicopia/structures/clouds/large_3.nbt new file mode 100644 index 00000000..4fd2200a Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/large_3.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/medium_1.nbt b/src/main/resources/data/unicopia/structures/clouds/medium_1.nbt new file mode 100644 index 00000000..91b3a21a Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/medium_1.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/medium_2.nbt b/src/main/resources/data/unicopia/structures/clouds/medium_2.nbt new file mode 100644 index 00000000..67319641 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/medium_2.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/pillar_boat.nbt b/src/main/resources/data/unicopia/structures/clouds/pillar_boat.nbt new file mode 100644 index 00000000..84e32d3f Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/pillar_boat.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/pillars/pillar_1.nbt b/src/main/resources/data/unicopia/structures/clouds/pillars/pillar_1.nbt new file mode 100644 index 00000000..c5af1333 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/pillars/pillar_1.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/pillars/pillar_2.nbt b/src/main/resources/data/unicopia/structures/clouds/pillars/pillar_2.nbt new file mode 100644 index 00000000..65839c62 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/pillars/pillar_2.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/pillars/pillar_3.nbt b/src/main/resources/data/unicopia/structures/clouds/pillars/pillar_3.nbt new file mode 100644 index 00000000..ea48d9ef Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/pillars/pillar_3.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/pillars/pillar_4.nbt b/src/main/resources/data/unicopia/structures/clouds/pillars/pillar_4.nbt new file mode 100644 index 00000000..a8d21958 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/pillars/pillar_4.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/pillars/well.nbt b/src/main/resources/data/unicopia/structures/clouds/pillars/well.nbt new file mode 100644 index 00000000..543f0964 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/pillars/well.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/small_1.nbt b/src/main/resources/data/unicopia/structures/clouds/small_1.nbt new file mode 100644 index 00000000..7dc60a7d Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/small_1.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/small_2.nbt b/src/main/resources/data/unicopia/structures/clouds/small_2.nbt new file mode 100644 index 00000000..b17f07df Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/small_2.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/small_3.nbt b/src/main/resources/data/unicopia/structures/clouds/small_3.nbt new file mode 100644 index 00000000..4823a4bd Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/small_3.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/village/house_1.nbt b/src/main/resources/data/unicopia/structures/clouds/village/house_1.nbt new file mode 100644 index 00000000..b2366c71 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/village/house_1.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/village/house_2.nbt b/src/main/resources/data/unicopia/structures/clouds/village/house_2.nbt new file mode 100644 index 00000000..8f7466dc Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/village/house_2.nbt differ diff --git a/src/main/resources/data/unicopia/structures/clouds/village/house_3.nbt b/src/main/resources/data/unicopia/structures/clouds/village/house_3.nbt new file mode 100644 index 00000000..eb14b508 Binary files /dev/null and b/src/main/resources/data/unicopia/structures/clouds/village/house_3.nbt differ diff --git a/src/main/resources/data/unicopia/tags/blocks/cloud_slabs.json b/src/main/resources/data/unicopia/tags/blocks/cloud_slabs.json index 9f8be83c..3a2b1dc1 100644 --- a/src/main/resources/data/unicopia/tags/blocks/cloud_slabs.json +++ b/src/main/resources/data/unicopia/tags/blocks/cloud_slabs.json @@ -4,6 +4,8 @@ "unicopia:cloud_slab", "unicopia:soggy_cloud_slab", "unicopia:dense_cloud_slab", - "unicopia:cloud_planks_slab" + "unicopia:etched_cloud_slab", + "unicopia:cloud_plank_slab", + "unicopia:cloud_brick_slab" ] } diff --git a/src/main/resources/data/unicopia/tags/blocks/cloud_stairs.json b/src/main/resources/data/unicopia/tags/blocks/cloud_stairs.json index bd0de50d..7f816bb4 100644 --- a/src/main/resources/data/unicopia/tags/blocks/cloud_stairs.json +++ b/src/main/resources/data/unicopia/tags/blocks/cloud_stairs.json @@ -4,6 +4,8 @@ "unicopia:cloud_stairs", "unicopia:soggy_cloud_stairs", "unicopia:dense_cloud_stairs", - "unicopia:cloud_planks_stairs" + "unicopia:etched_cloud_stairs", + "unicopia:cloud_plank_stairs", + "unicopia:cloud_brick_stairs" ] } diff --git a/src/main/resources/data/unicopia/tags/blocks/clouds.json b/src/main/resources/data/unicopia/tags/blocks/clouds.json index 3539ce34..911abcd4 100644 --- a/src/main/resources/data/unicopia/tags/blocks/clouds.json +++ b/src/main/resources/data/unicopia/tags/blocks/clouds.json @@ -3,7 +3,10 @@ "values": [ "unicopia:cloud", "unicopia:cloud_planks", + "unicopia:cloud_bricks", "unicopia:dense_cloud", + "unicopia:etched_cloud", + "unicopia:carved_cloud", "unicopia:compacted_cloud", "unicopia:compacted_cloud_planks", "unicopia:unstable_cloud", diff --git a/src/main/resources/data/unicopia/tags/items/bed_sheets.json b/src/main/resources/data/unicopia/tags/items/bed_sheets.json new file mode 100644 index 00000000..295c3f4d --- /dev/null +++ b/src/main/resources/data/unicopia/tags/items/bed_sheets.json @@ -0,0 +1,31 @@ +{ + "replace": false, + "values": [ + "unicopia:light_gray_bed_sheets", + "unicopia:gray_bed_sheets", + "unicopia:black_bed_sheets", + "unicopia:brown_bed_sheets", + "unicopia:red_bed_sheets", + "unicopia:orange_bed_sheets", + "unicopia:yellow_bed_sheets", + "unicopia:lime_bed_sheets", + "unicopia:green_bed_sheets", + "unicopia:cyan_bed_sheets", + "unicopia:light_blue_bed_sheets", + "unicopia:blue_bed_sheets", + "unicopia:purple_bed_sheets", + "unicopia:magenta_bed_sheets", + "unicopia:pink_bed_sheets", + + + "unicopia:apple_bed_sheets", + "unicopia:barred_bed_sheets", + "unicopia:checkered_bed_sheets", + "unicopia:kelp_bed_sheets", + "unicopia:rainbow_bed_sheets", + "unicopia:rainbow_bpw_bed_sheets", + "unicopia:rainbow_bpy_bed_sheets", + "unicopia:rainbow_pbg_bed_sheets", + "unicopia:rainbow_pwr_bed_sheets" + ] +} diff --git a/src/main/resources/data/unicopia/tags/items/cloud_jars.json b/src/main/resources/data/unicopia/tags/items/cloud_jars.json new file mode 100644 index 00000000..3dad874d --- /dev/null +++ b/src/main/resources/data/unicopia/tags/items/cloud_jars.json @@ -0,0 +1,7 @@ +{ + "replace": false, + "values": [ + "unicopia:rain_cloud_jar", + "unicopia:storm_cloud_jar" + ] +} diff --git a/src/main/resources/data/unicopia/tags/items/cloud_slabs.json b/src/main/resources/data/unicopia/tags/items/cloud_slabs.json index f928fc55..a7337a0e 100644 --- a/src/main/resources/data/unicopia/tags/items/cloud_slabs.json +++ b/src/main/resources/data/unicopia/tags/items/cloud_slabs.json @@ -3,6 +3,7 @@ "values": [ "unicopia:cloud_slab", "unicopia:dense_cloud_slab", - "unicopia:cloud_planks_slab" + "unicopia:etched_cloud_slab", + "unicopia:cloud_plank_slab" ] } diff --git a/src/main/resources/data/unicopia/tags/items/cloud_stairs.json b/src/main/resources/data/unicopia/tags/items/cloud_stairs.json index 59c6c75c..cbbba0dc 100644 --- a/src/main/resources/data/unicopia/tags/items/cloud_stairs.json +++ b/src/main/resources/data/unicopia/tags/items/cloud_stairs.json @@ -3,6 +3,7 @@ "values": [ "unicopia:cloud_stairs", "unicopia:dense_cloud_stairs", - "unicopia:cloud_planks_stairs" + "unicopia:etched_cloud_stairs", + "unicopia:cloud_plank_stairs" ] } diff --git a/src/main/resources/data/unicopia/tags/items/clouds.json b/src/main/resources/data/unicopia/tags/items/clouds.json index f3922795..7fe9a915 100644 --- a/src/main/resources/data/unicopia/tags/items/clouds.json +++ b/src/main/resources/data/unicopia/tags/items/clouds.json @@ -1,9 +1,13 @@ { "replace": false, "values": [ + "unicopia:cloud_lump", "unicopia:cloud", "unicopia:cloud_planks", + "unicopia:cloud_bricks", "unicopia:dense_cloud", - "unicopia:unstable_cloud" + "unicopia:etched_cloud", + "unicopia:unstable_cloud", + "unicopia:cloud_door" ] } diff --git a/src/main/resources/data/unicopia/tags/items/cools_off_kirins.json b/src/main/resources/data/unicopia/tags/items/cools_off_kirins.json new file mode 100644 index 00000000..15e752ad --- /dev/null +++ b/src/main/resources/data/unicopia/tags/items/cools_off_kirins.json @@ -0,0 +1,9 @@ +{ + "replace": false, + "values": [ + "minecraft:melon_slice", + "unicopia:juice", + { "id": "farmersdelight:melon_popsicle", "required": false }, + { "id": "farmersdelight:melon_juice", "required": false } + ] +} diff --git a/src/main/resources/data/unicopia/tags/items/floats_on_clouds.json b/src/main/resources/data/unicopia/tags/items/floats_on_clouds.json index 76585449..189ac69b 100644 --- a/src/main/resources/data/unicopia/tags/items/floats_on_clouds.json +++ b/src/main/resources/data/unicopia/tags/items/floats_on_clouds.json @@ -5,7 +5,6 @@ "#unicopia:cloud_slabs", "#unicopia:cloud_stairs", "#unicopia:cloud_beds", - "unicopia:cloud_planks_slab", "unicopia:cloud_pillar" ] } diff --git a/src/main/resources/data/unicopia/tags/items/food_types/candy.json b/src/main/resources/data/unicopia/tags/items/food_types/candy.json new file mode 100644 index 00000000..8a152f67 --- /dev/null +++ b/src/main/resources/data/unicopia/tags/items/food_types/candy.json @@ -0,0 +1,10 @@ +{ + "replace": false, + "values": [ + "unicopia:rock_candy", + "unicopia:candied_apple", + "minecraft:sugar", + { "id": "bakersdelight:sweet_berry_cheesecake_slice", "required": false }, + { "id": "bakersdelight:cake_slice", "required": false } + ] +} diff --git a/src/main/resources/data/unicopia/tags/items/food_types/cooked_sea_vegitable.json b/src/main/resources/data/unicopia/tags/items/food_types/cooked_sea_vegitable.json new file mode 100644 index 00000000..30ffdfce --- /dev/null +++ b/src/main/resources/data/unicopia/tags/items/food_types/cooked_sea_vegitable.json @@ -0,0 +1,8 @@ +{ + "replace": false, + "values": [ + "minecraft:dried_kelp_block", + "minecraft:glow_lichen", + "#c:coral_blocks" + ] +} diff --git a/src/main/resources/data/unicopia/tags/items/food_types/desserts.json b/src/main/resources/data/unicopia/tags/items/food_types/desserts.json new file mode 100644 index 00000000..0e14adc0 --- /dev/null +++ b/src/main/resources/data/unicopia/tags/items/food_types/desserts.json @@ -0,0 +1,8 @@ +{ + "replace": false, + "values": [ + "minecraft:cake", + "#unicopia:pies", + { "id": "bakersdelight:sweet_berry_cheesecake", "required": false } + ] +} diff --git a/src/main/resources/data/unicopia/tags/items/food_types/raw_sea_vegitable.json b/src/main/resources/data/unicopia/tags/items/food_types/raw_sea_vegitable.json new file mode 100644 index 00000000..c570e4a4 --- /dev/null +++ b/src/main/resources/data/unicopia/tags/items/food_types/raw_sea_vegitable.json @@ -0,0 +1,14 @@ +{ + "replace": false, + "values": [ + "minecraft:kelp", + "minecraft:dried_kelp", + "minecraft:seagrass", + "minecraft:sea_pickle", + "#c:corals", + "#c:coral_fans", + { "id": "farmersdelight:melon_popsicle", "required": false }, + { "id": "farmersdelight:kelp_roll", "required": false }, + { "id": "farmersdelight:kelp_roll_slice", "required": false } + ] +} diff --git a/src/main/resources/data/c/tags/items/pineapple.json b/src/main/resources/data/unicopia/tags/items/food_types/rocks.json similarity index 62% rename from src/main/resources/data/c/tags/items/pineapple.json rename to src/main/resources/data/unicopia/tags/items/food_types/rocks.json index 60c5a61e..229f317a 100644 --- a/src/main/resources/data/c/tags/items/pineapple.json +++ b/src/main/resources/data/unicopia/tags/items/food_types/rocks.json @@ -1,6 +1,6 @@ { "replace": false, "values": [ - "unicopia:pineapple" + "unicopia:rock_stew" ] } diff --git a/src/main/resources/data/unicopia/tags/items/food_types/shells.json b/src/main/resources/data/unicopia/tags/items/food_types/shells.json new file mode 100644 index 00000000..d62b7052 --- /dev/null +++ b/src/main/resources/data/unicopia/tags/items/food_types/shells.json @@ -0,0 +1,11 @@ +{ + "replace": false, + "values": [ + "minecraft:nautilus_shell", + "unicopia:clam_shell", + "unicopia:scallop_shell", + "unicopia:turret_shell", + "minecraft:seagrass", + "minecraft:sea_pickle" + ] +} diff --git a/src/main/resources/data/c/tags/items/banana.json b/src/main/resources/data/unicopia/tags/items/food_types/shelly.json similarity index 65% rename from src/main/resources/data/c/tags/items/banana.json rename to src/main/resources/data/unicopia/tags/items/food_types/shelly.json index f2e0bcc6..f8790589 100644 --- a/src/main/resources/data/c/tags/items/banana.json +++ b/src/main/resources/data/unicopia/tags/items/food_types/shelly.json @@ -1,6 +1,6 @@ { "replace": false, "values": [ - "unicopia:banana" + "unicopia:shelly" ] } diff --git a/src/main/resources/data/unicopia/tags/items/groups/changeling.json b/src/main/resources/data/unicopia/tags/items/groups/changeling.json index cea725a9..3cc31831 100644 --- a/src/main/resources/data/unicopia/tags/items/groups/changeling.json +++ b/src/main/resources/data/unicopia/tags/items/groups/changeling.json @@ -11,6 +11,7 @@ "unicopia:chitin_spikes", "unicopia:mysterious_egg", "unicopia:hive", + "unicopia:dark_oak_stable_door", "#unicopia:food_types/cooked_meat", "#unicopia:food_types/raw_meat", "#unicopia:food_types/raw_insect", diff --git a/src/main/resources/data/unicopia/tags/items/groups/earth_pony.json b/src/main/resources/data/unicopia/tags/items/groups/earth_pony.json index be47a5df..54ec96ce 100644 --- a/src/main/resources/data/unicopia/tags/items/groups/earth_pony.json +++ b/src/main/resources/data/unicopia/tags/items/groups/earth_pony.json @@ -10,6 +10,8 @@ "unicopia:stripped_zap_log", "unicopia:stripped_zap_wood", "unicopia:candied_apple", + "unicopia:stable_door", + "unicopia:dark_oak_stable_door", "minecraft:apple", "unicopia:green_apple", "unicopia:sweet_apple", @@ -61,6 +63,8 @@ "unicopia:apple_pie_slice", "unicopia:weather_vane", "#unicopia:baskets", - "unicopia:giant_balloon" + "unicopia:giant_balloon", + "unicopia:cloth_bed", + "#unicopia:bed_sheets" ] } diff --git a/src/main/resources/data/unicopia/tags/items/groups/pegasus.json b/src/main/resources/data/unicopia/tags/items/groups/pegasus.json index 6353ea9d..b76a934d 100644 --- a/src/main/resources/data/unicopia/tags/items/groups/pegasus.json +++ b/src/main/resources/data/unicopia/tags/items/groups/pegasus.json @@ -1,17 +1,29 @@ { "replace": false, "values": [ + "unicopia:shaping_bench", + "unicopia:cloud_chest", + "unicopia:cloud_lump", "unicopia:cloud", "unicopia:cloud_slab", "unicopia:cloud_stairs", "unicopia:cloud_planks", - "unicopia:cloud_planks_slab", - "unicopia:cloud_planks_stairs", + "unicopia:cloud_plank_slab", + "unicopia:cloud_plank_stairs", + "unicopia:cloud_bricks", + "unicopia:cloud_brick_slab", + "unicopia:cloud_brick_stairs", "unicopia:dense_cloud", "unicopia:dense_cloud_slab", "unicopia:dense_cloud_stairs", + "unicopia:etched_cloud", + "unicopia:etched_cloud_slab", + "unicopia:etched_cloud_stairs", "unicopia:unstable_cloud", "unicopia:cloud_pillar", + "unicopia:cloud_door", + "unicopia:cloud_bed", + "#unicopia:bed_sheets", "#unicopia:food_types/raw_fish", "#unicopia:food_types/cooked_fish", "unicopia:rain_cloud_jar", diff --git a/src/main/resources/data/unicopia/tags/items/groups/sea_pony.json b/src/main/resources/data/unicopia/tags/items/groups/sea_pony.json new file mode 100644 index 00000000..a9259060 --- /dev/null +++ b/src/main/resources/data/unicopia/tags/items/groups/sea_pony.json @@ -0,0 +1,11 @@ +{ + "replace": false, + "values": [ + "unicopia:pearl_necklace", + "minecraft:nautilus_shell", + "#unicopia:food_types/shells", + "#unicopia:food_types/shelly", + "#unicopia:food_types/raw_sea_vegitable", + "#unicopia:food_types/cooked_sea_vegitable" + ] +} diff --git a/src/main/resources/data/unicopia/tags/items/groups/unicorn.json b/src/main/resources/data/unicopia/tags/items/groups/unicorn.json index bf9762e2..79b0cb95 100644 --- a/src/main/resources/data/unicopia/tags/items/groups/unicorn.json +++ b/src/main/resources/data/unicopia/tags/items/groups/unicorn.json @@ -1,16 +1,17 @@ { "replace": false, "values": [ + "unicopia:spellbook", + "unicopia:gemstone", + "unicopia:botched_gem", "unicopia:friendship_bracelet", "unicopia:crystal_heart", "unicopia:crystal_shard", - "unicopia:gemstone", - "unicopia:botched_gem", - "unicopia:magic_staff", - "unicopia:dragon_breath_scroll", - "unicopia:spellbook", + "unicopia:crystal_door", "unicopia:meadowbrooks_staff", + "unicopia:magic_staff", "unicopia:grogars_bell", + "unicopia:dragon_breath_scroll", "unicopia:pegasus_amulet", "unicopia:alicorn_amulet", "unicopia:broken_alicorn_amulet", diff --git a/src/main/resources/data/unicopia/tags/items/loot_bug_high_value_drops.json b/src/main/resources/data/unicopia/tags/items/loot_bug_high_value_drops.json new file mode 100644 index 00000000..38c39b74 --- /dev/null +++ b/src/main/resources/data/unicopia/tags/items/loot_bug_high_value_drops.json @@ -0,0 +1,28 @@ +{ + "replace": false, + "values": [ + "minecraft:diamond", + "minecraft:gold_nugget", + "minecraft:iron_nugget", + "#c:gold_ingots", + "#c:raw_gold_ores", + "#c:raw_gold_blocks", + "minecraft:golden_apple", + "minecraft:golden_carrot", + "minecraft:golden_boots", + "minecraft:golden_leggings", + "minecraft:golden_chestplate", + "minecraft:golden_helmet", + "minecraft:golden_horse_armor", + "unicopia:golden_horse_shoe", + "minecraft:golden_pickaxe", + "minecraft:golden_axe", + "minecraft:golden_shovel", + "minecraft:golden_sword", + "minecraft:golden_hoe", + "unicopia:golden_polearm", + "unicopia:golden_feather", + "unicopia:golden_wing", + { "id": "farmersdelight:golden_knife", "required": false } + ] +} diff --git a/src/main/resources/data/unicopia/worldgen/processor_list/cloud_decay.json b/src/main/resources/data/unicopia/worldgen/processor_list/cloud_decay.json new file mode 100644 index 00000000..960c5ea5 --- /dev/null +++ b/src/main/resources/data/unicopia/worldgen/processor_list/cloud_decay.json @@ -0,0 +1,37 @@ +[ + { + "processor_type": "minecraft:rule", + "rules": [ + { + "location_predicate": { + "predicate_type": "always_true" + }, + "input_predicate": { + "predicate_type": "random_block_match", + "block": "unicopia:cloud", + "probability": 0.2 + }, + "output_state": { + "name": "unicopia:unstable_cloud", + "Name": "unicopia:unstable_cloud", + "properties": [] + } + }, + { + "location_predicate": { + "predicate_type": "always_true" + }, + "input_predicate": { + "predicate_type": "random_block_match", + "block": "unicopia:cloud", + "probability": 0.2 + }, + "output_state": { + "name": "unicopia:dense_cloud", + "Name": "unicopia:dense_cloud", + "properties": [] + } + } + ] + } +] \ No newline at end of file diff --git a/src/main/resources/data/unicopia/worldgen/structure/cloud_continent.json b/src/main/resources/data/unicopia/worldgen/structure/cloud_continent.json new file mode 100644 index 00000000..8651ff36 --- /dev/null +++ b/src/main/resources/data/unicopia/worldgen/structure/cloud_continent.json @@ -0,0 +1,27 @@ +{ + "type": "minecraft:jigsaw", + "biomes": "#minecraft:is_overworld", + "max_distance_from_center": 80, + "project_start_to_heightmap": "WORLD_SURFACE_WG", + "size": 6, + "spawn_overrides": { + "ambient": { + "bounding_box": "full", + "spawns": [ + { + "type": "unicopia:storm_cloud", + "weight": 3, + "minCount": 2, + "maxCount": 8 + } + ] + } + }, + "start_height": { + "absolute": 180 + }, + "start_pool": "unicopia:cloud_island/large/b", + "step": "surface_structures", + "terrain_adaptation": "none", + "use_expansion_hack": true +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/worldgen/structure/cloud_village.json b/src/main/resources/data/unicopia/worldgen/structure/cloud_village.json new file mode 100644 index 00000000..06894644 --- /dev/null +++ b/src/main/resources/data/unicopia/worldgen/structure/cloud_village.json @@ -0,0 +1,15 @@ +{ + "type": "minecraft:jigsaw", + "biomes": "#minecraft:is_overworld", + "max_distance_from_center": 80, + "project_start_to_heightmap": "WORLD_SURFACE_WG", + "size": 6, + "spawn_overrides": {}, + "start_height": { + "absolute": 180 + }, + "start_pool": "unicopia:clouds/start", + "step": "surface_structures", + "terrain_adaptation": "none", + "use_expansion_hack": true +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/worldgen/structure/floating_island.json b/src/main/resources/data/unicopia/worldgen/structure/floating_island.json new file mode 100644 index 00000000..4a2d3351 --- /dev/null +++ b/src/main/resources/data/unicopia/worldgen/structure/floating_island.json @@ -0,0 +1,15 @@ +{ + "type": "minecraft:jigsaw", + "biomes": "#minecraft:is_overworld", + "max_distance_from_center": 80, + "project_start_to_heightmap": "WORLD_SURFACE_WG", + "size": 6, + "spawn_overrides": {}, + "start_height": { + "absolute": 180 + }, + "start_pool": "unicopia:clouds/start", + "step": "surface_structures", + "terrain_adaptation": "beard_thin", + "use_expansion_hack": true +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/worldgen/structure_set/clouds.json b/src/main/resources/data/unicopia/worldgen/structure_set/clouds.json new file mode 100644 index 00000000..e0ec0876 --- /dev/null +++ b/src/main/resources/data/unicopia/worldgen/structure_set/clouds.json @@ -0,0 +1,22 @@ +{ + "placement": { + "type": "minecraft:random_spread", + "salt": 54138171, + "separation": 2, + "spacing": 10 + }, + "structures": [ + { + "structure": "unicopia:cloud_village", + "weight": 90 + }, + { + "structure": "unicopia:floating_island", + "weight": 1 + }, + { + "structure": "unicopia:cloud_continent", + "weight": 5 + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/a.json b/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/a.json new file mode 100644 index 00000000..79e09506 --- /dev/null +++ b/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/a.json @@ -0,0 +1,14 @@ +{ + "elements": [ + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:cloud_islands/continent/a", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + } + ], + "fallback": "minecraft:empty" +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/b.json b/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/b.json new file mode 100644 index 00000000..cddbf2ff --- /dev/null +++ b/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/b.json @@ -0,0 +1,14 @@ +{ + "elements": [ + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:cloud_islands/continent/b", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + } + ], + "fallback": "minecraft:empty" +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/c.json b/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/c.json new file mode 100644 index 00000000..aeb20c28 --- /dev/null +++ b/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/c.json @@ -0,0 +1,14 @@ +{ + "elements": [ + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:cloud_islands/continent/c", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + } + ], + "fallback": "minecraft:empty" +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/d.json b/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/d.json new file mode 100644 index 00000000..c4871c78 --- /dev/null +++ b/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/d.json @@ -0,0 +1,14 @@ +{ + "elements": [ + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:cloud_islands/continent/d", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + } + ], + "fallback": "minecraft:empty" +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/e.json b/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/e.json new file mode 100644 index 00000000..e1126c4b --- /dev/null +++ b/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/e.json @@ -0,0 +1,14 @@ +{ + "elements": [ + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:cloud_islands/continent/e", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + } + ], + "fallback": "minecraft:empty" +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/f.json b/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/f.json new file mode 100644 index 00000000..a59eb06e --- /dev/null +++ b/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/f.json @@ -0,0 +1,14 @@ +{ + "elements": [ + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:cloud_islands/continent/f", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + } + ], + "fallback": "minecraft:empty" +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/g.json b/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/g.json new file mode 100644 index 00000000..e389a898 --- /dev/null +++ b/src/main/resources/data/unicopia/worldgen/template_pool/cloud_island/large/g.json @@ -0,0 +1,14 @@ +{ + "elements": [ + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:cloud_islands/continent/g", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + } + ], + "fallback": "minecraft:empty" +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/worldgen/template_pool/cloud_islands/blobs.json b/src/main/resources/data/unicopia/worldgen/template_pool/cloud_islands/blobs.json new file mode 100644 index 00000000..36e4ec55 --- /dev/null +++ b/src/main/resources/data/unicopia/worldgen/template_pool/cloud_islands/blobs.json @@ -0,0 +1,14 @@ +{ + "elements": [ + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:cloud_islands/blobs/blob_1", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + } + ], + "fallback": "minecraft:empty" +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/worldgen/template_pool/cloud_islands/surfaces.json b/src/main/resources/data/unicopia/worldgen/template_pool/cloud_islands/surfaces.json new file mode 100644 index 00000000..07eeb051 --- /dev/null +++ b/src/main/resources/data/unicopia/worldgen/template_pool/cloud_islands/surfaces.json @@ -0,0 +1,32 @@ +{ + "elements": [ + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:cloud_islands/surfaces/surface_1", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:cloud_islands/surfaces/surface_2", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:cloud_islands/surfaces/surface_3", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + } + ], + "fallback": "minecraft:empty" +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/worldgen/template_pool/clouds/decorations.json b/src/main/resources/data/unicopia/worldgen/template_pool/clouds/decorations.json new file mode 100644 index 00000000..d7d6c455 --- /dev/null +++ b/src/main/resources/data/unicopia/worldgen/template_pool/clouds/decorations.json @@ -0,0 +1,60 @@ +{ + "elements": [ + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/pillars/pillar_1", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/pillars/pillar_2", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/pillars/pillar_3", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/pillars/pillar_4", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/pillars/well", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 1 + } + ], + "fallback": "minecraft:empty" +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/worldgen/template_pool/clouds/houses.json b/src/main/resources/data/unicopia/worldgen/template_pool/clouds/houses.json new file mode 100644 index 00000000..5aa3ca94 --- /dev/null +++ b/src/main/resources/data/unicopia/worldgen/template_pool/clouds/houses.json @@ -0,0 +1,38 @@ +{ + "elements": [ + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/village/house_1", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 4 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/village/house_2", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 6 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/village/house_3", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 1 + } + ], + "fallback": "minecraft:empty" +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/worldgen/template_pool/clouds/natural.json b/src/main/resources/data/unicopia/worldgen/template_pool/clouds/natural.json new file mode 100644 index 00000000..d401792e --- /dev/null +++ b/src/main/resources/data/unicopia/worldgen/template_pool/clouds/natural.json @@ -0,0 +1,131 @@ +{ + "elements": [ + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/small_1", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/small_2", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/small_3", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/medium_1", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/medium_2", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/large_1", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/large_2", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/large_3", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/junction_1", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/junction_2", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/junction_3", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/junction_4", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/junction_5", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/pillar_boat", + "processors": "unicopia:cloud_decay", + "projection": "rigid" + }, + "weight": 1 + } + ], + "fallback": "minecraft:empty" +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/worldgen/template_pool/clouds/pillars.json b/src/main/resources/data/unicopia/worldgen/template_pool/clouds/pillars.json new file mode 100644 index 00000000..c92e0cd2 --- /dev/null +++ b/src/main/resources/data/unicopia/worldgen/template_pool/clouds/pillars.json @@ -0,0 +1,49 @@ +{ + "elements": [ + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/pillars/pillar_1", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/pillars/pillar_2", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/pillars/pillar_3", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/pillars/pillar_4", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 1 + } + ], + "fallback": "minecraft:empty" +} \ No newline at end of file diff --git a/src/main/resources/data/unicopia/worldgen/template_pool/clouds/start.json b/src/main/resources/data/unicopia/worldgen/template_pool/clouds/start.json new file mode 100644 index 00000000..2b5136d1 --- /dev/null +++ b/src/main/resources/data/unicopia/worldgen/template_pool/clouds/start.json @@ -0,0 +1,93 @@ +{ + "elements": [ + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/small_1", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/small_2", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/small_3", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/medium_1", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/medium_2", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/large_1", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/large_2", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 1 + }, + { + "element": { + "element_type": "minecraft:single_pool_element", + "location": "unicopia:clouds/large_3", + "processors": { + "processors": [] + }, + "projection": "rigid" + }, + "weight": 1 + } + ], + "fallback": "minecraft:empty" +} \ No newline at end of file diff --git a/src/main/resources/data/unicopiamc/loot_tables/archaeology/desert_well.json b/src/main/resources/data/unicopiamc/loot_tables/archaeology/desert_well.json index 25d4fc53..c6c149e1 100644 --- a/src/main/resources/data/unicopiamc/loot_tables/archaeology/desert_well.json +++ b/src/main/resources/data/unicopiamc/loot_tables/archaeology/desert_well.json @@ -28,6 +28,23 @@ "type": "minecraft:item", "name": "unicopia:pebbles", "weight": 1 + }, + { + "type": "minecraft:item", + "name": "unicopia:shelly", + "weight": 1 + }, + { + "type": "minecraft:tag", + "name": "unicopia:food_types/shells", + "expand": true, + "weight": 2 + }, + { + "type": "minecraft:tag", + "name": "unicopia:food_types/pearl_necklace", + "expand": true, + "weight": 1 } ], "rolls": 1.0 diff --git a/src/main/resources/data/unicopiamc/loot_tables/chests/buried_treasure.json b/src/main/resources/data/unicopiamc/loot_tables/chests/buried_treasure.json new file mode 100644 index 00000000..d94e9dc6 --- /dev/null +++ b/src/main/resources/data/unicopiamc/loot_tables/chests/buried_treasure.json @@ -0,0 +1,25 @@ +{ + "type": "minecraft:chest", + "pools": [ + { + "rolls": { + "min": 1.0, + "max": 4.0, + "type": "minecraft:uniform" + }, + "entries": [ + { + "type": "minecraft:item", + "weight": 1, + "name": "unicopia:pearl_necklace" + }, + { + "type": "minecraft:tag", + "weight": 3, + "expand": true, + "name": "unicopia:food_types/shells" + } + ] + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopiamc/loot_tables/chests/shipwreck_supply.json b/src/main/resources/data/unicopiamc/loot_tables/chests/shipwreck_supply.json new file mode 100644 index 00000000..4181ec0e --- /dev/null +++ b/src/main/resources/data/unicopiamc/loot_tables/chests/shipwreck_supply.json @@ -0,0 +1,20 @@ +{ + "type": "minecraft:chest", + "pools": [ + { + "rolls": { + "min": 1.0, + "max": 6.0, + "type": "minecraft:uniform" + }, + "entries": [ + { + "type": "minecraft:tag", + "weight": 3, + "expand": true, + "name": "unicopia:food_types/shells" + } + ] + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopiamc/loot_tables/chests/shipwreck_treasure.json b/src/main/resources/data/unicopiamc/loot_tables/chests/shipwreck_treasure.json new file mode 100644 index 00000000..d94e9dc6 --- /dev/null +++ b/src/main/resources/data/unicopiamc/loot_tables/chests/shipwreck_treasure.json @@ -0,0 +1,25 @@ +{ + "type": "minecraft:chest", + "pools": [ + { + "rolls": { + "min": 1.0, + "max": 4.0, + "type": "minecraft:uniform" + }, + "entries": [ + { + "type": "minecraft:item", + "weight": 1, + "name": "unicopia:pearl_necklace" + }, + { + "type": "minecraft:tag", + "weight": 3, + "expand": true, + "name": "unicopia:food_types/shells" + } + ] + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopiamc/loot_tables/chests/underwater_ruin_big.json b/src/main/resources/data/unicopiamc/loot_tables/chests/underwater_ruin_big.json new file mode 100644 index 00000000..a4eea670 --- /dev/null +++ b/src/main/resources/data/unicopiamc/loot_tables/chests/underwater_ruin_big.json @@ -0,0 +1,30 @@ +{ + "type": "minecraft:chest", + "pools": [ + { + "rolls": { + "min": 1.0, + "max": 2.0, + "type": "minecraft:uniform" + }, + "entries": [ + { + "type": "minecraft:item", + "weight": 1, + "name": "unicopia:pearl_necklace" + }, + { + "type": "minecraft:item", + "weight": 4, + "name": "unicopia:shelly" + }, + { + "type": "minecraft:tag", + "weight": 8, + "expand": true, + "name": "unicopia:food_types/shells" + } + ] + } + ] +} \ No newline at end of file diff --git a/src/main/resources/data/unicopiamc/loot_tables/chests/underwater_ruin_small.json b/src/main/resources/data/unicopiamc/loot_tables/chests/underwater_ruin_small.json new file mode 100644 index 00000000..31d47b83 --- /dev/null +++ b/src/main/resources/data/unicopiamc/loot_tables/chests/underwater_ruin_small.json @@ -0,0 +1,20 @@ +{ + "type": "minecraft:chest", + "pools": [ + { + "rolls": { + "min": 1.0, + "max": 4.0, + "type": "minecraft:uniform" + }, + "entries": [ + { + "type": "minecraft:tag", + "weight": 1, + "expand": true, + "name": "unicopia:food_types/shells" + } + ] + } + ] +} \ No newline at end of file diff --git a/src/main/resources/unicopia.mixin.json b/src/main/resources/unicopia.mixin.json index 95738783..d8654fc3 100644 --- a/src/main/resources/unicopia.mixin.json +++ b/src/main/resources/unicopia.mixin.json @@ -17,14 +17,17 @@ "MixinChunkBlockLightProvider", "MutableBlockLightStorage", "MixinDamageSource", + "MixinEnchantmentHelper", "MixinFallLocation", "MixinEntity", "MixinEntityShapeContext", "MixinFallingBlock", "MixinFallingBlockEntity", "MixinFlowableFluid", + "MixinGuardianTargetPredicate", "MixinItem", "MixinItemEntity", + "MixinItemStack", "MixinLivingEntity", "MixinMilkBucketItem", "MixinMobEntity", @@ -34,6 +37,7 @@ "MixinPlayerManager", "MixinPowderSnowBlock", "MixinProjectileEntity", + "MixinPufferfishEntity", "MixinServerPlayerEntity", "MixinServerPlayNetworkHandler", "MixinServerWorld", @@ -57,6 +61,7 @@ "client": [ "client.MixinAnimalModel", "client.MixinArmorFeatureRenderer", + "client.MixinBackgroundRenderer", "client.MixinCamera", "client.MixinClientWorld", "client.MixinEntityRenderDispatcher", @@ -64,8 +69,8 @@ "client.MixinHeldItemRenderer", "client.MixinInGameHud", "client.MixinInGameHud$HeartType", - "client.MixinItem", "client.MixinItemModels", + "client.MixinItemStack", "client.MixinKeyboardInput", "client.MixinLivingEntityRenderer", "client.MixinModelPart", @@ -75,6 +80,7 @@ "client.MixinTranslationStorage", "client.MixinWorldRenderer", "client.sodium.MixinSodiumWorldRenderer", + "client.minelp.MixinPonyPosture", "trinkets.MixinTrinketCreativeSlot" ], "injectors": {