Garry's Mod Wiki

Revision Difference

Entity:LocalToWorld#514683

<function name="LocalToWorld" parent="Entity" type="classfunc">⤶ <description>Converts a vector local to an entity into a worldspace vector</description>⤶ <realm>Shared</realm>⤶ <args>⤶ <arg name="lpos" type="Vector">The local vector</arg>⤶ </args>⤶ <rets>⤶ <ret name="" type="Vector">The translated to world coordinates vector</ret>⤶ </rets>⤶ </function>⤶ ⤶ <example>⤶ <description>Produces a worldvector 100 units in front of the center of the entity, taking into account the entity's angle</description>⤶ <code>return ent:LocalToWorld(Vector(100,0,0))</code>⤶ ⤶ </example>