Page 1 of 2

[MOD 0.12.19] PersonalRoboportFix (0.3.2)

Posted: Thu Aug 13, 2015 8:45 pm
by SHiRKiT
Mod-Info-Header
  • Name: PersonalRoboportFix
  • Version: 0.3.2
  • Factorio-Version: 0.12.19
  • Description: Removes the annoying behaviour of having the personal robots having priority over the network's construction robots.
  • License: WTF Public License Image
  • Release: 2015-12.01
  • Download-Url: Download
  • Website: https://github.com/Shirkit/PersonalRoboportFix
  • Dependencies: None.
  • Category: Helper, Fix
  • Tags: Robots, Construction Robots, Roboports
License
Long description
Pictures
Version history

Re: [0.12.3] PersonalRoboportFix - Auto disable inside network

Posted: Fri Aug 14, 2015 8:37 am
by Ralord89
Oh god finally. It was actually becoming a big pain constantly adding and removing the ports when leaving my base. thanks for this, this is a massive help

Re: [0.12] PersonalRoboportFix (0.2.0) - Disable inside network

Posted: Fri Aug 14, 2015 5:26 pm
by SHiRKiT
Version 0.2.0 released, fixed crash when removing armor and added support for multiple personal roboports. If everything goes right, I'll be able to easily support modded Roboports and Personal Roboports.

Re: [0.12] PersonalRoboportFix (0.2.0) - Disable inside network

Posted: Sun Aug 16, 2015 2:22 am
by Ralord89
I placed down a Roboport and got this error

Code: Select all

Error while running the event handler: __PersonalRoboportFix__/control.lua:77: attempt to index field '?' (a boolean value)

Re: [0.12] PersonalRoboportFix (0.2.0) - Disable inside network

Posted: Sun Aug 16, 2015 1:08 pm
by SirRichie
So what happens if I place more than (personal roboports) * 10 construction robots into my inventory?
You say that mod will fail. Does that mean the game will crash or does that mean the personal roboport will then be enabled?

I am asking, because I really like the idea of the mod, but usually I do bulk loading of construction robots (~ 30) into roboports.

Re: [0.12] PersonalRoboportFix (0.2.0) - Disable inside network

Posted: Sun Aug 16, 2015 3:02 pm
by SHiRKiT
Ralord89 wrote:I placed down a Roboport and got this error

Code: Select all

Error while running the event handler: __PersonalRoboportFix__/control.lua:77: attempt to index field '?' (a boolean value)
Sorry, this was likely caused due migration from 0.1.0 to 0.2.0 I released a fix for 0.2.1 for you, but next versions I'll have to be more careful when upgrading versions. Sorry
SirRichie wrote:So what happens if I place more than (personal roboports) * 10 construction robots into my inventory?
You say that mod will fail. Does that mean the game will crash or does that mean the personal roboport will then be enabled?

I am asking, because I really like the idea of the mod, but usually I do bulk loading of construction robots (~ 30) into roboports.
No, it won't crash, it just won't work correctly. The way I detect if the personal robots are out if there's less than ( 10 * personal roboport count ) in the player's inventory, if you have 5 personal roboports and you have 100 construction bots on your inventory, I'll never be able to detect anything, and your personal roboports will be always active.

Re: [MOD 0.12] PersonalRoboportFix (0.2.1) - Disable inside net

Posted: Mon Sep 07, 2015 1:47 pm
by sadris

Code: Select all

__PersonalRoboportFix__/control.lua:153: god-controller doesn't have an inventory with index(5)
Occurs when I activate god mode with Test Mode.

Re: [MOD 0.12] PersonalRoboportFix (0.2.1) - Disable inside net

Posted: Wed Sep 16, 2015 11:50 am
by SirRichie
PersonalRoboportFix crashes in multiplayer on line 95 (forgot to capture the error, sorry) when a player dies.

We were way before getting a modular amor, so noone had a roboport (but the mod was active). Whenever a player died, the game reported an error in PersonalRoboportFix and then shut down.

