-- This file can be copied into a mod then modified to add compatibility for the Squeak Through mod. -- This is only necessary if reducing entity collision boxes is causing problems. -- Create squeak_through_exclusions table if it has not already been created by another mod. if not squeak_through_exclusions then squeak_through_exclusions = {} end -- Specify which prototypes who's collision box should not be altered. squeak_through_exclusions["YourModName"] = { -- Individual prototypes names to not alter. excluded_prototype_names = { -- e.g "small-pump", -- "storage-tank" }, -- Types of prototypes to not alter (affects prototypes from all mods). excluded_prototype_types = { -- e.g "pipe", -- "tree" } } --[[ Setup Instructions 1. Copy and rename this file then add a require clause to your data.lua to include it. e.g require "squeak-through-compatibility" 2. Replace "YourModName" below with the name of your mod (from info.json). 3. List any names of entity prototypes to exclude from alteration in the excluded_prototype_names section (string array). 4. List any types of entity prototypes to exclude from alteration in the excluded_prototype_types section (string array). These apply to all entities of that type from all mods so ideally would only be used when you require a vanilla collision box for all entities of a specific type e.g "pump". 5. To test that this code is being run you can uncomment the line at the very bottom (you should see an error on startup with your exclusions in it). That's it. ]] -- FYI: The squeak_through_exclusions table will be parsed in Squeak Through when it runs (after all mods data.lua and data-updates.lua have executed). -- It is visible to other mods because all data-related scripts are run in a shared lua interpreter. https://wiki.factorio.com/index.php?title=Lua/Data_Lifecycle -- Remote interfaces are not available at this point as remote is undefined. -- -- The reason for specifying the mod name to allow any compatibility stuff defined in Squeak Through to be overridden by other mods whenever they are updated. -- Uncomment the line below to check that this is being run - you should see an error pop up when the game loads containing these exclusions. -- error("squeak_through_exclusions:" .. serpent.block(squeak_through_exclusions) )