Factorio.com|Forums|Wiki|Mod Portal|API Docs

# Factorio Runtime Docs Version 2.0.77

# ScriptRenderTarget - Runtime Docs

## ScriptRenderTarget :: LuaEntity or MapPosition or ScriptRenderTargetTable

When writing it is possible to give LuaEntity or MapPosition directly. However, reading always returns the full ScriptRenderTargetTable.

The full ScriptRenderTargetTable allows specifying an offset for entity targets.

If an entity target of an object (except its `orientation_target`) is destroyed or changes surface, then the object is also destroyed.

#### Examples

    target = some_lua_entity

    target = {1, 4}

    target = {entity = another_lua_entity, offset = {-0.5, 1}}

    target = {position = {2.5, 3}}

Concept used in

- LuaRenderObject::set_corners()
- LuaRenderObject::from
- LuaRenderObject::to
- LuaRenderObject::target
- LuaRenderObject::left_top
- LuaRenderObject::right_bottom
- LuaRenderObject::vertices
- LuaRenderObject::orientation_target
- LuaRendering::draw_line()
- LuaRendering::draw_text()
- LuaRendering::draw_circle()
- LuaRendering::draw_rectangle()
- LuaRendering::draw_arc()
- LuaRendering::draw_polygon()
- LuaRendering::draw_sprite()
- LuaRendering::draw_light()
- LuaRendering::draw_animation()