First call FollowObject() method to set the character to follow. set call any of the camera transition functions to set the camera follow mode
Static Public Member Functions | |
static void | FollowObject (ParaObject obj) |
set the character to follow. | |
static void | FollowObject (const char *strObjectName) |
set the character to follow. | |
static void | FirstPerson (int nTransitionMode, float fHeight, float fAngle) |
Set the current camera to follow a certain object, using first person view of the object. | |
static void | ThirdPerson (int nTransitionMode, float fHeight, float fFacing, float fAngle) |
Set the current camera to follow a certain object, using Third Person view of the object, where character is always centered while allowing rotation around it from 360 degree angles,. | |
static void | Default (int nTransitionMode, float fHeight, float fAngle) |
: Set the current camera to follow a certain object, using the default view of the object. | |
static void | Fixed (int nTransitionMode, float fX, float fY, float fZ) |
Set the current camera to look at a certain object, from a fixed camera location while allowing rotation around it from 360 degree angles,. | |
static void | GetPosition (float *x, float *y, float *z) |
get the world position of the camera eye. | |
static void | GetLookAtPosition (float *x, float *y, float *z) |
get the position that the camera is currently looking at. | |
static ParaAttributeObject | GetAttributeObject () |
get the attribute object associated with the current camera object. | |
static void | GetAttributeObject_ (ParaAttributeObject &output) |
used for API exportation. |
void ParaScripting::ParaCamera::FollowObject | ( | ParaObject | obj | ) | [static] |
set the character to follow.
the object is also set as the current player
obj,: | the ParaObject to follow, one can call |
void ParaScripting::ParaCamera::FollowObject | ( | const char * | strObjectName | ) | [static] |
set the character to follow.
the object must be global in order to be found by its name. It is also set as the current player currently,
strObjectName,: | the name of the object to follow |
void ParaScripting::ParaCamera::FirstPerson | ( | int | nTransitionMode, | |
float | fHeight, | |||
float | fAngle | |||
) | [static] |
Set the current camera to follow a certain object, using first person view of the object.
nTransitionMode,: | 1 (default) smooth move or 0 immediate move | |
fRadius,: | the distance from the person to the camera | |
fAngle,: | camera lift up angle, this is usually Pi/4: 45 degrees |
void ParaScripting::ParaCamera::ThirdPerson | ( | int | nTransitionMode, | |
float | fHeight, | |||
float | fFacing, | |||
float | fAngle | |||
) | [static] |
Set the current camera to follow a certain object, using Third Person view of the object, where character is always centered while allowing rotation around it from 360 degree angles,.
nTransitionMode,: | 1 (default) smooth move or 0 immediate move | |
fRadius,: | the distance from the person to the camera | |
fFacing,: | camera facing, around the y axis, which is the world height axis. | |
fAngle,: | camera lift up angle, this is usually Pi/4: 45 degrees |
void ParaScripting::ParaCamera::Default | ( | int | nTransitionMode, | |
float | fHeight, | |||
float | fAngle | |||
) | [static] |
: Set the current camera to follow a certain object, using the default view of the object.
character restricted to move within a rectangular region, while camera is facing a fixed direction.
nTransitionMode,: | 1 (default) smooth move or 0 immediate move | |
fHeight,: | relative camera height above the object. | |
fAngle,: | camera lift up angle, this is usually Pi/4: 45 degrees |
void ParaScripting::ParaCamera::Fixed | ( | int | nTransitionMode, | |
float | fX, | |||
float | fY, | |||
float | fZ | |||
) | [static] |
Set the current camera to look at a certain object, from a fixed camera location while allowing rotation around it from 360 degree angles,.
nTransitionMode,: | 1 (default) smooth move or 0 immediate move | |
fX,: | camera location: x | |
fY,: | camera location: y | |
fZ,: | camera location: z |
void ParaScripting::ParaCamera::GetPosition | ( | float * | x, | |
float * | y, | |||
float * | z | |||
) | [static] |
get the world position of the camera eye.
This function takes no parameters. x,y,z are not input, but pure output. In the script, we can call it as below x,y,z = ParaCamera.GetPosition(); -- get the camera's eye position in Luabind, it is defined as .def("GetPosition", &ParaCamera::GetPosition, pure_out_value(_1) + pure_out_value(_2) + pure_out_value(_3)) please note, y is the absolute position in world coordinate
void ParaScripting::ParaCamera::GetLookAtPosition | ( | float * | x, | |
float * | y, | |||
float * | z | |||
) | [static] |
get the position that the camera is currently looking at.
ParaAttributeObject ParaScripting::ParaCamera::GetAttributeObject | ( | ) | [static] |
get the attribute object associated with the current camera object.
void ParaScripting::ParaCamera::GetAttributeObject_ | ( | ParaAttributeObject & | output | ) | [static] |
used for API exportation.