Re: [MOD 0.12] PersonalRoboportFix (0.2.1) - Disable inside net

Posted: Thu Sep 17, 2015 8:15 pm
by XyLe
This mod is really cool, i like it a lot. But actually sometimes i want my personal robots to have the first priority too, even when inside the network. I always felt like there should be a button to turn personal robots on and off, coz otherwise they just fly after a train somewhere and never come back :D

Also this mod says that you can't have more robots than your personal roboports can support. That problem would go away if you could simply have an "on/off" button. consider changing your mod that way please.

Re: [MOD 0.12] PersonalRoboportFix (0.2.1) - Disable inside net

Posted: Sat Sep 19, 2015 11:14 pm
by SHiRKiT
New version! 0.3.0 is out now!

Code: Select all

Fixed crash when using the Test Mode mod in God Mode.
Fixed crash in multiplayer when a player dies.
Added support for modded robots, modded roboports and modded personal roboports.
Fixed behaviour that would not allow palyers to have more than the limit of robots in their inventories.
sadris wrote:

Code: Select all

__PersonalRoboportFix__/control.lua:153: god-controller doesn't have an inventory with index(5)
Occurs when I activate god mode with Test Mode.
Thanks for the report. Should be fixed
SirRichie wrote:PersonalRoboportFix crashes in multiplayer on line 95 (forgot to capture the error, sorry) when a player dies.

We were way before getting a modular amor, so noone had a roboport (but the mod was active). Whenever a player died, the game reported an error in PersonalRoboportFix and then shut down.
Thanks for the report. Should be fixed by fixing the previous bug!
XyLe wrote:This mod is really cool, i like it a lot. But actually sometimes i want my personal robots to have the first priority too, even when inside the network. I always felt like there should be a button to turn personal robots on and off, coz otherwise they just fly after a train somewhere and never come back :D

Also this mod says that you can't have more robots than your personal roboports can support. That problem would go away if you could simply have an "on/off" button. consider changing your mod that way please.
1. I'm still considering in putting a on/off button. I actually wanted it to be a hotkey, I'll study this in the future. But for now, it should be stable.
2. The limit problem is now fixed!

Re: [MOD 0.12.5] PersonalRoboportFix (0.3.0)

Posted: Mon Oct 19, 2015 8:30 am
by MakiabelMFE
Hey it seems that the mod is broken in 0.12.11, from what I understand just have to change game. to script. however that didn't fully fixed it since it keeps calling an error in line 15 with the on_load event calling game.players
That's as far as I got, don't really know what to do past that so I'll just leave it reported here :D.

Re: [MOD 0.12.5] PersonalRoboportFix (0.3.0)

Posted: Mon Oct 19, 2015 10:59 am
by Steejo
Yeah, on_load no longer gives access to game. so it's needing changing.

Re: [MOD 0.12.16] PersonalRoboportFix (0.3.1)

Posted: Sun Nov 08, 2015 12:42 pm
by SHiRKiT
Opps guys, sorry for the delay. I haven't play Factorio in ages =] It's fixed now, thanks for the report, specially antisocialian for creating the issue at github who sent me an email =]

As a note, I have set this thread to email me whenever something is posted here, so I never miss a reply. Sorry for leaving it unupdated for so long, I imagine some of you prolly figured out the fix by removing on_load altogether.

0.3.1 is released with a fix

Re: [MOD 0.12.16] PersonalRoboportFix (0.3.1)

Posted: Sun Nov 08, 2015 12:56 pm
by antisocialian
:D I've noticed that the thread subscriptions don't last forever on this forum. I'm not sure if it's something the admins can change or not. I've seen other forums only allow thread subscriptions for 2 weeks.

Thanx for the update :)

Re: [MOD 0.12.16] PersonalRoboportFix (0.3.1)

