#Set scoreboard for offline player with macro

1 messages · Page 1 of 1 (latest)

somber templeBOT
#

Is it possible to call scoreboard with the player being the input of a macro?
I want to update the scoreboard for an offline player, which I'm currently saving the name of in data storage, but it seems like just passing the string as an argument doesn't work.

# Increase tick count
$scoreboard players add $(holder) fk_findersKeepersTicks 1

# Set scoreboard to `ticks / fk_ticks_in_a_day`
$scoreboard players operation $(holder) fk_findersKeepersDays = $(holder) fk_findersKeepersTicks
$scoreboard players operation $(holder) fk_findersKeepersDays /= fk_ticksInADay fk_constant
execute run function finders_keepers:update_score with storage finders_keepers:data holder

I'm trying to write a pack that adds the minecraft days to the scoreboard of the player that last ran my trigger to keep track of who's in possession of something for the longest.

unreal rockBOT
#

<@&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:1740381335: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

ripe pollen
#

looks like the problem should be that you're calling the macro wrong. unless your storage looks like {holder:{holder:<player>}} it should probably just be with storage finders_keepers:data

final valley
#

That's it!

#

I've been staring at this for an hour and its that simple

#

Thank you very much