Compare commits

..

21 commits

Author SHA1 Message Date
Mrbysco
0e3a961257 Re-enable Patchouli support 2024-10-17 00:54:39 +02:00
Mrbysco
82c99e0b56 Update compat mining lens recipes 2024-10-17 00:19:23 +02:00
Mrbysco
3e5561bfb3 Remove unused classes related to removed Smiley Cloud 2024-10-16 23:44:58 +02:00
Mrbysco
b0491d0a3d Remove laser particle todo 2024-10-16 23:41:20 +02:00
Mrbysco
7ad55e116b Remove code relating to removed Treasure Chest 2024-10-16 23:38:21 +02:00
Mrbysco
f40023cfd2 Change tile inventory saving/loading
Using the serializeNBT and deserializeNBT methods from ItemStackHandler
2024-10-16 23:37:31 +02:00
Mrbysco
a117dd5340 Fix placer not working 2024-10-16 23:29:06 +02:00
Mrbysco
8e06e4bcb0 Remove removed Smiley Cloud tile entity class 2024-10-16 23:10:41 +02:00
Mrbysco
b4521321c8 Remove empty lines between Override and method 2024-10-16 23:10:13 +02:00
Mrbysco
8cdd5acaaf Remove old TODO from TileEntityLaserRelayEnergy 2024-10-16 23:09:53 +02:00
Mrbysco
845aaf847d Remove todo in TileEntityLaserRelay 2024-10-16 23:06:56 +02:00
Mrbysco
0d525dea6c Remove TileEntity related to removed Compost 2024-10-16 23:06:48 +02:00
Mrbysco
3d5a99414f Remove old TileEntityBase TODO's
Remove unused method
2024-10-16 22:50:31 +02:00
Mrbysco
d112602764 Remove unused imports 2024-10-16 22:42:55 +02:00
Mrbysco
deadb3fd70 Make ActuallyContainers consistent
It now matches the rest of the registration related classes
2024-10-16 22:41:57 +02:00
Mrbysco
84c7b0d61a Move Entity registration code to InitEntities
Move BiomeModifier and Condition registration code to ActuallyBiomeModifiers
2024-10-16 22:40:19 +02:00
Mrbysco
09592c6f41 Resolve TODO on Crystal Cluster loottable 2024-10-16 22:26:33 +02:00
Mrbysco
005b3ccc8a Remove Black Quartz Ore loot TEMP 2024-10-16 22:12:30 +02:00
Mrbysco
072f5c68b7 Remove TODO on Ring of Growth recipe
Since it works
2024-10-16 22:08:29 +02:00
Mrbysco
863c2b758b Remove TODO as the content in question was removed 2024-10-16 22:02:28 +02:00
Mrbysco
f226651192 Update NeoForge 2024-10-16 22:02:17 +02:00
70 changed files with 808 additions and 1212 deletions

View file

@ -6,7 +6,7 @@ mod_version=1.2.14
# Forge # Forge
game_version=1.21.1 game_version=1.21.1
neo_version=21.1.69 neo_version=21.1.71
# mods.toml # mods.toml
loader=4 loader=4

View file

@ -1,4 +1,4 @@
// 1.21.1 2024-08-11T19:30:01.8143179 Loot Tables // 1.21.1 2024-10-16T22:24:12.9580535 Loot Tables
ef11aa79a2f96a47250f46811f8491fd34d627f9 data/actuallyadditions/loot_table/blocks/atomic_reconstructor.json ef11aa79a2f96a47250f46811f8491fd34d627f9 data/actuallyadditions/loot_table/blocks/atomic_reconstructor.json
e15c868b26b669c30365bfb93e7d9274e07df16d data/actuallyadditions/loot_table/blocks/battery_box.json e15c868b26b669c30365bfb93e7d9274e07df16d data/actuallyadditions/loot_table/blocks/battery_box.json
745d64af3b0203a138f9eca7de21ed4988b35c95 data/actuallyadditions/loot_table/blocks/bio_reactor.json 745d64af3b0203a138f9eca7de21ed4988b35c95 data/actuallyadditions/loot_table/blocks/bio_reactor.json
@ -29,11 +29,11 @@ fa895b25a0816ca506f7031ec3861cfd4de04f28 data/actuallyadditions/loot_table/block
7c7a4028f6fe02446d1557f72ad494ab363a8409 data/actuallyadditions/loot_table/blocks/crusher.json 7c7a4028f6fe02446d1557f72ad494ab363a8409 data/actuallyadditions/loot_table/blocks/crusher.json
cbd5456165eaf299685aab50dc3bce38d99a1cf8 data/actuallyadditions/loot_table/blocks/crusher_double.json cbd5456165eaf299685aab50dc3bce38d99a1cf8 data/actuallyadditions/loot_table/blocks/crusher_double.json
25b7a44418e2858552dd5150d67bffe1f30269a8 data/actuallyadditions/loot_table/blocks/diamatine_crystal_block.json 25b7a44418e2858552dd5150d67bffe1f30269a8 data/actuallyadditions/loot_table/blocks/diamatine_crystal_block.json
e22890b48eaf91862f5dede7b9c1480f41657e7f data/actuallyadditions/loot_table/blocks/diamatine_crystal_cluster.json ba64f685c7b3c7f998e61d9a3905e627784fb017 data/actuallyadditions/loot_table/blocks/diamatine_crystal_cluster.json
33bc6704cd8545a60049b9f168bc8aa391937e48 data/actuallyadditions/loot_table/blocks/display_stand.json 33bc6704cd8545a60049b9f168bc8aa391937e48 data/actuallyadditions/loot_table/blocks/display_stand.json
3f9aa8b99fad7066fd3a6118a499e3237920cc7e data/actuallyadditions/loot_table/blocks/dropper.json 3f9aa8b99fad7066fd3a6118a499e3237920cc7e data/actuallyadditions/loot_table/blocks/dropper.json
a8183cf6b77bbac91f09ea485f5eaadf70aa8fb0 data/actuallyadditions/loot_table/blocks/emeradic_crystal_block.json a8183cf6b77bbac91f09ea485f5eaadf70aa8fb0 data/actuallyadditions/loot_table/blocks/emeradic_crystal_block.json
39851863a99bf21d48df61350f1ae1e0e25dbeaa data/actuallyadditions/loot_table/blocks/emeradic_crystal_cluster.json 25d55ab81ed1fc53387b4bc3712d4f26b188270f data/actuallyadditions/loot_table/blocks/emeradic_crystal_cluster.json
4811fb48ac8e17ed71d0e42016ccfd7f244026d4 data/actuallyadditions/loot_table/blocks/empowered_diamatine_crystal_block.json 4811fb48ac8e17ed71d0e42016ccfd7f244026d4 data/actuallyadditions/loot_table/blocks/empowered_diamatine_crystal_block.json
e02f5203b700239638e4fafb9915e6873f1b76bc data/actuallyadditions/loot_table/blocks/empowered_emeradic_crystal_block.json e02f5203b700239638e4fafb9915e6873f1b76bc data/actuallyadditions/loot_table/blocks/empowered_emeradic_crystal_block.json
00fa7d2d85a41d1834d016cd232d92a8dad1a81f data/actuallyadditions/loot_table/blocks/empowered_enori_crystal_block.json 00fa7d2d85a41d1834d016cd232d92a8dad1a81f data/actuallyadditions/loot_table/blocks/empowered_enori_crystal_block.json
@ -45,7 +45,7 @@ bb7c77182bd147e1189d865c5a992fbf19a629f4 data/actuallyadditions/loot_table/block
6990098510a0dcb1961a80f00d5f71d4b2bc3f46 data/actuallyadditions/loot_table/blocks/energizer.json 6990098510a0dcb1961a80f00d5f71d4b2bc3f46 data/actuallyadditions/loot_table/blocks/energizer.json
f3c68d58b25c3dbb6d4a65c14dd6d2c28e53814f data/actuallyadditions/loot_table/blocks/enervator.json f3c68d58b25c3dbb6d4a65c14dd6d2c28e53814f data/actuallyadditions/loot_table/blocks/enervator.json
47d7dd8175c672b8568b8863c6b65ab26168fd5f data/actuallyadditions/loot_table/blocks/enori_crystal_block.json 47d7dd8175c672b8568b8863c6b65ab26168fd5f data/actuallyadditions/loot_table/blocks/enori_crystal_block.json
03330e1ee2c22c017c3bd55c880e979f1a4bb3d4 data/actuallyadditions/loot_table/blocks/enori_crystal_cluster.json b133d4e6b05aea63e6d89d696ac03710b88d1d51 data/actuallyadditions/loot_table/blocks/enori_crystal_cluster.json
aca50008d47da6a89a41421752329fc108b74caa data/actuallyadditions/loot_table/blocks/ethetic_green_block.json aca50008d47da6a89a41421752329fc108b74caa data/actuallyadditions/loot_table/blocks/ethetic_green_block.json
2898af59e57ae6b6400a02e56baaf5af796fe971 data/actuallyadditions/loot_table/blocks/ethetic_green_slab.json 2898af59e57ae6b6400a02e56baaf5af796fe971 data/actuallyadditions/loot_table/blocks/ethetic_green_slab.json
011939f5b508413a3827de5b12ff58dd1c875ca7 data/actuallyadditions/loot_table/blocks/ethetic_green_stairs.json 011939f5b508413a3827de5b12ff58dd1c875ca7 data/actuallyadditions/loot_table/blocks/ethetic_green_stairs.json
@ -95,7 +95,7 @@ f8a03e56a032e858126f1b1861ea0b759a3e517d data/actuallyadditions/loot_table/block
27ba42bb0f2dca72e29393944b61e566d758a2dc data/actuallyadditions/loot_table/blocks/long_range_breaker.json 27ba42bb0f2dca72e29393944b61e566d758a2dc data/actuallyadditions/loot_table/blocks/long_range_breaker.json
43113c67b268280ce09b9c90df83f33c15bf2f06 data/actuallyadditions/loot_table/blocks/oil_generator.json 43113c67b268280ce09b9c90df83f33c15bf2f06 data/actuallyadditions/loot_table/blocks/oil_generator.json
f0905fdc46775bb0d7382375b0a1109d125175e7 data/actuallyadditions/loot_table/blocks/palis_crystal_block.json f0905fdc46775bb0d7382375b0a1109d125175e7 data/actuallyadditions/loot_table/blocks/palis_crystal_block.json
ec28c8a70911ac7e3cf621d19aa06443a9da3ebf data/actuallyadditions/loot_table/blocks/palis_crystal_cluster.json 5162668136335d22fef342550e3a14f8c0347e92 data/actuallyadditions/loot_table/blocks/palis_crystal_cluster.json
dadc9a4648ff9cfa77840405384be4937cea991b data/actuallyadditions/loot_table/blocks/phantom_booster.json dadc9a4648ff9cfa77840405384be4937cea991b data/actuallyadditions/loot_table/blocks/phantom_booster.json
7ca8e4e140407dc71416289d293319748d6074a5 data/actuallyadditions/loot_table/blocks/phantom_breaker.json 7ca8e4e140407dc71416289d293319748d6074a5 data/actuallyadditions/loot_table/blocks/phantom_breaker.json
c020a9e28f95800f7eb064fc557afe3cd78ee77a data/actuallyadditions/loot_table/blocks/phantom_energyface.json c020a9e28f95800f7eb064fc557afe3cd78ee77a data/actuallyadditions/loot_table/blocks/phantom_energyface.json
@ -108,7 +108,7 @@ f0a5b8a9ef9e878baa8e1792605ecb6371bf6262 data/actuallyadditions/loot_table/block
e030d31981f02c0ed25d08fcaf8d8e7c89016247 data/actuallyadditions/loot_table/blocks/powered_furnace.json e030d31981f02c0ed25d08fcaf8d8e7c89016247 data/actuallyadditions/loot_table/blocks/powered_furnace.json
8f51bc016a6797bfdf81973a21509e14bd47f245 data/actuallyadditions/loot_table/blocks/ranged_collector.json 8f51bc016a6797bfdf81973a21509e14bd47f245 data/actuallyadditions/loot_table/blocks/ranged_collector.json
0cff315b834058c90a7f26425565e086fb833305 data/actuallyadditions/loot_table/blocks/restonia_crystal_block.json 0cff315b834058c90a7f26425565e086fb833305 data/actuallyadditions/loot_table/blocks/restonia_crystal_block.json
0e6bc03f897b89999df775595eae662728617604 data/actuallyadditions/loot_table/blocks/restonia_crystal_cluster.json d1c8ca548cefbb4f33d4763606a7e0c909319717 data/actuallyadditions/loot_table/blocks/restonia_crystal_cluster.json
247ec0004cfa51a635f305aed06f6a8f2d0cd0c4 data/actuallyadditions/loot_table/blocks/rice.json 247ec0004cfa51a635f305aed06f6a8f2d0cd0c4 data/actuallyadditions/loot_table/blocks/rice.json
d9337537495eb5b2d5288c6df81125594522e5b7 data/actuallyadditions/loot_table/blocks/shock_suppressor.json d9337537495eb5b2d5288c6df81125594522e5b7 data/actuallyadditions/loot_table/blocks/shock_suppressor.json
a534077796cbfbcf0c66f986db3abd037c2d14d6 data/actuallyadditions/loot_table/blocks/smooth_black_quartz_block.json a534077796cbfbcf0c66f986db3abd037c2d14d6 data/actuallyadditions/loot_table/blocks/smooth_black_quartz_block.json
@ -118,7 +118,7 @@ a33803a54b60eb930713929368729dbd01fa77f0 data/actuallyadditions/loot_table/block
b457272e382a377d7e55f2b74d49683a14d62825 data/actuallyadditions/loot_table/blocks/tiny_torch.json b457272e382a377d7e55f2b74d49683a14d62825 data/actuallyadditions/loot_table/blocks/tiny_torch.json
d43769e7f20448bf87952664a3ddd12db0804627 data/actuallyadditions/loot_table/blocks/vertical_digger.json d43769e7f20448bf87952664a3ddd12db0804627 data/actuallyadditions/loot_table/blocks/vertical_digger.json
16963296de38141657d91d76d0458313529e4033 data/actuallyadditions/loot_table/blocks/void_crystal_block.json 16963296de38141657d91d76d0458313529e4033 data/actuallyadditions/loot_table/blocks/void_crystal_block.json
58ebb57d3470800107617d0cc84250750834b675 data/actuallyadditions/loot_table/blocks/void_crystal_cluster.json 3a359dfa76bec7d76fe995787f74ab748a98b0c9 data/actuallyadditions/loot_table/blocks/void_crystal_cluster.json
d3498d690b7d9170fecdc2dd9825519b680cfeec data/actuallyadditions/loot_table/blocks/wood_casing.json d3498d690b7d9170fecdc2dd9825519b680cfeec data/actuallyadditions/loot_table/blocks/wood_casing.json
e1ebdde950a7f730c423a16143ad5598e3b6e3a7 data/actuallyadditions/loot_table/blocks/xp_solidifier.json e1ebdde950a7f730c423a16143ad5598e3b6e3a7 data/actuallyadditions/loot_table/blocks/xp_solidifier.json
860b2c007cf8a1942e3f2934e1385a3a75d3a940 data/actuallyadditions/loot_table/engineer_house.json 860b2c007cf8a1942e3f2934e1385a3a75d3a940 data/actuallyadditions/loot_table/engineer_house.json

