1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-08-11 17:51:04 +00:00

Added support for alignment in HUD items

This commit is contained in:
Diego Martínez 2013-04-22 06:53:55 -03:00 committed by Perttu Ahola
parent 58ded5cd27
commit 7c37b1891a
9 changed files with 38 additions and 2 deletions

View file

@ -3616,6 +3616,7 @@ void Server::SendHUDAdd(u16 peer_id, u32 id, HudElement *form)
writeU32(os, form->number);
writeU32(os, form->item);
writeU32(os, form->dir);
writeV2F1000(os, form->align);
// Make data buffer
std::string s = os.str();
@ -3650,6 +3651,7 @@ void Server::SendHUDChange(u16 peer_id, u32 id, HudElementStat stat, void *value
switch (stat) {
case HUD_STAT_POS:
case HUD_STAT_SCALE:
case HUD_STAT_ALIGN:
writeV2F1000(os, *(v2f *)value);
break;
case HUD_STAT_NAME: