Public Member Functions

FBApplyManagerRule Class Reference

Search for all occurrences

Detailed Description

ApplyManagerRules are used to define custom rules for manipulating custom objects.

It controls the relationship between the custom type objects and MB Core objects. For example, you can use it to allow the connection between your custom ragdoll physical property and the MB core character type object. And thus you can drag the ragdoll property from the asset browser or from scene navigator and attach it to a character.

Warning:
You shouldn't override the system default rule. All the function should return false if won't handle the call back.

Definition at line 114 of file fbapplymanagerrule.h.

#include <fbapplymanagerrule.h>

Inheritance diagram for FBApplyManagerRule:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 FBApplyManagerRule (HIObject pObject=NULL)
 Constructor.
virtual bool IsValidSrc (FBComponent *)
 Return true if pSrc is the type of custom object which this rule to be defined for.
virtual bool IsValidConnection (FBComponent *pSrc, FBComponent *&pDst, bool &pAllowMultiple)
 Return true if pDst is the type of custom or MB object which your custom object pSrc will be applied on.
virtual bool MenuBuild (FBAMMenu *pAMMenu, FBComponent *pFocusedObject)
 Build context menu for the type of custom object.
virtual bool MenuAction (int pMenuId, FBComponent *pFocusedObject)
 Perform action if the added menu item is clicked.

Constructor & Destructor Documentation

FBApplyManagerRule ( HIObject  pObject = NULL)

Constructor.

Parameters:
pObjectFor internal use only (default is NULL).

Member Function Documentation

virtual bool IsValidSrc ( FBComponent ) [inline, virtual]

Return true if pSrc is the type of custom object which this rule to be defined for.

Warning:
you should only return true if pSrc is the type of custom object you defined.

Definition at line 129 of file fbapplymanagerrule.h.

{ return false; }
virtual bool IsValidConnection ( FBComponent pSrc,
FBComponent *&  pDst,
bool &  pAllowMultiple 
) [inline, virtual]

Return true if pDst is the type of custom or MB object which your custom object pSrc will be applied on.

it's possible to return proper destination and return it by pDst. For example, pSrc is RagDoll Property, pDst is a one of IK/FK bone, then you can find associated Character and replace.

Parameters:
pSrcthe custom type of object you drag it to attach another object.
Return values:
pDstone of the selected destinations, it could be modified and return proper destination.
pAllowMultiplereturn true if allow multiple objects of same type as pSrc to be connected to pDst.
Returns:
return true if connection between pSrc and pDst is allowed.

Definition at line 142 of file fbapplymanagerrule.h.

{ return false; }
virtual bool MenuBuild ( FBAMMenu pAMMenu,
FBComponent pFocusedObject 
) [inline, virtual]

Build context menu for the type of custom object.

Parameters:
pAMMenuthe menu to add menu option on.
pFocusedObjectthe custom type of object you right-click on.
Returns:
return true if menu item has been added.

Definition at line 150 of file fbapplymanagerrule.h.

{ return false; }
virtual bool MenuAction ( int  pMenuId,
FBComponent pFocusedObject 
) [inline, virtual]

Perform action if the added menu item is clicked.

Parameters:
pMenuIdthe menu ID right-click on.
pFocusedObjectthe custom type of object right-click on.
Returns:
return true if action has been performed.

Definition at line 158 of file fbapplymanagerrule.h.

{ return false; }

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

FBApplyManagerRule FBApplyManagerRule FBApplyManagerRule FBApplyManagerRule FBApplyManagerRule FBApplyManagerRule FBApplyManagerRule FBApplyManagerRule FBApplyManagerRule FBApplyManagerRule
FBApplyManagerRule FBApplyManagerRule FBApplyManagerRule FBApplyManagerRule FBApplyManagerRule FBApplyManagerRule FBApplyManagerRule FBApplyManagerRule FBApplyManagerRule FBApplyManagerRule