VR-Forces 4.0.4 Class Documentation
include/vrfmodel/launchSmokeCtlr.h
Go to the documentation of this file.
00001 /*******************************************************************************
00002 ** Copyright (c) 2008 MAK Technologies, Inc.
00003 ** All rights reserved.
00004 *******************************************************************************/
00005 /*******************************************************************************
00006 ** $RCSfile: launchSmokeCtlr.h,v $ $Revision: 1.6 $ $State: Exp $
00007 *******************************************************************************/
00008 
00011 
00012 #ifndef launchSmokeController_H_
00013 #define launchSmokeController_H_
00014 
00015 #include <list>
00016 #include "vrfobjcore/singleTaskControllerComponent.h"
00017 #include "vlutil/vlString.h"
00018 #include "vrfmodel/vrfmodelDefines.h"
00019 
00020 class DtRwSensorContactInfo;
00021 class DtLaunchSmokeControllerDescriptor;
00022 
00027 class DT_DLL_vrfmodel DtLaunchSmokeController : public DtSingleTaskControllerComponent
00028 {
00029 public:
00031    DtLaunchSmokeController(const DtString & name, DtVrfObject* owner, 
00032       DtSimManager * simManager, DtComponentDescriptor* desc = NULL,
00033       DtReaderWriterRegistry * parentRegistry = 0);
00034 
00036    virtual ~DtLaunchSmokeController();
00037 
00039    DtLaunchSmokeController(const DtLaunchSmokeController& orig);
00040 
00042    DtLaunchSmokeController& operator=(const DtLaunchSmokeController& orig);
00043 
00046    virtual DtString type() const;
00047 
00049    virtual void registerTaskMsgCallbacks();
00050 
00054    static void launchSmokeTaskCallback(DtSimMessage * msg, void * usr);
00055 
00058    virtual void processLaunchSmokeTask(DtSimMessage * msg);
00059 
00062    virtual bool init();
00063 
00065    virtual void tick();
00066 
00068    static DtSimComponent* creator(const DtString & name, DtVrfObject* owner,
00069       DtSimManager * simManager, DtComponentDescriptor* desc,
00070       DtReaderWriterRegistry * parentRegistry);
00071 
00073    virtual bool useSmokeBomb();
00074 
00077    virtual bool launchSmoke();
00078 
00080    virtual void sendDetonation(const DtVector& geocLoc) const;
00081 
00083    virtual void launchSmokeTowards(double heading);
00084 
00086    virtual double calculateHeadingTowards(DtRwSensorContactInfo* closest) const;
00087 
00089    virtual DtRwSensorContactInfo* findClosestThreat() const;
00090 
00092    virtual void terrainClamp(const DtVector& geocLocIn, DtVector& geocLocOut) const;
00093 
00095    virtual void createSmoke(const std::list<DtVector>& cloudLocations);
00096 
00097 protected:
00098    const DtLaunchSmokeControllerDescriptor* myDesc;
00099    std::list<DtVector> myPoints;
00100    double myArcRange;
00101 
00103    bool myLaunchAtNearestThreat;
00104    double myHeading;
00105 };
00106 
00107 #endif

Document ID: Generated on Fri Jun 29 16:33:32 EDT 2012 from SVN revision 116588
Copyright © 2005-2012 VT MÄK Inc. All Rights Reserved (www.mak.com)