Started by
_RedLine_
on
Topic category: Help with Minecraft modding (Java Edition)
Help, please. How to make a mod in which it will be so that when a player enters the game for the first time, he has a random maximum amount of health between 20-50 units.
There must be a plugin called "Attributes". After downloading that plugin use the "Set base value of attribute of to" block and make the choosen attribute "Max Health"
20 is default player health. 1 hearth = 2 health point so configure that like this.
Set global trigger to "player joined world"
set base value of attribute Max Health of event/target entity to (number of your choosing)
If you want to make it random just make a local number variable and set it to random integer between 20-50 then set the attribute to that variable.