summaryrefslogtreecommitdiff
path: root/config.lua
diff options
context:
space:
mode:
authorEltrac <hi@guhub.cn>2025-03-09 10:30:05 +0800
committerEltrac <hi@guhub.cn>2025-03-09 10:30:05 +0800
commit533542a892a172b53d519ae6ca152214ed756c12 (patch)
tree29cba0e486ef0668fae444806a1008c8eddaef4d /config.lua
parentc4b1a488b3c995dff5597f1dc4e725232682c231 (diff)
refactor: set map size in config
Diffstat (limited to 'config.lua')
-rw-r--r--config.lua5
1 files changed, 4 insertions, 1 deletions
diff --git a/config.lua b/config.lua
index a80d2d6..df06685 100644
--- a/config.lua
+++ b/config.lua
@@ -28,11 +28,14 @@ config = {
defaultPlayerSpeed = 100,
playerShootCooldown = 0.2,
playerSize = 20,
+
+ initialMapSize = 7,
+ extendedMapSize = 5,
}
-- game default states
function initGame()
- local intialMap = map.generate(4, true)
+ local intialMap = map.generate(config.initialMapSize, true)
G = {
player = Player:new(),
shots = {},