You can use the "Execute command /" code block (found under Entity Management) to set the player's max health attribute.
For example, plugging in the following:
attribute @s minecraft:generic.max_health base set 30
will set the max health of the target entity to 30 (15 hearts).
NOTE: Attributes will reset up death, so to make a permanent change, you will have to keep track of the effect with a global variable and reapply it upon player respawn.
(Permanently)
idk the full details but this requires the health boost effect
when the player uses the item, run a procedure
if the player does not have health boost, give them health boost level 0 (mcreator interprets level 0 as level 1)
if the player has health boost, increase its level by 1
see if that works
You can use the "Execute command /" code block (found under Entity Management) to set the player's max health attribute.
For example, plugging in the following:
will set the max health of the target entity to 30 (15 hearts).
NOTE: Attributes will reset up death, so to make a permanent change, you will have to keep track of the effect with a global variable and reapply it upon player respawn.
IDK if u still need it, but pehkui addon or attribute changing (built in)