Cool menu stuff

This commit is contained in:
entar 2025-06-05 23:35:04 +07:00
parent 6849cb904d
commit 87dbbfc4ad
8 changed files with 538 additions and 6 deletions

BIN
images/menuBG.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 606 KiB

BIN
images/menuBGoverlay.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 715 KiB

View File

@ -20,7 +20,30 @@ local stateLoaded = false
local pressed = {false,false,false}
local font = love.graphics.newFont("fonts/Phantomuff.ttf", 25)
local bg
local logo
local gf
local freaky = love.audio.newSource("sounds/freakyMenu.ogg", "stream")
local function setup()
bg = myTypes.Image("images/menuBG.png", 0)
bg.ui = false
gf = myTypes.Sprite("sprites/gfDanceTitle.png", "sprites/gfDanceTitle.json")
gf:PlayAnimation("gfDance", 24, true)
gf.position = myTypes.Vector2(340, 60)
for index, rect in next, gf.quads.gfDance do
rect.resize = myTypes.Vector2(0.7,.7)
end
logo = myTypes.Sprite("sprites/logoBumpin.png", "sprites/logoBumpin.json")
logo:PlayAnimation("logo bumpin", 24, true)
logo.position = myTypes.Vector2(-80, 0)
freaky:play()
end
local font = love.graphics.newFont("fonts/Phantomuff.ttf", 40)
-- for index, song in next, songs do
-- curSong = index
@ -42,6 +65,7 @@ function love.update(dt)
curState.finish()
end
elseif not curState then
myTypes.cameraTarget = myTypes.Vector2(0,0)
myTypes.updateSprites(dt)
end
end
@ -51,25 +75,30 @@ function love.draw()
curState.draw()
else
myTypes.drawSprites()
love.graphics.print(string.format("Song: %s, Difficulty: %s, List: %s", curSong.name, curDiff, logging.dump(curDiffList)), font, love.graphics:getWidth()/2 - 20, love.graphics:getHeight()/2 + 150, 0, 1, 1, 200)
love.graphics.print({{0,0,0}, string.format("Song: %s, Difficulty: %s, List: %s", curSong.name, curDiff, logging.dump(curDiffList))}, font, love.graphics.getWidth()/4, love.graphics:getHeight()/2 + 250, 0, 1, 1, 200)
love.graphics.print(
string.format("Left: %s, Down: %s, Up: %s, Right: %s \nDownscroll: %s",
{{0,0,0}, string.format("Left: %s, Down: %s, Up: %s, Right: %s \nDownscroll: %s",
keybinds[1],
keybinds[2],
keybinds[3],
keybinds[4],
settings.Downscroll
))
love.graphics.print("Press 1 to change LEFT \nPress 2 to change DOWN \nPress 3 to change UP \nPress 4 to change RIGHT \nPress 0 to toggle DOWNSCROLL", 500, 0)
)})
love.graphics.print({{0,0,0}, "Press 1 to change LEFT \nPress 2 to change DOWN \nPress 3 to change UP \nPress 4 to change RIGHT \nPress 0 to toggle DOWNSCROLL"}, 500, 0)
end
end
function run()
myTypes.destroyAllSprites()
freaky:stop()
curState = state(curSong.name, curDiff)
curState.quit = function()
curState = nil
stateLoaded = false
myTypes.destroyAllSprites()
setup()
end
curState.restart = function()
curState = nil
@ -122,4 +151,6 @@ function love.keypressed(key, un, is)
end
end
love.window.setMode(1280, 720, { fullscreen = false , resizable = true})
love.window.setMode(1280, 720, { fullscreen = false , resizable = true})
setup()

BIN
sounds/freakyMenu.ogg Normal file

Binary file not shown.

337
sprites/gfDanceTitle.json Normal file
View File

