DI-Guy C++ SDK Reference  13.0
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
diguyCharacterPathScriptBead Class Reference

A bead that sits on a character's spline path and triggers a new script evaluation. More...

#include <diguyCharacterPathScriptBead.h>

Public Member Functions

const char * get_name ()
 Returns the name of the object. More...
 
int set_name (const char *name)
 This function sets the name of this object. More...
 
const char * get_script ()
 This function returns the script this bead performs. More...
 
int set_script (const char *script)
 This function sets the script this bead performs. More...
 
int set_script_type (const char *script)
 This function sets the script type of this bead. More...
 
const char * get_script_type ()
 Returns: The language of the script. More...
 
float get_distance_into_path ()
 This function returns how far into the path this bead is. More...
 
int set_distance_into_path (float distance_into_path)
 This function sets how far into the path this bead is. More...
 
float get_length ()
 This function returns where on the path this bead is. More...
 
int set_length (float length)
 This function sets how long this bead will have an effect. More...
 
float get_tin ()
 This function returns when on the path this bead is. More...
 
int set_tin (float tin)
 This function sets when this bead will begin to have an effect. More...
 
float get_duration ()
 This function returns how long this bead will have an effect. More...
 
int set_duration (float duration)
 This function sets how long this bead will have an effect. More...
 
Experimental Functions

The following functions are experimental and may change or disappear with no warning.

const char * get_begin_at_object_name ()
 
int set_begin_at_object_name (const char *begin_at_object_name)
 
float get_begin_at_object_offset ()
 
int set_begin_at_object_offset (float begin_at_object_offset)
 
const char * get_end_at_object_name ()
 
int set_end_at_object_name (const char *end_at_object_name)
 
float get_end_at_object_offset ()
 
int set_end_at_object_offset (float end_at_object_offset)
 

Private Functions

The functions and variables past this point are for internal use only.

No external access to them is expected or necessary.

class bdiBeadScript
 
bdiBeadScriptm_scripted_object
 A pointer to internal data. More...
 
bdiBeadScriptget_scripted_object ()
 
 diguyCharacterPathScriptBead (bdiBeadScript *scripted_object)
 A private constructor. More...
 
 ~diguyCharacterPathScriptBead ()
 A private destructor. More...
 

Detailed Description

A bead that sits on a character's spline path and triggers a new script evaluation.

Constructor & Destructor Documentation

diguyCharacterPathScriptBead::diguyCharacterPathScriptBead ( bdiBeadScript scripted_object)
private

A private constructor.

diguyCharacterPathScriptBead::~diguyCharacterPathScriptBead ( )
private

A private destructor.

Member Function Documentation

const char* diguyCharacterPathScriptBead::get_name ( )

Returns the name of the object.

This pointer will never be NULL.

Returns:

name of the object

Callable From:

  • C++
  • Script
int diguyCharacterPathScriptBead::set_name ( const char *  name)

This function sets the name of this object.

Returns:

0 on success, -1 on failure

Callable From:

  • C++
  • Script
const char* diguyCharacterPathScriptBead::get_script ( )

This function returns the script this bead performs.

Returns:

script to perform; empty string if no script set

Callable From:

  • C++
  • Script
int diguyCharacterPathScriptBead::set_script ( const char *  script)

This function sets the script this bead performs.

When a character is traversing the path containing this bead, the specified script will be performed when this bead is reached.

If this script bead is part of a diguyCharacterPath, the diguyCharacterPath::update() function must be called for changes to take effect.

Parameters
scriptthe script that should be evaluated when
thisbead is reached; pass NULL to un set the script

Returns:

0 on success, -1 on failure

Callable From:

  • C++
  • Script
int diguyCharacterPathScriptBead::set_script_type ( const char *  script)

This function sets the script type of this bead.

This can only be "lua".

Parameters
script_typethe language of the script

Returns:

0 on success, -1 on failure

Callable From:

  • C++
  • Script
const char* diguyCharacterPathScriptBead::get_script_type ( )

Returns: The language of the script.

