begin PLUS

This commit is contained in:
PossiblyAxolotl 2024-03-07 19:10:56 -06:00
parent e408cc8098
commit 73008809fe
6 changed files with 33 additions and 23 deletions

View file

@ -38,6 +38,8 @@ totalEnergy = 0
showEnergy = false
isPlus = false
next = nil
local gfx <const> = playdate.graphics

View file

@ -28,6 +28,10 @@ local sfxSelect = playdate.sound.sampleplayer.new("sfx/select")
sfxAccept:setVolume(0.5)
sfxSelect:setVolume(0.5)
local function setLogoPos()
logopos = -130
end
mainmenu = {}
function mainMenuCreation()
barposLerp = 160
@ -133,7 +137,7 @@ end
local function dataLoad()
barpos = 160
logopos = -112
setLogoPos()
local lvls = {"1. HOOK.json","2. ROCKET.json","3. HUT.json","4. SPINNER.json","5. SHUTTLE.json","6. SHELL.json","7. PYRAMID.json","8. KITCHEN.json","9. LADDER.json","10. CITY.json","11. FLOWER.json", "12. BOXES.json","13. SNAKE.json","14. TOWER.json","15. ESCAPE.json","H1. CAVEYARD.json", "H2. PUMPKIN.json", "H3. HAUNTED HOUS.json", "H4. TRICK OR TREAT.json", "H5. CANDY CORN.json","H6. COFFIN.json"}
local m = {}
m[0], m[1] = "data", "EXTRAS"
@ -156,7 +160,7 @@ end
local function customLoad()
barpos = 160
logopos = -112
setLogoPos()
local lvls = playdate.file.listFiles("levels")
local m = {}
m[0], m[1] = "customs", "BACK"
@ -178,7 +182,7 @@ local function customLoad()
end
function editLoad()
logopos = -112
setLogoPos()
barpos = 160
local lvls = playdate.file.listFiles("levels")
local m = {}
@ -200,7 +204,7 @@ function editLoad()
createMenu(m)
end
songlist = {"BACK","POV: YOU ARE A ROCKET","A LONELY, LOST SHIP", "LEVEL COMPLETE", "GAME COMPLETE", "CHIPVIBE2", "ORANGER CHIP","WACKMAN","HAUNTED HOUS", "SPOOKY ZONE","A HAPPY, FOUND SHIP"}
songlist = {"BACK","POV: YOU ARE A ROCKET","A LONELY, LOST SHIP", "LEVEL COMPLETE", "GAME COMPLETE", "CHIPVIBE2", "ORANGER CHIP","WACKMAN","HAUNTED HOUS", "SPOOKY ZONE","A HAPPY, FOUND SHIP", "AS WE ROCKET AWAY"}
songlist[0] = "musicbox"
function menuButtonPress(name, index)
@ -238,15 +242,15 @@ function menuButtonPress(name, index)
elseif name == "NO GRAVITY" then
setGrav(0)
barpos = 160
logopos = -112
setLogoPos()
elseif name == "NEGATIVE GRAVITY" then
setGrav(-0.2)
barpos = 160
logopos = -112
setLogoPos()
elseif name == "REGULAR GRAVITY" then
setGrav(0.2)
barpos = 160
logopos = -112
setLogoPos()
elseif name == "CHANGE MUSIC" then
setEditor("music")
@ -269,16 +273,16 @@ function menuButtonPress(name, index)
mode = "editor"
elseif name == "INVERT COLOURS" then
barpos = 160
logopos = -112
setLogoPos()
playdate.display.setInverted(not playdate.display.getInverted())
elseif name == "EXTRAS" then
local m = {}
barpos = 160
logopos = -112
setLogoPos()
--m[0],m[1], m[2], m[3], m[4], m[5], m[6] = "extras", "BACK", "MUSIC BOX", "LINKS", "END CUTSCENE", "START CUTSCENE", "LEVEL SELECT"
m[0],m[1], m[2], m[3], m[4], m[5], m[6],m[7] = "extras", "BACK","LINKS","END CUTSCENE", "START CUTSCENE", "MUSIC BOX", "LEVEL SELECT", "START HALLOWEEN GAME"
m[0],m[1], m[2], m[3], m[4], m[5], m[6],m[7], m[8] = "extras", "BACK","LINKS","END CUTSCENE", "START CUTSCENE", "MUSIC BOX", "LEVEL SELECT", "START HALLOWEEN GAME", "START PLUS GAME"
if playdate.file.exists("bonusLevels.rocketbytes") then
m[6] = "EXTRA LEVELS"
end
@ -287,7 +291,7 @@ function menuButtonPress(name, index)
local m = {}
m[0],m[1] = "qrs", "BACK"
createMenu(m)
logopos = -112
setLogoPos()
barpos = 160
elseif name == "USER LEVELS" then
page = 0
@ -312,26 +316,26 @@ function menuButtonPress(name, index)
elseif name == "BACK" or name == "CANCEL" then
if menu == "musicbox" then
local m = {}
m[0],m[1], m[2], m[3], m[4], m[5], m[6],m[7] = "extras", "BACK","LINKS","END CUTSCENE", "START CUTSCENE", "MUSIC BOX", "LEVEL SELECT", "START HALLOWEEN GAME"
m[0],m[1], m[2], m[3], m[4], m[5], m[6],m[7], m[8] = "extras", "BACK","LINKS","END CUTSCENE", "START CUTSCENE", "MUSIC BOX", "LEVEL SELECT", "START HALLOWEEN GAME", "START PLUS GAME"
if playdate.file.exists("bonusLevels.rocketbytes") then
m[6] = "EXTRA LEVELS"
barpos = 160
logopos = -112
setLogoPos()
end
song:stop()
song:load("sfx/song1")
song:play(0)
local m = {}
barpos = 160
logopos = -112
m[0],m[1], m[2], m[3], m[4], m[5], m[6],m[7] = "extras", "BACK","LINKS","END CUTSCENE", "START CUTSCENE", "MUSIC BOX", "LEVEL SELECT", "START HALLOWEEN GAME"
setLogoPos()
m[0],m[1], m[2], m[3], m[4], m[5], m[6],m[7], m[8] = "extras", "BACK","LINKS","END CUTSCENE", "START CUTSCENE", "MUSIC BOX", "LEVEL SELECT", "START HALLOWEEN GAME", "START PLUS GAME"
createMenu(m)
elseif menu == "qrs" or menu == "data" or menu == "dat" then
local m = {}
m[0],m[1], m[2], m[3], m[4], m[5], m[6],m[7] = "extras", "BACK","LINKS","END CUTSCENE", "START CUTSCENE", "MUSIC BOX", "LEVEL SELECT", "START HALLOWEEN GAME"
m[0],m[1], m[2], m[3], m[4], m[5], m[6],m[7], m[8] = "extras", "BACK","LINKS","END CUTSCENE", "START CUTSCENE", "MUSIC BOX", "LEVEL SELECT", "START HALLOWEEN GAME", "START PLUS GAME"
createMenu(m)
barpos = 160
logopos = -112
setLogoPos()
elseif menu == nil then
else
@ -339,7 +343,7 @@ function menuButtonPress(name, index)
end
elseif name == "MUSIC BOX" then
logopos = -112
setLogoPos()
barpos = 160
song:stop()
createMenu(songlist)
@ -348,7 +352,7 @@ function menuButtonPress(name, index)
menu = nil
editLoadName(name)
elseif menu == "musicbox" then
logopos = -112
setLogoPos()
barpos = 160
mode = "music"
songTitle = songlist[index]

