pop4959 / Chunky

Pre-generates chunks, quickly, efficiently, and safely.
GNU General Public License v3.0
541 stars 59 forks source link

Chunky commands are not recognized as valid commands when used as functions in a datapack #334

Closed sniffy54 closed 2 months ago

sniffy54 commented 3 months ago

Bug description When attempting to use any chunky command (chunky continue, shape, pause, etc) as a function included in a datapack the function is not recognized and will not run. The function does not give an error, instead Minecraft behaves as if the function was absent from the folder entirely. I have had success on chunky version 1.2.164 (1.18.2) with fabric API installed. So far I have tested Minecraft versions 1.20.1 (fabric & forge) and 1.20.4 (fabric) with all not working.

What I know In 1.18.2 chunky commands in functions do work correctly. Other mods that add commands do work as functions in 1.20 Chunky commands do work in command blocks

Mods Chunky 1.3.138 Fabric Fabric API

Datapack used ChunkyPreGen.zip (1.20.4)

5_sec.mcfunction does work (runs /kill @e) continue.mcfunction and pause.mcfunction both do not work (runs /chunky continue and pause respectively)

Rachid90 commented 3 months ago

I have the same issue, did you find a solution?

pop4959 commented 3 months ago

I have the same issue, did you find a solution?

I haven't had a chance to look into this issue yet. When there are updates I will comment here or the issue will be closed.

If you have a different data pack than the one provided above, would you mind sharing it? It would be nice to have a few different ones to test.

Rachid90 commented 3 months ago

I'm actually new to minecraft modding. I play the single player mode. Furthermore, I downloaded distant horizons with iris, then downloaded the chunky plugin just to pre-generate a world, so I can play with distant horizons without hassle. I copied the .jar file in the 'mods' folder and when I opened the game and entered my world to execute the chunky commands for pre-generation, it says 'unknown command' with the color red.

I then tried to move the .jar file to plugins (same directory as 'mods' folder), and it's the same issue.

pop4959 commented 3 months ago

I'm actually new to minecraft modding. I play the single player mode. Furthermore, I downloaded distant horizons with iris, then downloaded the chunky plugin just to pre-generate a world, so I can play with distant horizons without hassle. I copied the .jar file in the 'mods' folder and when I opened the game and entered my world to execute the chunky commands for pre-generation, it says 'unknown command' with the color red.

I then tried to move the .jar file to plugins (same directory as 'mods' folder), and it's the same issue.

This sounds like an unrelated problem. This issue relates to commands in data packs. There are no known problems with running commands in a general sense. In single player mode, you do need cheats enabled in order to use chunky. If you did not enable this when you created the world you will need to use the "Open to LAN" feature available to you from the pause menu to enable cheats temporarily. You should then be able to use commands.

If you are still having issues, please do not respond here but instead join our Discord server for additional help troubleshooting.

sniffy54 commented 3 months ago

I have the same issue, did you find a solution?

I haven't had a chance to look into this issue yet. When there are updates I will comment here or the issue will be closed.

If you have a different data pack than the one provided above, would you mind sharing it? It would be nice to have a few different ones to test.

I Unfortunately deleted the first data pack I made because I got frustrated that it wouldn't work. I modified the one I sent you to demonstrate that any function with a vanilla command works, but not when replaced with a chunky command. The unmodified Data pack originally included exclusively chunky commands, but none worked. When I replaced one of the functions with "kill @e" that particular function worked. This is the long winded way of saying you should be able to replicate the problem with any data pack by editing one of the .mcfunction files to include a Chunky command.

pop4959 commented 3 months ago

Great, yeah I hope to be able to test this soon when I can. The one data pack is fine to start with.

pop4959 commented 2 months ago

Fixed in a884a470988d8552b8107320babec44d4e5ee019. There was apparently an error (which no one reported here, this would have been fixed a lot faster if someone had shared that one) preventing data pack functions from loading.

Also needed to update the data pack, I've provided the updated data pack here based on the original one.

Demonstration:

[00:03:12] [main/INFO]: Found new data pack file/ChunkyPlayerPause.zip, loading it automatically
[00:03:13] [main/INFO]: Loaded 1175 recipes
[00:03:13] [main/INFO]: Loaded 1276 advancements
[00:03:13] [main/INFO]: Applied 0 biome modifications to 0 of 64 new biomes in 879.7 μs
[00:03:13] [Server thread/INFO]: Starting minecraft server version 1.20.6
[00:03:13] [Server thread/INFO]: Loading properties
[00:03:13] [Server thread/INFO]: Default game type: SURVIVAL
[00:03:13] [Server thread/INFO]: Generating keypair
[00:03:13] [Server thread/INFO]: Starting Minecraft server on *:25566
[00:03:13] [Server thread/INFO]: Using default channel type
[00:03:13] [Server thread/INFO]: Preparing level "world"
[00:03:14] [Server thread/INFO]: Preparing start region for dimension minecraft:overworld
[00:03:14] [Worker-Main-31/INFO]: Preparing spawn area: 0%
[00:03:14] [Worker-Main-24/INFO]: Preparing spawn area: 0%
[00:03:14] [Server thread/INFO]: Time elapsed: 868 ms
[00:03:14] [Server thread/INFO]: Done (1.288s)! For help, type "help"
[00:03:17] [Server thread/INFO]: [Chunky] Task running for minecraft:overworld. Processed: 78520 chunks (5.02%), ETA: 16:19:04, Rate: 25.3 cps, Current: 25, 150
[00:03:18] [Server thread/INFO]: [Chunky] Task running for minecraft:overworld. Processed: 78581 chunks (5.02%), ETA: 11:40:27, Rate: 35.4 cps, Current: 29, 141
[00:03:19] [Server thread/INFO]: [Chunky] Task running for minecraft:overworld. Processed: 78705 chunks (5.03%), ETA: 7:30:16, Rate: 55.0 cps, Current: 17, 137
[00:03:20] [Server thread/INFO]: [Chunky] Task running for minecraft:overworld. Processed: 78906 chunks (5.04%), ETA: 5:02:18, Rate: 81.9 cps, Current: 32, 135
[00:03:21] [Server thread/INFO]: [Chunky] Task running for minecraft:overworld. Processed: 79041 chunks (5.05%), ETA: 4:35:06, Rate: 90.0 cps, Current: 36, 138
[00:03:22] [Server thread/INFO]: [Chunky] Task running for minecraft:overworld. Processed: 79178 chunks (5.06%), ETA: 4:17:01, Rate: 96.3 cps, Current: 34, 158
[00:03:22] [User Authenticator #1/INFO]: UUID of player pop4959 is a806bad6-4b60-47dd-8048-6a4945125726
[00:03:23] [Server thread/INFO]: pop4959[/127.0.0.1:58361] logged in with entity id 309 at (3.9581978729178218, 66.0, -7.729056701788502)
[00:03:23] [Server thread/INFO]: pop4959 joined the game
[00:03:23] [Server thread/INFO]: [Chunky] Task running for minecraft:overworld. Processed: 79290 chunks (5.07%), ETA: 4:13:31, Rate: 97.7 cps, Current: 42, 151
[00:03:24] [Server thread/INFO]: [Chunky] Task running for minecraft:overworld. Processed: 79419 chunks (5.07%), ETA: 4:05:35, Rate: 100.8 cps, Current: 50, 144
[00:03:24] [Chunky-minecraft:overworld Thread/INFO]: [Chunky] Task stopped for minecraft:overworld.
[00:03:26] [Server thread/INFO]: pop4959 lost connection: Disconnected
[00:03:26] [Server thread/INFO]: pop4959 left the game
[00:03:30] [Server thread/INFO]: [Chunky] Task running for minecraft:overworld. Processed: 79485 chunks (5.08%), ETA: 3:30:08, Rate: 117.8 cps, Current: 57, 154
[00:03:31] [User Authenticator #2/INFO]: UUID of player pop4959 is a806bad6-4b60-47dd-8048-6a4945125726
[00:03:31] [Server thread/INFO]: [Chunky] Task running for minecraft:overworld. Processed: 79604 chunks (5.09%), ETA: 4:27:59, Rate: 92.4 cps, Current: 60, 144
[00:03:31] [Server thread/INFO]: pop4959[/127.0.0.1:58369] logged in with entity id 674 at (3.9581978729178218, 66.0, -7.729056701788502)
[00:03:31] [Server thread/INFO]: pop4959 joined the game
[00:03:32] [Server thread/INFO]: [Chunky] Task running for minecraft:overworld. Processed: 79774 chunks (5.10%), ETA: 3:25:13, Rate: 120.6 cps, Current: 54, 133
[00:03:33] [Server thread/INFO]: [Chunky] Task running for minecraft:overworld. Processed: 79957 chunks (5.11%), ETA: 3:06:45, Rate: 132.5 cps, Current: 76, 131
[00:03:34] [Server thread/INFO]: [Chunky] Task running for minecraft:overworld. Processed: 80075 chunks (5.12%), ETA: 3:11:26, Rate: 129.3 cps, Current: 68, 141
[00:03:34] [Chunky-minecraft:overworld Thread/INFO]: [Chunky] Task stopped for minecraft:overworld.
SavageTheUnicorn commented 1 month ago

Is this a planned addition for the bukkit version aswell? I notice only forge, fabric, and neoforge have recieved this so far. Datapack definitely not working for me in 1.19.4 Paper.