View file

@ -1,4 +1,4 @@
// 1.21.1 2024-08-11T19:30:01.8188184 Item Recipes // 1.21.1 2024-10-16T22:05:14.5301488 Item Recipes
14bd5bc2ee3e84b6f3a3181c0e0efd40df5f1d84 data/actuallyadditions/recipe/advanced_coil.json 14bd5bc2ee3e84b6f3a3181c0e0efd40df5f1d84 data/actuallyadditions/recipe/advanced_coil.json
955aad6c1def123a6adbaeabb13faa6eedce847f data/actuallyadditions/recipe/advanced_leaf_blower.json 955aad6c1def123a6adbaeabb13faa6eedce847f data/actuallyadditions/recipe/advanced_leaf_blower.json
97e7ba64f5054b030f4e49615dc4212a28ca9be1 data/actuallyadditions/recipe/basic_coil.json 97e7ba64f5054b030f4e49615dc4212a28ca9be1 data/actuallyadditions/recipe/basic_coil.json
@ -109,6 +109,7 @@ f7b4a51bf6bcaee860b68bfd2dc40a6b0bfff6bc data/actuallyadditions/recipe/rice_pape
73e49fa3d60186037c58569eee42fc6dbff0e55c data/actuallyadditions/recipe/rice_slime.json 73e49fa3d60186037c58569eee42fc6dbff0e55c data/actuallyadditions/recipe/rice_slime.json
f5cbc0efed1684fa5201cbd023d90fdec89aa0b3 data/actuallyadditions/recipe/rice_slime_potion.json f5cbc0efed1684fa5201cbd023d90fdec89aa0b3 data/actuallyadditions/recipe/rice_slime_potion.json
be20b48da77573463f63c119b542fde5d4c14843 data/actuallyadditions/recipe/ring.json be20b48da77573463f63c119b542fde5d4c14843 data/actuallyadditions/recipe/ring.json
b5bcd0457a68e28d37312f1a1e94a106d3b6f038 data/actuallyadditions/recipe/ring_of_growth.json
8e0ac0d696ff3ecd1ef43122707b8f131bba3fbf data/actuallyadditions/recipe/ring_of_magnetizing.json 8e0ac0d696ff3ecd1ef43122707b8f131bba3fbf data/actuallyadditions/recipe/ring_of_magnetizing.json
f31206c1d67ddc93e41d13f24d54e8d6b5913348 data/actuallyadditions/recipe/single_battery.json f31206c1d67ddc93e41d13f24d54e8d6b5913348 data/actuallyadditions/recipe/single_battery.json
9504d2a8e3cb536cf865e8385a013743a0d615d0 data/actuallyadditions/recipe/stone_aiot.json 9504d2a8e3cb536cf865e8385a013743a0d615d0 data/actuallyadditions/recipe/stone_aiot.json

View file

@ -0,0 +1,8 @@
// 1.21.1 2024-10-17T00:54:11.5444321 Patchouli Book Provider
25f9d206f1f0397918f65634d57f658516f3c952 assets/actuallyadditions/patchouli_books/booklet/en_us/categories/getting_started.json
7023c70c30600d465a96b315b2b7954eedad337d assets/actuallyadditions/patchouli_books/booklet/en_us/entries/crystals.json
cb103625b78fcc79697bdc00459a21cacf0c940a assets/actuallyadditions/patchouli_books/booklet/en_us/entries/engineer_house.json
88df6be8c958d5e89673e9eefcf73315d50bda9f assets/actuallyadditions/patchouli_books/booklet/en_us/entries/guide.json
2709d2e5c13efa327c5ee6c18fe10e377d49abe3 assets/actuallyadditions/patchouli_books/booklet/en_us/entries/intro.json
78d1f1a0d393feaf903c84d11ac2749d17779217 assets/actuallyadditions/patchouli_books/booklet/en_us/entries/tutorial.json
10146f4dd5bab35ef00a724fab1f3762e5f7c2b9 data/actuallyadditions/patchouli_books/booklet/book.json

View file

@ -0,0 +1,5 @@
{
"description": "",
"icon": "actuallyadditions:booklet",
"name": "booklet.actuallyadditions.indexEntry.getting_started"
}

View file

@ -0,0 +1,101 @@
{
"category": "actuallyadditions:getting_started",
"icon": "actuallyadditions:booklet",
"name": "booklet.actuallyadditions.chapter.crystals",
"pages": [
{
"type": "patchouli:text",
"text": "booklet.actuallyadditions.chapter.crystals.text.1"
},
{
"type": "patchouli:text",
"text": "booklet.actuallyadditions.chapter.crystals.text.2"
},
{
"type": "patchouli:text",
"text": "booklet.actuallyadditions.chapter.crystals.text.3"
},
{
"type": "patchouli:image",
"border": false,
"images": [
"actuallyadditions:textures/gui/booklet/page_atomic_reconstructor.png"
]
},
{
"type": "patchouli:text",
"text": "booklet.actuallyadditions.chapter.crystals.text.5"
},
{
"type": "patchouli:crafting",
"recipe": "actuallyadditions:atomic_reconstructor",
"text": "booklet.actuallyadditions.chapter.crystals.text.6"
},
{
"type": "actuallyadditions:reconstructor",
"recipe": "actuallyadditions:laser/crystalize_restonia_crystal_block",
"recipe2": "actuallyadditions:laser/crystalize_restonia_crystal",
"text": "booklet.actuallyadditions.reconstructor_recipe"
},
{
"type": "actuallyadditions:reconstructor",
"recipe": "actuallyadditions:laser/crystalize_palis_crystal_block",
"recipe2": "actuallyadditions:laser/crystalize_palis_crystal",
"text": "booklet.actuallyadditions.reconstructor_recipe"
},
{
"type": "actuallyadditions:reconstructor",
"recipe": "actuallyadditions:laser/crystalize_diamatine_crystal_block",
"recipe2": "actuallyadditions:laser/crystalize_diamatine_crystal",
"text": "booklet.actuallyadditions.reconstructor_recipe"
},
{
"type": "actuallyadditions:reconstructor",
"recipe": "actuallyadditions:laser/crystalize_void_crystal_block",
"recipe2": "actuallyadditions:laser/crystalize_void_crystal",
"text": "booklet.actuallyadditions.reconstructor_recipe"
},
{
"type": "actuallyadditions:reconstructor",
"recipe": "actuallyadditions:laser/crystalize_emeradic_crystal_block",
"recipe2": "actuallyadditions:laser/crystalize_emeradic_crystal",
"text": "booklet.actuallyadditions.reconstructor_recipe"
},
{
"type": "actuallyadditions:reconstructor",
"recipe": "actuallyadditions:laser/crystalize_enori_crystal_block",
"recipe2": "actuallyadditions:laser/crystalize_enori_crystal",
"text": "booklet.actuallyadditions.reconstructor_recipe"
},
{
"type": "patchouli:crafting",
"recipe": "actuallyadditions:decompress/restonia_crystal",
"recipe2": "actuallyadditions:compress/restonia_crystal_block"
},
{
"type": "patchouli:crafting",
"recipe": "actuallyadditions:decompress/palis_crystal",
"recipe2": "actuallyadditions:compress/palis_crystal_block"
},
{
"type": "patchouli:crafting",
"recipe": "actuallyadditions:decompress/diamatine_crystal",
"recipe2": "actuallyadditions:compress/diamatine_crystal_block"
},
{
"type": "patchouli:crafting",
"recipe": "actuallyadditions:decompress/void_crystal",
"recipe2": "actuallyadditions:compress/void_crystal_block"
},
{
"type": "patchouli:crafting",
"recipe": "actuallyadditions:decompress/emeradic_crystal",
"recipe2": "actuallyadditions:compress/emeradic_crystal_block"
},
{
"type": "patchouli:crafting",
"recipe": "actuallyadditions:decompress/enori_crystal",
"recipe2": "actuallyadditions:compress/enori_crystal_block"
}
]
}

View file

@ -0,0 +1,18 @@
{
"category": "actuallyadditions:getting_started",
"icon": "actuallyadditions:booklet",
"name": "booklet.actuallyadditions.chapter.engineer_house",
"pages": [
{
"type": "patchouli:text",
"text": "booklet.actuallyadditions.chapter.engineer_house.text.1"
},
{
"type": "patchouli:image",
"images": [
"actuallyadditions:textures/gui/booklet/page_engineer_house.png"
],
"text": "booklet.actuallyadditions.chapter.engineer_house.text.2"
}
]
}

View file

@ -0,0 +1,27 @@
{
"category": "actuallyadditions:getting_started",
"icon": "actuallyadditions:textures/item/youtube.png",
"name": "booklet.actuallyadditions.chapter.video_guide",
"pages": [
{
"type": "patchouli:link",
"link_text": "booklet.actuallyadditions.chapter.video_guide.booty.button",
"text": "booklet.actuallyadditions.chapter.video_guide.booty.text.1",
"url": "https://www.youtube.com/watch?v=fhjz0Ew56pM"
},
{
"type": "patchouli:text",
"text": "booklet.actuallyadditions.chapter.video_guide.booty.text.2"
},
{
"type": "patchouli:link",
"link_text": "booklet.actuallyadditions.chapter.video_guide.booty.button",
"text": "booklet.actuallyadditions.chapter.video_guide.dire.text.1",
"url": "https://www.youtube.com/playlist?list=PLJeFZ64pT89MrTRZYzD_rtHFajPVlt6cF"
},
{
"type": "patchouli:text",
"text": "booklet.actuallyadditions.chapter.video_guide.dire.text.2"
}
]
}

View file

@ -0,0 +1,23 @@
{
"category": "actuallyadditions:getting_started",
"icon": "actuallyadditions:booklet",
"name": "booklet.actuallyadditions.chapter.intro",
"pages": [
{
"type": "patchouli:text",
"text": "booklet.actuallyadditions.chapter.intro.text.1"
},
{
"type": "patchouli:text",
"text": "booklet.actuallyadditions.chapter.intro.text.2"
},
{
"type": "patchouli:text",
"text": "booklet.actuallyadditions.chapter.intro.text.3"
},
{
"type": "patchouli:text",
"text": "booklet.actuallyadditions.chapter.intro.text.4"
}
]
}

View file

@ -0,0 +1,25 @@
{
"category": "actuallyadditions:getting_started",
"icon": "actuallyadditions:booklet",
"name": "booklet.actuallyadditions.chapter.book_tutorial",
"pages": [
{
"type": "patchouli:text",
"text": "booklet.actuallyadditions.chapter.book_tutorial.text.1"
},
{
"type": "patchouli:text",
"text": "booklet.actuallyadditions.chapter.book_tutorial.text.2"
},
{
"type": "patchouli:text",
"text": "booklet.actuallyadditions.chapter.book_tutorial.text.3"
},
{
"type": "patchouli:crafting",
"recipe": "actuallyadditions:booklet",
"text": "booklet.actuallyadditions.shapeless_recipe",
"title": ""
}
]
}

View file

