How to start with an empry inventory?

Post all other topics which do not belong to any other category.
Post Reply
User avatar
ExDomino
Manual Inserter
Manual Inserter
Posts: 3
Joined: Sun Oct 02, 2016 1:01 am
Contact:

How to start with an empry inventory?

Post by ExDomino »

Hello,

I wanted to know if there a way to start a fresh new game with an empty inventoy.

Thank in advance.

HurkWurk
Filter Inserter
Filter Inserter
Posts: 259
Joined: Mon Nov 14, 2016 4:55 pm
Contact:

Re: How to start with an empry inventory?

Post by HurkWurk »

the starting inventory is controlled by the file "control.lua" in factorio\data\base\scenarios\XXXXXXX\control.lua

XXXXXX = any of the scenario types, freeplay being the most common.

this script is what does the inserts:

script.on_event(defines.events.on_player_created, function(event)
local player = game.players[event.player_index]
player.insert{name="iron-plate", count=8}
player.insert{name="pistol", count=1}
player.insert{name="firearm-magazine", count=10}
player.insert{name="burner-mining-drill", count = 1}
player.insert{name="stone-furnace", count = 1}
player.force.chart(player.surface, {{player.position.x - 200, player.position.y - 200}, {player.position.x + 200, player.position.y + 200}})
if (#game.players <= 1) then
game.show_message_dialog{text = {"msg-intro"}}
else
player.print({"msg-intro"})
end
silo_script.on_player_created(event)
end)

Post Reply

Return to “General discussion”