VR-Forces 4.1 Class Documentation
Extended Object Manager

This subclass of the DtVrfObjectManager prints out a message in its tick() method


Header file:

/*******************************************************************************
** Copyright (c) 2003 MAK Technologies, Inc.
** All rights reserved.
*******************************************************************************/
/*******************************************************************************
** $RCSfile: myObjectManager.h,v $ $Revision: 1.4 $ $State: Exp $
*******************************************************************************/
#ifndef MyObjectManager_H_
#define MyObjectManager_H_
{
public:
//The constructor takes a DtSimManager and entityAdvisory which get passed
//to the base class
MyObjectManager(DtSimManager* simManager, int entityAdvisory);
//destructor
virtual ~MyObjectManager();
//This is a good place to add your own behavior.
virtual void tick();
public:
//Creator function to be registered with the DtDefaultVrfCreator from
//main.cxx
static DtVrfObjectManager* creator(DtSimManager* simManager,
int entityAdvisory);
};
#endif

Implementation:

/*******************************************************************************
** Copyright (c) 2003 MAK Technologies, Inc.
** All rights reserved.
*******************************************************************************/
/*******************************************************************************
** $RCSfile: myObjectManager.cxx,v $ $Revision: 1.3 $ $State: Exp $
*******************************************************************************/
#include "myObjectManager.h"
//It is important to pass the DtSimManager to the constructor of the base class
MyObjectManager::MyObjectManager(DtSimManager* simManager, int entityAdvisory) :
DtVrfObjectManager(simManager)
{
}
{
}
{
//This is a good place to add your own functionality. For instance, if you
//were making an after action review tool, this might be a good place to
//connect to a database to store simulation information.
DtInfo("MyObjectManager::tick()\n");
//In order for VR-Forces to function, it is vital to call down to the base
//class !
}
//The creator simply calls new. It is important to pass on the DtSimManager.
int entityAdvisory)
{
return new MyObjectManager(simManager, entityAdvisory);
}

Document ID: Generated on Tue Jan 29 18:21:16 EST 2013 from SVN revision 123193
Copyright © 2005-2013 VT MÄK Inc. All Rights Reserved (www.mak.com)