@ -3,15 +3,50 @@
"pools": [ "pools": [
{ {
"bonus_rolls": 0.0, "bonus_rolls": 0.0,
"conditions": [
{
"condition": "minecraft:survives_explosion"
}
],
"entries": [ "entries": [
{
"type": "minecraft:alternatives",
"children": [
{ {
"type": "minecraft:item", "type": "minecraft:item",
"conditions": [
{
"condition": "minecraft:match_tool",
"predicate": {
"predicates": {
"minecraft:enchantments": [
{
"enchantments": "minecraft:silk_touch",
"levels": {
"min": 1
}
}
]
}
}
}
],
"name": "actuallyadditions:diamatine_crystal_cluster" "name": "actuallyadditions:diamatine_crystal_cluster"
},
{
"type": "minecraft:item",
"functions": [
{
"add": false,
"count": {
"type": "minecraft:uniform",
"max": 8.0,
"min": 2.0
},
"function": "minecraft:set_count"
},
{
"function": "minecraft:explosion_decay"
}
],
"name": "actuallyadditions:diamatine_crystal_shard"
}
]
} }
], ],
"rolls": 1.0 "rolls": 1.0

View file

@ -3,15 +3,50 @@
"pools": [ "pools": [
{ {
"bonus_rolls": 0.0, "bonus_rolls": 0.0,
"conditions": [
{
"condition": "minecraft:survives_explosion"
}
],
"entries": [ "entries": [
{
"type": "minecraft:alternatives",
"children": [
{ {
"type": "minecraft:item", "type": "minecraft:item",
"conditions": [
{
"condition": "minecraft:match_tool",
"predicate": {
"predicates": {
"minecraft:enchantments": [
{
"enchantments": "minecraft:silk_touch",
"levels": {
"min": 1
}
}
]
}
}
}
],
"name": "actuallyadditions:emeradic_crystal_cluster" "name": "actuallyadditions:emeradic_crystal_cluster"
},
{
"type": "minecraft:item",
"functions": [
{
"add": false,
"count": {
"type": "minecraft:uniform",
"max": 8.0,
"min": 2.0
},
"function": "minecraft:set_count"
},
{
"function": "minecraft:explosion_decay"
}
],
"name": "actuallyadditions:emeradic_crystal_shard"
}
]
} }
], ],
"rolls": 1.0 "rolls": 1.0

View file

@ -3,15 +3,50 @@
"pools": [ "pools": [
{ {
"bonus_rolls": 0.0, "bonus_rolls": 0.0,
"conditions": [
{
"condition": "minecraft:survives_explosion"
}
],
"entries": [ "entries": [
{
"type": "minecraft:alternatives",
"children": [
{ {
"type": "minecraft:item", "type": "minecraft:item",
"conditions": [
{
"condition": "minecraft:match_tool",
"predicate": {
"predicates": {
"minecraft:enchantments": [
{
"enchantments": "minecraft:silk_touch",
"levels": {
"min": 1
}
}
]
}
}
}
],
"name": "actuallyadditions:enori_crystal_cluster" "name": "actuallyadditions:enori_crystal_cluster"
},
{
"type": "minecraft:item",
"functions": [
{
"add": false,
"count": {
"type": "minecraft:uniform",
"max": 8.0,
"min": 2.0
},
"function": "minecraft:set_count"
},
{
"function": "minecraft:explosion_decay"
}
],
"name": "actuallyadditions:enori_crystal_shard"
}
]
} }
], ],
"rolls": 1.0 "rolls": 1.0

View file

@ -3,15 +3,50 @@
"pools": [ "pools": [
{ {
"bonus_rolls": 0.0, "bonus_rolls": 0.0,
"conditions": [
{
"condition": "minecraft:survives_explosion"
}
],
"entries": [ "entries": [
{
"type": "minecraft:alternatives",
"children": [
{ {
"type": "minecraft:item", "type": "minecraft:item",
"conditions": [
{
"condition": "minecraft:match_tool",
"predicate": {
"predicates": {
"minecraft:enchantments": [
{
"enchantments": "minecraft:silk_touch",
"levels": {
"min": 1
}
}
]
}
}
}
],
"name": "actuallyadditions:palis_crystal_cluster" "name": "actuallyadditions:palis_crystal_cluster"
},
{
"type": "minecraft:item",
"functions": [
{
"add": false,
"count": {
"type": "minecraft:uniform",
"max": 8.0,
"min": 2.0
},
"function": "minecraft:set_count"
},
{
"function": "minecraft:explosion_decay"
}
],
"name": "actuallyadditions:palis_crystal_shard"
}
]
} }
], ],
"rolls": 1.0 "rolls": 1.0

View file

@ -3,15 +3,50 @@
"pools": [ "pools": [
{ {
"bonus_rolls": 0.0, "bonus_rolls": 0.0,
"conditions": [
{
"condition": "minecraft:survives_explosion"
}
],
"entries": [ "entries": [
{
"type": "minecraft:alternatives",
"children": [
{ {
"type": "minecraft:item", "type": "minecraft:item",
"conditions": [
{
"condition": "minecraft:match_tool",
"predicate": {
"predicates": {
"minecraft:enchantments": [
{
"enchantments": "minecraft:silk_touch",
"levels": {
"min": 1
}
}
]
}
}
}
],
"name": "actuallyadditions:restonia_crystal_cluster" "name": "actuallyadditions:restonia_crystal_cluster"
},
{
"type": "minecraft:item",
"functions": [
{
"add": false,
"count": {
"type": "minecraft:uniform",
"max": 8.0,
"min": 2.0
},
"function": "minecraft:set_count"
},
{
"function": "minecraft:explosion_decay"
}
],
"name": "actuallyadditions:restonia_crystal_shard"
}
]
} }
], ],
"rolls": 1.0 "rolls": 1.0

View file

@ -3,15 +3,50 @@
"pools": [ "pools": [
{ {
"bonus_rolls": 0.0, "bonus_rolls": 0.0,
"conditions": [
{
"condition": "minecraft:survives_explosion"
}
],
"entries": [ "entries": [
{
"type": "minecraft:alternatives",
"children": [
{ {
"type": "minecraft:item", "type": "minecraft:item",
"conditions": [
{
"condition": "minecraft:match_tool",
"predicate": {
"predicates": {
"minecraft:enchantments": [
{
"enchantments": "minecraft:silk_touch",
"levels": {
"min": 1
}
}
]
}
}
}
],
"name": "actuallyadditions:void_crystal_cluster" "name": "actuallyadditions:void_crystal_cluster"
},
{
"type": "minecraft:item",
"functions": [
{
"add": false,
"count": {
"type": "minecraft:uniform",
"max": 8.0,
"min": 2.0
},
"function": "minecraft:set_count"
},
{
"function": "minecraft:explosion_decay"
}
],
"name": "actuallyadditions:void_crystal_shard"
}
]
} }
], ],
"rolls": 1.0 "rolls": 1.0

View file

@ -0,0 +1,21 @@
{
"book_texture": "actuallyadditions:textures/gui/booklet/booklet.png",
"creative_tab": "actuallyadditions.tab",
"custom_book_item": "actuallyadditions:booklet",
"dont_generate_book": true,
"i18n": true,
"landing_text": "<i>To be perfectly honest, I never actually realized how much content Actually Additions has before.<r><n> - Ellpeck",
"macros": {
"<i>": "$(o)",
"<imp>": "$(2)",
"<item>": "$(9)",
"<n>": "$(br)",
"<r>": "$()",
"<tifisgrin>": "$(4)$(n)"
},
"name": "booklet.actuallyadditions.item.actuallyadditions.booklet",
"show_progress": false,
"use_blocky_font": false,
"use_resource_pack": true,
"version": "153"
}

View file

@ -0,0 +1,24 @@
{
"type": "minecraft:crafting_shaped",
"category": "misc",
"key": {
"I": {
"item": "actuallyadditions:empowered_enori_crystal"
},
"O": {
"item": "actuallyadditions:ring"
},
"S": {
"tag": "c:seeds"
}
},
"pattern": [
"SIS",
"IOI",
"SIS"
],
"result": {
"count": 1,
"id": "actuallyadditions:ring_of_growth"
}
}

View file

@ -1,5 +1,6 @@
package de.ellpeck.actuallyadditions.data; package de.ellpeck.actuallyadditions.data;
import de.ellpeck.actuallyadditions.data.patchouli.PatchouliGenerator;
import de.ellpeck.actuallyadditions.mod.ActuallyAdditions; import de.ellpeck.actuallyadditions.mod.ActuallyAdditions;
import de.ellpeck.actuallyadditions.mod.gen.ActuallyBiomeModifiers; import de.ellpeck.actuallyadditions.mod.gen.ActuallyBiomeModifiers;
import de.ellpeck.actuallyadditions.mod.gen.ActuallyConfiguredFeatures; import de.ellpeck.actuallyadditions.mod.gen.ActuallyConfiguredFeatures;
@ -65,7 +66,7 @@ public class ActuallyAdditionsData {
generator.addProvider(true, new SoundsGenerator(packOutput, helper)); generator.addProvider(true, new SoundsGenerator(packOutput, helper));
// generator.addProvider(true, new PachouliGenerator(packOutput)); generator.addProvider(true, new PatchouliGenerator(packOutput, lookupProvider));
generator.addProvider(true, new GlobalLootModifierGenerator(packOutput, lookupProvider)); generator.addProvider(true, new GlobalLootModifierGenerator(packOutput, lookupProvider));

View file

@ -39,8 +39,6 @@ public class AdvancementGenerator extends AdvancementProvider {
.addCriterion("right_click", CriteriaTriggers.IMPOSSIBLE.createCriterion(new ImpossibleTrigger.TriggerInstance())) .addCriterion("right_click", CriteriaTriggers.IMPOSSIBLE.createCriterion(new ImpossibleTrigger.TriggerInstance()))
.save(consumer, "actuallyadditions:root"); .save(consumer, "actuallyadditions:root");
//TODO: Underwater Treasure Chest Advancement?
AdvancementHolder phantomFace = Advancement.Builder.advancement() AdvancementHolder phantomFace = Advancement.Builder.advancement()
.parent(root) .parent(root)
.display(new DisplayInfo(ActuallyBlocks.PHANTOM_ITEMFACE.get().asItem().getDefaultInstance(), .display(new DisplayInfo(ActuallyBlocks.PHANTOM_ITEMFACE.get().asItem().getDefaultInstance(),

View file

@ -453,12 +453,12 @@ public class ItemRecipeGenerator extends RecipeProvider {
.save(recipeOutput); .save(recipeOutput);
//Growth Ring //Growth Ring
/* Recipe.shaped(ActuallyItems.RING_OF_GROWTH.get()) Recipe.shaped(ActuallyItems.RING_OF_GROWTH.get())
.pattern("SIS", "IOI", "SIS") .pattern("SIS", "IOI", "SIS")
.define('S', Tags.Items.SEEDS) .define('S', Tags.Items.SEEDS)
.define('I', ActuallyItems.EMPOWERED_ENORI_CRYSTAL.get()) .define('I', ActuallyItems.EMPOWERED_ENORI_CRYSTAL.get())
.define('O', ActuallyItems.RING.get()) .define('O', ActuallyItems.RING.get())
.save(recipeOutput);*/ //TODO not done yet .save(recipeOutput);
Recipe.shapeless(ActuallyItems.CRAFTER_ON_A_STICK.get()).requires(Items.CRAFTING_TABLE).requires(ItemTags.SIGNS).save(recipeOutput); Recipe.shapeless(ActuallyItems.CRAFTER_ON_A_STICK.get()).requires(Items.CRAFTING_TABLE).requires(ItemTags.SIGNS).save(recipeOutput);

View file

@ -34,6 +34,7 @@ import net.minecraft.world.level.storage.loot.predicates.LootItemBlockStatePrope
import net.minecraft.world.level.storage.loot.providers.number.ConstantValue; import net.minecraft.world.level.storage.loot.providers.number.ConstantValue;
import net.minecraft.world.level.storage.loot.providers.number.UniformGenerator; import net.minecraft.world.level.storage.loot.providers.number.UniformGenerator;
import net.neoforged.neoforge.registries.DeferredHolder; import net.neoforged.neoforge.registries.DeferredHolder;
import net.neoforged.neoforge.registries.DeferredItem;
import java.util.List; import java.util.List;
import java.util.Set; import java.util.Set;
@ -185,27 +186,15 @@ public class LootTableGenerator extends LootTableProvider {
this.dropSelf(ActuallyBlocks.EMPOWERED_VOID_CRYSTAL.get()); this.dropSelf(ActuallyBlocks.EMPOWERED_VOID_CRYSTAL.get());
this.dropSelf(ActuallyBlocks.EMPOWERED_EMERADIC_CRYSTAL.get()); this.dropSelf(ActuallyBlocks.EMPOWERED_EMERADIC_CRYSTAL.get());
/* this.registerCrystal(ActuallyBlocks.CRYSTAL_CLUSTER_RESTONIA, ActuallyItems.RED_CRYSTAL_SHARD); this.registerCrystal(ActuallyBlocks.ENORI_CRYSTAL_CLUSTER, ActuallyItems.ENORI_CRYSTAL_SHARD);
this.registerCrystal(ActuallyBlocks.CRYSTAL_CLUSTER_PALIS, ActuallyItems.BLUE_CRYSTAL_SHARD); this.registerCrystal(ActuallyBlocks.RESTONIA_CRYSTAL_CLUSTER, ActuallyItems.RESTONIA_CRYSTAL_SHARD);
this.registerCrystal(ActuallyBlocks.CRYSTAL_CLUSTER_DIAMATINE, ActuallyItems.LIGHT_BLUE_CRYSTAL_SHARD); this.registerCrystal(ActuallyBlocks.PALIS_CRYSTAL_CLUSTER, ActuallyItems.PALIS_CRYSTAL_SHARD);
this.registerCrystal(ActuallyBlocks.CRYSTAL_CLUSTER_VOID, ActuallyItems.BLACK_CRYSTAL_SHARD); this.registerCrystal(ActuallyBlocks.DIAMATINE_CRYSTAL_CLUSTER, ActuallyItems.DIAMATINE_CRYSTAL_SHARD);
this.registerCrystal(ActuallyBlocks.CRYSTAL_CLUSTER_EMERADIC, ActuallyItems.GREEN_CRYSTAL_SHARD); this.registerCrystal(ActuallyBlocks.VOID_CRYSTAL_CLUSTER, ActuallyItems.VOID_CRYSTAL_SHARD);
this.registerCrystal(ActuallyBlocks.CRYSTAL_CLUSTER_ENORI, ActuallyItems.WHITE_CRYSTAL_SHARD);*/ this.registerCrystal(ActuallyBlocks.EMERADIC_CRYSTAL_CLUSTER, ActuallyItems.EMERADIC_CRYSTAL_SHARD);
//TODO temp
dropSelf(ActuallyBlocks.ENORI_CRYSTAL_CLUSTER.get());
dropSelf(ActuallyBlocks.RESTONIA_CRYSTAL_CLUSTER.get());
dropSelf(ActuallyBlocks.PALIS_CRYSTAL_CLUSTER.get());
dropSelf(ActuallyBlocks.DIAMATINE_CRYSTAL_CLUSTER.get());
dropSelf(ActuallyBlocks.VOID_CRYSTAL_CLUSTER.get());
dropSelf(ActuallyBlocks.EMERADIC_CRYSTAL_CLUSTER.get());
//TODO temp
dropSelf(ActuallyBlocks.BLACK_QUARTZ_ORE.get());
add(ActuallyBlocks.BLACK_QUARTZ_ORE.get(), createOreDrop(ActuallyBlocks.BLACK_QUARTZ_ORE.getBlock(), ActuallyItems.BLACK_QUARTZ.get())); add(ActuallyBlocks.BLACK_QUARTZ_ORE.get(), createOreDrop(ActuallyBlocks.BLACK_QUARTZ_ORE.getBlock(), ActuallyItems.BLACK_QUARTZ.get()));
//this.add(ActuallyBlocks.BLACK_QUARTZ_ORE.get(), ore -> droppingItemWithFortune(ore, ActuallyItems.BLACK_QUARTZ.get()));
addCrop(ActuallyBlocks.CANOLA, ActuallyItems.CANOLA, ActuallyItems.CANOLA_SEEDS); addCrop(ActuallyBlocks.CANOLA, ActuallyItems.CANOLA, ActuallyItems.CANOLA_SEEDS);
addCrop(ActuallyBlocks.RICE, ActuallyItems.RICE, ActuallyItems.RICE_SEEDS); addCrop(ActuallyBlocks.RICE, ActuallyItems.RICE, ActuallyItems.RICE_SEEDS);
addCrop(ActuallyBlocks.FLAX, () -> Items.STRING, ActuallyItems.FLAX_SEEDS); addCrop(ActuallyBlocks.FLAX, () -> Items.STRING, ActuallyItems.FLAX_SEEDS);
@ -230,17 +219,10 @@ public class LootTableGenerator extends LootTableProvider {
.include(ActuallyComponents.ENERGY_STORAGE.get()))); .include(ActuallyComponents.ENERGY_STORAGE.get())));
} }
/* // This isn't quite right :cry: fortune doesn't change it private void registerCrystal(Supplier<? extends Block> crystalCluster, DeferredItem<? extends Item> crystalShard) {
private void registerCrystal(RegistryObject<Block> crystalCluster, RegistryObject<Item> crystalShard) { this.add(crystalCluster.get(), block ->
this.registerLootTable(crystalCluster.get(), (crystal) -> this.createSingleItemTableWithSilkTouch(block, crystalShard.get(), UniformGenerator.between(2.0F, 8.0F)));
droppingWithSilkTouch(crystal, }
withExplosionDecay(crystal, ItemLootEntry.builder(crystalShard.get())
.acceptFunction(ApplyBonus.oreDrops(Enchantments.FORTUNE))
.acceptFunction(SetCount.builder(RandomValueRange.of(2f, 8f)))
)
)
);
}*/
@Override @Override
protected Iterable<Block> getKnownBlocks() { protected Iterable<Block> getKnownBlocks() {

View file

@ -1,125 +0,0 @@
//package de.ellpeck.actuallyadditions.data.patchouli;
//
//import de.ellpeck.actuallyadditions.data.patchouli.builder.ReconstructorPageBuilder;
//import de.ellpeck.actuallyadditions.mod.ActuallyAdditions;
//import de.ellpeck.actuallyadditions.mod.items.ActuallyItems;
//import net.minecraft.data.PackOutput;
//import net.minecraft.resources.ResourceLocation;
//import net.minecraft.world.item.ItemStack;
//import xyz.brassgoggledcoders.patchouliprovider.BookBuilder;
//import xyz.brassgoggledcoders.patchouliprovider.CategoryBuilder;
//import xyz.brassgoggledcoders.patchouliprovider.EntryBuilder;
//import xyz.brassgoggledcoders.patchouliprovider.PatchouliBookProvider;
//
//import java.util.function.Consumer;
//
//public class PachouliGenerator extends PatchouliBookProvider {
//
// public PachouliGenerator(PackOutput output) {
// super(output, ActuallyAdditions.MODID, "en_us");
// }
//
// @Override
// protected void addBooks(Consumer<BookBuilder> consumer) {
// final ItemStack bookStack = ActuallyItems.ITEM_BOOKLET.get().getDefaultInstance();
//
// BookBuilder bookBuilder = createBookBuilder("booklet",
// prefix("item.actuallyadditions.booklet"), "<i>To be perfectly honest, I never actually realized how much content Actually Additions has before.<r><n> - Ellpeck")
// .setVersion("153")
// .setCreativeTab("actuallyadditions.tab")
// .setCustomBookItem(bookStack)
// .setBookTexture("actuallyadditions:textures/gui/booklet/booklet.png")
// .setShowProgress(false)
// .setUseBlockyFont(false)
// .setI18n(true)
// .setDontGenerateBook(true)
// .addMacro("<imp>", "$(2)")
// .addMacro("<item>", "$(9)")
// .addMacro("<r>", "$()")
// .addMacro("<n>", "$(br)")
// .addMacro("<i>", "$(o)")
// .addMacro("<tifisgrin>", "$(4)$(n)")
// .setUseResourcePack(true);
//
//
// //Getting Started
// CategoryBuilder gettingStarted = bookBuilder.addCategory("getting_started", prefix("indexEntry.getting_started"),
// "", bookStack);
//
// gettingStarted.addEntry("tutorial", prefix("chapter.book_tutorial"), bookStack)
// .addTextPage(prefix("chapter.book_tutorial.text.1")).build()
// .addTextPage(prefix("chapter.book_tutorial.text.2")).build()
// .addTextPage(prefix("chapter.book_tutorial.text.3")).build()
// .addCraftingPage(ActuallyAdditions.modLoc("booklet"))
// .setTitle("").setText("booklet.actuallyadditions.shapeless_recipe").build();
//
// gettingStarted.addEntry("guide", prefix("chapter.video_guide"), "actuallyadditions:textures/item/youtube.png")
// .addLinkPage("https://www.youtube.com/watch?v=fhjz0Ew56pM", prefix("chapter.video_guide.booty.button"))
// .setText(prefix("chapter.video_guide.booty.text.1")).build()
// .addTextPage(prefix("chapter.video_guide.booty.text.2")).build()
// .addLinkPage("https://www.youtube.com/playlist?list=PLJeFZ64pT89MrTRZYzD_rtHFajPVlt6cF", prefix("chapter.video_guide.booty.button"))
// .setText(prefix("chapter.video_guide.dire.text.1")).build()
// .addTextPage(prefix("chapter.video_guide.dire.text.2")).build();
//
// gettingStarted.addEntry("intro", prefix("chapter.intro"), bookStack)
// .addTextPage(prefix("chapter.intro.text.1")).build()
// .addTextPage(prefix("chapter.intro.text.2")).build()
// .addTextPage(prefix("chapter.intro.text.3")).build()
// .addTextPage(prefix("chapter.intro.text.4")).build();
//
// gettingStarted.addEntry("engineer_house", prefix("chapter.engineer_house"), bookStack)
// .addTextPage(prefix("chapter.engineer_house.text.1")).build()
// .addImagePage(ActuallyAdditions.modLoc("textures/gui/booklet/page_engineer_house.png"))
// .setText("booklet.actuallyadditions.chapter.engineer_house.text.2").build();
//
// EntryBuilder crystalsBuilder = gettingStarted.addEntry("crystals", prefix("chapter.crystals"), bookStack)
// .addTextPage(prefix("chapter.crystals.text.1")).build()
// .addTextPage(prefix("chapter.crystals.text.2")).build()
// .addTextPage(prefix("chapter.crystals.text.3")).build()
// .addImagePage(ActuallyAdditions.modLoc("textures/gui/booklet/page_atomic_reconstructor.png")).setBorder(false).build()
// .addTextPage(prefix("chapter.crystals.text.5")).build()
// .addCraftingPage(ActuallyAdditions.modLoc("atomic_reconstructor"))
// .setText(prefix("chapter.crystals.text.6")).build();
// crystalsBuilder.addPage(new ReconstructorPageBuilder(ActuallyAdditions.modLoc("laser/crystalize_restonia_crystal_block"), crystalsBuilder))
// .setRecipe2(ActuallyAdditions.modLoc("laser/crystalize_restonia_crystal"))
// .setText("booklet.actuallyadditions.reconstructor_recipe").build();
// crystalsBuilder.addPage(new ReconstructorPageBuilder(ActuallyAdditions.modLoc("laser/crystalize_palis_crystal_block"), crystalsBuilder))
// .setRecipe2(ActuallyAdditions.modLoc("laser/crystalize_palis_crystal"))
// .setText("booklet.actuallyadditions.reconstructor_recipe").build();
// crystalsBuilder.addPage(new ReconstructorPageBuilder(ActuallyAdditions.modLoc("laser/crystalize_diamatine_crystal_block"), crystalsBuilder))
// .setRecipe2(ActuallyAdditions.modLoc("laser/crystalize_diamatine_crystal"))
// .setText("booklet.actuallyadditions.reconstructor_recipe").build();
// crystalsBuilder.addPage(new ReconstructorPageBuilder(ActuallyAdditions.modLoc("laser/crystalize_void_crystal_block"), crystalsBuilder))
// .setRecipe2(ActuallyAdditions.modLoc("laser/crystalize_void_crystal"))
// .setText("booklet.actuallyadditions.reconstructor_recipe").build();
// crystalsBuilder.addPage(new ReconstructorPageBuilder(ActuallyAdditions.modLoc("laser/crystalize_emeradic_crystal_block"), crystalsBuilder))
// .setRecipe2(ActuallyAdditions.modLoc("laser/crystalize_emeradic_crystal"))
// .setText("booklet.actuallyadditions.reconstructor_recipe").build();
// crystalsBuilder.addPage(new ReconstructorPageBuilder(ActuallyAdditions.modLoc("laser/crystalize_enori_crystal_block"), crystalsBuilder))
// .setRecipe2(ActuallyAdditions.modLoc("laser/crystalize_enori_crystal"))
// .setText("booklet.actuallyadditions.reconstructor_recipe").build();
// crystalsBuilder.addCraftingPage(ActuallyAdditions.modLoc("decompress/restonia_crystal"))
// .setRecipe2(ActuallyAdditions.modLoc("compress/restonia_crystal_block")).build()
// .addCraftingPage(ActuallyAdditions.modLoc("decompress/palis_crystal"))
// .setRecipe2(ActuallyAdditions.modLoc("compress/palis_crystal_block")).build()
// .addCraftingPage(ActuallyAdditions.modLoc("decompress/diamatine_crystal"))
// .setRecipe2(ActuallyAdditions.modLoc("compress/diamatine_crystal_block")).build()
// .addCraftingPage(ActuallyAdditions.modLoc("decompress/void_crystal"))
// .setRecipe2(ActuallyAdditions.modLoc("compress/void_crystal_block")).build()
// .addCraftingPage(ActuallyAdditions.modLoc("decompress/emeradic_crystal"))
// .setRecipe2(ActuallyAdditions.modLoc("compress/emeradic_crystal_block")).build()
// .addCraftingPage(ActuallyAdditions.modLoc("decompress/enori_crystal"))
// .setRecipe2(ActuallyAdditions.modLoc("compress/enori_crystal_block")).build();
// crystalsBuilder.build();
//
// //End of Getting Started
//
//
// //Finish book
// bookBuilder.build(consumer);
// }
//
// private String prefix(String name) {
// return "booklet.actuallyadditions." + name;
// }
//}

View file

@ -0,0 +1,128 @@
package de.ellpeck.actuallyadditions.data.patchouli;
import de.ellpeck.actuallyadditions.data.patchouli.builder.ReconstructorPageBuilder;
import de.ellpeck.actuallyadditions.mod.ActuallyAdditions;
import de.ellpeck.actuallyadditions.mod.items.ActuallyItems;
import net.minecraft.core.HolderLookup;
import net.minecraft.data.PackOutput;
import net.minecraft.world.item.ItemStack;
import xyz.brassgoggledcoders.patchouliprovider.BookBuilder;
import xyz.brassgoggledcoders.patchouliprovider.CategoryBuilder;
import xyz.brassgoggledcoders.patchouliprovider.EntryBuilder;
import xyz.brassgoggledcoders.patchouliprovider.PatchouliBookProvider;
import java.util.concurrent.CompletableFuture;
import java.util.function.Consumer;
public class PatchouliGenerator extends PatchouliBookProvider {
public PatchouliGenerator(PackOutput output, CompletableFuture<HolderLookup.Provider> lookupProvider) {
super(output, ActuallyAdditions.MODID, "en_us", lookupProvider);
}
@Override
protected void addBooks(Consumer<BookBuilder> consumer, HolderLookup.Provider provider) {
final ItemStack bookStack = ActuallyItems.ITEM_BOOKLET.get().getDefaultInstance();
BookBuilder bookBuilder = createBookBuilder("booklet",
prefix("item.actuallyadditions.booklet"),
"<i>To be perfectly honest, I never actually realized how much content Actually Additions has before.<r><n> - Ellpeck",
provider)
.setVersion("153")
.setCreativeTab("actuallyadditions.tab")
.setCustomBookItem(bookStack)
.setBookTexture("actuallyadditions:textures/gui/booklet/booklet.png")
.setShowProgress(false)
.setUseBlockyFont(false)
.setI18n(true)
.setDontGenerateBook(true)
.addMacro("<imp>", "$(2)")
.addMacro("<item>", "$(9)")
.addMacro("<r>", "$()")
.addMacro("<n>", "$(br)")
.addMacro("<i>", "$(o)")
.addMacro("<tifisgrin>", "$(4)$(n)")
.setUseResourcePack(true);
//Getting Started
CategoryBuilder gettingStarted = bookBuilder.addCategory("getting_started", prefix("indexEntry.getting_started"),
"", bookStack);
gettingStarted.addEntry("tutorial", prefix("chapter.book_tutorial"), bookStack)
.addTextPage(prefix("chapter.book_tutorial.text.1")).build()
.addTextPage(prefix("chapter.book_tutorial.text.2")).build()
.addTextPage(prefix("chapter.book_tutorial.text.3")).build()
.addCraftingPage(ActuallyAdditions.modLoc("booklet"))
.setTitle("").setText("booklet.actuallyadditions.shapeless_recipe").build();
gettingStarted.addEntry("guide", prefix("chapter.video_guide"), "actuallyadditions:textures/item/youtube.png")
.addLinkPage("https://www.youtube.com/watch?v=fhjz0Ew56pM", prefix("chapter.video_guide.booty.button"))
.setText(prefix("chapter.video_guide.booty.text.1")).build()
.addTextPage(prefix("chapter.video_guide.booty.text.2")).build()
.addLinkPage("https://www.youtube.com/playlist?list=PLJeFZ64pT89MrTRZYzD_rtHFajPVlt6cF", prefix("chapter.video_guide.booty.button"))
.setText(prefix("chapter.video_guide.dire.text.1")).build()
.addTextPage(prefix("chapter.video_guide.dire.text.2")).build();
gettingStarted.addEntry("intro", prefix("chapter.intro"), bookStack)
.addTextPage(prefix("chapter.intro.text.1")).build()
.addTextPage(prefix("chapter.intro.text.2")).build()
.addTextPage(prefix("chapter.intro.text.3")).build()
.addTextPage(prefix("chapter.intro.text.4")).build();
gettingStarted.addEntry("engineer_house", prefix("chapter.engineer_house"), bookStack)
.addTextPage(prefix("chapter.engineer_house.text.1")).build()
.addImagePage(ActuallyAdditions.modLoc("textures/gui/booklet/page_engineer_house.png"))
.setText("booklet.actuallyadditions.chapter.engineer_house.text.2").build();
EntryBuilder crystalsBuilder = gettingStarted.addEntry("crystals", prefix("chapter.crystals"), bookStack)
.addTextPage(prefix("chapter.crystals.text.1")).build()
.addTextPage(prefix("chapter.crystals.text.2")).build()
.addTextPage(prefix("chapter.crystals.text.3")).build()
.addImagePage(ActuallyAdditions.modLoc("textures/gui/booklet/page_atomic_reconstructor.png")).setBorder(false).build()
.addTextPage(prefix("chapter.crystals.text.5")).build()
.addCraftingPage(ActuallyAdditions.modLoc("atomic_reconstructor"))
.setText(prefix("chapter.crystals.text.6")).build();
crystalsBuilder.addPage(new ReconstructorPageBuilder(ActuallyAdditions.modLoc("laser/crystalize_restonia_crystal_block"), crystalsBuilder))
.setRecipe2(ActuallyAdditions.modLoc("laser/crystalize_restonia_crystal"))
.setText("booklet.actuallyadditions.reconstructor_recipe").build();
crystalsBuilder.addPage(new ReconstructorPageBuilder(ActuallyAdditions.modLoc("laser/crystalize_palis_crystal_block"), crystalsBuilder))
.setRecipe2(ActuallyAdditions.modLoc("laser/crystalize_palis_crystal"))
.setText("booklet.actuallyadditions.reconstructor_recipe").build();
crystalsBuilder.addPage(new ReconstructorPageBuilder(ActuallyAdditions.modLoc("laser/crystalize_diamatine_crystal_block"), crystalsBuilder))
.setRecipe2(ActuallyAdditions.modLoc("laser/crystalize_diamatine_crystal"))
.setText("booklet.actuallyadditions.reconstructor_recipe").build();
crystalsBuilder.addPage(new ReconstructorPageBuilder(ActuallyAdditions.modLoc("laser/crystalize_void_crystal_block"), crystalsBuilder))
.setRecipe2(ActuallyAdditions.modLoc("laser/crystalize_void_crystal"))
.setText("booklet.actuallyadditions.reconstructor_recipe").build();
crystalsBuilder.addPage(new ReconstructorPageBuilder(ActuallyAdditions.modLoc("laser/crystalize_emeradic_crystal_block"), crystalsBuilder))
.setRecipe2(ActuallyAdditions.modLoc("laser/crystalize_emeradic_crystal"))
.setText("booklet.actuallyadditions.reconstructor_recipe").build();
crystalsBuilder.addPage(new ReconstructorPageBuilder(ActuallyAdditions.modLoc("laser/crystalize_enori_crystal_block"), crystalsBuilder))
.setRecipe2(ActuallyAdditions.modLoc("laser/crystalize_enori_crystal"))
.setText("booklet.actuallyadditions.reconstructor_recipe").build();
crystalsBuilder.addCraftingPage(ActuallyAdditions.modLoc("decompress/restonia_crystal"))
.setRecipe2(ActuallyAdditions.modLoc("compress/restonia_crystal_block")).build()
.addCraftingPage(ActuallyAdditions.modLoc("decompress/palis_crystal"))
.setRecipe2(ActuallyAdditions.modLoc("compress/palis_crystal_block")).build()
.addCraftingPage(ActuallyAdditions.modLoc("decompress/diamatine_crystal"))
.setRecipe2(ActuallyAdditions.modLoc("compress/diamatine_crystal_block")).build()
.addCraftingPage(ActuallyAdditions.modLoc("decompress/void_crystal"))
.setRecipe2(ActuallyAdditions.modLoc("compress/void_crystal_block")).build()
.addCraftingPage(ActuallyAdditions.modLoc("decompress/emeradic_crystal"))
.setRecipe2(ActuallyAdditions.modLoc("compress/emeradic_crystal_block")).build()
.addCraftingPage(ActuallyAdditions.modLoc("decompress/enori_crystal"))
.setRecipe2(ActuallyAdditions.modLoc("compress/enori_crystal_block")).build();
crystalsBuilder.build();
//End of Getting Started
//Finish book
bookBuilder.build(consumer);
}
private String prefix(String name) {
return "booklet.actuallyadditions." + name;
}
}

View file

@ -10,24 +10,19 @@
package de.ellpeck.actuallyadditions.mod; package de.ellpeck.actuallyadditions.mod;
import com.mojang.serialization.Codec;
import com.mojang.serialization.MapCodec;
import com.mojang.serialization.codecs.RecordCodecBuilder;
import de.ellpeck.actuallyadditions.api.ActuallyAdditionsAPI; import de.ellpeck.actuallyadditions.api.ActuallyAdditionsAPI;
import de.ellpeck.actuallyadditions.api.ActuallyTags; import de.ellpeck.actuallyadditions.api.ActuallyTags;
import de.ellpeck.actuallyadditions.api.farmer.IFarmerBehavior; import de.ellpeck.actuallyadditions.api.farmer.IFarmerBehavior;
import de.ellpeck.actuallyadditions.mod.blocks.ActuallyBlocks; import de.ellpeck.actuallyadditions.mod.blocks.ActuallyBlocks;
import de.ellpeck.actuallyadditions.mod.components.ActuallyComponents; import de.ellpeck.actuallyadditions.mod.components.ActuallyComponents;
import de.ellpeck.actuallyadditions.mod.config.CommonConfig; import de.ellpeck.actuallyadditions.mod.config.CommonConfig;
import de.ellpeck.actuallyadditions.mod.config.conditions.BoolConfigCondition;
import de.ellpeck.actuallyadditions.mod.crafting.ActuallyRecipes; import de.ellpeck.actuallyadditions.mod.crafting.ActuallyRecipes;
import de.ellpeck.actuallyadditions.mod.data.WorldData; import de.ellpeck.actuallyadditions.mod.data.WorldData;
import de.ellpeck.actuallyadditions.mod.entity.EntityWorm;
import de.ellpeck.actuallyadditions.mod.entity.InitEntities; import de.ellpeck.actuallyadditions.mod.entity.InitEntities;
import de.ellpeck.actuallyadditions.mod.event.CommonEvents; import de.ellpeck.actuallyadditions.mod.event.CommonEvents;
import de.ellpeck.actuallyadditions.mod.fluids.InitFluids; import de.ellpeck.actuallyadditions.mod.fluids.InitFluids;
import de.ellpeck.actuallyadditions.mod.gen.ActuallyBiomeModifiers;
import de.ellpeck.actuallyadditions.mod.gen.ActuallyVillages; import de.ellpeck.actuallyadditions.mod.gen.ActuallyVillages;
import de.ellpeck.actuallyadditions.mod.gen.modifier.BoolConfigFeatureBiomeModifier;
import de.ellpeck.actuallyadditions.mod.gen.village.ActuallyPOITypes; import de.ellpeck.actuallyadditions.mod.gen.village.ActuallyPOITypes;
import de.ellpeck.actuallyadditions.mod.gen.village.ActuallyVillagers; import de.ellpeck.actuallyadditions.mod.gen.village.ActuallyVillagers;
import de.ellpeck.actuallyadditions.mod.gen.village.InitVillager; import de.ellpeck.actuallyadditions.mod.gen.village.InitVillager;
@ -44,13 +39,8 @@ import de.ellpeck.actuallyadditions.mod.update.UpdateChecker;
import de.ellpeck.actuallyadditions.mod.util.ResourceReloader; import de.ellpeck.actuallyadditions.mod.util.ResourceReloader;
import net.minecraft.core.registries.BuiltInRegistries; import net.minecraft.core.registries.BuiltInRegistries;
import net.minecraft.resources.ResourceLocation; import net.minecraft.resources.ResourceLocation;
import net.minecraft.world.entity.EntityType;
import net.minecraft.world.entity.MobCategory;
import net.minecraft.world.item.Item; import net.minecraft.world.item.Item;
import net.minecraft.world.item.Items; import net.minecraft.world.item.Items;
import net.minecraft.world.level.biome.Biome;
import net.minecraft.world.level.levelgen.GenerationStep;
import net.minecraft.world.level.levelgen.placement.PlacedFeature;
import net.neoforged.api.distmarker.Dist; import net.neoforged.api.distmarker.Dist;
import net.neoforged.bus.api.IEventBus; import net.neoforged.bus.api.IEventBus;
import net.neoforged.fml.ModContainer; import net.neoforged.fml.ModContainer;
@ -61,19 +51,12 @@ import net.neoforged.fml.event.lifecycle.FMLCommonSetupEvent;
import net.neoforged.neoforge.client.gui.ConfigurationScreen; import net.neoforged.neoforge.client.gui.ConfigurationScreen;
import net.neoforged.neoforge.client.gui.IConfigScreenFactory; import net.neoforged.neoforge.client.gui.IConfigScreenFactory;
import net.neoforged.neoforge.common.NeoForge; import net.neoforged.neoforge.common.NeoForge;
import net.neoforged.neoforge.common.conditions.ICondition;
import net.neoforged.neoforge.common.world.BiomeModifier;
import net.neoforged.neoforge.event.AddReloadListenerEvent; import net.neoforged.neoforge.event.AddReloadListenerEvent;
import net.neoforged.neoforge.event.server.ServerStartedEvent; import net.neoforged.neoforge.event.server.ServerStartedEvent;
import net.neoforged.neoforge.event.server.ServerStoppedEvent; import net.neoforged.neoforge.event.server.ServerStoppedEvent;
import net.neoforged.neoforge.registries.DeferredHolder;
import net.neoforged.neoforge.registries.DeferredRegister;
import net.neoforged.neoforge.registries.NeoForgeRegistries;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import java.util.function.Supplier;
@Mod(ActuallyAdditions.MODID) @Mod(ActuallyAdditions.MODID)
public class ActuallyAdditions { public class ActuallyAdditions {
@ -89,22 +72,6 @@ public class ActuallyAdditions {
public static final Logger LOGGER = LoggerFactory.getLogger(MODID); public static final Logger LOGGER = LoggerFactory.getLogger(MODID);
private static final DeferredRegister<EntityType<?>> ENTITIES = DeferredRegister.create(BuiltInRegistries.ENTITY_TYPE, MODID);
public static final Supplier<EntityType<EntityWorm>> ENTITY_WORM = ENTITIES.register("worm", () -> EntityType.Builder.of(EntityWorm::new, MobCategory.MISC).build(MODID + ":worm"));
private static final DeferredRegister<MapCodec<? extends ICondition>> CONDITION_CODECS = DeferredRegister.create(NeoForgeRegistries.Keys.CONDITION_CODECS, MODID);
public static final DeferredHolder<MapCodec<? extends ICondition>, MapCodec<BoolConfigCondition>> BOOL_CONFIG_CONDITION = CONDITION_CODECS.register("bool_config_condition", () -> BoolConfigCondition.CODEC);
public static final DeferredRegister<MapCodec<? extends BiomeModifier>> BIOME_MODIFIER_SERIALIZERS = DeferredRegister.create(NeoForgeRegistries.Keys.BIOME_MODIFIER_SERIALIZERS, MODID);
public static final Supplier<MapCodec<BoolConfigFeatureBiomeModifier>> BOOL_CONFIG_MODIFIER = BIOME_MODIFIER_SERIALIZERS.register("bool_config_feature_modifier", () ->
RecordCodecBuilder.mapCodec(builder -> builder.group(
Biome.LIST_CODEC.fieldOf("biomes").forGetter(BoolConfigFeatureBiomeModifier::biomes),
PlacedFeature.LIST_CODEC.fieldOf("features").forGetter(BoolConfigFeatureBiomeModifier::features),
GenerationStep.Decoration.CODEC.fieldOf("step").forGetter(BoolConfigFeatureBiomeModifier::step),
Codec.STRING.fieldOf("boolConfig").forGetter(BoolConfigFeatureBiomeModifier::boolConfig)
).apply(builder, BoolConfigFeatureBiomeModifier::new))
);
public static boolean commonCapsLoaded; public static boolean commonCapsLoaded;
public ActuallyAdditions(IEventBus eventBus, ModContainer container, Dist dist) { public ActuallyAdditions(IEventBus eventBus, ModContainer container, Dist dist) {
@ -119,14 +86,14 @@ public class ActuallyAdditions {
ActuallyPOITypes.init(eventBus); ActuallyPOITypes.init(eventBus);
ActuallyComponents.init(eventBus); ActuallyComponents.init(eventBus);
ActuallyLootModifiers.init(eventBus); ActuallyLootModifiers.init(eventBus);
ActuallyContainers.CONTAINERS.register(eventBus); ActuallyContainers.init(eventBus);
ArmorMaterials.init(eventBus); ArmorMaterials.init(eventBus);
ENTITIES.register(eventBus); InitEntities.init(eventBus);
CONDITION_CODECS.register(eventBus); InitFluids.init(eventBus);
BIOME_MODIFIER_SERIALIZERS.register(eventBus); ActuallyBiomeModifiers.init(eventBus);
eventBus.addListener(this::onConfigReload);
ActuallyParticles.init(eventBus); ActuallyParticles.init(eventBus);
ActuallyTags.init(); ActuallyTags.init();
eventBus.addListener(this::onConfigReload);
NeoForge.EVENT_BUS.addListener(this::serverStarted); NeoForge.EVENT_BUS.addListener(this::serverStarted);
NeoForge.EVENT_BUS.addListener(this::serverStopped); NeoForge.EVENT_BUS.addListener(this::serverStopped);
@ -136,7 +103,6 @@ public class ActuallyAdditions {
NeoForge.EVENT_BUS.addListener(ActuallyAdditions::reloadEvent); NeoForge.EVENT_BUS.addListener(ActuallyAdditions::reloadEvent);
NeoForge.EVENT_BUS.addListener(Worm::onHoe); NeoForge.EVENT_BUS.addListener(Worm::onHoe);
NeoForge.EVENT_BUS.addListener(ActuallyVillages::modifyVillageStructures); NeoForge.EVENT_BUS.addListener(ActuallyVillages::modifyVillageStructures);
InitFluids.init(eventBus);
eventBus.addListener(PacketHandler::register); eventBus.addListener(PacketHandler::register);
eventBus.addListener(this::setup); eventBus.addListener(this::setup);
@ -164,7 +130,6 @@ public class ActuallyAdditions {
commonCapsLoaded = false; // Loader.isModLoaded("commoncapabilities"); commonCapsLoaded = false; // Loader.isModLoaded("commoncapabilities");
new UpdateChecker(); new UpdateChecker();
InitEntities.init(); // todo: [port] replace
} }
private void onConfigReload(ModConfigEvent event) { private void onConfigReload(ModConfigEvent event) {

View file

@ -16,6 +16,7 @@ import de.ellpeck.actuallyadditions.mod.blocks.render.RenderBatteryBox;
import de.ellpeck.actuallyadditions.mod.blocks.render.RenderDisplayStand; import de.ellpeck.actuallyadditions.mod.blocks.render.RenderDisplayStand;
import de.ellpeck.actuallyadditions.mod.blocks.render.RenderEmpowerer; import de.ellpeck.actuallyadditions.mod.blocks.render.RenderEmpowerer;
import de.ellpeck.actuallyadditions.mod.blocks.render.RenderLaserRelay; import de.ellpeck.actuallyadditions.mod.blocks.render.RenderLaserRelay;
import de.ellpeck.actuallyadditions.mod.entity.InitEntities;
import de.ellpeck.actuallyadditions.mod.entity.RenderWorm; import de.ellpeck.actuallyadditions.mod.entity.RenderWorm;
import de.ellpeck.actuallyadditions.mod.event.ClientEvents; import de.ellpeck.actuallyadditions.mod.event.ClientEvents;
import de.ellpeck.actuallyadditions.mod.fluids.InitFluids; import de.ellpeck.actuallyadditions.mod.fluids.InitFluids;
@ -142,7 +143,7 @@ public class ActuallyAdditionsClient {
event.registerBlockEntityRenderer(ActuallyBlocks.LASER_RELAY_ITEM_ADVANCED.getTileEntityType(), RenderLaserRelay::new); event.registerBlockEntityRenderer(ActuallyBlocks.LASER_RELAY_ITEM_ADVANCED.getTileEntityType(), RenderLaserRelay::new);
event.registerBlockEntityRenderer(ActuallyBlocks.LASER_RELAY_FLUIDS.getTileEntityType(), RenderLaserRelay::new); event.registerBlockEntityRenderer(ActuallyBlocks.LASER_RELAY_FLUIDS.getTileEntityType(), RenderLaserRelay::new);
event.registerEntityRenderer(ActuallyAdditions.ENTITY_WORM.get(), RenderWorm::new); event.registerEntityRenderer(InitEntities.ENTITY_WORM.get(), RenderWorm::new);
} }
public static void registerParticleFactories(RegisterParticleProvidersEvent event) { public static void registerParticleFactories(RegisterParticleProvidersEvent event) {

View file

@ -11,19 +11,19 @@
package de.ellpeck.actuallyadditions.mod.entity; package de.ellpeck.actuallyadditions.mod.entity;
import de.ellpeck.actuallyadditions.mod.ActuallyAdditions; import de.ellpeck.actuallyadditions.mod.ActuallyAdditions;
import net.minecraft.core.registries.BuiltInRegistries;
import net.minecraft.world.entity.EntityType;
import net.minecraft.world.entity.MobCategory;
import net.neoforged.bus.api.IEventBus;
import net.neoforged.neoforge.registries.DeferredRegister;
import java.util.function.Supplier;
public final class InitEntities { public final class InitEntities {
private static final DeferredRegister<EntityType<?>> ENTITIES = DeferredRegister.create(BuiltInRegistries.ENTITY_TYPE, ActuallyAdditions.MODID);
public static final Supplier<EntityType<EntityWorm>> ENTITY_WORM = ENTITIES.register("worm", () -> EntityType.Builder.of(EntityWorm::new, MobCategory.MISC).build(ActuallyAdditions.MODID + ":worm"));
public static void init() { public static void init(IEventBus bus) {
ActuallyAdditions.LOGGER.info("Initializing Entities..."); ENTITIES.register(bus);
//EntityRegistry.registerModEntity(ActuallyAdditions.modLoc("worm"), EntityWorm.class, ActuallyAdditions.MODID + ".worm", 0, ActuallyAdditions.INSTANCE, 64, 1, false);
} }
public static void initClient() {
//RenderingRegistry.registerEntityRenderingHandler(EntityWorm.class, RenderWorm::new);
}
} }

View file

@ -1,6 +1,10 @@
package de.ellpeck.actuallyadditions.mod.gen; package de.ellpeck.actuallyadditions.mod.gen;
import com.mojang.serialization.Codec;
import com.mojang.serialization.MapCodec;
import com.mojang.serialization.codecs.RecordCodecBuilder;
import de.ellpeck.actuallyadditions.mod.ActuallyAdditions; import de.ellpeck.actuallyadditions.mod.ActuallyAdditions;
import de.ellpeck.actuallyadditions.mod.config.conditions.BoolConfigCondition;
import de.ellpeck.actuallyadditions.mod.gen.modifier.BoolConfigFeatureBiomeModifier; import de.ellpeck.actuallyadditions.mod.gen.modifier.BoolConfigFeatureBiomeModifier;
import net.minecraft.core.HolderGetter; import net.minecraft.core.HolderGetter;
import net.minecraft.core.HolderSet; import net.minecraft.core.HolderSet;
@ -11,10 +15,35 @@ import net.minecraft.tags.BiomeTags;
import net.minecraft.world.level.biome.Biome; import net.minecraft.world.level.biome.Biome;
import net.minecraft.world.level.levelgen.GenerationStep; import net.minecraft.world.level.levelgen.GenerationStep;
import net.minecraft.world.level.levelgen.placement.PlacedFeature; import net.minecraft.world.level.levelgen.placement.PlacedFeature;
import net.neoforged.bus.api.IEventBus;
import net.neoforged.neoforge.common.conditions.ICondition;
import net.neoforged.neoforge.common.world.BiomeModifier; import net.neoforged.neoforge.common.world.BiomeModifier;
import net.neoforged.neoforge.registries.DeferredHolder;
import net.neoforged.neoforge.registries.DeferredRegister;
import net.neoforged.neoforge.registries.NeoForgeRegistries; import net.neoforged.neoforge.registries.NeoForgeRegistries;
public class ActuallyBiomeModifiers { import java.util.function.Supplier;
public final class ActuallyBiomeModifiers {
private static final DeferredRegister<MapCodec<? extends ICondition>> CONDITION_CODECS = DeferredRegister.create(NeoForgeRegistries.Keys.CONDITION_CODECS, ActuallyAdditions.MODID);
public static final DeferredHolder<MapCodec<? extends ICondition>, MapCodec<BoolConfigCondition>> BOOL_CONFIG_CONDITION = CONDITION_CODECS.register("bool_config_condition", () -> BoolConfigCondition.CODEC);
public static final DeferredRegister<MapCodec<? extends BiomeModifier>> BIOME_MODIFIER_SERIALIZERS = DeferredRegister.create(NeoForgeRegistries.Keys.BIOME_MODIFIER_SERIALIZERS, ActuallyAdditions.MODID);
public static final Supplier<MapCodec<BoolConfigFeatureBiomeModifier>> BOOL_CONFIG_MODIFIER = BIOME_MODIFIER_SERIALIZERS.register("bool_config_feature_modifier", () ->
RecordCodecBuilder.mapCodec(builder -> builder.group(
Biome.LIST_CODEC.fieldOf("biomes").forGetter(BoolConfigFeatureBiomeModifier::biomes),
PlacedFeature.LIST_CODEC.fieldOf("features").forGetter(BoolConfigFeatureBiomeModifier::features),
GenerationStep.Decoration.CODEC.fieldOf("step").forGetter(BoolConfigFeatureBiomeModifier::step),
Codec.STRING.fieldOf("boolConfig").forGetter(BoolConfigFeatureBiomeModifier::boolConfig)
).apply(builder, BoolConfigFeatureBiomeModifier::new))
);
public static void init(IEventBus bus) {
CONDITION_CODECS.register(bus);
BIOME_MODIFIER_SERIALIZERS.register(bus);
}
protected static final ResourceKey<BiomeModifier> ADD_BLACK_QUARTZ_ORE_MODIFIER = ResourceKey.create(NeoForgeRegistries.Keys.BIOME_MODIFIERS, protected static final ResourceKey<BiomeModifier> ADD_BLACK_QUARTZ_ORE_MODIFIER = ResourceKey.create(NeoForgeRegistries.Keys.BIOME_MODIFIERS,
ActuallyAdditions.modLoc("add_black_quartz")); ActuallyAdditions.modLoc("add_black_quartz"));

View file

@ -1,8 +1,8 @@
package de.ellpeck.actuallyadditions.mod.gen.modifier; package de.ellpeck.actuallyadditions.mod.gen.modifier;
import com.mojang.serialization.MapCodec; import com.mojang.serialization.MapCodec;
import de.ellpeck.actuallyadditions.mod.ActuallyAdditions;
import de.ellpeck.actuallyadditions.mod.config.CommonConfig; import de.ellpeck.actuallyadditions.mod.config.CommonConfig;
import de.ellpeck.actuallyadditions.mod.gen.ActuallyBiomeModifiers;
import net.minecraft.core.Holder; import net.minecraft.core.Holder;
import net.minecraft.core.HolderSet; import net.minecraft.core.HolderSet;
import net.minecraft.world.level.biome.Biome; import net.minecraft.world.level.biome.Biome;
@ -34,6 +34,6 @@ public record BoolConfigFeatureBiomeModifier(HolderSet<Biome> biomes, HolderSet<
@Override @Override
public MapCodec<? extends BiomeModifier> codec() { public MapCodec<? extends BiomeModifier> codec() {
return ActuallyAdditions.BOOL_CONFIG_MODIFIER.get(); return ActuallyBiomeModifiers.BOOL_CONFIG_MODIFIER.get();
} }
} }

View file

@ -3,13 +3,14 @@ package de.ellpeck.actuallyadditions.mod.inventory;
import de.ellpeck.actuallyadditions.mod.ActuallyAdditions; import de.ellpeck.actuallyadditions.mod.ActuallyAdditions;
import net.minecraft.core.registries.BuiltInRegistries; import net.minecraft.core.registries.BuiltInRegistries;
import net.minecraft.world.inventory.MenuType; import net.minecraft.world.inventory.MenuType;
import net.neoforged.bus.api.IEventBus;
import net.neoforged.neoforge.common.extensions.IMenuTypeExtension; import net.neoforged.neoforge.common.extensions.IMenuTypeExtension;
import net.neoforged.neoforge.registries.DeferredRegister; import net.neoforged.neoforge.registries.DeferredRegister;
import java.util.function.Supplier; import java.util.function.Supplier;
public class ActuallyContainers { public class ActuallyContainers {
public static final DeferredRegister<MenuType<?>> CONTAINERS = DeferredRegister.create(BuiltInRegistries.MENU, ActuallyAdditions.MODID); private static final DeferredRegister<MenuType<?>> CONTAINERS = DeferredRegister.create(BuiltInRegistries.MENU, ActuallyAdditions.MODID);
public static final Supplier<MenuType<SackContainer>> SACK_CONTAINER = CONTAINERS.register("sack_container", () -> IMenuTypeExtension.create(SackContainer::fromNetwork)); public static final Supplier<MenuType<SackContainer>> SACK_CONTAINER = CONTAINERS.register("sack_container", () -> IMenuTypeExtension.create(SackContainer::fromNetwork));
public static final Supplier<MenuType<VoidSackContainer>> VOID_SACK_CONTAINER = CONTAINERS.register("void_sack_container", () -> IMenuTypeExtension.create(VoidSackContainer::new)); public static final Supplier<MenuType<VoidSackContainer>> VOID_SACK_CONTAINER = CONTAINERS.register("void_sack_container", () -> IMenuTypeExtension.create(VoidSackContainer::new));
@ -39,5 +40,9 @@ public class ActuallyContainers {
public static final Supplier<MenuType<ContainerRangedCollector>> RANGED_COLLECTOR_CONTAINER = CONTAINERS.register("ranged_collector_container", () -> IMenuTypeExtension.create(ContainerRangedCollector::fromNetwork)); public static final Supplier<MenuType<ContainerRangedCollector>> RANGED_COLLECTOR_CONTAINER = CONTAINERS.register("ranged_collector_container", () -> IMenuTypeExtension.create(ContainerRangedCollector::fromNetwork));
public static final Supplier<MenuType<ContainerXPSolidifier>> XPSOLIDIFIER_CONTAINER = CONTAINERS.register("xpsolidifier_container", () -> IMenuTypeExtension.create(ContainerXPSolidifier::fromNetwork)); public static final Supplier<MenuType<ContainerXPSolidifier>> XPSOLIDIFIER_CONTAINER = CONTAINERS.register("xpsolidifier_container", () -> IMenuTypeExtension.create(ContainerXPSolidifier::fromNetwork));
public static final Supplier<MenuType<ItemTagContainer>> ITEM_TAG_CONTAINER = CONTAINERS.register("item_tag_container", () -> IMenuTypeExtension.create(ItemTagContainer::fromNetwork)); public static final Supplier<MenuType<ItemTagContainer>> ITEM_TAG_CONTAINER = CONTAINERS.register("item_tag_container", () -> IMenuTypeExtension.create(ItemTagContainer::fromNetwork));
public static void init(IEventBus evt) {
CONTAINERS.register(evt);
}
} }

View file

@ -10,9 +10,9 @@
package de.ellpeck.actuallyadditions.mod.items; package de.ellpeck.actuallyadditions.mod.items;
import de.ellpeck.actuallyadditions.mod.ActuallyAdditions;
import de.ellpeck.actuallyadditions.mod.config.CommonConfig; import de.ellpeck.actuallyadditions.mod.config.CommonConfig;
import de.ellpeck.actuallyadditions.mod.entity.EntityWorm; import de.ellpeck.actuallyadditions.mod.entity.EntityWorm;
import de.ellpeck.actuallyadditions.mod.entity.InitEntities;
import de.ellpeck.actuallyadditions.mod.items.base.ItemBase; import de.ellpeck.actuallyadditions.mod.items.base.ItemBase;
import net.minecraft.core.BlockPos; import net.minecraft.core.BlockPos;
import net.minecraft.world.InteractionResult; import net.minecraft.world.InteractionResult;
@ -48,7 +48,7 @@ public class Worm extends ItemBase {
if (!worms.isEmpty()) if (!worms.isEmpty())
return super.useOn(context); return super.useOn(context);
EntityWorm worm = new EntityWorm(ActuallyAdditions.ENTITY_WORM.get(), level); EntityWorm worm = new EntityWorm(InitEntities.ENTITY_WORM.get(), level);
worm.setPos(pos.getX() + 0.5, pos.getY() + 0.5, pos.getZ() + 0.5); worm.setPos(pos.getX() + 0.5, pos.getY() + 0.5, pos.getZ() + 0.5);
worm.setCustomName(stack.getHoverName()); worm.setCustomName(stack.getHoverName());
level.addFreshEntity(worm); level.addFreshEntity(worm);

View file

@ -1,25 +0,0 @@
// TODO: [port] not used
///*
// * This file ("ISmileyCloudEasterEgg.java") is part of the Actually Additions mod for Minecraft.
// * It is created and owned by Ellpeck and distributed
// * under the Actually Additions License to be found at
// * http://ellpeck.de/actaddlicense
// * View the source code at https://github.com/Ellpeck/ActuallyAdditions
// *
// * © 2015-2017 Ellpeck
// */
//
//package de.ellpeck.actuallyadditions.mod.misc.cloud;
//
//public interface ISmileyCloudEasterEgg {
//
// /**
// * Extra rendering function
// */
// void renderExtra(float f);
//
// /**
// * The name the cloud has to have for this effect to occur
// */
// String[] getTriggerNames();
//}

View file

@ -1,524 +0,0 @@
// TODO: [port] not used
///*
// * This file ("SmileyCloudEasterEggs.java") is part of the Actually Additions mod for Minecraft.
// * It is created and owned by Ellpeck and distributed
// * under the Actually Additions License to be found at
// * http://ellpeck.de/actaddlicense
// * View the source code at https://github.com/Ellpeck/ActuallyAdditions
// *
// * © 2015-2017 Ellpeck
// */
//
//package de.ellpeck.actuallyadditions.mod.misc.cloud;
//
//import java.util.ArrayList;
//import java.util.List;
//
//import de.ellpeck.actuallyadditions.mod.blocks.InitBlocks;
//import de.ellpeck.actuallyadditions.mod.items.InitItems;
//import de.ellpeck.actuallyadditions.mod.items.metalists.TheFoods;
//import de.ellpeck.actuallyadditions.mod.items.metalists.TheMiscItems;
//import de.ellpeck.actuallyadditions.mod.util.AssetUtil;
//import net.minecraft.block.Block;
//
//import net.minecraft.init.Blocks;
//import net.minecraft.init.Items;
//import net.minecraft.item.ItemStack;
//
//public final class SmileyCloudEasterEggs {
//
// public static final List<ISmileyCloudEasterEgg> CLOUD_STUFF = new ArrayList<>();
//
// static {
// //Glenthor
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "glenthor", "glenthorlp", "twoofeight" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(true, new ItemStack(Items.DYE, 1, 2));
// renderHeadBlock(InitBlocks.blockHeatCollector, 0, 5F);
// }
// });
// //Ellpeck
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "ellpeck", "ellopecko", "peck" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(InitItems.itemPhantomConnector));
// renderHeadBlock(InitBlocks.blockPhantomLiquiface, 0, 25F);
// }
// });
// //Tyrex
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "tyrex", "lord_tobinho", "tobinho" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(Items.FISHING_ROD));
// renderHoldingItem(true, new ItemStack(Items.FISH));
// }
// });
// //Hose
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "dqmhose", "xdqmhose", "hose" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(Items.REEDS));
// renderHeadBlock(Blocks.TORCH, 0, 15F);
// }
// });
// //Tobi
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "jemx", "jemxx", "jemxxx", "spielertobi200" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(true, new ItemStack(Items.MILK_BUCKET));
// renderHeadBlock(Blocks.REDSTONE_LAMP, 0, 35F);
// }
// });
// //Vazkii
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "vazkii", "vaski", "waskie" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(true, new ItemStack(Items.DYE, 1, 15));
// renderHeadBlock(Blocks.RED_FLOWER, 5, 20F);
// }
// });
// //Kitty
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "kitty", "kiddy", "kittyvancat", "kittyvancatlp" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(true, new ItemStack(Items.FISH));
// renderHoldingItem(false, new ItemStack(Items.MILK_BUCKET));
// renderHeadBlock(Blocks.WOOL, 10, 15F);
// }
// });
// //Canitzp
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "canitz", "canitzp", "kannnichts", "kannnichtsp" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(Items.WOODEN_SWORD));
// renderHeadBlock(Blocks.CHEST, 0, 70F);
// }
// });
// //Lari
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "lari", "larixine", "xine", "laxi", "lachsirine", "lala", "lalilu" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(Items.IRON_HELMET));
// renderHeadBlock(InitBlocks.blockBlackLotus, 0, 28F);
// }
// });
// //RotesDing
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "rotesding", "dotesring" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(Items.MILK_BUCKET));
// renderHoldingItem(true, new ItemStack(Items.DYE, 1, 1));
// renderHeadBlock(Blocks.WOOL, 14, 18F);
// }
// });
// //Bande
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "bande", "bandelenth" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(Items.DIAMOND_PICKAXE));
// renderHeadBlock(Blocks.WOOL, 4, 18F);
// }
// });
// //Wolle
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "wolle", "wuitoi" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(Items.STRING));
// renderHeadBlock(Blocks.WOOL, 0, 18F);
// }
// });
// //Pakto
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "pakto", "paktosan", "paktosanlp" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(Items.DYE, 1, 9));
// renderHeadBlock(InitBlocks.blockColoredLampOn, 6, 18F);
// }
// });
// //Honka
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "honka", "honkalonka", "lonka", "lonki" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(InitItems.itemLeafBlowerAdvanced, 1, 9));
// renderHeadBlock(Blocks.HAY_BLOCK, 0, 74F);
// }
// });
// //Acid
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "acid", "acid_blues", "acidblues" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(InitItems.itemFoods, 1, TheFoods.PIZZA.ordinal()));
// renderHeadBlock(Blocks.BOOKSHELF, 0, 27F);
// }
// });
// //Jasin
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "jasin", "jasindow" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(Items.WRITTEN_BOOK));
// renderHeadBlock(Blocks.WEB, 0, 56F);
// }
// });
// //ShadowNinjaCat
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "shadowninjacat", "ninja", "tl" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(Items.DIAMOND_SWORD));
// renderHeadBlock(Blocks.DIAMOND_BLOCK, 0, 26F);
// }
// });
// //NihonTiger
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "nihon", "nihontiger", "tiger" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(Items.STONE_PICKAXE));
// renderHoldingItem(true, new ItemStack(Items.POISONOUS_POTATO));
// renderHeadBlock(Blocks.GRAVEL, 0, 47F);
// }
// });
// //FrauBaerchen
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "fraubaerchen", "baerchen", "nina" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(Items.COOKIE));
// renderHoldingItem(true, new ItemStack(Items.PAPER));
// renderHeadBlock(Blocks.COAL_BLOCK, 0, 60F);
// }
// });
// //Diddi
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "0xdd", "didi", "diddi", "theultimatehose" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(true, new ItemStack(InitItems.itemDrill));
// renderHeadBlock(Blocks.REDSTONE_BLOCK, 0, 30F);
// }
// });
// //MineLoad
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "mineload", "miney", "loady", "mineyloady" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(InitItems.itemMagnetRing));
// renderHeadBlock(Blocks.CRAFTING_TABLE, 0, 35F);
// }
// });
// //Kilobyte (When I asked him if he liked the mod, he just looked at the code. Maybe he'll find this eventually.)
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "kilobyte", "kilo", "byte" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(InitItems.itemMisc, 1, TheMiscItems.DRILL_CORE.ordinal()));
// renderHeadBlock(Blocks.REDSTONE_ORE, 0, 80F);
// }
// });
// //XDjackieXD
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "jackie", "xdjackiexd", "xdjackie", "jackiexd" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(Items.ENCHANTED_BOOK));
// renderHeadBlock(InitBlocks.blockDirectionalBreaker, 0, 40F);
// }
// });
// //Little Lampi (I still can't get over it)
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "lampi", "littlelampi", "little lampi" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(Items.GLOWSTONE_DUST));
// renderHeadBlock(InitBlocks.blockColoredLampOn, 4, 40F);
// }
// });
// //AtomSponge
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "sponge", "atomsponge", "atom", "explosions", "explosion" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(Items.GUNPOWDER));
// renderHeadBlock(Blocks.SPONGE, 0, 20F);
// }
// });
// //Mattzimann
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "mattzimann", "mattziman", "matziman", "marzipan", "mattzi" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(InitItems.itemSwordEmerald));
// renderHeadBlock(InitBlocks.blockCoffeeMachine, 0, 35F);
// }
// });
// //Etho
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "etho", "ethoslab" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(Items.REDSTONE));
// renderHeadBlock(Blocks.REDSTONE_BLOCK, 0, 48F);
// }
// });
// //Direwolf20
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "direwolf", "dire", "direwolf20", "dw20" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(Items.BONE));
// renderHeadBlock(Blocks.BONE_BLOCK, 0, 48F);
// }
// });
// //Jessassin
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "jessassin", "thejessassin" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHeadBlock(InitBlocks.blockLaserRelayItem, 0, 27F);
// renderHoldingItem(false, new ItemStack(InitItems.itemLaserWrench));
// }
// });
// //Biffa
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "biffa", "biffatech", "biffaplays", "biffa2001" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(InitItems.itemCoffee));
// }
// });
// //Xisuma
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "xisuma", "xisumavoid" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHeadBlock(Blocks.REDSTONE_BLOCK, 0, 93F);
// renderHoldingItem(false, new ItemStack(Items.ELYTRA));
// }
// });
// //Welsknight
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "welsknight", "wels" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHeadBlock(Blocks.STONE_BRICK_STAIRS, 0, 10F);
// renderHoldingItem(false, new ItemStack(Items.DIAMOND_PICKAXE));
// }
// });
// //xbony2
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "bony", "xbony", "xbony2" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHoldingItem(false, new ItemStack(InitItems.itemBooklet));
// renderHeadBlock(InitBlocks.blockSmileyCloud, 0, 13F);
// }
// });
// //MattaBase
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "themattabase", "mattabase", "matt", "mad" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHeadBlock(Blocks.WOOL, 13, 35F);
// renderHoldingItem(false, new ItemStack(InitItems.itemSwordQuartz));
// renderHoldingItem(true, new ItemStack(Items.SHIELD));
// }
// });
// //Cloudy
// register(new ISmileyCloudEasterEgg() {
// @Override
// public String[] getTriggerNames() {
// return new String[] { "cloudy", "cloudhunter" };
// }
//
// @Override
// public void renderExtra(float f) {
// renderHeadBlock(Blocks.REDSTONE_BLOCK, 0, 17F);
// //other hand is for fapping
// renderHoldingItem(true, new ItemStack(Items.BOW));
// }
// });
// }
//
// private static void register(ISmileyCloudEasterEgg egg) {
// CLOUD_STUFF.add(egg);
// }
//
// private static void renderHoldingItem(boolean leftHand, ItemStack stack) {
// GlStateManager.pushMatrix();
// GlStateManager.rotate(180F, 0F, 0F, 1F);
// GlStateManager.rotate(90, 0, 1, 0);
// GlStateManager.translate(-0.15, -1F, leftHand ? -0.525F : 0.525F);
// GlStateManager.scale(0.75F, 0.75F, 0.75F);
//
// AssetUtil.renderItemInWorld(stack);
//
// GlStateManager.popMatrix();
// }
//
// private static void renderHeadBlock(Block block, int meta, float rotation) {
// GlStateManager.pushMatrix();
// GlStateManager.disableLighting();
// GlStateManager.translate(-0.015F, 0.625F, 0.04F);
// GlStateManager.scale(0.5F, 0.5F, 0.5F);
// GlStateManager.rotate(180F, 1F, 0F, 0F);
// GlStateManager.rotate(rotation, 0F, 1F, 0F);
//
// AssetUtil.renderBlockInWorld(block, meta);
//
// GlStateManager.enableLighting();
// GlStateManager.popMatrix();
// }
//}

View file

@ -76,9 +76,6 @@ public final class PacketHandler {
double outY = compound.getDouble("OutY") + 0.525; double outY = compound.getDouble("OutY") + 0.525;
double outZ = compound.getDouble("OutZ") + 0.5; double outZ = compound.getDouble("OutZ") + 0.5;
// Particle fx = new ParticleLaserItem(mc.level, outX, outY, outZ, stack, 0.025, inX, inY, inZ);
//mc.effectRenderer.addEffect(fx); //TODO
mc.level.addParticle(ParticleLaserItem.Factory.createData(stack, inX, inY, inZ), mc.level.addParticle(ParticleLaserItem.Factory.createData(stack, inX, inY, inZ),
outX, outY, outZ, 0, 0.025, 0); outX, outY, outZ, 0, 0.025, 0);
} }

View file

@ -1,57 +0,0 @@
// TODO: [port][note] no longer required
///*
// * This file ("TreasureChestHandler.java") is part of the Actually Additions mod for Minecraft.
// * It is created and owned by Ellpeck and distributed
// * under the Actually Additions License to be found at
// * http://ellpeck.de/actaddlicense
// * View the source code at https://github.com/Ellpeck/ActuallyAdditions
// *
// * © 2015-2017 Ellpeck
// */
//
//package de.ellpeck.actuallyadditions.mod.recipe;
//
//import de.ellpeck.actuallyadditions.api.ActuallyAdditionsAPI;
//import de.ellpeck.actuallyadditions.mod.items.InitItems;
//import de.ellpeck.actuallyadditions.mod.items.metalists.TheJams;
//import net.minecraft.init.Items;
//import net.minecraft.item.ItemStack;
//
//public final class TreasureChestHandler {
//
// public static void init() {
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.DIAMOND), 5, 1, 2);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.IRON_INGOT), 30, 1, 5);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.GOLD_NUGGET), 60, 1, 8);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.GOLD_INGOT), 35, 1, 3);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.ENDER_PEARL), 10, 1, 2);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.EMERALD), 3, 1, 1);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.EXPERIENCE_BOTTLE), 5, 3, 6);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(InitItems.itemSolidifiedExperience), 15, 3, 6);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.RECORD_11), 1, 1, 1);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.RECORD_13), 1, 1, 1);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.RECORD_BLOCKS), 1, 1, 1);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.RECORD_CAT), 1, 1, 1);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.RECORD_CHIRP), 1, 1, 1);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.RECORD_FAR), 1, 1, 1);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.RECORD_MALL), 1, 1, 1);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.RECORD_MELLOHI), 1, 1, 1);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.RECORD_STAL), 1, 1, 1);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.RECORD_STRAD), 1, 1, 1);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.RECORD_WARD), 1, 1, 1);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.RECORD_WAIT), 1, 1, 1);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.SADDLE), 5, 1, 1);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.NAME_TAG), 20, 1, 2);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(InitItems.itemJams, 1, TheJams.CU_BA_RA.ordinal()), 10, 1, 2);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(InitItems.itemJams, 1, TheJams.GRA_KI_BA.ordinal()), 10, 1, 2);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(InitItems.itemJams, 1, TheJams.PL_AP_LE.ordinal()), 10, 1, 2);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(InitItems.itemJams, 1, TheJams.CH_AP_CI.ordinal()), 10, 1, 2);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(InitItems.itemJams, 1, TheJams.HO_ME_KI.ordinal()), 10, 1, 2);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(InitItems.itemJams, 1, TheJams.PI_CO.ordinal()), 10, 1, 2);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.FISH), 80, 1, 3);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.FISH, 1, 1), 60, 1, 3);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.FISH, 1, 2), 10, 1, 1);
// ActuallyAdditionsAPI.addTreasureChestLoot(new ItemStack(Items.FISH, 1, 3), 40, 1, 2);
// }
//
//}

