So I want to make a skript that allows players to type command that would transform all their levels into a water bottle (which is held as typing command). The water bottle has custom lore showing amount of levels stored and name including player's display name, so it can't be faked. Upon drinking the bottle, any player doing so will get the levels added to his current XP. So far I managed to do the command for making the bottle, but I can't figure out how to add the stored value.
It takes the lore as a string not as an integer. How can I go around this?
Code:
command /storexp:
trigger:
player is holding water bottle named "Water Bottle"
set player's held item to water bottle named "<purple>%player's tab list name%'s Experience" with lore "<orange>%player's level%"
set player's level to 0