]> git.somenet.org - factorio/some-resourcespam.git/commitdiff
RELEASE 2.0.2 - Correctly skip spamming non-nauvis. This time for real... hopefully master
authorSomeone <someone@somenet.org>
Sun, 27 Oct 2024 01:32:37 +0000 (02:32 +0100)
committerSomeone <someone@somenet.org>
Sun, 27 Oct 2024 01:32:37 +0000 (02:32 +0100)
changelog.txt
control.lua
info.json

index f54abea24e9e0028ed2089ee2d4295f9a44fa220..de71dcbd8c2d9884fa6a3f3e8b1b477582c0c6b0 100644 (file)
@@ -1,3 +1,10 @@
+---------------------------------------------------------------------------------------------------
+Version: 2.0.2
+Date: 2024-10-27
+
+  Changed:
+    - Correctly skip spamming non-nauvis. This time for real... hopefully.
+
 ---------------------------------------------------------------------------------------------------
 Version: 2.0.1
 Date: 2024-10-27
index 621ed4cb0b63a2e1a78320be7c6aeb429909dd99..39c81ff2fff6392b7fc335f87cb7ee95314b3e36 100644 (file)
@@ -1,8 +1,7 @@
 -- Iterate over every tile in the new chunk and spam with random resources, if empty and possible.
 script.on_event(defines.events.on_chunk_generated, function (event)
-    -- this mod is intended as an early game challenge. Therefore do nothing on non-nauvis.
-    if not event.surface.planet then return end
-    if not event.surface.planet.name ~= "nauvis" then return end
+    -- this mod is intended as an early game challenge. Therefore do nothing on any non-initial surface.
+    if not (event.surface.index == 1) then return end
 
     -- prevent one big continuous patch
     if (event.area.left_top.x/32)%10 == 5 or (event.area.left_top.y/32)%10 == 5 then
index 27ff1b9bec019800abe4ef3a4c0a86323468b722..82549e2849c31971271b3722994163664ff3e9b9 100644 (file)
--- a/info.json
+++ b/info.json
@@ -1,6 +1,6 @@
 {
     "name": "some-resourcespam",
-    "version": "2.0.1",
+    "version": "2.0.2",
     "title": "Some resource spam",
     "author": "someone1337",
     "homepage": "https://git.somenet.org/factorio/some-resourcespam.git",