mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-15 17:35:37 +02:00
Lua HUD
This commit is contained in:
committed by
kwolekr
parent
1f42479e0c
commit
49f6e347f0
16
src/player.h
16
src/player.h
@@ -87,6 +87,7 @@ class Map;
|
||||
class IGameDef;
|
||||
struct CollisionInfo;
|
||||
class PlayerSAO;
|
||||
struct HudElement;
|
||||
|
||||
class Player
|
||||
{
|
||||
@@ -243,6 +244,9 @@ public:
|
||||
|
||||
u32 keyPressed;
|
||||
|
||||
std::map<u32, HudElement*> hud;
|
||||
std::map<u8, u32> hud_bars;
|
||||
|
||||
protected:
|
||||
IGameDef *m_gamedef;
|
||||
|
||||
@@ -253,6 +257,18 @@ protected:
|
||||
v3f m_position;
|
||||
};
|
||||
|
||||
struct HudElement {
|
||||
u8 type;
|
||||
core::vector2df pos;
|
||||
std::string name;
|
||||
|
||||
core::vector2df scale;
|
||||
std::string text;
|
||||
u32 number;
|
||||
u32 item;
|
||||
u32 dir;
|
||||
};
|
||||
|
||||
/*
|
||||
Player on the server
|
||||
*/
|
||||
|
Reference in New Issue
Block a user