This addon is inspired by the campfire in Dark Soul(not free fire lol), which serves to heal the player and as a checkpoint. Use this addon and have an experience like playing an RPG game!
Select version for changelog:
Changelog
Reworked:
- Added checkpoint feature
- Added particle & sound effects
- Changed the regeneration system





function healthHeal() {
const players = world.getPlayers();
for(const player of players){
let thealth = player.getComponent("minecraft:health");
let totalhealth = thealth.effectiveMax;
let healamount = totalhealth/20;
let chealth = player.getComponent("minecraft:health");
let currenthealth = chealth.currentValue;
if (totalhealth > currenthealth) {
let health = player.getComponent("minecraft:health")
health.setCurrent(currenthealth + healamount)
}}
}
function heal() {
if (system.currentTick % 40 === 0) {
healthHeal()}
system.run(heal);
}
system.run(heal);
What's the point besides being cruel
Kannst die Mod auf 1.21 updaten bitte
can you help me?