Bugs and problems

New energy types, decorations, electric train, new types of belts and inserters, bigger inventory and many more stuff.

Moderators: McGuten, odin_spain

Post Reply
leeknivek
Inserter
Inserter
Posts: 30
Joined: Wed Dec 31, 2014 7:55 pm
Contact:

Re: Bugs and problems

Post by leeknivek »

Oh, I see now - downloading it as I type this. I guess I should have read above beforehand... Thanks!

EDIT:

Having an issue now using Electric trains, logistic chest carts, accumulator wagon, etc.
Error while running event handler: __5Dim_Trains__/control.lua:579:LuaBootstrap Doesn't Contain Key Surfaces
Trying to place these on electric rails and normal rails, getting this error every time.

redmoon
Burner Inserter
Burner Inserter
Posts: 9
Joined: Tue Jun 16, 2015 5:59 am
Contact:

Re: Bugs and problems

Post by redmoon »

leeknivek wrote:Oh, I see now - downloading it as I type this. I guess I should have read above beforehand... Thanks!

EDIT:

Having an issue now using Electric trains, logistic chest carts, accumulator wagon, etc.
Error while running event handler: __5Dim_Trains__/control.lua:579:LuaBootstrap Doesn't Contain Key Surfaces
Trying to place these on electric rails and normal rails, getting this error every time.
I found an error in this line
https://forums.factorio.com/forum/vie ... 10#p115232

CovertJaguar
Burner Inserter
Burner Inserter
Posts: 6
Joined: Sun Dec 21, 2014 1:53 pm
Contact:

Re: Bugs and problems

Post by CovertJaguar »

A few things.

First off the curved water rails (both variants) can't actually be placed on water. And the electric curved rails have a different collision box size than the vanilla rails.

Also, the Logistic Passive Provider Wagon has issues with items vanishing some times. A bunch of items will be loaded into the Wagon but only about half show up in the GUI, the others are just gone. I haven't been able to determine exactly when it does and doesn't happen, but more inserters seems to make it more common. I haven't tested the other Wagons. I suppose it might have something to do with setting slot filters.

EDIT: It seems to only happen for inserters placed in the center of the wagon. I assume that they are loading the logistics crate entity instead of the wagon entity.

CovertJaguar
Burner Inserter
Burner Inserter
Posts: 6
Joined: Sun Dec 21, 2014 1:53 pm
Contact:

Re: Bugs and problems

Post by CovertJaguar »

Upon further testing I have also determined that the copyInventory() function is causing massive lag spikes whenever a logistics wagon inventory is modified.

I did what I could to improve the function:

Code: Select all

function copyInventory(copyFrom, copyTo, filter)
	local activeFilter = filter
	if filter == nil or filter == "" then
		filter = "*"
	end
	
	if copyFrom ~= nil and copyTo ~= nil then
		local fromContents = copyFrom.get_contents()
		local toContents = copyTo.get_contents()
		local action = fromContents
		for name,count in pairs(toContents) do
			if action[name] == nil then
				action[name] = -count
			else
				action[name] = action[name] - count
			end
		end
		for name,diff in pairs(action) do
			if diff ~= 0 then
				local filterType = getItemTypeFromName(name)
				if filterType == nil or filterType == "item" then
					filterType = getEntityTypeFromName(name)
				end
				if filter == name or filter == filterType or filter == "*" then
					--debugLog("#################itemName: " .. name .. " diff: " .. diff)
					if diff > 0 then
						copyTo.insert({name=name,count=diff})
					elseif diff < 0 then
						copyTo.remove({name=name,count=0-diff})
					end
				end
			end
		end
	end
	
end
I'm sure some one more intimate with LUA could do even better.

McGuten
Filter Inserter
Filter Inserter
Posts: 310
Joined: Tue Jun 24, 2014 3:06 pm
Contact:

Re: Bugs and problems

Post by McGuten »