Posted: Tue Dec 01, 2015 6:30 am
by Segundo
The PersonalRoboportFix (0.3.1) does not work anymore in Factorio version 0.12.18 and 0.12.19 in multiplayer mode.

Factorio gives an "Player:Connected" error with the PersonalRoboportFix mod (0.3.1) and quits back to the main menu when loading an map created in multiplayer.

One loads the saved multiplayer map then others can connect to it, it gives an error about the not (yet) connected players.

Can the mod be updated to work with the latest versions of Factorio?

Thanks for this handy mod.

From the change log of Factorio 0.12.18:

Scripting
Reading or writing LuaPlayer::character will now fail if the LuaPlayer isn't connected (see LuaPlayer::connected).
Lua API documentation is included in release packages (directory doc-html)

Re: [MOD 0.12.16] PersonalRoboportFix (0.3.1)

Posted: Tue Dec 01, 2015 1:20 pm
by SHiRKiT
Segundo wrote:The PersonalRoboportFix (0.3.1) does not work anymore in Factorio version 0.12.18 and 0.12.19 in multiplayer mode.

Factorio gives an "Player:Connected" error with the PersonalRoboportFix mod (0.3.1) and quits back to the main menu when loading an map created in multiplayer.

One loads the saved multiplayer map then others can connect to it, it gives an error about the not (yet) connected players.

Can the mod be updated to work with the latest versions of Factorio?

Thanks for this handy mod.

From the change log of Factorio 0.12.18:

Scripting
Reading or writing LuaPlayer::character will now fail if the LuaPlayer isn't connected (see LuaPlayer::connected).
Lua API documentation is included in release packages (directory doc-html)
Thank you very much for the report! It was so specific that the fix was trivial. The new 0.3.2 is now released in Github. Thanks Segundo!

Re: [MOD 0.12.19] PersonalRoboportFix (0.3.2)

Posted: Thu Dec 17, 2015 7:46 pm
by antisocialian
I'm having a problem with the mod. I am currently running factorio version 0.12.20 and version 0.3.2 of your mod and I am on a save that at one time had been a multiplayer(2 players) and now it's just me.

When I put on my suit of armour that has roboports in it, or when I add roboports to a suit of armour I'm wearing, I get this:
Image

Clicking OK then sends me directly back to the main menu. I had been wearing the armour just a few minutes prior to this(within the same game session, still all solo) so I'm confused as to whats happening, tho I have a limited understanding of most mod's inner workings.

Edit: I am currently within me logistics network, but when I'm outside it there are no issues with putting on the armour.
Edit2: I have tried using the command

Code: Select all

/c game.remove_offline_players()
and that did something, but then this mod and another(TheFATController, which is also having issues when ever I open the train listing) both gave errors(the error for this mod being the same). Is there another way to make the game be a singleplayer only game? or am I screwed until I start a new one?

Re: [MOD 0.12.19] PersonalRoboportFix (0.3.2)

Posted: Thu Dec 24, 2015 1:28 am
by Urbs
Anti,

what mod is that showing all that data at the top left of your screen? Some kind of res monitor?

Re: [MOD 0.12.19] PersonalRoboportFix (0.3.2)

Posted: Mon Dec 28, 2015 12:58 am
by SHiRKiT
Sorry for the delay, it's holiday times and I've been doing nothing but relaxing with family and friends this week.

antisocialian, I can't trace down your issue to what's causing this bug, could you kindly share your Mod folder and your savegame so I can fix this?

I don't understand why would need to remove offline players since I do a check

Code: Select all

if player.connected and player.controller_type == defines.controllers.character then
So it shouldn't be checking for offline players and shouldn't try to peek on unavailable information on line 82. Only if something went wrong in saving the data, so only by checking the savegame I can try to fix.

Re: [MOD 0.12.19] PersonalRoboportFix (0.3.2)

Posted: Sat Jan 09, 2016 3:28 pm
by SHiRKiT
I really needed that savegame+mods_folder to track down the issue that caused this =\