readme
This commit is contained in:
parent
4caa5722bf
commit
51ca1fcefb
22
README.md
22
README.md
@ -1,16 +1,24 @@
|
|||||||

|

|
||||||
# Helium
|
# Helium
|
||||||
## user facing functions
|
## Major features:
|
||||||
|
### Custom elements
|
||||||
|
Write your own elements, and interface with them however you want to
|
||||||
|
### Efficient rendering & updating
|
||||||
|
The elements only update&re-render when state changes
|
||||||
|
### Code hotswap
|
||||||
|
Save a file, and see changes immediately
|
||||||
|
## User facing interface
|
||||||
```lua
|
```lua
|
||||||
Element(function,reloader,w,h,parameters) --Creates a new element
|
helium.element(function,reloader,w,h,parameters)
|
||||||
:draw(x,y) --Renders the element at a location
|
->Element --Creates a new element
|
||||||
:undraw() --Removes the element from the render buffer
|
:draw(x,y) --Renders the element at a location
|
||||||
|
:undraw() --Removes the element from the render buffer
|
||||||
|
|
||||||
--The intended loader for element files (supports optional live hotswapping)
|
--The intended loader for element files (supports optional live hotswapping)
|
||||||
HeliumLoader(filepath) -> ElementFactory
|
HeliumLoader(filepath) -> ElementFactory
|
||||||
ElementFactory(w,h,parameters) -> Element
|
ElementFactory(parameters,w,h) -> Element
|
||||||
|
|
||||||
Input
|
helium.input
|
||||||
.subscribe(x, y, w, h, subType, callback, startOn)
|
.subscribe(x, y, w, h, subType, callback, startOn)
|
||||||
subType -- Subscription type
|
subType -- Subscription type
|
||||||
callback -- Subscription callback on event
|
callback -- Subscription callback on event
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user