Minecraft Data Packs / Mini-game

Hanafuda | Japanese Flower Cards

  • check_circle Advancements
  • check_circle Functions
  • check_circle Loot Tables
  • check_circle Predicates
  • check_circle Recipes
  • 1,335 views, 6 today
  • 44 downloads, 1 today
  • 19
  • 14
  • 9
Required Resource Pack
kanokarob avatar kanokarob
Level 67 : High Grandmaster Programmer
490

What are Hanafuda?

Hanafuda are Japanese Flower Cards. Created during a period in Japan where gambling was illegal, these cards were designed to be small and concealable, as well as illustrated and beautiful so as to not look like they could be used for gambling.

A traditional Hanafuda deck is made up of 48 cards. Twelve flowers or other plants appear on the cards, making up twelve "suits," one for every month of the year. Each month has 4 cards.

What does this data pack do?

This pack adds a craftable Hanafuda Deck, which you can then deal Hanafuda cards from. Right click the deck while in your mainhand or offhand, or while it's in an item frame to draw a card at random. Right click the deck while sneaking to shuffle all cards in your inventory back into the deck. The same card cannot be drawn from the deck until it has been shuffled back in. Note that this means if you lose a card, it is lost from that deck, and you'll have to craft a new deck (once you realize that has happened).

Hanafuda | Japanese Flower Cards Minecraft Data Pack
(Any dye can be used in any slot, including four of the same dye)


Additionally, this pack adds some foundation to play a game with the Hanafuda. Many games exist that use Hanafuda, but the most popular is called Koi-Koi, and it's what's been recreated here.

This Hanafuda Deck has custom artwork that is Minecraft-focused, while still paying homage to the standard Hanafuda designs. Where able, the same flowers, plants, and animals have been used, but with Minecraft textures, such as Spruce Trees and pink Peonies. In other cases, close approximations have been made, like a Hoglin instead of a Boar. And in others still, they use more original Minecraft features, like Chorus plants instead of Chrysanthemum. Below is a list of all the plants and their month.

January:   Spruce Trees
February:  Rose Bush
March:   Flowering Azalea Leaves
April:    Weeping Vines
May:    Twisting Vines
June:    Peony
July:    Sweet Berry (Bush)
August:   Mycelium
September: Chorus
October:   Glow Berries
November:  Jungle Leaves
December:  Lilac

How to play Koi-Koi in Minecraft

Koi-Koi is a two-player game using one Hanafuda deck. "Koi-Koi" literally means "Come On!", a phrase used during gameplay. Once you have a Hanafuda Deck crafted, you'll also need at least 8 item frames somewhere between each player, where they can both reach. More item frames may be necessary as the game goes on.

Setup:

Choose 1 player to be the dealer. Either place the Hanafuda deck in an item frame where both players can reach it, or have the dealer hold the deck in their hotbar, somewhere convenient.

The dealer draws 4 cards from the deck and gives them to their opponent (if the deck is in an item frame, the opponent can draw for themselves), then draws 4 cards and places them in 4 of the item frames between the two players, then draws 4 cards and keep them in their inventory. Repeat this step so that both players have 8 cards in their hotbar, and there are 8 cards in item frames between the players.

Turn Procedure:

Starting with the dealer, each player's turn occurs in this order.
  1. The turn player right clicks a card in an item frame while holding a card from the same month (depicting the same plant) in their mainhand. A sound and particles will indicate a successful match. The player picks up the card from the item frame, and moves both cards out of their hotbar, but still in their inventory. (They are captured)

  2. The turn player draws a card from the deck (or is dealt one by the dealer) and tries to match that new card in the same way as above. If they can't, the card is placed in an empty item frame.

  3. If the player has captured all the cards necessary for a Combo*, both players will be told what combo has been obtained and how many points it is worth. The turn player will be given a text prompt to either "Koi-Koi" or "Stop". If they choose Koi-Koi, the game continues until either player gets a new combo or adds to an existing one. If they Stop, the game ends and scores are calculated.
Note: If a player has no matching card in their hand for step 1, they must still place a card in an empty item frame. They still get to perform step 2.

Special Rules:

