1 // Ryzom - MMORPG Framework <http://dev.ryzom.com/projects/ryzom/>
2 // Copyright (C) 2010 Winch Gate Property Limited
4 // This program is free software: you can redistribute it and/or modify
5 // it under the terms of the GNU Affero General Public License as
6 // published by the Free Software Foundation, either version 3 of the
7 // License, or (at your option) any later version.
9 // This program is distributed in the hope that it will be useful,
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 // GNU Affero General Public License for more details.
14 // You should have received a copy of the GNU Affero General Public License
15 // along with this program. If not, see <http://www.gnu.org/licenses/>.
22 #include "nel/misc/debug.h"
23 #include "nel/misc/string_conversion.h"
26 using namespace NLMISC
;
28 uint8
CCombat::_MaxHistoryDepth
= 2;
30 namespace COMBAT_HISTORY
33 // The conversion table
34 NL_BEGIN_STRING_CONVERSION_TABLE (TCombatHistory
)
35 NL_STRING_CONVERSION_TABLE_ENTRY (Miss
)
36 NL_STRING_CONVERSION_TABLE_ENTRY (Fumble
)
37 NL_STRING_CONVERSION_TABLE_ENTRY (Parry
)
38 NL_STRING_CONVERSION_TABLE_ENTRY (Dodge
)
39 NL_STRING_CONVERSION_TABLE_ENTRY (HitHead
)
40 NL_STRING_CONVERSION_TABLE_ENTRY (HitChest
)
41 NL_STRING_CONVERSION_TABLE_ENTRY (HitArms
)
42 NL_STRING_CONVERSION_TABLE_ENTRY (HitHands
)
43 NL_STRING_CONVERSION_TABLE_ENTRY (HitLegs
)
44 NL_STRING_CONVERSION_TABLE_ENTRY (HitFeet
)
45 NL_STRING_CONVERSION_TABLE_ENTRY (CriticalHitHead
)
46 NL_STRING_CONVERSION_TABLE_ENTRY (CriticalHitChest
)
47 NL_STRING_CONVERSION_TABLE_ENTRY (CriticalHitArms
)
48 NL_STRING_CONVERSION_TABLE_ENTRY (CriticalHitHands
)
49 NL_STRING_CONVERSION_TABLE_ENTRY (CriticalHitLegs
)
50 NL_STRING_CONVERSION_TABLE_ENTRY (CriticalHitFeet
)
51 NL_STRING_CONVERSION_TABLE_ENTRY (Unknown
)
52 NL_END_STRING_CONVERSION_TABLE(TCombatHistory
, CombatHistoryConversion
, Unknown
)
55 //--------------------------------------------------------------
56 // CCombat::toString()
57 //--------------------------------------------------------------
58 const string
&toString(TCombatHistory event
)
60 return CombatHistoryConversion
.toString(event
);
62 }; // COMBAT_HISTORY //