sorry guys for this inactivity, i make a new version for fix some bugs i upload it in a few hours...

big sorry :(
Image

HellNeko
Burner Inserter
Burner Inserter
Posts: 7
Joined: Sun Oct 18, 2015 9:38 pm
Contact:

Re: Bugs and problems

Post by HellNeko »

The problem i am having is that the accumulator wont change up, the power rail is not providing power to the electric engine or any of the logistics wagon and laser turret wagon and the curve rail for water (both of them) are not placing on the water i am running factorio 12.18 and using 5Dim's core 2.0.0 and Trains 2.0.1

McGuten
Filter Inserter
Filter Inserter
Posts: 310
Joined: Tue Jun 24, 2014 3:06 pm
Contact:

Re: Bugs and problems

Post by McGuten »

HellNeko wrote:The problem i am having is that the accumulator wont change up, the power rail is not providing power to the electric engine or any of the logistics wagon and laser turret wagon and the curve rail for water (both of them) are not placing on the water i am running factorio 12.18 and using 5Dim's core 2.0.0 and Trains 2.0.1
You use electric rails?
Image

RodneyMckay
Burner Inserter
Burner Inserter
Posts: 7
Joined: Sun Jul 26, 2015 9:36 am
Contact:

Re: Bugs and problems

Post by RodneyMckay »

Hi, I have a similar Problem: First I got the Error. "LuaBootstrap doesn't contain key surface", so I used the control.lua from Redmoon. Now I could place the electric Locomotve, but it doesn't get any power on power rails. If it is near to a power Pole, it connect's to it and get't power. Any Ideas Why?

Factorio 12.19
5dim's core 2.0.0
5dim's trains 2.0.1 with redmoon's control.lua
RSO Mod 1.4.6
Yuoki_0.2.37
no-hand-crafting_0.12.2
BetterPoles_1.0.0

first I thought it could be the better electric Pole mod, but it happens also without that mod.

HellNeko
Burner Inserter
Burner Inserter
Posts: 7
Joined: Sun Oct 18, 2015 9:38 pm
Contact:

Re: Bugs and problems

Post by HellNeko »

McGuten wrote:
HellNeko wrote:The problem i am having is that the accumulator wont change up, the power rail is not providing power to the electric engine or any of the logistics wagon and laser turret wagon and the curve rail for water (both of them) are not placing on the water i am running factorio 12.18 and using 5Dim's core 2.0.0 and Trains 2.0.1
You use electric rails?
yes i used the electric rails i had a testing zone in my base but the engine didn't move at all unless i put a power pole near it and i did tried just put one near the track on the end of the line

RodneyMckay
Burner Inserter
Burner Inserter
Posts: 7
Joined: Sun Jul 26, 2015 9:36 am
Contact:

Re: Bugs and problems

Post by RodneyMckay »

So I found the bug in the bug: I've build the track diagonal, and it connected to the big power pole and some Parts of the Track got powered up! I have absulute no Idea why this happened, but it happened. Soon I will check if the battle Waggon will get Power.

It seem's, that the power rails do not connect to each other properly.

And as I removed the big Power Pole the whole Track lost Power.

SableDrake
Manual Inserter
Manual Inserter
Posts: 1
Joined: Fri Dec 04, 2015 9:07 pm
Contact:

Re: Bugs and problems

Post by SableDrake »

In trains 2.0.1 the no loader for rail error described before was fixed for the "normal" prototypes, but not for the "ores" ones.

Klypto
Manual Inserter
Manual Inserter
Posts: 3
Joined: Tue Dec 15, 2015 4:55 pm
Contact:

Re: Bugs and problems

Post by Klypto »

RodneyMckay wrote:So I found the bug in the bug: I've build the track diagonal, and it connected to the big power pole and some Parts of the Track got powered up! I have absulute no Idea why this happened, but it happened. Soon I will check if the battle Waggon will get Power.

It seem's, that the power rails do not connect to each other properly.

And as I removed the big Power Pole the whole Track lost Power.
If you are using RedMoon's Control file, on line 132 and 164 the code reads as

Code: Select all

if event.created_entity.type == "rail" then
it should be

Code: Select all

if event.created_entity.type == "straight-rail" or event.created_entity.type == "curved-rail" then
This only fixes placing new rail. You would have to write a new function to find and fix existing rail.



Since I got curious/annoyed enough to read the file now but have 0 experience modding factorio or it's mechanics, I want to try and understand why the electric rail places invisible 1x1 power poles instead of invisible 1x1 substations.

Wouldn't invisible substations make for better visuals? In theory there would be no odd looking power line from the train to the track. Or is there a way to hide the power lines?

RodneyMckay
Burner Inserter
Burner Inserter
Posts: 7
Joined: Sun Jul 26, 2015 9:36 am
Contact:

Re: Bugs and problems

Post by RodneyMckay »

Thanks to Redmoon and Klypto! Now the Rails do act as Powerrails. Either I will write a function to replace all layed Rails, or I will replace them manually with help of my Robots.

Aes Sedai
Burner Inserter
Burner Inserter
Posts: 16
Joined: Fri Jan 08, 2016 12:37 am
Contact:

Re: Bugs and problems

Post by Aes Sedai »

Ran into a crash (0.12.x version of 5dim, Factorio version 0.12.20 64bit, on Windows) when placing a clip of armor piercing ammo into a gun turret carriage. Crash also occurs using regular ammo. This was the error:

Error while running the event handler: __5dim_trains__/control.lua:1129:LuaBootstrap doesn't contain key item_prototypes.

I also ran into another bug related to the laser carriages. When I attached them to a locomotive and the train advanced forward the laser turret was not connected to the carriage base. The locomotive + carriages would move, but the laser turret itself would still be where I initially placed the carriage.

Image

Modlist from log:

Code: Select all

0.697 Loading mod core 0.0.0 (data.lua)
0.701 Loading mod base 0.12.20 (data.lua)
0.756 Loading mod 5dim_core 2.0.0 (data.lua)
0.795 Loading mod advanced-logistics-system 0.2.10 (data.lua)
0.834 Loading mod Explosive Termites 1.1.7 (data.lua)
0.866 Loading mod KS_Power 0.1.1 (data.lua)
0.899 Loading mod Orbital Ion Cannon 1.0.5 (data.lua)
0.936 Loading mod radar-two 0.2.0 (data.lua)
0.971 Loading mod RailTanker 1.1.2 (data.lua)
1.005 Loading mod research-queue 1.2.2 (data.lua)
1.049 Loading mod TheFatController 0.3.18 (data.lua)
1.089 Loading mod upgrade-planner 1.1.7 (data.lua)
1.124 Loading mod UraniumPower 0.6.3 (data.lua)
1.171 Loading mod Warehousing 0.0.5 (data.lua)
1.210 Loading mod 5dim_automatization 2.0.0 (data.lua)
1.262 Loading mod 5dim_decoration 2.0.0 (data.lua)
1.311 Loading mod 5dim_energy 2.0.0 (data.lua)
1.365 Loading mod 5dim_logistic 2.0.0 (data.lua)
1.422 Loading mod 5dim_mining 2.0.0 (data.lua)
1.472 Loading mod 5dim_module 2.0.0 (data.lua)
1.532 Loading mod 5dim_resources 2.0.0 (data.lua)
1.583 Loading mod 5dim_trains 2.0.1 (data.lua)
1.644 Loading mod 5dim_transport 2.0.0 (data.lua)
1.723 Loading mod 5dim_vehicle 2.0.0 (data.lua)
1.778 Loading mod FARL 0.4.41 (data.lua)
1.841 Loading mod rso-mod 1.4.7 (data-updates.lua)
1.912 Loading mod FARL 0.4.41 (data-updates.lua)
1.966 Loading mod advanced-logistics-system 0.2.10 (data-final-fixes.lua)
2.029 Loading mod research-queue 1.2.2 (data-final-fixes.lua)
2.116 Loading mod WaiTex 0.9.0 (data-final-fixes.lua)

Elusive
Manual Inserter
Manual Inserter
Posts: 3
Joined: Sun Sep 27, 2015 5:20 pm
Contact:

Re: Bugs and problems

Post by Elusive »

Mods:

test-mode_0.12.11.zip (used to reproduce issue with no other mods)
5_dim_trains_2.0.1
5dim_core_2.0.0

When placing ore in an active provider cargo wagon:

Error while running the event handler: __5dim_trains__/control.lua:1129: LuaBootstrap doesn't contain key item_prototypes.

Changing "script" to "game" in control.lua seems to fix it in 12.20 for these two helper methods, but I don't know much about Factorio's API.

powerafro
Burner Inserter
Burner Inserter
Posts: 12
Joined: Thu Mar 07, 2013 6:53 pm
Contact:

Re: Bugs and problems

Post by powerafro »

I had the same problem as Elusive.

Factorio version: 12.22
5dim_trains_2.0.1

When i place some raw wood into the requester cargo wagon, The same error:


Error while running the event handler: __5dim_trains__/control.lua:1129: LuaBootstrap doesn't contain key item_prototypes.

greetings powerafro

Scorpio_King
Burner Inserter
Burner Inserter
Posts: 9
Joined: Wed Jan 20, 2016 2:59 pm
Contact:

Re: Bugs and problems

Post by Scorpio_King »

If 2 trains pass each other with accumulators and one of them have power and the other don't, the one that does not have power will drain the one who does. Makes it useless if you have more than one towards same destination.

5dim_core_2.0.0
5dim_trains_2.0.1

Factorio 0.12.20 [x64]

McGuten
Filter Inserter
Filter Inserter
Posts: 310
Joined: Tue Jun 24, 2014 3:06 pm
Contact:

Re: Bugs and problems

Post by McGuten »

It will be fixed in next release ^^
Image

fregate84
Fast Inserter
Fast Inserter
Posts: 233
Joined: Sun Jun 22, 2014 10:56 am
Contact:

Re: Bugs and problems

Post by fregate84 »

1/ I have the same problem

Code: Select all

Error while running the event handler: __5dim_trains__/control.lua:1129: LuaBootstrap doesn't contain key item_prototypes.
and

Code: Select all

__5dim_trains__/control.lua:1136: LuaBootstrap doesn't contain key entity_prototypes.

and Changing "script" to "game" in control.lua seems to fix it in my case too.

2/ An other bug : when a delete a gun-wagon, the gun is not delete on game.

3/ I don't understand how cargo-wagon-accumulator work. whe didn't see the charge and it's is not working xith eletric locomotive.

McGuten
Filter Inserter
Filter Inserter
Posts: 310
Joined: Tue Jun 24, 2014 3:06 pm
Contact:

Re: Bugs and problems

Post by McGuten »

fregate84 wrote:1/ I have the same problem

Code: Select all

Error while running the event handler: __5dim_trains__/control.lua:1129: LuaBootstrap doesn't contain key item_prototypes.
and

Code: Select all

__5dim_trains__/control.lua:1136: LuaBootstrap doesn't contain key entity_prototypes.

and Changing "script" to "game" in control.lua seems to fix it in my case too.
Yes, i fixed this buf yesterday and today i will upload the new modules version
fregate84 wrote:2/ An other bug : when a delete a gun-wagon, the gun is not delete on game.
Put the war-wagon back and try to take it again
fregate84 wrote:3/ I don't understand how cargo-wagon-accumulator work. whe didn't see the charge and it's is not working xith eletric locomotive.
I will see it too ^^
Image

Post Reply

Return to “5dim's mod”