The new LuaForce.research_queue would expose read/write access to the forces current research queue as a numbered dictionary of technologies. With number 1 being the current research and counting up the queue.
When read it would return LuaTechnology and when writing it would accept TechnologySpecification. Same types as previous_research and current_research.
This would allow mods to identify (read) future scheduled researches in the queue and to manipulate them if desired.
Add a LuaForce.research_queue function
- Muppet9010
- Filter Inserter
- Posts: 281
- Joined: Sat Dec 09, 2017 6:01 pm
- Contact:
Re: Add a LuaForce.research_queue function
Okay, added to the next version.
Note for mod makers: I have removed the LuaForce::current_research write in the next version, you will have to use LuaForce::add_research() and cancel_current_research() instead (those are added by the next version). This change was made because the current_research write did not work correctly with the research queue.
Note for mod makers: I have removed the LuaForce::current_research write in the next version, you will have to use LuaForce::add_research() and cancel_current_research() instead (those are added by the next version). This change was made because the current_research write did not work correctly with the research queue.
I'm an admin over at https://wiki.factorio.com. Feel free to contact me if there's anything wrong (or right) with it.
- Muppet9010
- Filter Inserter
- Posts: 281
- Joined: Sat Dec 09, 2017 6:01 pm
- Contact:
Re: Add a LuaForce.research_queue function
thanks, works as expected