eronoobos / BABAR-The-Shardifant

Balanced Annihilation & Balanced Annilhation Reloaded configuration for Shard
2 stars 1 forks source link

Fatal: LuaRules: cannot allocate more memory! (805306386 bytes already used, 805306368 bytes maximum) #33

Open pandaro opened 8 years ago

pandaro commented 8 years ago

for now in nation map (32x32)

eronoobos commented 8 years ago

Sadly, this is only a LuaAI issue. Because of something that's inside an if ShardSpringLua then statement? Because of something in AILoader.lua or preload/shard_lua/? Or because of different garbage collection behaviour between the two environments?

eronoobos commented 8 years ago

https://github.com/eronoobos/BABAR-The-Shardifant/commit/ae5e9eba84734e003b580a283df3c5388d9d3a26 seems to have helped a little, presumably because the table.removes don't leave extra crap sitting around in tables anymore. But still there's something else leaking tons of memory.

eronoobos commented 8 years ago

notes:

(data gathered from /debug)

Memory usage therefore indeed seems to be related to garbage collection. I presume that what's left when the game is paused are the Lua tables that are not garbage. Maybe the AI is simply updating tables too often?