View file

@ -49,25 +49,11 @@ public abstract class TileEntityBase extends BlockEntity {
this.writeSyncableNBT(compound, lookupProvider, NBTType.SAVE_TILE); this.writeSyncableNBT(compound, lookupProvider, NBTType.SAVE_TILE);
} }
// TODO: [port] remove if the above is correct
// @Override
// public final CompoundNBT writeToNBT(CompoundNBT compound) {
// this.writeSyncableNBT(compound, NBTType.SAVE_TILE);
// return compound;
// }
@Override @Override
public void loadAdditional(CompoundTag compound, HolderLookup.Provider lookupProvider) { public void loadAdditional(CompoundTag compound, HolderLookup.Provider lookupProvider) {
this.readSyncableNBT(compound, lookupProvider, NBTType.SAVE_TILE); this.readSyncableNBT(compound, lookupProvider, NBTType.SAVE_TILE);
} }
// TODO: [port] remove if the above is correct
// @Override
// public final void readFromNBT(CompoundNBT compound) {
// this.readSyncableNBT(compound, NBTType.SAVE_TILE);
// }
@Nullable @Nullable
@Override @Override
public ClientboundBlockEntityDataPacket getUpdatePacket() { public ClientboundBlockEntityDataPacket getUpdatePacket() {
@ -150,22 +136,6 @@ public abstract class TileEntityBase extends BlockEntity {
} }
} }
// TODO: [port] eval if still required in some way
// @Override
// public boolean shouldRefresh(World world, BlockPos pos, BlockState oldState, BlockState newState) {
// return !oldState.getBlock().isAssociatedBlock(newState.getBlock());
// }
@Deprecated
public String getNameForTranslation() {
return "removeme";// "container.actuallyadditions." + this.name + ".name";
}
// @Override
// public ITextComponent getDisplayName() {
// return new TranslationTextComponent(this.getNameForTranslation());
// }
public int getComparatorStrength() { public int getComparatorStrength() {
return 0; return 0;
} }