These special rules are traditional to Koi-Koi, but are not handled automatically by this data pack.
  • If all 4 cards of the same month are dealt in the item frames at the start of the game, shuffle all the cards back and redeal, as the game is moot.
  • If 3 cards of the same month are all in the item frames, and at any point a player makes a match with 1 of them, that player also collects all the others of the same suit (Pick up 1 of remaining 2 unmatched cards and match it with the last one, since you can't match using cards that are already captured)
  • If a player is dealt all 4 cards of the same month, they automatically win the game. Shuffle all the cards back and play again!

Combos:

When a player captures all the cards for a combo, they are given the decision to Koi-Koi or end the game, counting up their points. Some combos are more valuable than others, and they are how you get scored (Even though cards have individual point values, these are traditionally for grouping certain similar cards, not for scoring).

Below are all of the combos the data pack recognizes.
  • 10 Plains:         1 point, +1 for each additional Plains
  • 5 Banners:        1 point, +1 for each additional Banner
  • 5 Animals:        1 point, +1 for each additional Animal
  • Potion + Moon:     5 Points
  • Potion + Curtain:     5 Points
  • 3 Poetry Banners:     6 Points
  • 3 Blue Banners:     6 Points
  • Hoglin-Goat-Bat:     6 Points
  • Three Lights (no Creeper): 6 Points
  • Four Lights (w/ Creeper): 7 Points
  • Four Lights (no Creeper): 8 Points
  • Five Lights:        15 Points

Ending the Game:

When a player decides to Stop after capturing a combo, the game ends and scores are calculated based on the combos the player got. Traditionally, only the player who Stopped is awarded points, and play continues for a determined number of rounds or until a determined number of points are reached. However for this data pack, the scores of both players are calculated and shown.

Importantly, the player who Stopped gets a multiplier based on the number of times Koi-Koi was called by either player. If Koi-Koi was called once, the player who Stops gets their score multiplied by 2. If twice, the multiplier is x3. This is why it can be good to Koi-Koi and keep playing if you have so far only captured a few points, in the event you are playing multiple rounds to try and catch up, but also dangerous, as your opponent may be the one who gets the bonus if they Stop first.

Known Bugs

  • After placing a Hanafuda Deck in an item frame, you need to change your selected hotbar slot before being able to draw from the deck. This is a weird Minecraft bug with how it handles predicates and item frames, so unfortunately there's nothing I can do about it.

  • In my testing, trying to capture cards while recording (either with Replay Mod or with external recording software) can be inconsistent or unreliable. I'm still working out if there is anything that can be done about this, but it probably has to do with FPS or something similar as a result of the recording.

License
By downloading Hanafuda | Japanese Flower Cards ("The Pack"), you recognize and agree that you may not distribute the Pack on any platform, in whole or in part, in edited or modified form, without express written permission from kanokarob ("The Creator"). You are permitted to make modifications or changes to the Pack for your personal use. Personal use may include, but is not limited to, playing in a Singleplayer world, hosting or playing on a public Multiplayer server with an edited or unedited version of the Pack, and/or recording gameplay of the Pack in video or image format. You may upload video or image recordings of the Pack and its gameplay to any public platform, however a link to this page must be provided in a clear and accessible location, and you may not claim to have or have had any part in its creation or development.
CompatibilityMinecraft 1.19
Tags

Create an account or sign in to comment.

1
07/19/2022 12:36 pm
Level 1 : New Miner
FiyahKitteh
FiyahKitteh avatar
Hai!
So I was given a card deck (that looks like a shroom on a fishing rod, is that normal?), but I can't draw cards from the deck, not even when placed in an item frame. It only rotates the rod and nothing else happens. What am I missing?
2
07/19/2022 1:36 pmhistory
Level 67 : High Grandmaster Programmer
kanokarob
kanokarob avatar
Well for the visuals that would be due to not having the resource pack installed.

As for the card drawing, my suspicion would be that you have another incompatible data pack (unlikely), or are on a Spigot, Paper, or Bukkit server, which don't support data packs. However I would not be able to troubleshoot more without more information about your non-vanilla inclusions.

Also be sure to check out the known bugs section above to be safe.
1
07/20/2022 1:00 pm
Level 1 : New Miner
FiyahKitteh
FiyahKitteh avatar
Well, I put the resource pack zip into my .minecraft / resource pack folder. So it should work, right?
I have MC 1.19 and am on a Forge 41.0.93 server.
And I do have other inclusions, yes. What exactly does your datapack change (values)? Maybe I can figure out if something is disturbing it.

I did notice when looking through your resource pack, that the fungus on a stick (which is what the deck looks like for me right now) is in there (\hanafuda-rp-v1-0-by-kanokarob.zip\assets\minecraft\models\item\warped_fungus_on_a_stick.json)
Is that supposed to be there or?
2
07/20/2022 3:33 pm
Level 67 : High Grandmaster Programmer
kanokarob
kanokarob avatar
If you have the resource pack and have it selected, then yes, it would show correctly. That is unless you have another data pack+resource pack that changes Warped Fungus on a Stick also, in which case the two resource packs may need to be merged.

The resource pack is indeed set up correctly and that file is supposed to be there.
1
07/20/2022 6:28 pm
Level 1 : New Miner
FiyahKitteh
FiyahKitteh avatar
Ah, I see. It changes that stick. Good to know, thanks. That just helped me narrow it down.

Any idea on why I still can't pick up cards from the deck? Even when in hand and right-clicking as the tool-tip says, it doesn't pick anything up. Seems strange, hmm
1
07/20/2022 6:59 pm
Level 67 : High Grandmaster Programmer
kanokarob
kanokarob avatar
If you're on forge it's likely one of your other data packs is interfering in some way. It's hard to say why that would be since all of this pack's scoreboard objectives and similar are namespaced; one or more of those other packs may be breaking the tick function.

Simple way to narrow things down would be to remove/disable other data packs, see if the Hanafuda deck works, and then re-enable them one or more at a time until it stops working.
2
06/26/2022 10:41 am
Level 38 : Artisan Nerd
PaPeedy
PaPeedy avatar
Very creative! My friend plays Minecraft and loves Japanese art and stuff and I be sure to tell him to check this out! Another great datapack kanokarob!
3
06/25/2022 9:17 pm
Level 47 : Master Engineer
Apollo404
Apollo404 avatar
One of the most interesting and unique datapack concepts I've seen in a long time. Great job!
2
06/25/2022 6:31 pm
Level 1 : New Miner
JustARandomGuyOnTheInternet
JustARandomGuyOnTheInternet avatar
This looks amazing can't wait to try it out!
Planet Minecraft

Website

© 2010 - 2022
www.planetminecraft.com

Welcome