-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathyan.lua
More file actions
57 lines (46 loc) · 1.37 KB
/
yan.lua
File metadata and controls
57 lines (46 loc) · 1.37 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
--[[
_ _ __ _ _ __
| | | |/ _` | '_ \
| |_| | (_| | | | |
\__, |\__,_|_| |_|
__/ |
|___/
A simple UI library for Love2D, based on Roblox's UI system and inspired by dphfox's Fusion.
Made by @Nibbl-z
https://github.com/Nibbl-z/Yan
]]
yan = {}
uibase = require "yan.uibase"
textlabel = require "yan.textlabel"
textinput = require "yan.textinput"
imagelabel = require "yan.imagelabel"
screen = require "yan.screen"
tween = require "yan.tween"
UDim2 = require "yan.datatypes.udim2"
UDim = require "yan.datatypes.udim"
Color = require "yan.datatypes.color"
Vector2 = require "yan.datatypes.vector2"
EasingStyle = require "yan.datatypes.easingstyle"
TweenInfo = require "yan.datatypes.tweeninfo"
common = require "yan.common" -- whatever just take it
local registry = require "yan.registry"
--- Updates yan. Call this in `love.update`.
---@param dt number
function yan:update(dt)
registry:update(dt)
end
--- Draws all screens. Call this in `love.draw`.
function yan:draw()
registry:draw()
end
--- Handles all text input. Call this in `love.textinput`.
---@param text string
function yan:textinput(text)
registry:textinput(text)
end
--- Handles all key presses. Call this in `love.keypressed`.
---@param key string
function yan:keypressed(key)
registry:keypressed(key)
end
return yan