Garry's Mod

Garry's Mod

Not enough ratings
[SF] hMenuLib
   
Award
Favorite
Favorited
Unfavorite
Content Type: Dupe
Dupe Tags: Machines
File Size
Posted
Updated
8.416 KB
12 Jan @ 12:17pm
9 Mar @ 7:37am
5 Change Notes ( view )

Subscribe to download
[SF] hMenuLib

Description
hMenuLib by hamache
A library for my custom panels, lets you create windows and elements inside them.

HOOKS : -- use hml.hook.add(...) onState(window, state) onResize(window, w, h, ow, oh) onMove(window, x, y, ox, oy) hml = hml.new(x, y, w, h, table data) -- creates a new window. you can insert a table of configurations in table data: color - primary color icolor - secondary color label - window title lfont - window title font icolorA - secondary color alpha for transparent version focus - enable cursor on window open? open - set first state minw - minimal width minh - minimal height lockpos - make window static lockscale - lock window scaling hml:editTable(table data) -- edits configurations table hml:destroy() -- removes a window completely hml:state(bool) -- open/close the window ////////// ELEMENT MANIPULATION hml:newelement(etype, x, y, ...) -- creates an element inside the window. currently there are only 2 element types: 'button': ...color, width, height, function, text, text font, centerX, centerY, stretchW, stretchH 'text': ...color, text, font, centerx, centery, align --centerX will move the object based on the fraction between 0-2 of the window width --centerY will move the object based on the fraction between 0-2 of the window height --strecthW will stretch the object based on the fraction between 0-2 of the window width --strecthH will stretch the object based on the fraction between 0-2 of the window height hmle:editTable(table config) -- edits element's arguments. hmle:destroy() -- removes an element completely
4 Comments
𝐃𝐉𝐀𝐒𝐓 17 Jan @ 7:08am 
умертвительно:steammocking:
Blank 17 Jan @ 7:07am 
ржачно
𝐃𝐉𝐀𝐒𝐓 12 Jan @ 8:32pm 
Окно в европу
bad time 12 Jan @ 12:25pm 
окна:gmod: