[1.1.0] Control scripts in tips/tricks
Posted: Tue Nov 24, 2020 2:58 pm
I'm trying to customise the tips/tricks scenes to better fit my mod. It's slow going but I'm making progress.
Before I dive too far into it though, is it possible to have my mod's control.lua run at all? The reason I ask is because I have entities being built that trigger additional things with events, but they aren't working.
I also quickly discovered that I can't use "require" to get access to things I would normally use - notably require("util"). Presumably my only option there is to copy-paste the functions I need directly into the simulation.
I've also noticed there seem to be some undocumented functions being used in these simulations, particularly surface.create_entities_from_blueprint_string, game.create_test_player and a few others. Are these exclusively available in simulations? I imagine the documentation will be updated at some point but are there any particular features that would be useful to know about?
And just in general, any tips on editing these simulations or creating my own would be much appreciated
Before I dive too far into it though, is it possible to have my mod's control.lua run at all? The reason I ask is because I have entities being built that trigger additional things with events, but they aren't working.
I also quickly discovered that I can't use "require" to get access to things I would normally use - notably require("util"). Presumably my only option there is to copy-paste the functions I need directly into the simulation.
I've also noticed there seem to be some undocumented functions being used in these simulations, particularly surface.create_entities_from_blueprint_string, game.create_test_player and a few others. Are these exclusively available in simulations? I imagine the documentation will be updated at some point but are there any particular features that would be useful to know about?
And just in general, any tips on editing these simulations or creating my own would be much appreciated