Page 7 of 20

Re: [MOD 0.16] Miniloader

Posted: Fri Feb 16, 2018 12:30 pm
by DRY411S
On your next release, would you mind either moving or duplicating entries for your loaders into the entity-name section of your locale please?

My Recycling Machines Mod checks every item prototype for certain properties. Your railloader and unloader have the 'place_result' property which suggests that there is an entity prototype associated and that the locale should be in the entity-name section. As a result, my Recycling Machine gives an ugly error display when i hover over your entities in the Recycling Machines menus.
railloader.png
railloader.png (225.09 KiB) Viewed 6351 times
To put this into context, your mod is one of very, very few examples of where this happens. Across all of Bob's Mods for example, it happens only once, for a single entity, and I'm about to make thew same request to him :)

Re: [MOD 0.16] Miniloader

Posted: Fri Feb 16, 2018 7:41 pm
by Therax
DRY411S wrote:On your next release, would you mind either moving or duplicating entries for your loaders into the entity-name section of your locale please?

My Recycling Machines Mod checks every item prototype for certain properties. Your railloader and unloader have the 'place_result' property which suggests that there is an entity prototype associated and that the locale should be in the entity-name section. As a result, my Recycling Machine gives an ugly error display when i hover over your entities in the Recycling Machines menus.
railloader.png
To put this into context, your mod is one of very, very few examples of where this happens. Across all of Bob's Mods for example, it happens only once, for a single entity, and I'm about to make thew same request to him :)
I think you meant to post this in the Bulk Rail Loaders thread, but I'll answer here anyway:

At a guess, having not looked at your code, I think your mod needs to look at the value of the place_result property, not just for presence or absence. This is what the Factorio core does, and not every entity has the same item-name as entity-name. For example, in vanilla there is a "rail" item, but no "rail" entity, only "straight-rail" and "curved-rail". I have the below values in my mod, which is how the recipe display in your screenshot gets the correct name.

In prototypes/item/railloader.lua:

