valence-rs/valence

Set default health based on max health attribute

SelfMadeSystem opened this issue · 0 comments

Describe the problem related to your feature request.

Currently, all entities' default health is the same. However, now that we have their default max health attribute, we can now set the default health value for each entity.

This problem isn't very apparent, but it becomes apparent when we include food and saturation via #565 / #568

What solution would you like?

Default the max health of entities

What alternative(s) have you considered?

I don't think one is feasible.

Additional context

Since #568 (HealthUpdateS2c) tells the client about their food level, saturation, AND health, we need to have good defaults.