Mojira Archive
MC-273291

/spawnpoint command does not work when executed from an enchantment effect.

Attempting to have a player run a function containing the /spawnpoint command from a custom enchantment does not set a new spawnpoint.

Steps to Reproduce:

  • Create a custom enchantment inside of a datapack.
  • Make the enchantment run a function containing the /spawnpoint command as an effect by the "hit_block" effect.
  • activate the enchantment on a tool.
  • run /kill command

Observed results: Player respawns at world spawn

Expected Results: Player should spawn at location that the /spawnpoint command was ran from.

 

Notes: Attached are the custom enchantment and function included. The other two commands work as intended. Running the function in game manually will set the player's spawn properly.

Awaiting Response

Ambideer Hendrix

2024-06-13, 05:43 AM

2024-06-14, 06:16 PM

2024-06-14, 06:16 PM

0

1

Unconfirmed

(Unassigned)

1.21 Release Candidate 1

-