- simple access to value of XPE variables
- as an integer
- as a float
- as a string
- writing a basic C value to an XPE variable
- C integer to XPE variable
- C float to XPE variable
- C string to XPE variable
- copying values between XPE variables without knowing the types of the values involved
- incrementing an XPE variables that holds an integer
- simple non-optimised version
- optimised version
accessing XPE variables
simple access to value of XPE variables
- using XPE variable fred as an integer
int xint;
xint = XPE::get_variable("fred").get_int();
- using XPE variable fred as a float
float xfloat;
xfloat = XPE::get_variable("fred").get_float();
- using XPE variable fred as a string
const char
*xstr;
xstr = XPE::get_variable("fred").get_str();
writing a basic C value to an XPE variable
- writing a C integer to an XPE variable
int xint;
xint = 55;
XPE::get_variable("fred") = (long)xint;
- writing a C float to an XPE variable
float xfloat;
xfloat = 55.5
XPE::get_variable("fred") = xfloat;
- writing a C string to an XPE variable
const char
*xstr;
xstr = "hello world";
XPE::get_variable("fred") = xstr;
copying values between XPE variables without knowing the types of the values involved
XPE::get_variable("fred") = XPE::get_variable("jack");
incrementing an XPE variables that holds an integer