Skip to content

Commit

Permalink
Old uncommited changes.
Browse files Browse the repository at this point in the history
  • Loading branch information
nagolove committed Feb 6, 2021
1 parent 43bc3cf commit a317893
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 11 deletions.
5 changes: 3 additions & 2 deletions common.lua
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,7 @@ function compareDates(now, date)
end

function getDefaultSettings()
print("getDefaultSettings")
return {
volume = 0.2,
firstRun = true,
Expand All @@ -160,14 +161,14 @@ function readSettings()

if data then
ok, data = serpent.load(data)
if not ok then
if not data then
data = getDefaultSettings()
end
else
data = getDefaultSettings()
end

settings = data
return data
end

function writeSettings()
Expand Down
6 changes: 3 additions & 3 deletions hex.lua
Original file line number Diff line number Diff line change
Expand Up @@ -182,8 +182,8 @@ end

-- map - 2d array
function newHexField(startcx, startcy, map,rad, color)
print(inspect(map))
print(#map)
--print(inspect(map))
--print(#map)
local xcount = #map
local ycount = #map[1]
assert(xcount == ycount)
Expand Down Expand Up @@ -283,7 +283,7 @@ function newHexField(startcx, startcy, map,rad, color)

mesh:setVertices(meshData)

print("result", inspect(result))
--print("result", inspect(result))
return result, mesh
end

Expand Down
7 changes: 5 additions & 2 deletions main.lua
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
onAndroid = love.system.getOS() == "Android"
__DEBUG__ = false
onAndroid = love.system.getOS() == "Android"
useKeyboard = true
preventiveFirstRun = true
--preventiveFirstRun = false
Expand Down Expand Up @@ -97,7 +98,9 @@ function subInit()
end

function love.load(arg)
readSettings()
settings = readSettings()
print("SUUKA")
print(inspect(settings))
loadLocales()

print("arg", inspect(arg))
Expand Down
6 changes: 3 additions & 3 deletions nback.lua
Original file line number Diff line number Diff line change
Expand Up @@ -273,9 +273,7 @@ end

function nback:drawMapIndices()
local currentHex = self.hexField:get(1, 1)
--print(inspect(currentHex))
local currentHex = self.hexField:get(2, 1)
--print(inspect(currentHex))

g.setColor{1, 0, 0}
for k, v in pairs(self.hexField) do
Expand Down Expand Up @@ -624,7 +622,9 @@ function nback:draw()
--self:drawField()

gr.draw(self.hexMesh)
self:drawMapIndices()
if __DEBUG__ then
self:drawMapIndices()
end

self:drawActiveSignal()
--self.processor:update()
Expand Down
2 changes: 1 addition & 1 deletion pkg_send.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/env bash

packagename="nback2.zip"
packagename="nback_hex.zip"

case "$(uname)" in
Linux*)
Expand Down

0 comments on commit a317893

Please sign in to comment.