#How to make a advancement unachievable to everyone once a player first unlocks it.

1 messages · Page 1 of 1 (latest)

scenic trout
#

My friend has been working on a coding project for a SMP with custom weapons which are unlocked by a custom advancement. He asked me to help code a specific part while he works on other things, and i just cant seem to figure out how to code this properly. I'm tasked with making it so that only the first player to unlock the advancement can be the only player get it. Im very unexperienced with coding so help would be appreciated. This the code for the advancement if it helps.
{
"display": {
"icon": {
"id": "minecraft:diamond_sword",
"components": {},
"count": 1
},
"title": "Aiglos",
"description": "Gain the Aiglos, A legendary elvish spear passed down for generations.",
"frame": "challenge",
"show_toast": true,
"announce_to_chat": true,
"hidden": false
},
"parent": "bomo:utility",
"criteria": {
"beacon_made": {
"trigger": "minecraft:construct_beacon",
"conditions": {
"level": 4
}
},
"eat_god_apple": {
"trigger": "minecraft:consume_item",
"conditions": {
"item": {
"items": "minecraft:enchanted_golden_apple",
"count": 1
}
}
}
},
"requirements": [
["eat_god_apple"],
["beacon_made"]
],
"rewards": {
"function": "bomo:aiglos01"
}
}

ripe wrenBOT
#

<@&1201956957406109788>

Someone will come and help soon!

💬 While you wait, take this time to provide more context and details.

🙇 If nobody has answered you by <t:1741143867:t>, feel free to use the Summon Helpers button to ping our helper team.

✅ Once your question has been resolved (or you no longer need it), please click Resolve Question or run /resolve

silk void
#

Add an additional value check condition that checks if a fake player's score is not 1, then in the reward function, set that fake player's score to 1

#

You'll probably need to add the condition to both criteria

scenic trout
#

what do you mean "fake player"?

#

like is a fake player jsut a title in place for a real player?

silk void
#

A fake player is technical term. You can define any name for a player in a scoreboard command, including a player name that doesn't/can't exist

scenic trout
#

oh ok thanks

ripe wrenBOT
#
Question Closed

Your question, #1346672173753827490 (How to make a advancement unachievable to everyone once a player first unlocks it.), was resolved!

Original Message

#1346672173753827490 message

Duration open

19h17m