Code: Select all
player :: LuaPlayer (optional)
by_player :: LuaPlayer (optional)
position :: Position (optional)
resolution :: Position (optional)
zoom :: double (optional)
path :: string (optional): Path to save the screenshot in
show_gui :: boolean (optional): Include game GUI in the screenshot?
show_entity_info :: boolean (optional): Include entity info (alt-mode)?
Code: Select all
player :: LuaPlayer (optional)
by_player :: LuaPlayer (optional)
position :: Position (optional)
surface :: LuaSurface (optional)
resolution :: Position (optional)
zoom :: double (optional)
path :: string (optional): Path to save the screenshot in
show_gui :: boolean (optional): Include game GUI in the screenshot?
show_entity_info :: boolean (optional): Include entity info (alt-mode)?
brightness :: double (optional) :: Take screenshot at specified brightness 14% is in-game night and 100% is normal daylight.
Brightness is needed to allow for screenshots to always be taken at a specific brightness level regardless of what the surface brightness currently is. Removes the need to perform ugly "hacks" to simulate this. The train cameras already seem to do this so I, naively, assume giving this power to take_screenshot is quick-n-easy.