-
Notifications
You must be signed in to change notification settings - Fork 0
button_module:new
Looobay edited this page Apr 30, 2024
·
1 revision
This function allows you to load a button in the love.load()
function.
button_module:new(x,y,width,height,color,text,textColor,func,center)
-
x
(number) The position of the new button (x-axis). -
y
(number) The position of the new button (y-axis). -
width
(number) Width of the button. -
height
(number) Height of the button. -
color
(table) The color of the button. (Exemple : {1,0,0} for red) -
text
(string) The text of the button. -
textColor
(table) The color of the text. (Exemple : {1,0,0} for red) -
func
(function) The function that will be executed when the button is clicked. -
center
(boolean) Determines if the text is centered.
- Nothing.