Browse Source

main stuff

master
Nicholas Hayashi 3 years ago
parent
commit
e63a9895ab
  1. 24
      main.lua

24
main.lua

@ -1,11 +1,7 @@
math.randomseed(os.time())
math.random()
math.random()
math.random()
math.random()
-- @TODO -- @TODO
-- main
-- -- scale menu hexes to window size, right now they look bad on smaller resolutions
-- settings menu -- settings menu
-- -- make the volume icon clickable -- -- make the volume icon clickable
-- -- music volume slider or number input box -- -- music volume slider or number input box
@ -32,6 +28,13 @@ math.random()
-- -- place towers -- -- place towers
-- -- move home? -- -- move home?
-- lua's random number generator doesn't really produce random looking values if you don't seed it and discard a few calls first
math.randomseed(os.time())
math.random()
math.random()
math.random()
math.random()
-- aspect ratios seem like a huge mess -- aspect ratios seem like a huge mess
-- for now, i think we should enforce 4:3 -- for now, i think we should enforce 4:3
local RESOLUTION_OPTIONS = { local RESOLUTION_OPTIONS = {
@ -55,8 +58,7 @@ settings = am.load_state("settings", "json") or {
sound_on = true sound_on = true
} }
do
win = am.window{
win = am.window{
width = settings.window_width, width = settings.window_width,
height = settings.window_height, height = settings.window_height,
title = "hexyz", title = "hexyz",
@ -65,8 +67,7 @@ do
highdpi = true, highdpi = true,
letterbox = true, letterbox = true,
show_cursor = true, show_cursor = true,
}
end
}
-- asset interfaces and/or trivial code -- asset interfaces and/or trivial code
require "conf" require "conf"
@ -74,6 +75,7 @@ require "color"
require "sound" require "sound"
require "texture" require "texture"
--
require "src/entity" require "src/entity"
require "src/extra" require "src/extra"
require "src/geometry" require "src/geometry"

Loading…
Cancel
Save