Haha, that's creepy.
So anywho, I've been busy today and haven't actually touched any source yet, but to even things out a bit, here's a list of functions that are already in the AGE engine.
---Math
Add VAR, INT/FLOAT : Will add the given int/float value to the given variable.
Sub VAR, INT/FLOAT : Will subtract the given int/float value from the given variable.
---Array commands
Dim array_name, arrary_size : will create an array or resize a currently existing array.
Undim array_name : will erase the given array and all of its contained data from memory.
@array_name, array_index : Can be used in a similarly to a vairable in the way that it will either return the stored data or, if used first, set the stored data of the given index in the given array.
---System
Do...loop : Code within do and loop will be run repeatedly, until the loop is exited.
For $VAR = INT to INT...Next $VAR : This works like an ordinary loop, only every loop the given variable which is initially set to the first INT given will be incremented by 1. When the variable reaches the second INT given, the loop will exit when it gets to Next.
Exit : This will exit the current loop.
End : This will immediately end the program.
If...Endif : Will execute the script within if the given if statement is true. An Else condition can be placed between If and Endif to run a script if the condition is false.
Message INT/FLOAT/STRING : Will dispay the given message in the form of a windows 'OK' dialog box. Handy for debugging.
Runiscript : Will run the initial script for entities within the current AGM level.
Runlscript : Will run the loop script for entities within the current AGM level.
Runescript : Will run the end script for entities within the current AGM level.
Updatedelta : Will update the delta value for the Delta() command.
---File
Write file INT, INT/FLOAT/STRING : This will write to the specified file the specified data.
Delete file String : This will delete the specified file.
---3D
Sync on : This will turn off automatic sync.
sync off : This will turn off user set syncs.
sync rate INT : This will define the maximum sync rate.
Sync : If sync has been activated via sync on, this will update the screen.
Set agm load distance FLOAT : This will set the AGM load distance. This is at 25 by default.
Set BBa FLOAT : This will set the distance that an object will be replaced by a billboard by multiplying the number given by that of the objects size.
Set BBb FLOAT : This will set the distance that a billboard will be deleted by multiplying the number given by that of the objects size.
Agm distance load : This will gradually load the objects of an AGM level based on their size and distance from the camera.
Load agm level STRING : This will load the given AGM level. If a level is currently open then it will be closed automatically.
--Camera
Mcc INT/FLOAT : This is a premade mouse to camera control function.
Position camera FLOAT, FLOAT, FLOAT : This will position the camera at the given xyz coordinates.
Move camera FLOAT : This will move the camera forward or backwards.
Xrotate camera FLOAT : This will rotate the camera by the value on the x axis.
Yrotate camera FLOAT : This will rotate the camera by the value on the y axis.
Zrotate camera FLOAT : This will rotate the camera by the value on the z axis.
Turn camera left INT, FLOAT : This will rotate the camera left by the given value.
Turn camera right INT, FLOAT : This will rotate the camera right by the given value.
Rotate camera FLOAT, FLOAT, FLOAT : This will rotate the camera by the given xyz angles.
Point camera FLOAT, FLOAT, FLOAT : This will point the camera towards the given xyz position.
Set camera range FLOAT, FLOAT : This will set the cameras near far range of visibility.
Backdrop on : This will activate the 3D backdrop.
Backdrop off : This will deactivate the 3D backdrop.
Color backdrop INT : This will set the backdrop color.
Fog on : This will turn fog on.
Fog off : This will turn fog off.
Fog distance FLOAT : This will set the fog distance.
Color fog : This will set the fog color.
--Object
Delete object INT : Will delete the specified object from memory.
Set build position FLOAT, FLOAT, FLOAT : This will set the default xyz position for all objects that are created/load.
Set build rotation FLOAT, FLOAT, FLOAT : This will set the default xyz rotation for all objects that are created/load.
Position object INT, FLOAT, FLOAT, FLOAT : This will position the specified object at the given xyz coordinates.
Move object INT, FLOAT : This will move the specified object forward or backwards.
Move object left INT, FLOAT : This will move the specified object left.
Move object right INT, FLOAT : This will move the specified object right.
Move object up INT, FLOAT : This will move the specified object up.
Move object down INT FLOAT : This will move the specified object down.
Xrotate object INT, FLOAT : This will rotate the specified object by the given value on the x axis.
Yrotate object INT, FLOAT : This will rotate the specified object by the given value on the y axis.
Zrotate object INT, FLOAT : This will rotate the specified object by the given value on the z axis.
Turn object left INT, FLOAT : This will rotate the specified object left by the given value.
Turn object right INT, FLOAT : This will rotate the specified object right by the given value.
Rotate object INT, FLOAT, FLOAT, FLOAT : This will rotate the specified object by the given xyz angles.
Rotateobjecttopoint INT, FLOAT, FLOAT, FLOAT, FLOAT : Will rotate the specified object towards the given xyz coordinates gradually, based on the given smoothness value at the end.
Point object INT, FLOAT, FLOAT, FLOAT : This will point the specified object towards the given xyz position.
Play object INT, FLOAT, FLOAT : This will play the specified object from the given frame to the second given frame.
Loop object INT, FLOAT, FLOAT : This will loop the specified object from the given frame to the second given frame.
Stop object INT : This will stop the specified object from playing its animation.
Set object frame INT, FLOAT : This will set the given object to the given frame.
Set object speed INT, FLOAT : This will set the given objects animation speed.
Set object visible INT : Will set the visibility for the current object. 1 for visible and 0 for not visible. An invisible object won't be picked up by the Objectundermouse command.
-Collision
Set object collision INT, INT : This will set the given objects collision on(1) or off(0).
Runcollision INT : Will calculate the collision for the given object and reposition it accordingly.
Runxintersections INT : Will calculate the collision for the given object on the x axis and reposition it accordingly.
Runyintersections INT : Will calculate the collision for the given object on the y axis and reposition it accordingly.
Runzintersections INT : Will calculate the collision for the given object on the z axis and reposition it accordingly.
---2D
Print INT/FLOAT/STRING : This will print the specified data to the set cursor position on screen.
Set cursor INT, INT : This will set the cursor for the print command.
Text INT, INT, INT/FLOAT/STRING : This will print the specified data to the screen at the at the specified x and y screen positions.
Position Mouse INT, INT : Will set the mouse position to that of the given X and Y screen position.
Set Mouse Visible INT : This will set the visibility of the mouse. 1 being visible and 0 being invisible.
Draw box INT, INT, INT, INT, INT, INT, INT, INT : Will draw a box from the given xy position to the given xy position. The additional values are for ethe colour of each corner.
Draw line INT, INT, INT, INT : Will draw a line from the given xy position to the given xy position.
Draw dot INT, INT, INT : Will draw a dot at the given xy position. The additional value is for the colour of the dot.
--Image
Delete image INT : Will delete the specified image from memory.
Draw image INT, INT, INT : Will display the specified image at the given xy screen position.
---Sound
Delete sound INT : This will delete the specified sound from memory.
Play sound INT : This will play the specified sound.
Loop sound INT : This will loop the specified sound.
Pause sound INT : This will pause the specified sound.
Stop sound INT : This will stop the specified sound.
---Music
Delete music INT : This will delete the specified music from memory.
Play music INT : This will play the specified music.
Loop music INT : This will loop the specified music.
Pause music INT : This will pause the specified music.
Stop music INT : This will stop the specified music.
--Client/Server
Net_Update : Will check for new messages and update the return commands in preperation for them.
Net_Send_String INT, STRING : Will send the given the string using the given INT as a label for the message type.
Net_Send_Position_XY_Y FLOAT, FLOAT, FLOAT : Will send the given XY coords and the Y angle of the clients object.
Net_Send_Position_XYZ_Y FLOAT, FLOAT, FLOAT : Will send the given XYZ coords and the Y angle of the client object.
Net_Send_Position_XYZ_XYZ FLOAT, FLOAT, FLOAT : Will send the given XYZ coords and the XYZ angles of the client object.
~~~ Functions that return a value ~~~
---Math
Rnd( INT ) : Will return a random number between 0 and the given number, including 0 and the given number in the calculation.
Rgb ( INT, INT, INT ) : Will convert the given red, green and blue values into one value, for use with commands like fog color.
Delta( INT/FLOAT ) : Will return the delta value of the given number. This can be used in conjunction with Updatedelta to ensure that objects or other entities are moved at the same speed, regardless of the FPS.
---Variable commands
var_switch_flag VAR : Will return the switched flag of the given variable.
var_min VAR, INT : will return the corrected value of the given variable based on the minimum number.
var_max VAR, INT : will return the corrected value of the given variable based on the maximum number.
---System
Timer$() : Will return the computers internal system time.
Screen fps() : Will return the current ammount of frames per second.
---File
File read( STRING ) : Will open the specified file for reading and return the number of the file.
File write( STRING ) : Will open the specified file for writing and return the number of the file.
File exist( STRING ) : Will return a 1 if the specified exists.
Read file( INT ) : Will return a line from the specified open file.
---3D
--Camera
Camera position x() : Will return the current position of the camera on the x axis.
Camera position y() : Will return the current position of the camera on the y axis.
Camera position z() : Will return the current position of the camera on the z axis.
Camera angle x() : Will return the current angle of the camera on the x axis.
Camera angle y() : Will return the current angle of the camera on the y axis.
Camera angle z() : Will return the current angle of the camera on the z axis.
--Object
Loadobject( STRING ) : Will load the specified object into memory and return its number.
Makebox( FLOAT, FLOAT, FLOAT ) : Will create a box using the given xyz values as size data and return its number.
Makecube( FLOAT ) : Will create a cube using the given vale as size data and return its number.
Makesphere( FLOAT ) : Will create a sphere using the given value as size data and return its number.
Makeplain( FLOAT ) : Will create a plain using the given value as size data and return its number.
Object position x( INT ) : Will return the current position of the specified object on the x axis.
Object position y( INT ) : Will return the current position of the specified object on the y axis.
Object position z( INT ) : Will return the current position of the specified object on the z axis.
Object angle x( INT ) : Will return the current angle of the specified object on the x axis.
Object angle y( INT ) : Will return the current angle of the specified object on the y axis.
Object angle z( INT ) : Will return the current angle of the specified object on the z axis.
Object screen x( INT ) : Will return the current position of the specified objects on the screens x axis.
Object screen y( INT ) : Will return the current position of the specified objects on the screens y axis.
Object collision( INT, INT ) : Will return a 1 if the specified objects are colliding with eachother.
Objectundermouse : Will return the number of the object currently undereath the cursor.
Returnxintersections( INT ) : Will calculate the collision for the given object on the x axis and reposition it accordingly. Will then return the value that the object has been moved by on the x axis.
Returnyintersections( INT ) : Will calculate the collision for the given object on the y axis and reposition it accordingly. Will then return the value that the object has been moved by on the y axis.
Returnzintersections( INT ) : Will calculate the collision for the given object on the z axis and reposition it accordingly. Will then return the value that the object has been moved by on the z axis.
Lineclear( FLOAT, FLOAT, FLOAT, FLOAT, FLOAT, FLOAT ) : Will check if the line from the given xyz to the second given xyz is blocked, and if so, the distance from the start of the line to the blockage is returned.
Objectlineclear( INT, FLOAT, FLOAT, FLOAT ) : Will check if the line from the given object to the given xyz position is blocked, and if so, the distance from the start of the line to the blockage is returned.
Objectslineclear( INT, INT ) : Will check if the line from the given object to the second given object is blocked, and if so, the distance from the start of the line to the blockage is returned.
Withinrange( FLOAT, FLOAT, FLOAT, FLOAT, FLOAT, FLOAT, FLOAT ) : Will return a 1 if the the given xyz position is within the second xyz positions range. The range to check for is the last float given.
Objectwithinrange( INT, FLOAT, FLOAT, FLOAT, FLOAT ) : Will check if the given object is within range of the given xyz position. The range to check for is the last float given.
Objectswithinrange( INT, INT, FLOAT ) : Will check if the given object is within range of the second given object by the range given. The range to check for is the last float given.
Distance(FLOAT, FLOAT, FLOAT, FLOAT, FLOAT, FLOAT) : Will return the distance from the first given xyz coordinates to the second.
Objectdistance(INT, FLOAT, FLOAT, FLOAT) : Will return the distance from the object to the given xyz coordinates.
Objectsdistance(INT, INT) : Will return the distance between the two given objects.
Pointingtoposition( INT, FLOAT, FLOAT, FLOAT, FLOAT ) : Will check if the given object is pointing towards the given xyz position by a certain angle range. The angle range to check for is the last float given.
---2D
--Text
asc( STRING ) : Will return the ascii number for the provided letter. If more than one letter is given, then the ascii number for the first letter will be returned.
chr$( INT ) : Will return the charater that the given ascii number represents.
Mid$( STRING, INT ) : Will return the the selected character from the given string.
Left$( STRING, INT ) : Will return the charaters from the left of the string up to the one specified.
Right$( STRING, INT ) : Will return the charaters from the right of the string up to the one specified.
--Image
Loadimage( STRING ) : Will load the specified image into memory and return its number.
---Sound
Loadsound( STRING ) : Will load the specified sound into memory and return its number.
---Music
Loadmusic( STRING ) : Will load the specified music into memory and return its number.
---Input
keystate( INT ) : Will return a 1 if the key for the given number is being pressed.
mouseclick( INT ) : Will return a 1 if the given mouse button is being pressed.
Mousex() : will return the position of the mouse on the screens 2D x axis.
Mousey() : will return the position of the mouse on the screens 2D y axis.
Mousemovex() : Will return the distance that the mouse has moved on the screens x axis since this command was last called.
Mousemovey() : Will return the distance that the mouse has moved on the screens y axis since this command was last called.
--Client/Server
Net_Connect STRING : Will connect to the given IP address. This should be the address of the server.
Net_Message_Type : Will return the current message type.
Net_Message_String : Will return the current message string.
Net_Message_Float : Will return the current message float.
One thing that you could all do now to make AGE better can be to suggest a function. Tell me what kind of command you want added and, providing it's something that I can actually manage, I'll add it!
Hopefully I can build up the list of neat functions with ones that you peeps want.
You are not alone.[/center]