@ -0,0 +1,337 @@
{
"TextureAtlas": {
"SubTexture": [
{
"_name": "gfDance0000",
"_x": "0",
"_y": "0",
"_width": "717",
"_height": "648",
"_frameX": "-2",
"_frameY": "-14",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0001",
"_x": "727",
"_y": "0",
"_width": "721",
"_height": "648",
"_frameX": "0",
"_frameY": "-14",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0002",
"_x": "1458",
"_y": "0",
"_width": "721",
"_height": "646",
"_frameX": "0",
"_frameY": "-16",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0003",
"_x": "2189",
"_y": "0",
"_width": "717",
"_height": "646",
"_frameX": "-2",
"_frameY": "-16",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0004",
"_x": "2916",
"_y": "0",
"_width": "717",
"_height": "649",
"_frameX": "-2",
"_frameY": "-13",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0005",
"_x": "0",
"_y": "659",
"_width": "717",
"_height": "649",
"_frameX": "-2",
"_frameY": "-13",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0006",
"_x": "727",
"_y": "659",
"_width": "717",
"_height": "650",
"_frameX": "-2",
"_frameY": "-12",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0007",
"_x": "1454",
"_y": "659",
"_width": "717",
"_height": "661",
"_frameX": "-2",
"_frameY": "-1",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0008",
"_x": "1454",
"_y": "659",
"_width": "717",
"_height": "661",
"_frameX": "-2",
"_frameY": "-1",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0009",
"_x": "1454",
"_y": "659",
"_width": "717",
"_height": "661",
"_frameX": "-2",
"_frameY": "-1",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0010",
"_x": "2181",
"_y": "659",
"_width": "717",
"_height": "662",
"_frameX": "-2",
"_frameY": "0",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0011",
"_x": "2181",
"_y": "659",
"_width": "717",
"_height": "662",
"_frameX": "-2",
"_frameY": "0",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0012",
"_x": "2181",
"_y": "659",
"_width": "717",
"_height": "662",
"_frameX": "-2",
"_frameY": "0",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0013",
"_x": "2908",
"_y": "659",
"_width": "717",
"_height": "661",
"_frameX": "-2",
"_frameY": "-1",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0014",
"_x": "2908",
"_y": "659",
"_width": "717",
"_height": "661",
"_frameX": "-2",
"_frameY": "-1",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0015",
"_x": "0",
"_y": "1331",
"_width": "717",
"_height": "650",
"_frameX": "-2",
"_frameY": "-12",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0016",
"_x": "727",
"_y": "1331",
"_width": "721",
"_height": "650",
"_frameX": "0",
"_frameY": "-12",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0017",
"_x": "1458",
"_y": "1331",
"_width": "721",
"_height": "650",
"_frameX": "0",
"_frameY": "-12",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0018",
"_x": "2189",
"_y": "1331",
"_width": "717",
"_height": "650",
"_frameX": "-2",
"_frameY": "-12",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0019",
"_x": "2916",
"_y": "1331",
"_width": "717",
"_height": "651",
"_frameX": "-2",
"_frameY": "-11",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0020",
"_x": "0",
"_y": "1992",
"_width": "717",
"_height": "651",
"_frameX": "-2",
"_frameY": "-11",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0021",
"_x": "727",
"_y": "1992",
"_width": "717",
"_height": "652",
"_frameX": "-2",
"_frameY": "-10",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0022",
"_x": "1454",
"_y": "1992",
"_width": "717",
"_height": "657",
"_frameX": "-2",
"_frameY": "-5",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0023",
"_x": "1454",
"_y": "1992",
"_width": "717",
"_height": "657",
"_frameX": "-2",
"_frameY": "-5",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0024",
"_x": "1454",
"_y": "1992",
"_width": "717",
"_height": "657",
"_frameX": "-2",
"_frameY": "-5",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0025",
"_x": "2181",
"_y": "1992",
"_width": "717",
"_height": "656",
"_frameX": "-2",
"_frameY": "-6",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0026",
"_x": "2181",
"_y": "1992",
"_width": "717",
"_height": "656",
"_frameX": "-2",
"_frameY": "-6",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0027",
"_x": "2181",
"_y": "1992",
"_width": "717",
"_height": "656",
"_frameX": "-2",
"_frameY": "-6",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0028",
"_x": "2908",
"_y": "1992",
"_width": "717",
"_height": "656",
"_frameX": "-2",
"_frameY": "-6",
"_frameWidth": "721",
"_frameHeight": "662"
},
{
"_name": "gfDance0029",
"_x": "2908",
"_y": "1992",
"_width": "717",
"_height": "656",
"_frameX": "-2",
"_frameY": "-6",
"_frameWidth": "721",
"_frameHeight": "662"
}
],
"_imagePath": "gfDanceTitle.png"
}
}

