donno
2006-10-02, 13:36
Intro
Vortex Presets uses a scripting library known as AngelScript. The Scripting language follows the same/similar syntax to C/C++. Here is a list of things that might be useful to know. I might post this on the Wiki Later on. Just thought this forums looking bare. Hopefully some more infomation can be given later like examples, samples, explanations on how stuff actually works. For now this list is here just so you know.
Supported Data Types
float
int
bool
Texture
Map
VoicePrint
Tunnel
List of Global Defined Constants
const int PRIM_POINTLIST = 1;
const int PRIM_LINELIST = 2;
const int PRIM_LINELOOP = 3;
const int PRIM_LINESTRIP = 4;
const int PRIM_TRIANGLELIST = 5;
const int PRIM_TRIANGLESTRIP = 6;
const int PRIM_TRIANGLEFAN = 7;
const int PRIM_QUADLIST = 8;
const int PRIM_QUADSTRIP = 9;
const int TEXTURE_FRAMEBUFFER = 1;
const int TEXTURE_NEXTPRESET = 2;
const int TEXTURE_CURRPRESET = 3;
const int TEXTURE_ALBUMART = 4;
const int NULL = 0;
const int BLEND_OFF = 0;
const int BLEND_ADD = 1;
const int BLEND_MOD = 2;
const int BLEND_MAX = 3;
const int FILLMODE_SOLID = 0;
const int FILLMODE_WIREFRAME = 1;
Global Vortex Variables
TREBLE
MIDDLE
BASS
TIMEPASS
FINISHED (Set by User)
As you guess you can use these to base your animations/movement/position/size etc on what the auto is like
Operators and Math
+ Addition (5+3 will give 8)
- Subtraction (5-3 will give 2)
* Multiplcation (2*4 will give 8)
= Equality (left side will be made same as right side)
+= (same as left = left + right
-= (same as left = left - right)
Cos(x) Cosine of x in radians
Sin(x) Sine of x in radians
Rand() Chooses a random float from 0 to 1. [Not sure how many decial places]
Rand()*10 Chooses a random float from 0 to 10 [Still not sure how many decimal places]
Pow(a,x) a to the power of x (I think :D)
Fabs(a) makes float a an absolute value
Vortex Functions
I got no idea exactly how these works i just found them in the inlucded presets.
a,b,c,d,e,[f] for showing variables in the function argument,
gfxSetTexture(Texture Type);
gfxSetRenderTarget(Texture Type); (also gfxSetRenderTarget(Map Type)
gfxSetEnvTexture(Texture Type);
gfxTranslate(a, b, c);
gfxRotate(a,b,c,d);
gfxColour(a, b, c, d);
gfxCube(a,b, c, d,e,[f]); (Using f coz I use f for something else)
gfxTexCoord(a,b);
gfxVertex(x,y,s);
gfxSetBlendMode(BLEND_ADD);
gfxBegin(PRIM_QUADLIST);
gfxEnd();
gfxPushMatrix();
gfxPopMatrix();
gfxClear(0);
gfxSetAspect(0);
gfxTexRect(-1, 1, 1, -1);
gfxLookAt(Cos(tn*1.23)*5,Sin(tn)*5,(tm*2)-1,Cos(tn*0.6734)*2,Sin(tn*0.2143)*2,(tm*2)+8,0,1,0 );
Vortex Presets uses a scripting library known as AngelScript. The Scripting language follows the same/similar syntax to C/C++. Here is a list of things that might be useful to know. I might post this on the Wiki Later on. Just thought this forums looking bare. Hopefully some more infomation can be given later like examples, samples, explanations on how stuff actually works. For now this list is here just so you know.
Supported Data Types
float
int
bool
Texture
Map
VoicePrint
Tunnel
List of Global Defined Constants
const int PRIM_POINTLIST = 1;
const int PRIM_LINELIST = 2;
const int PRIM_LINELOOP = 3;
const int PRIM_LINESTRIP = 4;
const int PRIM_TRIANGLELIST = 5;
const int PRIM_TRIANGLESTRIP = 6;
const int PRIM_TRIANGLEFAN = 7;
const int PRIM_QUADLIST = 8;
const int PRIM_QUADSTRIP = 9;
const int TEXTURE_FRAMEBUFFER = 1;
const int TEXTURE_NEXTPRESET = 2;
const int TEXTURE_CURRPRESET = 3;
const int TEXTURE_ALBUMART = 4;
const int NULL = 0;
const int BLEND_OFF = 0;
const int BLEND_ADD = 1;
const int BLEND_MOD = 2;
const int BLEND_MAX = 3;
const int FILLMODE_SOLID = 0;
const int FILLMODE_WIREFRAME = 1;
Global Vortex Variables
TREBLE
MIDDLE
BASS
TIMEPASS
FINISHED (Set by User)
As you guess you can use these to base your animations/movement/position/size etc on what the auto is like
Operators and Math
+ Addition (5+3 will give 8)
- Subtraction (5-3 will give 2)
* Multiplcation (2*4 will give 8)
= Equality (left side will be made same as right side)
+= (same as left = left + right
-= (same as left = left - right)
Cos(x) Cosine of x in radians
Sin(x) Sine of x in radians
Rand() Chooses a random float from 0 to 1. [Not sure how many decial places]
Rand()*10 Chooses a random float from 0 to 10 [Still not sure how many decimal places]
Pow(a,x) a to the power of x (I think :D)
Fabs(a) makes float a an absolute value
Vortex Functions
I got no idea exactly how these works i just found them in the inlucded presets.
a,b,c,d,e,[f] for showing variables in the function argument,
gfxSetTexture(Texture Type);
gfxSetRenderTarget(Texture Type); (also gfxSetRenderTarget(Map Type)
gfxSetEnvTexture(Texture Type);
gfxTranslate(a, b, c);
gfxRotate(a,b,c,d);
gfxColour(a, b, c, d);
gfxCube(a,b, c, d,e,[f]); (Using f coz I use f for something else)
gfxTexCoord(a,b);
gfxVertex(x,y,s);
gfxSetBlendMode(BLEND_ADD);
gfxBegin(PRIM_QUADLIST);
gfxEnd();
gfxPushMatrix();
gfxPopMatrix();
gfxClear(0);
gfxSetAspect(0);
gfxTexRect(-1, 1, 1, -1);
gfxLookAt(Cos(tn*1.23)*5,Sin(tn)*5,(tm*2)-1,Cos(tn*0.6734)*2,Sin(tn*0.2143)*2,(tm*2)+8,0,1,0 );