GenerateNewLocationFromLocation(location, float, float, float)

Creates a new location from a given location

location GenerateNewLocationFromLocation(
    location lTarget,
    float fDistance,
    float fAngle,
    float fOrientation
);

Parameters

lTarget

Location to start from

fDistance

Create new location at this distance from lTarget

fAngle

And at this angle

fOrientation

Orientation of the new location


Description

This function returns a new location based on the following.
A location:
The name of this function is GenerateNewLocationFromLocation so this is the originating location that serves as teh point of reference for the new location.
A distance and an angle:
The new location is going to be (distance) away at (angle) angle with zero being north.
A orientation
Once created the location will be given the supplied facing.

Calls

object GetAreaFromLocation(location lTarget)
vector GetPositionFromLocation(location lTarget)
vector GetChangedPosition(vector vOriginal, float fDistance, float fAngle)
location Location(object oArea, vector vNewPos, float fOrientation)



Remarks

BioWare lists this as a private function, but I can see a lot of purposes for this function.

Function is found in x0_i0_position, but including nw_i0_generic will suffice.


Requirements

#include "x0_i0_position"

Version

1.61

See Also

categories: Area Functions


 author: Lilac Soul, editors: Michael Nork, Mistress