Eliminate DefineConsoleMethod

This commit is contained in:
Lukas Joergensen 2018-04-17 21:01:50 +02:00
parent e718841467
commit 76908eae3c
77 changed files with 483 additions and 483 deletions

View file

@ -418,7 +418,7 @@ void AIClient::onAdd( const char *nameSpace ) {
/**
* Sets the move speed for an AI object
*/
DefineConsoleMethod( AIClient, setMoveSpeed, void, (F32 speed), , "ai.setMoveSpeed( float );" )
DefineEngineMethod( AIClient, setMoveSpeed, void, (F32 speed), , "ai.setMoveSpeed( float );" )
{
AIClient *ai = static_cast<AIClient *>( object );
ai->setMoveSpeed( speed );
@ -427,7 +427,7 @@ DefineConsoleMethod( AIClient, setMoveSpeed, void, (F32 speed), , "ai.setMoveSpe
/**
* Stops all AI movement, halt!
*/
DefineConsoleMethod( AIClient, stop, void, (),, "ai.stop();" )
DefineEngineMethod( AIClient, stop, void, (),, "ai.stop();" )
{
AIClient *ai = static_cast<AIClient *>( object );
ai->setMoveMode( AIClient::ModeStop );
@ -436,7 +436,7 @@ DefineConsoleMethod( AIClient, stop, void, (),, "ai.stop();" )
/**
* Tells the AI to aim at the location provided
*/
DefineConsoleMethod( AIClient, setAimLocation, void, (Point3F v), , "ai.setAimLocation( x y z );" )
DefineEngineMethod( AIClient, setAimLocation, void, (Point3F v), , "ai.setAimLocation( x y z );" )
{
AIClient *ai = static_cast<AIClient *>( object );
@ -446,7 +446,7 @@ DefineConsoleMethod( AIClient, setAimLocation, void, (Point3F v), , "ai.setAimLo
/**
* Tells the AI to move to the location provided
*/
DefineConsoleMethod( AIClient, setMoveDestination, void, (Point3F v), , "ai.setMoveDestination( x y z );" )
DefineEngineMethod( AIClient, setMoveDestination, void, (Point3F v), , "ai.setMoveDestination( x y z );" )
{
AIClient *ai = static_cast<AIClient *>( object );
@ -456,7 +456,7 @@ DefineConsoleMethod( AIClient, setMoveDestination, void, (Point3F v), , "ai.setM
/**
* Returns the point the AI is aiming at
*/
DefineConsoleMethod( AIClient, getAimLocation, Point3F, (),, "ai.getAimLocation();" )
DefineEngineMethod( AIClient, getAimLocation, Point3F, (),, "ai.getAimLocation();" )
{
AIClient *ai = static_cast<AIClient *>( object );
return ai->getAimLocation();
@ -465,7 +465,7 @@ DefineConsoleMethod( AIClient, getAimLocation, Point3F, (),, "ai.getAimLocation(
/**
* Returns the point the AI is set to move to
*/
DefineConsoleMethod( AIClient, getMoveDestination, Point3F, (),, "ai.getMoveDestination();" )
DefineEngineMethod( AIClient, getMoveDestination, Point3F, (),, "ai.getMoveDestination();" )
{
AIClient *ai = static_cast<AIClient *>( object );
return ai->getMoveDestination();
@ -474,7 +474,7 @@ DefineConsoleMethod( AIClient, getMoveDestination, Point3F, (),, "ai.getMoveDest
/**
* Sets the bots target object
*/
DefineConsoleMethod( AIClient, setTargetObject, void, (const char * objName), , "ai.setTargetObject( obj );" )
DefineEngineMethod( AIClient, setTargetObject, void, (const char * objName), , "ai.setTargetObject( obj );" )
{
AIClient *ai = static_cast<AIClient *>( object );
@ -489,7 +489,7 @@ DefineConsoleMethod( AIClient, setTargetObject, void, (const char * objName), ,
/**
* Gets the object the AI is targeting
*/
DefineConsoleMethod( AIClient, getTargetObject, S32, (),, "ai.getTargetObject();" )
DefineEngineMethod( AIClient, getTargetObject, S32, (),, "ai.getTargetObject();" )
{
AIClient *ai = static_cast<AIClient *>( object );
@ -499,7 +499,7 @@ DefineConsoleMethod( AIClient, getTargetObject, S32, (),, "ai.getTargetObject();
/**
* Tells the bot the mission is cycling
*/
DefineConsoleMethod( AIClient, missionCycleCleanup, void, (),, "ai.missionCycleCleanup();" )
DefineEngineMethod( AIClient, missionCycleCleanup, void, (),, "ai.missionCycleCleanup();" )
{
AIClient *ai = static_cast<AIClient*>( object );
ai->missionCycleCleanup();
@ -508,7 +508,7 @@ DefineConsoleMethod( AIClient, missionCycleCleanup, void, (),, "ai.missionCycleC
/**
* Sets the AI to run mode
*/
DefineConsoleMethod( AIClient, move, void, (),, "ai.move();" )
DefineEngineMethod( AIClient, move, void, (),, "ai.move();" )
{
AIClient *ai = static_cast<AIClient *>( object );
ai->setMoveMode( AIClient::ModeMove );
@ -517,7 +517,7 @@ DefineConsoleMethod( AIClient, move, void, (),, "ai.move();" )
/**
* Gets the AI's location in the world
*/
DefineConsoleMethod( AIClient, getLocation, Point3F, (),, "ai.getLocation();" )
DefineEngineMethod( AIClient, getLocation, Point3F, (),, "ai.getLocation();" )
{
AIClient *ai = static_cast<AIClient *>( object );
return ai->getLocation();
@ -559,7 +559,7 @@ DefineEngineFunction( aiAddPlayer, S32, (const char * name, const char * ns), ("
/**
* Tells the AI to move forward 100 units...TEST FXN
*/
DefineConsoleMethod( AIClient, moveForward, void, (),, "ai.moveForward();" )
DefineEngineMethod( AIClient, moveForward, void, (),, "ai.moveForward();" )
{
AIClient *ai = static_cast<AIClient *>( object );

View file

@ -160,7 +160,7 @@ ConsoleFunction(aiConnect, S32 , 2, 20, "(...)"
//-----------------------------------------------------------------------------
DefineConsoleMethod(AIConnection, setMove, void, (const char * field, F32 value), ,"(string field, float value)"
DefineEngineMethod(AIConnection, setMove, void, (const char * field, F32 value), ,"(string field, float value)"
"Set a field on the current move.\n\n"
"@param field One of {'x','y','z','yaw','pitch','roll'}\n"
"@param value Value to set field to.")
@ -190,7 +190,7 @@ DefineConsoleMethod(AIConnection, setMove, void, (const char * field, F32 value)
object->setMove(&move);
}
DefineConsoleMethod(AIConnection,getMove,F32, (const char * field), ,"(string field)"
DefineEngineMethod(AIConnection,getMove,F32, (const char * field), ,"(string field)"
"Get the given field of a move.\n\n"
"@param field One of {'x','y','z','yaw','pitch','roll'}\n"
"@returns The requested field on the current move.")
@ -212,7 +212,7 @@ DefineConsoleMethod(AIConnection,getMove,F32, (const char * field), ,"(string fi
}
DefineConsoleMethod(AIConnection,setFreeLook,void,(bool isFreeLook), ,"(bool isFreeLook)"
DefineEngineMethod(AIConnection,setFreeLook,void,(bool isFreeLook), ,"(bool isFreeLook)"
"Enable/disable freelook on the current move.")
{
Move move = object->getMove();
@ -220,7 +220,7 @@ DefineConsoleMethod(AIConnection,setFreeLook,void,(bool isFreeLook), ,"(bool isF
object->setMove(&move);
}
DefineConsoleMethod(AIConnection, getFreeLook, bool, (), ,"getFreeLook()"
DefineEngineMethod(AIConnection, getFreeLook, bool, (), ,"getFreeLook()"
"Is freelook on for the current move?")
{
return object->getMove().freeLook;
@ -229,7 +229,7 @@ DefineConsoleMethod(AIConnection, getFreeLook, bool, (), ,"getFreeLook()"
//-----------------------------------------------------------------------------
DefineConsoleMethod(AIConnection,setTrigger,void, (S32 idx, bool set), ,"(int trigger, bool set)"
DefineEngineMethod(AIConnection,setTrigger,void, (S32 idx, bool set), ,"(int trigger, bool set)"
"Set a trigger.")
{
if (idx >= 0 && idx < MaxTriggerKeys)
@ -240,7 +240,7 @@ DefineConsoleMethod(AIConnection,setTrigger,void, (S32 idx, bool set), ,"(int tr
}
}
DefineConsoleMethod(AIConnection,getTrigger,bool, (S32 idx), ,"(int trigger)"
DefineEngineMethod(AIConnection,getTrigger,bool, (S32 idx), ,"(int trigger)"
"Is the given trigger set?")
{
if (idx >= 0 && idx < MaxTriggerKeys)
@ -251,7 +251,7 @@ DefineConsoleMethod(AIConnection,getTrigger,bool, (S32 idx), ,"(int trigger)"
//-----------------------------------------------------------------------------
DefineConsoleMethod(AIConnection,getAddress,const char*,(), ,"")
DefineEngineMethod(AIConnection,getAddress,const char*,(), ,"")
{
// Override the netConnection method to return to indicate
// this is an ai connection.

View file

@ -1251,7 +1251,7 @@ ConsoleDocFragment _setAimObject(
"void setAimObject(GameBase targetObject, Point3F offset);"
);
DefineConsoleMethod( AIPlayer, setAimObject, void, ( const char * objName, Point3F offset ), (Point3F::Zero), "( GameBase obj, [Point3F offset] )"
DefineEngineMethod( AIPlayer, setAimObject, void, ( const char * objName, Point3F offset ), (Point3F::Zero), "( GameBase obj, [Point3F offset] )"
"Sets the bot's target object. Optionally set an offset from target location."
"@hide")
{

View file

@ -30,7 +30,7 @@ ConsoleMethod(CameraComponent, getMode, const char*, 2, 2, "() - We get the firs
return "fly";
}
DefineConsoleMethod(CameraComponent, getForwardVector, VectorF, (), ,
DefineEngineMethod(CameraComponent, getForwardVector, VectorF, (), ,
"Get the number of static fields on the object.\n"
"@return The number of static fields defined on the object.")
{
@ -44,7 +44,7 @@ DefineConsoleMethod(CameraComponent, getForwardVector, VectorF, (), ,
return returnVec;
}
DefineConsoleMethod(CameraComponent, getRightVector, VectorF, (), ,
DefineEngineMethod(CameraComponent, getRightVector, VectorF, (), ,
"Get the number of static fields on the object.\n"
"@return The number of static fields defined on the object.")
{
@ -58,7 +58,7 @@ DefineConsoleMethod(CameraComponent, getRightVector, VectorF, (), ,
return returnVec;
}
DefineConsoleMethod(CameraComponent, getUpVector, VectorF, (), ,
DefineEngineMethod(CameraComponent, getUpVector, VectorF, (), ,
"Get the number of static fields on the object.\n"
"@return The number of static fields defined on the object.")
{
@ -72,14 +72,14 @@ DefineConsoleMethod(CameraComponent, getUpVector, VectorF, (), ,
return returnVec;
}
DefineConsoleMethod(CameraComponent, setForwardVector, void, (VectorF newForward), (VectorF(0, 0, 0)),
DefineEngineMethod(CameraComponent, setForwardVector, void, (VectorF newForward), (VectorF(0, 0, 0)),
"Get the number of static fields on the object.\n"
"@return The number of static fields defined on the object.")
{
object->setForwardVector(newForward);
}
DefineConsoleMethod(CameraComponent, getWorldPosition, Point3F, (), ,
DefineEngineMethod(CameraComponent, getWorldPosition, Point3F, (), ,
"Get the number of static fields on the object.\n"
"@return The number of static fields defined on the object.")
{

View file

@ -24,21 +24,21 @@
#include "T3D/components/collision/collisionComponent.h"
#include "materials/baseMatInstance.h"
DefineConsoleMethod(CollisionComponent, getNumberOfContacts, S32, (), ,
DefineEngineMethod(CollisionComponent, getNumberOfContacts, S32, (), ,
"Gets the number of contacts this collider has hit.\n"
"@return The number of static fields defined on the object.")
{
return object->getCollisionList()->getCount();
}
DefineConsoleMethod(CollisionComponent, getBestContact, S32, (), ,
DefineEngineMethod(CollisionComponent, getBestContact, S32, (), ,
"Gets the number of contacts this collider has hit.\n"
"@return The number of static fields defined on the object.")
{
return 0;
}
DefineConsoleMethod(CollisionComponent, getContactNormal, Point3F, (), ,
DefineEngineMethod(CollisionComponent, getContactNormal, Point3F, (), ,
"Gets the number of contacts this collider has hit.\n"
"@return The number of static fields defined on the object.")
{
@ -53,7 +53,7 @@ DefineConsoleMethod(CollisionComponent, getContactNormal, Point3F, (), ,
return Point3F::Zero;
}
DefineConsoleMethod(CollisionComponent, getContactMaterial, S32, (), ,
DefineEngineMethod(CollisionComponent, getContactMaterial, S32, (), ,
"Gets the number of contacts this collider has hit.\n"
"@return The number of static fields defined on the object.")
{
@ -69,7 +69,7 @@ DefineConsoleMethod(CollisionComponent, getContactMaterial, S32, (), ,
return 0;
}
DefineConsoleMethod(CollisionComponent, getContactObject, S32, (), ,
DefineEngineMethod(CollisionComponent, getContactObject, S32, (), ,
"Gets the number of contacts this collider has hit.\n"
"@return The number of static fields defined on the object.")
{
@ -81,7 +81,7 @@ DefineConsoleMethod(CollisionComponent, getContactObject, S32, (), ,
return 0;
}
DefineConsoleMethod(CollisionComponent, getContactPoint, Point3F, (), ,
DefineEngineMethod(CollisionComponent, getContactPoint, Point3F, (), ,
"Gets the number of contacts this collider has hit.\n"
"@return The number of static fields defined on the object.")
{
@ -96,7 +96,7 @@ DefineConsoleMethod(CollisionComponent, getContactPoint, Point3F, (), ,
return Point3F::Zero;
}
DefineConsoleMethod(CollisionComponent, getContactTime, S32, (), ,
DefineEngineMethod(CollisionComponent, getContactTime, S32, (), ,
"Gets the number of contacts this collider has hit.\n"
"@return The number of static fields defined on the object.")
{

View file

@ -633,7 +633,7 @@ ConsoleMethod(Component, endGroup, void, 2, 2, "()\n"
object->endFieldGroup();
}
DefineConsoleMethod(Component, addComponentField, void, (String fieldName, String fieldDesc, String fieldType, String defValue, String userData, bool hidden),
DefineEngineMethod(Component, addComponentField, void, (String fieldName, String fieldDesc, String fieldType, String defValue, String userData, bool hidden),
("", "", "", "", "", false),
"Get the number of static fields on the object.\n"
"@return The number of static fields defined on the object.")
@ -678,7 +678,7 @@ ConsoleMethod(Component, setComponentield, const char *, 3, 3, "(int index) - Ge
return buf;
}
DefineConsoleMethod(Component, getComponentFieldType, const char *, (String fieldName), ,
DefineEngineMethod(Component, getComponentFieldType, const char *, (String fieldName), ,
"Get the number of static fields on the object.\n"
"@return The number of static fields defined on the object.")
{

View file

@ -1800,7 +1800,7 @@ DefineEngineMethod(Entity, setBox, void,
}
/*DefineConsoleMethod(Entity, callOnComponents, void, (const char* functionName), ,
/*DefineEngineMethod(Entity, callOnComponents, void, (const char* functionName), ,
"Get the number of static fields on the object.\n"
"@return The number of static fields defined on the object.")
{
@ -1875,7 +1875,7 @@ ConsoleMethod(Entity, getComponentByIndex, S32, 3, 3, "(int index) - Gets a part
return (comp != NULL) ? comp->getId() : 0;
}
DefineConsoleMethod(Entity, getComponent, S32, (String componentName), (""),
DefineEngineMethod(Entity, getComponent, S32, (String componentName), (""),
"Get the number of static fields on the object.\n"
"@return The number of static fields defined on the object.")
{
@ -1916,7 +1916,7 @@ ConsoleMethod(Entity, getComponentCount, S32, 2, 2, "() - Get the count of behav
return object->getComponentCount();
}
DefineConsoleMethod(Entity, setComponentDirty, void, (S32 componentID, bool forceUpdate), (0, false),
DefineEngineMethod(Entity, setComponentDirty, void, (S32 componentID, bool forceUpdate), (0, false),
"Get the number of static fields on the object.\n"
"@return The number of static fields defined on the object.")
{
@ -1925,7 +1925,7 @@ DefineConsoleMethod(Entity, setComponentDirty, void, (S32 componentID, bool forc
object->setComponentDirty(comp, forceUpdate);*/
}
DefineConsoleMethod(Entity, getMoveVector, VectorF, (),,
DefineEngineMethod(Entity, getMoveVector, VectorF, (),,
"Get the number of static fields on the object.\n"
"@return The number of static fields defined on the object.")
{
@ -1939,7 +1939,7 @@ DefineConsoleMethod(Entity, getMoveVector, VectorF, (),,
return VectorF::Zero;
}
DefineConsoleMethod(Entity, getMoveRotation, VectorF, (), ,
DefineEngineMethod(Entity, getMoveRotation, VectorF, (), ,
"Get the number of static fields on the object.\n"
"@return The number of static fields defined on the object.")
{
@ -1953,7 +1953,7 @@ DefineConsoleMethod(Entity, getMoveRotation, VectorF, (), ,
return VectorF::Zero;
}
DefineConsoleMethod(Entity, getMoveTrigger, bool, (S32 triggerNum), (0),
DefineEngineMethod(Entity, getMoveTrigger, bool, (S32 triggerNum), (0),
"Get the number of static fields on the object.\n"
"@return The number of static fields defined on the object.")
{
@ -1974,28 +1974,28 @@ DefineEngineMethod(Entity, getForwardVector, VectorF, (), ,
return forVec;
}
DefineConsoleMethod(Entity, setForwardVector, void, (VectorF newForward), (VectorF(0,0,0)),
DefineEngineMethod(Entity, setForwardVector, void, (VectorF newForward), (VectorF(0,0,0)),
"Get the number of static fields on the object.\n"
"@return The number of static fields defined on the object.")
{
object->setForwardVector(newForward);
}
DefineConsoleMethod(Entity, lookAt, void, (Point3F lookPosition),,
DefineEngineMethod(Entity, lookAt, void, (Point3F lookPosition),,
"Get the number of static fields on the object.\n"
"@return The number of static fields defined on the object.")
{
//object->setForwardVector(newForward);
}
DefineConsoleMethod(Entity, rotateTo, void, (Point3F lookPosition, F32 degreePerSecond), (1.0),
DefineEngineMethod(Entity, rotateTo, void, (Point3F lookPosition, F32 degreePerSecond), (1.0),
"Get the number of static fields on the object.\n"
"@return The number of static fields defined on the object.")
{
//object->setForwardVector(newForward);
}
DefineConsoleMethod(Entity, notify, void, (String signalFunction, String argA, String argB, String argC, String argD, String argE),
DefineEngineMethod(Entity, notify, void, (String signalFunction, String argA, String argB, String argC, String argD, String argE),
("", "", "", "", "", ""),
"Triggers a signal call to all components for a certain function.")
{

View file

@ -440,7 +440,7 @@ static ConsoleDocFragment _lbplayAnimation2(
"void playAnimation(LightAnimData anim);"
);
DefineConsoleMethod( LightBase, playAnimation, void, (const char * anim), (""), "( [LightAnimData anim] )\t"
DefineEngineMethod( LightBase, playAnimation, void, (const char * anim), (""), "( [LightAnimData anim] )\t"
"Plays a light animation on the light. If no LightAnimData is passed the "
"existing one is played."
"@hide")
@ -484,7 +484,7 @@ void LightBase::playAnimation( LightAnimData *animData )
}
}
DefineConsoleMethod( LightBase, pauseAnimation, void, (), , "Stops the light animation." )
DefineEngineMethod( LightBase, pauseAnimation, void, (), , "Stops the light animation." )
{
object->pauseAnimation();
}

View file

@ -494,7 +494,7 @@ ConsoleDocFragment _SpawnSpherespawnObject1(
"bool spawnObject(string additionalProps);"
);
DefineConsoleMethod(SpawnSphere, spawnObject, S32, (String additionalProps), ,
DefineEngineMethod(SpawnSphere, spawnObject, S32, (String additionalProps), ,
"([string additionalProps]) Spawns the object based on the SpawnSphere's "
"class, datablock, properties, and script settings. Allows you to pass in "
"extra properties."

View file

@ -238,7 +238,7 @@ void PhysicsDebrisData::unpackData(BitStream* stream)
shapeName = stream->readSTString();
}
DefineConsoleMethod( PhysicsDebrisData, preload, void, (), ,
DefineEngineMethod( PhysicsDebrisData, preload, void, (), ,
"@brief Loads some information to have readily available at simulation time.\n\n"
"Forces generation of shaders, materials, and other data used by the %PhysicsDebris object. "
"This function should be used while a level is loading in order to shorten "

View file

@ -314,7 +314,7 @@ void StaticShape::unpackUpdate(NetConnection *connection, BitStream *bstream)
// This appears to be legacy T2 stuff
// Marked internal, as this is flagged to be deleted
// [8/1/2010 mperry]
DefineConsoleMethod( StaticShape, setPoweredState, void, (bool isPowered), , "(bool isPowered)"
DefineEngineMethod( StaticShape, setPoweredState, void, (bool isPowered), , "(bool isPowered)"
"@internal")
{
if(!object->isServerObject())
@ -322,7 +322,7 @@ DefineConsoleMethod( StaticShape, setPoweredState, void, (bool isPowered), , "(b
object->setPowered(isPowered);
}
DefineConsoleMethod( StaticShape, getPoweredState, bool, (), , "@internal")
DefineEngineMethod( StaticShape, getPoweredState, bool, (), , "@internal")
{
if(!object->isServerObject())
return(false);

View file

@ -59,7 +59,7 @@ DefineEngineMethod(AssetQuery, set, bool, (S32 queryId), ,
//-----------------------------------------------------------------------------
DefineConsoleMethod(AssetQuery, getCount, S32, (), ,
DefineEngineMethod(AssetQuery, getCount, S32, (), ,
"Gets the count of asset Id results.\n"
"@return (int)The count of asset Id results.\n")
{
@ -68,7 +68,7 @@ DefineConsoleMethod(AssetQuery, getCount, S32, (), ,
//-----------------------------------------------------------------------------
DefineConsoleMethod(AssetQuery, getAsset, const char*, (S32 resultIndex), (-1),
DefineEngineMethod(AssetQuery, getAsset, const char*, (S32 resultIndex), (-1),
"Gets the asset Id at the specified query result index.\n"
"@param resultIndex The query result index to use.\n"
"@return (assetId)The asset Id at the specified index or NULL if not valid.\n")

View file

@ -571,7 +571,7 @@ DefineEngineMethod( SimXMLDocument, attribute, const char*, ( const char* attrib
}
// These two methods don't make a lot of sense the way TS works. Leaving them in for backwards-compatibility.
DefineConsoleMethod( SimXMLDocument, attributeF32, F32, (const char * attributeName), , "(string attributeName)"
DefineEngineMethod( SimXMLDocument, attributeF32, F32, (const char * attributeName), , "(string attributeName)"
"@brief Get float attribute from the current Element on the stack.\n\n"
"@param attributeName Name of attribute to retrieve.\n"
"@return The value of the given attribute in the form of a float.\n"
@ -580,7 +580,7 @@ DefineConsoleMethod( SimXMLDocument, attributeF32, F32, (const char * attributeN
return dAtof( object->attribute( attributeName ) );
}
DefineConsoleMethod(SimXMLDocument, attributeS32, S32, (const char * attributeName), , "(string attributeName)"
DefineEngineMethod(SimXMLDocument, attributeS32, S32, (const char * attributeName), , "(string attributeName)"
"@brief Get int attribute from the current Element on the stack.\n\n"
"@param attributeName Name of attribute to retrieve.\n"
"@return The value of the given attribute in the form of an integer.\n"

View file

@ -225,7 +225,7 @@ void ConsoleLogger::log( const char *consoleLine )
//-----------------------------------------------------------------------------
DefineConsoleMethod( ConsoleLogger, attach, bool, (), , "() Attaches the logger to the console and begins writing to file"
DefineEngineMethod( ConsoleLogger, attach, bool, (), , "() Attaches the logger to the console and begins writing to file"
"@tsexample\n"
"// Create the logger\n"
"// Will automatically start writing to testLogging.txt with normal priority\n"
@ -247,7 +247,7 @@ DefineConsoleMethod( ConsoleLogger, attach, bool, (), , "() Attaches the logger
//-----------------------------------------------------------------------------
DefineConsoleMethod( ConsoleLogger, detach, bool, (), , "() Detaches the logger from the console and stops writing to file"
DefineEngineMethod( ConsoleLogger, detach, bool, (), , "() Detaches the logger from the console and stops writing to file"
"@tsexample\n"
"// Create the logger\n"
"// Will automatically start writing to testLogging.txt with normal priority\n"

View file

@ -861,7 +861,7 @@ public:
// these macros can be removed and all definitions that make use of them can be removed
// as well.
#define DefineConsoleMethod( className, name, returnType, args, defaultArgs, usage ) \
#define DefineEngineMethod( className, name, returnType, args, defaultArgs, usage ) \
struct _ ## className ## name ## frame \
{ \
typedef className ObjectType; \

View file

@ -123,7 +123,7 @@ static char* suppressSpaces(const char* in_pname)
//-----------------------------------------------------------------------------
// Query Groups.
//-----------------------------------------------------------------------------
DefineConsoleMethod(FieldBrushObject, queryGroups, const char*, (const char* simObjName), , "(simObject) Query available static-field groups for selected object./\n"
DefineEngineMethod(FieldBrushObject, queryGroups, const char*, (const char* simObjName), , "(simObject) Query available static-field groups for selected object./\n"
"@param simObject Object to query static-field groups on.\n"
"@return Space-seperated static-field group list.")
{
@ -191,7 +191,7 @@ DefineConsoleMethod(FieldBrushObject, queryGroups, const char*, (const char* sim
//-----------------------------------------------------------------------------
// Query Fields.
//-----------------------------------------------------------------------------
DefineConsoleMethod(FieldBrushObject, queryFields, const char*, (const char* simObjName, const char* groupList), (""), "(simObject, [groupList]) Query available static-fields for selected object./\n"
DefineEngineMethod(FieldBrushObject, queryFields, const char*, (const char* simObjName, const char* groupList), (""), "(simObject, [groupList]) Query available static-fields for selected object./\n"
"@param simObject Object to query static-fields on.\n"
"@param groupList groups to filter static-fields against.\n"
"@return Space-seperated static-field list.")
@ -366,7 +366,7 @@ DefineConsoleMethod(FieldBrushObject, queryFields, const char*, (const char* sim
//-----------------------------------------------------------------------------
// Copy Fields.
//-----------------------------------------------------------------------------
DefineConsoleMethod(FieldBrushObject, copyFields, void, (const char* simObjName, const char* pFieldList), (""), "(simObject, [fieldList]) Copy selected static-fields for selected object./\n"
DefineEngineMethod(FieldBrushObject, copyFields, void, (const char* simObjName, const char* pFieldList), (""), "(simObject, [fieldList]) Copy selected static-fields for selected object./\n"
"@param simObject Object to copy static-fields from.\n"
"@param fieldList fields to filter static-fields against.\n"
"@return No return value.")
@ -500,7 +500,7 @@ void FieldBrushObject::copyFields( SimObject* pSimObject, const char* fieldList
//-----------------------------------------------------------------------------
// Paste Fields.
//-----------------------------------------------------------------------------
DefineConsoleMethod(FieldBrushObject, pasteFields, void, (const char* simObjName), , "(simObject) Paste copied static-fields to selected object./\n"
DefineEngineMethod(FieldBrushObject, pasteFields, void, (const char* simObjName), , "(simObject) Paste copied static-fields to selected object./\n"
"@param simObject Object to paste static-fields to.\n"
"@return No return value.")
{

View file

@ -2190,14 +2190,14 @@ void PersistenceManager::deleteObjectsFromFile(const char* fileName)
clearAll();
}
DefineConsoleMethod( PersistenceManager, deleteObjectsFromFile, void, ( const char * fileName ), , "( fileName )"
DefineEngineMethod( PersistenceManager, deleteObjectsFromFile, void, ( const char * fileName ), , "( fileName )"
"Delete all of the objects that are created from the given file." )
{
// Delete Objects.
object->deleteObjectsFromFile( fileName );
}
DefineConsoleMethod( PersistenceManager, setDirty, void, ( const char * objName, const char * fileName ), (""), "(SimObject object, [filename])"
DefineEngineMethod( PersistenceManager, setDirty, void, ( const char * objName, const char * fileName ), (""), "(SimObject object, [filename])"
"Mark an existing SimObject as dirty (will be written out when saveDirty() is called).")
{
SimObject *dirtyObject = NULL;
@ -2226,7 +2226,7 @@ DefineConsoleMethod( PersistenceManager, setDirty, void, ( const char * objName
}
}
DefineConsoleMethod( PersistenceManager, removeDirty, void, ( const char * objName ), , "(SimObject object)"
DefineEngineMethod( PersistenceManager, removeDirty, void, ( const char * objName ), , "(SimObject object)"
"Remove a SimObject from the dirty list.")
{
SimObject *dirtyObject = NULL;
@ -2243,7 +2243,7 @@ DefineConsoleMethod( PersistenceManager, removeDirty, void, ( const char * objNa
object->removeDirty(dirtyObject);
}
DefineConsoleMethod( PersistenceManager, isDirty, bool, ( const char * objName ), , "(SimObject object)"
DefineEngineMethod( PersistenceManager, isDirty, bool, ( const char * objName ), , "(SimObject object)"
"Returns true if the SimObject is on the dirty list.")
{
SimObject *dirtyObject = NULL;
@ -2262,19 +2262,19 @@ DefineConsoleMethod( PersistenceManager, isDirty, bool, ( const char * objName )
return false;
}
DefineConsoleMethod( PersistenceManager, hasDirty, bool, (), , "()"
DefineEngineMethod( PersistenceManager, hasDirty, bool, (), , "()"
"Returns true if the manager has dirty objects to save." )
{
return object->hasDirty();
}
DefineConsoleMethod( PersistenceManager, getDirtyObjectCount, S32, (), , "()"
DefineEngineMethod( PersistenceManager, getDirtyObjectCount, S32, (), , "()"
"Returns the number of dirty objects." )
{
return object->getDirtyList().size();
}
DefineConsoleMethod( PersistenceManager, getDirtyObject, S32, (S32 index), , "( index )"
DefineEngineMethod( PersistenceManager, getDirtyObject, S32, (S32 index), , "( index )"
"Returns the ith dirty object." )
{
if ( index < 0 || index >= object->getDirtyList().size() )
@ -2290,7 +2290,7 @@ DefineConsoleMethod( PersistenceManager, getDirtyObject, S32, (S32 index), , "(
return ( dirtyObject.getObject() ) ? dirtyObject.getObject()->getId() : 0;
}
DefineConsoleMethod( PersistenceManager, listDirty, void, (), , "()"
DefineEngineMethod( PersistenceManager, listDirty, void, (), , "()"
"Prints the dirty list to the console.")
{
const PersistenceManager::DirtyList dirtyList = object->getDirtyList();
@ -2318,13 +2318,13 @@ DefineConsoleMethod( PersistenceManager, listDirty, void, (), , "()"
}
}
DefineConsoleMethod( PersistenceManager, saveDirty, bool, (), , "()"
DefineEngineMethod( PersistenceManager, saveDirty, bool, (), , "()"
"Saves all of the SimObject's on the dirty list to their respective files.")
{
return object->saveDirty();
}
DefineConsoleMethod( PersistenceManager, saveDirtyObject, bool, (const char * objName), , "(SimObject object)"
DefineEngineMethod( PersistenceManager, saveDirtyObject, bool, (const char * objName), , "(SimObject object)"
"Save a dirty SimObject to it's file.")
{
SimObject *dirtyObject = NULL;
@ -2342,13 +2342,13 @@ DefineConsoleMethod( PersistenceManager, saveDirtyObject, bool, (const char * ob
return false;
}
DefineConsoleMethod( PersistenceManager, clearAll, void, (), , "()"
DefineEngineMethod( PersistenceManager, clearAll, void, (), , "()"
"Clears all the tracked objects without saving them." )
{
object->clearAll();
}
DefineConsoleMethod( PersistenceManager, removeObjectFromFile, void, (const char * objName, const char * filename),("") , "(SimObject object, [filename])"
DefineEngineMethod( PersistenceManager, removeObjectFromFile, void, (const char * objName, const char * filename),("") , "(SimObject object, [filename])"
"Remove an existing SimObject from a file (can optionally specify a different file than \
the one it was created in.")
{
@ -2371,7 +2371,7 @@ DefineConsoleMethod( PersistenceManager, removeObjectFromFile, void, (const char
}
}
DefineConsoleMethod( PersistenceManager, removeField, void, (const char * objName, const char * fieldName), , "(SimObject object, string fieldName)"
DefineEngineMethod( PersistenceManager, removeField, void, (const char * objName, const char * fieldName), , "(SimObject object, string fieldName)"
"Remove a specific field from an object declaration.")
{
SimObject *dirtyObject = NULL;

View file

@ -428,7 +428,7 @@ void SimDataBlock::write(Stream &stream, U32 tabStop, U32 flags)
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimDataBlock, reloadOnLocalClient, void, (),,
DefineEngineMethod( SimDataBlock, reloadOnLocalClient, void, (),,
"Reload the datablock. This can only be used with a local client configuration." )
{
// Make sure we're running a local client.

View file

@ -2271,7 +2271,7 @@ DefineEngineMethod( SimObject, dumpGroupHierarchy, void, (),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, isMethod, bool, ( const char* methodName ),,
DefineEngineMethod( SimObject, isMethod, bool, ( const char* methodName ),,
"Test whether the given method is defined on this object.\n"
"@param The name of the method.\n"
"@return True if the object implements the given method." )
@ -2291,7 +2291,7 @@ DefineEngineMethod( SimObject, isChildOfGroup, bool, ( SimGroup* group ),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, getClassNamespace, const char*, (),,
DefineEngineMethod( SimObject, getClassNamespace, const char*, (),,
"Get the name of the class namespace assigned to this object.\n"
"@return The name of the 'class' namespace." )
{
@ -2300,7 +2300,7 @@ DefineConsoleMethod( SimObject, getClassNamespace, const char*, (),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, getSuperClassNamespace, const char*, (),,
DefineEngineMethod( SimObject, getSuperClassNamespace, const char*, (),,
"Get the name of the superclass namespace assigned to this object.\n"
"@return The name of the 'superClass' namespace." )
{
@ -2309,7 +2309,7 @@ DefineConsoleMethod( SimObject, getSuperClassNamespace, const char*, (),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, setClassNamespace, void, ( const char* name ),,
DefineEngineMethod( SimObject, setClassNamespace, void, ( const char* name ),,
"Assign a class namespace to this object.\n"
"@param name The name of the 'class' namespace for this object." )
{
@ -2318,7 +2318,7 @@ DefineConsoleMethod( SimObject, setClassNamespace, void, ( const char* name ),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, setSuperClassNamespace, void, ( const char* name ),,
DefineEngineMethod( SimObject, setSuperClassNamespace, void, ( const char* name ),,
"Assign a superclass namespace to this object.\n"
"@param name The name of the 'superClass' namespace for this object." )
{
@ -2345,7 +2345,7 @@ DefineEngineMethod( SimObject, setIsSelected, void, ( bool state ), ( true ),
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, isExpanded, bool, (),,
DefineEngineMethod( SimObject, isExpanded, bool, (),,
"Get whether the object has been marked as expanded. (in editor)\n"
"@return True if the object is marked expanded." )
{
@ -2354,7 +2354,7 @@ DefineConsoleMethod( SimObject, isExpanded, bool, (),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, setIsExpanded, void, ( bool state ), ( true ),
DefineEngineMethod( SimObject, setIsExpanded, void, ( bool state ), ( true ),
"Set whether the object has been marked as expanded. (in editor)\n"
"@param state True if the object is to be marked expanded; false if not." )
{
@ -2363,7 +2363,7 @@ DefineConsoleMethod( SimObject, setIsExpanded, void, ( bool state ), ( true ),
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, getFilename, const char*, (),,
DefineEngineMethod( SimObject, getFilename, const char*, (),,
"Returns the filename the object is attached to.\n"
"@return The name of the file the object is associated with; usually the file the object was loaded from." )
{
@ -2372,7 +2372,7 @@ DefineConsoleMethod( SimObject, getFilename, const char*, (),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, setFilename, void, ( const char* fileName ),,
DefineEngineMethod( SimObject, setFilename, void, ( const char* fileName ),,
"Sets the object's file name and path\n"
"@param fileName The name of the file to associate this object with." )
{
@ -2381,7 +2381,7 @@ DefineConsoleMethod( SimObject, setFilename, void, ( const char* fileName ),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, getDeclarationLine, S32, (),,
DefineEngineMethod( SimObject, getDeclarationLine, S32, (),,
"Get the line number at which the object is defined in its file.\n\n"
"@return The line number of the object's definition in script.\n"
"@see getFilename()")
@ -2418,7 +2418,7 @@ DefineEngineFunction( debugEnumInstances, void, ( const char* className, const c
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, assignFieldsFrom, void, ( SimObject* fromObject ),,
DefineEngineMethod( SimObject, assignFieldsFrom, void, ( SimObject* fromObject ),,
"Copy fields from another object onto this one. The objects must "
"be of same type. Everything from the object will overwrite what's "
"in this object; extra fields in this object will remain. This "
@ -2439,7 +2439,7 @@ DefineEngineMethod( SimObject, assignPersistentId, void, (),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, getCanSave, bool, (),,
DefineEngineMethod( SimObject, getCanSave, bool, (),,
"Get whether the object will be included in saves.\n"
"@return True if the object will be saved; false otherwise." )
{
@ -2448,7 +2448,7 @@ DefineConsoleMethod( SimObject, getCanSave, bool, (),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, setCanSave, void, ( bool value ), ( true ),
DefineEngineMethod( SimObject, setCanSave, void, ( bool value ), ( true ),
"Set whether the object will be included in saves.\n"
"@param value If true, the object will be included in saves; if false, it will be excluded." )
{
@ -2529,7 +2529,7 @@ DefineEngineMethod( SimObject, setHidden, void, ( bool value ), ( true ),
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, dumpMethods, ArrayObject*, (),,
DefineEngineMethod( SimObject, dumpMethods, ArrayObject*, (),,
"List the methods defined on this object.\n\n"
"Each description is a newline-separated vector with the following elements:\n"
"- Minimum number of arguments.\n"
@ -2776,7 +2776,7 @@ DefineEngineMethod( SimObject, dump, void, ( bool detailed ), ( false ),
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, save, bool, ( const char* fileName, bool selectedOnly, const char* preAppendString ), ( false, "" ),
DefineEngineMethod( SimObject, save, bool, ( const char* fileName, bool selectedOnly, const char* preAppendString ), ( false, "" ),
"Save out the object to the given file.\n"
"@param fileName The name of the file to save to."
"@param selectedOnly If true, only objects marked as selected will be saved out.\n"
@ -2808,7 +2808,7 @@ DefineEngineMethod( SimObject, getName, const char*, (),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, getClassName, const char*, (),,
DefineEngineMethod( SimObject, getClassName, const char*, (),,
"Get the name of the C++ class which the object is an instance of.\n"
"@return The name of the C++ class of the object." )
{
@ -2818,7 +2818,7 @@ DefineConsoleMethod( SimObject, getClassName, const char*, (),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, isField, bool, ( const char* fieldName ),,
DefineEngineMethod( SimObject, isField, bool, ( const char* fieldName ),,
"Test whether the given field is defined on this object.\n"
"@param fieldName The name of the field.\n"
"@return True if the object implements the given field." )
@ -2828,7 +2828,7 @@ DefineConsoleMethod( SimObject, isField, bool, ( const char* fieldName ),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, getFieldValue, const char*, ( const char* fieldName, S32 index ), ( -1 ),
DefineEngineMethod( SimObject, getFieldValue, const char*, ( const char* fieldName, S32 index ), ( -1 ),
"Return the value of the given field on this object.\n"
"@param fieldName The name of the field. If it includes a field index, the index is parsed out.\n"
"@param index Optional parameter to specify the index of an array field separately.\n"
@ -2872,7 +2872,7 @@ DefineConsoleMethod( SimObject, getFieldValue, const char*, ( const char* fieldN
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, setFieldValue, bool, ( const char* fieldName, const char* value, S32 index ), ( -1 ),
DefineEngineMethod( SimObject, setFieldValue, bool, ( const char* fieldName, const char* value, S32 index ), ( -1 ),
"Set the value of the given field on this object.\n"
"@param fieldName The name of the field to assign to. If it includes an array index, the index will be parsed out.\n"
"@param value The new value to assign to the field.\n"
@ -2919,7 +2919,7 @@ DefineConsoleMethod( SimObject, setFieldValue, bool, ( const char* fieldName, co
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, getFieldType, const char*, ( const char* fieldName ),,
DefineEngineMethod( SimObject, getFieldType, const char*, ( const char* fieldName ),,
"Get the console type code of the given field.\n"
"@return The numeric type code for the underlying console type of the given field." )
{
@ -2934,7 +2934,7 @@ DefineConsoleMethod( SimObject, getFieldType, const char*, ( const char* fieldNa
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, setFieldType, void, ( const char* fieldName, const char* type ),,
DefineEngineMethod( SimObject, setFieldType, void, ( const char* fieldName, const char* type ),,
"Set the console type code for the given field.\n"
"@param fieldName The name of the dynamic field to change to type for.\n"
"@param type The name of the console type.\n"
@ -2974,7 +2974,7 @@ DefineEngineMethod( SimObject, getInternalName, const char*, (),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, dumpClassHierarchy, void, (),,
DefineEngineMethod( SimObject, dumpClassHierarchy, void, (),,
"Dump the native C++ class hierarchy of this object's C++ class to the console." )
{
object->dumpClassHierarchy();
@ -2982,7 +2982,7 @@ DefineConsoleMethod( SimObject, dumpClassHierarchy, void, (),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, isMemberOfClass, bool, ( const char* className ),,
DefineEngineMethod( SimObject, isMemberOfClass, bool, ( const char* className ),,
"Test whether this object is a member of the specified class.\n"
"@param className Name of a native C++ class.\n"
"@return True if this object is an instance of the given C++ class or any of its super classes." )
@ -3004,7 +3004,7 @@ DefineConsoleMethod( SimObject, isMemberOfClass, bool, ( const char* className )
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, isInNamespaceHierarchy, bool, ( const char* name ),,
DefineEngineMethod( SimObject, isInNamespaceHierarchy, bool, ( const char* name ),,
"Test whether the namespace of this object is a direct or indirect child to the given namespace.\n"
"@param name The name of a namespace.\n"
"@return True if the given namespace name is within the namespace hierarchy of this object." )
@ -3039,7 +3039,7 @@ DefineEngineMethod( SimObject, getGroup, SimGroup*, (),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, delete, void, (),,
DefineEngineMethod( SimObject, delete, void, (),,
"Delete and remove the object." )
{
object->deleteObject();
@ -3067,7 +3067,7 @@ ConsoleMethod( SimObject,schedule, S32, 4, 0, "( float time, string method, stri
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, getDynamicFieldCount, S32, (),,
DefineEngineMethod( SimObject, getDynamicFieldCount, S32, (),,
"Get the number of dynamic fields defined on the object.\n"
"@return The number of dynamic fields defined on the object." )
{
@ -3081,7 +3081,7 @@ DefineConsoleMethod( SimObject, getDynamicFieldCount, S32, (),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, getDynamicField, const char*, ( S32 index ),,
DefineEngineMethod( SimObject, getDynamicField, const char*, ( S32 index ),,
"Get a value of a dynamic field by index.\n"
"@param index The index of the dynamic field.\n"
"@return The value of the dynamic field at the given index or \"\"." )
@ -3113,7 +3113,7 @@ DefineConsoleMethod( SimObject, getDynamicField, const char*, ( S32 index ),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, getFieldCount, S32, (),,
DefineEngineMethod( SimObject, getFieldCount, S32, (),,
"Get the number of static fields on the object.\n"
"@return The number of static fields defined on the object." )
{
@ -3135,7 +3135,7 @@ DefineConsoleMethod( SimObject, getFieldCount, S32, (),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimObject, getField, const char*, ( S32 index ),,
DefineEngineMethod( SimObject, getField, const char*, ( S32 index ),,
"Retrieve the value of a static field by index.\n"
"@param index The index of the static field.\n"
"@return The value of the static field with the given index or \"\"." )

View file

@ -187,7 +187,7 @@ void SimPersistSet::addObject( SimObject* object )
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimPersistSet, resolvePersistentIds, void, (), , "() - Try to bind unresolved persistent IDs in the set." )
DefineEngineMethod( SimPersistSet, resolvePersistentIds, void, (), , "() - Try to bind unresolved persistent IDs in the set." )
{
object->resolvePIDs();
}

View file

@ -954,7 +954,7 @@ DefineEngineMethod( SimSet, clear, void, (),,
//-----------------------------------------------------------------------------
//UNSAFE; don't want this in the new API
DefineConsoleMethod( SimSet, deleteAllObjects, void, (), , "() Delete all objects in the set." )
DefineEngineMethod( SimSet, deleteAllObjects, void, (), , "() Delete all objects in the set." )
{
object->deleteAllObjects();
}
@ -1026,7 +1026,7 @@ DEFINE_CALLIN( fnSimSet_getCountRecursive, getCountRecursive, SimSet, U32, ( Sim
return set->sizeRecursive();
}
DefineConsoleMethod( SimSet, getFullCount, S32, (), , "() Get the number of direct and indirect child objects contained in the set.\n"
DefineEngineMethod( SimSet, getFullCount, S32, (), , "() Get the number of direct and indirect child objects contained in the set.\n"
"@return The number of objects contained in the set as well as in other sets contained directly or indirectly in the set." )
{
return object->sizeRecursive();
@ -1122,7 +1122,7 @@ DefineEngineMethod( SimSet, pushToBack, void, ( SimObject* obj ),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( SimSet, sort, void, ( const char * callbackFunction ), , "( string callbackFunction ) Sort the objects in the set using the given comparison function.\n"
DefineEngineMethod( SimSet, sort, void, ( const char * callbackFunction ), , "( string callbackFunction ) Sort the objects in the set using the given comparison function.\n"
"@param callbackFunction Name of a function that takes two object arguments A and B and returns -1 if A is less, 1 if B is less, and 0 if both are equal." )
{
object->scriptSort( callbackFunction );

View file

@ -484,7 +484,7 @@ static ConsoleDocFragment _FileObjectwriteObject2(
"FileObject",
"void writeObject( SimObject* object, string prepend);");
DefineConsoleMethod( FileObject, writeObject, void, (const char * simName, const char * objName), (""), "FileObject.writeObject(SimObject, object prepend)"
DefineEngineMethod( FileObject, writeObject, void, (const char * simName, const char * objName), (""), "FileObject.writeObject(SimObject, object prepend)"
"@hide")
{
SimObject* obj = Sim::findObject( simName );

View file

@ -1185,67 +1185,67 @@ void GuiMeshRoadEditorCtrl::matchTerrainToRoad()
// with the terrain underneath it.
}
DefineConsoleMethod( GuiMeshRoadEditorCtrl, deleteNode, void, (), , "deleteNode()" )
DefineEngineMethod( GuiMeshRoadEditorCtrl, deleteNode, void, (), , "deleteNode()" )
{
object->deleteSelectedNode();
}
DefineConsoleMethod( GuiMeshRoadEditorCtrl, getMode, const char*, (), , "" )
DefineEngineMethod( GuiMeshRoadEditorCtrl, getMode, const char*, (), , "" )
{
return object->getMode();
}
DefineConsoleMethod( GuiMeshRoadEditorCtrl, setMode, void, (const char * mode), , "setMode( String mode )" )
DefineEngineMethod( GuiMeshRoadEditorCtrl, setMode, void, (const char * mode), , "setMode( String mode )" )
{
String newMode = ( mode );
object->setMode( newMode );
}
DefineConsoleMethod( GuiMeshRoadEditorCtrl, getNodeWidth, F32, (), , "" )
DefineEngineMethod( GuiMeshRoadEditorCtrl, getNodeWidth, F32, (), , "" )
{
return object->getNodeWidth();
}
DefineConsoleMethod( GuiMeshRoadEditorCtrl, setNodeWidth, void, ( F32 width ), , "" )
DefineEngineMethod( GuiMeshRoadEditorCtrl, setNodeWidth, void, ( F32 width ), , "" )
{
object->setNodeWidth( width );
}
DefineConsoleMethod( GuiMeshRoadEditorCtrl, getNodeDepth, F32, (), , "" )
DefineEngineMethod( GuiMeshRoadEditorCtrl, getNodeDepth, F32, (), , "" )
{
return object->getNodeDepth();
}
DefineConsoleMethod( GuiMeshRoadEditorCtrl, setNodeDepth, void, ( F32 depth ), , "" )
DefineEngineMethod( GuiMeshRoadEditorCtrl, setNodeDepth, void, ( F32 depth ), , "" )
{
object->setNodeDepth( depth );
}
DefineConsoleMethod( GuiMeshRoadEditorCtrl, getNodePosition, Point3F, (), , "" )
DefineEngineMethod( GuiMeshRoadEditorCtrl, getNodePosition, Point3F, (), , "" )
{
return object->getNodePosition();
}
DefineConsoleMethod( GuiMeshRoadEditorCtrl, setNodePosition, void, (Point3F pos), , "" )
DefineEngineMethod( GuiMeshRoadEditorCtrl, setNodePosition, void, (Point3F pos), , "" )
{
object->setNodePosition( pos );
}
DefineConsoleMethod( GuiMeshRoadEditorCtrl, getNodeNormal, Point3F, (), , "" )
DefineEngineMethod( GuiMeshRoadEditorCtrl, getNodeNormal, Point3F, (), , "" )
{
return object->getNodeNormal();
}
DefineConsoleMethod( GuiMeshRoadEditorCtrl, setNodeNormal, void, (Point3F normal), , "" )
DefineEngineMethod( GuiMeshRoadEditorCtrl, setNodeNormal, void, (Point3F normal), , "" )
{
object->setNodeNormal( normal );
}
DefineConsoleMethod( GuiMeshRoadEditorCtrl, setSelectedRoad, void, (const char * objName), (""), "" )
DefineEngineMethod( GuiMeshRoadEditorCtrl, setSelectedRoad, void, (const char * objName), (""), "" )
{
if ( String::isEmpty(objName) )
object->setSelectedRoad(NULL);
@ -1257,7 +1257,7 @@ DefineConsoleMethod( GuiMeshRoadEditorCtrl, setSelectedRoad, void, (const char *
}
}
DefineConsoleMethod( GuiMeshRoadEditorCtrl, getSelectedRoad, S32, (), , "" )
DefineEngineMethod( GuiMeshRoadEditorCtrl, getSelectedRoad, S32, (), , "" )
{
MeshRoad *road = object->getSelectedRoad();
if ( !road )
@ -1266,14 +1266,14 @@ DefineConsoleMethod( GuiMeshRoadEditorCtrl, getSelectedRoad, S32, (), , "" )
return road->getId();
}
DefineConsoleMethod( GuiMeshRoadEditorCtrl, regenerate, void, (), , "" )
DefineEngineMethod( GuiMeshRoadEditorCtrl, regenerate, void, (), , "" )
{
MeshRoad *road = object->getSelectedRoad();
if ( road )
road->regenerate();
}
DefineConsoleMethod( GuiMeshRoadEditorCtrl, matchTerrainToRoad, void, (), , "" )
DefineEngineMethod( GuiMeshRoadEditorCtrl, matchTerrainToRoad, void, (), , "" )
{
object->matchTerrainToRoad();
}

View file

@ -1393,66 +1393,66 @@ void GuiRiverEditorCtrl::_renderSelectedRiver( ObjectRenderInst *ri, SceneRender
}
}
DefineConsoleMethod( GuiRiverEditorCtrl, deleteNode, void, (), , "deleteNode()" )
DefineEngineMethod( GuiRiverEditorCtrl, deleteNode, void, (), , "deleteNode()" )
{
object->deleteSelectedNode();
}
DefineConsoleMethod( GuiRiverEditorCtrl, getMode, const char*, (), , "" )
DefineEngineMethod( GuiRiverEditorCtrl, getMode, const char*, (), , "" )
{
return object->getMode();
}
DefineConsoleMethod( GuiRiverEditorCtrl, setMode, void, ( const char * mode ), , "setMode( String mode )" )
DefineEngineMethod( GuiRiverEditorCtrl, setMode, void, ( const char * mode ), , "setMode( String mode )" )
{
String newMode = ( mode );
object->setMode( newMode );
}
DefineConsoleMethod( GuiRiverEditorCtrl, getNodeWidth, F32, (), , "" )
DefineEngineMethod( GuiRiverEditorCtrl, getNodeWidth, F32, (), , "" )
{
return object->getNodeWidth();
}
DefineConsoleMethod( GuiRiverEditorCtrl, setNodeWidth, void, ( F32 width ), , "" )
DefineEngineMethod( GuiRiverEditorCtrl, setNodeWidth, void, ( F32 width ), , "" )
{
object->setNodeWidth( width );
}
DefineConsoleMethod( GuiRiverEditorCtrl, getNodeDepth, F32, (), , "" )
DefineEngineMethod( GuiRiverEditorCtrl, getNodeDepth, F32, (), , "" )
{
return object->getNodeDepth();
}
DefineConsoleMethod( GuiRiverEditorCtrl, setNodeDepth, void, ( F32 depth ), , "" )
DefineEngineMethod( GuiRiverEditorCtrl, setNodeDepth, void, ( F32 depth ), , "" )
{
object->setNodeDepth( depth );
}
DefineConsoleMethod( GuiRiverEditorCtrl, getNodePosition, Point3F, (), , "" )
DefineEngineMethod( GuiRiverEditorCtrl, getNodePosition, Point3F, (), , "" )
{
return object->getNodePosition();
}
DefineConsoleMethod( GuiRiverEditorCtrl, setNodePosition, void, (Point3F pos), , "" )
DefineEngineMethod( GuiRiverEditorCtrl, setNodePosition, void, (Point3F pos), , "" )
{
object->setNodePosition( pos );
}
DefineConsoleMethod( GuiRiverEditorCtrl, getNodeNormal, Point3F, (), , "" )
DefineEngineMethod( GuiRiverEditorCtrl, getNodeNormal, Point3F, (), , "" )
{
return object->getNodeNormal();
}
DefineConsoleMethod( GuiRiverEditorCtrl, setNodeNormal, void, (Point3F normal), , "" )
DefineEngineMethod( GuiRiverEditorCtrl, setNodeNormal, void, (Point3F normal), , "" )
{
object->setNodeNormal( normal );
}
DefineConsoleMethod( GuiRiverEditorCtrl, setSelectedRiver, void, (const char * objName), (""), "" )
DefineEngineMethod( GuiRiverEditorCtrl, setSelectedRiver, void, (const char * objName), (""), "" )
{
if (dStrcmp( objName,"" )==0)
object->setSelectedRiver(NULL);
@ -1464,7 +1464,7 @@ DefineConsoleMethod( GuiRiverEditorCtrl, setSelectedRiver, void, (const char * o
}
}
DefineConsoleMethod( GuiRiverEditorCtrl, getSelectedRiver, S32, (), , "" )
DefineEngineMethod( GuiRiverEditorCtrl, getSelectedRiver, S32, (), , "" )
{
River *river = object->getSelectedRiver();
if ( !river )
@ -1473,7 +1473,7 @@ DefineConsoleMethod( GuiRiverEditorCtrl, getSelectedRiver, S32, (), , "" )
return river->getId();
}
DefineConsoleMethod( GuiRiverEditorCtrl, regenerate, void, (), , "" )
DefineEngineMethod( GuiRiverEditorCtrl, regenerate, void, (), , "" )
{
River *river = object->getSelectedRiver();
if ( river )

View file

@ -1037,45 +1037,45 @@ void GuiRoadEditorCtrl::submitUndo( const UTF8 *name )
undoMan->addAction( action );
}
DefineConsoleMethod( GuiRoadEditorCtrl, deleteNode, void, (), , "deleteNode()" )
DefineEngineMethod( GuiRoadEditorCtrl, deleteNode, void, (), , "deleteNode()" )
{
object->deleteSelectedNode();
}
DefineConsoleMethod( GuiRoadEditorCtrl, getMode, const char*, (), , "" )
DefineEngineMethod( GuiRoadEditorCtrl, getMode, const char*, (), , "" )
{
return object->getMode();
}
DefineConsoleMethod( GuiRoadEditorCtrl, setMode, void, ( const char * mode ), , "setMode( String mode )" )
DefineEngineMethod( GuiRoadEditorCtrl, setMode, void, ( const char * mode ), , "setMode( String mode )" )
{
String newMode = ( mode );
object->setMode( newMode );
}
DefineConsoleMethod( GuiRoadEditorCtrl, getNodeWidth, F32, (), , "" )
DefineEngineMethod( GuiRoadEditorCtrl, getNodeWidth, F32, (), , "" )
{
return object->getNodeWidth();
}
DefineConsoleMethod( GuiRoadEditorCtrl, setNodeWidth, void, ( F32 width ), , "" )
DefineEngineMethod( GuiRoadEditorCtrl, setNodeWidth, void, ( F32 width ), , "" )
{
object->setNodeWidth( width );
}
DefineConsoleMethod( GuiRoadEditorCtrl, getNodePosition, Point3F, (), , "" )
DefineEngineMethod( GuiRoadEditorCtrl, getNodePosition, Point3F, (), , "" )
{
return object->getNodePosition();
}
DefineConsoleMethod( GuiRoadEditorCtrl, setNodePosition, void, ( Point3F pos ), , "" )
DefineEngineMethod( GuiRoadEditorCtrl, setNodePosition, void, ( Point3F pos ), , "" )
{
object->setNodePosition( pos );
}
DefineConsoleMethod( GuiRoadEditorCtrl, setSelectedRoad, void, ( const char * pathRoad ), (""), "" )
DefineEngineMethod( GuiRoadEditorCtrl, setSelectedRoad, void, ( const char * pathRoad ), (""), "" )
{
if (dStrcmp( pathRoad,"")==0 )
object->setSelectedRoad(NULL);
@ -1087,7 +1087,7 @@ DefineConsoleMethod( GuiRoadEditorCtrl, setSelectedRoad, void, ( const char * pa
}
}
DefineConsoleMethod( GuiRoadEditorCtrl, getSelectedRoad, S32, (), , "" )
DefineEngineMethod( GuiRoadEditorCtrl, getSelectedRoad, S32, (), , "" )
{
DecalRoad *road = object->getSelectedRoad();
if ( road )
@ -1096,12 +1096,12 @@ DefineConsoleMethod( GuiRoadEditorCtrl, getSelectedRoad, S32, (), , "" )
return NULL;
}
DefineConsoleMethod( GuiRoadEditorCtrl, getSelectedNode, S32, (), , "" )
DefineEngineMethod( GuiRoadEditorCtrl, getSelectedNode, S32, (), , "" )
{
return object->getSelectedNode();
}
DefineConsoleMethod( GuiRoadEditorCtrl, deleteRoad, void, (), , "" )
DefineEngineMethod( GuiRoadEditorCtrl, deleteRoad, void, (), , "" )
{
object->deleteSelectedRoad();
}

View file

@ -640,7 +640,7 @@ BaseMatInstance* SkyBox::_getMaterialInstance()
return mMatInstance;
}
DefineConsoleMethod( SkyBox, postApply, void, (), , "")
DefineEngineMethod( SkyBox, postApply, void, (), , "")
{
object->inspectPostApply();
}

View file

@ -558,12 +558,12 @@ void Sun::_onUnselected()
Parent::_onUnselected();
}
DefineConsoleMethod(Sun, apply, void, (), , "")
DefineEngineMethod(Sun, apply, void, (), , "")
{
object->inspectPostApply();
}
DefineConsoleMethod(Sun, animate, void, ( F32 duration, F32 startAzimuth, F32 endAzimuth, F32 startElevation, F32 endElevation ), , "animate( F32 duration, F32 startAzimuth, F32 endAzimuth, F32 startElevation, F32 endElevation )")
DefineEngineMethod(Sun, animate, void, ( F32 duration, F32 startAzimuth, F32 endAzimuth, F32 startElevation, F32 endElevation ), , "animate( F32 duration, F32 startAzimuth, F32 endAzimuth, F32 startElevation, F32 endElevation )")
{
object->animate(duration, startAzimuth, endAzimuth, startElevation, endElevation);

View file

@ -187,7 +187,7 @@ bool ForestBrush::containsItemData( const ForestItemData *inData )
return false;
}
DefineConsoleMethod( ForestBrush, containsItemData, bool, ( const char * obj ), , "( ForestItemData obj )" )
DefineEngineMethod( ForestBrush, containsItemData, bool, ( const char * obj ), , "( ForestItemData obj )" )
{
ForestItemData *data = NULL;
if ( !Sim::findObject( obj, data ) )

View file

@ -682,7 +682,7 @@ bool ForestBrushTool::getGroundAt( const Point3F &worldPt, F32 *zValueOut, Vecto
return true;
}
DefineConsoleMethod( ForestBrushTool, collectElements, void, (), , "" )
DefineEngineMethod( ForestBrushTool, collectElements, void, (), , "" )
{
object->collectElements();
}

View file

@ -370,24 +370,24 @@ bool ForestEditorCtrl::isDirty()
return foundDirty;
}
DefineConsoleMethod( ForestEditorCtrl, updateActiveForest, void, (), , "()" )
DefineEngineMethod( ForestEditorCtrl, updateActiveForest, void, (), , "()" )
{
object->updateActiveForest( true );
}
DefineConsoleMethod( ForestEditorCtrl, setActiveTool, void, ( const char * toolName ), , "( ForestTool tool )" )
DefineEngineMethod( ForestEditorCtrl, setActiveTool, void, ( const char * toolName ), , "( ForestTool tool )" )
{
ForestTool *tool = dynamic_cast<ForestTool*>( Sim::findObject( toolName ) );
object->setActiveTool( tool );
}
DefineConsoleMethod( ForestEditorCtrl, getActiveTool, S32, (), , "()" )
DefineEngineMethod( ForestEditorCtrl, getActiveTool, S32, (), , "()" )
{
ForestTool *tool = object->getActiveTool();
return tool ? tool->getId() : 0;
}
DefineConsoleMethod( ForestEditorCtrl, deleteMeshSafe, void, ( const char * obj ), , "( ForestItemData obj )" )
DefineEngineMethod( ForestEditorCtrl, deleteMeshSafe, void, ( const char * obj ), , "( ForestItemData obj )" )
{
ForestItemData *db;
if ( !Sim::findObject( obj, db ) )
@ -396,12 +396,12 @@ DefineConsoleMethod( ForestEditorCtrl, deleteMeshSafe, void, ( const char * obj
object->deleteMeshSafe( db );
}
DefineConsoleMethod( ForestEditorCtrl, isDirty, bool, (), , "" )
DefineEngineMethod( ForestEditorCtrl, isDirty, bool, (), , "" )
{
return object->isDirty();
}
DefineConsoleMethod(ForestEditorCtrl, setActiveForest, void, (const char * obj), , "( Forest obj )")
DefineEngineMethod(ForestEditorCtrl, setActiveForest, void, (const char * obj), , "( Forest obj )")
{
Forest *forestObject;
if (!Sim::findObject(obj, forestObject))

View file

@ -563,32 +563,32 @@ void ForestSelectionTool::onUndoAction()
mBounds.intersect( mSelection[i].getWorldBox() );
}
DefineConsoleMethod( ForestSelectionTool, getSelectionCount, S32, (), , "" )
DefineEngineMethod( ForestSelectionTool, getSelectionCount, S32, (), , "" )
{
return object->getSelectionCount();
}
DefineConsoleMethod( ForestSelectionTool, deleteSelection, void, (), , "" )
DefineEngineMethod( ForestSelectionTool, deleteSelection, void, (), , "" )
{
object->deleteSelection();
}
DefineConsoleMethod( ForestSelectionTool, clearSelection, void, (), , "" )
DefineEngineMethod( ForestSelectionTool, clearSelection, void, (), , "" )
{
object->clearSelection();
}
DefineConsoleMethod( ForestSelectionTool, cutSelection, void, (), , "" )
DefineEngineMethod( ForestSelectionTool, cutSelection, void, (), , "" )
{
object->cutSelection();
}
DefineConsoleMethod( ForestSelectionTool, copySelection, void, (), , "" )
DefineEngineMethod( ForestSelectionTool, copySelection, void, (), , "" )
{
object->copySelection();
}
DefineConsoleMethod( ForestSelectionTool, pasteSelection, void, (), , "" )
DefineEngineMethod( ForestSelectionTool, pasteSelection, void, (), , "" )
{
object->pasteSelection();
}

View file

@ -361,22 +361,22 @@ void Forest::saveDataFile( const char *path )
mData->write( mDataFileName );
}
DefineConsoleMethod( Forest, saveDataFile, void, (const char * path), (""), "saveDataFile( [path] )" )
DefineEngineMethod( Forest, saveDataFile, void, (const char * path), (""), "saveDataFile( [path] )" )
{
object->saveDataFile( path );
}
DefineConsoleMethod(Forest, isDirty, bool, (), , "()")
DefineEngineMethod(Forest, isDirty, bool, (), , "()")
{
return object->getData() && object->getData()->isDirty();
}
DefineConsoleMethod(Forest, regenCells, void, (), , "()")
DefineEngineMethod(Forest, regenCells, void, (), , "()")
{
object->getData()->regenCells();
}
DefineConsoleMethod(Forest, clear, void, (), , "()" )
DefineEngineMethod(Forest, clear, void, (), , "()" )
{
object->clear();
}

View file

@ -191,7 +191,7 @@ void TheoraTextureObject::play()
//-----------------------------------------------------------------------------
DefineConsoleMethod( TheoraTextureObject, play, void, (),,
DefineEngineMethod( TheoraTextureObject, play, void, (),,
"Start playback of the video." )
{
object->play();
@ -199,7 +199,7 @@ DefineConsoleMethod( TheoraTextureObject, play, void, (),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( TheoraTextureObject, stop, void, (),,
DefineEngineMethod( TheoraTextureObject, stop, void, (),,
"Stop playback of the video." )
{
object->stop();
@ -207,7 +207,7 @@ DefineConsoleMethod( TheoraTextureObject, stop, void, (),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( TheoraTextureObject, pause, void, (),,
DefineEngineMethod( TheoraTextureObject, pause, void, (),,
"Pause playback of the video." )
{
object->pause();

View file

@ -92,17 +92,17 @@ void GuiToolboxButtonCtrl::onSleep()
//-------------------------------------
DefineConsoleMethod( GuiToolboxButtonCtrl, setNormalBitmap, void, ( const char * name ), , "( filepath name ) sets the bitmap that shows when the button is active")
DefineEngineMethod( GuiToolboxButtonCtrl, setNormalBitmap, void, ( const char * name ), , "( filepath name ) sets the bitmap that shows when the button is active")
{
object->setNormalBitmap(name);
}
DefineConsoleMethod( GuiToolboxButtonCtrl, setLoweredBitmap, void, ( const char * name ), , "( filepath name ) sets the bitmap that shows when the button is disabled")
DefineEngineMethod( GuiToolboxButtonCtrl, setLoweredBitmap, void, ( const char * name ), , "( filepath name ) sets the bitmap that shows when the button is disabled")
{
object->setLoweredBitmap(name);
}
DefineConsoleMethod( GuiToolboxButtonCtrl, setHoverBitmap, void, ( const char * name ), , "( filepath name ) sets the bitmap that shows when the button is disabled")
DefineEngineMethod( GuiToolboxButtonCtrl, setHoverBitmap, void, ( const char * name ), , "( filepath name ) sets the bitmap that shows when the button is disabled")
{
object->setHoverBitmap(name);
}

View file

@ -261,7 +261,7 @@ static ConsoleDocFragment _sGuiBitmapCtrlSetBitmap2(
//"Set the bitmap displayed in the control. Note that it is limited in size, to 256x256."
DefineConsoleMethod( GuiBitmapCtrl, setBitmap, void, ( const char * fileRoot, bool resize), ( false),
DefineEngineMethod( GuiBitmapCtrl, setBitmap, void, ( const char * fileRoot, bool resize), ( false),
"( String filename | String filename, bool resize ) Assign an image to the control.\n\n"
"@hide" )
{

View file

@ -658,17 +658,17 @@ void GuiColorPickerCtrl::setScriptValue(const char *value)
setValue(newValue);
}
DefineConsoleMethod(GuiColorPickerCtrl, getSelectorPos, Point2I, (), , "Gets the current position of the selector")
DefineEngineMethod(GuiColorPickerCtrl, getSelectorPos, Point2I, (), , "Gets the current position of the selector")
{
return object->getSelectorPos();
}
DefineConsoleMethod(GuiColorPickerCtrl, setSelectorPos, void, (Point2I newPos), , "Sets the current position of the selector")
DefineEngineMethod(GuiColorPickerCtrl, setSelectorPos, void, (Point2I newPos), , "Sets the current position of the selector")
{
object->setSelectorPos(newPos);
}
DefineConsoleMethod(GuiColorPickerCtrl, updateColor, void, (), , "Forces update of pick color")
DefineEngineMethod(GuiColorPickerCtrl, updateColor, void, (), , "Forces update of pick color")
{
object->updateColor();
}

View file

@ -379,18 +379,18 @@ void GuiFileTreeCtrl::recurseInsert( Item* parent, StringTableEntry path )
}
DefineConsoleMethod( GuiFileTreeCtrl, getSelectedPath, const char*, (), , "getSelectedPath() - returns the currently selected path in the tree")
DefineEngineMethod( GuiFileTreeCtrl, getSelectedPath, const char*, (), , "getSelectedPath() - returns the currently selected path in the tree")
{
const String& path = object->getSelectedPath();
return Con::getStringArg( path );
}
DefineConsoleMethod( GuiFileTreeCtrl, setSelectedPath, bool, (const char * path), , "setSelectedPath(path) - expands the tree to the specified path")
DefineEngineMethod( GuiFileTreeCtrl, setSelectedPath, bool, (const char * path), , "setSelectedPath(path) - expands the tree to the specified path")
{
return object->setSelectedPath( path );
}
DefineConsoleMethod( GuiFileTreeCtrl, reload, void, (), , "() - Reread the directory tree hierarchy." )
DefineEngineMethod( GuiFileTreeCtrl, reload, void, (), , "() - Reread the directory tree hierarchy." )
{
object->updateTree();
}

View file

@ -601,7 +601,7 @@ void GuiGradientCtrl::sortColorRange()
dQsort( mAlphaRange.address(), mAlphaRange.size(), sizeof(ColorRange), _numIncreasing);
}
DefineConsoleMethod(GuiGradientCtrl, getColorCount, S32, (), , "Get color count")
DefineEngineMethod(GuiGradientCtrl, getColorCount, S32, (), , "Get color count")
{
if( object->getDisplayMode() == GuiGradientCtrl::pHorizColorRange )
return object->mColorRange.size();
@ -611,7 +611,7 @@ DefineConsoleMethod(GuiGradientCtrl, getColorCount, S32, (), , "Get color count"
return 0;
}
DefineConsoleMethod(GuiGradientCtrl, getColor, LinearColorF, (S32 idx), , "Get color value")
DefineEngineMethod(GuiGradientCtrl, getColor, LinearColorF, (S32 idx), , "Get color value")
{
if( object->getDisplayMode() == GuiGradientCtrl::pHorizColorRange )

View file

@ -167,7 +167,7 @@ void GuiMaterialCtrl::onRender( Point2I offset, const RectI &updateRect )
GFX->setTexture( 0, NULL );
}
DefineConsoleMethod( GuiMaterialCtrl, setMaterial, bool, ( const char * materialName ), , "( string materialName )"
DefineEngineMethod( GuiMaterialCtrl, setMaterial, bool, ( const char * materialName ), , "( string materialName )"
"Set the material to be displayed in the control." )
{
return object->setMaterial( materialName );

View file

@ -300,82 +300,82 @@ void GuiPopUpMenuCtrl::initPersistFields(void)
}
//------------------------------------------------------------------------------
DefineConsoleMethod( GuiPopUpMenuCtrl, add, void, (const char * name, S32 idNum, U32 scheme), ("", -1, 0), "(string name, int idNum, int scheme=0)")
DefineEngineMethod( GuiPopUpMenuCtrl, add, void, (const char * name, S32 idNum, U32 scheme), ("", -1, 0), "(string name, int idNum, int scheme=0)")
{
object->addEntry(name, idNum, scheme);
}
DefineConsoleMethod( GuiPopUpMenuCtrl, addScheme, void, (U32 id, ColorI fontColor, ColorI fontColorHL, ColorI fontColorSEL), ,
DefineEngineMethod( GuiPopUpMenuCtrl, addScheme, void, (U32 id, ColorI fontColor, ColorI fontColorHL, ColorI fontColorSEL), ,
"(int id, ColorI fontColor, ColorI fontColorHL, ColorI fontColorSEL)")
{
object->addScheme( id, fontColor, fontColorHL, fontColorSEL );
}
DefineConsoleMethod( GuiPopUpMenuCtrl, getText, const char*, (), , "")
DefineEngineMethod( GuiPopUpMenuCtrl, getText, const char*, (), , "")
{
return object->getText();
}
DefineConsoleMethod( GuiPopUpMenuCtrl, clear, void, (), , "Clear the popup list.")
DefineEngineMethod( GuiPopUpMenuCtrl, clear, void, (), , "Clear the popup list.")
{
object->clear();
}
//FIXME: clashes with SimSet.sort
DefineConsoleMethod(GuiPopUpMenuCtrl, sort, void, (), , "Sort the list alphabetically.")
DefineEngineMethod(GuiPopUpMenuCtrl, sort, void, (), , "Sort the list alphabetically.")
{
object->sort();
}
// Added to sort the entries by ID
DefineConsoleMethod(GuiPopUpMenuCtrl, sortID, void, (), , "Sort the list by ID.")
DefineEngineMethod(GuiPopUpMenuCtrl, sortID, void, (), , "Sort the list by ID.")
{
object->sortID();
}
DefineConsoleMethod( GuiPopUpMenuCtrl, forceOnAction, void, (), , "")
DefineEngineMethod( GuiPopUpMenuCtrl, forceOnAction, void, (), , "")
{
object->onAction();
}
DefineConsoleMethod( GuiPopUpMenuCtrl, forceClose, void, (), , "")
DefineEngineMethod( GuiPopUpMenuCtrl, forceClose, void, (), , "")
{
object->closePopUp();
}
DefineConsoleMethod( GuiPopUpMenuCtrl, getSelected, S32, (), , "Gets the selected index")
DefineEngineMethod( GuiPopUpMenuCtrl, getSelected, S32, (), , "Gets the selected index")
{
return object->getSelected();
}
DefineConsoleMethod( GuiPopUpMenuCtrl, setSelected, void, (S32 id, bool scriptCallback), (true), "(int id, [scriptCallback=true])")
DefineEngineMethod( GuiPopUpMenuCtrl, setSelected, void, (S32 id, bool scriptCallback), (true), "(int id, [scriptCallback=true])")
{
object->setSelected( id, scriptCallback );
}
DefineConsoleMethod( GuiPopUpMenuCtrl, setFirstSelected, void, (bool scriptCallback), (true), "([scriptCallback=true])")
DefineEngineMethod( GuiPopUpMenuCtrl, setFirstSelected, void, (bool scriptCallback), (true), "([scriptCallback=true])")
{
object->setFirstSelected( scriptCallback );
}
DefineConsoleMethod( GuiPopUpMenuCtrl, setNoneSelected, void, (), , "")
DefineEngineMethod( GuiPopUpMenuCtrl, setNoneSelected, void, (), , "")
{
object->setNoneSelected();
}
DefineConsoleMethod( GuiPopUpMenuCtrl, getTextById, const char*, (S32 id), , "(int id)")
DefineEngineMethod( GuiPopUpMenuCtrl, getTextById, const char*, (S32 id), , "(int id)")
{
return(object->getTextById(id));
}
DefineConsoleMethod( GuiPopUpMenuCtrl, changeTextById, void, ( S32 id, const char * text ), , "( int id, string text )" )
DefineEngineMethod( GuiPopUpMenuCtrl, changeTextById, void, ( S32 id, const char * text ), , "( int id, string text )" )
{
object->setEntryText( id, text );
}
DefineConsoleMethod( GuiPopUpMenuCtrl, setEnumContent, void, (const char * className, const char * enumName), , "(string class, string enum)"
DefineEngineMethod( GuiPopUpMenuCtrl, setEnumContent, void, (const char * className, const char * enumName), , "(string class, string enum)"
"This fills the popup with a classrep's field enumeration type info.\n\n"
"More of a helper function than anything. If console access to the field list is added, "
"at least for the enumerated types, then this should go away..")
@ -429,20 +429,20 @@ DefineConsoleMethod( GuiPopUpMenuCtrl, setEnumContent, void, (const char * class
}
//------------------------------------------------------------------------------
DefineConsoleMethod( GuiPopUpMenuCtrl, findText, S32, (const char * text), , "(string text)"
DefineEngineMethod( GuiPopUpMenuCtrl, findText, S32, (const char * text), , "(string text)"
"Returns the position of the first entry containing the specified text or -1 if not found.")
{
return( object->findText( text ) );
}
//------------------------------------------------------------------------------
DefineConsoleMethod( GuiPopUpMenuCtrl, size, S32, (), , "Get the size of the menu - the number of entries in it.")
DefineEngineMethod( GuiPopUpMenuCtrl, size, S32, (), , "Get the size of the menu - the number of entries in it.")
{
return( object->getNumEntries() );
}
//------------------------------------------------------------------------------
DefineConsoleMethod( GuiPopUpMenuCtrl, replaceText, void, (bool doReplaceText), , "(bool doReplaceText)")
DefineEngineMethod( GuiPopUpMenuCtrl, replaceText, void, (bool doReplaceText), , "(bool doReplaceText)")
{
object->replaceText(S32(doReplaceText));
}
@ -532,7 +532,7 @@ void GuiPopUpMenuCtrl::clearEntry( S32 entry )
}
//------------------------------------------------------------------------------
DefineConsoleMethod( GuiPopUpMenuCtrl, clearEntry, void, (S32 entry), , "(S32 entry)")
DefineEngineMethod( GuiPopUpMenuCtrl, clearEntry, void, (S32 entry), , "(S32 entry)")
{
object->clearEntry(entry);
}

View file

@ -364,7 +364,7 @@ ConsoleDocFragment _GuiPopUpMenuCtrlExAdd(
"void add(string name, S32 idNum, S32 scheme=0);"
);
DefineConsoleMethod( GuiPopUpMenuCtrlEx, add, void, (const char * name, S32 idNum, U32 scheme), ("", -1, 0), "(string name, int idNum, int scheme=0)")
DefineEngineMethod( GuiPopUpMenuCtrlEx, add, void, (const char * name, S32 idNum, U32 scheme), ("", -1, 0), "(string name, int idNum, int scheme=0)")
{
object->addEntry(name, idNum, scheme);
}
@ -525,7 +525,7 @@ ConsoleDocFragment _GuiPopUpMenuCtrlExsetSelected(
"setSelected(int id, bool scriptCallback=true);"
);
DefineConsoleMethod( GuiPopUpMenuCtrlEx, setSelected, void, (S32 id, bool scriptCallback), (true), "(int id, [scriptCallback=true])"
DefineEngineMethod( GuiPopUpMenuCtrlEx, setSelected, void, (S32 id, bool scriptCallback), (true), "(int id, [scriptCallback=true])"
"@hide")
{
object->setSelected( id, scriptCallback );
@ -539,7 +539,7 @@ ConsoleDocFragment _GuiPopUpMenuCtrlExsetFirstSelected(
);
DefineConsoleMethod( GuiPopUpMenuCtrlEx, setFirstSelected, void, (bool scriptCallback), (true), "([scriptCallback=true])"
DefineEngineMethod( GuiPopUpMenuCtrlEx, setFirstSelected, void, (bool scriptCallback), (true), "([scriptCallback=true])"
"@hide")
{
object->setFirstSelected( scriptCallback );
@ -561,7 +561,7 @@ DefineEngineMethod( GuiPopUpMenuCtrlEx, getTextById, const char*, (S32 id),,
}
DefineConsoleMethod( GuiPopUpMenuCtrlEx, getColorById, ColorI, (S32 id), ,
DefineEngineMethod( GuiPopUpMenuCtrlEx, getColorById, ColorI, (S32 id), ,
"@brief Get color of an entry's box\n\n"
"@param id ID number of entry to query\n\n"
"@return ColorI in the format of \"Red Green Blue Alpha\", each of with is a value between 0 - 255")
@ -572,7 +572,7 @@ DefineConsoleMethod( GuiPopUpMenuCtrlEx, getColorById, ColorI, (S32 id), ,
}
DefineConsoleMethod( GuiPopUpMenuCtrlEx, setEnumContent, void, ( const char * className, const char * enumName ), ,
DefineEngineMethod( GuiPopUpMenuCtrlEx, setEnumContent, void, ( const char * className, const char * enumName ), ,
"@brief This fills the popup with a classrep's field enumeration type info.\n\n"
"More of a helper function than anything. If console access to the field list is added, "
"at least for the enumerated types, then this should go away.\n\n"
@ -628,7 +628,7 @@ DefineConsoleMethod( GuiPopUpMenuCtrlEx, setEnumContent, void, ( const char * cl
}
//------------------------------------------------------------------------------
DefineConsoleMethod( GuiPopUpMenuCtrlEx, findText, S32, (const char * text), , "(string text)"
DefineEngineMethod( GuiPopUpMenuCtrlEx, findText, S32, (const char * text), , "(string text)"
"Returns the id of the first entry containing the specified text or -1 if not found."
"@param text String value used for the query\n\n"
"@return Numerical ID of entry containing the text.")
@ -637,7 +637,7 @@ DefineConsoleMethod( GuiPopUpMenuCtrlEx, findText, S32, (const char * text), , "
}
//------------------------------------------------------------------------------
DefineConsoleMethod( GuiPopUpMenuCtrlEx, size, S32, (), ,
DefineEngineMethod( GuiPopUpMenuCtrlEx, size, S32, (), ,
"@brief Get the size of the menu\n\n"
"@return Number of entries in the menu\n")
{
@ -645,7 +645,7 @@ DefineConsoleMethod( GuiPopUpMenuCtrlEx, size, S32, (), ,
}
//------------------------------------------------------------------------------
DefineConsoleMethod( GuiPopUpMenuCtrlEx, replaceText, void, (S32 boolVal), ,
DefineEngineMethod( GuiPopUpMenuCtrlEx, replaceText, void, (S32 boolVal), ,
"@brief Flag that causes each new text addition to replace the current entry\n\n"
"@param True to turn on replacing, false to disable it")
{
@ -737,7 +737,7 @@ void GuiPopUpMenuCtrlEx::clearEntry( S32 entry )
}
//------------------------------------------------------------------------------
DefineConsoleMethod( GuiPopUpMenuCtrlEx, clearEntry, void, (S32 entry), , "(S32 entry)")
DefineEngineMethod( GuiPopUpMenuCtrlEx, clearEntry, void, (S32 entry), , "(S32 entry)")
{
object->clearEntry(entry);
}

View file

@ -2139,7 +2139,7 @@ ConsoleDocFragment _pushDialog(
"void pushDialog( GuiControl ctrl, int layer=0, bool center=false);"
);
DefineConsoleMethod( GuiCanvas, pushDialog, void, (const char * ctrlName, S32 layer, bool center), ( 0, false), "(GuiControl ctrl, int layer=0, bool center=false)"
DefineEngineMethod( GuiCanvas, pushDialog, void, (const char * ctrlName, S32 layer, bool center), ( 0, false), "(GuiControl ctrl, int layer=0, bool center=false)"
"@hide")
{
GuiControl *gui;
@ -2176,7 +2176,7 @@ ConsoleDocFragment _popDialog2(
"void popDialog();"
);
DefineConsoleMethod( GuiCanvas, popDialog, void, (GuiControl * gui), (nullAsType<GuiControl*>()), "(GuiControl ctrl=NULL)"
DefineEngineMethod( GuiCanvas, popDialog, void, (GuiControl * gui), (nullAsType<GuiControl*>()), "(GuiControl ctrl=NULL)"
"@hide")
{
if (gui)
@ -2204,7 +2204,7 @@ ConsoleDocFragment _popLayer2(
"void popLayer(S32 layer);"
);
DefineConsoleMethod( GuiCanvas, popLayer, void, (S32 layer), (0), "(int layer)"
DefineEngineMethod( GuiCanvas, popLayer, void, (S32 layer), (0), "(int layer)"
"@hide")
{
@ -2362,7 +2362,7 @@ ConsoleDocFragment _setCursorPos2(
"bool setCursorPos( F32 posX, F32 posY);"
);
DefineConsoleMethod( GuiCanvas, setCursorPos, void, (Point2I pos), , "(Point2I pos)"
DefineEngineMethod( GuiCanvas, setCursorPos, void, (Point2I pos), , "(Point2I pos)"
"@hide")
{
@ -2647,7 +2647,7 @@ DefineEngineMethod( GuiCanvas, setWindowPosition, void, ( Point2I position ),,
object->getPlatformWindow()->setPosition( position );
}
DefineConsoleMethod( GuiCanvas, isFullscreen, bool, (), , "() - Is this canvas currently fullscreen?" )
DefineEngineMethod( GuiCanvas, isFullscreen, bool, (), , "() - Is this canvas currently fullscreen?" )
{
if (Platform::getWebDeployment())
return false;
@ -2658,14 +2658,14 @@ DefineConsoleMethod( GuiCanvas, isFullscreen, bool, (), , "() - Is this canvas c
return object->getPlatformWindow()->getVideoMode().fullScreen;
}
DefineConsoleMethod( GuiCanvas, minimizeWindow, void, (), , "() - minimize this canvas' window." )
DefineEngineMethod( GuiCanvas, minimizeWindow, void, (), , "() - minimize this canvas' window." )
{
PlatformWindow* window = object->getPlatformWindow();
if ( window )
window->minimize();
}
DefineConsoleMethod( GuiCanvas, isMinimized, bool, (), , "()" )
DefineEngineMethod( GuiCanvas, isMinimized, bool, (), , "()" )
{
PlatformWindow* window = object->getPlatformWindow();
if ( window )
@ -2674,7 +2674,7 @@ DefineConsoleMethod( GuiCanvas, isMinimized, bool, (), , "()" )
return false;
}
DefineConsoleMethod( GuiCanvas, isMaximized, bool, (), , "()" )
DefineEngineMethod( GuiCanvas, isMaximized, bool, (), , "()" )
{
PlatformWindow* window = object->getPlatformWindow();
if ( window )
@ -2683,21 +2683,21 @@ DefineConsoleMethod( GuiCanvas, isMaximized, bool, (), , "()" )
return false;
}
DefineConsoleMethod( GuiCanvas, maximizeWindow, void, (), , "() - maximize this canvas' window." )
DefineEngineMethod( GuiCanvas, maximizeWindow, void, (), , "() - maximize this canvas' window." )
{
PlatformWindow* window = object->getPlatformWindow();
if ( window )
window->maximize();
}
DefineConsoleMethod( GuiCanvas, restoreWindow, void, (), , "() - restore this canvas' window." )
DefineEngineMethod( GuiCanvas, restoreWindow, void, (), , "() - restore this canvas' window." )
{
PlatformWindow* window = object->getPlatformWindow();
if( window )
window->restore();
}
DefineConsoleMethod( GuiCanvas, setFocus, void, (), , "() - Claim OS input focus for this canvas' window.")
DefineEngineMethod( GuiCanvas, setFocus, void, (), , "() - Claim OS input focus for this canvas' window.")
{
PlatformWindow* window = object->getPlatformWindow();
if( window )
@ -2712,7 +2712,7 @@ DefineEngineMethod( GuiCanvas, setMenuBar, void, ( GuiControl* menu ),,
return object->setMenuBar( menu );
}
DefineConsoleMethod( GuiCanvas, setVideoMode, void,
DefineEngineMethod( GuiCanvas, setVideoMode, void,
(U32 width, U32 height, bool fullscreen, U32 bitDepth, U32 refreshRate, U32 antialiasLevel),
( false, 0, 0, 0),
"(int width, int height, bool fullscreen, [int bitDepth], [int refreshRate], [int antialiasLevel] )\n"

View file

@ -2898,7 +2898,7 @@ static ConsoleDocFragment _sGuiControlSetExtent2(
"GuiControl", // The class to place the method in; use NULL for functions.
"void setExtent( Point2I p );" ); // The definition string.
DefineConsoleMethod( GuiControl, setExtent, void, ( const char* extOrX, const char* y ), (""),
DefineEngineMethod( GuiControl, setExtent, void, ( const char* extOrX, const char* y ), (""),
"( Point2I p | int x, int y ) Set the width and height of the control.\n\n"
"@hide" )
{

View file

@ -66,13 +66,13 @@ DbgFileView::DbgFileView()
mSize.set(1, 0);
}
DefineConsoleMethod(DbgFileView, setCurrentLine, void, (S32 line, bool selected), , "(int line, bool selected)"
DefineEngineMethod(DbgFileView, setCurrentLine, void, (S32 line, bool selected), , "(int line, bool selected)"
"Set the current highlighted line.")
{
object->setCurrentLine(line, selected);
}
DefineConsoleMethod(DbgFileView, getCurrentLine, const char *, (), , "()"
DefineEngineMethod(DbgFileView, getCurrentLine, const char *, (), , "()"
"Get the currently executing file and line, if any.\n\n"
"@returns A string containing the file, a tab, and then the line number."
" Use getField() with this.")
@ -84,38 +84,38 @@ DefineConsoleMethod(DbgFileView, getCurrentLine, const char *, (), , "()"
return ret;
}
DefineConsoleMethod(DbgFileView, open, bool, (const char * filename), , "(string filename)"
DefineEngineMethod(DbgFileView, open, bool, (const char * filename), , "(string filename)"
"Open a file for viewing.\n\n"
"@note This loads the file from the local system.")
{
return object->openFile(filename);
}
DefineConsoleMethod(DbgFileView, clearBreakPositions, void, (), , "()"
DefineEngineMethod(DbgFileView, clearBreakPositions, void, (), , "()"
"Clear all break points in the current file.")
{
object->clearBreakPositions();
}
DefineConsoleMethod(DbgFileView, setBreakPosition, void, (U32 line), , "(int line)"
DefineEngineMethod(DbgFileView, setBreakPosition, void, (U32 line), , "(int line)"
"Set a breakpoint at the specified line.")
{
object->setBreakPosition(line);
}
DefineConsoleMethod(DbgFileView, setBreak, void, (U32 line), , "(int line)"
DefineEngineMethod(DbgFileView, setBreak, void, (U32 line), , "(int line)"
"Set a breakpoint at the specified line.")
{
object->setBreakPointStatus(line, true);
}
DefineConsoleMethod(DbgFileView, removeBreak, void, (U32 line), , "(int line)"
DefineEngineMethod(DbgFileView, removeBreak, void, (U32 line), , "(int line)"
"Remove a breakpoint from the specified line.")
{
object->setBreakPointStatus(line, false);
}
DefineConsoleMethod(DbgFileView, findString, bool, (const char * findThis), , "(string findThis)"
DefineEngineMethod(DbgFileView, findString, bool, (const char * findThis), , "(string findThis)"
"Find the specified string in the currently viewed file and "
"scroll it into view.")
{

View file

@ -2468,7 +2468,7 @@ void GuiEditCtrl::startMouseGuideDrag( guideAxis axis, U32 guideIndex, bool lock
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, getContentControl, S32, (), , "() - Return the toplevel control edited inside the GUI editor." )
DefineEngineMethod( GuiEditCtrl, getContentControl, S32, (), , "() - Return the toplevel control edited inside the GUI editor." )
{
GuiControl* ctrl = object->getContentControl();
if( ctrl )
@ -2479,7 +2479,7 @@ DefineConsoleMethod( GuiEditCtrl, getContentControl, S32, (), , "() - Return the
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, setContentControl, void, (GuiControl *ctrl ), , "( GuiControl ctrl ) - Set the toplevel control to edit in the GUI editor." )
DefineEngineMethod( GuiEditCtrl, setContentControl, void, (GuiControl *ctrl ), , "( GuiControl ctrl ) - Set the toplevel control to edit in the GUI editor." )
{
if (ctrl)
object->setContentControl(ctrl);
@ -2487,7 +2487,7 @@ DefineConsoleMethod( GuiEditCtrl, setContentControl, void, (GuiControl *ctrl ),
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, addNewCtrl, void, (GuiControl *ctrl), , "(GuiControl ctrl)")
DefineEngineMethod( GuiEditCtrl, addNewCtrl, void, (GuiControl *ctrl), , "(GuiControl ctrl)")
{
if (ctrl)
object->addNewControl(ctrl);
@ -2495,28 +2495,28 @@ DefineConsoleMethod( GuiEditCtrl, addNewCtrl, void, (GuiControl *ctrl), , "(GuiC
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, addSelection, void, (S32 id), , "selects a control.")
DefineEngineMethod( GuiEditCtrl, addSelection, void, (S32 id), , "selects a control.")
{
object->addSelection(id);
}
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, removeSelection, void, (S32 id), , "deselects a control.")
DefineEngineMethod( GuiEditCtrl, removeSelection, void, (S32 id), , "deselects a control.")
{
object->removeSelection(id);
}
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, clearSelection, void, (), , "Clear selected controls list.")
DefineEngineMethod( GuiEditCtrl, clearSelection, void, (), , "Clear selected controls list.")
{
object->clearSelection();
}
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, select, void, (GuiControl *ctrl), , "(GuiControl ctrl)")
DefineEngineMethod( GuiEditCtrl, select, void, (GuiControl *ctrl), , "(GuiControl ctrl)")
{
if (ctrl)
object->setSelection(ctrl, false);
@ -2524,7 +2524,7 @@ DefineConsoleMethod( GuiEditCtrl, select, void, (GuiControl *ctrl), , "(GuiContr
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, setCurrentAddSet, void, (GuiControl *addSet), , "(GuiControl ctrl)")
DefineEngineMethod( GuiEditCtrl, setCurrentAddSet, void, (GuiControl *addSet), , "(GuiControl ctrl)")
{
if (addSet)
object->setCurrentAddSet(addSet);
@ -2532,7 +2532,7 @@ DefineConsoleMethod( GuiEditCtrl, setCurrentAddSet, void, (GuiControl *addSet),
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, getCurrentAddSet, S32, (), , "Returns the set to which new controls will be added")
DefineEngineMethod( GuiEditCtrl, getCurrentAddSet, S32, (), , "Returns the set to which new controls will be added")
{
const GuiControl* add = object->getCurrentAddSet();
return add ? add->getId() : 0;
@ -2540,49 +2540,49 @@ DefineConsoleMethod( GuiEditCtrl, getCurrentAddSet, S32, (), , "Returns the set
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, toggle, void, (), , "Toggle activation.")
DefineEngineMethod( GuiEditCtrl, toggle, void, (), , "Toggle activation.")
{
object->setEditMode( !object->isActive() );
}
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, justify, void, (U32 mode), , "(int mode)" )
DefineEngineMethod( GuiEditCtrl, justify, void, (U32 mode), , "(int mode)" )
{
object->justifySelection( (GuiEditCtrl::Justification)mode );
}
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, bringToFront, void, (), , "")
DefineEngineMethod( GuiEditCtrl, bringToFront, void, (), , "")
{
object->bringToFront();
}
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, pushToBack, void, (), , "")
DefineEngineMethod( GuiEditCtrl, pushToBack, void, (), , "")
{
object->pushToBack();
}
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, deleteSelection, void, (), , "() - Delete the selected controls.")
DefineEngineMethod( GuiEditCtrl, deleteSelection, void, (), , "() - Delete the selected controls.")
{
object->deleteSelection();
}
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, moveSelection, void, (S32 dx, S32 dy), , "Move all controls in the selection by (dx,dy) pixels.")
DefineEngineMethod( GuiEditCtrl, moveSelection, void, (S32 dx, S32 dy), , "Move all controls in the selection by (dx,dy) pixels.")
{
object->moveAndSnapSelection(Point2I(dx, dy));
}
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, saveSelection, void, (const char * filename), (nullAsType<const char*>()), "( string fileName=null ) - Save selection to file or clipboard.")
DefineEngineMethod( GuiEditCtrl, saveSelection, void, (const char * filename), (nullAsType<const char*>()), "( string fileName=null ) - Save selection to file or clipboard.")
{
object->saveSelection( filename );
@ -2590,7 +2590,7 @@ DefineConsoleMethod( GuiEditCtrl, saveSelection, void, (const char * filename),
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, loadSelection, void, (const char * filename), (nullAsType<const char*>()), "( string fileName=null ) - Load selection from file or clipboard.")
DefineEngineMethod( GuiEditCtrl, loadSelection, void, (const char * filename), (nullAsType<const char*>()), "( string fileName=null ) - Load selection from file or clipboard.")
{
object->loadSelection( filename );
@ -2598,7 +2598,7 @@ DefineConsoleMethod( GuiEditCtrl, loadSelection, void, (const char * filename),
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, selectAll, void, (), , "()")
DefineEngineMethod( GuiEditCtrl, selectAll, void, (), , "()")
{
object->selectAll();
}
@ -2613,14 +2613,14 @@ DefineEngineMethod( GuiEditCtrl, getSelection, SimSet*, (),,
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, getNumSelected, S32, (), , "() - Return the number of controls currently selected." )
DefineEngineMethod( GuiEditCtrl, getNumSelected, S32, (), , "() - Return the number of controls currently selected." )
{
return object->getNumSelected();
}
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, getSelectionGlobalBounds, const char*, (), , "() - Returns global bounds of current selection as vector 'x y width height'." )
DefineEngineMethod( GuiEditCtrl, getSelectionGlobalBounds, const char*, (), , "() - Returns global bounds of current selection as vector 'x y width height'." )
{
RectI bounds = object->getSelectionGlobalBounds();
String str = String::ToString( "%i %i %i %i", bounds.point.x, bounds.point.y, bounds.extent.x, bounds.extent.y );
@ -2633,7 +2633,7 @@ DefineConsoleMethod( GuiEditCtrl, getSelectionGlobalBounds, const char*, (), , "
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, selectParents, void, ( bool addToSelection ), (false), "( bool addToSelection=false ) - Select parents of currently selected controls." )
DefineEngineMethod( GuiEditCtrl, selectParents, void, ( bool addToSelection ), (false), "( bool addToSelection=false ) - Select parents of currently selected controls." )
{
object->selectParents( addToSelection );
@ -2641,7 +2641,7 @@ DefineConsoleMethod( GuiEditCtrl, selectParents, void, ( bool addToSelection ),
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, selectChildren, void, ( bool addToSelection ), (false), "( bool addToSelection=false ) - Select children of currently selected controls." )
DefineEngineMethod( GuiEditCtrl, selectChildren, void, ( bool addToSelection ), (false), "( bool addToSelection=false ) - Select children of currently selected controls." )
{
object->selectChildren( addToSelection );
@ -2657,14 +2657,14 @@ DefineEngineMethod( GuiEditCtrl, getTrash, SimGroup*, (),,
//-----------------------------------------------------------------------------
DefineConsoleMethod(GuiEditCtrl, setSnapToGrid, void, (U32 gridsize), , "GuiEditCtrl.setSnapToGrid(gridsize)")
DefineEngineMethod(GuiEditCtrl, setSnapToGrid, void, (U32 gridsize), , "GuiEditCtrl.setSnapToGrid(gridsize)")
{
object->setSnapToGrid(gridsize);
}
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, readGuides, void, ( GuiControl* ctrl, S32 axis ), (-1), "( GuiControl ctrl [, int axis ] ) - Read the guides from the given control." )
DefineEngineMethod( GuiEditCtrl, readGuides, void, ( GuiControl* ctrl, S32 axis ), (-1), "( GuiControl ctrl [, int axis ] ) - Read the guides from the given control." )
{
// Find the control.
@ -2694,7 +2694,7 @@ DefineConsoleMethod( GuiEditCtrl, readGuides, void, ( GuiControl* ctrl, S32 axis
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, writeGuides, void, ( GuiControl* ctrl, S32 axis ), ( -1), "( GuiControl ctrl [, int axis ] ) - Write the guides to the given control." )
DefineEngineMethod( GuiEditCtrl, writeGuides, void, ( GuiControl* ctrl, S32 axis ), ( -1), "( GuiControl ctrl [, int axis ] ) - Write the guides to the given control." )
{
// Find the control.
@ -2724,7 +2724,7 @@ DefineConsoleMethod( GuiEditCtrl, writeGuides, void, ( GuiControl* ctrl, S32 axi
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, clearGuides, void, ( S32 axis ), (-1), "( [ int axis ] ) - Clear all currently set guide lines." )
DefineEngineMethod( GuiEditCtrl, clearGuides, void, ( S32 axis ), (-1), "( [ int axis ] ) - Clear all currently set guide lines." )
{
if( axis != -1 )
{
@ -2745,7 +2745,7 @@ DefineConsoleMethod( GuiEditCtrl, clearGuides, void, ( S32 axis ), (-1), "( [ in
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, fitIntoParents, void, (bool width, bool height), (true, true), "( bool width=true, bool height=true ) - Fit selected controls into their parents." )
DefineEngineMethod( GuiEditCtrl, fitIntoParents, void, (bool width, bool height), (true, true), "( bool width=true, bool height=true ) - Fit selected controls into their parents." )
{
object->fitIntoParents( width, height );
@ -2753,7 +2753,7 @@ DefineConsoleMethod( GuiEditCtrl, fitIntoParents, void, (bool width, bool height
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiEditCtrl, getMouseMode, const char*, (), , "() - Return the current mouse mode." )
DefineEngineMethod( GuiEditCtrl, getMouseMode, const char*, (), , "() - Return the current mouse mode." )
{
switch( object->getMouseMode() )
{

View file

@ -60,7 +60,7 @@ void GuiFilterCtrl::initPersistFields()
Parent::initPersistFields();
}
DefineConsoleMethod( GuiFilterCtrl, getValue, const char*, (), , "Return a tuple containing all the values in the filter."
DefineEngineMethod( GuiFilterCtrl, getValue, const char*, (), , "Return a tuple containing all the values in the filter."
"@internal")
{
static char buffer[512];
@ -89,7 +89,7 @@ ConsoleMethod( GuiFilterCtrl, setValue, void, 3, 20, "(f1, f2, ...)"
object->set(filter);
}
DefineConsoleMethod( GuiFilterCtrl, identity, void, (), , "Reset the filtering."
DefineEngineMethod( GuiFilterCtrl, identity, void, (), , "Reset the filtering."
"@internal")
{
object->identity();

View file

@ -1486,7 +1486,7 @@ PopupMenu* GuiMenuBar::findMenu(StringTableEntry barTitle)
//-----------------------------------------------------------------------------
// Console Methods
//-----------------------------------------------------------------------------
DefineConsoleMethod(GuiMenuBar, attachToCanvas, void, (const char *canvas, S32 pos), , "(GuiCanvas, pos)")
DefineEngineMethod(GuiMenuBar, attachToCanvas, void, (const char *canvas, S32 pos), , "(GuiCanvas, pos)")
{
GuiCanvas* canv = dynamic_cast<GuiCanvas*>(Sim::findObject(canvas));
if (canv)
@ -1495,7 +1495,7 @@ DefineConsoleMethod(GuiMenuBar, attachToCanvas, void, (const char *canvas, S32 p
}
}
DefineConsoleMethod(GuiMenuBar, removeFromCanvas, void, (), , "()")
DefineEngineMethod(GuiMenuBar, removeFromCanvas, void, (), , "()")
{
GuiCanvas* canvas = object->getRoot();
@ -1503,23 +1503,23 @@ DefineConsoleMethod(GuiMenuBar, removeFromCanvas, void, (), , "()")
canvas->setMenuBar(nullptr);
}
DefineConsoleMethod(GuiMenuBar, getMenuCount, S32, (), , "()")
DefineEngineMethod(GuiMenuBar, getMenuCount, S32, (), , "()")
{
return object->getMenuListCount();
}
DefineConsoleMethod(GuiMenuBar, getMenu, S32, (S32 index), (0), "(Index)")
DefineEngineMethod(GuiMenuBar, getMenu, S32, (S32 index), (0), "(Index)")
{
return object->getMenu(index)->getId();
}
//-----------------------------------------------------------------------------
DefineConsoleMethod(GuiMenuBar, insert, void, (SimObject* pObject, S32 pos), (nullAsType<SimObject*>(), -1), "(object, pos) insert object at position")
DefineEngineMethod(GuiMenuBar, insert, void, (SimObject* pObject, S32 pos), (nullAsType<SimObject*>(), -1), "(object, pos) insert object at position")
{
object->insert(pObject, pos);
}
DefineConsoleMethod(GuiMenuBar, findMenu, S32, (const char* barTitle), (""), "(barTitle)")
DefineEngineMethod(GuiMenuBar, findMenu, S32, (const char* barTitle), (""), "(barTitle)")
{
StringTableEntry barTitleStr = StringTable->insert(barTitle);
PopupMenu* menu = object->findMenu(barTitleStr);

View file

@ -1004,7 +1004,7 @@ bool GuiParticleGraphCtrl::renderGraphTooltip(Point2I cursorPos, StringTableEntr
return true;
}
DefineConsoleMethod(GuiParticleGraphCtrl, setSelectedPoint, void, (S32 point), , "(int point)"
DefineEngineMethod(GuiParticleGraphCtrl, setSelectedPoint, void, (S32 point), , "(int point)"
"Set the selected point on the graph.\n"
"@return No return value")
{
@ -1016,7 +1016,7 @@ DefineConsoleMethod(GuiParticleGraphCtrl, setSelectedPoint, void, (S32 point), ,
object->setSelectedPoint( point );
}
DefineConsoleMethod(GuiParticleGraphCtrl, setSelectedPlot, void, (S32 plotID), , "(int plotID)"
DefineEngineMethod(GuiParticleGraphCtrl, setSelectedPlot, void, (S32 plotID), , "(int plotID)"
"Set the selected plot (a.k.a. graph)."
"@return No return value" )
{
@ -1028,7 +1028,7 @@ DefineConsoleMethod(GuiParticleGraphCtrl, setSelectedPlot, void, (S32 plotID), ,
object->setSelectedPlot( plotID );
}
DefineConsoleMethod(GuiParticleGraphCtrl, clearGraph, void, (S32 plotID), , "(int plotID)"
DefineEngineMethod(GuiParticleGraphCtrl, clearGraph, void, (S32 plotID), , "(int plotID)"
"Clear the graph of the given plot."
"@return No return value")
{
@ -1040,14 +1040,14 @@ DefineConsoleMethod(GuiParticleGraphCtrl, clearGraph, void, (S32 plotID), , "(in
object->clearGraph( plotID );
}
DefineConsoleMethod(GuiParticleGraphCtrl, clearAllGraphs, void, (), , "()"
DefineEngineMethod(GuiParticleGraphCtrl, clearAllGraphs, void, (), , "()"
"Clear all of the graphs."
"@return No return value")
{
object->clearAllGraphs();
}
DefineConsoleMethod(GuiParticleGraphCtrl, addPlotPoint, S32, (S32 plotID, F32 x, F32 y, bool setAdded), (true), "(int plotID, float x, float y, bool setAdded = true;)"
DefineEngineMethod(GuiParticleGraphCtrl, addPlotPoint, S32, (S32 plotID, F32 x, F32 y, bool setAdded), (true), "(int plotID, float x, float y, bool setAdded = true;)"
"Add a data point to the given plot."
"@return")
{
@ -1060,7 +1060,7 @@ DefineConsoleMethod(GuiParticleGraphCtrl, addPlotPoint, S32, (S32 plotID, F32 x,
return object->addPlotPoint( plotID, Point2F(x, y), setAdded);
}
DefineConsoleMethod(GuiParticleGraphCtrl, insertPlotPoint, void, (S32 plotID, S32 i, F32 x, F32 y), , "(int plotID, int i, float x, float y)\n"
DefineEngineMethod(GuiParticleGraphCtrl, insertPlotPoint, void, (S32 plotID, S32 i, F32 x, F32 y), , "(int plotID, int i, float x, float y)\n"
"Insert a data point to the given plot and plot position.\n"
"@param plotID The plot you want to access\n"
"@param i The data point.\n"
@ -1075,7 +1075,7 @@ DefineConsoleMethod(GuiParticleGraphCtrl, insertPlotPoint, void, (S32 plotID, S3
object->insertPlotPoint( plotID, i, Point2F(x, y));
}
DefineConsoleMethod(GuiParticleGraphCtrl, changePlotPoint, S32, (S32 plotID, S32 i, F32 x, F32 y), , "(int plotID, int i, float x, float y)"
DefineEngineMethod(GuiParticleGraphCtrl, changePlotPoint, S32, (S32 plotID, S32 i, F32 x, F32 y), , "(int plotID, int i, float x, float y)"
"Change a data point to the given plot and plot position.\n"
"@param plotID The plot you want to access\n"
"@param i The data point.\n"
@ -1090,21 +1090,21 @@ DefineConsoleMethod(GuiParticleGraphCtrl, changePlotPoint, S32, (S32 plotID, S32
return object->changePlotPoint( plotID, i, Point2F(x, y));
}
DefineConsoleMethod(GuiParticleGraphCtrl, getSelectedPlot, S32, (), , "() "
DefineEngineMethod(GuiParticleGraphCtrl, getSelectedPlot, S32, (), , "() "
"Gets the selected Plot (a.k.a. graph).\n"
"@return The plot's ID.")
{
return object->getSelectedPlot();
}
DefineConsoleMethod(GuiParticleGraphCtrl, getSelectedPoint, S32, (), , "()"
DefineEngineMethod(GuiParticleGraphCtrl, getSelectedPoint, S32, (), , "()"
"Gets the selected Point on the Plot (a.k.a. graph)."
"@return The last selected point ID")
{
return object->getSelectedPoint();
}
DefineConsoleMethod(GuiParticleGraphCtrl, isExistingPoint, bool, (S32 plotID, S32 samples), , "(int plotID, int samples)"
DefineEngineMethod(GuiParticleGraphCtrl, isExistingPoint, bool, (S32 plotID, S32 samples), , "(int plotID, int samples)"
"@return Returns true or false whether or not the point in the plot passed is an existing point.")
{
@ -1119,7 +1119,7 @@ DefineConsoleMethod(GuiParticleGraphCtrl, isExistingPoint, bool, (S32 plotID, S3
return object->isExistingPoint(plotID, samples);
}
DefineConsoleMethod(GuiParticleGraphCtrl, getPlotPoint, Point2F, (S32 plotID, S32 samples), , "(int plotID, int samples)"
DefineEngineMethod(GuiParticleGraphCtrl, getPlotPoint, Point2F, (S32 plotID, S32 samples), , "(int plotID, int samples)"
"Get a data point from the plot specified, samples from the start of the graph."
"@return The data point ID")
{
@ -1137,7 +1137,7 @@ DefineConsoleMethod(GuiParticleGraphCtrl, getPlotPoint, Point2F, (S32 plotID, S3
return object->getPlotPoint(plotID, samples);
}
DefineConsoleMethod(GuiParticleGraphCtrl, getPlotIndex, S32, (S32 plotID, F32 x, F32 y), , "(int plotID, float x, float y)\n"
DefineEngineMethod(GuiParticleGraphCtrl, getPlotIndex, S32, (S32 plotID, F32 x, F32 y), , "(int plotID, float x, float y)\n"
"Gets the index of the point passed on the plotID passed (graph ID).\n"
"@param plotID The plot you wish to check.\n"
"@param x,y The coordinates of the point to get.\n"
@ -1151,7 +1151,7 @@ DefineConsoleMethod(GuiParticleGraphCtrl, getPlotIndex, S32, (S32 plotID, F32 x,
return object->getPlotIndex(plotID, x, y);
}
DefineConsoleMethod(GuiParticleGraphCtrl, getGraphColor, LinearColorF, (S32 plotID), , "(int plotID)"
DefineEngineMethod(GuiParticleGraphCtrl, getGraphColor, LinearColorF, (S32 plotID), , "(int plotID)"
"Get the color of the graph passed."
"@return Returns the color of the graph as a string of RGB values formatted as \"R G B\"")
{
@ -1165,7 +1165,7 @@ DefineConsoleMethod(GuiParticleGraphCtrl, getGraphColor, LinearColorF, (S32 plot
}
DefineConsoleMethod(GuiParticleGraphCtrl, getGraphMin, Point2F, (S32 plotID), , "(int plotID) "
DefineEngineMethod(GuiParticleGraphCtrl, getGraphMin, Point2F, (S32 plotID), , "(int plotID) "
"Get the minimum values of the graph ranges.\n"
"@return Returns the minimum of the range formatted as \"x-min y-min\"")
{
@ -1177,7 +1177,7 @@ DefineConsoleMethod(GuiParticleGraphCtrl, getGraphMin, Point2F, (S32 plotID), ,
return object->getGraphMin(plotID);
}
DefineConsoleMethod(GuiParticleGraphCtrl, getGraphMax, Point2F, (S32 plotID), , "(int plotID) "
DefineEngineMethod(GuiParticleGraphCtrl, getGraphMax, Point2F, (S32 plotID), , "(int plotID) "
"Get the maximum values of the graph ranges.\n"
"@return Returns the maximum of the range formatted as \"x-max y-max\"")
{
@ -1190,7 +1190,7 @@ DefineConsoleMethod(GuiParticleGraphCtrl, getGraphMax, Point2F, (S32 plotID), ,
}
DefineConsoleMethod(GuiParticleGraphCtrl, getGraphName, const char*, (S32 plotID), , "(int plotID) "
DefineEngineMethod(GuiParticleGraphCtrl, getGraphName, const char*, (S32 plotID), , "(int plotID) "
"Get the name of the graph passed.\n"
"@return Returns the name of the plot")
{
@ -1207,7 +1207,7 @@ DefineConsoleMethod(GuiParticleGraphCtrl, getGraphName, const char*, (S32 plotID
return retBuffer;
}
DefineConsoleMethod(GuiParticleGraphCtrl, setGraphMin, void, (S32 plotID, F32 minX, F32 minY), , "(int plotID, float minX, float minY) "
DefineEngineMethod(GuiParticleGraphCtrl, setGraphMin, void, (S32 plotID, F32 minX, F32 minY), , "(int plotID, float minX, float minY) "
"Set the min values of the graph of plotID.\n"
"@param plotID The plot to modify\n"
"@param minX,minY The minimum bound of the value range.\n"
@ -1223,7 +1223,7 @@ DefineConsoleMethod(GuiParticleGraphCtrl, setGraphMin, void, (S32 plotID, F32 mi
object->setGraphMin(plotID, Point2F(minX, minY));
}
DefineConsoleMethod(GuiParticleGraphCtrl, setGraphMinX, void, (S32 plotID, F32 minX), , "(int plotID, float minX) "
DefineEngineMethod(GuiParticleGraphCtrl, setGraphMinX, void, (S32 plotID, F32 minX), , "(int plotID, float minX) "
"Set the min X value of the graph of plotID.\n"
"@param plotID The plot to modify.\n"
"@param minX The minimum x value.\n"
@ -1239,7 +1239,7 @@ DefineConsoleMethod(GuiParticleGraphCtrl, setGraphMinX, void, (S32 plotID, F32 m
object->setGraphMinX(plotID, minX);
}
DefineConsoleMethod(GuiParticleGraphCtrl, setGraphMinY, void, (S32 plotID, F32 minX), , "(int plotID, float minY) "
DefineEngineMethod(GuiParticleGraphCtrl, setGraphMinY, void, (S32 plotID, F32 minX), , "(int plotID, float minY) "
"Set the min Y value of the graph of plotID."
"@param plotID The plot to modify.\n"
"@param minY The minimum y value.\n"
@ -1255,7 +1255,7 @@ DefineConsoleMethod(GuiParticleGraphCtrl, setGraphMinY, void, (S32 plotID, F32 m
object->setGraphMinY(plotID, minX);
}
DefineConsoleMethod(GuiParticleGraphCtrl, setGraphMax, void, (S32 plotID, F32 maxX, F32 maxY), , "(int plotID, float maxX, float maxY) "
DefineEngineMethod(GuiParticleGraphCtrl, setGraphMax, void, (S32 plotID, F32 maxX, F32 maxY), , "(int plotID, float maxX, float maxY) "
"Set the max values of the graph of plotID."
"@param plotID The plot to modify\n"
"@param maxX,maxY The maximum bound of the value range.\n"
@ -1271,7 +1271,7 @@ DefineConsoleMethod(GuiParticleGraphCtrl, setGraphMax, void, (S32 plotID, F32 ma
object->setGraphMax(plotID, Point2F(maxX, maxY));
}
DefineConsoleMethod(GuiParticleGraphCtrl, setGraphMaxX, void, (S32 plotID, F32 maxX), , "(int plotID, float maxX)"
DefineEngineMethod(GuiParticleGraphCtrl, setGraphMaxX, void, (S32 plotID, F32 maxX), , "(int plotID, float maxX)"
"Set the max X value of the graph of plotID."
"@param plotID The plot to modify.\n"
"@param maxX The maximum x value.\n"
@ -1287,7 +1287,7 @@ DefineConsoleMethod(GuiParticleGraphCtrl, setGraphMaxX, void, (S32 plotID, F32 m
object->setGraphMaxX(plotID, maxX);
}
DefineConsoleMethod(GuiParticleGraphCtrl, setGraphMaxY, void, (S32 plotID, F32 maxX), , "(int plotID, float maxY)"
DefineEngineMethod(GuiParticleGraphCtrl, setGraphMaxY, void, (S32 plotID, F32 maxX), , "(int plotID, float maxY)"
"Set the max Y value of the graph of plotID."
"@param plotID The plot to modify.\n"
"@param maxY The maximum y value.\n"
@ -1303,7 +1303,7 @@ DefineConsoleMethod(GuiParticleGraphCtrl, setGraphMaxY, void, (S32 plotID, F32 m
object->setGraphMaxY(plotID, maxX);
}
DefineConsoleMethod(GuiParticleGraphCtrl, setGraphHidden, void, (S32 plotID, bool isHidden), , "(int plotID, bool isHidden)"
DefineEngineMethod(GuiParticleGraphCtrl, setGraphHidden, void, (S32 plotID, bool isHidden), , "(int plotID, bool isHidden)"
"Set whether the graph number passed is hidden or not."
"@return No return value.")
{
@ -1317,7 +1317,7 @@ DefineConsoleMethod(GuiParticleGraphCtrl, setGraphHidden, void, (S32 plotID, boo
object->setGraphHidden(plotID, isHidden);
}
DefineConsoleMethod(GuiParticleGraphCtrl, setAutoGraphMax, void, (bool autoMax), , "(bool autoMax) "
DefineEngineMethod(GuiParticleGraphCtrl, setAutoGraphMax, void, (bool autoMax), , "(bool autoMax) "
"Set whether the max will automatically be set when adding points "
"(ie if you add a value over the current max, the max is increased to that value).\n"
"@return No return value.")
@ -1325,35 +1325,35 @@ DefineConsoleMethod(GuiParticleGraphCtrl, setAutoGraphMax, void, (bool autoMax),
object->setAutoGraphMax(autoMax);
}
DefineConsoleMethod(GuiParticleGraphCtrl, setAutoRemove, void, (bool autoRemove), , "(bool autoRemove) "
DefineEngineMethod(GuiParticleGraphCtrl, setAutoRemove, void, (bool autoRemove), , "(bool autoRemove) "
"Set whether or not a point should be deleted when you drag another one over it."
"@return No return value.")
{
object->setAutoRemove(autoRemove);
}
DefineConsoleMethod(GuiParticleGraphCtrl, setRenderAll, void, (bool autoRemove), , "(bool renderAll)"
DefineEngineMethod(GuiParticleGraphCtrl, setRenderAll, void, (bool autoRemove), , "(bool renderAll)"
"Set whether or not a position should be rendered on every point or just the last selected."
"@return No return value.")
{
object->setRenderAll(autoRemove);
}
DefineConsoleMethod(GuiParticleGraphCtrl, setPointXMovementClamped, void, (bool autoRemove), , "(bool clamped)"
DefineEngineMethod(GuiParticleGraphCtrl, setPointXMovementClamped, void, (bool autoRemove), , "(bool clamped)"
"Set whether the x position of the selected graph point should be clamped"
"@return No return value.")
{
object->setPointXMovementClamped(autoRemove);
}
DefineConsoleMethod(GuiParticleGraphCtrl, setRenderGraphTooltip, void, (bool autoRemove), , "(bool renderGraphTooltip)"
DefineEngineMethod(GuiParticleGraphCtrl, setRenderGraphTooltip, void, (bool autoRemove), , "(bool renderGraphTooltip)"
"Set whether or not to render the graph tooltip."
"@return No return value.")
{
object->setRenderGraphTooltip(autoRemove);
}
DefineConsoleMethod(GuiParticleGraphCtrl, setGraphName, void, (S32 plotID, const char * graphName), , "(int plotID, string graphName) "
DefineEngineMethod(GuiParticleGraphCtrl, setGraphName, void, (S32 plotID, const char * graphName), , "(int plotID, string graphName) "
"Set the name of the given plot.\n"
"@param plotID The plot to modify.\n"
"@param graphName The name to set on the plot.\n"
@ -1369,7 +1369,7 @@ DefineConsoleMethod(GuiParticleGraphCtrl, setGraphName, void, (S32 plotID, const
object->setGraphName(plotID, graphName);
}
DefineConsoleMethod(GuiParticleGraphCtrl, resetSelectedPoint, void, (), , "()"
DefineEngineMethod(GuiParticleGraphCtrl, resetSelectedPoint, void, (), , "()"
"This will reset the currently selected point to nothing."
"@return No return value.")
{

View file

@ -524,7 +524,7 @@ ConsoleMethod(GuiInspectorComponentGroup, removeDynamicField, void, 3, 3, "")
{
}
DefineConsoleMethod(GuiInspectorComponentGroup, getComponent, S32, (), ,"")
DefineEngineMethod(GuiInspectorComponentGroup, getComponent, S32, (), ,"")
{
return object->getComponent()->getId();
}

View file

@ -316,7 +316,7 @@ void GuiInspectorDynamicField::_executeSelectedCallback()
Con::executef( mInspector, "onFieldSelected", mDynField->slotName, "TypeDynamicField" );
}
DefineConsoleMethod( GuiInspectorDynamicField, renameField, void, (const char* newDynamicFieldName),, "field.renameField(newDynamicFieldName);" )
DefineEngineMethod( GuiInspectorDynamicField, renameField, void, (const char* newDynamicFieldName),, "field.renameField(newDynamicFieldName);" )
{
object->renameField( newDynamicFieldName );
}

View file

@ -188,7 +188,7 @@ void GuiInspectorDynamicGroup::updateAllFields()
inspectGroup();
}
DefineConsoleMethod(GuiInspectorDynamicGroup, inspectGroup, bool, (), , "Refreshes the dynamic fields in the inspector.")
DefineEngineMethod(GuiInspectorDynamicGroup, inspectGroup, bool, (), , "Refreshes the dynamic fields in the inspector.")
{
return object->inspectGroup();
}
@ -263,11 +263,11 @@ void GuiInspectorDynamicGroup::addDynamicField()
instantExpand();
}
DefineConsoleMethod( GuiInspectorDynamicGroup, addDynamicField, void, (), , "obj.addDynamicField();" )
DefineEngineMethod( GuiInspectorDynamicGroup, addDynamicField, void, (), , "obj.addDynamicField();" )
{
object->addDynamicField();
}
DefineConsoleMethod( GuiInspectorDynamicGroup, removeDynamicField, void, (), , "" )
DefineEngineMethod( GuiInspectorDynamicGroup, removeDynamicField, void, (), , "" )
{
}

View file

@ -688,59 +688,59 @@ void GuiInspectorField::_setFieldDocs( StringTableEntry docs )
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiInspectorField, getInspector, S32, (), , "() - Return the GuiInspector to which this field belongs." )
DefineEngineMethod( GuiInspectorField, getInspector, S32, (), , "() - Return the GuiInspector to which this field belongs." )
{
return object->getInspector()->getId();
}
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiInspectorField, getInspectedFieldName, const char*, (), , "() - Return the name of the field edited by this inspector field." )
DefineEngineMethod( GuiInspectorField, getInspectedFieldName, const char*, (), , "() - Return the name of the field edited by this inspector field." )
{
return object->getFieldName();
}
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiInspectorField, getInspectedFieldType, const char*, (), , "() - Return the type of the field edited by this inspector field." )
DefineEngineMethod( GuiInspectorField, getInspectedFieldType, const char*, (), , "() - Return the type of the field edited by this inspector field." )
{
return object->getFieldType();
}
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiInspectorField, apply, void, ( const char * newValue, bool callbacks ), (true), "( string newValue, bool callbacks=true ) - Set the field's value. Suppress callbacks for undo if callbacks=false." )
DefineEngineMethod( GuiInspectorField, apply, void, ( const char * newValue, bool callbacks ), (true), "( string newValue, bool callbacks=true ) - Set the field's value. Suppress callbacks for undo if callbacks=false." )
{
object->setData( newValue, callbacks );
}
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiInspectorField, applyWithoutUndo, void, (const char * data), , "() - Set field value without recording undo (same as 'apply( value, false )')." )
DefineEngineMethod( GuiInspectorField, applyWithoutUndo, void, (const char * data), , "() - Set field value without recording undo (same as 'apply( value, false )')." )
{
object->setData( data, false );
}
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiInspectorField, getData, const char*, (), , "() - Return the value currently displayed on the field." )
DefineEngineMethod( GuiInspectorField, getData, const char*, (), , "() - Return the value currently displayed on the field." )
{
return object->getData();
}
//-----------------------------------------------------------------------------
DefineConsoleMethod( GuiInspectorField, reset, void, (), , "() - Reset to default value." )
DefineEngineMethod( GuiInspectorField, reset, void, (), , "() - Reset to default value." )
{
object->resetData();
}
DefineConsoleMethod(GuiInspectorField, setCaption, void, (String newCaption),, "() - Reset to default value.")
DefineEngineMethod(GuiInspectorField, setCaption, void, (String newCaption),, "() - Reset to default value.")
{
object->setCaption(StringTable->insert(newCaption.c_str()));
}
DefineConsoleMethod(GuiInspectorField, setEditControl, void, (GuiControl* editCtrl), (nullAsType<GuiControl*>()), "() - Reset to default value.")
DefineEngineMethod(GuiInspectorField, setEditControl, void, (GuiControl* editCtrl), (nullAsType<GuiControl*>()), "() - Reset to default value.")
{
object->setEditControl(editCtrl);
}

View file

@ -250,12 +250,12 @@ GuiInspectorField* GuiInspectorVariableGroup::createInspectorField()
return NULL;
}
DefineConsoleMethod(GuiInspectorVariableGroup, createInspectorField, GuiInspectorField*, (),, "createInspectorField()")
DefineEngineMethod(GuiInspectorVariableGroup, createInspectorField, GuiInspectorField*, (),, "createInspectorField()")
{
return object->createInspectorField();
}
DefineConsoleMethod(GuiInspectorVariableGroup, addInspectorField, void, (GuiInspectorField* field), (nullAsType<GuiInspectorField*>()), "addInspectorField( GuiInspectorFieldObject )")
DefineEngineMethod(GuiInspectorVariableGroup, addInspectorField, void, (GuiInspectorField* field), (nullAsType<GuiInspectorField*>()), "addInspectorField( GuiInspectorFieldObject )")
{
object->addInspectorField(field);
}

View file

@ -216,17 +216,17 @@ void GuiVariableInspector::setFieldEnabled(const char* name, bool enabled)
}
}
DefineConsoleMethod(GuiVariableInspector, startGroup, void, (const char* name),, "startGroup( groupName )")
DefineEngineMethod(GuiVariableInspector, startGroup, void, (const char* name),, "startGroup( groupName )")
{
object->startGroup(name);
}
DefineConsoleMethod(GuiVariableInspector, endGroup, void, (),, "endGroup()")
DefineEngineMethod(GuiVariableInspector, endGroup, void, (),, "endGroup()")
{
object->endGroup();
}
DefineConsoleMethod(GuiVariableInspector, addField, void, (const char* name, const char* label, const char* typeName,
DefineEngineMethod(GuiVariableInspector, addField, void, (const char* name, const char* label, const char* typeName,
const char* description, const char* defaultValue, const char* dataValues, SimObject* ownerObj),
("","","","","", "", nullAsType<SimObject*>()), "addField( fieldName/varName, fieldLabel, fieldTypeName, description, defaultValue, defaultValues, ownerObject )")
{
@ -236,7 +236,7 @@ DefineConsoleMethod(GuiVariableInspector, addField, void, (const char* name, con
object->addField(name, label, typeName, description, defaultValue, dataValues, ownerObj);
}
DefineConsoleMethod(GuiVariableInspector, addCallbackField, void, (const char* name, const char* label, const char* typeName,
DefineEngineMethod(GuiVariableInspector, addCallbackField, void, (const char* name, const char* label, const char* typeName,
const char* description, const char* defaultValue, const char* dataValues, const char* callbackName, SimObject* ownerObj),
("", "", "", "", "", "", nullAsType<SimObject*>()), "addField( fieldName/varName, fieldLabel, fieldTypeName, description, defaultValue, defaultValues, callbackName, ownerObject )")
{
@ -246,22 +246,22 @@ DefineConsoleMethod(GuiVariableInspector, addCallbackField, void, (const char* n
object->addCallbackField(name, label, typeName, description, defaultValue, dataValues, callbackName, ownerObj);
}
DefineConsoleMethod(GuiVariableInspector, update, void, (), , "update()")
DefineEngineMethod(GuiVariableInspector, update, void, (), , "update()")
{
object->update();
}
DefineConsoleMethod(GuiVariableInspector, clearFields, void, (), , "clearFields()")
DefineEngineMethod(GuiVariableInspector, clearFields, void, (), , "clearFields()")
{
object->clearFields();
}
DefineConsoleMethod(GuiVariableInspector, setFieldEnabled, void, (const char* fieldName, bool isEnabled), (true), "setFieldEnabled( fieldName, isEnabled )")
DefineEngineMethod(GuiVariableInspector, setFieldEnabled, void, (const char* fieldName, bool isEnabled), (true), "setFieldEnabled( fieldName, isEnabled )")
{
object->setFieldEnabled(fieldName, isEnabled);
}
DefineConsoleMethod( GuiVariableInspector, loadVars, void, ( const char * searchString ), , "loadVars( searchString )" )
DefineEngineMethod( GuiVariableInspector, loadVars, void, ( const char * searchString ), , "loadVars( searchString )" )
{
object->loadVars( searchString );
}

View file

@ -445,17 +445,17 @@ void PopupMenu::hidePopupSubmenus()
//-----------------------------------------------------------------------------
// Console Methods
//-----------------------------------------------------------------------------
DefineConsoleMethod(PopupMenu, insertItem, S32, (S32 pos, const char * title, const char * accelerator, const char* cmd), ("", "", ""), "(pos[, title][, accelerator][, cmd])")
DefineEngineMethod(PopupMenu, insertItem, S32, (S32 pos, const char * title, const char * accelerator, const char* cmd), ("", "", ""), "(pos[, title][, accelerator][, cmd])")
{
return object->insertItem(pos, title, accelerator, cmd);
}
DefineConsoleMethod(PopupMenu, removeItem, void, (S32 pos), , "(pos)")
DefineEngineMethod(PopupMenu, removeItem, void, (S32 pos), , "(pos)")
{
object->removeItem(pos);
}
DefineConsoleMethod(PopupMenu, insertSubMenu, S32, (S32 pos, String title, String subMenu), , "(pos, title, subMenu)")
DefineEngineMethod(PopupMenu, insertSubMenu, S32, (S32 pos, String title, String subMenu), , "(pos, title, subMenu)")
{
PopupMenu *mnu = dynamic_cast<PopupMenu *>(Sim::findObject(subMenu));
if(mnu == NULL)
@ -466,40 +466,40 @@ DefineConsoleMethod(PopupMenu, insertSubMenu, S32, (S32 pos, String title, Strin
return object->insertSubMenu(pos, title, mnu);
}
DefineConsoleMethod(PopupMenu, setItem, bool, (S32 pos, const char * title, const char * accelerator, const char *cmd), (""), "(pos, title[, accelerator][, cmd])")
DefineEngineMethod(PopupMenu, setItem, bool, (S32 pos, const char * title, const char * accelerator, const char *cmd), (""), "(pos, title[, accelerator][, cmd])")
{
return object->setItem(pos, title, accelerator, cmd);
}
//-----------------------------------------------------------------------------
DefineConsoleMethod(PopupMenu, enableItem, void, (S32 pos, bool enabled), , "(pos, enabled)")
DefineEngineMethod(PopupMenu, enableItem, void, (S32 pos, bool enabled), , "(pos, enabled)")
{
object->enableItem(pos, enabled);
}
DefineConsoleMethod(PopupMenu, checkItem, void, (S32 pos, bool checked), , "(pos, checked)")
DefineEngineMethod(PopupMenu, checkItem, void, (S32 pos, bool checked), , "(pos, checked)")
{
object->checkItem(pos, checked);
}
DefineConsoleMethod(PopupMenu, checkRadioItem, void, (S32 firstPos, S32 lastPos, S32 checkPos), , "(firstPos, lastPos, checkPos)")
DefineEngineMethod(PopupMenu, checkRadioItem, void, (S32 firstPos, S32 lastPos, S32 checkPos), , "(firstPos, lastPos, checkPos)")
{
object->checkRadioItem(firstPos, lastPos, checkPos);
}
DefineConsoleMethod(PopupMenu, isItemChecked, bool, (S32 pos), , "(pos)")
DefineEngineMethod(PopupMenu, isItemChecked, bool, (S32 pos), , "(pos)")
{
return object->isItemChecked(pos);
}
DefineConsoleMethod(PopupMenu, getItemCount, S32, (), , "()")
DefineEngineMethod(PopupMenu, getItemCount, S32, (), , "()")
{
return object->getItemCount();
}
//-----------------------------------------------------------------------------
DefineConsoleMethod(PopupMenu, showPopup, void, (const char * canvasName, S32 x, S32 y), ( -1, -1), "(Canvas,[x, y])")
DefineEngineMethod(PopupMenu, showPopup, void, (const char * canvasName, S32 x, S32 y), ( -1, -1), "(Canvas,[x, y])")
{
GuiCanvas *pCanvas = dynamic_cast<GuiCanvas*>(Sim::findObject(canvasName));
object->showPopup(pCanvas, x, y);

View file

@ -177,13 +177,13 @@ ConsoleDocClass( GuiIdleCamFadeBitmapCtrl,
"This is going to be deprecated, and any useful code ported to FadeinBitmap\n\n"
"@internal");
DefineConsoleMethod(GuiIdleCamFadeBitmapCtrl, fadeIn, void, (), , "()"
DefineEngineMethod(GuiIdleCamFadeBitmapCtrl, fadeIn, void, (), , "()"
"@internal")
{
object->fadeIn();
}
DefineConsoleMethod(GuiIdleCamFadeBitmapCtrl, fadeOut, void, (), , "()"
DefineEngineMethod(GuiIdleCamFadeBitmapCtrl, fadeOut, void, (), , "()"
"@internal")
{
object->fadeOut();

View file

@ -59,7 +59,7 @@ static ConsoleDocFragment _setProcessTicks(
"void setProcessTicks( bool tick )"
);
DefineConsoleMethod( GuiTickCtrl, setProcessTicks, void, (bool tick), (true), "( [tick = true] ) - This will set this object to either be processing ticks or not" )
DefineEngineMethod( GuiTickCtrl, setProcessTicks, void, (bool tick), (true), "( [tick = true] ) - This will set this object to either be processing ticks or not" )
{
object->setProcessTicks(tick);
}

View file

@ -258,7 +258,7 @@ static ConsoleDocFragment _MessageVectordump2(
"MessageVector",
"void dump( string filename, string header);");
DefineConsoleMethod( MessageVector, dump, void, (const char * filename, const char * header), (""), "(string filename, string header=NULL)"
DefineEngineMethod( MessageVector, dump, void, (const char * filename, const char * header), (""), "(string filename, string header=NULL)"
"Dump the message vector to a file, optionally prefixing a header."
"@hide")
{

View file

@ -219,7 +219,7 @@ void CreatorTree::sort()
}
//------------------------------------------------------------------------------
DefineConsoleMethod( CreatorTree, addGroup, S32, (S32 group, const char * name, const char * value), , "(string group, string name, string value)")
DefineEngineMethod( CreatorTree, addGroup, S32, (S32 group, const char * name, const char * value), , "(string group, string name, string value)")
{
CreatorTree::Node * grp = object->findNode(group);
@ -236,7 +236,7 @@ DefineConsoleMethod( CreatorTree, addGroup, S32, (S32 group, const char * name,
return(node ? node->getId() : -1);
}
DefineConsoleMethod( CreatorTree, addItem, S32, (S32 group, const char * name, const char * value), , "(Node group, string name, string value)")
DefineEngineMethod( CreatorTree, addItem, S32, (S32 group, const char * name, const char * value), , "(Node group, string name, string value)")
{
CreatorTree::Node * grp = object->findNode(group);
@ -249,7 +249,7 @@ DefineConsoleMethod( CreatorTree, addItem, S32, (S32 group, const char * name, c
}
//------------------------------------------------------------------------------
DefineConsoleMethod( CreatorTree, fileNameMatch, bool, (const char * world, const char * type, const char * filename), , "(string world, string type, string filename)")
DefineEngineMethod( CreatorTree, fileNameMatch, bool, (const char * world, const char * type, const char * filename), , "(string world, string type, string filename)")
{
// argv[2] - world short
// argv[3] - type short
@ -269,12 +269,12 @@ DefineConsoleMethod( CreatorTree, fileNameMatch, bool, (const char * world, cons
return(!dStrnicmp(filename+1, type, typeLen));
}
DefineConsoleMethod( CreatorTree, getSelected, S32, (), , "Return a handle to the currently selected item.")
DefineEngineMethod( CreatorTree, getSelected, S32, (), , "Return a handle to the currently selected item.")
{
return(object->getSelected());
}
DefineConsoleMethod( CreatorTree, isGroup, bool, (const char * group), , "(Group g)")
DefineEngineMethod( CreatorTree, isGroup, bool, (const char * group), , "(Group g)")
{
CreatorTree::Node * node = object->findNode(dAtoi(group));
if(node && node->isGroup())
@ -282,24 +282,24 @@ DefineConsoleMethod( CreatorTree, isGroup, bool, (const char * group), , "(Group
return(false);
}
DefineConsoleMethod( CreatorTree, getName, const char*, (const char * item), , "(Node item)")
DefineEngineMethod( CreatorTree, getName, const char*, (const char * item), , "(Node item)")
{
CreatorTree::Node * node = object->findNode(dAtoi(item));
return(node ? node->mName : 0);
}
DefineConsoleMethod( CreatorTree, getValue, const char*, (S32 nodeValue), , "(Node n)")
DefineEngineMethod( CreatorTree, getValue, const char*, (S32 nodeValue), , "(Node n)")
{
CreatorTree::Node * node = object->findNode(nodeValue);
return(node ? node->mValue : 0);
}
DefineConsoleMethod( CreatorTree, clear, void, (), , "Clear the tree.")
DefineEngineMethod( CreatorTree, clear, void, (), , "Clear the tree.")
{
object->clear();
}
DefineConsoleMethod( CreatorTree, getParent, S32, (S32 nodeValue), , "(Node n)")
DefineEngineMethod( CreatorTree, getParent, S32, (S32 nodeValue), , "(Node n)")
{
CreatorTree::Node * node = object->findNode(nodeValue);
if(node && node->mParent)

View file

@ -128,7 +128,7 @@ static GameBase * getControlObj()
return(control);
}
DefineConsoleMethod( EditManager, setBookmark, void, (S32 val), , "(int slot)")
DefineEngineMethod( EditManager, setBookmark, void, (S32 val), , "(int slot)")
{
if(val < 0 || val > 9)
return;
@ -138,7 +138,7 @@ DefineConsoleMethod( EditManager, setBookmark, void, (S32 val), , "(int slot)")
object->mBookmarks[val] = control->getTransform();
}
DefineConsoleMethod( EditManager, gotoBookmark, void, (S32 val), , "(int slot)")
DefineEngineMethod( EditManager, gotoBookmark, void, (S32 val), , "(int slot)")
{
if(val < 0 || val > 9)
return;
@ -148,17 +148,17 @@ DefineConsoleMethod( EditManager, gotoBookmark, void, (S32 val), , "(int slot)")
control->setTransform(object->mBookmarks[val]);
}
DefineConsoleMethod( EditManager, editorEnabled, void, (), , "Perform the onEditorEnabled callback on all SimObjects and set gEditingMission true" )
DefineEngineMethod( EditManager, editorEnabled, void, (), , "Perform the onEditorEnabled callback on all SimObjects and set gEditingMission true" )
{
object->editorEnabled();
}
DefineConsoleMethod( EditManager, editorDisabled, void, (), , "Perform the onEditorDisabled callback on all SimObjects and set gEditingMission false" )
DefineEngineMethod( EditManager, editorDisabled, void, (), , "Perform the onEditorDisabled callback on all SimObjects and set gEditingMission false" )
{
object->editorDisabled();
}
DefineConsoleMethod( EditManager, isEditorEnabled, bool, (), , "Return the value of gEditingMission." )
DefineEngineMethod( EditManager, isEditorEnabled, bool, (), , "Return the value of gEditingMission." )
{
return gEditingMission;
}

View file

@ -2179,43 +2179,43 @@ void GuiConvexEditorCtrl::splitSelectedFace()
updateGizmoPos();
}
DefineConsoleMethod( GuiConvexEditorCtrl, hollowSelection, void, (), , "" )
DefineEngineMethod( GuiConvexEditorCtrl, hollowSelection, void, (), , "" )
{
object->hollowSelection();
}
DefineConsoleMethod( GuiConvexEditorCtrl, recenterSelection, void, (), , "" )
DefineEngineMethod( GuiConvexEditorCtrl, recenterSelection, void, (), , "" )
{
object->recenterSelection();
}
DefineConsoleMethod( GuiConvexEditorCtrl, hasSelection, S32, (), , "" )
DefineEngineMethod( GuiConvexEditorCtrl, hasSelection, S32, (), , "" )
{
return object->hasSelection();
}
DefineConsoleMethod( GuiConvexEditorCtrl, handleDelete, void, (), , "" )
DefineEngineMethod( GuiConvexEditorCtrl, handleDelete, void, (), , "" )
{
object->handleDelete();
}
DefineConsoleMethod( GuiConvexEditorCtrl, handleDeselect, void, (), , "" )
DefineEngineMethod( GuiConvexEditorCtrl, handleDeselect, void, (), , "" )
{
object->handleDeselect();
}
DefineConsoleMethod( GuiConvexEditorCtrl, dropSelectionAtScreenCenter, void, (), , "" )
DefineEngineMethod( GuiConvexEditorCtrl, dropSelectionAtScreenCenter, void, (), , "" )
{
object->dropSelectionAtScreenCenter();
}
DefineConsoleMethod( GuiConvexEditorCtrl, selectConvex, void, (ConvexShape *convex), , "( ConvexShape )" )
DefineEngineMethod( GuiConvexEditorCtrl, selectConvex, void, (ConvexShape *convex), , "( ConvexShape )" )
{
if (convex)
object->setSelection( convex, -1 );
}
DefineConsoleMethod( GuiConvexEditorCtrl, splitSelectedFace, void, (), , "" )
DefineEngineMethod( GuiConvexEditorCtrl, splitSelectedFace, void, (), , "" )
{
object->splitSelectedFace();
}

View file

@ -784,12 +784,12 @@ void GuiDecalEditorCtrl::setMode( String mode, bool sourceShortcut = false )
Con::executef( this, "paletteSync", mMode );
}
DefineConsoleMethod( GuiDecalEditorCtrl, deleteSelectedDecal, void, (), , "deleteSelectedDecal()" )
DefineEngineMethod( GuiDecalEditorCtrl, deleteSelectedDecal, void, (), , "deleteSelectedDecal()" )
{
object->deleteSelectedDecal();
}
DefineConsoleMethod( GuiDecalEditorCtrl, deleteDecalDatablock, void, ( const char * datablock ), , "deleteSelectedDecalDatablock( String datablock )" )
DefineEngineMethod( GuiDecalEditorCtrl, deleteDecalDatablock, void, ( const char * datablock ), , "deleteSelectedDecalDatablock( String datablock )" )
{
String lookupName( datablock );
if( lookupName == String::EmptyString )
@ -798,22 +798,22 @@ DefineConsoleMethod( GuiDecalEditorCtrl, deleteDecalDatablock, void, ( const cha
object->deleteDecalDatablock( lookupName );
}
DefineConsoleMethod( GuiDecalEditorCtrl, setMode, void, ( String newMode ), , "setMode( String mode )()" )
DefineEngineMethod( GuiDecalEditorCtrl, setMode, void, ( String newMode ), , "setMode( String mode )()" )
{
object->setMode( newMode );
}
DefineConsoleMethod( GuiDecalEditorCtrl, getMode, const char*, (), , "getMode()" )
DefineEngineMethod( GuiDecalEditorCtrl, getMode, const char*, (), , "getMode()" )
{
return object->mMode;
}
DefineConsoleMethod( GuiDecalEditorCtrl, getDecalCount, S32, (), , "getDecalCount()" )
DefineEngineMethod( GuiDecalEditorCtrl, getDecalCount, S32, (), , "getDecalCount()" )
{
return gDecalManager->mDecalInstanceVec.size();
}
DefineConsoleMethod( GuiDecalEditorCtrl, getDecalTransform, const char*, ( U32 id ), , "getDecalTransform()" )
DefineEngineMethod( GuiDecalEditorCtrl, getDecalTransform, const char*, ( U32 id ), , "getDecalTransform()" )
{
DecalInstance *decalInstance = gDecalManager->mDecalInstanceVec[id];
@ -835,7 +835,7 @@ DefineConsoleMethod( GuiDecalEditorCtrl, getDecalTransform, const char*, ( U32 i
return returnBuffer;
}
DefineConsoleMethod( GuiDecalEditorCtrl, getDecalLookupName, const char*, ( U32 id ), , "getDecalLookupName( S32 )()" )
DefineEngineMethod( GuiDecalEditorCtrl, getDecalLookupName, const char*, ( U32 id ), , "getDecalLookupName( S32 )()" )
{
DecalInstance *decalInstance = gDecalManager->mDecalInstanceVec[id];
if( decalInstance == NULL )
@ -844,7 +844,7 @@ DefineConsoleMethod( GuiDecalEditorCtrl, getDecalLookupName, const char*, ( U32
return decalInstance->mDataBlock->lookupName;
}
DefineConsoleMethod( GuiDecalEditorCtrl, selectDecal, void, ( U32 id ), , "selectDecal( S32 )()" )
DefineEngineMethod( GuiDecalEditorCtrl, selectDecal, void, ( U32 id ), , "selectDecal( S32 )()" )
{
DecalInstance *decalInstance = gDecalManager->mDecalInstanceVec[id];
if( decalInstance == NULL )
@ -853,7 +853,7 @@ DefineConsoleMethod( GuiDecalEditorCtrl, selectDecal, void, ( U32 id ), , "selec
object->selectDecal( decalInstance );
}
DefineConsoleMethod( GuiDecalEditorCtrl, editDecalDetails, void, ( U32 id, Point3F pos, Point3F tan,F32 size ), , "editDecalDetails( S32 )()" )
DefineEngineMethod( GuiDecalEditorCtrl, editDecalDetails, void, ( U32 id, Point3F pos, Point3F tan,F32 size ), , "editDecalDetails( S32 )()" )
{
DecalInstance *decalInstance = gDecalManager->mDecalInstanceVec[id];
if( decalInstance == NULL )
@ -872,14 +872,14 @@ DefineConsoleMethod( GuiDecalEditorCtrl, editDecalDetails, void, ( U32 id, Point
gDecalManager->notifyDecalModified( decalInstance );
}
DefineConsoleMethod( GuiDecalEditorCtrl, getSelectionCount, S32, (), , "" )
DefineEngineMethod( GuiDecalEditorCtrl, getSelectionCount, S32, (), , "" )
{
if ( object->mSELDecal != NULL )
return 1;
return 0;
}
DefineConsoleMethod( GuiDecalEditorCtrl, retargetDecalDatablock, void, ( const char * dbFrom, const char * dbTo ), , "" )
DefineEngineMethod( GuiDecalEditorCtrl, retargetDecalDatablock, void, ( const char * dbFrom, const char * dbTo ), , "" )
{
if( dStrcmp( dbFrom, "" ) != 0 && dStrcmp( dbTo, "" ) != 0 )
object->retargetDecalDatablock( dbFrom, dbTo );

View file

@ -95,7 +95,7 @@ void GuiMissionAreaEditorCtrl::setSelectedMissionArea( MissionArea *missionArea
Con::executef( this, "onMissionAreaSelected" );
}
DefineConsoleMethod( GuiMissionAreaEditorCtrl, setSelectedMissionArea, void, (const char * missionAreaName), (""), "" )
DefineEngineMethod( GuiMissionAreaEditorCtrl, setSelectedMissionArea, void, (const char * missionAreaName), (""), "" )
{
if ( dStrcmp( missionAreaName, "" )==0 )
object->setSelectedMissionArea(NULL);
@ -107,7 +107,7 @@ DefineConsoleMethod( GuiMissionAreaEditorCtrl, setSelectedMissionArea, void, (co
}
}
DefineConsoleMethod( GuiMissionAreaEditorCtrl, getSelectedMissionArea, const char*, (), , "" )
DefineEngineMethod( GuiMissionAreaEditorCtrl, getSelectedMissionArea, const char*, (), , "" )
{
MissionArea *missionArea = object->getSelectedMissionArea();
if ( !missionArea )

View file

@ -88,35 +88,35 @@ void GuiTerrPreviewCtrl::initPersistFields()
}
DefineConsoleMethod( GuiTerrPreviewCtrl, reset, void, (), , "Reset the view of the terrain.")
DefineEngineMethod( GuiTerrPreviewCtrl, reset, void, (), , "Reset the view of the terrain.")
{
object->reset();
}
DefineConsoleMethod( GuiTerrPreviewCtrl, setRoot, void, (), , "Add the origin to the root and reset the origin.")
DefineEngineMethod( GuiTerrPreviewCtrl, setRoot, void, (), , "Add the origin to the root and reset the origin.")
{
object->setRoot();
}
DefineConsoleMethod( GuiTerrPreviewCtrl, getRoot, Point2F, (), , "Return a Point2F representing the position of the root.")
DefineEngineMethod( GuiTerrPreviewCtrl, getRoot, Point2F, (), , "Return a Point2F representing the position of the root.")
{
return object->getRoot();
}
DefineConsoleMethod( GuiTerrPreviewCtrl, setOrigin, void, (Point2F pos), , "(float x, float y)"
DefineEngineMethod( GuiTerrPreviewCtrl, setOrigin, void, (Point2F pos), , "(float x, float y)"
"Set the origin of the view.")
{
object->setOrigin( pos );
}
DefineConsoleMethod( GuiTerrPreviewCtrl, getOrigin, Point2F, (), , "Return a Point2F containing the position of the origin.")
DefineEngineMethod( GuiTerrPreviewCtrl, getOrigin, Point2F, (), , "Return a Point2F containing the position of the origin.")
{
return object->getOrigin();
}
DefineConsoleMethod( GuiTerrPreviewCtrl, getValue, const char*, (), , "Returns a 4-tuple containing: root_x root_y origin_x origin_y")
DefineEngineMethod( GuiTerrPreviewCtrl, getValue, const char*, (), , "Returns a 4-tuple containing: root_x root_y origin_x origin_y")
{
Point2F r = object->getRoot();
Point2F o = object->getOrigin();
@ -126,7 +126,7 @@ DefineConsoleMethod( GuiTerrPreviewCtrl, getValue, const char*, (), , "Returns a
return valuebuf;
}
DefineConsoleMethod( GuiTerrPreviewCtrl, setValue, void, (const char * tuple), , "Accepts a 4-tuple in the same form as getValue returns.\n\n"
DefineEngineMethod( GuiTerrPreviewCtrl, setValue, void, (const char * tuple), , "Accepts a 4-tuple in the same form as getValue returns.\n\n"
"@see GuiTerrPreviewCtrl::getValue()")
{
Point2F r,o;

View file

@ -795,7 +795,7 @@ void TerrainSmoothAction::smooth( TerrainBlock *terrain, F32 factor, U32 steps )
redo();
}
DefineConsoleMethod( TerrainSmoothAction, smooth, void, ( TerrainBlock *terrain, F32 factor, U32 steps ), , "( TerrainBlock obj, F32 factor, U32 steps )")
DefineEngineMethod( TerrainSmoothAction, smooth, void, ( TerrainBlock *terrain, F32 factor, U32 steps ), , "( TerrainBlock obj, F32 factor, U32 steps )")
{
if (terrain)
object->smooth( terrain, factor, mClamp( steps, 1, 13 ) );

View file

@ -2403,7 +2403,7 @@ void TerrainEditor::reorderMaterial( S32 index, S32 orderPos )
//------------------------------------------------------------------------------
DefineConsoleMethod( TerrainEditor, attachTerrain, void, (const char * terrain), (""), "(TerrainBlock terrain)")
DefineEngineMethod( TerrainEditor, attachTerrain, void, (const char * terrain), (""), "(TerrainBlock terrain)")
{
SimSet * missionGroup = dynamic_cast<SimSet*>(Sim::findObject("MissionGroup"));
if (!missionGroup)
@ -2459,12 +2459,12 @@ DefineConsoleMethod( TerrainEditor, attachTerrain, void, (const char * terrain),
}
}
DefineConsoleMethod( TerrainEditor, getTerrainBlockCount, S32, (), , "()")
DefineEngineMethod( TerrainEditor, getTerrainBlockCount, S32, (), , "()")
{
return object->getTerrainBlockCount();
}
DefineConsoleMethod( TerrainEditor, getTerrainBlock, S32, (S32 index), , "(S32 index)")
DefineEngineMethod( TerrainEditor, getTerrainBlock, S32, (S32 index), , "(S32 index)")
{
TerrainBlock* tb = object->getTerrainBlock(index);
if(!tb)
@ -2473,7 +2473,7 @@ DefineConsoleMethod( TerrainEditor, getTerrainBlock, S32, (S32 index), , "(S32 i
return tb->getId();
}
DefineConsoleMethod(TerrainEditor, getTerrainBlocksMaterialList, const char *, (), , "() gets the list of current terrain materials for all terrain blocks.")
DefineEngineMethod(TerrainEditor, getTerrainBlocksMaterialList, const char *, (), , "() gets the list of current terrain materials for all terrain blocks.")
{
Vector<StringTableEntry> list;
object->getTerrainBlocksMaterialList(list);
@ -2502,23 +2502,23 @@ DefineConsoleMethod(TerrainEditor, getTerrainBlocksMaterialList, const char *, (
return ret;
}
DefineConsoleMethod( TerrainEditor, setBrushType, void, (String type), , "(string type)"
DefineEngineMethod( TerrainEditor, setBrushType, void, (String type), , "(string type)"
"One of box, ellipse, selection.")
{
object->setBrushType(type);
}
DefineConsoleMethod( TerrainEditor, getBrushType, const char*, (), , "()")
DefineEngineMethod( TerrainEditor, getBrushType, const char*, (), , "()")
{
return object->getBrushType();
}
DefineConsoleMethod( TerrainEditor, setBrushSize, void, ( S32 w, S32 h), (0), "(int w [, int h])")
DefineEngineMethod( TerrainEditor, setBrushSize, void, ( S32 w, S32 h), (0), "(int w [, int h])")
{
object->setBrushSize( w, h==0?w:h );
}
DefineConsoleMethod( TerrainEditor, getBrushSize, const char*, (), , "()")
DefineEngineMethod( TerrainEditor, getBrushSize, const char*, (), , "()")
{
Point2I size = object->getBrushSize();
@ -2528,74 +2528,74 @@ DefineConsoleMethod( TerrainEditor, getBrushSize, const char*, (), , "()")
return ret;
}
DefineConsoleMethod( TerrainEditor, setBrushPressure, void, (F32 pressure), , "(float pressure)")
DefineEngineMethod( TerrainEditor, setBrushPressure, void, (F32 pressure), , "(float pressure)")
{
object->setBrushPressure( pressure );
}
DefineConsoleMethod( TerrainEditor, getBrushPressure, F32, (), , "()")
DefineEngineMethod( TerrainEditor, getBrushPressure, F32, (), , "()")
{
return object->getBrushPressure();
}
DefineConsoleMethod( TerrainEditor, setBrushSoftness, void, (F32 softness), , "(float softness)")
DefineEngineMethod( TerrainEditor, setBrushSoftness, void, (F32 softness), , "(float softness)")
{
object->setBrushSoftness( softness );
}
DefineConsoleMethod( TerrainEditor, getBrushSoftness, F32, (), , "()")
DefineEngineMethod( TerrainEditor, getBrushSoftness, F32, (), , "()")
{
return object->getBrushSoftness();
}
DefineConsoleMethod( TerrainEditor, getBrushPos, const char*, (), , "Returns a Point2I.")
DefineEngineMethod( TerrainEditor, getBrushPos, const char*, (), , "Returns a Point2I.")
{
return object->getBrushPos();
}
DefineConsoleMethod( TerrainEditor, setBrushPos, void, (Point2I pos), , "Location")
DefineEngineMethod( TerrainEditor, setBrushPos, void, (Point2I pos), , "Location")
{
object->setBrushPos(pos);
}
DefineConsoleMethod( TerrainEditor, setAction, void, (const char * action_name), , "(string action_name)")
DefineEngineMethod( TerrainEditor, setAction, void, (const char * action_name), , "(string action_name)")
{
object->setAction(action_name);
}
DefineConsoleMethod( TerrainEditor, getActionName, const char*, (U32 index), , "(int num)")
DefineEngineMethod( TerrainEditor, getActionName, const char*, (U32 index), , "(int num)")
{
return (object->getActionName(index));
}
DefineConsoleMethod( TerrainEditor, getNumActions, S32, (), , "")
DefineEngineMethod( TerrainEditor, getNumActions, S32, (), , "")
{
return(object->getNumActions());
}
DefineConsoleMethod( TerrainEditor, getCurrentAction, const char*, (), , "")
DefineEngineMethod( TerrainEditor, getCurrentAction, const char*, (), , "")
{
return object->getCurrentAction();
}
DefineConsoleMethod( TerrainEditor, resetSelWeights, void, (bool clear), , "(bool clear)")
DefineEngineMethod( TerrainEditor, resetSelWeights, void, (bool clear), , "(bool clear)")
{
object->resetSelWeights(clear);
}
DefineConsoleMethod( TerrainEditor, clearSelection, void, (), , "")
DefineEngineMethod( TerrainEditor, clearSelection, void, (), , "")
{
object->clearSelection();
}
DefineConsoleMethod( TerrainEditor, processAction, void, (String action), (""), "(string action=NULL)")
DefineEngineMethod( TerrainEditor, processAction, void, (String action), (""), "(string action=NULL)")
{
object->processAction(action);
}
DefineConsoleMethod( TerrainEditor, getActiveTerrain, S32, (), , "")
DefineEngineMethod( TerrainEditor, getActiveTerrain, S32, (), , "")
{
S32 ret = 0;
@ -2607,27 +2607,27 @@ DefineConsoleMethod( TerrainEditor, getActiveTerrain, S32, (), , "")
return ret;
}
DefineConsoleMethod( TerrainEditor, getNumTextures, S32, (), , "")
DefineEngineMethod( TerrainEditor, getNumTextures, S32, (), , "")
{
return object->getNumTextures();
}
DefineConsoleMethod( TerrainEditor, markEmptySquares, void, (), , "")
DefineEngineMethod( TerrainEditor, markEmptySquares, void, (), , "")
{
object->markEmptySquares();
}
DefineConsoleMethod( TerrainEditor, mirrorTerrain, void, (S32 mirrorIndex), , "")
DefineEngineMethod( TerrainEditor, mirrorTerrain, void, (S32 mirrorIndex), , "")
{
object->mirrorTerrain(mirrorIndex);
}
DefineConsoleMethod(TerrainEditor, setTerraformOverlay, void, (bool overlayEnable), , "(bool overlayEnable) - sets the terraformer current heightmap to draw as an overlay over the current terrain.")
DefineEngineMethod(TerrainEditor, setTerraformOverlay, void, (bool overlayEnable), , "(bool overlayEnable) - sets the terraformer current heightmap to draw as an overlay over the current terrain.")
{
// XA: This one needs to be implemented :)
}
DefineConsoleMethod(TerrainEditor, updateMaterial, bool, ( U32 index, String matName ), ,
DefineEngineMethod(TerrainEditor, updateMaterial, bool, ( U32 index, String matName ), ,
"( int index, string matName )\n"
"Changes the material name at the index." )
{
@ -2645,7 +2645,7 @@ DefineConsoleMethod(TerrainEditor, updateMaterial, bool, ( U32 index, String mat
return true;
}
DefineConsoleMethod(TerrainEditor, addMaterial, S32, ( String matName ), ,
DefineEngineMethod(TerrainEditor, addMaterial, S32, ( String matName ), ,
"( string matName )\n"
"Adds a new material." )
{
@ -2660,7 +2660,7 @@ DefineConsoleMethod(TerrainEditor, addMaterial, S32, ( String matName ), ,
return true;
}
DefineConsoleMethod( TerrainEditor, removeMaterial, void, ( S32 index ), , "( int index ) - Remove the material at the given index." )
DefineEngineMethod( TerrainEditor, removeMaterial, void, ( S32 index ), , "( int index ) - Remove the material at the given index." )
{
TerrainBlock *terr = object->getClientTerrain();
if ( !terr )
@ -2689,7 +2689,7 @@ DefineConsoleMethod( TerrainEditor, removeMaterial, void, ( S32 index ), , "( in
object->setGridUpdateMinMax();
}
DefineConsoleMethod(TerrainEditor, getMaterialCount, S32, (), ,
DefineEngineMethod(TerrainEditor, getMaterialCount, S32, (), ,
"Returns the current material count." )
{
TerrainBlock *terr = object->getClientTerrain();
@ -2699,7 +2699,7 @@ DefineConsoleMethod(TerrainEditor, getMaterialCount, S32, (), ,
return 0;
}
DefineConsoleMethod(TerrainEditor, getMaterials, const char *, (), , "() gets the list of current terrain materials.")
DefineEngineMethod(TerrainEditor, getMaterials, const char *, (), , "() gets the list of current terrain materials.")
{
TerrainBlock *terr = object->getClientTerrain();
if ( !terr )
@ -2716,7 +2716,7 @@ DefineConsoleMethod(TerrainEditor, getMaterials, const char *, (), , "() gets th
return ret;
}
DefineConsoleMethod( TerrainEditor, getMaterialName, const char*, (S32 index), , "( int index ) - Returns the name of the material at the given index." )
DefineEngineMethod( TerrainEditor, getMaterialName, const char*, (S32 index), , "( int index ) - Returns the name of the material at the given index." )
{
TerrainBlock *terr = object->getClientTerrain();
if ( !terr )
@ -2732,7 +2732,7 @@ DefineConsoleMethod( TerrainEditor, getMaterialName, const char*, (S32 index), ,
return Con::getReturnBuffer( name );
}
DefineConsoleMethod( TerrainEditor, getMaterialIndex, S32, ( String name ), , "( string name ) - Returns the index of the material with the given name or -1." )
DefineEngineMethod( TerrainEditor, getMaterialIndex, S32, ( String name ), , "( string name ) - Returns the index of the material with the given name or -1." )
{
TerrainBlock *terr = object->getClientTerrain();
if ( !terr )
@ -2747,13 +2747,13 @@ DefineConsoleMethod( TerrainEditor, getMaterialIndex, S32, ( String name ), , "(
return -1;
}
DefineConsoleMethod( TerrainEditor, reorderMaterial, void, ( S32 index, S32 orderPos ), , "( int index, int order ) "
DefineEngineMethod( TerrainEditor, reorderMaterial, void, ( S32 index, S32 orderPos ), , "( int index, int order ) "
"- Reorder material at the given index to the new position, changing the order in which it is rendered / blended." )
{
object->reorderMaterial( index, orderPos );
}
DefineConsoleMethod(TerrainEditor, getTerrainUnderWorldPoint, S32, (const char * ptOrX, const char * Y, const char * Z), ("", "", ""),
DefineEngineMethod(TerrainEditor, getTerrainUnderWorldPoint, S32, (const char * ptOrX, const char * Y, const char * Z), ("", "", ""),
"(x/y/z) Gets the terrain block that is located under the given world point.\n"
"@param x/y/z The world coordinates (floating point values) you wish to query at. "
"These can be formatted as either a string (\"x y z\") or separately as (x, y, z)\n"
@ -2822,12 +2822,12 @@ void TerrainEditor::initPersistFields()
Parent::initPersistFields();
}
DefineConsoleMethod( TerrainEditor, getSlopeLimitMinAngle, F32, (), , "")
DefineEngineMethod( TerrainEditor, getSlopeLimitMinAngle, F32, (), , "")
{
return object->mSlopeMinAngle;
}
DefineConsoleMethod( TerrainEditor, setSlopeLimitMinAngle, F32, (F32 angle), , "")
DefineEngineMethod( TerrainEditor, setSlopeLimitMinAngle, F32, (F32 angle), , "")
{
if ( angle < 0.0f )
angle = 0.0f;
@ -2838,12 +2838,12 @@ DefineConsoleMethod( TerrainEditor, setSlopeLimitMinAngle, F32, (F32 angle), , "
return angle;
}
DefineConsoleMethod( TerrainEditor, getSlopeLimitMaxAngle, F32, (), , "")
DefineEngineMethod( TerrainEditor, getSlopeLimitMaxAngle, F32, (), , "")
{
return object->mSlopeMaxAngle;
}
DefineConsoleMethod( TerrainEditor, setSlopeLimitMaxAngle, F32, (F32 angle), , "")
DefineEngineMethod( TerrainEditor, setSlopeLimitMaxAngle, F32, (F32 angle), , "")
{
if ( angle > 90.0f )
angle = 90.0f;

View file

@ -3252,7 +3252,7 @@ DefineEngineMethod( WorldEditor, getActiveSelection, S32, (),,
return object->getActiveSelectionSet()->getId();
}
DefineConsoleMethod( WorldEditor, setActiveSelection, void, ( WorldEditorSelection* selection), ,
DefineEngineMethod( WorldEditor, setActiveSelection, void, ( WorldEditorSelection* selection), ,
"Set the currently active WorldEditorSelection object.\n"
"@param selection A WorldEditorSelectionSet object to use for the selection container.")
{

View file

@ -329,7 +329,7 @@ void LangTable::setCurrentLanguage(S32 langid)
DefineConsoleMethod(LangTable, addLanguage, S32, (String filename, String languageName), ("", ""),
DefineEngineMethod(LangTable, addLanguage, S32, (String filename, String languageName), ("", ""),
"(string filename, [string languageName])"
"@brief Adds a language to the table\n\n"
"@param filename Name and path to the language file\n"
@ -343,7 +343,7 @@ DefineConsoleMethod(LangTable, addLanguage, S32, (String filename, String langua
return object->addLanguage(scriptFilenameBuffer, (const UTF8*)languageName);
}
DefineConsoleMethod(LangTable, getString, const char *, (U32 id), ,
DefineEngineMethod(LangTable, getString, const char *, (U32 id), ,
"(string filename)"
"@brief Grabs a string from the specified table\n\n"
"If an invalid is passed, the function will attempt to "
@ -363,14 +363,14 @@ DefineConsoleMethod(LangTable, getString, const char *, (U32 id), ,
return "";
}
DefineConsoleMethod(LangTable, setDefaultLanguage, void, (S32 langId), , "(int language)"
DefineEngineMethod(LangTable, setDefaultLanguage, void, (S32 langId), , "(int language)"
"@brief Sets the default language table\n\n"
"@param language ID of the table\n")
{
object->setDefaultLanguage(langId);
}
DefineConsoleMethod(LangTable, setCurrentLanguage, void, (S32 langId), ,
DefineEngineMethod(LangTable, setCurrentLanguage, void, (S32 langId), ,
"(int language)"
"@brief Sets the current language table for grabbing text\n\n"
"@param language ID of the table\n")
@ -378,14 +378,14 @@ DefineConsoleMethod(LangTable, setCurrentLanguage, void, (S32 langId), ,
object->setCurrentLanguage(langId);
}
DefineConsoleMethod(LangTable, getCurrentLanguage, S32, (), , "()"
DefineEngineMethod(LangTable, getCurrentLanguage, S32, (), , "()"
"@brief Get the ID of the current language table\n\n"
"@return Numerical ID of the current language table")
{
return object->getCurrentLanguage();
}
DefineConsoleMethod(LangTable, getLangName, const char *, (S32 langId), , "(int language)"
DefineEngineMethod(LangTable, getLangName, const char *, (S32 langId), , "(int language)"
"@brief Return the readable name of the language table\n\n"
"@param language Numerical ID of the language table to access\n\n"
"@return String containing the name of the table, NULL if ID was invalid or name was never specified")
@ -402,7 +402,7 @@ DefineConsoleMethod(LangTable, getLangName, const char *, (S32 langId), , "(int
return "";
}
DefineConsoleMethod(LangTable, getNumLang, S32, (), , "()"
DefineEngineMethod(LangTable, getNumLang, S32, (), , "()"
"@brief Used to find out how many languages are in the table\n\n"
"@return Size of the vector containing the languages, numerical")
{

View file

@ -629,25 +629,25 @@ void Material::StageData::getFeatureSet( FeatureSet *outFeatures ) const
}
}
DefineConsoleMethod( Material, flush, void, (),,
DefineEngineMethod( Material, flush, void, (),,
"Flushes all material instances that use this material." )
{
object->flush();
}
DefineConsoleMethod( Material, reload, void, (),,
DefineEngineMethod( Material, reload, void, (),,
"Reloads all material instances that use this material." )
{
object->reload();
}
DefineConsoleMethod( Material, dumpInstances, void, (),,
DefineEngineMethod( Material, dumpInstances, void, (),,
"Dumps a formatted list of the currently allocated material instances for this material to the console." )
{
MATMGR->dumpMaterialInstances( object );
}
DefineConsoleMethod( Material, getAnimFlags, const char*, (U32 id), , "" )
DefineEngineMethod( Material, getAnimFlags, const char*, (U32 id), , "" )
{
char * animFlags = Con::getReturnBuffer(512);
@ -688,19 +688,19 @@ DefineConsoleMethod( Material, getAnimFlags, const char*, (U32 id), , "" )
return animFlags;
}
DefineConsoleMethod(Material, getFilename, const char*, (),, "Get filename of material")
DefineEngineMethod(Material, getFilename, const char*, (),, "Get filename of material")
{
SimObject *material = static_cast<SimObject *>(object);
return material->getFilename();
}
DefineConsoleMethod( Material, isAutoGenerated, bool, (),,
DefineEngineMethod( Material, isAutoGenerated, bool, (),,
"Returns true if this Material was automatically generated by MaterialList::mapMaterials()" )
{
return object->isAutoGenerated();
}
DefineConsoleMethod( Material, setAutoGenerated, void, (bool isAutoGenerated), ,
DefineEngineMethod( Material, setAutoGenerated, void, (bool isAutoGenerated), ,
"setAutoGenerated(bool isAutoGenerated): Set whether or not the Material is autogenerated." )
{
object->setAutoGenerated(isAutoGenerated);

View file

@ -64,17 +64,17 @@ void SimResponseCurve::clear()
mCurve.clear();
}
DefineConsoleMethod( SimResponseCurve, addPoint, void, ( F32 value, F32 time ), , "addPoint( F32 value, F32 time )" )
DefineEngineMethod( SimResponseCurve, addPoint, void, ( F32 value, F32 time ), , "addPoint( F32 value, F32 time )" )
{
object->addPoint( value, time );
}
DefineConsoleMethod( SimResponseCurve, getValue, F32, ( F32 time ), , "getValue( F32 time )" )
DefineEngineMethod( SimResponseCurve, getValue, F32, ( F32 time ), , "getValue( F32 time )" )
{
return object->getValue( time );
}
DefineConsoleMethod( SimResponseCurve, clear, void, (), , "clear()" )
DefineEngineMethod( SimResponseCurve, clear, void, (), , "clear()" )
{
object->clear();
}

View file

@ -1517,7 +1517,7 @@ DefineEngineMethod( SceneObject, isGlobalBounds, bool, (),,
return object->isGlobalBounds();
}
DefineConsoleMethod(SceneObject, setForwardVector, void, (VectorF newForward, VectorF upVector), (VectorF(0, 0, 0), VectorF(0, 0, 1)),
DefineEngineMethod(SceneObject, setForwardVector, void, (VectorF newForward, VectorF upVector), (VectorF(0, 0, 0), VectorF(0, 0, 1)),
"Sets the forward vector of a scene object, making it face Y+ along the new vector.\n"
"@param The new forward vector to set.\n"
"@param (Optional) The up vector to use to help orient the rotation.")

View file

@ -1569,7 +1569,7 @@ static ConsoleDocFragment _sSetTransform2(
"void setTransform( Point3F position, Point3F direction )"
);
DefineConsoleMethod( SFXSource, setTransform, void, ( const char * position, const char * direction ), ( "" ),
DefineEngineMethod( SFXSource, setTransform, void, ( const char * position, const char * direction ), ( "" ),
"( vector position [, vector direction ] ) "
"Set the position and orientation of a 3D sound source.\n"
"@hide" )

View file

@ -137,7 +137,7 @@ bool TerrainBlock::exportLayerMaps( const UTF8 *filePrefix, const String &format
return true;
}
DefineConsoleMethod( TerrainBlock, exportHeightMap, bool, (const char * fileNameStr, const char * format), ( "png"), "(string filename, [string format]) - export the terrain block's heightmap to a bitmap file (default: png)" )
DefineEngineMethod( TerrainBlock, exportHeightMap, bool, (const char * fileNameStr, const char * format), ( "png"), "(string filename, [string format]) - export the terrain block's heightmap to a bitmap file (default: png)" )
{
UTF8 fileName[1024];
Con::expandScriptFilename( fileName, sizeof( fileName ), fileNameStr );
@ -145,7 +145,7 @@ DefineConsoleMethod( TerrainBlock, exportHeightMap, bool, (const char * fileName
return object->exportHeightMap( fileName, format );
}
DefineConsoleMethod( TerrainBlock, exportLayerMaps, bool, (const char * filePrefixStr, const char * format), ( "png"), "(string filePrefix, [string format]) - export the terrain block's layer maps to bitmap files (default: png)" )
DefineEngineMethod( TerrainBlock, exportLayerMaps, bool, (const char * filePrefixStr, const char * format), ( "png"), "(string filePrefix, [string format]) - export the terrain block's layer maps to bitmap files (default: png)" )
{
UTF8 filePrefix[1024];
Con::expandScriptFilename( filePrefix, sizeof( filePrefix ), filePrefixStr );

View file

@ -420,7 +420,7 @@ void EventManager::dumpSubscribers()
//-----------------------------------------------------------------------------
// Console Methods
//-----------------------------------------------------------------------------
DefineConsoleMethod( EventManager, registerEvent, bool, ( const char * evt ), , "( String event )\n"
DefineEngineMethod( EventManager, registerEvent, bool, ( const char * evt ), , "( String event )\n"
"Register an event with the event manager.\n"
"@param event The event to register.\n"
"@return Whether or not the event was registered successfully." )
@ -428,14 +428,14 @@ DefineConsoleMethod( EventManager, registerEvent, bool, ( const char * evt ), ,
return object->registerEvent( evt );
}
DefineConsoleMethod( EventManager, unregisterEvent, void, ( const char * evt ), , "( String event )\n"
DefineEngineMethod( EventManager, unregisterEvent, void, ( const char * evt ), , "( String event )\n"
"Remove an event from the EventManager.\n"
"@param event The event to remove.\n" )
{
object->unregisterEvent( evt );
}
DefineConsoleMethod( EventManager, isRegisteredEvent, bool, ( const char * evt ), , "( String event )\n"
DefineEngineMethod( EventManager, isRegisteredEvent, bool, ( const char * evt ), , "( String event )\n"
"Check if an event is registered or not.\n"
"@param event The event to check.\n"
"@return Whether or not the event exists." )
@ -443,7 +443,7 @@ DefineConsoleMethod( EventManager, isRegisteredEvent, bool, ( const char * evt )
return object->isRegisteredEvent( evt );
}
DefineConsoleMethod( EventManager, postEvent, bool, ( const char * evt, const char * data ), (""), "( String event, String data )\n"
DefineEngineMethod( EventManager, postEvent, bool, ( const char * evt, const char * data ), (""), "( String event, String data )\n"
"~Trigger an event.\n"
"@param event The event to trigger.\n"
"@param data The data associated with the event.\n"
@ -458,7 +458,7 @@ DefineConsoleMethod( EventManager, postEvent, bool, ( const char * evt, const ch
return object->postEvent( evt, data );
}
DefineConsoleMethod( EventManager, subscribe, bool, ( const char * listenerName, const char * evt, const char * callback ), (""), "( SimObject listener, String event, String callback )\n\n"
DefineEngineMethod( EventManager, subscribe, bool, ( const char * listenerName, const char * evt, const char * callback ), (""), "( SimObject listener, String event, String callback )\n\n"
"Subscribe a listener to an event.\n"
"@param listener The listener to subscribe.\n"
"@param event The event to subscribe to.\n"
@ -476,7 +476,7 @@ DefineConsoleMethod( EventManager, subscribe, bool, ( const char * listenerName,
return object->subscribe( cbObj, evt, callback );
}
DefineConsoleMethod( EventManager, remove, void, ( const char * listenerName, const char * evt), , "( SimObject listener, String event )\n\n"
DefineEngineMethod( EventManager, remove, void, ( const char * listenerName, const char * evt), , "( SimObject listener, String event )\n\n"
"Remove a listener from an event.\n"
"@param listener The listener to remove.\n"
"@param event The event to be removed from.\n")
@ -487,7 +487,7 @@ DefineConsoleMethod( EventManager, remove, void, ( const char * listenerName, co
object->remove( listener, evt );
}
DefineConsoleMethod( EventManager, removeAll, void, ( const char * listenerName ), , "( SimObject listener )\n\n"
DefineEngineMethod( EventManager, removeAll, void, ( const char * listenerName ), , "( SimObject listener )\n\n"
"Remove a listener from all events.\n"
"@param listener The listener to remove.\n")
{
@ -498,13 +498,13 @@ DefineConsoleMethod( EventManager, removeAll, void, ( const char * listenerName
object->removeAll( listener );
}
DefineConsoleMethod( EventManager, dumpEvents, void, (), , "()\n\n"
DefineEngineMethod( EventManager, dumpEvents, void, (), , "()\n\n"
"Print all registered events to the console." )
{
object->dumpEvents();
}
DefineConsoleMethod( EventManager, dumpSubscribers, void, ( const char * listenerName ), (""), "( String event )\n\n"
DefineEngineMethod( EventManager, dumpSubscribers, void, ( const char * listenerName ), (""), "( String event )\n\n"
"Print all subscribers to an event to the console.\n"
"@param event The event whose subscribers are to be printed. If this parameter isn't specified, all events will be dumped." )
{

View file

@ -155,19 +155,19 @@ const char *Message::getType()
// Console Methods
//-----------------------------------------------------------------------------
DefineConsoleMethod(Message, getType, const char *, (), , "() Get message type (script class name or C++ class name if no script defined class)")
DefineEngineMethod(Message, getType, const char *, (), , "() Get message type (script class name or C++ class name if no script defined class)")
{
return object->getType();
}
//-----------------------------------------------------------------------------
DefineConsoleMethod(Message, addReference, void, (), , "() Increment the reference count for this message")
DefineEngineMethod(Message, addReference, void, (), , "() Increment the reference count for this message")
{
object->addReference();
}
DefineConsoleMethod(Message, freeReference, void, (), , "() Decrement the reference count for this message")
DefineEngineMethod(Message, freeReference, void, (), , "() Decrement the reference count for this message")
{
object->freeReference();
}

View file

@ -482,12 +482,12 @@ const char* Settings::findNextValue()
}
// make sure to replace the strings
DefineConsoleMethod(Settings, findFirstValue, const char*, ( const char* pattern, bool deepSearch, bool includeDefaults ), ("", false, false), "settingObj.findFirstValue();")
DefineEngineMethod(Settings, findFirstValue, const char*, ( const char* pattern, bool deepSearch, bool includeDefaults ), ("", false, false), "settingObj.findFirstValue();")
{
return object->findFirstValue( pattern, deepSearch, includeDefaults );
}
DefineConsoleMethod(Settings, findNextValue, const char*, (), , "settingObj.findNextValue();")
DefineEngineMethod(Settings, findNextValue, const char*, (), , "settingObj.findNextValue();")
{
return object->findNextValue();
}
@ -644,7 +644,7 @@ void SettingSaveNode::buildDocument(SimXMLDocument *document, bool skipWrite)
document->popElement();
}
DefineConsoleMethod(Settings, setValue, void, (const char * settingName, const char * value), (""), "settingObj.setValue(settingName, value);")
DefineEngineMethod(Settings, setValue, void, (const char * settingName, const char * value), (""), "settingObj.setValue(settingName, value);")
{
StringTableEntry fieldName = StringTable->insert( settingName );
@ -654,13 +654,13 @@ DefineConsoleMethod(Settings, setValue, void, (const char * settingName, const c
object->setValue( fieldName );
}
DefineConsoleMethod(Settings, setDefaultValue, void, (const char * settingName, const char * value), , "settingObj.setDefaultValue(settingName, value);")
DefineEngineMethod(Settings, setDefaultValue, void, (const char * settingName, const char * value), , "settingObj.setDefaultValue(settingName, value);")
{
StringTableEntry fieldName = StringTable->insert( settingName );
object->setDefaultValue( fieldName, value );
}
DefineConsoleMethod(Settings, value, const char*, (const char * settingName, const char * defaultValue), (""), "settingObj.value(settingName, defaultValue);")
DefineEngineMethod(Settings, value, const char*, (const char * settingName, const char * defaultValue), (""), "settingObj.value(settingName, defaultValue);")
{
StringTableEntry fieldName = StringTable->insert( settingName );
@ -672,7 +672,7 @@ DefineConsoleMethod(Settings, value, const char*, (const char * settingName, con
return "";
}
DefineConsoleMethod(Settings, remove, void, (const char * settingName, bool includeDefaults), (false), "settingObj.remove(settingName, includeDefaults = false);")
DefineEngineMethod(Settings, remove, void, (const char * settingName, bool includeDefaults), (false), "settingObj.remove(settingName, includeDefaults = false);")
{
// there's a problem with some fields not being removed properly, but works if you run it twice,
// a temporary solution for now is simply to call the remove twice
@ -687,27 +687,27 @@ ConsoleMethod(Settings, write, bool, 2, 2, "%success = settingObj.write();")
return object->write();
}
DefineConsoleMethod(Settings, read, bool, (), , "%success = settingObj.read();")
DefineEngineMethod(Settings, read, bool, (), , "%success = settingObj.read();")
{
return object->read();
}
DefineConsoleMethod(Settings, beginGroup, void, (const char * groupName, bool includeDefaults), (false), "settingObj.beginGroup(groupName, fromStart = false);")
DefineEngineMethod(Settings, beginGroup, void, (const char * groupName, bool includeDefaults), (false), "settingObj.beginGroup(groupName, fromStart = false);")
{
object->beginGroup( groupName, includeDefaults );
}
DefineConsoleMethod(Settings, endGroup, void, (), , "settingObj.endGroup();")
DefineEngineMethod(Settings, endGroup, void, (), , "settingObj.endGroup();")
{
object->endGroup();
}
DefineConsoleMethod(Settings, clearGroups, void, (), , "settingObj.clearGroups();")
DefineEngineMethod(Settings, clearGroups, void, (), , "settingObj.clearGroups();")
{
object->clearGroups();
}
DefineConsoleMethod(Settings, getCurrentGroups, const char*, (), , "settingObj.getCurrentGroups();")
DefineEngineMethod(Settings, getCurrentGroups, const char*, (), , "settingObj.getCurrentGroups();")
{
return object->getCurrentGroups();
}

View file

@ -145,7 +145,7 @@ void CompoundUndoAction::onDeleteNotify( SimObject* object )
Parent::onDeleteNotify( object );
}
DefineConsoleMethod( CompoundUndoAction, addAction, void, (const char * objName), , "addAction( UndoAction )" )
DefineEngineMethod( CompoundUndoAction, addAction, void, (const char * objName), , "addAction( UndoAction )" )
{
UndoAction *action;
if ( Sim::findObject( objName, action ) )
@ -206,7 +206,7 @@ UndoManager& UndoManager::getDefaultManager()
return *defaultMan;
}
DefineConsoleMethod(UndoManager, clearAll, void, (),, "Clears the undo manager.")
DefineEngineMethod(UndoManager, clearAll, void, (),, "Clears the undo manager.")
{
object->clearAll();
}
@ -344,7 +344,7 @@ void UndoManager::redo()
(*react).redo();
}
DefineConsoleMethod(UndoManager, getUndoCount, S32, (),, "")
DefineEngineMethod(UndoManager, getUndoCount, S32, (),, "")
{
return object->getUndoCount();
}
@ -354,7 +354,7 @@ S32 UndoManager::getUndoCount()
return mUndoStack.size();
}
DefineConsoleMethod(UndoManager, getUndoName, const char*, (S32 index), , "(index)")
DefineEngineMethod(UndoManager, getUndoName, const char*, (S32 index), , "(index)")
{
return object->getUndoName(index);
}
@ -367,7 +367,7 @@ const char* UndoManager::getUndoName(S32 index)
return NULL;
}
DefineConsoleMethod(UndoManager, getUndoAction, S32, (S32 index), , "(index)")
DefineEngineMethod(UndoManager, getUndoAction, S32, (S32 index), , "(index)")
{
UndoAction * action = object->getUndoAction(index);
if ( !action )
@ -386,7 +386,7 @@ UndoAction* UndoManager::getUndoAction(S32 index)
return NULL;
}
DefineConsoleMethod(UndoManager, getRedoCount, S32, (),, "")
DefineEngineMethod(UndoManager, getRedoCount, S32, (),, "")
{
return object->getRedoCount();
}
@ -396,7 +396,7 @@ S32 UndoManager::getRedoCount()
return mRedoStack.size();
}
DefineConsoleMethod(UndoManager, getRedoName, const char*, (S32 index), , "(index)")
DefineEngineMethod(UndoManager, getRedoName, const char*, (S32 index), , "(index)")
{
return object->getRedoName(index);
}
@ -409,7 +409,7 @@ const char* UndoManager::getRedoName(S32 index)
return NULL;
}
DefineConsoleMethod(UndoManager, getRedoAction, S32, (S32 index), , "(index)")
DefineEngineMethod(UndoManager, getRedoAction, S32, (S32 index), , "(index)")
{
UndoAction * action = object->getRedoAction(index);
@ -501,7 +501,7 @@ void UndoManager::popCompound( bool discard )
}
//-----------------------------------------------------------------------------
DefineConsoleMethod(UndoAction, addToManager, void, (const char * undoManager), (""), "action.addToManager([undoManager])")
DefineEngineMethod(UndoAction, addToManager, void, (const char * undoManager), (""), "action.addToManager([undoManager])")
{
UndoManager *theMan = NULL;
if (!String::isEmpty(undoManager))
@ -515,32 +515,32 @@ DefineConsoleMethod(UndoAction, addToManager, void, (const char * undoManager),
//-----------------------------------------------------------------------------
DefineConsoleMethod( UndoAction, undo, void, (),, "() - Undo action contained in undo." )
DefineEngineMethod( UndoAction, undo, void, (),, "() - Undo action contained in undo." )
{
object->undo();
}
//-----------------------------------------------------------------------------
DefineConsoleMethod( UndoAction, redo, void, (),, "() - Reo action contained in undo." )
DefineEngineMethod( UndoAction, redo, void, (),, "() - Reo action contained in undo." )
{
object->redo();
}
//-----------------------------------------------------------------------------
DefineConsoleMethod(UndoManager, undo, void, (),, "UndoManager.undo();")
DefineEngineMethod(UndoManager, undo, void, (),, "UndoManager.undo();")
{
object->undo();
}
//-----------------------------------------------------------------------------
DefineConsoleMethod(UndoManager, redo, void, (),, "UndoManager.redo();")
DefineEngineMethod(UndoManager, redo, void, (),, "UndoManager.redo();")
{
object->redo();
}
//-----------------------------------------------------------------------------
DefineConsoleMethod(UndoManager, getNextUndoName, const char *, (),, "UndoManager.getNextUndoName();")
DefineEngineMethod(UndoManager, getNextUndoName, const char *, (),, "UndoManager.getNextUndoName();")
{
const char *name = object->getNextUndoName();
if(!name)
@ -552,7 +552,7 @@ DefineConsoleMethod(UndoManager, getNextUndoName, const char *, (),, "UndoManage
}
//-----------------------------------------------------------------------------
DefineConsoleMethod(UndoManager, getNextRedoName, const char *, (),, "UndoManager.getNextRedoName();")
DefineEngineMethod(UndoManager, getNextRedoName, const char *, (),, "UndoManager.getNextRedoName();")
{
const char *name = object->getNextRedoName();
if(!name)
@ -565,7 +565,7 @@ DefineConsoleMethod(UndoManager, getNextRedoName, const char *, (),, "UndoManage
//-----------------------------------------------------------------------------
DefineConsoleMethod( UndoManager, pushCompound, const char*, ( String name ), ("\"\""), "( string name=\"\" ) - Push a CompoundUndoAction onto the compound stack for assembly." )
DefineEngineMethod( UndoManager, pushCompound, const char*, ( String name ), ("\"\""), "( string name=\"\" ) - Push a CompoundUndoAction onto the compound stack for assembly." )
{
CompoundUndoAction* action = object->pushCompound( name );
@ -580,7 +580,7 @@ DefineConsoleMethod( UndoManager, pushCompound, const char*, ( String name ), ("
//-----------------------------------------------------------------------------
DefineConsoleMethod( UndoManager, popCompound, void, ( bool discard ), (false), "( bool discard=false ) - Pop the current CompoundUndoAction off the stack." )
DefineEngineMethod( UndoManager, popCompound, void, ( bool discard ), (false), "( bool discard=false ) - Pop the current CompoundUndoAction off the stack." )
{
if( !object->getCompoundStackDepth() )
{