View file

@ -78,16 +78,20 @@ public class TileEntityBreaker extends TileEntityInventoryBase implements MenuPr
public static <T extends BlockEntity> void serverTick(Level level, BlockPos pos, BlockState state, T t) { public static <T extends BlockEntity> void serverTick(Level level, BlockPos pos, BlockState state, T t) {
if (t instanceof TileEntityBreaker tile) { if (t instanceof TileEntityBreaker tile) {
tile.serverTick(); tile.serverTick();
}
}
if (!tile.isRedstonePowered && !tile.isPulseMode) { @Override
if (tile.currentTime > 0) { protected void serverTick() {
tile.currentTime--; super.serverTick();
if (tile.currentTime <= 0) { if (!isRedstonePowered && !isPulseMode) {
tile.doWork(); if (currentTime > 0) {
currentTime--;
if (currentTime <= 0) {
doWork();
} }
} else { } else {
tile.currentTime = 15; currentTime = 15;
}
} }
} }
} }

View file

@ -1,141 +0,0 @@
// FIXME: [port] No longer required
///*
// * This file ("TileEntityCompost.java") is part of the Actually Additions mod for Minecraft.
// * It is created and owned by Ellpeck and distributed
// * under the Actually Additions License to be found at
// * http://ellpeck.de/actaddlicense
// * View the source code at https://github.com/Ellpeck/ActuallyAdditions
// *
// * © 2015-2017 Ellpeck
// */
//
//package de.ellpeck.actuallyadditions.mod.tile;
//
//import de.ellpeck.actuallyadditions.api.ActuallyAdditionsAPI;
//import de.ellpeck.actuallyadditions.api.recipe.CompostRecipe;
//import de.ellpeck.actuallyadditions.mod.util.ItemStackHandlerAA.IAcceptor;
//import de.ellpeck.actuallyadditions.mod.util.ItemStackHandlerAA.IRemover;
//import de.ellpeck.actuallyadditions.mod.util.ItemUtil;
//import de.ellpeck.actuallyadditions.mod.util.StackUtil;
//import net.minecraft.block.BlockState;
//import net.minecraft.init.Blocks;
//import net.minecraft.item.ItemStack;
//import net.minecraft.nbt.CompoundNBT;
//
//public class TileEntityCompost extends TileEntityInventoryBase {
//
// public static final int COMPOST_TIME_TICKS = 3000;
//
// protected int conversionTime;
// protected CompostRecipe recipe;
//
// public TileEntityCompost() {
// super(ActuallyTiles.COMPOST_TILE.get(), 1);
// }
//
// public static CompostRecipe getRecipeForInput(ItemStack input) {
// if (StackUtil.isValid(input)) {
// for (CompostRecipe recipe : ActuallyAdditionsAPI.COMPOST_RECIPES) {
// if (recipe.matches(input)) {
// return recipe;
// }
// }
// }
// return null;
// }
//
// @Override
// public void writeSyncableNBT(CompoundNBT compound, NBTType type) {
// super.writeSyncableNBT(compound, lookupProvider, type);
// if (type != NBTType.SAVE_BLOCK) {
// compound.putInt("ConversionTime", this.conversionTime);
// }
// }
//
// @Override
// public boolean shouldSyncSlots() {
// return true;
// }
//
// @Override
// public void readSyncableNBT(CompoundNBT compound, NBTType type) {
// super.readSyncableNBT(compound, lookupProvider, type);
// if (type != NBTType.SAVE_BLOCK) {
// this.conversionTime = compound.getInt("ConversionTime");
// }
// if (type == NBTType.SYNC) {
// this.world.markBlockRangeForRenderUpdate(this.pos, this.pos.up());
// }
// }
//
// @Override
// public void updateEntity() {
// super.updateEntity();
// if (!this.world.isRemote) {
// boolean theFlag = this.conversionTime > 0;
// ItemStack input = this.inv.getStackInSlot(0);
// if (StackUtil.isValid(input)) {
// if (this.recipe == null || !this.recipe.matches(input)) {
// this.recipe = getRecipeForInput(input);
// }
// if (this.recipe != null) {
// this.conversionTime++;
// if (this.conversionTime >= COMPOST_TIME_TICKS) {
// ItemStack stack = this.recipe.getOutput().copy();
// stack.setCount(input.getCount());
// this.inv.setStackInSlot(0, stack);
// this.conversionTime = 0;
// this.markDirty();
// }
// } else {
// this.conversionTime = 0;
// }
// }
//
// if (theFlag != this.conversionTime > 0) {
// this.markDirty();
// }
// }
// }
//
// @Override
// public IAcceptor getAcceptor() {
// return (slot, stack, automation) -> getRecipeForInput(stack) != null;
// }
//
// @Override
// public IRemover getRemover() {
// return (slot, automation) -> getRecipeForInput(this.inv.getStackInSlot(slot)) == null;
// }
//
// public BlockState getCurrentDisplay() {
// ItemStack input = this.inv.getStackInSlot(0);
// CompostRecipe displayRecipe = this.recipe;
// if (displayRecipe == null || !displayRecipe.matches(input)) {
// displayRecipe = getRecipeForInput(input);
// }
//
// if (displayRecipe == null) {
// for (CompostRecipe r : ActuallyAdditionsAPI.COMPOST_RECIPES) {
// if (ItemUtil.areItemsEqual(input, r.getOutput(), true)) {
// return r.getOutputDisplay();
// } else if (r.getInput().apply(input)) {
// return r.getInputDisplay();
// }
// }
// }
//
// if (displayRecipe != null) {
// return displayRecipe.getInputDisplay();
// }
// return Blocks.AIR.getDefaultState();
// }
//
// public float getHeight() {
// ItemStack input = this.inv.getStackInSlot(0);
// if (input.isEmpty()) {
// return 0;
// }
// return (float) input.getCount() / input.getMaxStackSize();
// }
//}

