#\/

1 messages · Page 1 of 1 (latest)

tight radish
#

i am making a battle royale minigame. I added team system for it. it works by giving the same score in 'team_number' scoreboard for players in the same team.
every player also have unique player_id (just score in player_id scoreboard). After player dies he goes into a spectator mode and summon a death box (with items he had) [chest_minecart]. This death box copies this player scores (player_id and team_number) to own scoreboards (death_box_team and death_box_player_id). I want to make respawning teammates (something like reboot vans in fortnite or repawn beacons in apex). I can set the timer for player wich dies.

But how to check:

  1. If player clicked on death box (tried with advancements but idk how to check other things than just interacting)

  2. Player wich interacted with death box has the same score on team_number as chest_minecart on death_box_team
    3.Player wich interacted with death box has player_knocked score set to 0

  3. How to check if player timer is more than 1.. when teammate tries to grab his card/banner (problem is in connecting a chest_minecart that is clicked with player)

  4. How to give a player with same score on player_id as chest_minecart on death_box_player_id, tag or score

I have been trying to do this for half a day and i have no clue how to

runic basaltBOT
#

-# (helpers summoned) <@&1166082198152159386> <@&1202694677766348840>

tiny zephyr
#

Curious, how come the scoreboard team system instead of the actual team command?

Anyway, clicking on the box, you have a few options;

  1. Use an interaction entity
  2. If you can, use a note block or something, and detect when the data of it has changed (interacted)

For detecting if they are on the same team, I recommend a interaction entity, as when interacted, they store the players UUID.

Check if the score of the UUID stored matches the score of the stored dead player

For detecting if the player is knocked out, just use execute if score <player> <objective> matches <value> run ...

For checking a score more than one, same command as above but set the value to 1... the .. means equal or greater than, so 1.. is the same as 1≤.

Not sure what your asking for your 5th point, but as a guess, scoreboard has an operations argument, I recommend messing with that for a bit