Skip to content

Commit

Permalink
fix hunter hat and hunter npc equipment
Browse files Browse the repository at this point in the history
remove custom hunter equipment layer
  • Loading branch information
Cheaterpaul committed Nov 13, 2023
1 parent f28821d commit fdb1f98
Show file tree
Hide file tree
Showing 35 changed files with 908 additions and 331 deletions.
1 change: 1 addition & 0 deletions dev_resources/models/hunter_hat_0.bbmodel
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"meta":{"format_version":"4.5","model_format":"modded_entity","box_uv":true},"name":"hunter_hat_0","model_identifier":"","modded_entity_version":"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":"base","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-6,7,-6],"to":[6,8,6],"autouv":0,"color":1,"origin":[0,7,0],"faces":{"north":{"uv":[12,12,24,13],"texture":0},"east":{"uv":[0,12,12,13],"texture":0},"south":{"uv":[36,12,48,13],"texture":0},"west":{"uv":[24,12,36,13],"texture":0},"up":{"uv":[24,12,12,0],"texture":0},"down":{"uv":[36,0,24,12],"texture":0}},"type":"cube","uuid":"a5c5cc8b-f51c-827d-22b3-71211579c36f"},{"name":"top","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-4,8,-4],"to":[4,13,4],"autouv":0,"color":1,"origin":[0,7,0],"uv_offset":[0,13],"faces":{"north":{"uv":[8,21,16,26],"texture":0},"east":{"uv":[0,21,8,26],"texture":0},"south":{"uv":[24,21,32,26],"texture":0},"west":{"uv":[16,21,24,26],"texture":0},"up":{"uv":[16,21,8,13],"texture":0},"down":{"uv":[24,13,16,21],"texture":0}},"type":"cube","uuid":"b939058b-dcac-b765-a176-dcee112ee0c8"}],"outliner":[{"name":"base","origin":[0,0,0],"color":0,"uuid":"a7333056-0cf6-b839-c6d1-ce42a9141e94","export":true,"mirror_uv":false,"isOpen":true,"locked":false,"visibility":true,"autouv":0,"children":["a5c5cc8b-f51c-827d-22b3-71211579c36f",{"name":"top","origin":[0,0,0],"color":0,"uuid":"39d3e81b-72d5-cca0-1e78-605018656aac","export":true,"mirror_uv":false,"isOpen":true,"locked":false,"visibility":true,"autouv":0,"children":["b939058b-dcac-b765-a176-dcee112ee0c8"]}]}],"textures":[{"path":"/home/paube/Desktop/hunter_hat_0.png","name":"hunter_hat_0.png","folder":"","namespace":"","id":"1","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":false,"uuid":"f0c63af7-c93b-b9f6-525a-ba0f62c150db","source":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAAAXNSR0IArs4c6QAAAARzQklUCAgICHwIZIgAAAJ6SURBVHhe7VnBSsNAELWIoaB40IKKUtGDJ///Mzx5qqBYFBXUgyhIPNRM8IXpsNlJXGi70+mlLTOb7HvzdualHWz0fO3tj2a0pCiGG8VWUa8uf8r6nX8vy++5K3fNf397HfTcUlJ675sRATvbuw3oEFCQ8fn1UW+O5z8/Pcxt+PDopCGP8leegGrDtQKu7+6jzF+enc7FiagKXHBNRWqtKHpVBPUuSooEet+MCCAwk8eX6H0vjg8aUDHwuAhIcAJcAYaOAJpf1yNA+dPpbe9judAeMB6fz2jsdWmCfCzK7i83TdOA8rMggMZV1yZIoDAOY1MA3iKLJvjfMUjrJAnU/QE+mzGIqsLdcSdIn+nMc/PTJz8bBUjrG/ouz3nMOiN34QTA23MZdgWDysMOw80RUMQ4CZIAxKSdDnV1unYoL9U6qyMH1peTQp8BUJsGo+Gmeo+UMZa6Vt0cxh6vHq/wWhCAiodIWCsCQuf5anITVaHZIwDUa0MAmiA1P/QAejdPAKYAzj+fAF0cYfZHgAjg4JvZ/fc7YPZNsK3C0szw722xNpVIY8XXL9r5yY49QIVxtnmC9PhtXiAEkB8V3jPk9VeCgFiFsGENPCeQN0pt/dIJoGcB7uF55aTHl/IJxbm8u8RTvXyyFeZ/dMzJU/yxwR+WQg8lIDH2gIMcvn7pBKQymPt69WEod4Da/p0AjSHrcVeA9Qpr+FwBGkPW464A6xXW8LkCNIasx10B1ius4XMFaAxZj7sCrFdYw+cK0BiyHncFWK+whs8VoDFkPe4KsF5hDZ8rQGPIetwVYL3CGj5XgMaQ9bgrwHqFNXyuAI0h63FXgPUKa/h+Ae/zxFCn6/JsAAAAAElFTkSuQmCC","relative_path":"../hunter_hat_0.png"}]}
1 change: 1 addition & 0 deletions dev_resources/models/hunter_hat_0_item.bbmodel
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"meta":{"format_version":"4.5","model_format":"java_block","box_uv":false},"name":"hunter_hat_1_item","parent":"","ambientocclusion":true,"front_gui_light":false,"visible_box":[1,1,0],"variable_placeholders":"","variable_placeholder_buttons":[],"unhandled_root_fields":{},"resolution":{"width":64,"height":64},"elements":[{"name":"bottom_small","box_uv":false,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[2,0,2],"to":[14,1,14],"autouv":0,"color":1,"origin":[0,0,0],"faces":{"north":{"uv":[12,12,24,13],"texture":0},"east":{"uv":[0,12,12,13],"texture":0},"south":{"uv":[24,12,36,13],"texture":0},"west":{"uv":[36,12,48,13],"texture":0},"up":{"uv":[24,12,12,0],"texture":0},"down":{"uv":[36,0,24,12],"texture":0}},"type":"cube","uuid":"168e8025-007d-d132-488e-64e196f8710e"},{"name":"top_high","box_uv":false,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[4,1,4],"to":[12,6,12],"autouv":0,"color":1,"origin":[0,0,0],"faces":{"north":{"uv":[8,21,16,26],"texture":0},"east":{"uv":[0,21,8,26],"texture":0},"south":{"uv":[24,21,32,26],"texture":0},"west":{"uv":[16,21,24,26],"texture":0},"up":{"uv":[16,21,8,13],"texture":0},"down":{"uv":[24,13,16,21],"texture":0}},"type":"cube","uuid":"1ed98f79-9839-2b20-5104-425390509ccc"}],"outliner":[{"name":"hunter_hat_0","origin":[0,0,0],"color":0,"uuid":"13b314d6-873a-af96-986f-936509614d7b","export":true,"mirror_uv":false,"isOpen":true,"locked":false,"visibility":true,"autouv":0,"children":["168e8025-007d-d132-488e-64e196f8710e","1ed98f79-9839-2b20-5104-425390509ccc"]}],"textures":[{"path":"/home/paube/Desktop/hunter_hat_head_0.png","name":"hunter_hat_head_0.png","folder":"","namespace":"","id":"0","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":"e4cd367a-2bde-1b90-f496-913c948a39b3","relative_path":"../hunter_hat_head_0.png","source":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAAAXNSR0IArs4c6QAAAARzQklUCAgICHwIZIgAAAJ6SURBVHhe7VnBSsNAELWIoaB40IKKUtGDJ///Mzx5qqBYFBXUgyhIPNRM8IXpsNlJXGi70+mlLTOb7HvzdualHWz0fO3tj2a0pCiGG8VWUa8uf8r6nX8vy++5K3fNf397HfTcUlJ675sRATvbuw3oEFCQ8fn1UW+O5z8/Pcxt+PDopCGP8leegGrDtQKu7+6jzF+enc7FiagKXHBNRWqtKHpVBPUuSooEet+MCCAwk8eX6H0vjg8aUDHwuAhIcAJcAYaOAJpf1yNA+dPpbe9judAeMB6fz2jsdWmCfCzK7i83TdOA8rMggMZV1yZIoDAOY1MA3iKLJvjfMUjrJAnU/QE+mzGIqsLdcSdIn+nMc/PTJz8bBUjrG/ouz3nMOiN34QTA23MZdgWDysMOw80RUMQ4CZIAxKSdDnV1unYoL9U6qyMH1peTQp8BUJsGo+Gmeo+UMZa6Vt0cxh6vHq/wWhCAiodIWCsCQuf5anITVaHZIwDUa0MAmiA1P/QAejdPAKYAzj+fAF0cYfZHgAjg4JvZ/fc7YPZNsK3C0szw722xNpVIY8XXL9r5yY49QIVxtnmC9PhtXiAEkB8V3jPk9VeCgFiFsGENPCeQN0pt/dIJoGcB7uF55aTHl/IJxbm8u8RTvXyyFeZ/dMzJU/yxwR+WQg8lIDH2gIMcvn7pBKQymPt69WEod4Da/p0AjSHrcVeA9Qpr+FwBGkPW464A6xXW8LkCNIasx10B1ius4XMFaAxZj7sCrFdYw+cK0BiyHncFWK+whs8VoDFkPe4KsF5hDZ8rQGPIetwVYL3CGj5XgMaQ9bgrwHqFNXyuAI0h63FXgPUKa/h+Ae/zxFCn6/JsAAAAAElFTkSuQmCC"}],"display":{"thirdperson_righthand":{"translation":[0,4,0],"scale":[0.5,0.5,0.5]},"thirdperson_lefthand":{"translation":[0,4,0],"scale":[0.5,0.5,0.5]},"firstperson_righthand":{"translation":[0,4,0],"scale":[0.75,0.75,0.75]},"firstperson_lefthand":{"translation":[0,4,0],"scale":[0.75,0.75,0.75]},"ground":{"translation":[0,5,0],"scale":[0.75,0.75,0.75]},"gui":{"rotation":[25,-51,0],"translation":[0,4.25,0],"scale":[0.7,0.7,0.7]},"head":{"translation":[0,18.5,0],"scale":[1.6,1.6,1.6]},"fixed":{"rotation":[-90,0,0],"translation":[0,0,-7],"scale":[0.75,0.75,0.75]}}}
1 change: 1 addition & 0 deletions dev_resources/models/hunter_hat_1.bbmodel
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"meta":{"format_version":"4.5","model_format":"modded_entity","box_uv":true},"name":"hunter_hat_1","model_identifier":"","modded_entity_version":"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":"base","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-8,7,-8],"to":[8,8,8],"autouv":0,"color":1,"origin":[0,7,0],"faces":{"north":{"uv":[16,16,32,17],"texture":0},"east":{"uv":[0,16,16,17],"texture":0},"south":{"uv":[48,16,64,17],"texture":0},"west":{"uv":[32,16,48,17],"texture":0},"up":{"uv":[32,16,16,0],"texture":0},"down":{"uv":[48,0,32,16],"texture":0}},"type":"cube","uuid":"716315f1-0c93-ce1a-736a-c05e21739eef"},{"name":"top","box_uv":true,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[-4,8,-4],"to":[4,11,4],"autouv":0,"color":1,"origin":[0,7,0],"uv_offset":[0,17],"faces":{"north":{"uv":[8,25,16,28],"texture":0},"east":{"uv":[0,25,8,28],"texture":0},"south":{"uv":[24,25,32,28],"texture":0},"west":{"uv":[16,25,24,28],"texture":0},"up":{"uv":[16,25,8,17],"texture":0},"down":{"uv":[24,17,16,25],"texture":0}},"type":"cube","uuid":"8b55e0c1-0d3b-df85-754b-b702a07f42a5"}],"outliner":[{"name":"base","origin":[0,0,0],"color":0,"uuid":"b0b4848d-0652-aa0a-12e0-772da01bd9fb","export":true,"mirror_uv":false,"isOpen":true,"locked":false,"visibility":true,"autouv":0,"children":["716315f1-0c93-ce1a-736a-c05e21739eef",{"name":"top","origin":[0,0,0],"color":0,"uuid":"3f8aa1c7-fa84-80ea-fdd5-2327cf4a689b","export":true,"mirror_uv":false,"isOpen":true,"locked":false,"visibility":true,"autouv":0,"children":["8b55e0c1-0d3b-df85-754b-b702a07f42a5"]}]}],"textures":[{"path":"/home/paube/Desktop/hunter_hat_1.png","name":"hunter_hat_1.png","folder":"block","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":false,"uuid":"92fbf913-7c64-178c-f12a-9a7de5180e2e","source":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAAAXNSR0IArs4c6QAAAARzQklUCAgICHwIZIgAAAMPSURBVHhe7VnBShxBEN1FHASDhyhESVCSQ075/8/wlJOBiIuSBNSDGAiTQzI12Td5W/R0zdDKzJa1l3W3ume7Xr2qetUuF4Wv14dHf/CIqtpr/6x2q/b98efDQr7D5/p33X5f17+Sv6r3Y31u//3d7bLEhaLN8sMCAA4O59gRONGB1ICjgdDrBaDUMwUIBkUAng0AHCX5Ww7Hr1f7B/+i37CAHdTOYg+zpI8ZsmZyAI5P3v1PgXWEchRHFDmaSBsNmqZ2ilnfv10XsbhosxxQAGBnPl9eZVPy0/uzDbuApdkhC5rIbqxrUq37LOvBpMkZcHr6oWOARPDi5kcWgI9v37QO61Tg4qidxwMFBK4N8v3kDOAiKNEcAgA6A0AQQED/PucZhK6gNh1mcgCQAnBgCABtzjeHZ/qPBQD7Z5ECXLzGAgBKo3AOZQBYtFp9LapjRZtZB6D1WQBIEeROgNaIGjAEAGbPLABAFR9aBLkGAAzogXVvTxbSVCeYRQ3g0w5pg8j9MZ0AzjN4s+gCEEIp/c+ylSt+nzzWCpGB7VODkzNA2iCnACKkVV2K9sh73RZ1lHWa8OfJu4AehlISl4cfPeSgJeqJL6um1sZZzAK5cZhpj2rfNyektIEehzFe8zOKGaAdyNGNJWwqQpynnAKpcdfar1mjC2cfQ1Jn4LapU9PUATztdRJ0PfUJWOcXX7JsPdrbMX9jCN2fa415OBl2JBo6R8EUq+1tPQA87gIEVm/uAcC4q3v6i2MAclCng3sG6BQAAHh3XwS11EX+v7gUYP0+5g5w9l0gR/GNYUTdyetUSAGUuwHG+tJhplQfLKHlc9fUUIB6DSRp3z9CcnZcoJRK2ScBgC8ZWQrrh/dNeryfLzb0OJuyTQ5AKYLbvt+UwtvuoHX+AMBCyLs9GOA9wpZ/wQALIe/2YID3CFv+BQMshLzbgwHeI2z5FwywEPJuDwZ4j7DlXzDAQsi7PRjgPcKWf8EACyHv9mCA9whb/gUDLIS824MB3iNs+RcMsBDybg8GeI+w5V8wwELIu/0vwguGl+5p8ToAAAAASUVORK5CYII=","relative_path":"../hunter_hat_1.png"}]}
1 change: 1 addition & 0 deletions dev_resources/models/hunter_hat_1_item.bbmodel
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"meta":{"format_version":"4.5","model_format":"java_block","box_uv":false},"name":"hunter_hat_1_item","parent":"","ambientocclusion":true,"front_gui_light":false,"visible_box":[1,1,0],"variable_placeholders":"","variable_placeholder_buttons":[],"unhandled_root_fields":{},"resolution":{"width":64,"height":64},"elements":[{"name":"bottom_big","box_uv":false,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[0,0,0],"to":[16,1,16],"autouv":0,"color":1,"origin":[0,0,0],"faces":{"north":{"uv":[16,16,32,17],"texture":0},"east":{"uv":[0,16,16,17],"texture":0},"south":{"uv":[48,16,64,17],"texture":0},"west":{"uv":[32,16,48,17],"texture":0},"up":{"uv":[32,16,16,0],"texture":0},"down":{"uv":[48,0,32,16],"texture":0}},"type":"cube","uuid":"ef45cd03-4364-32dd-cb30-d3074cb1846e"},{"name":"top_flat","box_uv":false,"rescale":false,"locked":false,"render_order":"default","allow_mirror_modeling":true,"from":[4,1,4],"to":[12,4,12],"autouv":0,"color":1,"origin":[0,0,0],"faces":{"north":{"uv":[8,25,16,28],"texture":0},"east":{"uv":[0,25,8,28],"texture":0},"south":{"uv":[24,25,32,28],"texture":0},"west":{"uv":[16,25,24,28],"texture":0},"up":{"uv":[16,25,8,17],"texture":0},"down":{"uv":[24,17,16,25],"texture":0}},"type":"cube","uuid":"b13156a6-9345-745a-7baa-330ba90113f9"}],"outliner":[{"name":"hunter_hat_1","origin":[0,0,0],"color":0,"uuid":"593ddaed-7548-079c-92b7-b3929ad0444e","export":true,"mirror_uv":false,"isOpen":true,"locked":false,"visibility":true,"autouv":0,"children":["ef45cd03-4364-32dd-cb30-d3074cb1846e","b13156a6-9345-745a-7baa-330ba90113f9"]}],"textures":[{"path":"/home/paube/Projects/Minecraft/Vampirism/1.20/src/main/resources/assets/vampirism/textures/models/armor/hunter_hat_head_1.png","name":"hunter_hat_head_1.png","folder":"models/armor","namespace":"vampirism","id":"0","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":"a9929aea-1461-97ee-dcf6-46d76bd13be4","relative_path":"../../Projects/Minecraft/Vampirism/1.20/src/main/resources/assets/vampirism/textures/models/armor/hunter_hat_head_1.png","source":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAAAXNSR0IArs4c6QAAAARzQklUCAgICHwIZIgAAAMOSURBVHhe7Vk9S0RBDPQKD0GxUAsFsfD//yYLEbRQC1GQs9DL8805hrzdlSW+cJdrvI/dfclkkkzWxV7n6+T07BNHLJcHw9vl/nL4+/r2siff4fPqYzV8v1q9m0/V+7G+tP/56XHR40LXZnmwAADD4Rw7Aic2IK3B0UDo9QKQdaYAwaAIwGEA4CjJezGOX0eHx9/RX7OAHdTOYg+zZIoZsmZ2AM4vLn9SYIxQieKIIkcTaaNB09S2mPVwf9fF4q7NYqAAwM7UDGLAkDKaHfL9OrK//F+n2uazrAeTZmfA1dX1hgEtOSk1gx3QuW45D88FBF4v39cArxXIbgZwEWzJSawHa2SPAAL668hrB5gJAsbsACAFyIEiqGibYjycR8ssRZ9ZMNSMcX+IFODiVTNIAwBKo3C2MgD64vb2povFXZtZB6D11QDgomkJnBYAmD0hAEAVby2CiJ5Ucq4FRGuzdlmdIEQNYGtrBgkDkPtaFKEtltoggxeiC6CvW/qfZSucRQtk0DQLGAism1KDNcD/pQ1yCiBCWtVZtIej/Buksdb9zBYGrFZz/gUAFieWxOXhxxI+1sRYMxzghQCgRFPu9YjilHNaG+hxGOM1zxrdAOh5XuejVmwlJzhPOQWscdcCwRp2kBK6cJZAHIQSTaQMrE7Nqg7QwwsORwvr7cMtVPdcUwVAhh04O+TdeKsDZvRWYU/nWs6uAmApNwZi6wHAuKsjv3MMAJ10Omw9A3QKsH4XFmx9EdRSF/m/cynA19t/uQNsqcRzrlmUKG4NLFoHcEpsFOF4O1y6AQagc9eQhb6jYyegmjDBaZ0PSTr1j5DS760XKN7sGABgLc/SVz98atLj/SxdfzFovMODLMVvvVq+F6CqEOp9QPT9CUD0CHnblwzwRjj6+cmA6BHyti8Z4I1w9POTAdEj5G1fMsAb4ejnJwOiR8jbvmSAN8LRz08GRI+Qt33JAG+Eo5+fDIgeIW/7kgHeCEc/PxkQPULe9iUDvBGOfn4yIHqEvO1LBngjHP38ZED0CHnbt/MM+AJAeI6X4stu5AAAAABJRU5ErkJggg=="}],"display":{"thirdperson_righthand":{"translation":[0,4,0],"scale":[0.5,0.5,0.5]},"thirdperson_lefthand":{"translation":[0,4,0],"scale":[0.5,0.5,0.5]},"firstperson_righthand":{"translation":[0,4,0],"scale":[0.75,0.75,0.75]},"firstperson_lefthand":{"translation":[0,4,0],"scale":[0.75,0.75,0.75]},"ground":{"translation":[0,5,0],"scale":[0.75,0.75,0.75]},"gui":{"rotation":[25,-51,0],"translation":[0,4.25,0],"scale":[0.7,0.7,0.7]},"head":{"translation":[0,18.5,0],"scale":[1.6,1.6,1.6]},"fixed":{"rotation":[-90,0,0],"translation":[0,0,-7],"scale":[0.75,0.75,0.75]}}}
Original file line number Diff line number Diff line change
Expand Up @@ -13,27 +13,17 @@ public interface IAdvancedHunter extends IHunterMob, IAdjustableLevel, IVillageC
/**
* The type integer declares multiple things about the hunter. This the different values are stored in the different bits of the integer.
* <br>
* - Bits 0-1 are used for the hunter hat<br>
* - Bits 2-3 are used for the hunter hat<br>
* - bit 4 defines if the hunter has a cloak<br>
* - bits 5-13 are used for the hunter body texture<br>
* - bit 0 defines if the hunter has a cloak<br>
* - bits 1-9 are used for the hunter body texture<br>
*/
int getHunterType();

default int getHatType() {
return this.getHunterType() & 0b11;
}

default int getEquipmentType() {
return this.getHunterType() >> 2 & 0b11;
}

default boolean hasCloak() {
return (this.getHunterType() >> 4 & 0b1) == 1;
return (this.getHunterType() & 0b1) == 1;
}

default int getBodyTexture() {
return this.getHunterType() >> 5 & 0b11111111;
return this.getHunterType() >> 1 & 0b11111111;
}

@Nullable
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,23 +23,6 @@ default boolean canUseCrossbow(ItemStack stack){
return true;
}

/**
* current crossbow arm pose to use for rendering
*/
default ArmPose getArmPose() {
if (isHoldingCrossbow()) {
if (isChargingCrossbow()) {
return ArmPose.CROSSBOW_CHARGE;
}
InteractionHand hand = ProjectileUtil.getWeaponHoldingHand(((LivingEntity) this), IVampirismCrossbow.class::isInstance);
ItemStack itemstack = ((LivingEntity) this).getItemInHand(hand);
if (itemstack.getItem() instanceof IVampirismCrossbow && CrossbowItem.isCharged(itemstack)) {
return ArmPose.CROSSBOW_HOLD;
}
}
return ArmPose.NEUTRAL;
}

@Override
default void performCrossbowAttack(@Nonnull LivingEntity entity, float speed) {
InteractionHand hand = ProjectileUtil.getWeaponHoldingHand(entity, IVampirismCrossbow.class::isInstance);
Expand Down

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -115,9 +115,8 @@ static void onRegisterLayers(EntityRenderersEvent.@NotNull RegisterLayerDefiniti
event.registerLayerDefinition(CLOTHING_CROWN, ClothingCrownModel::createLayer);
event.registerLayerDefinition(CLOTHING_PANTS, ClothingPantsModel::createLayer);
event.registerLayerDefinition(CLOTHING_HAT, VampireHatModel::createLayer);
event.registerLayerDefinition(HUNTER_HAT0, () -> HunterHatModel.createLayer(0, 0));
event.registerLayerDefinition(HUNTER_HAT1, () -> HunterHatModel.createLayer(0, 1));
event.registerLayerDefinition(HUNTER_EQUIPMENT, HunterEquipmentModel::createLayer);
event.registerLayerDefinition(HUNTER_HAT0, HunterHatModel::createHat0Layer);
event.registerLayerDefinition(HUNTER_HAT1, HunterHatModel::createHat1Layer);
event.registerLayerDefinition(VILLAGER_WITH_ARMS, () -> VillagerWithArmsModel.createLayer(0));
event.registerLayerDefinition(GENERIC_BIPED, () -> LayerDefinition.create(PlayerModel.createMesh(CubeDeformation.NONE, false), 64, 64));
event.registerLayerDefinition(GENERIC_BIPED_SLIM, () -> LayerDefinition.create(PlayerModel.createMesh(CubeDeformation.NONE, true), 64, 64));
Expand Down
Loading

0 comments on commit fdb1f98

Please sign in to comment.