This site works best with JavaScript enabled. Please enable JavaScript to get the best experience from this site.
/scoreboard objectives add xp xp
/scoreboard objectives add gespeichert dummy
/execute as @p at @s run scoreboard players operation @s gespeichert = @s xp
----------------------------------------------------
/execute as @p at @s run xp add @s {score from scoreboard named gespeichert}
(its for storing xp to get it back later)
cant find the command..
Use this to modify the player's XP:
/execute as @p run execute store result entity @s XpTotal int 1 run scoreboard players get @s gespeichert
Some of my projects:
https://www.curseforge.com/members/megacrafter1077/projects
https://datapackcenter.com/projects/adventure.104/
My tutorials:
https://datapackcenter.com/projects/data-pack-basics.71/
https://datapackcenter.com/projects/loot-tables.72/
https://datapackcenter.com/projects/custom-crafting-tutorial.70/
https://datapackcenter.com/projects/custom-item-models-tutorial.69/
https://datapackcenter.com/projects/raycasting-tutorial.68/
sry cant handle that
it read result of scoreboard (i believe) but how i give that result as xp or level to @p
Quote from romanorose76» sry cant handle that it read result of scoreboard (i believe) but how i give that result as xp or level to @p
The command reads the value of the scoreboard objective and gives the value to the player as XP
sry it didn. thats why i wrote " cant handle"
it only tells for exsample player got 20[gespeichert]
Quote from romanorose76» sry it didn. thats why i wrote " cant handle" it only tells for exsample player got 20[gespeichert]
I see what you mean now. I completely forgot that the player data can't be modified directly. Here is a working system:
execute as @a unless score @s gespeichert matches 0 run experience add @s 1
scoreboard players remove @a[scores={gespeichert=1..}] gespeichert 1
^ these two commands should repeatedly run in a command block chain. It is very important that they run in order.
Tank you😉
/scoreboard objectives add xp xp
/scoreboard objectives add gespeichert dummy
/execute as @p at @s run scoreboard players operation @s gespeichert = @s xp
----------------------------------------------------
/execute as @p at @s run xp add @s {score from scoreboard named gespeichert}
(its for storing xp to get it back later)
cant find the command..
Use this to modify the player's XP:
Some of my projects:
https://www.curseforge.com/members/megacrafter1077/projects
https://datapackcenter.com/projects/adventure.104/
My tutorials:
https://datapackcenter.com/projects/data-pack-basics.71/
https://datapackcenter.com/projects/loot-tables.72/
https://datapackcenter.com/projects/custom-crafting-tutorial.70/
https://datapackcenter.com/projects/custom-item-models-tutorial.69/
https://datapackcenter.com/projects/raycasting-tutorial.68/
sry cant handle that
it read result of scoreboard (i believe) but how i give that result as xp or level to @p
The command reads the value of the scoreboard objective and gives the value to the player as XP
Some of my projects:
https://www.curseforge.com/members/megacrafter1077/projects
https://datapackcenter.com/projects/adventure.104/
My tutorials:
https://datapackcenter.com/projects/data-pack-basics.71/
https://datapackcenter.com/projects/loot-tables.72/
https://datapackcenter.com/projects/custom-crafting-tutorial.70/
https://datapackcenter.com/projects/custom-item-models-tutorial.69/
https://datapackcenter.com/projects/raycasting-tutorial.68/
sry it didn. thats why i wrote " cant handle"
it only tells for exsample player got 20[gespeichert]
I see what you mean now. I completely forgot that the player data can't be modified directly. Here is a working system:
^ these two commands should repeatedly run in a command block chain. It is very important that they run in order.
Some of my projects:
https://www.curseforge.com/members/megacrafter1077/projects
https://datapackcenter.com/projects/adventure.104/
My tutorials:
https://datapackcenter.com/projects/data-pack-basics.71/
https://datapackcenter.com/projects/loot-tables.72/
https://datapackcenter.com/projects/custom-crafting-tutorial.70/
https://datapackcenter.com/projects/custom-item-models-tutorial.69/
https://datapackcenter.com/projects/raycasting-tutorial.68/
Tank you😉