It looks like you're new here. If you want to get involved, click one of these buttons!
Hi, I was wondering how to make a plain button at the centre of the screen (a simple box), against a plain black background. When the button is clicked, I want a basic sound played.
Because I’m new here, it would help if someone could show me how to do this in an easy-to-understand step-by-step way, thanks.
I looked at the example projects, but I’m kinda dumb lol so please help.
Comments
here you go
@Vile Your next question is probably going to be how to do multiple buttons. I don't know your programming skills, but this example uses a
class
to handle multiple buttons.@Spartan You're missing an end statement in Button:draw() and have one too many in Button:touched(t). That means that the function Button:touched(t) is inside the function Button:draw(). The way your code is indented isn't the way it actually is.