View file

@ -35,38 +35,11 @@ public abstract class TileEntityInventoryBase extends TileEntityBase {
this.inv = new TileStackHandler(slots); this.inv = new TileStackHandler(slots);
} }
public static void saveSlots(IItemHandler slots, CompoundTag compound, HolderLookup.Provider provider) {
if (slots != null && slots.getSlots() > 0) {
ListTag tagList = new ListTag();
for (int i = 0; i < slots.getSlots(); i++) {
ItemStack slot = slots.getStackInSlot(i);
CompoundTag tagCompound = new CompoundTag();
if (StackUtil.isValid(slot)) {
slot.save(provider, tagCompound);
}
tagList.add(tagCompound);
}
compound.put("Items", tagList);
}
}
public static void loadSlots(IItemHandlerModifiable slots, CompoundTag compound, HolderLookup.Provider provider) {
if (slots != null && slots.getSlots() > 0) {
ListTag tagList = compound.getList("Items", 10);
for (int i = 0; i < slots.getSlots(); i++) {
CompoundTag tagCompound = tagList.getCompound(i);
slots.setStackInSlot(i, tagCompound.contains("id")
? ItemStack.parseOptional(provider, tagCompound)
: ItemStack.EMPTY);
}
}
}
@Override @Override
public void writeSyncableNBT(CompoundTag compound, HolderLookup.Provider lookupProvider, NBTType type) { public void writeSyncableNBT(CompoundTag compound, HolderLookup.Provider lookupProvider, NBTType type) {
super.writeSyncableNBT(compound, lookupProvider, type); super.writeSyncableNBT(compound, lookupProvider, type);
if (type == NBTType.SAVE_TILE || type == NBTType.SYNC && this.shouldSyncSlots()) { if (type == NBTType.SAVE_TILE || type == NBTType.SYNC && this.shouldSyncSlots()) {
saveSlots(this.inv, compound, lookupProvider); compound.put("Items", this.inv.serializeNBT(lookupProvider));
} }
} }
@ -109,7 +82,7 @@ public abstract class TileEntityInventoryBase extends TileEntityBase {
public void readSyncableNBT(CompoundTag compound, HolderLookup.Provider lookupProvider, NBTType type) { public void readSyncableNBT(CompoundTag compound, HolderLookup.Provider lookupProvider, NBTType type) {
super.readSyncableNBT(compound, lookupProvider, type); super.readSyncableNBT(compound, lookupProvider, type);
if (type == NBTType.SAVE_TILE || type == NBTType.SYNC && this.shouldSyncSlots()) { if (type == NBTType.SAVE_TILE || type == NBTType.SYNC && this.shouldSyncSlots()) {
loadSlots(this.inv, compound, lookupProvider); this.inv.deserializeNBT(lookupProvider, compound.getCompound("Items"));
} }
} }

View file

@ -174,12 +174,6 @@ public abstract class TileEntityLaserRelay extends TileEntityInventoryBase {
return this.cachedNetwork; return this.cachedNetwork;
} }
// @Override TODO: Fix the renderBoundingBox
//
// public AABB getRenderBoundingBox() {
// return INFINITE_EXTENT_AABB;
// }
@Override @Override
public boolean shouldSyncSlots() { public boolean shouldSyncSlots() {
return true; return true;

View file

@ -110,7 +110,6 @@ public class TileEntityLaserRelayEnergy extends TileEntityLaserRelay {
return transmitted; return transmitted;
} }
// TODO: [port] this is super hacky, review and fix up
@Override @Override
public IEnergyStorage getEnergyStorage(Direction facing) { public IEnergyStorage getEnergyStorage(Direction facing) {
return this.energyStorages[facing == null return this.energyStorages[facing == null

View file

@ -248,13 +248,11 @@ public class TileEntityLaserRelayFluids extends TileEntityLaserRelay {
} }
@Override @Override
public Component getExtraDisplayString() { public Component getExtraDisplayString() {
return Component.translatable("info.actuallyadditions.laserRelay.fluid.extra").append(": ").append(Component.translatable(this.mode.name).withStyle(ChatFormatting.DARK_RED)); return Component.translatable("info.actuallyadditions.laserRelay.fluid.extra").append(": ").append(Component.translatable(this.mode.name).withStyle(ChatFormatting.DARK_RED));
} }
@Override @Override
public Component getCompassDisplayString() { public Component getCompassDisplayString() {
return Component.translatable("info.actuallyadditions.laserRelay.energy.display").withStyle(ChatFormatting.GREEN); return Component.translatable("info.actuallyadditions.laserRelay.energy.display").withStyle(ChatFormatting.GREEN);
} }

View file

@ -1,61 +0,0 @@
// TODO: [port][note]: Not used
///*
// * This file ("TileEntitySmileyCloud.java") is part of the Actually Additions mod for Minecraft.
// * It is created and owned by Ellpeck and distributed
// * under the Actually Additions License to be found at
// * http://ellpeck.de/actaddlicense
// * View the source code at https://github.com/Ellpeck/ActuallyAdditions
// *
// * © 2015-2017 Ellpeck
// */
//
//package de.ellpeck.actuallyadditions.mod.tile;
//
//import de.ellpeck.actuallyadditions.mod.network.gui.IStringReactor;
//import net.minecraft.entity.player.PlayerEntity;
//import net.minecraft.nbt.CompoundNBT;
//
//public class TileEntitySmileyCloud extends TileEntityBase implements IStringReactor {
//
// public String name;
// private String nameBefore;
//
// public TileEntitySmileyCloud() {
// super("smileyCloud");
// }
//
// @Override
// public void writeSyncableNBT(CompoundNBT compound, NBTType type) {
// super.writeSyncableNBT(compound, lookupProvider, type);
// if (this.name != null && type != NBTType.SAVE_BLOCK) {
// compound.setString("Name", this.name);
// }
// }
//
// @Override
// public void readSyncableNBT(CompoundNBT compound, NBTType type) {
// super.readSyncableNBT(compound, lookupProvider, type);
// if (type != NBTType.SAVE_BLOCK) {
// this.name = compound.getString("Name");
// }
// }
//
// @Override
// public void updateEntity() {
// super.updateEntity();
// if (!this.world.isRemote) {
// boolean nameChanged = this.name != null
// ? !this.name.equals(this.nameBefore)
// : this.nameBefore != null;
// if (nameChanged && this.sendUpdateWithInterval()) {
// this.nameBefore = this.name;
// this.markDirty();
// }
// }
// }
//
// @Override
// public void onTextReceived(String text, int textID, PlayerEntity player) {
// this.name = text;
// }
//}

View file

@ -72,11 +72,6 @@ public final class AssetUtil {
guiGraphics.drawString(font, text, xSize / 2f - font.width(text) / 2f, yPositionOfMachineText, 0xFFFFFF, false); guiGraphics.drawString(font, text, xSize / 2f - font.width(text) / 2f, yPositionOfMachineText, 0xFFFFFF, false);
} }
public static void displayNameString(GuiGraphics guiGraphics, Font font, int xSize, int yPositionOfMachineText, TileEntityBase tile) {
displayNameString(guiGraphics, font, xSize, yPositionOfMachineText, I18n.get(tile.getNameForTranslation()));
}
// public static void renderBlockInWorld(Block block, int meta) { // public static void renderBlockInWorld(Block block, int meta) {
// renderItemInWorld(new ItemStack(block, 1, meta), combinedLightIn, combinedOverlayIn, matrices, buffer); // renderItemInWorld(new ItemStack(block, 1, meta), combinedLightIn, combinedOverlayIn, matrices, buffer);
// } // }

View file

@ -23,6 +23,7 @@ import net.minecraft.world.entity.item.ItemEntity;
import net.minecraft.world.entity.player.Player; import net.minecraft.world.entity.player.Player;
import net.minecraft.world.item.ItemStack; import net.minecraft.world.item.ItemStack;
import net.minecraft.world.item.Items; import net.minecraft.world.item.Items;
import net.minecraft.world.item.context.BlockPlaceContext;
import net.minecraft.world.level.Level; import net.minecraft.world.level.Level;
import net.minecraft.world.level.block.Block; import net.minecraft.world.level.block.Block;
import net.minecraft.world.level.block.Blocks; import net.minecraft.world.level.block.Blocks;
@ -165,8 +166,9 @@ public final class WorldUtil {
if (level instanceof ServerLevel && StackUtil.isValid(stack) && pos != null) { if (level instanceof ServerLevel && StackUtil.isValid(stack) && pos != null) {
BlockPos offsetPos = pos.relative(side); BlockPos offsetPos = pos.relative(side);
BlockState state = level.getBlockState(offsetPos); BlockState state = level.getBlockState(offsetPos);
Block block = state.getBlock(); boolean replaceable = state.canBeReplaced(new BlockPlaceContext(level, null, InteractionHand.MAIN_HAND, stack,
boolean replaceable = false; //= block.canBeReplaced(world, offsetPos); //TODO new BlockHitResult(new Vec3(0, 0, 0), side, pos, false)
));
//Redstone //Redstone
if (replaceable && stack.getItem() == Items.REDSTONE) { if (replaceable && stack.getItem() == Items.REDSTONE) {

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "elementalcraft:inert_crystal_ore" "count": 1,
"id": "elementalcraft:inert_crystal_ore"
}, },
"weight": 500 "weight": 500
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "elementsofpower:agate_ore" "count": 1,
"id": "elementsofpower:agate_ore"
}, },
"weight": 25 "weight": 25
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "elementsofpower:citrine_ore" "count": 1,
"id": "elementsofpower:citrine_ore"
}, },
"weight": 25 "weight": 25
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "elementsofpower:onyx_ore" "count": 1,
"id": "elementsofpower:onyx_ore"
}, },
"weight": 25 "weight": 25
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "elementsofpower:rubellite_ore" "count": 1,
"id": "elementsofpower:rubellite_ore"
}, },
"weight": 25 "weight": 25
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "elementsofpower:ruby_ore" "count": 1,
"id": "elementsofpower:ruby_ore"
}, },
"weight": 25 "weight": 25
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "elementsofpower:sapphire_ore" "count": 1,
"id": "elementsofpower:sapphire_ore"
}, },
"weight": 25 "weight": 25
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "immersiveengineering:ore_silver" "count": 1,
"id": "immersiveengineering:ore_silver"
}, },
"weight": 1000 "weight": 1000
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "mekanism:fluorite_ore" "count": 1,
"id": "mekanism:fluorite_ore"
}, },
"weight": 1000 "weight": 1000
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "mekanism:lead_ore" "count": 1,
"id": "mekanism:lead_ore"
}, },
"weight": 2000 "weight": 2000
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "mekanism:osmium_ore" "count": 1,
"id": "mekanism:osmium_ore"
}, },
"weight": 3000 "weight": 3000
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "mekanism:tin_ore" "count": 1,
"id": "mekanism:tin_ore"
}, },
"weight": 2000 "weight": 2000
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "mekanism:uranium_ore" "count": 1,
"id": "mekanism:uranium_ore"
}, },
"weight": 500 "weight": 500
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "modern_industrialization:antimony_ore" "count": 1,
"id": "modern_industrialization:antimony_ore"
}, },
"weight": 1000 "weight": 1000
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "modern_industrialization:lignite_coal_ore" "count": 1,
"id": "modern_industrialization:lignite_coal_ore"
}, },
"weight": 1500 "weight": 1500
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "modern_industrialization:monazite_ore" "count": 1,
"id": "modern_industrialization:monazite_ore"
}, },
"weight": 100 "weight": 100
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "modern_industrialization:nickel_ore" "count": 1,
"id": "modern_industrialization:nickel_ore"
}, },
"weight": 2000 "weight": 2000
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "modern_industrialization:salt_ore" "count": 1,
"id": "modern_industrialization:salt_ore"
}, },
"weight": 500 "weight": 500
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "powah:uraninite_ore" "count": 1,
"id": "powah:uraninite_ore"
}, },
"weight": 200 "weight": 200
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "xycraft_world:aluminum_ore_stone" "count": 1,
"id": "xycraft_world:aluminum_ore_stone"
}, },
"weight": 250 "weight": 250
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "xycraft_world:xychorium_ore_stone_blue" "count": 1,
"id": "xycraft_world:xychorium_ore_stone_blue"
}, },
"weight": 300 "weight": 300
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "xycraft_world:xychorium_ore_stone_dark" "count": 1,
"id": "xycraft_world:xychorium_ore_stone_dark"
}, },
"weight": 300 "weight": 300
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "xycraft_world:xychorium_ore_stone_green" "count": 1,
"id": "xycraft_world:xychorium_ore_stone_green"
}, },
"weight": 300 "weight": 300
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "xycraft_world:xychorium_ore_stone_light" "count": 1,
"id": "xycraft_world:xychorium_ore_stone_light"
}, },
"weight": 300 "weight": 300
} }

View file

@ -7,10 +7,11 @@
], ],
"type": "actuallyadditions:mining_lens", "type": "actuallyadditions:mining_lens",
"ingredient": { "ingredient": {
"tag": "forge:stone" "tag": "c:stones"
}, },
"result": { "result": {
"item": "xycraft_world:xychorium_ore_stone_red" "count": 1,
"id": "xycraft_world:xychorium_ore_stone_red"
}, },
"weight": 300 "weight": 300
} }