I couldn't get my .love file to upload without an error. As soon as I can I will upload it.
Code: Select all
mouse_x, mouse_y = love.mouse.getPosition()
-- Play Button
IMG_button_play_w = IMG_button_play:getWidth()
IMG_button_play_h = IMG_button_play:getHeight()
IMG_button_play_x = (screen.center_w - (IMG_button_play:getWidth() / 2))
IMG_button_play_y = (screen.center_h - (IMG_button_play:getHeight() / 2 + 125))
love.graphics.draw(IMG_button_play, IMG_button_play_x, IMG_button_play_y)
if mouse_x > IMG_button_play_x and mouse_x < IMG_button_play_x + IMG_button_play_w and mouse_y > IMG_button_play_y and mouse_y < IMG_button_play_y + IMG_button_play_h then
love.graphics.print("BUTTON: PLAY ", 10, 95)
if love.mouse.isDown("l") then
_state = 3
love.audio.stop(intro)
end
end