Callable From:

  • C++
  • Script
float diguyCharacterPathScriptBead::get_distance_into_path ( )

This function returns how far into the path this bead is.

Returns:

distance into path of this bead, in meters

Callable From:

  • C++
  • Script
int diguyCharacterPathScriptBead::set_distance_into_path ( float  distance_into_path)

This function sets how far into the path this bead is.

Since distances and times on paths are interrelated, calling this function will have the side-effect of setting when on the path the bead is located, as if to a call to set_tin().

If this script bead is part of a diguyCharacterPath, the diguyCharacterPath::update() function must be called for changes to take effect.

Parameters
distance_into_pathhow far into the path this bead is, in meters

Returns:

0 on success, -1 on failure

Callable From:

  • C++
  • Script
float diguyCharacterPathScriptBead::get_length ( )

This function returns where on the path this bead is.

Returns:

location of this bead, in meters

Callable From:

  • C++
  • Script
int diguyCharacterPathScriptBead::set_length ( float  length)

This function sets how long this bead will have an effect.

The bead will have an effect from its initial distance into the path (as set by set_distance_into_path()) to (distance + length) seconds.

Since distances and times on paths are interrelated, calling this function will have the side-effect of setting when on the path the bead's effect ends, as if to a call to set_duration().

If this script bead is part of a diguyCharacterPath, the diguyCharacterPath::update() function must be called for changes to take effect.

Parameters
durationduration of this bead, in seconds

Returns:

0 on success, -1 on failure

Callable From:

  • C++
  • Script
float diguyCharacterPathScriptBead::get_tin ( )

This function returns when on the path this bead is.

Returns:

time location of this bead, in seconds

Callable From:

  • C++
  • Script
int diguyCharacterPathScriptBead::set_tin ( float  tin)

This function sets when this bead will begin to have an effect.

Since distances and times on paths are interrelated, calling this function will have the side-effect of setting where on the path the bead is located, as if to a call to set_distance_into_path().

If this script bead is part of a diguyCharacterPath, the diguyCharacterPath::update() function must be called for changes to take effect.

Parameters
tinwhen this bead begins to have an effect, in seconds

Returns:

0 on success, -1 on failure

Callable From:

  • C++
  • Script
float diguyCharacterPathScriptBead::get_duration ( )

This function returns how long this bead will have an effect.

Returns:

duration of this bead, in seconds

Callable From:

  • C++
  • Script
int diguyCharacterPathScriptBead::set_duration ( float  duration)

This function sets how long this bead will have an effect.

The bead will have an effect from tin seconds (as set by set_tin()) to (tin + duration) seconds.

Since distances and times on paths are interrelated, calling this function will have the side-effect of setting where on the path the bead's effect ends, as if to a call to set_length().

If this script bead is part of a diguyCharacterPath, the diguyCharacterPath::update() function must be called for changes to take effect.

Parameters
durationduration of this bead, in seconds

Returns:

0 on success, -1 on failure

Callable From:

  • C++
  • Script
const char* diguyCharacterPathScriptBead::get_begin_at_object_name ( )
int diguyCharacterPathScriptBead::set_begin_at_object_name ( const char *  begin_at_object_name)
float diguyCharacterPathScriptBead::get_begin_at_object_offset ( )
int diguyCharacterPathScriptBead::set_begin_at_object_offset ( float  begin_at_object_offset)
const char* diguyCharacterPathScriptBead::get_end_at_object_name ( )
int diguyCharacterPathScriptBead::set_end_at_object_name ( const char *  end_at_object_name)
float diguyCharacterPathScriptBead::get_end_at_object_offset ( )
int diguyCharacterPathScriptBead::set_end_at_object_offset ( float  end_at_object_offset)
bdiBeadScript* diguyCharacterPathScriptBead::get_scripted_object ( )
inline

Friends And Related Function Documentation

friend class bdiBeadScript
friend

Member Data Documentation

bdiBeadScript* diguyCharacterPathScriptBead::m_scripted_object
private

A pointer to internal data.


The documentation for this class was generated from the following file: