VR-Forces 4.0.4 Class Documentation
examples/bhaveSdkModifySpeed/sandConstraint.h
Go to the documentation of this file.
00001 /*******************************************************************************
00002 ** Copyright (c) 2011 MAK Technologies, Inc.
00003 ** All rights reserved.
00004 *******************************************************************************/
00005 
00006 #pragma once
00007 
00008 #include <bhaveSim/preferredTerraintypeConstraint.h>
00009 #include <kyruntime.h>
00010 
00011 
00012 namespace BHAVE
00013 {
00014 
00019 class DtSandConstraint : public DtPreferredTerrainTypeConstraint
00020 {
00021 public:
00022    KY_DECLARE_CONSTRAINT(DtSandConstraint);
00023 
00024    DtSandConstraint();
00025 
00026    //Cost functions for constraints. See Kynapse documentation.
00027    KyBool GetCost(Kaim::Bot* bot, const Kaim::PointWrapper& from, const Kaim::PointWrapper& to, KyFloat32& cost);
00028    KyBool GetCost_PathFinding(Kaim::Bot& bot, const Kaim::PointWrapper& from, const Kaim::PointWrapper& to, KyFloat32& cost);
00029    KyBool GetCost_PathFollowing(Kaim::Bot& bot, const Kaim::PointWrapper& from, const Kaim::PointWrapper& to, KyFloat32& cost);
00030 
00031 protected:
00032    //Determines the cost of passing through this particular terrain type
00033    KyFloat32 GetCostRatio(const Kaim::NavTerrainTypeMask& terrainType) const;
00034 };
00035 
00036 } //namespace BHAVE
00037 
00038 

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)