VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
humanDamagePSR.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2018 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 
6 #pragma once
7 
9 #include <readerWriter/rwReal.h>
10 #include <readerWriter/rwString.h>
11 #include <readerWriter//rwInt.h>
12 #include <vrfutil/rwTemplatedMap.h>
13 
15 
17 
19 {
20 public:
21 
24  const DtString& rwName = DtString::nullString(),
25  DtReaderWriterRegistry* parentRegistry = 0);
26 
29  const DtString& rwName = DtString::nullString(),
30  DtReaderWriterRegistry* parentRegistry = 0);
31 
33  virtual ~DtHumanDamagePSR() override;
34 
37 
40  const DtString& rwName = DtString::nullString(), DtReaderWriterRegistry* parentRegistry = 0) const override;
41 
43  virtual DtString type() const override;
44 
45  virtual void setCurrentDamageState(DtDamageState state);
46  virtual DtDamageState currentDamageState() const;
47 
49  virtual void setTimeToRecover(double recoverTime);
50  virtual double timeToRecover() const;
51 
53  virtual void addPowerType(const DtRwString & powerType, const double initialLevel = 0);
54 
56  virtual void setPowerLevel(DtString & powerType, const double level);
57  virtual double powerLevel(DtString & powerType);
58 
59  virtual const CumulativePowersMap& cumulativePowersMap() const;
60  virtual CumulativePowersMap& cumulativePowersMap();
61 
63  static DtVrfProcessStateRepository* creator(const DtString& rwName,
64  DtLocalObject* vrfObject, DtReaderWriterRegistry* parentRegistry);
65 
66 protected:
71 
77 };
78 
CumulativePowersMap myCumulativePowersMap
Keep track when we save out scenario on current level of health of the entity.
Definition: humanDamagePSR.h:73
Holds data and provides accessors pertinent to damage adjudication. E.g. time destroyed.
Definition: damageAdjudicationPSR.h:18
virtual DtVrfProcessStateRepository * clone(const DtString &rwName=DtString::nullString(), DtReaderWriterRegistry *parentRegistry=0) const override
Returns a newly created copy of this object.
DT_DLL_VRVCORE DtTaitBryan level(const DtCoordinateSystem &cs, const DtVector &localOrigin, double topoHeading)
Returns a level orientation with the topographic heading.
Description: Readable, Writable DtString Variable substitutions are done on this object when it is re...
Definition: rwString.h:20
Definition: readerWriterRegistry.h:39
#define DT_DLL_vrfobjcore
This file is used to determine how to build.
Definition: vrfobjcoreDefines.h:24
Description: Readable, Writable int.
Definition: rwInt.h:25
virtual DtString type() const override
Returns the string type of this process state repository.
Description: Readable, Writable DtReal (double)
Definition: rwReal.h:27
Definition: humanDamagePSR.h:18
Class DtVrfProcessStateRepository: Abstract base class for all process state repositories. Process state repositories represent (potentially) shared, savable information for one or more components functioning together to achieve some process or set of processes; such as aiming and firing a weapon; moving an object; or just waiting a specified amount of time.
Definition: vrfProcessStateRepository.h:45
DtRwReal myTimeToRecover
Time to recover from stunned state. Can only recover from that state. Once prone, entity isn&#39;t gettin...
Definition: humanDamagePSR.h:76
DtDamageAdjudicationPSR & operator=(const DtDamageAdjudicationPSR &orig)
Assignment operator.
DtRwTemplatedMapPtr< DtRwString, DtRwReal > CumulativePowersMap
Definition: humanDamagePSR.h:16
static DtVrfProcessStateRepository * creator(const DtString &rwName, DtLocalObject *vrfObject, DtReaderWriterRegistry *parentRegistry)
Returns a newly created instance of this class.
A locally simulated VRF object.
Definition: localObject.h:98
DtRwInt myCurrentDamageState
Previous Damage State. We add this in case some one calls set appearance and changes the damage state...
Definition: humanDamagePSR.h:70

Document ID: Generated on Thu Oct 23 22:29:17 EDT 2025 from SVN revision 280951
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)