PARTICIPANT IN A UNRANKED JAM
This Data Pack is an entry in the completed PMC Lucky Block Data Pack Community Event.

Minecraft Data Packs / Other

[Event Entry] Kyleong's lucky blocks entry

  • check_circle Functions
  • 4,050 views, 2 today
  • 407 downloads, 0 today
  • 7
  • 4
  • 7
kyleong's Avatar kyleong
Level 71 : Legendary Engineer
224
This is an entry for the Planet Minecraft Community Lucky Block Data Pack event! (PMC lucky block)

info of the event [​event ended]

event result

how to install data pack tutorial from Minecraft wiki

enjoy!

Options
there are only... 8 of them, but I think they are all unique and with good quality. they are mostly mini-quests with a reward, along with some others.

this data pack is too small to be an individual pack, but I think it could be a good part of the PMC lucky block data pack.

-fish catching quest

-hog feeding quest

-attack dodging quest

-try to hit quest

-the rain

-annoying kid

-MLG water bucket

-lucky chest (jackpot)

detailed explanation (Spoiler)
some of them are very straight forward:

-The rain: anvils/arrow/XP bottle(render as fire charges) will fall from the sky(21 blocks above around)

-annoying kid: a very annoying baby husk will spawn, 5 health points and immune to knockback. It moves very fast and has huge knockback, but only tickles you. (0.1 attack damage)

-MLG water bucket: throw you up to the air, you need to land an MLG water bucket to survive (will give you a water bucket if you don't have one)

-lucky chest (jackpot): spawn a chest with 3 "jackpot ticket" inside, all tickets look the same. you can only choose and take one of them, and only one ticket can lead to the jackpot. (random every time)(if you broke the chest, you will get nothing but 3 useless paper) so basically you have 1 in 3 chance to get a jackpot from it.

mini-quests:

-fish catching quest: 6 tropical fish and a pufferfish will spawn and scatter. catch the tropical fish with the name "catch me" in 6 seconds to get a reward (tropical fish type is random)(will give you a water bucket if you don't have one)

-hog feeding quest: a Hoglin will spawn, you need to feed it without getting hurt(by any source) in 10 seconds to get a reward.(crimson fungus is given)

-dodging quest: spawn a pillager with a blaze on top, avoid any damage for 12 seconds to get a reward. (shield doesn't work, pillager has a piercing enchantment crossbow)

-try to hit quest: a horde of bat or rabbit will spawn, kill the bat/rabbit with the name "hit me" in 12 seconds to get a reward (the correct bat/rabbit only have 0.1 hp, and they will emit green potion particles.)

*considering the cost of crafting a lucky block, the rewards may not be as great as those you can see in other entries.



CreditEntry for: PMC Lucky Block Data Pack Community Event
CompatibilityMinecraft 1.16
Tags

3 Update Logs

Update v1.0.3 (final update) : by kyleong 07/05/2020 11:50:46 amJul 5th, 2020

*This is just a final adjustment before the PMC lucky block submission deadline, doesn't add any more options

fixed bugs

reward loot changed along with the cost of the lucky block
LOAD MORE LOGS

Create an account or sign in to comment.

2
07/02/2020 8:13 am
Level 70 : Legendary Engineer
Bertiecrafter
Bertiecrafter's Avatar
Hey! This is a very neat little datapack, the options are really fun minigames and short enough. Nicely done :D
1
07/02/2020 8:35 amhistory
Level 70 : Legendary Engineer
Bertiecrafter
Bertiecrafter's Avatar
Based on the code for the fish quest, here are some points of improvement:
- Using @p won't work, since the schedule command will run at worldspawn instead of the fish spawn location.
- Multiple instances of the same quest won't work, since you're testing globally for the existance of an entity, instead of based on location. Also schedule is not used in a way that supports non-global commands.
- One of the quests is missing a space in the message to chat. Maybe you could use the info field in the template command as well.
- Fail messages could use some proper capitalization =) ("Anvils are falling (...)" instead of "anvil is falling (...)")

For the first two points, you might want to spawn an invisible armor stand or area affect cloud for each of the events and use the scoreboard to track time left. You create the objective in the load function, remove it in the uninstall function and decrease for all armor stands with a certain tag in the tick function (20/s). Once the objective hits zero, you simply kill all fish or whatever entity and the armor stand. Instead of using the schedule command, you can also use tick to run a function every 1/20th of a second.
So your tick function would contain commands like:

execute as @e[​tag=kylong_fish_quest] at @s run function (...)/fish_loop
execute as @e[​tag=kylong_fish_quest,scores={klng_timer=0}] at @s run function (...)/fail
scoreboard players remove @e[​scores={klng_timer=1..}] klng_timer 1

The commands mean that the given function will be run AT and AS each found entity. As a result, @p will work again, you can use @e[​distance=..10] to kill all spawned entities within 10 blocks (instead of all across the map) and @s to kill the armor stand itself.

Hopefully this can help you make the quests multiplayer compatible and multi-instance.
2
07/02/2020 9:28 am
Level 71 : Legendary Engineer
kyleong
kyleong's Avatar
Sorry I was not thinking about multiplayer compatibility.
Thank you so much for the in-depth feedback! they are very detailed!
1
07/05/2020 10:25 am
Level 70 : Legendary Engineer
Bertiecrafter
Bertiecrafter's Avatar
Not quite right, but looking good so far!

- The "rain" option is still called "anvil rain" while it might not drop anvils.
- In the tick function, make sure to check what entity will be your "as" and what entity will be your "at". For fish, you kill all fish around the area_affect_cloud and give @s a nice message. However, for the "hit" quest, your "at" and "as" are both the area affect cloud. This means that in hit_success, you are trying to /tellraw the cloud xD Also note that the file also contains "kill @s" which would obviously kill the player if you tried to make the nearest player your "as".

Try to make it consistent so that the "at" entity will be the location of the event, while the "as" entity will be the player that failed/succeeded. You'll have to edit both the tick and actual option functions for that.
1
07/05/2020 11:55 amhistory
Level 71 : Legendary Engineer
kyleong
kyleong's Avatar
Now it should be good to go. I didn't make it "as" the player, I just change the /tellraw target to @p.
I may make commands consistent in my future work, but not this time. I don't want to raise the chance of make another mistake, which further increases your work.

Thanks!
2
07/05/2020 1:15 pm
Level 70 : Legendary Engineer
Bertiecrafter
Bertiecrafter's Avatar
Fair enough, I'm impressed at how far you were able to twist the creation around and show some beautiful commands in the tick function. Well done =)
1
07/02/2020 12:42 pm
Level 70 : Legendary Engineer
Bertiecrafter
Bertiecrafter's Avatar
No problem, I forgot to mention that you should probably fix the others in the same way, since I assume you used the schedule mechanics everywhere XD
Planet Minecraft

Website

© 2010 - 2024
www.planetminecraft.com

Welcome