{"action":"created","issue":{"url":"https://api.github.com/repos/Blu3wolf/Treefarm-Lite/issues/25","repository_url":"https://api.github.com/repos/Blu3wolf/Treefarm-Lite","labels_url":"https://api.github.com/repos/Blu3wolf/Treefarm-Lite/issues/25/labels{/name}","comments_url":"https://api.github.com/repos/Blu3wolf/Treefarm-Lite/issues/25/comments","events_url":"https://api.github.com/repos/Blu3wolf/Treefarm-Lite/issues/25/events","html_url":"https://github.com/Blu3wolf/Treefarm-Lite/issues/25","id":149867861,"number":25,"title":"Treefarms suddently stops working. Unsure what causes it...","user":{"login":"Valerate","id":9370337,"avatar_url":"https://avatars.githubusercontent.com/u/9370337?v=3","gravatar_id":"","url":"https://api.github.com/users/Valerate","html_url":"https://github.com/Valerate","followers_url":"https://api.github.com/users/Valerate/followers","following_url":"https://api.github.com/users/Valerate/following{/other_user}","gists_url":"https://api.github.com/users/Valerate/gists{/gist_id}","starred_url":"https://api.github.com/users/Valerate/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Valerate/subscriptions","organizations_url":"https://api.github.com/users/Valerate/orgs","repos_url":"https://api.github.com/users/Valerate/repos","events_url":"https://api.github.com/users/Valerate/events{/privacy}","received_events_url":"https://api.github.com/users/Valerate/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/Blu3wolf/Treefarm-Lite/labels/confirmed%20bug","name":"confirmed bug","color":"fc2929"},{"url":"https://api.github.com/repos/Blu3wolf/Treefarm-Lite/labels/fixed?","name":"fixed?","color":"bfe5bf"},{"url":"https://api.github.com/repos/Blu3wolf/Treefarm-Lite/labels/important","name":"important","color":"fbca04"}],"state":"open","locked":false,"assignee":{"login":"Blu3wolf","id":12153041,"avatar_url":"https://avatars.githubusercontent.com/u/12153041?v=3","gravatar_id":"","url":"https://api.github.com/users/Blu3wolf","html_url":"https://github.com/Blu3wolf","followers_url":"https://api.github.com/users/Blu3wolf/followers","following_url":"https://api.github.com/users/Blu3wolf/following{/other_user}","gists_url":"https://api.github.com/users/Blu3wolf/gists{/gist_id}","starred_url":"https://api.github.com/users/Blu3wolf/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Blu3wolf/subscriptions","organizations_url":"https://api.github.com/users/Blu3wolf/orgs","repos_url":"https://api.github.com/users/Blu3wolf/repos","events_url":"https://api.github.com/users/Blu3wolf/events{/privacy}","received_events_url":"https://api.github.com/users/Blu3wolf/received_events","type":"User","site_admin":false},"milestone":null,"comments":31,"created_at":"2016-04-20T19:49:17Z","updated_at":"2016-04-30T16:23:02Z","closed_at":null,"body":"Hi\r\n\r\nMy treefarms randomly stops working, both before sappling enter and when there's fully mature trees. Only fix is to replace the farm, which sucks to do over and over.\r\n\r\nModlist:\r\n{\r\n    \"mods\": [\r\n        {\r\n            \"name\": \"base\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"5dim_automatization\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"5dim_battlefield\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"5dim_core\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"5dim_decoration\",\r\n            \"enabled\": \"false\"\r\n        },\r\n        {\r\n            \"name\": \"5dim_energy\",\r\n            \"enabled\": \"false\"\r\n        },\r\n        {\r\n            \"name\": \"5dim_logistic\",\r\n            \"enabled\": \"false\"\r\n        },\r\n        {\r\n            \"name\": \"5dim_mining\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"5dim_module\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"5dim_ores\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"5dim_resources\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"5dim_trains\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"5dim_transport\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"5dim_vehicle\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"AdvancedEquipment\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"bobassembly\",\r\n            \"enabled\": \"false\"\r\n        },\r\n        {\r\n            \"name\": \"bobconfig\",\r\n            \"enabled\": \"false\"\r\n        },\r\n        {\r\n            \"name\": \"bobelectronics\",\r\n            \"enabled\": \"false\"\r\n        },\r\n        {\r\n            \"name\": \"bobenemies\",\r\n            \"enabled\": \"false\"\r\n        },\r\n        {\r\n            \"name\": \"boblibrary\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"boblogistics\",\r\n            \"enabled\": \"false\"\r\n        },\r\n        {\r\n            \"name\": \"bobmining\",\r\n            \"enabled\": \"false\"\r\n        },\r\n        {\r\n            \"name\": \"bobmodules\",\r\n            \"enabled\": \"false\"\r\n        },\r\n        {\r\n            \"name\": \"bobores\",\r\n            \"enabled\": \"false\"\r\n        },\r\n        {\r\n            \"name\": \"bobplates\",\r\n            \"enabled\": \"false\"\r\n        },\r\n        {\r\n            \"name\": \"bobpower\",\r\n            \"enabled\": \"false\"\r\n        },\r\n        {\r\n            \"name\": \"bobtech\",\r\n            \"enabled\": \"false\"\r\n        },\r\n        {\r\n            \"name\": \"bobwarfare\",\r\n            \"enabled\": \"false\"\r\n        },\r\n        {\r\n            \"name\": \"clock\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"CORE-DyTech-Core\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"Cursed-PI\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"EvoGUI\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"FARL\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"Force Fields\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"Foreman\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"InterfaceChest\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"KS_Power\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"Landfill\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"MAIN-DyTech-Dynamics\",\r\n            \"enabled\": \"false\"\r\n        },\r\n        {\r\n            \"name\": \"MAIN-DyTech-Machine\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"MAIN-DyTech-Power\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"MAIN-DyTech-War\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"MAIN-DyTech-World\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"RailTanker\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"research-queue\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"RoadWorks\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"rso-mod\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"scarynights\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"SmartLoader\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"SmartSplitters\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"TheFatController\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"Treefarm-AC\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"Treefarm-Lite\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"upgrade-planner\",\r\n            \"enabled\": \"true\"\r\n        },\r\n        {\r\n            \"name\": \"Warehousing\",\r\n            \"enabled\": \"true\"\r\n        }\r\n    ]\r\n}\r\n"},"comment":{"url":"https://api.github.com/repos/Blu3wolf/Treefarm-Lite/issues/comments/215976687","html_url":"https://github.com/Blu3wolf/Treefarm-Lite/issues/25#issuecomment-215976687","issue_url":"https://api.github.com/repos/Blu3wolf/Treefarm-Lite/issues/25","id":215976687,"user":{"login":"Peppe-KSP","id":6327177,"avatar_url":"https://avatars.githubusercontent.com/u/6327177?v=3","gravatar_id":"","url":"https://api.github.com/users/Peppe-KSP","html_url":"https://github.com/Peppe-KSP","followers_url":"https://api.github.com/users/Peppe-KSP/followers","following_url":"https://api.github.com/users/Peppe-KSP/following{/other_user}","gists_url":"https://api.github.com/users/Peppe-KSP/gists{/gist_id}","starred_url":"https://api.github.com/users/Peppe-KSP/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Peppe-KSP/subscriptions","organizations_url":"https://api.github.com/users/Peppe-KSP/orgs","repos_url":"https://api.github.com/users/Peppe-KSP/repos","events_url":"https://api.github.com/users/Peppe-KSP/events{/privacy}","received_events_url":"https://api.github.com/users/Peppe-KSP/received_events","type":"User","site_admin":false},"created_at":"2016-04-30T16:23:02Z","updated_at":"2016-04-30T16:23:02Z","body":"> Thats fair, but I dont actually do a #count on the table contents. In the case of global.tf.treesToGrow[event.tick], I dont even bother removing each field as Im going through - it has a temporary life cycle. The table (an unordered list) is built as trees are cycled over when growing, and then on the appropriate tick they are themselves cycled over, building a new table (more likely many new tables, given the randomness), and then just setting the old one to nil. \r\n\r\nYeah I guess I am just curious if setting the processed tick to nil has some overhead cost.  If the entry still remains in a raw count of the table using: #global.tf.treesToGrow.  I know i loop over the table different using an index value, so the table count was important to me.\r\n\r\nI think you are right you don't need to worry about the count of tree updates since you would never call the that tick index again, so if a tree is invalid don't worry about it as it's parent tick will be dead soon enough.  Is there overhead to finding the parent tick by it's game.tick index after a 20 hour long game? -- Lua is returning 1 row that it had to sort out of 4 million nils?\r\n\r\n"}}