134 lines
2.7 KiB
Lua
134 lines
2.7 KiB
Lua
import "CoreLibs/easing"
|
|
import "CoreLibs/object"
|
|
import "CoreLibs/sprites"
|
|
import "CoreLibs/timer"
|
|
import "CoreLibs/ui"
|
|
import "CoreLibs/math"
|
|
|
|
-- Libraries
|
|
import 'libraries/noble/Noble'
|
|
import "libraries/AnimatedSprite"
|
|
import "libraries/pdParticles"
|
|
import "libraries/playout"
|
|
import "libraries/pdDialogue"
|
|
|
|
import 'utilities/enum'
|
|
import 'utilities/ui'
|
|
import 'utilities/utils'
|
|
|
|
ZIndex = {
|
|
player = 4,
|
|
enemy = 3,
|
|
props = 3,
|
|
fx = 6,
|
|
ui = 10,
|
|
alert = 12,
|
|
ground = 100,
|
|
flash = 101
|
|
}
|
|
CollideGroups = {
|
|
player = 1,
|
|
enemy = 2,
|
|
props = 3,
|
|
items = 4,
|
|
wall = 5
|
|
}
|
|
|
|
Drones = {
|
|
{
|
|
id = 1,
|
|
name = "Quad FPV",
|
|
description =
|
|
"This is a quadrocopter with a camera on it. It's a good drone for beginners. It's easy to control and has a good battery life.",
|
|
price = 100,
|
|
locked = false,
|
|
preview = Graphics.image.new("assets/sprites/assemble/1/preview.png"),
|
|
full = Graphics.image.new("assets/sprites/assemble/1/8.png")
|
|
},
|
|
{
|
|
id = 2,
|
|
name = "Drone 2",
|
|
description = "This is a drone",
|
|
price = 200,
|
|
locked = true,
|
|
preview = nil,
|
|
full = nil
|
|
},
|
|
{
|
|
id = 3,
|
|
name = "Drone 3",
|
|
description = "This is a drone",
|
|
price = 300,
|
|
locked = true,
|
|
preview = nil,
|
|
full = nil
|
|
},
|
|
{
|
|
id = 4,
|
|
name = "Drone 4",
|
|
description = "This is a drone",
|
|
price = 400,
|
|
locked = true,
|
|
preview = nil,
|
|
full = nil
|
|
}
|
|
}
|
|
|
|
import "scripts/player"
|
|
import "scripts/bigBoomSprite"
|
|
import "scripts/groundSprite"
|
|
import "scripts/balebaSprite"
|
|
import "scripts/dangerSprite"
|
|
import "scripts/tankSprite"
|
|
import "scripts/progressBar"
|
|
import "scripts/selectionSprite"
|
|
import "scripts/DroneCard"
|
|
import "scripts/pageSprite"
|
|
|
|
import "scenes/BaseScene"
|
|
import 'scenes/Assemble'
|
|
import 'scenes/DroneCardSelector'
|
|
import 'scenes/Menu'
|
|
import 'scenes/Game'
|
|
|
|
Difficulty = {
|
|
Easy = "Easy",
|
|
Medium = "Medium",
|
|
Hard = "Hard"
|
|
}
|
|
|
|
DifficultySettings = {
|
|
[Difficulty.Easy] = {
|
|
assebleTime = 1700,
|
|
distance = 200
|
|
},
|
|
[Difficulty.Medium] = {
|
|
assebleTime = 1000,
|
|
distance = 350
|
|
},
|
|
[Difficulty.Hard] = {
|
|
assebleTime = 500,
|
|
distance = 500
|
|
}
|
|
}
|
|
|
|
Noble.Settings.setup({
|
|
difficulty = Difficulty.Medium,
|
|
music = true,
|
|
debug = true
|
|
})
|
|
|
|
Noble.GameData.setup({
|
|
drone1 = 0,
|
|
drone2 = 0,
|
|
drone3 = 0,
|
|
drone4 = 0,
|
|
money = 150
|
|
})
|
|
|
|
playdate.display.setRefreshRate(50)
|
|
|
|
Noble.showFPS = false
|
|
|
|
Noble.new(Assemble)
|