Respect object property hp_max field for players (#6287)
* Respect object property hp_max field for players This allows modders to configure the maximal HP per player * Statbars: Downscale bar to full 20 HP when exceeding this value Add default max HP for players and breath constants to builtin Document the constants * Rename PLAYER_MAX_HP -> PLAYER_MAX_HP_DEFAULT
This commit is contained in:
@@ -100,7 +100,7 @@ void RemotePlayer::deSerialize(std::istream &is, const std::string &playername,
|
||||
try {
|
||||
sao->setHPRaw(args.getS32("hp"));
|
||||
} catch(SettingNotFoundException &e) {
|
||||
sao->setHPRaw(PLAYER_MAX_HP);
|
||||
sao->setHPRaw(PLAYER_MAX_HP_DEFAULT);
|
||||
}
|
||||
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user