BIN
sprites/gfDanceTitle.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

164
sprites/logoBumpin.json Normal file
View File

@ -0,0 +1,164 @@
{
"TextureAtlas": {
"SubTexture": [
{
"_name": "logo bumpin0000",
"_x": "0",
"_y": "0",
"_width": "894",
"_height": "670",
"_frameX": "-22",
"_frameY": "-16",
"_frameWidth": "939",
"_frameHeight": "703"
},
{
"_name": "logo bumpin0001",
"_x": "904",
"_y": "0",
"_width": "939",
"_height": "703"
},
{
"_name": "logo bumpin0002",
"_x": "904",
"_y": "0",
"_width": "939",
"_height": "703"
},
{
"_name": "logo bumpin0003",
"_x": "0",
"_y": "713",
"_width": "911",
"_height": "683",
"_frameX": "-14",
"_frameY": "-10",
"_frameWidth": "939",
"_frameHeight": "703"
},
{
"_name": "logo bumpin0004",
"_x": "0",
"_y": "713",
"_width": "911",
"_height": "683",
"_frameX": "-14",
"_frameY": "-10",
"_frameWidth": "939",
"_frameHeight": "703"
},
{
"_name": "logo bumpin0005",
"_x": "921",
"_y": "713",
"_width": "905",
"_height": "679",
"_frameX": "-17",
"_frameY": "-12",
"_frameWidth": "939",
"_frameHeight": "703"
},
{
"_name": "logo bumpin0006",
"_x": "921",
"_y": "713",
"_width": "905",
"_height": "679",
"_frameX": "-17",
"_frameY": "-12",
"_frameWidth": "939",
"_frameHeight": "703"
},
{
"_name": "logo bumpin0007",
"_x": "921",
"_y": "713",
"_width": "905",
"_height": "679",
"_frameX": "-17",
"_frameY": "-12",
"_frameWidth": "939",
"_frameHeight": "703"
},
{
"_name": "logo bumpin0008",
"_x": "921",
"_y": "713",
"_width": "905",
"_height": "679",
"_frameX": "-17",
"_frameY": "-12",
"_frameWidth": "939",
"_frameHeight": "703"
},
{
"_name": "logo bumpin0009",
"_x": "921",
"_y": "713",
"_width": "905",
"_height": "679",
"_frameX": "-17",
"_frameY": "-12",
"_frameWidth": "939",
"_frameHeight": "703"
},
{
"_name": "logo bumpin0010",
"_x": "921",
"_y": "713",
"_width": "905",
"_height": "679",
"_frameX": "-17",
"_frameY": "-12",
"_frameWidth": "939",
"_frameHeight": "703"
},
{
"_name": "logo bumpin0011",
"_x": "921",
"_y": "713",
"_width": "905",
"_height": "679",
"_frameX": "-17",
"_frameY": "-12",
"_frameWidth": "939",
"_frameHeight": "703"
},
{
"_name": "logo bumpin0012",
"_x": "921",
"_y": "713",
"_width": "905",
"_height": "679",
"_frameX": "-17",
"_frameY": "-12",
"_frameWidth": "939",
"_frameHeight": "703"
},
{
"_name": "logo bumpin0013",
"_x": "921",
"_y": "713",
"_width": "905",
"_height": "679",
"_frameX": "-17",
"_frameY": "-12",
"_frameWidth": "939",
"_frameHeight": "703"
},
{
"_name": "logo bumpin0014",
"_x": "921",
"_y": "713",
"_width": "905",
"_height": "679",
"_frameX": "-17",
"_frameY": "-12",
"_frameWidth": "939",
"_frameHeight": "703"
}
],
"_imagePath": "logoBumpin.png"
}
}

BIN
sprites/logoBumpin.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 679 KiB