View file

@ -50,15 +50,19 @@ function updateBox()
playdate.graphics.drawLine(0,19,400,19)
local time = playdate.getTime()
local displayTime = time.minute
if time.minute < 10 then
displayTime = "0"..time.minute
end
if timeRate == true then
local prefix = " AM"
if time.hour > 11 then prefix = " PM" end
if time.hour == 0 then time.hour = 24 end
local tt = (time.hour % 12)
if tt == 0 then tt = 12 end
playdate.graphics.drawText(tt..":"..time.minute..prefix,0,0)
playdate.graphics.drawText(tt..":"..displayTime..prefix,0,0)
else
playdate.graphics.drawText(time.hour..":"..time.minute,0,0)
playdate.graphics.drawText(time.hour..":"..displayTime,0,0)
end
playdate.graphics.drawText(math.ceil(playdate.getBatteryPercentage()).."%",400-playdate.graphics.getTextSize(math.ceil(playdate.getBatteryPercentage()).."%"),0)

BIN
Source/gfx/bytesplus.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 625 B

View file

@ -3,6 +3,6 @@ author=PossiblyAxolotl
description=Help a crew of rockets collect energy to get back home!
bundleID=com.PossiblyAxolotl.RocketBytes
launchSoundPath=launcher/rocketing
version=1.4.3
buildNumber=10403
version=1.5.0
buildNumber=1500
imagePath=launcher

BIN
Source/sfx/song11.wav Normal file

Binary file not shown.