#www.buttons.gov
1 messages · Page 1 of 1 (latest)
This looks like a project that could make things much less annoying when joining a server for the first time
totally agree. good work so far! keep it up
L4D style pickup alerts
love it <3
This idea no lie was on my mind for a while! I applaud the idea.
Alright heres a real world usage of it.
from hardcoded wordsoup, to dynamic wordsoup, to simplified. took only a couple minutes to change and tinker with
Maybe, if possible, change the text to the far right. Usually the tutorial stuff goes on the right to allow the user to read from left to right before figuring out how to do something. It’s up to you, but it would be epic to switch the sides it’s on.
its all configurable, i just picked random stuff
this is the actual code
local textx, texth = w * 0.5, h * 0.75
local tw, _ = draw.SimpleTextBlurHint("<bind:invnext> Previous <action:IN_ATTACK> Spawn <bind:invprev> Next", "ZSHUDFontSmall", textx, texth, COLOR_DARKRED, TEXT_ALIGN_CENTER)
textx = textx - (tw * 0.25)
draw.SimpleTextBlurHint("<action:IN_RELOAD> Random spawn", "ZSHUDFontSmall", textx, texth + space * 1, COLOR_DARKRED, TEXT_ALIGN_LEFT)
draw.SimpleTextBlurHint("<action:IN_DUCK> Last spawn", "ZSHUDFontSmall", textx, texth + space * 2, COLOR_DARKRED, TEXT_ALIGN_LEFT)
draw.SimpleTextBlurHint("<action:IN_JUMP> Freeroam", "ZSHUDFontSmall", textx, texth + space * 3, COLOR_DARKRED, TEXT_ALIGN_LEFT)```
draw.SimpleTextBlurHint being a wrapper ontop of hints.SimpleText that applies a blur effect which isnt enabled in the screenshot
Its still rough but i wanna leave everything up to the dev and just provide sensible defaults where possible
theres also a hints.SimpleTextEx which provides raw access to every single thing about it
i intend to follow that pattern everywhere, non ex with sensible defaults, ex with full control
this is just raw straight from existing code as the purpose here was testing how easy that is, so dont look at the way its written too much
right now theres no wrappers or anything to make this easier, but basic functionality is finally there
i love that syntax of action:IN_Key
what happens when the key isn't bound? will it display a command from lookup?
the syntaxes it supports are <key:KEY_E> (KEY_, JOYSTICK_, MOUSE_) enums
<bind:+forward> /<bind:gmod_undo> referencing of binds
<action:IN_ATTACK> IN_ enums
i havent decided yet, currently it shows a blank key
theres 3 ways i know of it can go right now:
Blank key
Raw text
Unbound text placeholder
Amazing!
Yeah man, this looks great and and an easy format to boot
A bit further again, this time i added caching for the parsing, content alignment support for the dlabel, unified the rendering to be 1 implementation and got almost full feature parity with dlabel (only wrapping and text inset left to do)
https://cdn.discordapp.com/attachments/288761962240671746/1241796470978646161/gm_construct0119.jpg?ex=664b8096&is=664a2f16&hm=797a6959730f6fe17ba2221a30bea248ad6d525f04f1b93f159c829bf76444b1&
looking so forward to implementing multiline support and wrapping.........