diff options
author | HimbeerserverDE <himbeerserverde@gmail.com> | 2023-06-08 15:26:01 +0200 |
---|---|---|
committer | HimbeerserverDE <himbeerserverde@gmail.com> | 2023-06-08 15:26:01 +0200 |
commit | 487727a717d95c393f83b580e42d377f673a27cd (patch) | |
tree | 8fb4f7b4de8414f6411dee8408ad47cab3cd2e32 /tocltcmds.go | |
parent | f173e4c5755d35fcbdb549d735a939dd342e6e47 (diff) |
add support for HUD styles
Diffstat (limited to 'tocltcmds.go')
-rw-r--r-- | tocltcmds.go | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/tocltcmds.go b/tocltcmds.go index 814ac73..477ddbc 100644 --- a/tocltcmds.go +++ b/tocltcmds.go @@ -433,6 +433,7 @@ type HUD struct { Size [2]int32 ZIndex int16 Text2 string + Style HUDStyleFlags } type HUDID uint32 @@ -520,6 +521,10 @@ type ToCltChangeHUD struct { //mt:if %s.Field == HUDText2 Text2 string //mt:end + + //mt:if %s.Field == HUDStyle + Style HUDStyleFlags + //mt:end } type HUDField uint8 @@ -538,11 +543,22 @@ const ( HUDSize HUDZIndex HUDText2 + HUDStyle hudMax ) //go:generate stringer -trimprefix HUD -type HUDField +type HUDStyleFlags uint32 + +const ( + StyleBold HUDStyleFlags = 1 << iota + StyleItalic + StyleMono +) + +//go:generate stringer -trimprefix Style -type HUDStyleFlags + // ToCltHUDFlags tells the client to update its HUD flags. type ToCltHUDFlags struct { // &^= Mask |