kaszanalubizryc
New Member
- Joined
- Sep 10, 2015
- Messages
- 148
- Reaction score
- 1
hello someone can help i want do
when i have health 0-65535 i see it
when i have more
65535 then i see 100 procent health
when i have health 0-65535 i see it
when i have more
65535 then i see 100 procent health
Code:
msg.AddU16((uint16_t)std::floor((float)player->getHealth() * 100 / std::max(player->getPlayerInfo(PLAYERINFO_MAXHEALTH), 1)));
msg.AddU16(100);