[Kovarex] [0.16.4] missing train auto/manual switch ...

Things that has been reported already before.
Loewchen
Global Moderator
Global Moderator
Posts: 9290
Joined: Wed Jan 07, 2015 5:53 pm
Contact:

Re: [0.16.4] missing train auto/manual switch ...

Post by Loewchen »

This save has been modded with a "save-file mod", if you can produce this issue with a not modified save, let us know.
mophydeen
Filter Inserter
Filter Inserter
Posts: 529
Joined: Sun Nov 22, 2015 5:02 pm
Contact:

Re: [0.16.4] missing train auto/manual switch ...

Post by mophydeen »

in sl-extended there is a command:

Code: Select all

/inv <-100,100> - Decrease,increase character inventory bonus.
when the bonus is > 0 this bug happens.
/inv 20 > bonus 200 : now you see the bug
/inv -20 > bonus 0 : bug is gone ...


I use the below code. It worked fine in 0.15+

Code: Select all

commands.add_command("inv", " <" .. -INVENTORY_ROWS_MAX .. "," .. INVENTORY_ROWS_MAX .. "> - Decrease,increase inventory with 10 slots.", function(param)
	characterInventory(game.players[param.player_index], param.parameter)
end)
function characterInventory(player, amountOfBonusLinesString)
  	if amountOfBonusLinesString and tonumber(amountOfBonusLinesString) and tonumber(amountOfBonusLinesString) >= -INVENTORY_ROWS_MAX and tonumber(amountOfBonusLinesString) <= INVENTORY_ROWS_MAX  then
	  	bonus = 10 * tonumber(amountOfBonusLinesString)
	  	if player.character.character_inventory_slots_bonus  + bonus > 0 then
			player.character.character_inventory_slots_bonus  = player.character.character_inventory_slots_bonus + bonus
	    else
	    	player.character.character_inventory_slots_bonus  = 0
	    end
	    if not global["config-pers"][player.name]["bonus"] then
	    	global["config-pers"][player.name]["bonus"] = {}
	    end
      global["config-pers"][player.name]["bonus"]["character_inventory_slots_bonus"] = player.character.character_inventory_slots_bonus
		if bonus < 0 then 
		    msg = "Inventory decreased by "
		else
		    msg = "Inventory increased by "
		end
		slSaysAll(msg .. player.name .. "  (bonus: " .. player.character.character_inventory_slots_bonus .. ")")
  	else
  		if not amountOfBonusLinesString then
  			amountOfBonusLinesString = ""
  		end
		slSays(player, "Please use a value between [" .. -INVENTORY_ROWS_MAX .. "," .. INVENTORY_ROWS_MAX .. "]  (used: /inv " .. amountOfBonusLinesString .. ")")
  	end
end
Jessea2010
Burner Inserter
Burner Inserter
Posts: 18
Joined: Fri Dec 15, 2017 5:33 pm
Contact:

Re: [0.16.4] missing train auto/manual switch ...

Post by Jessea2010 »

Loewchen wrote:This save has been modded with a "save-file mod", if you can produce this issue with a not modified save, let us know.
It happens with any Inventory increase. Try with wormmus config mod. Set inventory size to 1000 and you will see.
kovarex
Factorio Staff
Factorio Staff
Posts: 8207
Joined: Wed Feb 06, 2013 12:00 am
Contact:

Re: [Kovarex] [0.16.4] missing train auto/manual switch ...

Post by kovarex »

Duplicate of: 55378
Post Reply

Return to “Duplicates”