Docs elaboration re create_entity direction/orientation

Place to ask discuss and request the modding support of Factorio. Don't request mods here.
Post Reply
sparr
Smart Inserter
Smart Inserter
Posts: 1327
Joined: Fri Feb 14, 2014 5:52 pm
Contact:

Docs elaboration re create_entity direction/orientation

Post by sparr »

http://lua-api.factorio.com/latest/LuaS ... ate_entity
direction :: defines.direction (optional): Desired orientation of the entity after creation.
Direction and Orientation are two different things in most of the Factorio API, so having the term used seemingly interchangeably here is confusing. For many "normal" entities, the direction specified here ends up as the direction property of the created entity. For entities like vehicles and rolling stock, the direction specified here gets converted to an orientation, then the entity gets that orientation or an orientation snapped to the curved rail it's on but has direction==0.

One or two extra sentences here might make this more clear.

Post Reply

Return to “Modding interface requests”