Code: Select all

  {
    type = "item",
    name = "railloader",
    ...
    place_result = "railloader-placement-proxy",
In locale/en/railloader.cfg:

Code: Select all

[entity-name]
railloader-placement-proxy=Bulk rail loader

Re: [MOD 0.16] Miniloader

Posted: Fri Feb 16, 2018 7:53 pm
by DRY411S
That looks as though it will work thanks. This is the only mod so far where the his value isn't the same as the prototype name.

Re: [MOD 0.16] Miniloader

Posted: Fri Feb 16, 2018 11:21 pm
by Therax
DRY411S wrote:That looks as though it will work thanks. This is the only mod so far where the his value isn't the same as the prototype name.
I guess I'm weirder than I thought. :) Bulk Rail Loaders has to do some funky magic to enable building directly over the top of existing rails.

Re: [MOD 0.16] Miniloader

Posted: Sun Feb 18, 2018 7:38 am
by DRY411S
Therax wrote:
DRY411S wrote:That looks as though it will work thanks. This is the only mod so far where the his value isn't the same as the prototype name.
I guess I'm weirder than I thought. :) Bulk Rail Loaders has to do some funky magic to enable building directly over the top of existing rails.
Confirmed that this was a bug in my new code. All working fine now thanks.

Re: [MOD 0.16] Miniloader

Posted: Sun Feb 18, 2018 7:44 am
by AreYouScared
Seems to not like joining a paused with mini loaders enabled. When joining a modded multiplayer game with this mod i get the following error
mod-miniloader was registered for the following events when the map was saved but has not re-registered them as a result of loading: on_selected_entity_changed (ID 52)
MultiplayerManager failed: "" + multiplayer.script-event-mismatch + "" + "mod-miniloader"
This was also sent to Rseding, as it might not be caused by the mod
Update:
Rseding: It means it isn't written correctly and is doing events wrong.

Re: [MOD 0.16] Miniloader

Posted: Sun Feb 18, 2018 5:48 pm
by Therax
cjmwid wrote:mod-miniloader was registered for the following events when the map was saved but has not re-registered them as a result of loading: on_selected_entity_changed (ID 52)
MultiplayerManager failed: "" + multiplayer.script-event-mismatch + "" + "mod-miniloader"
Definitely a problem in the mod, and I have a good idea how to fix it.

Re: [MOD 0.16] Miniloader

Posted: Sun Feb 18, 2018 6:52 pm
by AreYouScared
Thanks my solution to joining was to just restart the server I'm just happy to doesn't save the paused state

Re: [MOD 0.16] Miniloader

Posted: Fri Feb 23, 2018 2:33 am
by eradicator
Therax wrote:
DRY411S wrote:That looks as though it will work thanks. This is the only mod so far where the his value isn't the same as the prototype name.
I guess I'm weirder than I thought. :) Bulk Rail Loaders has to do some funky magic to enable building directly over the top of existing rails.
Not really. I've used proxy placers for some really fancy magic haxery in the past :P
-----------------------
Just tried miniloaders for the first time and the render layer order looks wrong with chests. Maybe you could try adding render_layer = "object" to the prototype?
minilayer.jpg
minilayer.jpg (54.3 KiB) Viewed 6286 times
minilayer2.jpg
minilayer2.jpg (77.98 KiB) Viewed 6285 times
(Also i was a bit sad that the secret hidden inserters don't give a magical direct chest-2-chest loading ability. But happy again after discovering the one-tile lane balancing.)

Re: [MOD 0.16] Miniloader

Posted: Sat Feb 24, 2018 4:04 am
by Therax
eradicator wrote:Not really. I've used proxy placers for some really fancy magic haxery in the past :P
That makes two of us?
eradicator wrote:Just tried miniloaders for the first time and the render layer order looks wrong with chests. Maybe you could try adding render_layer = "object" to the prototype?
Sadly, render_layer is ignored for inserter-type entities:

Code: Select all

0.863 Warning PrototypeLoader.cpp:132: Value ROOT.inserter.miniloader-inserter.render_layer was not used.
For Bulk Rail Loaders I got around this by having a basic-entity with a custom render_layer, so the loader would render on top of cargo wagons, but for miniloaders that would obscure the circuit connector.
eradicator wrote:(Also i was a bit sad that the secret hidden inserters don't give a magical direct chest-2-chest loading ability. But happy again after discovering the one-tile lane balancing.)
The one-tile lane balancing is an advertised feature in the Long Description of OP, and on the mod portal. :)
therax wrote:put them in your bus as compact priority splitters, or single-belt lane rebalancers.

Re: [MOD 0.16] Miniloader

Posted: Sat Feb 24, 2018 5:13 pm
by eradicator
Oh. I assumed you were already using an extra entity for the graphics. So i guess the graphics is the inserter base?
Have you tried "lower_object" (or any of the other layers)? That might work with circuit connectors. Or...you could proxy out the circuit connector as such to a new entity (zero range power pole?). /haxery

I'm just really sensitive to that sort of graphics bug :P

Re: [MOD 0.16] Miniloader

Posted: Thu Mar 01, 2018 1:08 pm
by SelfDestructor
Hi! When pasting a blueprint without any miniloaders in Factorio 0.16.27 with Miniloader version 1.5.11 I get this error:

Code: Select all

Error while running event Bluebuild::on_tick (ID 0)
Error while running event miniloader::on_put_item (ID 9)
__miniloader__/lualib/util.lua:65: invalid direction passed to rotate_box
stack traceback:
	__Bluebuild__/control.lua:131: in function 'bluebuild'
	__Bluebuild__/control.lua:50: in function 'bluecheck'
	__Bluebuild__/control.lua:35: in function 'playerloop'
	__Bluebuild__/control.lua:269: in function <__Bluebuild__/control.lua:268>
If I paste a blueprint with a miniloader in it, I get no errors and the blueprint sets down fine.

Re: [MOD 0.16] Miniloader

Posted: Thu Mar 01, 2018 4:39 pm
by Therax
SelfDestructor wrote:Hi! When pasting a blueprint without any miniloaders in Factorio 0.16.27 with Miniloader version 1.5.11 I get this error:

Code: Select all

Error while running event Bluebuild::on_tick (ID 0)
Error while running event miniloader::on_put_item (ID 9)
__miniloader__/lualib/util.lua:65: invalid direction passed to rotate_box
stack traceback:
	__Bluebuild__/control.lua:131: in function 'bluebuild'
	__Bluebuild__/control.lua:50: in function 'bluecheck'
	__Bluebuild__/control.lua:35: in function 'playerloop'
	__Bluebuild__/control.lua:269: in function <__Bluebuild__/control.lua:268>
If I paste a blueprint with a miniloader in it, I get no errors and the blueprint sets down fine.
This is a bug in Bluebuild. Until it's fixed, you can work around it by disabling Bluebuild via the in-game hotkeys before placing a blueprint or walking near to blueprint ghosts. Basically anytime Bluebuild tries to build something and you have a blueprint in your cursor, you will see this error. You can reactivate it after clearing the blueprint from your cursor.

Re: [MOD 0.16] Miniloader

Posted: Fri Mar 02, 2018 9:34 am
by AreYouScared
Currently getting this error, Unable to join the server anymore because of it.

Image

Note: Same issue as posted before by me, This time was caused by a client(Only one logged into the server) losing packets and getting disconnected from it.

Again solution was to restart server.
103.344 Verbose Scenario.cpp:260: Map setup finished: 2.153879 seconds.
103.367 Error ClientMultiplayerManager.cpp:1096: mod-miniloader was registered for the following events when the map was saved but has not re-registered them as a result of loading: on_selected_entity_changed (ID 52)
103.367 Error ClientMultiplayerManager.cpp:95: MultiplayerManager failed: "" + multiplayer.script-event-mismatch + "
" + "
mod-miniloader"
103.367 Info ClientMultiplayerManager.cpp:573: MapTick(22316385) changing state from(ConnectedLoadingMap) to(Failed)
105.648 Info ClientMultiplayerManager.cpp:188: Quitting multiplayer connection.

Re: [MOD 0.16] Miniloader

Posted: Fri Mar 02, 2018 2:15 pm
by SelfDestructor
Therax wrote:This is a bug in Bluebuild. Until it's fixed, you can work around it by disabling Bluebuild via the in-game hotkeys before placing a blueprint or walking near to blueprint ghosts. Basically anytime Bluebuild tries to build something and you have a blueprint in your cursor, you will see this error. You can reactivate it after clearing the blueprint from your cursor.
Thank you! I kept reading "blueprint" in my head so it didn't even hit me that it was another mod.

Re: [MOD 0.16] Miniloader

Posted: Fri Mar 02, 2018 2:19 pm
by Lindetwin
I use version 1.5.11. Everytime i make a blueprint with the mod installed it crashes.
Photo of the crash in the attachements.

Re: [MOD 0.16] Miniloader

Posted: Fri Mar 02, 2018 6:11 pm
by Therax
cjmwid wrote:Currently getting this error, Unable to join the server anymore because of it.

Note: Same issue as posted before by me, This time was caused by a client(Only one logged into the server) losing packets and getting disconnected from it.

Again solution was to restart server.
What version of miniloader are you running? I believe this should have been fixed in 1.5.11.
Lindetwin wrote:I use version 1.5.11. Everytime i make a blueprint with the mod installed it crashes.
You are running an outdated experimental of 0.16.x. Please update to the latest.

Re: [MOD 0.16] Miniloader

Posted: Fri Mar 02, 2018 7:34 pm
by Lindetwin
Thank you for responing so fast, i really appriciate it. i will now look if this works.

Re: [MOD 0.16] Miniloader

Posted: Fri Mar 02, 2018 7:35 pm
by Lindetwin
It worked, again thanks for the mod and your help.

Re: [MOD 0.16] Miniloader

Posted: Sun Mar 04, 2018 6:13 am
by AreYouScared
Therax wrote:
cjmwid wrote:Currently getting this error, Unable to join the server anymore because of it.

Note: Same issue as posted before by me, This time was caused by a client(Only one logged into the server) losing packets and getting disconnected from it.

Again solution was to restart server.
What version of miniloader are you running? I believe this should have been fixed in 1.5.11.

Version 1.5.11 we are running.


Just ran into another issue,
168224.575 Error MainLoop.cpp:1031: Exception at tick 27915619: Error while running event miniloader::on_tick (ID 0)
LuaEntity API call when LuaEntity was invalid.
stack traceback:
__miniloader__/circuit.lua:9: in function 'sync_filters'
__miniloader__/gui.lua:16: in function 'handler'
__miniloader__/lualib/ontick.lua:18: in function 'handler'
__miniloader__/lualib/event.lua:16: in function <__miniloader__/lualib/event.lua:8>
168224.575 Error ServerMultiplayerManager.cpp:96: MultiplayerManager failed: "Error while running event miniloader::on_tick (ID 0)
LuaEntity API call when LuaEntity was invalid.
stack traceback:
__miniloader__/circuit.lua:9: in function 'sync_filters'
__miniloader__/gui.lua:16: in function 'handler'
__miniloader__/lualib/ontick.lua:18: in function 'handler'
__miniloader__/lualib/event.lua:16: in function <__miniloader__/lualib/event.lua:8>"
168224.575 Info ServerMultiplayerManager.cpp:698: mapTick(27915619) changing state from(InGame) to(Failed)
Two players on multiplayer, One has the GUI open, the other mines the loader, causes the server to crash