diff --git a/code/ryzom/client/data/gamedev/fd.cmd b/code/ryzom/client/data/gamedev/fd.cmd
index ca176e6aa..9f9dec1a9 100644
--- a/code/ryzom/client/data/gamedev/fd.cmd
+++ b/code/ryzom/client/data/gamedev/fd.cmd
@@ -3,30 +3,30 @@ db SERVER:INTERFACES:FLAGS 255
-db SERVER:CHARACTER_INFO:SCORES:MaxHitPoints 100
-db SERVER:CHARACTER_INFO:SCORES:BaseHitPoints 120
-db SERVER:CHARACTER_INFO:SCORES:MaxStamina 120
-db SERVER:CHARACTER_INFO:SCORES:BaseStamina 100
-db SERVER:CHARACTER_INFO:SCORES:MaxSap 100
-db SERVER:CHARACTER_INFO:SCORES:BaseSap 100
-db SERVER:CHARACTER_INFO:SCORES:MaxFocus 100
-db SERVER:CHARACTER_INFO:SCORES:BaseFocus 100
+db SERVER:CHARACTER_INFO:SCORES:MaxChaScore1 100
+db SERVER:CHARACTER_INFO:SCORES:BaseChaScore1 120
+db SERVER:CHARACTER_INFO:SCORES:MaxChaScore2 120
+db SERVER:CHARACTER_INFO:SCORES:BaseChaScore2 100
+db SERVER:CHARACTER_INFO:SCORES:MaxChaScore3 100
+db SERVER:CHARACTER_INFO:SCORES:BaseChaScore3 100
+db SERVER:CHARACTER_INFO:SCORES:MaxChaScore4 100
+db SERVER:CHARACTER_INFO:SCORES:BaseChaScore4 100
-db SERVER:CHARACTER_INFO:CHARACTERISTICS:Constitution 33
-db SERVER:CHARACTER_INFO:CHARACTERISTICS:Metabolism 100
-db SERVER:CHARACTER_INFO:CHARACTERISTICS:Strength 50
-db SERVER:CHARACTER_INFO:CHARACTERISTICS:WellBalanced 30
-db SERVER:CHARACTER_INFO:CHARACTERISTICS:Intelligence 30
-db SERVER:CHARACTER_INFO:CHARACTERISTICS:Wisdom 420
-db SERVER:CHARACTER_INFO:CHARACTERISTICS:Dexterity 121
-db SERVER:CHARACTER_INFO:CHARACTERISTICS:Will 654
+db SERVER:CHARACTER_INFO:CHARACTERISTICS:Cha1 33
+db SERVER:CHARACTER_INFO:CHARACTERISTICS:Cha1Reg 100
+db SERVER:CHARACTER_INFO:CHARACTERISTICS:Cha2 50
+db SERVER:CHARACTER_INFO:CHARACTERISTICS:Cha2Reg 30
+db SERVER:CHARACTER_INFO:CHARACTERISTICS:Cha3 30
+db SERVER:CHARACTER_INFO:CHARACTERISTICS:Cha3Reg 420
+db SERVER:CHARACTER_INFO:CHARACTERISTICS:Cha4 121
+db SERVER:CHARACTER_INFO:CHARACTERISTICS:Cha4Reg 654
db SERVER:USER:SKILL_POINTS 1000
-db SERVER:TARGET:BARS:HP 80
-db SERVER:TARGET:BARS:STA 32
-db SERVER:TARGET:BARS:SAP 69
-db SERVER:TARGET:BARS:FOCUS 95
+db SERVER:TARGET:BARS:ChaScore1 80
+db SERVER:TARGET:BARS:ChaScore2 32
+db SERVER:TARGET:BARS:ChaScore3 69
+db SERVER:TARGET:BARS:ChaScore4 95
@@ -347,25 +347,25 @@ db SERVER:STATIC_DATA:BAG_BULK_MAX 400
db SERVER:PACK_ANIMAL:BEAST0:STATUS 15
db SERVER:PACK_ANIMAL:BEAST0:TYPE 2
db SERVER:PACK_ANIMAL:BEAST0:UID 2
-db SERVER:PACK_ANIMAL:BEAST0:HP 40
+db SERVER:PACK_ANIMAL:BEAST0:ChaScore1 40
db SERVER:PACK_ANIMAL:BEAST0:BULK_MAX 200
db SERVER:PACK_ANIMAL:BEAST1:STATUS 15
db SERVER:PACK_ANIMAL:BEAST1:TYPE 1
db SERVER:PACK_ANIMAL:BEAST1:UID 3
-db SERVER:PACK_ANIMAL:BEAST1:HP 0
+db SERVER:PACK_ANIMAL:BEAST1:ChaScore1 0
db SERVER:PACK_ANIMAL:BEAST1:BULK_MAX 300
db SERVER:PACK_ANIMAL:BEAST2:STATUS 15
db SERVER:PACK_ANIMAL:BEAST2:TYPE 2
db SERVER:PACK_ANIMAL:BEAST2:UID 4
-db SERVER:PACK_ANIMAL:BEAST2:HP 0
+db SERVER:PACK_ANIMAL:BEAST2:ChaScore1 0
db SERVER:PACK_ANIMAL:BEAST2:BULK_MAX 300
db SERVER:PACK_ANIMAL:BEAST3:STATUS 15
db SERVER:PACK_ANIMAL:BEAST3:TYPE 2
db SERVER:PACK_ANIMAL:BEAST3:UID 1
-db SERVER:PACK_ANIMAL:BEAST3:HP 30
+db SERVER:PACK_ANIMAL:BEAST3:ChaScore1 30
db SERVER:PACK_ANIMAL:BEAST3:BULK_MAX 100
diff --git a/code/ryzom/client/data/gamedev/fd2.cmd b/code/ryzom/client/data/gamedev/fd2.cmd
index bf8ba20a3..75f186229 100644
--- a/code/ryzom/client/data/gamedev/fd2.cmd
+++ b/code/ryzom/client/data/gamedev/fd2.cmd
@@ -1,17 +1,17 @@
-db SERVER:USER:HP_MAX 100
-db SERVER:USER:HP 45
-db SERVER:USER:STA_MAX 100
-db SERVER:USER:STA 70
-db SERVER:USER:SAP_MAX 100
-db SERVER:USER:SAP 90
+db SERVER:USER:ChaScore1_MAX 100
+db SERVER:USER:ChaScore1 45
+db SERVER:USER:ChaScore2_MAX 100
+db SERVER:USER:ChaScore2 70
+db SERVER:USER:ChaScore3_MAX 100
+db SERVER:USER:chaScore3 90
db SERVER:USER:ACT_MAX 9
db SERVER:USER:ACT 2
-db SERVER:TARGET:HP_MAX 100
-db SERVER:TARGET:HP 80
-db SERVER:TARGET:STA_MAX 100
-db SERVER:TARGET:STA 32
-db SERVER:TARGET:SAP_MAX 100
-db SERVER:TARGET:SAP 69
+db SERVER:TARGET:ChaScore1_MAX 100
+db SERVER:TARGET:ChaScore1 80
+db SERVER:TARGET:ChaScore2_MAX 100
+db SERVER:TARGET:ChaScore2 32
+db SERVER:TARGET:ChaScore3_MAX 100
+db SERVER:TARGET:ChaScore3 69
// db SERVER:INVENTORY:1:0:SHEET 123648
// db SERVER:INVENTORY:2:0:SHEET 137472
// db SERVER:INVENTORY:2:1:SHEET 232960
diff --git a/code/ryzom/client/data/gamedev/fd3.cmd b/code/ryzom/client/data/gamedev/fd3.cmd
index 55fc70732..0ed00d4ce 100644
--- a/code/ryzom/client/data/gamedev/fd3.cmd
+++ b/code/ryzom/client/data/gamedev/fd3.cmd
@@ -14,24 +14,24 @@ db SERVER:MODIFIERS:BONUS:7:SHEET 1572
db SERVER:MODIFIERS:MALUS:0:SHEET 1572
db SERVER:MODIFIERS:MALUS:1:SHEET 1572
db SERVER:MODIFIERS:MALUS:2:SHEET 1572
-db SERVER:CHARACTER_INFO:SCORES:Sap 10
-db SERVER:CHARACTER_INFO:SCORES:MaxSap 100
-db SERVER:CHARACTER_INFO:SCORES:MaxSapStatus 1
-db SERVER:CHARACTER_INFO:SCORES:Stamina 25
-db SERVER:CHARACTER_INFO:SCORES:MaxStamina 110
-db SERVER:CHARACTER_INFO:SCORES:MaxStaminaStatus 2
-db SERVER:CHARACTER_INFO:CHARACTERISTICS:Strength 30
-db SERVER:CHARACTER_INFO:CHARACTERISTICS:MaxStrengthStatus 0
-db SERVER:CHARACTER_INFO:CHARACTERISTICS:Constitution 90
-db SERVER:CHARACTER_INFO:CHARACTERISTICS:MaxConstitutionStatus 1
+db SERVER:CHARACTER_INFO:SCORES:ChaScore3 10
+db SERVER:CHARACTER_INFO:SCORES:MaxChaScore3 100
+db SERVER:CHARACTER_INFO:SCORES:MaxChaScore3Status 1
+db SERVER:CHARACTER_INFO:SCORES:ChaScore2 25
+db SERVER:CHARACTER_INFO:SCORES:MaxChaScore2 110
+db SERVER:CHARACTER_INFO:SCORES:MaxChaScore2Status 2
+db SERVER:CHARACTER_INFO:CHARACTERISTICS:Cha2 30
+db SERVER:CHARACTER_INFO:CHARACTERISTICS:MaxCha2Status 0
+db SERVER:CHARACTER_INFO:CHARACTERISTICS:Cha1 90
+db SERVER:CHARACTER_INFO:CHARACTERISTICS:MaxCha1Status 1
db SERVER:CHARACTER_INFO:CHARACTERISTICS:Agility 60
db SERVER:CHARACTER_INFO:CHARACTERISTICS:MaxAgilityStatus 2
db SERVER:CHARACTER_INFO:CHARACTERISTICS:Will 45
db SERVER:CHARACTER_INFO:CHARACTERISTICS:MaxWillStatus 0
-db SERVER:CHARACTER_INFO:CHARACTERISTICS:WellBalanced 65
-db SERVER:CHARACTER_INFO:CHARACTERISTICS:MaxWellBalancedStatus 2
-db SERVER:CHARACTER_INFO:CHARACTERISTICS:Intelligence 33
-db SERVER:CHARACTER_INFO:CHARACTERISTICS:MaxIntelligenceStatus 0
+db SERVER:CHARACTER_INFO:CHARACTERISTICS:Cha2Reg 65
+db SERVER:CHARACTER_INFO:CHARACTERISTICS:MaxCha2RegStatus 2
+db SERVER:CHARACTER_INFO:CHARACTERISTICS:Cha3 33
+db SERVER:CHARACTER_INFO:CHARACTERISTICS:MaxCha3Status 0
db SERVER:CHARACTER_INFO:CHARACTERISTICS:Charisme 10
db SERVER:CHARACTER_INFO:CHARACTERISTICS:MaxCharismeStatus 1
db SERVER:CHARACTER_INFO:CHARACTERISTICS:Empathie 62
diff --git a/code/ryzom/client/data/gamedev/interfaces_v3/config.xml b/code/ryzom/client/data/gamedev/interfaces_v3/config.xml
index 7b73429c4..15214a085 100644
--- a/code/ryzom/client/data/gamedev/interfaces_v3/config.xml
+++ b/code/ryzom/client/data/gamedev/interfaces_v3/config.xml
@@ -264,16 +264,16 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
-
+
-
-
-
+
-
-
-
+
-
-
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -2923,13 +2923,13 @@ This MUST follow the Enum MISSION_DESC::TIconId
-
-
-
@@ -3464,15 +3464,15 @@ This MUST follow the Enum MISSION_DESC::TIconId
-
-
-
-
-
@@ -3749,69 +3749,69 @@ This MUST follow the Enum MISSION_DESC::TIconId
value_from_code="getMaxTeamMember()" />
-
-
+
-
-
-
-
+
-
-
-
-
-
-
-
-
+
+
+
+
-
-
-
-
-
-
-
-
diff --git a/code/ryzom/client/data/gamedev/interfaces_v3/game_config.xml b/code/ryzom/client/data/gamedev/interfaces_v3/game_config.xml
index 38e63cb24..f3d3a6be6 100644
--- a/code/ryzom/client/data/gamedev/interfaces_v3/game_config.xml
+++ b/code/ryzom/client/data/gamedev/interfaces_v3/game_config.xml
@@ -1005,11 +1005,11 @@
text_ref="BR BR"
w="100"
prompt=""
- enter_loose_focus="true"
+ enter_loose_ChaScore4="true"
multi_line="false"
onenter="game_config_change_screen_ratio_custom"
- enter_recover_focus="false"
- reset_focus_on_hide="true"
+ enter_recover_ChaScore4="false"
+ reset_ChaScore4_on_hide="true"
max_historic="0"
entry_type="positive_float"
max_float_prec="5"
@@ -1334,7 +1334,7 @@
y="0"
hardtext="uiHud" />
+ -->
@@ -3222,7 +3222,7 @@
preset="UI:TEMP:PRESET_FX" />
-
-
-
-
-
-
-
-
-
+ tooltip="uittIdentityChaScore1"
+ text="uiChaScore1"
+ val="%player_ChaScore1"
+ maxval="%player_ChaScore1_max"
+ baseval="%player_ChaScore1_base" />
+ tooltip="uittIdentityChaScore3"
+ text="uiChaScore3"
+ val="%player_ChaScore3"
+ maxval="%player_ChaScore3_max"
+ baseval="%player_ChaScore3_base" />
+ tooltip="uittIdentityChaScore2"
+ text="uiChaScore2"
+ val="%player_ChaScore2"
+ maxval="%player_ChaScore2_max"
+ baseval="%player_ChaScore2_base" />
+ tooltip="uittIdentityChaScore4"
+ text="uiChaScore4"
+ val="%player_ChaScore4"
+ maxval="%player_ChaScore4_max"
+ baseval="%player_ChaScore4_base" />
+ text="uiChaScore1"
+ val="%player_ChaScore1reg"
+ baseval="%player_ChaScore1reg_base"
+ tooltip="uittIdentityChaScore1Reg" />
+ text="uiChaScore3"
+ val="%player_ChaScore3reg"
+ baseval="%player_ChaScore3reg_base"
+ tooltip="uittIdentityChaScore3Reg" />
+ text="uiChaScore2"
+ val="%player_ChaScore2reg"
+ baseval="%player_ChaScore2reg_base"
+ tooltip="uittIdentityChaScore2Reg" />
+ text="uiChaScore4"
+ val="%player_ChaScore4reg"
+ baseval="%player_ChaScore4reg_base"
+ tooltip="uittIdentityChaScore4Reg" />
+ text="uiCarac_ChaScore1Max"
+ val="%player_carac_ChaScore1max"
+ tooltip="uittIdentityCha1" />
+ text="uiCarac_ChaScore3Max"
+ val="%player_carac_ChaScore3max"
+ tooltip="uittIdentityCha3" />
+ text="uiCarac_ChaScore2Max"
+ val="%player_carac_ChaScore2max"
+ tooltip="uittIdentityCha2" />
+ text="uiCarac_ChaScore4Max"
+ val="%player_carac_ChaScore4max"
+ tooltip="uittIdentityCha4" />
+ text="uiCarac_ChaScore1Reg"
+ val="%player_carac_ChaScore1reg"
+ tooltip="uittIdentityCha1Reg" />
+ text="uiCarac_ChaScore3Reg"
+ val="%player_carac_ChaScore3reg"
+ tooltip="uittIdentityCha3Reg" />
+ tooltip="uittIdentityCha2Reg" />
+ text="uiCarac_ChaScore4Reg"
+ val="%player_carac_ChaScore4reg"
+ tooltip="uittIdentityCha4Reg" />
+ text="uiChaScore1"
+ val="%target_ChaScore1" />
@@ -1485,15 +1485,15 @@
posref="MR MR"
mini="true"
x="-16"
- color1="%sta_color"
- value1="UI:VARIABLES:BARS:TEAM:#team_mate_index:STA"
+ color1="%ChaScore2_color"
+ value1="UI:VARIABLES:BARS:TEAM:#team_mate_index:ChaScore2"
range1="UI:CONST:127"
- color2="%sap_color"
- value2="UI:VARIABLES:BARS:TEAM:#team_mate_index:SAP"
+ color2="%ChaScore3_color"
+ value2="UI:VARIABLES:BARS:TEAM:#team_mate_index:ChaScore3"
range2="UI:CONST:127"
- color3="%hp_color"
- color3_negative="%hp_color_neg"
- value3="UI:VARIABLES:BARS:TEAM:#team_mate_index:HP"
+ color3="%ChaScore1_color"
+ color3_negative="%ChaScore1_color_neg"
+ value3="UI:VARIABLES:BARS:TEAM:#team_mate_index:ChaScore1"
range3="UI:CONST:127" />
+ color1="%ChaScore2_color" value1="UI:VARIABLES:BARS:TEAM:#team_mate_index:ChaScore2" range1="UI:CONST:127"
+ color2="%ChaScore3_color" value2="UI:VARIABLES:BARS:TEAM:#team_mate_index:ChaScore3" range2="UI:CONST:127"
+ color3="%ChaScore1_color" color3_negative="%ChaScore1_color_neg" value3="UI:VARIABLES:BARS:TEAM:#team_mate_index:ChaScore1" range3="UI:CONST:127" />
diff --git a/code/ryzom/client/data/gamedev/interfaces_v3/login_config.xml b/code/ryzom/client/data/gamedev/interfaces_v3/login_config.xml
index e4b2e77e7..f74f1728e 100644
--- a/code/ryzom/client/data/gamedev/interfaces_v3/login_config.xml
+++ b/code/ryzom/client/data/gamedev/interfaces_v3/login_config.xml
@@ -1051,15 +1051,15 @@ This MUST follow the Enum MISSION_DESC::TIconId
-
-
-
-
-
diff --git a/code/ryzom/client/data/gamedev/interfaces_v3/out_v2_config.xml b/code/ryzom/client/data/gamedev/interfaces_v3/out_v2_config.xml
index a0ca1c01b..973d34550 100644
--- a/code/ryzom/client/data/gamedev/interfaces_v3/out_v2_config.xml
+++ b/code/ryzom/client/data/gamedev/interfaces_v3/out_v2_config.xml
@@ -227,15 +227,15 @@
-
-
-
-
-
diff --git a/code/ryzom/client/data/gamedev/interfaces_v3/outgame_career.xml b/code/ryzom/client/data/gamedev/interfaces_v3/outgame_career.xml
index b793b8f21..3b1cae0e3 100644
--- a/code/ryzom/client/data/gamedev/interfaces_v3/outgame_career.xml
+++ b/code/ryzom/client/data/gamedev/interfaces_v3/outgame_career.xml
@@ -7,14 +7,14 @@
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
@@ -26,47 +26,47 @@
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
@@ -74,136 +74,136 @@
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
@@ -1156,20 +1156,20 @@
-
-
-
-
+
+
+
+
-
-
-
-
+
+
+
+
@@ -1810,4 +1810,4 @@
-
\ No newline at end of file
+
diff --git a/code/ryzom/client/data/gamedev/interfaces_v3/outgame_config.xml b/code/ryzom/client/data/gamedev/interfaces_v3/outgame_config.xml
index a56d622f7..0edcdd1b1 100644
--- a/code/ryzom/client/data/gamedev/interfaces_v3/outgame_config.xml
+++ b/code/ryzom/client/data/gamedev/interfaces_v3/outgame_config.xml
@@ -221,15 +221,15 @@
-
-
-
-
-
diff --git a/code/ryzom/client/data/gamedev/interfaces_v3/outgame_summary.xml b/code/ryzom/client/data/gamedev/interfaces_v3/outgame_summary.xml
index 34004be1f..3b732c076 100644
--- a/code/ryzom/client/data/gamedev/interfaces_v3/outgame_summary.xml
+++ b/code/ryzom/client/data/gamedev/interfaces_v3/outgame_summary.xml
@@ -545,10 +545,10 @@
-
-
-
-
+
+
+
+
-->
@@ -920,4 +920,4 @@
-
\ No newline at end of file
+
diff --git a/code/ryzom/client/data/gamedev/interfaces_v3/phrase.xml b/code/ryzom/client/data/gamedev/interfaces_v3/phrase.xml
index 426303058..02fcfae97 100644
--- a/code/ryzom/client/data/gamedev/interfaces_v3/phrase.xml
+++ b/code/ryzom/client/data/gamedev/interfaces_v3/phrase.xml
@@ -732,17 +732,17 @@
global_color="false" />
-
+
-
+
-
+
-
+
@@ -756,9 +756,9 @@
+ color1="%ChaScore2_color" value1="SERVER:EXECUTE_PHRASE:LINK:#index:TARGET_ChaScore2" range1="UI:CONST:127"
+ color2="%ChaScore3_color" value2="SERVER:EXECUTE_PHRASE:LINK:#index:TARGET_ChaScore3" range2="UI:CONST:127"
+ color3="%ChaScore1_color" value3="SERVER:EXECUTE_PHRASE:LINK:#index:TARGET_ChaScore1" range3="UI:CONST:127" />
diff --git a/code/ryzom/client/data/gamedev/interfaces_v3/player.lua b/code/ryzom/client/data/gamedev/interfaces_v3/player.lua
index 3827593b1..56887b9f0 100644
--- a/code/ryzom/client/data/gamedev/interfaces_v3/player.lua
+++ b/code/ryzom/client/data/gamedev/interfaces_v3/player.lua
@@ -44,60 +44,60 @@ end
------------------------------------------------------------------------------------------------------------
--- Update player bars in function of what we wants to display (we can hide each one of the 3 bars : sap,stamina and focus)
+-- Update player bars in function of what we wants to display (we can hide each one of the 3 bars : ChaScore3,ChaScore2 and ChaScore4)
function game:updatePlayerBars()
- local dispSap = getDbProp('UI:SAVE:PLAYER:DISP_SAP');
- local dispSta = getDbProp('UI:SAVE:PLAYER:DISP_STA');
- local dispFoc = getDbProp('UI:SAVE:PLAYER:DISP_FOC');
+ local dispChaScore3 = getDbProp('UI:SAVE:PLAYER:DISP_ChaScore3');
+ local dispChaScore2 = getDbProp('UI:SAVE:PLAYER:DISP_ChaScore2');
+ local dispChaScore4 = getDbProp('UI:SAVE:PLAYER:DISP_ChaScore4');
local ui = getUI('ui:interface:player:content');
-- active ui in function of what is displayed
- ui.b_sap.active = (dispSap == 1);
- ui.jsap.active = (dispSap == 1);
+ ui.b_ChaScore3.active = (dispChaScore3 == 1);
+ ui.jChaScore3.active = (dispChaScore3 == 1);
- ui.b_sta.active = (dispSta == 1);
- ui.jsta.active = (dispSta == 1);
+ ui.b_ChaScore2.active = (dispChaScore2 == 1);
+ ui.jChaScore2.active = (dispChaScore2 == 1);
- ui.b_foc.active = (dispFoc == 1);
- ui.jfoc.active = (dispFoc == 1);
+ ui.b_ChaScore4.active = (dispChaScore4 == 1);
+ ui.jChaScore4.active = (dispChaScore4 == 1);
-- choose good y-position
- local totalBarDisp = dispSap + dispSta + dispFoc;
+ local totalBarDisp = dispChaScore3 + dispChaScore2 + dispChaScore4;
if (totalBarDisp == 3) then
- ui.b_sap.y = -20;
- ui.b_sta.y = -35;
- ui.b_foc.y = -50;
+ ui.b_ChaScore3.y = -20;
+ ui.b_ChaScore2.y = -35;
+ ui.b_ChaScore4.y = -50;
ui.current_action.y = -65;
elseif (totalBarDisp == 2) then
- if (dispSap == 0) then
- ui.b_sta.y = -20;
- ui.b_foc.y = -35;
+ if (dispChaScore3 == 0) then
+ ui.b_ChaScore2.y = -20;
+ ui.b_ChaScore4.y = -35;
end
- if (dispSta == 0) then
- ui.b_sap.y = -20;
- ui.b_foc.y = -35;
+ if (dispCha == 0) then
+ ui.b_ChaScore3.y = -20;
+ ui.b_ChaScore4.y = -35;
end
- if (dispFoc == 0) then
- ui.b_sap.y = -20;
- ui.b_sta.y = -35;
+ if (dispChaScore4 == 0) then
+ ui.b_ChaScore3.y = -20;
+ ui.b_ChaScore2.y = -35;
end
ui.current_action.y = -50;
elseif (totalBarDisp == 1) then
- ui.b_sta.y = -20;
- ui.b_foc.y = -20;
- ui.b_sta.y = -20;
+ ui.b_ChaScore2.y = -20;
+ ui.b_ChaScore4.y = -20;
+ ui.b_ChaScore2.y = -20;
ui.current_action.y = -35;
@@ -864,10 +864,10 @@ function game:updatePhraseTooltip(phrase)
text = concatUCString(text, "@{CCCF}")
end
-- IMPORTANT : the following getters on 'phrase' take in account the 'total action malus' for the timebeing
- self:setPhraseTooltipCarac(ttWin, "hp_cost", phrase:getHpCost())
- self:setPhraseTooltipCarac(ttWin, "sta_cost", phrase:getStaCost())
- self:setPhraseTooltipCarac(ttWin, "sap_cost", phrase:getSapCost())
- self:setPhraseTooltipCarac(ttWin, "focus_cost", phrase:getFocusCost())
+ self:setPhraseTooltipCarac(ttWin, "ChaScore1_cost", phrase:getChaScore1Cost())
+ self:setPhraseTooltipCarac(ttWin, "ChaScore2_cost", phrase:getChaScore2Cost())
+ self:setPhraseTooltipCarac(ttWin, "ChaScore3_cost", phrase:getChaScore3Cost())
+ self:setPhraseTooltipCarac(ttWin, "ChaScore4_cost", phrase:getChaScore4Cost())
self:setPhraseTooltipCarac(ttWin, "cast_time", phrase:getCastTime(), concatUCString(string.format("%.1f", phrase:getCastTime()), i18n.get("uittSeconds")))
local castRange = phrase:getCastRange()
if not phrase:isMagicPhrase() then
@@ -935,10 +935,10 @@ function game:updateBuffItemTooltip(buffItem)
local ttWin = getUI("ui:interface:buff_item_context_help")
local text = buffItem:getName()
- self:setPhraseTooltipCarac(ttWin, "hp_buff", buffItem:getHpBuff())
- self:setPhraseTooltipCarac(ttWin, "sta_buff", buffItem:getStaBuff())
- self:setPhraseTooltipCarac(ttWin, "sap_buff", buffItem:getSapBuff())
- self:setPhraseTooltipCarac(ttWin, "focus_buff", buffItem:getFocusBuff())
+ self:setPhraseTooltipCarac(ttWin, "ChaScore1_buff", buffItem:getChaScore1Buff())
+ self:setPhraseTooltipCarac(ttWin, "ChaScore2_buff", buffItem:getChaScore2Buff())
+ self:setPhraseTooltipCarac(ttWin, "ChaScore3_buff", buffItem:getChaScore3Buff())
+ self:setPhraseTooltipCarac(ttWin, "ChaScore4_buff", buffItem:getChaScore4Buff())
updateTooltipCoords()
return text
diff --git a/code/ryzom/client/data/gamedev/interfaces_v3/player.xml b/code/ryzom/client/data/gamedev/interfaces_v3/player.xml
index 997d151fc..bd94b2a2c 100644
--- a/code/ryzom/client/data/gamedev/interfaces_v3/player.xml
+++ b/code/ryzom/client/data/gamedev/interfaces_v3/player.xml
@@ -40,19 +40,19 @@
posref="#posref"
x="#x"
y="#y"
- color1="%focus_color"
- value1="%player_focus_percent"
+ color1="%ChaScore4_color"
+ value1="%player_ChaScore4_percent"
range1="%player_percent_max"
- color2="%sap_color"
- value2="%player_sap_percent"
+ color2="%ChaScore3_color"
+ value2="%player_ChaScore3_percent"
range2="%player_percent_max"
- color3="%sta_color"
- value3="%player_sta_percent"
+ color3="%ChaScore2_color"
+ value3="%player_ChaScore2_percent"
range3="%player_percent_max" />
-
-
+
-
+
+ params="dblink=UI:SAVE:PLAYER:DISP_ChaScore4|value=not(@UI:SAVE:PLAYER:DISP_ChaScore4)" />
-
+ text="uiChaScore1"
+ val="%player_ChaScore1"
+ maxval="%player_ChaScore1_max"
+ val_bar="%player_ChaScore1_percent"
+ tooltip="uittGaugesChaScore1" />
+ text="uiChaScore3"
+ val="%player_ChaScore3"
+ maxval="%player_ChaScore3_max"
+ val_bar="%player_ChaScore3_percent"
+ tooltip="uittGaugesChaScore3" />
+ text="uiChaScore2"
+ val="%player_ChaScore2"
+ maxval="%player_ChaScore2_max"
+ val_bar="%player_ChaScore2_percent"
+ tooltip="uittGaugesChaScore2" />
+ text="uiChaScore4"
+ val="%player_ChaScore4"
+ maxval="%player_ChaScore4_max"
+ val_bar="%player_ChaScore4_percent"
+ tooltip="uittGaugesChaScore4" />
-
-
-
-
-
+
@@ -162,10 +158,10 @@
-
-
-
-
+
+
+
+
@@ -173,10 +169,10 @@
-
-
-
-
+
+
+
+
@@ -187,7 +183,7 @@
-
+
@@ -237,9 +233,9 @@
-
-
-
+
+
+
diff --git a/code/ryzom/client/data/gamedev/interfaces_v3/widgets.xml b/code/ryzom/client/data/gamedev/interfaces_v3/widgets.xml
index b806edb8d..ecfaec5c2 100644
--- a/code/ryzom/client/data/gamedev/interfaces_v3/widgets.xml
+++ b/code/ryzom/client/data/gamedev/interfaces_v3/widgets.xml
@@ -3897,39 +3897,39 @@
active="false"
global_color="false"/>
+ posparent="ChaScore1_cost" />
+ posparent="ChaScore2_cost" />
+ posparent="ChaScore3_cost" />
+ posparent="ChaScore4_cost" />
@@ -4104,7 +4104,7 @@
line_maxw="300"
multi_line_maxw_only="true" />
+ posparent="ChaScore1_buff" />
+ posparent="ChaScore2_buff" />
+ posparent="ChaScore3_buff" />
@@ -6927,203 +6927,7 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -7146,24 +6950,4 @@
global_color="false" />
-
-
-
-
-
diff --git a/code/ryzom/client/data/gamedev/pa.cmd b/code/ryzom/client/data/gamedev/pa.cmd
index 4acd773dd..642f7ff0f 100644
--- a/code/ryzom/client/data/gamedev/pa.cmd
+++ b/code/ryzom/client/data/gamedev/pa.cmd
@@ -1,12 +1,12 @@
db SERVER:PACK_ANIMAL:NbBeast 3
-db SERVER:PACK_ANIMAL:BEAST:0:HP 32
-db SERVER:PACK_ANIMAL:BEAST:0:SAP 32
-db SERVER:PACK_ANIMAL:BEAST:0:STA 32
-db SERVER:PACK_ANIMAL:BEAST:1:HP 64
-db SERVER:PACK_ANIMAL:BEAST:1:SAP 64
-db SERVER:PACK_ANIMAL:BEAST:1:STA 64
-db SERVER:PACK_ANIMAL:BEAST:2:HP 128
-db SERVER:PACK_ANIMAL:BEAST:2:SAP 128
-db SERVER:PACK_ANIMAL:BEAST:2:STA 128
+db SERVER:PACK_ANIMAL:BEAST:0:ChaScore1 32
+db SERVER:PACK_ANIMAL:BEAST:0:ChaScore3 32
+db SERVER:PACK_ANIMAL:BEAST:0:ChaScore2 32
+db SERVER:PACK_ANIMAL:BEAST:1:ChaScore1 64
+db SERVER:PACK_ANIMAL:BEAST:1:ChaScore3 64
+db SERVER:PACK_ANIMAL:BEAST:1:ChaScore2 64
+db SERVER:PACK_ANIMAL:BEAST:2:ChaScore1 128
+db SERVER:PACK_ANIMAL:BEAST:2:ChaScore3 128
+db SERVER:PACK_ANIMAL:BEAST:2:ChaScore2 128
diff --git a/code/ryzom/client/data/gamedev/steed.cmd b/code/ryzom/client/data/gamedev/steed.cmd
index 7b4287563..eeb28dc05 100644
--- a/code/ryzom/client/data/gamedev/steed.cmd
+++ b/code/ryzom/client/data/gamedev/steed.cmd
@@ -1,4 +1,4 @@
db SERVER:PACK_ANIMAL:STEED:Present 1
-db SERVER:PACK_ANIMAL:STEED:HP 32
-db SERVER:PACK_ANIMAL:STEED:SAP 32
-db SERVER:PACK_ANIMAL:STEED:STA 32
\ No newline at end of file
+db SERVER:PACK_ANIMAL:STEED:ChaScore1 32
+db SERVER:PACK_ANIMAL:STEED:ChaScore3 32
+db SERVER:PACK_ANIMAL:STEED:ChaScore2 32
\ No newline at end of file
diff --git a/code/ryzom/client/data/gamedev/team.cmd b/code/ryzom/client/data/gamedev/team.cmd
index 72ccb21a9..f475bc92e 100644
--- a/code/ryzom/client/data/gamedev/team.cmd
+++ b/code/ryzom/client/data/gamedev/team.cmd
@@ -1,18 +1,18 @@
db SERVER:GROUP:0:PRESENT 1
db SERVER:GROUP:0:NAME 0
-db SERVER:GROUP:0:STA 32
-db SERVER:GROUP:0:SAP 32
-db SERVER:GROUP:0:HP -32
+db SERVER:GROUP:0:ChaScore2 32
+db SERVER:GROUP:0:ChaScore3 32
+db SERVER:GROUP:0:ChaScore1 -32
db SERVER:GROUP:1:PRESENT 1
db SERVER:GROUP:1:NAME 1
-db SERVER:GROUP:1:STA 64
-db SERVER:GROUP:1:SAP 64
-db SERVER:GROUP:1:HP 64
+db SERVER:GROUP:1:ChaScore2 64
+db SERVER:GROUP:1:ChaScore3 64
+db SERVER:GROUP:1:ChaScore1 64
db SERVER:GROUP:2:PRESENT 1
db SERVER:GROUP:2:NAME 2
-db SERVER:GROUP:2:STA 127
-db SERVER:GROUP:2:SAP 127
-db SERVER:GROUP:2:HP 127
+db SERVER:GROUP:2:ChaScore2 127
+db SERVER:GROUP:2:ChaScore3 127
+db SERVER:GROUP:2:ChaScore1 127
db SERVER:GROUP:LEADER_INDEX 0
db SERVER:GROUP:SUCCESSOR_INDEX 1
diff --git a/code/ryzom/client/src/character_cl.cpp b/code/ryzom/client/src/character_cl.cpp
index 5d949b201..7f22d81e3 100644
--- a/code/ryzom/client/src/character_cl.cpp
+++ b/code/ryzom/client/src/character_cl.cpp
@@ -1756,12 +1756,12 @@ void CCharacterCL::updateVisualPropertyBars(const NLMISC::TGameCycle &gameCycle,
{
CBarManager::CBarInfo barInfo;
- // Encode HP to 7 bits
- barInfo.Score[SCORES::hit_points] = (sint8)((prop&0x7ff) * 127 / 1023);
+ // Encode ChaScore1 to 7 bits
+ barInfo.Score[SCORES::cha_score1] = (sint8)((prop&0x7ff) * 127 / 1023);
// NB: barInfo are sint8, but no problem, since anything following is 7 bits.
- barInfo.Score[SCORES::stamina] = (uint8)((prop>>11)&0x7f);
- barInfo.Score[SCORES::sap] = (uint8)((prop>>18)&0x7f);
- barInfo.Score[SCORES::focus] = (uint8)((prop>>25)&0x7f);
+ barInfo.Score[SCORES::cha_score2] = (uint8)((prop>>11)&0x7f);
+ barInfo.Score[SCORES::cha_score3] = (uint8)((prop>>18)&0x7f);
+ barInfo.Score[SCORES::cha_score4] = (uint8)((prop>>25)&0x7f);
// update The Bar manager
CBarManager *pBM= CBarManager::getInstance();
@@ -1769,13 +1769,13 @@ void CCharacterCL::updateVisualPropertyBars(const NLMISC::TGameCycle &gameCycle,
WHY gameCycle+1 ????? (yoyo)
It's because sometimes I have a bug With target DB update and VP update. This is the scenario
where I suppose the problem rises:
- tick=320: EGS::tickUpdate(): player.DBTargetHP.setProp(49)
- tick=321: EGS::combat update, target ennemy receives a Hit, VPHp=10 => transmitted to client with timestamp=321
+ tick=320: EGS::tickUpdate(): player.DBTargetChaScore1.setProp(49)
+ tick=321: EGS::combat update, target ennemy receives a Hit, VPChaScore1=10 => transmitted to client with timestamp=321
EGS::databaseUpdate(), DB updated, with timestamp=321!!!
Thus I receives on client:
- first the VP with Hp=10, timestamp=321
- second the DB with Hp=49, timestamp=321 too => replaced => BUG
+ first the VP with ChaScore1=10, timestamp=321
+ second the DB with ChaScore1=49, timestamp=321 too => replaced => BUG
NB: DB is typically sent at low frequency by FrontEnd, thus received later on client.
Since databaseUpdate() is called every 2 ticks, adding +1 to VP timestamps solve easily the problem.
@@ -1785,19 +1785,19 @@ void CCharacterCL::updateVisualPropertyBars(const NLMISC::TGameCycle &gameCycle,
NB: moreover, tickupdate() is called every 8 (or 16) ticks, and databaseUpdate() every 2 ticks. So there is one more
possible bug:
- 318: EGS::tickUpdate(): player.DBTargetHP.setProp(49)
- 319: EGS::combat update, target ennemy receives a Hit, VPHp=10 => transmitted to client with timestamp=319
+ 318: EGS::tickUpdate(): player.DBTargetChaScore1.setProp(49)
+ 319: EGS::combat update, target ennemy receives a Hit, VPChaScore1=10 => transmitted to client with timestamp=319
EGS::databaseUpdate(), BUT decide to send only a small subset of DB (because lot of things to send)
- => our TargetHP is not updated
+ => our TargetChaScore1 is not updated
320: nothing. tickupdate() is not called, since every 8 ticks
- 321: EGS::databaseUpdate(), update TargetHP, with timestamp=321 !!!!! => Bug
+ 321: EGS::databaseUpdate(), update TargetChaScore1, with timestamp=321 !!!!! => Bug
(remind that we cannot store a timestamp for each DB property, else would be too big to store and to send...)
BTW, this last bug should be very rare, so don't care.
*********** */
pBM->updateBars(dataSetId(), barInfo, gameCycle+1,
- CBarManager::HpFlag | CBarManager::StaFlag | CBarManager::SapFlag | CBarManager::FocusFlag);
+ CBarManager::ChaScore1Flag | CBarManager::ChaScore2Flag | CBarManager::ChaScore3Flag | CBarManager::ChaScore4Flag);
}// updateVisualPropertyBars //
@@ -3048,7 +3048,7 @@ KeyChosen:
case CAnimationStateSheet::ElecCastInit:
case CAnimationStateSheet::FearCastInit:
case CAnimationStateSheet::FireCastInit:
- case CAnimationStateSheet::HealHPCastInit:
+ case CAnimationStateSheet::HealChaScore1CastInit:
case CAnimationStateSheet::MadCastInit:
case CAnimationStateSheet::PoisonCastInit:
case CAnimationStateSheet::RootCastInit:
@@ -3068,7 +3068,7 @@ KeyChosen:
case CAnimationStateSheet::ElecCastLoop:
case CAnimationStateSheet::FearCastLoop:
case CAnimationStateSheet::FireCastLoop:
- case CAnimationStateSheet::HealHPCastLoop:
+ case CAnimationStateSheet::HealChaScore1CastLoop:
case CAnimationStateSheet::MadCastLoop:
case CAnimationStateSheet::PoisonCastLoop:
case CAnimationStateSheet::RootCastLoop:
@@ -3088,7 +3088,7 @@ KeyChosen:
case CAnimationStateSheet::ElecCastEnd:
case CAnimationStateSheet::FearCastEnd:
case CAnimationStateSheet::FireCastEnd:
- case CAnimationStateSheet::HealHPCastEnd:
+ case CAnimationStateSheet::HealChaScore1CastEnd:
case CAnimationStateSheet::MadCastEnd:
case CAnimationStateSheet::PoisonCastEnd:
case CAnimationStateSheet::RootCastEnd:
@@ -3111,7 +3111,7 @@ KeyChosen:
case CAnimationStateSheet::ElecCastFail:
case CAnimationStateSheet::FearCastFail:
case CAnimationStateSheet::FireCastFail:
- case CAnimationStateSheet::HealHPCastFail:
+ case CAnimationStateSheet::HealChaScore1CastFail:
case CAnimationStateSheet::MadCastFail:
case CAnimationStateSheet::PoisonCastFail:
case CAnimationStateSheet::RootCastFail:
@@ -3684,8 +3684,8 @@ void CCharacterCL::beginCast(const MBEHAV::CBehaviour &behaviour)
case MBEHAV::CAST_FIRE:
setAnim(CAnimationStateSheet::FireCastInit);
break;
- case MBEHAV::CAST_HEALHP:
- setAnim(CAnimationStateSheet::HealHPCastInit);
+ case MBEHAV::CAST_HEALChaScore1:
+ setAnim(CAnimationStateSheet::HealChaScore1CastInit);
break;
case MBEHAV::CAST_MAD:
setAnim(CAnimationStateSheet::MadCastInit);
@@ -3743,8 +3743,8 @@ void CCharacterCL::endCast(const MBEHAV::CBehaviour &behaviour, const MBEHAV::CB
case MBEHAV::CAST_FIRE:
setAnim(CAnimationStateSheet::FireCastEnd);
break;
- case MBEHAV::CAST_HEALHP:
- setAnim(CAnimationStateSheet::HealHPCastEnd);
+ case MBEHAV::CAST_HEALChaScore1:
+ setAnim(CAnimationStateSheet::HealChaScore1CastEnd);
break;
case MBEHAV::CAST_MAD:
setAnim(CAnimationStateSheet::MadCastEnd);
@@ -4528,23 +4528,23 @@ bool CCharacterCL::isCurrentBehaviourAttackEnd() const
// ***************************************************************************
-void CCharacterCL::applyBehaviourFlyingHPs(const CBehaviourContext &bc, const MBEHAV::CBehaviour &behaviour,
+void CCharacterCL::applyBehaviourFlyingChaScore1s(const CBehaviourContext &bc, const MBEHAV::CBehaviour &behaviour,
const vector &targetHitDates)
{
nlassert(targetHitDates.size()==bc.Targets.Targets.size());
if(!bc.Targets.Targets.empty())
{
- if(behaviour.DeltaHP != 0)
+ if(behaviour.DeltaChaScore1 != 0)
{
- CRGBA deltaHPColor(0, 0, 0);
+ CRGBA deltaChaScore1Color(0, 0, 0);
// if it's a hit
- if( behaviour.DeltaHP < 0 )
+ if( behaviour.DeltaChaScore1 < 0 )
{
// if the behaviour is casted by the user
if( slot() == 0 )
{
- deltaHPColor = ClientCfg.SystemInfoParams["dgm"].Color;
+ deltaChaScore1Color = ClientCfg.SystemInfoParams["dgm"].Color;
}
else
// if the behaviour is casted by an entity that target the user
@@ -4555,27 +4555,27 @@ void CCharacterCL::applyBehaviourFlyingHPs(const CBehaviourContext &bc, const MB
{
// if actor is player : use pvp color
if( actor->isPlayer() )
- deltaHPColor = ClientCfg.SystemInfoParams["dgp"].Color;
+ deltaChaScore1Color = ClientCfg.SystemInfoParams["dgp"].Color;
else
- deltaHPColor = ClientCfg.SystemInfoParams["dg"].Color;
+ deltaChaScore1Color = ClientCfg.SystemInfoParams["dg"].Color;
}
}
else
{
- deltaHPColor = CRGBA(127,127,127);
+ deltaChaScore1Color = CRGBA(127,127,127);
}
}
else
{
- deltaHPColor = CRGBA(0,220,0);
+ deltaChaScore1Color = CRGBA(0,220,0);
}
- // Set the delta HP
+ // Set the delta ChaScore1
for (size_t i=0; iaddHPOutput(behaviour.DeltaHP, deltaHPColor, float(targetHitDates[i]-TimeInSec));
+ target2->addChaScore1Output(behaviour.DeltaChaScore1, deltaChaScore1Color, float(targetHitDates[i]-TimeInSec));
}
}
}
@@ -4724,7 +4724,7 @@ void CCharacterCL::applyBehaviour(const CBehaviourContext &bc) // virtual
updateCurrentAttack();
if (isCurrentBehaviourAttackEnd())
{
- // retrieve target hit dates, so flying HPs have the correct ones
+ // retrieve target hit dates, so flying ChaScore1s have the correct ones
performCurrentAttackEnd(bc, selfSpell && isOffensif, targetHitDates, combatAnimState);
}
@@ -4752,7 +4752,7 @@ void CCharacterCL::applyBehaviour(const CBehaviourContext &bc) // virtual
case MBEHAV::CAST_ELEC:
case MBEHAV::CAST_FEAR:
case MBEHAV::CAST_FIRE:
- case MBEHAV::CAST_HEALHP:
+ case MBEHAV::CAST_HEALChaScore1:
case MBEHAV::CAST_MAD:
case MBEHAV::CAST_POISON:
case MBEHAV::CAST_ROOT:
@@ -4792,8 +4792,8 @@ void CCharacterCL::applyBehaviour(const CBehaviourContext &bc) // virtual
default:
break;
}
- // DeltaHP
- applyBehaviourFlyingHPs(bc, behaviour, targetHitDates);
+ // DeltaChaScore1
+ applyBehaviourFlyingChaScore1s(bc, behaviour, targetHitDates);
}
// This is a behaviour for the combat.
else if(behaviour.isCombat() || behaviour.isCreatureAttack())
@@ -4838,8 +4838,8 @@ void CCharacterCL::applyBehaviour(const CBehaviourContext &bc) // virtual
UserControls.resetSmoothCameraDeltaYaw();
}
- // DeltaHP
- applyBehaviourFlyingHPs(bc, behaviour, targetHitDates);
+ // DeltaChaScore1
+ applyBehaviourFlyingChaScore1s(bc, behaviour, targetHitDates);
}
// Emote
else if(behaviour.isEmote())
@@ -4901,11 +4901,11 @@ void CCharacterCL::applyBehaviour(const CBehaviourContext &bc) // virtual
break;
// Extracting Begin
case MBEHAV::EXTRACTING:
- // DeltaHP
+ // DeltaChaScore1
if(target)
- if(behaviour.DeltaHP != 0)
- target->addHPOutput(behaviour.DeltaHP,CRGBA(0,220,0));
- // If receiving a new DeltaHP in the current extraction, don't reset the animation
+ if(behaviour.DeltaChaScore1 != 0)
+ target->addChaScore1Output(behaviour.DeltaChaScore1,CRGBA(0,220,0));
+ // If receiving a new DeltaChaScore1 in the current extraction, don't reset the animation
if ( previousBehaviour.Behaviour != _CurrentBehaviour.Behaviour )
setAnim(CAnimationStateSheet::UseInit);
break;
@@ -6069,13 +6069,13 @@ void CCharacterCL::updateVisible (const TTime ¤tTimeInMs, CEntityCL *targe
}
// Update Modifiers
- if(!_HPModifiers.empty())
+ if(!_ChaScore1Modifiers.empty())
{
- HPMD mod;
- mod.CHPModifier::operator= (*_HPModifiers.begin());
+ ChaScore1MD mod;
+ mod.CChaScore1Modifier::operator= (*_ChaScore1Modifiers.begin());
mod.Time = TimeInSec + mod.DeltaT;
- _HPDisplayed.push_back(mod);
- _HPModifiers.erase(_HPModifiers.begin());
+ _ChaScore1Displayed.push_back(mod);
+ _ChaScore1Modifiers.erase(_ChaScore1Modifiers.begin());
}
// Parent
@@ -6121,8 +6121,8 @@ void CCharacterCL::updateSomeClipped (const TTime ¤tTimeInMs, CEntityCL *t
}
// Remove Modifiers.
- _HPModifiers.clear();
- _HPDisplayed.clear();
+ _ChaScore1Modifiers.clear();
+ _ChaScore1Displayed.clear();
// Parent
CEntityCL::updateSomeClipped(currentTimeInMs, target);
@@ -7602,12 +7602,12 @@ void CCharacterCL::drawName(const NLMISC::CMatrix &mat) // virtual
//---------------------------------------------------
// displayModifiers :
-// Display the Hp Bar
+// Display the ChaScore1 Bar
//---------------------------------------------------
void CCharacterCL::displayModifiers() // virtual
{
// if none, no op
- if( _HPDisplayed.empty())
+ if( _ChaScore1Displayed.empty())
return;
// **** get the name pos
@@ -7631,13 +7631,13 @@ void CCharacterCL::displayModifiers() // virtual
scale = ClientCfg.ConstNameSizeDist / dist;
- // **** Display HP modifiers.
+ // **** Display ChaScore1 modifiers.
CInterfaceManager *pIM= CInterfaceManager::getInstance();
- std::list::iterator itTmp;
- std::list::iterator it = _HPDisplayed.begin();
- while(it != _HPDisplayed.end())
+ std::list::iterator itTmp;
+ std::list::iterator it = _ChaScore1Displayed.begin();
+ while(it != _ChaScore1Displayed.end())
{
- HPMD &mod = *it;
+ ChaScore1MD &mod = *it;
//
const float totalDuration= 3.f;
const float noFadeDuration= 1.f;
@@ -7646,15 +7646,15 @@ void CCharacterCL::displayModifiers() // virtual
{
itTmp = it;
++it;
- _HPDisplayed.erase(itTmp);
+ _ChaScore1Displayed.erase(itTmp);
}
else if (TimeInSec >= mod.Time)
{
- ucstring hpModifier;
+ ucstring ChaScore1Modifier;
if (mod.Text.empty())
- hpModifier = ucstring(toString("%d", mod.Value));
+ ChaScore1Modifier = ucstring(toString("%d", mod.Value));
else
- hpModifier = mod.Text;
+ ChaScore1Modifier = mod.Text;
double t = TimeInSec-mod.Time;
// for character, keep the deltaZ the first time it is displayed, and apply the same each frame
// (avoid Z movement of the flying text because of animation)
@@ -7669,11 +7669,11 @@ void CCharacterCL::displayModifiers() // virtual
else
mod.Color.A= 255-(uint8)((t-noFadeDuration)*255.0/fadeDuration);
- // Display the hp modifier. display with a X offset according if user or not, for more readability
+ // Display the ChaScore1 modifier. display with a X offset according if user or not, for more readability
sint deltaX= -pIM->FlyingTextManager.getOffsetXForCharacter();
if(UserEntity && UserEntity->slot()==slot())
deltaX*= -1;
- pIM->FlyingTextManager.addFlyingText(&mod, hpModifier, pos, mod.Color, scale, deltaX);
+ pIM->FlyingTextManager.addFlyingText(&mod, ChaScore1Modifier, pos, mod.Color, scale, deltaX);
// Next
++it;
@@ -10035,7 +10035,7 @@ NLMISC_COMMAND(attack, "simulate an attack", " applyBehaviour(bc);
return true;
}
@@ -10088,7 +10088,7 @@ NLMISC_COMMAND(rangeAttack, "simulate a range attack", " [intensity] [loca
if (!target) return false;
double dist = (target->pos() - entity->pos()).norm();
bc.Targets.Targets.push_back(CMultiTarget::CTarget(targetSlot, false, (uint8) ceilf((float) (dist / MULTI_TARGET_DISTANCE_UNIT))));
- bc.Behav.DeltaHP = -10;
+ bc.Behav.DeltaChaScore1 = -10;
entity->applyBehaviour(bc);
return true;
}
@@ -10160,7 +10160,7 @@ NLMISC_COMMAND(creatureAttack, "simulate a creature attack (2 attaques per creat
}
bc.Behav.CreatureAttack2.HitType = hitType;
bc.BehavTime = TimeInSec;
- bc.Behav.DeltaHP = -15;
+ bc.Behav.DeltaChaScore1 = -15;
caster->applyBehaviour(bc);
return true;
}
diff --git a/code/ryzom/client/src/character_cl.h b/code/ryzom/client/src/character_cl.h
index e2057d693..0a65a67c9 100644
--- a/code/ryzom/client/src/character_cl.h
+++ b/code/ryzom/client/src/character_cl.h
@@ -161,7 +161,7 @@ public:
/// Display the entity name.
virtual void displayName();
- /// Display the Hp Modifiers
+ /// Display the ChaScore1 Modifiers
virtual void displayModifiers();
/// Draw Path
virtual void drawPath();
@@ -1062,8 +1062,8 @@ private:
// remove attached fxs that depends on another slot when it has been removed
void updateAttachedFXListForSlotRemoved(std::list &fxList, const CLFECOMMON::TCLEntityId &slotRemoved);
- // apply the flying HP related to behaviour
- void applyBehaviourFlyingHPs(const CBehaviourContext &bc, const MBEHAV::CBehaviour &behaviour, const std::vector &targetHitDates);
+ // apply the flying ChaScore1 related to behaviour
+ void applyBehaviourFlyingChaScore1s(const CBehaviourContext &bc, const MBEHAV::CBehaviour &behaviour, const std::vector &targetHitDates);
protected:
// retrieve attack from an id and a list of attack lists filenames
diff --git a/code/ryzom/client/src/client_sheets/animation_set_list_sheet.h b/code/ryzom/client/src/client_sheets/animation_set_list_sheet.h
index ad991dae1..b75c213ba 100644
--- a/code/ryzom/client/src/client_sheets/animation_set_list_sheet.h
+++ b/code/ryzom/client/src/client_sheets/animation_set_list_sheet.h
@@ -158,7 +158,7 @@ public:
ElecCastInit,
FearCastInit,
FireCastInit,
- HealHPCastInit,
+ HealChaScore1CastInit,
MadCastInit,
PoisonCastInit,
RootCastInit,
@@ -174,7 +174,7 @@ public:
ElecCastLoop,
FearCastLoop,
FireCastLoop,
- HealHPCastLoop,
+ HealChaScore1CastLoop,
MadCastLoop,
PoisonCastLoop,
RootCastLoop,
@@ -190,7 +190,7 @@ public:
ElecCastFail,
FearCastFail,
FireCastFail,
- HealHPCastFail,
+ HealChaScore1CastFail,
MadCastFail,
PoisonCastFail,
RootCastFail,
@@ -206,7 +206,7 @@ public:
ElecCastEnd,
FearCastEnd,
FireCastEnd,
- HealHPCastEnd,
+ HealChaScore1CastEnd,
MadCastEnd,
PoisonCastEnd,
RootCastEnd,
diff --git a/code/ryzom/client/src/client_sheets/item_sheet.cpp b/code/ryzom/client/src/client_sheets/item_sheet.cpp
index afc2f6413..72183d9cc 100644
--- a/code/ryzom/client/src/client_sheets/item_sheet.cpp
+++ b/code/ryzom/client/src/client_sheets/item_sheet.cpp
@@ -838,8 +838,8 @@ bool CItemSheet::hasCharacRequirement(uint itemLevel, CHARACTERISTICS::TCharacte
case ITEM_TYPE::MEDIUM_SLEEVES:
case ITEM_TYPE::MEDIUM_VEST:
case ITEM_TYPE::BUCKLER:
- // Constitution requirement
- caracType= CHARACTERISTICS::constitution;
+ // Cha1 requirement
+ caracType= CHARACTERISTICS::cha1;
caracValue= itemLevel / 1.5f;
return true;
case ITEM_TYPE::HEAVY_BOOTS:
@@ -849,8 +849,8 @@ bool CItemSheet::hasCharacRequirement(uint itemLevel, CHARACTERISTICS::TCharacte
case ITEM_TYPE::HEAVY_VEST:
case ITEM_TYPE::HEAVY_HELMET:
case ITEM_TYPE::SHIELD:
- // Constitution requirement
- caracType= CHARACTERISTICS::constitution;
+ // Cha1 requirement
+ caracType= CHARACTERISTICS::cha1;
caracValue= float((sint)itemLevel - 10);
caracValue= max(caracValue, 0.f);
return true;
@@ -865,14 +865,14 @@ bool CItemSheet::hasCharacRequirement(uint itemLevel, CHARACTERISTICS::TCharacte
switch( ItemType )
{
case ITEM_TYPE::MAGICIAN_STAFF:
- // Intelligence requirement
- caracType= CHARACTERISTICS::intelligence;
+ // Cha3 requirement
+ caracType= CHARACTERISTICS::cha3;
caracValue= float((sint)itemLevel - 10);
caracValue= max(caracValue, 0.f);
return true;
default:
- // Strength requirement
- caracType= CHARACTERISTICS::strength;
+ // Cha2 requirement
+ caracType= CHARACTERISTICS::cha2;
caracValue= float((sint)itemLevel - 10);
caracValue= max(caracValue, 0.f);
return true;
@@ -881,7 +881,7 @@ bool CItemSheet::hasCharacRequirement(uint itemLevel, CHARACTERISTICS::TCharacte
// **** RANGE_WEAPON
case ITEMFAMILY::RANGE_WEAPON:
- caracType= CHARACTERISTICS::well_balanced;
+ caracType= CHARACTERISTICS::cha2_reg;
caracValue= float((sint)itemLevel - 10);
caracValue= max(caracValue, 0.f);
return true;
diff --git a/code/ryzom/client/src/client_sheets/pact_sheet.cpp b/code/ryzom/client/src/client_sheets/pact_sheet.cpp
index 4ea80299b..37d64e2e9 100644
--- a/code/ryzom/client/src/client_sheets/pact_sheet.cpp
+++ b/code/ryzom/client/src/client_sheets/pact_sheet.cpp
@@ -40,9 +40,9 @@ void CPactSheet::build(const NLGEORGES::UFormElm &root)
const UFormElm *node;
// variable is used for calculate pact effect in differential between pacts type
- sint16 LoseHitPoints = 0;
- sint16 LoseStamina = 0;
- sint16 LoseSap = 0;
+ sint16 LoseChaScore1 = 0;
+ sint16 LoseChaScore2 = 0;
+ sint16 LoseChaScore3 = 0;
sint16 LoseSkills = 0;
sint16 value;
@@ -54,20 +54,20 @@ void CPactSheet::build(const NLGEORGES::UFormElm &root)
if( node )
{
- node->getValueByName( value, "HitPoints" );
- value = 0 - value - LoseHitPoints;
- LoseHitPoints += value;
- PactLose[ i ].LoseHitPointsLevel = value;
+ node->getValueByName( value, "ChaScore1" );
+ value = 0 - value - LoseChaScore1;
+ LoseChaScore1 += value;
+ PactLose[ i ].LoseChaScore1Level = value;
- node->getValueByName( value, "Stamina" );
- value = 0 - value - LoseStamina;
- LoseStamina += value;
- PactLose[ i ].LoseStaminaLevel = value;
+ node->getValueByName( value, "ChaScore2" );
+ value = 0 - value - LoseChaScore2;
+ LoseChaScore2 += value;
+ PactLose[ i ].LoseChaScore2Level = value;
- node->getValueByName( value, "Sap" );
- value = 0 - value - LoseSap;
- LoseSap += value;
- PactLose[ i ].LoseSapLevel = value;
+ node->getValueByName( value, "ChaScore3" );
+ value = 0 - value - LoseChaScore3;
+ LoseChaScore3 += value;
+ PactLose[ i ].LoseChaScore3Level = value;
node->getValueByName( value, "Skills" );
value = 0 - value - LoseSkills;
diff --git a/code/ryzom/client/src/client_sheets/pact_sheet.h b/code/ryzom/client/src/client_sheets/pact_sheet.h
index 986b1f40f..daca88300 100644
--- a/code/ryzom/client/src/client_sheets/pact_sheet.h
+++ b/code/ryzom/client/src/client_sheets/pact_sheet.h
@@ -27,18 +27,18 @@ class CPactSheet : public CEntitySheet
public:
struct SPact
{
- uint16 LoseHitPointsLevel;
- uint16 LoseStaminaLevel;
- uint16 LoseSapLevel;
+ uint16 LoseChaScore1Level;
+ uint16 LoseChaScore2Level;
+ uint16 LoseChaScore3Level;
uint16 LoseSkillsLevel;
float Duration;
std::string Name;
void serial(class NLMISC::IStream &f) throw(NLMISC::EStream)
{
- f.serial( LoseHitPointsLevel);
- f.serial( LoseStaminaLevel );
- f.serial( LoseSapLevel );
+ f.serial( LoseChaScore1Level);
+ f.serial( LoseChaScore2Level );
+ f.serial( LoseChaScore3Level );
f.serial( LoseSkillsLevel );
f.serial( Duration );
f.serial( Name );
diff --git a/code/ryzom/client/src/commands.cpp b/code/ryzom/client/src/commands.cpp
index 60c6ba356..6f2508302 100644
--- a/code/ryzom/client/src/commands.cpp
+++ b/code/ryzom/client/src/commands.cpp
@@ -695,7 +695,7 @@ NLMISC_COMMAND(bugReport, "Call the bug report tool with dump", "
if (ClientCfg.Local)
sys += "ShardName OFFLINE ";
- FILE *fp = nlfopen (getLogDirectory() + "bug_report.txt", "wb");
+ FILE *fp = fopen (std::string(getLogDirectory() + "bug_report.txt").c_str(), "wb");
if (fp != NULL)
{
string res = addSlashR(getDebugInformation());
@@ -2440,7 +2440,7 @@ NLMISC_COMMAND(mode, "Change the mode for an entity in a slot", " [
return true;
}
-NLMISC_COMMAND(behaviour, "Change the behaviour for an entity in a slot", " [] [] [] [dt(tick)]")
+NLMISC_COMMAND(behaviour, "Change the behaviour for an entity in a slot", " [] [] [] [dt(tick)]")
{
// Check parameters.
if(args.size() < 2 || args.size() > 6)
@@ -2505,7 +2505,7 @@ NLMISC_COMMAND(behaviour, "Change the behaviour for an entity in a slot", " 4)
- fromString(args[4], behaviour.DeltaHP);
+ fromString(args[4], behaviour.DeltaChaScore1);
}
// get the dt
sint32 dt= 10;
@@ -4296,10 +4296,10 @@ NLMISC_COMMAND(debugItemInfo, "simulate a ItemInfo received from server", "itemS
itemInfo.ParryModifier= -10;
itemInfo.AdversaryDodgeModifier= 666;
itemInfo.AdversaryParryModifier= 333;
- itemInfo.HpBuff= 12;
- itemInfo.SapBuff= -14;
- itemInfo.StaBuff= 0;
- itemInfo.FocusBuff= 1;
+ itemInfo.ChaScore1Buff= 12;
+ itemInfo.ChaScore3Buff= -14;
+ itemInfo.ChaScore2Buff= 0;
+ itemInfo.ChaScore4Buff= 1;
itemInfo.MagicProtection[0]= PROTECTION_TYPE::Electricity;
itemInfo.MagicProtectionFactor[0]= 43;
itemInfo.MagicProtection[1]= PROTECTION_TYPE::Shockwave;
diff --git a/code/ryzom/client/src/entity_cl.h b/code/ryzom/client/src/entity_cl.h
index 328ec1cc7..60d1c1abd 100644
--- a/code/ryzom/client/src/entity_cl.h
+++ b/code/ryzom/client/src/entity_cl.h
@@ -86,7 +86,7 @@ namespace NL3D
class CEntitySheet;
class CEntityCL;
-struct CAttackInfo;
+class CAttackInfo;
class CItemSheet;
@@ -261,7 +261,7 @@ public:
/// Display the entity name.
virtual void displayName() {}
- /// Display the Hp Modifiers
+ /// Display the ChaScore1 Modifiers
virtual void displayModifiers() {}
/// Draw Path
virtual void drawPath() {}
@@ -631,9 +631,9 @@ public:
/// Return true if the character is really dead. With no lag because of anim or LCT
virtual bool isReallyDead() const {return false;}
- // Add hit points gain/lost by this entity.
- void addHPOutput(sint16 hp, NLMISC::CRGBA color, float dt=0.0f) { if(_HPModifiers.size()<20) _HPModifiers.push_back(CHPModifier(hp,color,dt));}
- void addHPOutput(const ucstring &text, NLMISC::CRGBA color, float dt=0.0f) { if(_HPModifiers.size()<20 && !text.empty()) _HPModifiers.push_back(CHPModifier(text,color,dt));}
+ // Add ChaScore1 gain/lost by this entity.
+ void addChaScore1Output(sint16 ChaScore1, NLMISC::CRGBA color, float dt=0.0f) { if(_ChaScore1Modifiers.size()<20) _ChaScore1Modifiers.push_back(CChaScore1Modifier(ChaScore1,color,dt));}
+ void addChaScore1Output(const ucstring &text, NLMISC::CRGBA color, float dt=0.0f) { if(_ChaScore1Modifiers.size()<20 && !text.empty()) _ChaScore1Modifiers.push_back(CChaScore1Modifier(text,color,dt));}
/// Return the entity sheet scale. (return 1.0 if there is any problem).
virtual float getSheetScale() const {return 1.0f;}
@@ -984,33 +984,33 @@ protected:
// Local selection box
NLMISC::CAABBox _LocalSelectBox;
// List of modifiers taken by this entity.
- class CHPModifier
+ class CChaScore1Modifier
{
public:
- CHPModifier() {}
- virtual ~CHPModifier() {}
- CHPModifier (sint16 value, NLMISC::CRGBA color, float dt) : Value(value), Color(color), DeltaT(dt) {}
- CHPModifier (const ucstring &text, NLMISC::CRGBA color, float dt) : Text(text), Color(color), DeltaT(dt) {}
+ CChaScore1Modifier() {}
+ virtual ~CChaScore1Modifier() {}
+ CChaScore1Modifier (sint16 value, NLMISC::CRGBA color, float dt) : Value(value), Color(color), DeltaT(dt) {}
+ CChaScore1Modifier (const ucstring &text, NLMISC::CRGBA color, float dt) : Text(text), Color(color), DeltaT(dt) {}
sint16 Value; // If Text.empty(), take the Value
ucstring Text;
NLMISC::CRGBA Color;
float DeltaT;
};
- std::list _HPModifiers;
+ std::list _ChaScore1Modifiers;
//
- class HPMD : public CHPModifier
+ class ChaScore1MD : public CChaScore1Modifier
{
public:
double Time;
// DeltaZ between pos() and namePos(). computed only one time
float DeltaZ;
- HPMD()
+ ChaScore1MD()
{
DeltaZ= -FLT_MAX;
}
};
- std::list _HPDisplayed;
+ std::list _ChaScore1Displayed;
// The transparency factor
float _TranspFactor; // 0 - opaque 1 - transparent
diff --git a/code/ryzom/client/src/forage_source_cl.cpp b/code/ryzom/client/src/forage_source_cl.cpp
index b99d37218..2bb21d80a 100644
--- a/code/ryzom/client/src/forage_source_cl.cpp
+++ b/code/ryzom/client/src/forage_source_cl.cpp
@@ -215,13 +215,13 @@ void CForageSourceCL::updateClipped (const NLMISC::TTime ¤tTimeInMs, CEnti
void CForageSourceCL::updateVisible(const NLMISC::TTime &time, CEntityCL *target)
{
// Update Modifiers
- if(!_HPModifiers.empty())
+ if(!_ChaScore1Modifiers.empty())
{
- HPMD mod;
- mod.CHPModifier::operator= (*_HPModifiers.begin());
+ ChaScore1MD mod;
+ mod.CChaScore1Modifier::operator= (*_ChaScore1Modifiers.begin());
mod.Time = TimeInSec;
- _HPDisplayed.push_back(mod);
- _HPModifiers.erase(_HPModifiers.begin());
+ _ChaScore1Displayed.push_back(mod);
+ _ChaScore1Modifiers.erase(_ChaScore1Modifiers.begin());
}
// parent
@@ -581,7 +581,7 @@ void CForageSourceCL::updateVisualPropertyTarget(const NLMISC::TGameCycle &/* ga
void CForageSourceCL::displayModifiers()
{
// if none, no op
- if( _HPDisplayed.empty())
+ if( _ChaScore1Displayed.empty())
return;
// **** get the name pos
@@ -598,13 +598,13 @@ void CForageSourceCL::displayModifiers()
scale = ClientCfg.ConstNameSizeDist / dist;
- // **** Display HP modifiers.
+ // **** Display ChaScore1 modifiers.
CInterfaceManager *pIM= CInterfaceManager::getInstance();
- std::list::iterator itTmp;
- std::list::iterator it = _HPDisplayed.begin();
- while(it != _HPDisplayed.end())
+ std::list::iterator itTmp;
+ std::list::iterator it = _ChaScore1Displayed.begin();
+ while(it != _ChaScore1Displayed.end())
{
- HPMD &mod = *it;
+ ChaScore1MD &mod = *it;
//
const float totalDuration= 3.f;
const float noFadeDuration= 1.f;
@@ -613,13 +613,13 @@ void CForageSourceCL::displayModifiers()
{
itTmp = it;
++it;
- _HPDisplayed.erase(itTmp);
+ _ChaScore1Displayed.erase(itTmp);
}
else
{
uint16 qttyDelta = ((uint16)mod.Value) & 0xFF;
uint16 qlty = ((uint16)mod.Value) >> 8;
- ucstring hpModifier = ucstring(toString("%u ", qttyDelta) + CI18N::get("uittQualityAbbrev") + toString(" %u", qlty));
+ ucstring ChaScore1Modifier = ucstring(toString("%u ", qttyDelta) + CI18N::get("uittQualityAbbrev") + toString(" %u", qlty));
double t = TimeInSec-mod.Time;
// Compute the position for the Modifier.
CVector pos= namePos + CVector(0.0f, 0.0f, 0.3f+(float)t*1.0f/totalDuration);
@@ -636,7 +636,7 @@ void CForageSourceCL::displayModifiers()
color.A= 255-(uint8)((t-noFadeDuration)*255.0/fadeDuration);
// Display the name
- pIM->FlyingTextManager.addFlyingText(&mod, hpModifier, pos, color, scale);
+ pIM->FlyingTextManager.addFlyingText(&mod, ChaScore1Modifier, pos, color, scale);
// Next
++it;
diff --git a/code/ryzom/client/src/interface_v3/action_handler_game.cpp b/code/ryzom/client/src/interface_v3/action_handler_game.cpp
index 445e95097..c12f7406e 100644
--- a/code/ryzom/client/src/interface_v3/action_handler_game.cpp
+++ b/code/ryzom/client/src/interface_v3/action_handler_game.cpp
@@ -3968,8 +3968,8 @@ static void fillPlayerBarText(ucstring &str, const string &dbScore, SCORES::TSco
}
// ***************************************************************************
-// Life
-class CHandlerPlayerTTLife : public IActionHandler
+// ChaScore1
+class CHandlerPlayerTTChaScore1 : public IActionHandler
{
public:
void execute (CCtrlBase * /* pCaller */, const std::string &/* sParams */)
@@ -3977,16 +3977,16 @@ public:
CInterfaceManager *pIM= CInterfaceManager::getInstance();
ucstring str;
- fillPlayerBarText(str, "HP", SCORES::hit_points, "uittPlayerLifeFormat");
+ fillPlayerBarText(str, "ChaScore1", SCORES::cha_score1, "uittPlayerChaScore1Format");
CWidgetManager::getInstance()->setContextHelpText(str);
}
};
-REGISTER_ACTION_HANDLER(CHandlerPlayerTTLife, "player_tt_life");
+REGISTER_ACTION_HANDLER(CHandlerPlayerTTChaScore1, "player_tt_cha_score1");
// ***************************************************************************
-// Stamina
-class CHandlerPlayerTTStamina : public IActionHandler
+// ChaScore2
+class CHandlerPlayerTTChaScore2 : public IActionHandler
{
public:
void execute (CCtrlBase * /* pCaller */, const std::string &/* sParams */)
@@ -3994,16 +3994,16 @@ public:
CInterfaceManager *pIM= CInterfaceManager::getInstance();
ucstring str;
- fillPlayerBarText(str, "STA", SCORES::stamina, "uittPlayerStaminaFormat");
+ fillPlayerBarText(str, "ChaScore2", SCORES::cha_score1, "uittPlayerChaScore2Format");
CWidgetManager::getInstance()->setContextHelpText(str);
}
};
-REGISTER_ACTION_HANDLER(CHandlerPlayerTTStamina, "player_tt_stamina");
+REGISTER_ACTION_HANDLER(CHandlerPlayerTTChaScore2, "player_tt_cha_score2");
// ***************************************************************************
-// Sap
-class CHandlerPlayerTTSap : public IActionHandler
+// ChaScore3
+class CHandlerPlayerTTChaScore3 : public IActionHandler
{
public:
void execute (CCtrlBase * /* pCaller */, const std::string &/* sParams */)
@@ -4011,16 +4011,16 @@ public:
CInterfaceManager *pIM= CInterfaceManager::getInstance();
ucstring str;
- fillPlayerBarText(str, "SAP", SCORES::sap, "uittPlayerSapFormat");
+ fillPlayerBarText(str, "ChaScore3", SCORES::cha_score3, "uittPlayerChaScore3Format");
CWidgetManager::getInstance()->setContextHelpText(str);
}
};
-REGISTER_ACTION_HANDLER(CHandlerPlayerTTSap, "player_tt_sap");
+REGISTER_ACTION_HANDLER(CHandlerPlayerTTChaScore3, "player_tt_cha_score3");
// ***************************************************************************
-// Focus
-class CHandlerPlayerTTFocus : public IActionHandler
+// ChaScore4
+class CHandlerPlayerTTChaScore4 : public IActionHandler
{
public:
void execute (CCtrlBase * /* pCaller */, const std::string &/* sParams */)
@@ -4028,12 +4028,12 @@ public:
CInterfaceManager *pIM= CInterfaceManager::getInstance();
ucstring str;
- fillPlayerBarText(str, "FOCUS", SCORES::focus, "uittPlayerFocusFormat");
+ fillPlayerBarText(str, "ChaScore4", SCORES::cha_score4, "uittPlayerChaScore4Format");
CWidgetManager::getInstance()->setContextHelpText(str);
}
};
-REGISTER_ACTION_HANDLER(CHandlerPlayerTTFocus, "player_tt_focus");
+REGISTER_ACTION_HANDLER(CHandlerPlayerTTChaScore4, "player_tt_cha_score4");
// ***************************************************************************
// Bulk: NB: work for player / animal
@@ -4179,7 +4179,7 @@ public:
CRGBA color = CRGBA::stringToRGBA(getParam(sParams, "color").c_str());
if (entity < 256)
- EntitiesMngr.entity (entity)->addHPOutput (CI18N::get (text), color);
+ EntitiesMngr.entity (entity)->addChaScore1Output (CI18N::get (text), color);
}
};
REGISTER_ACTION_HANDLER(CHandlerEntityFlyingText, "entity_flying_text");
diff --git a/code/ryzom/client/src/interface_v3/action_handler_help.cpp b/code/ryzom/client/src/interface_v3/action_handler_help.cpp
index 072d53591..e4959ddb9 100644
--- a/code/ryzom/client/src/interface_v3/action_handler_help.cpp
+++ b/code/ryzom/client/src/interface_v3/action_handler_help.cpp
@@ -1389,8 +1389,8 @@ void getBuffText(CDBCtrlSheet *item, ucstring &itemText)
// retrieve the current itemInfo
const CClientItemInfo &itemInfo= getInventory().getItemInfo(getInventory().getItemSlotId(item) );
- const string valIds[]={"Hp", "Sap", "Sta", "Focus"};
- sint32 vals[]= {itemInfo.HpBuff, itemInfo.SapBuff, itemInfo.StaBuff, itemInfo.FocusBuff};
+ const string valIds[]={"ChaScore1", "ChaScore3", "ChaScore2", "ChaScore4"};
+ sint32 vals[]= {itemInfo.ChaScore1Buff, itemInfo.ChaScore3Buff, itemInfo.ChaScore2Buff, itemInfo.ChaScore4Buff};
uint numVals= sizeof(vals) / sizeof(vals[0]);
ucstring bufInfo;
@@ -1840,7 +1840,7 @@ void getArmorBonus(CDBCtrlSheet *item, ucstring &itemText, const CItemSheet*pIS)
level = item->getQuality() / 2;
if (pIS->Armor.ArmorType == ARMORTYPE::HEAVY || pIS->Armor.ArmorType == ARMORTYPE::MEDIUM)
- armor_bonus = "@{FFFF}(+@{2F2F}" + toString(level) + " @{FFFF}" + CI18N::get("uiHP") + ")";
+ armor_bonus = "@{FFFF}(+@{2F2F}" + toString(level) + " @{FFFF}" + CI18N::get("uiChaScore1") + ")";
strFindReplace(itemText, "%armor_bonus", armor_bonus);
}
@@ -2596,9 +2596,9 @@ static void setupPactHelp(CSheetHelpSetup &setup)
pactText= CI18N::get("uihelpPactFormat");
strFindReplace(pactText, "%lvl", toString(pactLevel));
- strFindReplace(pactText, "%hp", toString(pactLose.LoseHitPointsLevel));
- strFindReplace(pactText, "%sta", toString(pactLose.LoseStaminaLevel));
- strFindReplace(pactText, "%sap", toString(pactLose.LoseSapLevel));
+ strFindReplace(pactText, "%ChaScore1", toString(pactLose.LoseChaScore1Level));
+ strFindReplace(pactText, "%ChaScore2", toString(pactLose.LoseChaScore2Level));
+ strFindReplace(pactText, "%ChaScore3", toString(pactLose.LoseChaScore3Level));
strFindReplace(pactText, "%skill", toString(pactLose.LoseSkillsLevel));
// **** setup the text
@@ -3937,15 +3937,13 @@ public:
s += getSystemInformation();
string progname;
- std::string moduleName;
+ char name[1024] = "";
#ifdef NL_OS_WINDOWS
- wchar_t name[1024];
- GetModuleFileNameW(NULL, name, 1023);
- moduleName = wideToUtf8(name);
+ GetModuleFileName (NULL, name, 1023);
#else
// TODO for Linux
#endif
- progname = CFile::getFilename(moduleName);
+ progname = CFile::getFilename(name);
progname += " ";
progname += "Statistic Report";
diff --git a/code/ryzom/client/src/interface_v3/bar_manager.cpp b/code/ryzom/client/src/interface_v3/bar_manager.cpp
index 21281a700..8c1665044 100644
--- a/code/ryzom/client/src/interface_v3/bar_manager.cpp
+++ b/code/ryzom/client/src/interface_v3/bar_manager.cpp
@@ -97,7 +97,7 @@ void CBarManager::CBarDataEntry::resetDB()
// ***************************************************************************
void CBarManager::CBarDataEntry::connectDB(const std::string &baseDBin, const std::string &baseDBout, const std::string &presentDB,
- const std::string &hpDB, const std::string &sapDB, const std::string &staDB, const std::string &focusDB)
+ const std::string &ChaScore1DB, const std::string &ChaScore3DB, const std::string &ChaScore2DB, const std::string &ChaScore4DB)
{
CInterfaceManager *pIM= CInterfaceManager::getInstance();
@@ -110,27 +110,27 @@ void CBarManager::CBarDataEntry::connectDB(const std::string &baseDBin, const st
UIDIn= NLGUI::CDBManager::getInstance()->getDbProp(baseDBin+"UID", false);
if(!presentDB.empty())
PresentIn= NLGUI::CDBManager::getInstance()->getDbProp(baseDBin+presentDB, false);
- if(!hpDB.empty())
- ScoreIn[SCORES::hit_points]= NLGUI::CDBManager::getInstance()->getDbProp(baseDBin+hpDB, false);
- if(!sapDB.empty())
- ScoreIn[SCORES::sap]= NLGUI::CDBManager::getInstance()->getDbProp(baseDBin+sapDB, false);
- if(!staDB.empty())
- ScoreIn[SCORES::stamina]= NLGUI::CDBManager::getInstance()->getDbProp(baseDBin+staDB, false);
- if(!focusDB.empty())
- ScoreIn[SCORES::focus]= NLGUI::CDBManager::getInstance()->getDbProp(baseDBin+focusDB, false);
+ if(!ChaScore1DB.empty())
+ ScoreIn[SCORES::cha_score1]= NLGUI::CDBManager::getInstance()->getDbProp(baseDBin+ChaScore1DB, false);
+ if(!ChaScore3DB.empty())
+ ScoreIn[SCORES::cha_score3]= NLGUI::CDBManager::getInstance()->getDbProp(baseDBin+ChaScore3DB, false);
+ if(!ChaScore2DB.empty())
+ ScoreIn[SCORES::cha_score2]= NLGUI::CDBManager::getInstance()->getDbProp(baseDBin+ChaScore2DB, false);
+ if(!ChaScore4DB.empty())
+ ScoreIn[SCORES::cha_score4]= NLGUI::CDBManager::getInstance()->getDbProp(baseDBin+ChaScore4DB, false);
}
// try to connect each output entry (don't create)
if(!baseDBout.empty())
{
- if(!hpDB.empty())
- ScoreOut[SCORES::hit_points]= NLGUI::CDBManager::getInstance()->getDbProp(baseDBout+hpDB, false);
- if(!sapDB.empty())
- ScoreOut[SCORES::sap]= NLGUI::CDBManager::getInstance()->getDbProp(baseDBout+sapDB, false);
- if(!staDB.empty())
- ScoreOut[SCORES::stamina]= NLGUI::CDBManager::getInstance()->getDbProp(baseDBout+staDB, false);
- if(!focusDB.empty())
- ScoreOut[SCORES::focus]= NLGUI::CDBManager::getInstance()->getDbProp(baseDBout+focusDB, false);
+ if(!ChaScore1DB.empty())
+ ScoreOut[SCORES::cha_score1]= NLGUI::CDBManager::getInstance()->getDbProp(baseDBout+ChaScore1DB, false);
+ if(!ChaScore3DB.empty())
+ ScoreOut[SCORES::cha_score3]= NLGUI::CDBManager::getInstance()->getDbProp(baseDBout+ChaScore3DB, false);
+ if(!ChaScore2DB.empty())
+ ScoreOut[SCORES::cha_score2]= NLGUI::CDBManager::getInstance()->getDbProp(baseDBout+ChaScore2DB, false);
+ if(!ChaScore4DB.empty())
+ ScoreOut[SCORES::cha_score4]= NLGUI::CDBManager::getInstance()->getDbProp(baseDBout+ChaScore4DB, false);
}
}
@@ -207,28 +207,28 @@ void CBarManager::initInGame()
// *** create connexion to the Local Output database
for(i=0;i<_EntryBars[TeamMemberType].size();i++)
{
- // don't connect FOCUS, since not setuped by SERVER
+ // don't connect ChaScore4, since not setuped by SERVER
_EntryBars[TeamMemberType][i].connectDB(
toString("SERVER:GROUP:%d:",i),
toString("UI:VARIABLES:BARS:TEAM:%d:",i),
"PRESENT",
- "HP", "SAP", "STA", "");
+ "ChaScore1", "ChaScore3", "ChaScore2", "");
}
for(i=0;i<_EntryBars[AnimalType].size();i++)
{
- // don't connect STA, SAP and FOCUS for animal, since they don't have
+ // don't connect ChaScore2, ChaScore3 and ChaScore4 for animal, since they don't have
_EntryBars[AnimalType][i].connectDB(
toString("SERVER:PACK_ANIMAL:BEAST%d:",i),
toString("UI:VARIABLES:BARS:ANIMAL:%d:",i),
"STATUS",
- "HP", "", "", "");
+ "ChaScore1", "", "", "");
}
nlassert(_EntryBars[TargetType].size()==1);
_EntryBars[TargetType][0].connectDB(
"SERVER:TARGET:BARS:",
"UI:VARIABLES:BARS:TARGET:",
"", // no present flag for target (not so important)
- "HP", "SAP", "STA", "FOCUS");
+ "ChaScore1", "ChaScore3", "ChaScore2", "ChaScore4");
// NB: don't connect the DB for entities, since CEntityCL read it directly from getBarsByEntityId() (simpler and faster)
@@ -237,30 +237,30 @@ void CBarManager::initInGame()
nlctassert(MaxEntryType==4);
nlctassert(SCORES::NUM_SCORES==4);
// For each entry type, tells what score they can affect (see DB connection above)
- _EntryScoreFlags[EntityType]= HpFlag | SapFlag | StaFlag | FocusFlag; // all
- _EntryScoreFlags[TeamMemberType]= HpFlag | SapFlag | StaFlag; // anything but focus
- _EntryScoreFlags[AnimalType]= HpFlag; // Hp only
- _EntryScoreFlags[TargetType]= HpFlag | SapFlag | StaFlag | FocusFlag; // all
+ _EntryScoreFlags[EntityType]= ChaScore1Flag | ChaScore3Flag | ChaScore2Flag | ChaScore4Flag; // all
+ _EntryScoreFlags[TeamMemberType]= ChaScore1Flag | ChaScore3Flag | ChaScore2Flag; // anything but ChaScore4
+ _EntryScoreFlags[AnimalType]= ChaScore1Flag; // ChaScore1 only
+ _EntryScoreFlags[TargetType]= ChaScore1Flag | ChaScore3Flag | ChaScore2Flag | ChaScore4Flag; // all
// *** create connexion for User Bar mgt
// user now can only manage 4 scores
nlctassert(SCORES::NUM_SCORES==4);
// Input max values
- _UserScores[SCORES::hit_points].DBInMax= NLGUI::CDBManager::getInstance()->getDbProp("SERVER:CHARACTER_INFO:SCORES0:Max", false);
- _UserScores[SCORES::sap].DBInMax= NLGUI::CDBManager::getInstance()->getDbProp("SERVER:CHARACTER_INFO:SCORES2:Max", false);
- _UserScores[SCORES::stamina].DBInMax= NLGUI::CDBManager::getInstance()->getDbProp("SERVER:CHARACTER_INFO:SCORES1:Max", false);
- _UserScores[SCORES::focus].DBInMax= NLGUI::CDBManager::getInstance()->getDbProp("SERVER:CHARACTER_INFO:SCORES3:Max", false);
+ _UserScores[SCORES::cha_score1].DBInMax= NLGUI::CDBManager::getInstance()->getDbProp("SERVER:CHARACTER_INFO:SCORES0:Max", false);
+ _UserScores[SCORES::cha_score3].DBInMax= NLGUI::CDBManager::getInstance()->getDbProp("SERVER:CHARACTER_INFO:SCORES2:Max", false);
+ _UserScores[SCORES::cha_score2].DBInMax= NLGUI::CDBManager::getInstance()->getDbProp("SERVER:CHARACTER_INFO:SCORES1:Max", false);
+ _UserScores[SCORES::cha_score3].DBInMax= NLGUI::CDBManager::getInstance()->getDbProp("SERVER:CHARACTER_INFO:SCORES3:Max", false);
// Output real values
- _UserScores[SCORES::hit_points].DBOutVal= NLGUI::CDBManager::getInstance()->getDbProp("UI:VARIABLES:USER:HP", false);
- _UserScores[SCORES::sap].DBOutVal= NLGUI::CDBManager::getInstance()->getDbProp("UI:VARIABLES:USER:SAP", false);
- _UserScores[SCORES::stamina].DBOutVal= NLGUI::CDBManager::getInstance()->getDbProp("UI:VARIABLES:USER:STA", false);
- _UserScores[SCORES::focus].DBOutVal= NLGUI::CDBManager::getInstance()->getDbProp("UI:VARIABLES:USER:FOCUS", false);
+ _UserScores[SCORES::cha_score1].DBOutVal= NLGUI::CDBManager::getInstance()->getDbProp("UI:VARIABLES:USER:ChaScore1", false);
+ _UserScores[SCORES::cha_score3].DBOutVal= NLGUI::CDBManager::getInstance()->getDbProp("UI:VARIABLES:USER:ChaScore3", false);
+ _UserScores[SCORES::cha_score2].DBOutVal= NLGUI::CDBManager::getInstance()->getDbProp("UI:VARIABLES:USER:ChaScore2", false);
+ _UserScores[SCORES::cha_score4].DBOutVal= NLGUI::CDBManager::getInstance()->getDbProp("UI:VARIABLES:USER:ChaScore4", false);
// Output ratio values
- _UserScores[SCORES::hit_points].DBOutRatio= NLGUI::CDBManager::getInstance()->getDbProp("UI:VARIABLES:USER:HP_RATIO", false);
- _UserScores[SCORES::sap].DBOutRatio= NLGUI::CDBManager::getInstance()->getDbProp("UI:VARIABLES:USER:SAP_RATIO", false);
- _UserScores[SCORES::stamina].DBOutRatio= NLGUI::CDBManager::getInstance()->getDbProp("UI:VARIABLES:USER:STA_RATIO", false);
- _UserScores[SCORES::focus].DBOutRatio= NLGUI::CDBManager::getInstance()->getDbProp("UI:VARIABLES:USER:FOCUS_RATIO", false);
+ _UserScores[SCORES::cha_score1].DBOutRatio= NLGUI::CDBManager::getInstance()->getDbProp("UI:VARIABLES:USER:ChaScore1_RATIO", false);
+ _UserScores[SCORES::cha_score3].DBOutRatio= NLGUI::CDBManager::getInstance()->getDbProp("UI:VARIABLES:USER:ChaScore3_RATIO", false);
+ _UserScores[SCORES::cha_score2].DBOutRatio= NLGUI::CDBManager::getInstance()->getDbProp("UI:VARIABLES:USER:ChaScore2_RATIO", false);
+ _UserScores[SCORES::cha_score4].DBOutRatio= NLGUI::CDBManager::getInstance()->getDbProp("UI:VARIABLES:USER:ChaScore4_RATIO", false);
}
// ***************************************************************************
@@ -410,7 +410,7 @@ void CBarManager::updateBars(uint dataSetId, CBarInfo barInfo, TGameCycle serve
if(it==_UIDBars.end())
return;
- barInfoLog("BARS: updateBars(dsid=%x, biHP=%d, t=%d, sf=%x", dataSetId, barInfo.Score[SCORES::hit_points], serverTick, scoreFlags);
+ barInfoLog("BARS: updateBars(dsid=%x, biChaScore1=%d, t=%d, sf=%x", dataSetId, barInfo.Score[SCORES::cha_score1], serverTick, scoreFlags);
// special Case: if the info is for the User (slot 0)
if(dataSetId==_EntryBars[EntityType][0].DataSetId)
@@ -585,7 +585,7 @@ CBarManager::CBarInfo CBarManager::getBarsByEntityId(CLFECOMMON::TCLEntityId ent
}
// ***************************************************************************
-void CBarManager::setupUserBarInfo(uint8 msgNumber, sint32 hp, sint32 sap, sint32 sta, sint32 focus)
+void CBarManager::setupUserBarInfo(uint8 msgNumber, sint32 ChaScore1, sint32 ChaScore3, sint32 ChaScore2, sint32 ChaScore4)
{
/*
Since we are not sure of the message order, use a little counter to discard old messages
@@ -614,10 +614,10 @@ void CBarManager::setupUserBarInfo(uint8 msgNumber, sint32 hp, sint32 sap, sint3
_LastUserBarMsgNumber= msgNumber;
// user now can only manage 4 scores
nlctassert(SCORES::NUM_SCORES==4);
- _UserScores[SCORES::hit_points].Score= hp;
- _UserScores[SCORES::sap].Score= sap;
- _UserScores[SCORES::stamina].Score= sta;
- _UserScores[SCORES::focus].Score= focus;
+ _UserScores[SCORES::cha_score1].Score= ChaScore1;
+ _UserScores[SCORES::cha_score3].Score= ChaScore3;
+ _UserScores[SCORES::cha_score2].Score= ChaScore2;
+ _UserScores[SCORES::cha_score4].Score= ChaScore4;
// update actual database now.
for(uint i=0;i(this);
uint32 itemSlotId= getInventory().getItemSlotId(ctrlSheet);
CClientItemInfo itemInfo = getInventory().getItemInfo(itemSlotId);
- ls.push(itemInfo.HpBuff);
+ ls.push(itemInfo.ChaScore1Buff);
return 1;
}
// ***************************************************************************
-int CDBCtrlSheet::luaGetSapBuff(CLuaState &ls)
+int CDBCtrlSheet::luaGetChaScore3Buff(CLuaState &ls)
{
CDBCtrlSheet *ctrlSheet = const_cast(this);
uint32 itemSlotId= getInventory().getItemSlotId(ctrlSheet);
CClientItemInfo itemInfo = getInventory().getItemInfo(itemSlotId);
- ls.push(itemInfo.SapBuff);
+ ls.push(itemInfo.ChaScore3Buff);
return 1;
}
// ***************************************************************************
-int CDBCtrlSheet::luaGetFocusBuff(CLuaState &ls)
+int CDBCtrlSheet::luaGetChaScore4Buff(CLuaState &ls)
{
CDBCtrlSheet *ctrlSheet = const_cast(this);
uint32 itemSlotId= getInventory().getItemSlotId(ctrlSheet);
CClientItemInfo itemInfo = getInventory().getItemInfo(itemSlotId);
- ls.push(itemInfo.FocusBuff);
+ ls.push(itemInfo.ChaScore4Buff);
return 1;
}
// ***************************************************************************
-int CDBCtrlSheet::luaGetStaBuff(CLuaState &ls)
+int CDBCtrlSheet::luaGetChaScore2Buff(CLuaState &ls)
{
CDBCtrlSheet *ctrlSheet = const_cast(this);
uint32 itemSlotId= getInventory().getItemSlotId(ctrlSheet);
CClientItemInfo itemInfo = getInventory().getItemInfo(itemSlotId);
- ls.push(itemInfo.StaBuff);
+ ls.push(itemInfo.ChaScore2Buff);
return 1;
}
@@ -2428,17 +2428,17 @@ void CDBCtrlSheet::drawSheet (sint32 x, sint32 y, bool draging, bool showSelecti
sint costMalus;
CBarManager &bm = *CBarManager::getInstance();
//
- pPM->getPhraseHpCost(phrase, totalActionMalus, cost, costMalus);
- if (cost > bm.getUserScore(SCORES::hit_points)) forceGrayed = true;
+ pPM->getPhraseChaScore1Cost(phrase, totalActionMalus, cost, costMalus);
+ if (cost > bm.getUserScore(SCORES::cha_score1)) forceGrayed = true;
//
- pPM->getPhraseSapCost(phrase, totalActionMalus, cost, costMalus);
- if (cost > bm.getUserScore(SCORES::sap)) forceGrayed = true;
+ pPM->getPhraseChaScore3Cost(phrase, totalActionMalus, cost, costMalus);
+ if (cost > bm.getUserScore(SCORES::cha_score3)) forceGrayed = true;
//
- pPM->getPhraseStaCost(phrase, totalActionMalus, cost, costMalus);
- if (cost > bm.getUserScore(SCORES::stamina)) forceGrayed = true;
+ pPM->getPhraseChaScore2Cost(phrase, totalActionMalus, cost, costMalus);
+ if (cost > bm.getUserScore(SCORES::cha_score2)) forceGrayed = true;
//
- pPM->getPhraseFocusCost(phrase, totalActionMalus, cost, costMalus);
- if (cost > bm.getUserScore(SCORES::focus)) forceGrayed = true;
+ pPM->getPhraseChaScore4Cost(phrase, totalActionMalus, cost, costMalus);
+ if (cost > bm.getUserScore(SCORES::cha_score4)) forceGrayed = true;
}
}
}
diff --git a/code/ryzom/client/src/interface_v3/dbctrl_sheet.h b/code/ryzom/client/src/interface_v3/dbctrl_sheet.h
index 8c697d660..e1becbbb9 100644
--- a/code/ryzom/client/src/interface_v3/dbctrl_sheet.h
+++ b/code/ryzom/client/src/interface_v3/dbctrl_sheet.h
@@ -280,10 +280,10 @@ public:
REFLECT_STRING ("on_can_drop", getActionOnCanDrop, setActionOnCanDrop);
REFLECT_STRING ("on_can_drop_params", getParamsOnCanDrop, setParamsOnCanDrop);
REFLECT_LUA_METHOD("getDraggedSheet", luaGetDraggedSheet)
- REFLECT_LUA_METHOD("getHpBuff", luaGetHpBuff)
- REFLECT_LUA_METHOD("getSapBuff", luaGetSapBuff)
- REFLECT_LUA_METHOD("getFocusBuff", luaGetFocusBuff)
- REFLECT_LUA_METHOD("getStaBuff", luaGetStaBuff)
+ REFLECT_LUA_METHOD("getChaScore1Buff", luaGetChaScore1Buff)
+ REFLECT_LUA_METHOD("getChaScore3Buff", luaGetChaScore3Buff)
+ REFLECT_LUA_METHOD("getChaScore4Buff", luaGetChaScore4Buff)
+ REFLECT_LUA_METHOD("getChaScore2Buff", luaGetChaScore2Buff)
REFLECT_LUA_METHOD("getName", luaGetName)
REFLECT_LUA_METHOD("getCreatorName", luaGetCreatorName)
REFLECT_LUA_METHOD("waitInfo", luaWaitInfo)
@@ -291,10 +291,10 @@ public:
REFLECT_EXPORT_END
int luaGetDraggedSheet(CLuaState &ls);
- int luaGetHpBuff(CLuaState &ls);
- int luaGetSapBuff(CLuaState &ls);
- int luaGetFocusBuff(CLuaState &ls);
- int luaGetStaBuff(CLuaState &ls);
+ int luaGetChaScore1Buff(CLuaState &ls);
+ int luaGetChaScore3Buff(CLuaState &ls);
+ int luaGetChaScore4Buff(CLuaState &ls);
+ int luaGetChaScore2Buff(CLuaState &ls);
int luaGetName(CLuaState &ls);
int luaGetCreatorName(CLuaState &ls);
int luaWaitInfo(CLuaState &ls);
diff --git a/code/ryzom/client/src/interface_v3/group_in_scene_user_info.cpp b/code/ryzom/client/src/interface_v3/group_in_scene_user_info.cpp
index 53cddc93b..cc42f4322 100644
--- a/code/ryzom/client/src/interface_v3/group_in_scene_user_info.cpp
+++ b/code/ryzom/client/src/interface_v3/group_in_scene_user_info.cpp
@@ -59,10 +59,10 @@ public:
inline NLMISC::CCDBNodeLeaf *getTitle() { return _Title ? (&*_Title) : &*(_Title = NLGUI::CDBManager::getInstance()->getDbProp(_DBPrefix + "TITLE")); }
inline NLMISC::CCDBNodeLeaf *getRPTags() { return _RPTags ? (&*_RPTags) : &*(_RPTags = NLGUI::CDBManager::getInstance()->getDbProp(_DBPrefix + "RPTAGS")); }
inline NLMISC::CCDBNodeLeaf *getGuildName() { return _GuildName ? (&*_GuildName) : &*(_GuildName = NLGUI::CDBManager::getInstance()->getDbProp(_DBPrefix + "GUILD_NAME")); }
- inline NLMISC::CCDBNodeLeaf *getHP() { return _HP ? (&*_HP) : &*(_HP = NLGUI::CDBManager::getInstance()->getDbProp(_DBPrefix + "HP")); }
- inline NLMISC::CCDBNodeLeaf *getSta() { return _Sta ? (&*_Sta) : &*(_Sta = NLGUI::CDBManager::getInstance()->getDbProp(_DBPrefix + "STA")); }
- inline NLMISC::CCDBNodeLeaf *getSap() { return _Sap ? (&*_Sap) : &*(_Sap = NLGUI::CDBManager::getInstance()->getDbProp(_DBPrefix + "SAP")); }
- inline NLMISC::CCDBNodeLeaf *getFocus() { return _Focus ? (&*_Focus) : &*(_Focus = NLGUI::CDBManager::getInstance()->getDbProp(_DBPrefix + "FOCUS")); }
+ inline NLMISC::CCDBNodeLeaf *getChaScore1() { return _ChaScore1 ? (&*_ChaScore1) : &*(_ChaScore1 = NLGUI::CDBManager::getInstance()->getDbProp(_DBPrefix + "ChaScore1")); }
+ inline NLMISC::CCDBNodeLeaf *getChaScore2() { return _ChaScore2 ? (&*_ChaScore2) : &*(_ChaScore2 = NLGUI::CDBManager::getInstance()->getDbProp(_DBPrefix + "ChaScore2")); }
+ inline NLMISC::CCDBNodeLeaf *getChaScore3() { return _ChaScore3 ? (&*_ChaScore3) : &*(_ChaScore3 = NLGUI::CDBManager::getInstance()->getDbProp(_DBPrefix + "ChaScore3")); }
+ inline NLMISC::CCDBNodeLeaf *getChaScore4() { return _ChaScore4 ? (&*_ChaScore4) : &*(_ChaScore4 = NLGUI::CDBManager::getInstance()->getDbProp(_DBPrefix + "ChaScore4")); }
inline NLMISC::CCDBNodeLeaf *getAction() { return _Action ? (&*_Action) : &*(_Action = NLGUI::CDBManager::getInstance()->getDbProp(_DBPrefix + "ACTION")); }
inline NLMISC::CCDBNodeLeaf *getMessages() { return _Messages ? (&*_Messages) : &*(_Messages = NLGUI::CDBManager::getInstance()->getDbProp(_DBPrefix + "MESSAGES")); }
inline NLMISC::CCDBNodeLeaf *getPvPLogo() { return _PvPLogo ? (&*_PvPLogo) : &*(_PvPLogo = NLGUI::CDBManager::getInstance()->getDbProp(_DBPrefix + "PVP_LOGO")); }
@@ -77,10 +77,10 @@ private:
NLMISC::CRefPtr _Title;
NLMISC::CRefPtr _RPTags;
NLMISC::CRefPtr _GuildName;
- NLMISC::CRefPtr _HP;
- NLMISC::CRefPtr _Sta;
- NLMISC::CRefPtr _Sap;
- NLMISC::CRefPtr _Focus;
+ NLMISC::CRefPtr _ChaScore1;
+ NLMISC::CRefPtr _ChaScore2;
+ NLMISC::CRefPtr _ChaScore3;
+ NLMISC::CRefPtr _ChaScore4;
NLMISC::CRefPtr _Action;
NLMISC::CRefPtr _Messages;
NLMISC::CRefPtr _PvPLogo;
@@ -150,7 +150,7 @@ CRGBA CGroupInSceneUserInfo::BarColor[NumBars]=
CRGBA(255, 255, 255),
};
-CRGBA CGroupInSceneUserInfo::BarColorHPNegative = CRGBA(127, 32, 0);
+CRGBA CGroupInSceneUserInfo::BarColorChaScore1Negative = CRGBA(127, 32, 0);
// ***************************************************************************
@@ -227,7 +227,7 @@ CGroupInSceneUserInfo *CGroupInSceneUserInfo::build (CEntityCL *entity)
forageSourceBarDisplayed = (entity->slot() == UserEntity->selection());
bars[Time] = forageSourceBarDisplayed;
bars[Amount] = forageSourceBarDisplayed;
- //bool displayExtractingParams = true; //forageSource->isExtractionInProgress() /*&& NLGUI::CDBManager::getInstance()->getDbProp(dbEntry+"HP")*/;
+ //bool displayExtractingParams = true; //forageSource->isExtractionInProgress() /*&& NLGUI::CDBManager::getInstance()->getDbProp(dbEntry+"ChaScore1")*/;
bars[Life] = forageSourceBarDisplayed;//displayExtractingParams;
bars[Danger] = forageSourceBarDisplayed;//displayExtractingParams;
bars[Spawn] = forageSourceBarDisplayed;//displayExtractingParams;
@@ -862,18 +862,18 @@ void CGroupInSceneUserInfo::getBarSettings( CInterfaceManager* pIM, bool isUser,
// if currently is edition mode, then bars are not displayed
if (ClientCfg.R2EDEnabled && R2::isEditionCurrent())
{
- bars[HP] = false;
- bars[SAP] = false;
- bars[STA] = false;
- bars[Focus] = false;
+ bars[ChaScore1] = false;
+ bars[ChaScore3] = false;
+ bars[ChaScore2] = false;
+ bars[ChaScore4] = false;
bars[Action] = false;
}
else
{
- bars[HP] = _ConfigSaveInsceneDB[dbEntry].getHP()->getValueBool();
- bars[SAP] = (isUser || isFriend) && (isUser || isPlayer) && _ConfigSaveInsceneDB[dbEntry].getSap()->getValueBool();
- bars[STA] = (isUser || isFriend) && (isUser || isPlayer) && _ConfigSaveInsceneDB[dbEntry].getSta()->getValueBool();
- bars[Focus] = (isUser || isFriend) && (isUser || isPlayer) && _ConfigSaveInsceneDB[dbEntry].getFocus()->getValueBool();
+ bars[ChaScore1] = _ConfigSaveInsceneDB[dbEntry].getChaScore1()->getValueBool();
+ bars[ChaScore3] = (isUser || isFriend) && (isUser || isPlayer) && _ConfigSaveInsceneDB[dbEntry].getChaScore3()->getValueBool();
+ bars[ChaScore2] = (isUser || isFriend) && (isUser || isPlayer) && _ConfigSaveInsceneDB[dbEntry].getChaScore2()->getValueBool();
+ bars[ChaScore4] = (isUser || isFriend) && (isUser || isPlayer) && _ConfigSaveInsceneDB[dbEntry].getChaScore4()->getValueBool();
bars[Action] = (isUser) && _ConfigSaveInsceneDB[dbEntry].getAction()->getValueBool();
}
}
@@ -1059,28 +1059,28 @@ void CGroupInSceneUserInfo::updateDynamicData ()
// NB: forage don't use CBarManager for 2 reasons: useless (forage bars exist only through VP),
// and complicated since updated at each frame on client (because of smooth transition code)
CForageSourceCL *forageSource = static_cast(_Entity);
- barInfo.Score[SCORES::hit_points]= forageSource->getTimeBar(); // Map TimeBar to HP
- barInfo.Score[SCORES::sap]= forageSource->getQuantityBar(); // Map QuantityBar to SAP
- barInfo.Score[SCORES::stamina]= forageSource->getDBar(); // Map D Bar to Sta
- barInfo.Score[SCORES::focus]= forageSource->getEBar(); // Map E Bar to Focus
+ barInfo.Score[SCORES::cha_score1]= forageSource->getTimeBar(); // Map TimeBar to ChaScore1
+ barInfo.Score[SCORES::cha_score3]= forageSource->getQuantityBar(); // Map QuantityBar to ChaScore3
+ barInfo.Score[SCORES::cha_score2]= forageSource->getDBar(); // Map D Bar to ChaScore2
+ barInfo.Score[SCORES::cha_score4]= forageSource->getEBar(); // Map E Bar to ChaScore4
}
// Set the bar
- if (_Bars[HP])
+ if (_Bars[ChaScore1])
{
- sint value = (sint)_BatLength * barInfo.Score[SCORES::hit_points] / RZ_BARS_LENGTH;
+ sint value = (sint)_BatLength * barInfo.Score[SCORES::cha_score1] / RZ_BARS_LENGTH;
if ( ! _Entity->isForageSource() )
{
if (value < 0)
{
value = -value;
- _Bars[HP]->setColorRGBA(BarColorHPNegative);
+ _Bars[ChaScore1]->setColorRGBA(BarColorChaScore1Negative);
}
else
{
- _Bars[HP]->setColorRGBA(BarColor[HP]);
+ _Bars[ChaScore1]->setColorRGBA(BarColor[ChaScore1]);
}
- // if dead creature, force the hp to 0
+ // if dead creature, force the ChaScore1 to 0
if( _Entity->mode() == MBEHAV::DEATH && !_Entity->isPlayer() && !_Entity->isUser())
{
if( value > 0 )
@@ -1095,22 +1095,22 @@ void CGroupInSceneUserInfo::updateDynamicData ()
CForageSourceCL *forageSource = static_cast(_Entity);
if ( forageSource->isInExtraTime() )
{
- _Bars[HP]->setColorRGBA(
+ _Bars[ChaScore1]->setColorRGBA(
forageSource->isInProspectionExtraTime() ?
CRGBA( 255, 0, 0 ) : // red
CRGBA( 235, 144, 0 ) ); // orange
}
}
clamp (value, 0, (sint)_BatLength);
- if(_Bars[HP]->getW() != value)
- _Bars[HP]->setWAndInvalidateCoords (value);
+ if(_Bars[ChaScore1]->getW() != value)
+ _Bars[ChaScore1]->setWAndInvalidateCoords (value);
}
- if (_Bars[SAP])
+ if (_Bars[ChaScore3])
{
- int value = _BatLength * barInfo.Score[SCORES::sap] / RZ_BARS_LENGTH;
+ int value = _BatLength * barInfo.Score[SCORES::cha_score3] / RZ_BARS_LENGTH;
clamp (value, 0, (int)_BatLength);
- if(_Bars[SAP]->getW() != value)
- _Bars[SAP]->setWAndInvalidateCoords (value);
+ if(_Bars[ChaScore3]->getW() != value)
+ _Bars[ChaScore3]->setWAndInvalidateCoords (value);
// Forage source quantity bar: update contents value in tooltip
if ( _Entity->isForageSource() )
@@ -1126,27 +1126,27 @@ void CGroupInSceneUserInfo::updateDynamicData ()
toolTip2->setDefaultContextHelp( txt );
}
}
- if (_Bars[STA])
+ if (_Bars[ChaScore2])
{
- int value = _BatLength * barInfo.Score[SCORES::stamina] / RZ_BARS_LENGTH;
+ int value = _BatLength * barInfo.Score[SCORES::cha_score2] / RZ_BARS_LENGTH;
clamp (value, 0, (int)_BatLength);
- if(_Bars[STA]->getW() != value)
+ if(_Bars[ChaScore2]->getW() != value)
{
// Forage source life bar: update danger colour
if ( _Entity->isForageSource() )
{
- CRGBA color = _Bars[STA]->getColorRGBA();
- color.blendFromuiRGBOnly( CRGBA( 255, 127, 127 ), CRGBA( 255, 0, 0 ), (RZ_BARS_LENGTH - barInfo.Score[SCORES::stamina]) * (256/RZ_BARS_LENGTH) );
- _Bars[STA]->setColorRGBA( color );
+ CRGBA color = _Bars[ChaScore2]->getColorRGBA();
+ color.blendFromuiRGBOnly( CRGBA( 255, 127, 127 ), CRGBA( 255, 0, 0 ), (RZ_BARS_LENGTH - barInfo.Score[SCORES::cha_score2]) * (256/RZ_BARS_LENGTH) );
+ _Bars[ChaScore2]->setColorRGBA( color );
}
- _Bars[STA]->setWAndInvalidateCoords (value);
+ _Bars[ChaScore2]->setWAndInvalidateCoords (value);
}
}
- if (_Bars[Focus])
+ if (_Bars[ChaScore4])
{
- int value = _BatLength * barInfo.Score[SCORES::focus] / RZ_BARS_LENGTH;
+ int value = _BatLength * barInfo.Score[SCORES::cha_score4] / RZ_BARS_LENGTH;
clamp (value, 0, (int)_BatLength);
- if(_Bars[Focus]->getW() != value)
+ if(_Bars[ChaScore4]->getW() != value)
{
// Forage source life bar: update danger colour
if ( _Entity->isForageSource() )
@@ -1154,16 +1154,16 @@ void CGroupInSceneUserInfo::updateDynamicData ()
CForageSourceCL *forageSource = static_cast(_Entity);
if ( forageSource->isSafe() )
{
- _Bars[Focus]->setColorRGBA( CForageSourceCL::SafeSourceColor );
+ _Bars[ChaScore4]->setColorRGBA( CForageSourceCL::SafeSourceColor );
}
else
{
- CRGBA color = _Bars[Focus]->getColorRGBA();
- color.blendFromuiRGBOnly( CRGBA( 255, 175, 0 ), CRGBA( 255, 0, 0 ), (RZ_BARS_LENGTH - barInfo.Score[SCORES::focus]) * (256/RZ_BARS_LENGTH) );
- _Bars[Focus]->setColorRGBA( color );
+ CRGBA color = _Bars[ChaScore4]->getColorRGBA();
+ color.blendFromuiRGBOnly( CRGBA( 255, 175, 0 ), CRGBA( 255, 0, 0 ), (RZ_BARS_LENGTH - barInfo.Score[SCORES::cha_score4]) * (256/RZ_BARS_LENGTH) );
+ _Bars[ChaScore4]->setColorRGBA( color );
}
}
- _Bars[Focus]->setWAndInvalidateCoords (value);
+ _Bars[ChaScore4]->setWAndInvalidateCoords (value);
}
}
diff --git a/code/ryzom/client/src/interface_v3/group_in_scene_user_info.h b/code/ryzom/client/src/interface_v3/group_in_scene_user_info.h
index 3869a74b1..b2843341b 100644
--- a/code/ryzom/client/src/interface_v3/group_in_scene_user_info.h
+++ b/code/ryzom/client/src/interface_v3/group_in_scene_user_info.h
@@ -63,10 +63,10 @@ protected:
enum TBar
{
// Living entity Forage source
- HP = 0, Time = HP, // If making changes to this enum, please update
- SAP, Amount = SAP, // CForageSourceCL::updateVisualPropertyBars() and
- STA, Life = STA, // updateVisiblePostPos() because the HP/SAP/STA
- Focus, Danger = Focus, // properties are *not* in an array in CEntityCL.
+ ChaScore1 = 0, Time = ChaScore1, // If making changes to this enum, please update
+ ChaScore3, Amount = ChaScore3, // CForageSourceCL::updateVisualPropertyBars() and
+ ChaScore2, Life = ChaScore2, // updateVisiblePostPos() because the ChaScore1/ChaScore3/ChaScore2
+ ChaScore4, Danger = ChaScore4, // properties are *not* in an array in CEntityCL.
Action, Spawn = Action,
NumBars
};
@@ -90,7 +90,7 @@ protected:
class CViewBitmap *_MissionTarget;
static uint _BatLength;
static NLMISC::CRGBA BarColor[NumBars];
- static NLMISC::CRGBA BarColorHPNegative;
+ static NLMISC::CRGBA BarColorChaScore1Negative;
// Node user leaf
static NLMISC::CCDBNodeLeaf *_Value;
diff --git a/code/ryzom/client/src/interface_v3/interface_manager.cpp b/code/ryzom/client/src/interface_v3/interface_manager.cpp
index de06251f7..0b5e6b33a 100644
--- a/code/ryzom/client/src/interface_v3/interface_manager.cpp
+++ b/code/ryzom/client/src/interface_v3/interface_manager.cpp
@@ -1004,7 +1004,7 @@ void CInterfaceManager::initInGame()
// Init FlyingText manager
FlyingTextManager.initInGame();
- // Init Bar Manager (HP, SAP etc... Bars)
+ // Init Bar Manager (ChaScore1, ChaScore2 etc... Bars)
CBarManager::getInstance()->initInGame();
// Init interface props linked to client time
@@ -1275,7 +1275,7 @@ void CInterfaceManager::uninitInGame0 ()
void CInterfaceManager::uninitInGame1 ()
{
- // release Bar Manager (HP, SAP etc... Bars)
+ // release Bar Manager (ChaScore1, ChaScore2 etc... Bars)
CBarManager::getInstance()->releaseInGame();
// release FlyingTextManager
@@ -1833,8 +1833,7 @@ bool CInterfaceManager::saveConfig (const string &filename)
COFile f;
- // using temporary file, so no f.close() unless its a success
- if (!f.open(filename, false, false, true)) return false;
+ if (!f.open(filename)) return false;
CInterfaceConfig ic;
@@ -1881,6 +1880,7 @@ bool CInterfaceManager::saveConfig (const string &filename)
{
nlwarning("Config saving failed");
// couldn't save result so do not continue
+ f.close();
return false;
}
@@ -1936,14 +1936,14 @@ bool CInterfaceManager::saveConfig (const string &filename)
nlwarning("Bad user dyn chat saving");
return false;
}
-
- f.close();
}
catch(const NLMISC::EStream &)
{
+ f.close();
nlwarning("Config saving failed.");
return false;
}
+ f.close();
ContinentMngr.serialFOWMaps();
@@ -2652,8 +2652,7 @@ bool CInterfaceManager::saveKeys(const std::string &filename)
try
{
COFile file;
- // using temporary file, so no file.close() unless its a success
- if (file.open (filename, false, false, true))
+ if (file.open (filename))
{
COXml xmlStream;
xmlStream.init (&file);
@@ -2683,7 +2682,8 @@ bool CInterfaceManager::saveKeys(const std::string &filename)
}
catch (const Exception &e)
{
- nlwarning ("Error while writing the file %s : %s.", filename.c_str(), e.what ());
+ nlwarning ("Error while writing the file %s : %s. Remove it.", filename.c_str(), e.what ());
+ CFile::deleteFile(filename);
}
return ret;
}
@@ -2711,7 +2711,7 @@ void CInterfaceManager::log(const ucstring &str, const std::string &cat)
{
// Open file with the name of the player
const string fileName= "save/log_" + PlayerSelectedFileName + ".txt";
- FILE *f = nlfopen(fileName, "at");
+ FILE *f = fopen(fileName.c_str(), "at");
if (f != NULL)
{
const string finalString = string(NLMISC::IDisplayer::dateToHumanString()) + " (" + NLMISC::toUpper(cat) + ") * " + str.toUtf8();
diff --git a/code/ryzom/client/src/interface_v3/item_consumable_effect.cpp b/code/ryzom/client/src/interface_v3/item_consumable_effect.cpp
index 6e50666b1..e98a80407 100644
--- a/code/ryzom/client/src/interface_v3/item_consumable_effect.cpp
+++ b/code/ryzom/client/src/interface_v3/item_consumable_effect.cpp
@@ -87,7 +87,7 @@ void CItemConsumableEffectHelper::getItemConsumableEffectText(const CItemSheet *
effects += "\n";
}
- if ( name == "SP_LIFE_AURA" )
+ if ( name == "SP_ChaScore1_AURA" )
{
uint16 regenMod;
@@ -101,7 +101,7 @@ void CItemConsumableEffectHelper::getItemConsumableEffectText(const CItemSheet *
uint32 userDisableTime;
fromString(params[4].c_str(), userDisableTime);
- ucstring result = CI18N::get("uiItemConsumableEffectLifeAura");
+ ucstring result = CI18N::get("uiItemConsumableEffectChaScore1Aura");
strFindReplace(result, "%modifier", toString(regenMod));
strFindReplace(result, "%minutes", toString(duration/60));
strFindReplace(result, "%secondes", toString(duration%60));
@@ -113,7 +113,7 @@ void CItemConsumableEffectHelper::getItemConsumableEffectText(const CItemSheet *
effects += "\n";
}
- if ( name == "SP_LIFE_AURA2" )
+ if ( name == "SP_ChaScore1_AURA2" )
{
uint16 regenMod;
@@ -128,7 +128,7 @@ void CItemConsumableEffectHelper::getItemConsumableEffectText(const CItemSheet *
uint32 userDisableTime;
fromString(params[4].c_str(), userDisableTime);
- ucstring result = CI18N::get("uiItemConsumableEffectLifeAura");
+ ucstring result = CI18N::get("uiItemConsumableEffectChaScore1Aura");
strFindReplace(result, "%modifier", toString(bonus));
strFindReplace(result, "%minutes", toString(duration/60));
strFindReplace(result, "%secondes", toString(duration%60));
@@ -140,7 +140,7 @@ void CItemConsumableEffectHelper::getItemConsumableEffectText(const CItemSheet *
effects += "\n";
}
- if ( name == "SP_STAMINA_AURA" )
+ if ( name == "SP_ChaScore2_AURA" )
{
uint16 regenMod;
@@ -154,7 +154,7 @@ void CItemConsumableEffectHelper::getItemConsumableEffectText(const CItemSheet *
uint32 userDisableTime;
fromString(params[4].c_str(), userDisableTime);
- ucstring result = CI18N::get("uiItemConsumableEffectStaminaAura");
+ ucstring result = CI18N::get("uiItemConsumableEffectChaScore2Aura");
strFindReplace(result, "%modifier", toString(regenMod));
strFindReplace(result, "%minutes", toString(duration/60));
strFindReplace(result, "%secondes", toString(duration%60));
@@ -167,7 +167,7 @@ void CItemConsumableEffectHelper::getItemConsumableEffectText(const CItemSheet *
}
- if ( name == "SP_STAMINA_AURA2" )
+ if ( name == "SP_ChaScore2_AURA2" )
{
uint16 regenMod;
@@ -182,7 +182,7 @@ void CItemConsumableEffectHelper::getItemConsumableEffectText(const CItemSheet *
uint32 userDisableTime;
fromString(params[4].c_str(), userDisableTime);
- ucstring result = CI18N::get("uiItemConsumableEffectStaminaAura");
+ ucstring result = CI18N::get("uiItemConsumableEffectChaScore2Aura");
strFindReplace(result, "%modifier", toString(bonus));
strFindReplace(result, "%minutes", toString(duration/60));
strFindReplace(result, "%secondes", toString(duration%60));
@@ -194,7 +194,7 @@ void CItemConsumableEffectHelper::getItemConsumableEffectText(const CItemSheet *
effects += "\n";
}
- if ( name == "SP_SAP_AURA" )
+ if ( name == "SP_ChaScore3_AURA" )
{
uint16 regenMod;
@@ -208,7 +208,7 @@ void CItemConsumableEffectHelper::getItemConsumableEffectText(const CItemSheet *
uint32 userDisableTime;
fromString(params[4].c_str(), userDisableTime);
- ucstring result = CI18N::get("uiItemConsumableEffectSapAura");
+ ucstring result = CI18N::get("uiItemConsumableEffectChaScore3Aura");
strFindReplace(result, "%modifier", toString(regenMod));
strFindReplace(result, "%minutes", toString(duration/60));
strFindReplace(result, "%secondes", toString(duration%60));
@@ -220,7 +220,7 @@ void CItemConsumableEffectHelper::getItemConsumableEffectText(const CItemSheet *
effects += "\n";
}
- if ( name == "SP_SAP_AURA2" )
+ if ( name == "SP_ChaScore3_AURA2" )
{
uint16 regenMod;
@@ -235,7 +235,7 @@ void CItemConsumableEffectHelper::getItemConsumableEffectText(const CItemSheet *
uint32 userDisableTime;
fromString(params[4].c_str(), userDisableTime);
- ucstring result = CI18N::get("uiItemConsumableEffectSapAura");
+ ucstring result = CI18N::get("uiItemConsumableEffectChaScore3Aura");
strFindReplace(result, "%modifier", toString(bonus));
strFindReplace(result, "%minutes", toString(duration/60));
strFindReplace(result, "%secondes", toString(duration%60));
diff --git a/code/ryzom/client/src/interface_v3/sbrick_manager.cpp b/code/ryzom/client/src/interface_v3/sbrick_manager.cpp
index 86946e2e1..bdd707c8a 100644
--- a/code/ryzom/client/src/interface_v3/sbrick_manager.cpp
+++ b/code/ryzom/client/src/interface_v3/sbrick_manager.cpp
@@ -422,11 +422,11 @@ void CSBrickManager::compileBrickProperties()
}
// Get usual PropIds
- HpPropId= getBrickPropId("hp");
- SapPropId= getBrickPropId("sap");
- StaPropId= getBrickPropId("sta");
- StaWeightFactorId = getBrickPropId("sta_weight_factor");
- FocusPropId= getBrickPropId("focus");
+ ChaScore1PropId= getBrickPropId("ChaScore1");
+ ChaScore3PropId= getBrickPropId("ChaScore3");
+ ChaScore2PropId= getBrickPropId("ChaScore2");
+ ChaScore2WeightFactorId = getBrickPropId("ChaScore2_weight_factor");
+ ChaScore4PropId= getBrickPropId("ChaScore4");
CastTimePropId= getBrickPropId("ma_casting_time");
RangePropId= getBrickPropId("ma_range");
diff --git a/code/ryzom/client/src/interface_v3/sbrick_manager.h b/code/ryzom/client/src/interface_v3/sbrick_manager.h
index d963309bf..00d86ce91 100644
--- a/code/ryzom/client/src/interface_v3/sbrick_manager.h
+++ b/code/ryzom/client/src/interface_v3/sbrick_manager.h
@@ -128,11 +128,11 @@ public:
// get a prop Id from its name.
uint getBrickPropId(const std::string &name);
// Important Ids for properties (to compute cost, range etc...).
- uint HpPropId;
- uint SapPropId;
- uint StaPropId;
- uint StaWeightFactorId;
- uint FocusPropId;
+ uint ChaScore1PropId;
+ uint ChaScore3PropId;
+ uint ChaScore2PropId;
+ uint ChaScore2WeightFactorId;
+ uint ChaScore4PropId;
uint CastTimePropId;
uint RangePropId;
// @}
diff --git a/code/ryzom/client/src/interface_v3/sphrase_manager.cpp b/code/ryzom/client/src/interface_v3/sphrase_manager.cpp
index 0b96f77a3..fc0b840c7 100644
--- a/code/ryzom/client/src/interface_v3/sphrase_manager.cpp
+++ b/code/ryzom/client/src/interface_v3/sphrase_manager.cpp
@@ -1135,19 +1135,19 @@ void CSPhraseManager::buildPhraseDesc(ucstring &text, const CSPhraseCom &phrase,
sint success= getPhraseSuccessRate(phrase);
float castTime= 0, castTimeMalus= 0;
sint range= 0, rangeMalus= 0;
- sint hpCost= 0, hpCostMalus= 0;
+ sint ChaScore1Cost= 0, ChaScore1CostMalus= 0;
sint enCost= 0, enCostMalus= 0;
getPhraseCastTime(phrase, totalActionMalus, castTime, castTimeMalus);
getPhraseMagicRange(phrase, totalActionMalus, range, rangeMalus);
- getPhraseHpCost(phrase, totalActionMalus, hpCost, hpCostMalus);
+ getPhraseChaScore1Cost(phrase, totalActionMalus, ChaScore1Cost, ChaScore1CostMalus);
if(rootBrick->isCombat())
- getPhraseStaCost(phrase, totalActionMalus, enCost, enCostMalus);
+ getPhraseChaScore2Cost(phrase, totalActionMalus, enCost, enCostMalus);
else if(rootBrick->isMagic())
- getPhraseSapCost(phrase, totalActionMalus, enCost, enCostMalus);
+ getPhraseChaScore3Cost(phrase, totalActionMalus, enCost, enCostMalus);
else
- getPhraseFocusCost(phrase, totalActionMalus, enCost, enCostMalus);
+ getPhraseChaScore4Cost(phrase, totalActionMalus, enCost, enCostMalus);
sint32 successModifier = 0;
CCDBNodeLeaf * nodeSM = NULL;
@@ -1198,7 +1198,7 @@ void CSPhraseManager::buildPhraseDesc(ucstring &text, const CSPhraseCom &phrase,
strFindReplace(text, "%success", toString(successStr));
strFindReplace(text, "%duration", formatMalus(castTime, castTimeMalus) );
strFindReplace(text, "%energy_cost", formatMalus(enCost, enCostMalus) );
- strFindReplace(text, "%hp_cost", formatMalus(hpCost, hpCostMalus) );
+ strFindReplace(text, "%ChaScore1_cost", formatMalus(ChaScore1Cost, ChaScore1CostMalus) );
// special range and "self"
if(range==0)
strFindReplace(text, "%range", CI18N::get("uihelpPhraseRangeSelf"));
@@ -1461,38 +1461,38 @@ sint CSPhraseManager::getForageExtractionPhraseSuccessRate(const CSPhraseCom
}
// ***************************************************************************
-void CSPhraseManager::getPhraseSapCost(const CSPhraseCom &phrase, uint32 totalActionMalus, sint &cost, sint &costMalus)
+void CSPhraseManager::getPhraseChaScore3Cost(const CSPhraseCom &phrase, uint32 totalActionMalus, sint &cost, sint &costMalus)
{
CSBrickManager *pBM= CSBrickManager::getInstance();
- cost= (sint)getPhraseSumBrickProp(phrase, pBM->SapPropId, true);
+ cost= (sint)getPhraseSumBrickProp(phrase, pBM->ChaScore3PropId, true);
// compute malus (positive)
costMalus= (cost * (totalActionMalus))/100;
}
// ***************************************************************************
-void CSPhraseManager::getPhraseStaCost(const CSPhraseCom &phrase, uint32 totalActionMalus, sint &cost, sint &costMalus)
+void CSPhraseManager::getPhraseChaScore2Cost(const CSPhraseCom &phrase, uint32 totalActionMalus, sint &cost, sint &costMalus)
{
CSBrickManager *pBM= CSBrickManager::getInstance();
- cost= (sint)getPhraseSumBrickProp(phrase, pBM->StaPropId, true);
+ cost= (sint)getPhraseSumBrickProp(phrase, pBM->ChaScore2PropId, true);
// TODO: combat special case
// compute malus (positive)
costMalus= (cost * (totalActionMalus))/100;
}
// ***************************************************************************
-void CSPhraseManager::getPhraseFocusCost(const CSPhraseCom &phrase, uint32 totalActionMalus, sint &cost, sint &costMalus)
+void CSPhraseManager::getPhraseChaScore4Cost(const CSPhraseCom &phrase, uint32 totalActionMalus, sint &cost, sint &costMalus)
{
CSBrickManager *pBM= CSBrickManager::getInstance();
- cost= (sint)getPhraseSumBrickProp(phrase, pBM->FocusPropId, true);
+ cost= (sint)getPhraseSumBrickProp(phrase, pBM->ChaScore4PropId, true);
// compute malus (positive)
costMalus= (cost * (totalActionMalus))/100;
}
// ***************************************************************************
-void CSPhraseManager::getPhraseHpCost(const CSPhraseCom &phrase, uint32 totalActionMalus, sint &cost, sint &costMalus)
+void CSPhraseManager::getPhraseChaScore1Cost(const CSPhraseCom &phrase, uint32 totalActionMalus, sint &cost, sint &costMalus)
{
CSBrickManager *pBM= CSBrickManager::getInstance();
- cost= (sint)getPhraseSumBrickProp(phrase, pBM->HpPropId, true);
+ cost= (sint)getPhraseSumBrickProp(phrase, pBM->ChaScore1PropId, true);
// compute malus (positive)
costMalus= (cost * (totalActionMalus))/100;
}
@@ -1656,7 +1656,7 @@ float CSPhraseManager::getPhraseSumBrickProp(const CSPhraseCom &phrase, uint
else
sum+= brick->Properties[j].Value;
}
- else if(propId==CSBrickManager::getInstance()->StaPropId && brick->Properties[j].PropId==CSBrickManager::getInstance()->StaWeightFactorId)
+ else if(propId==CSBrickManager::getInstance()->ChaScore2PropId && brick->Properties[j].PropId==CSBrickManager::getInstance()->ChaScore2WeightFactorId)
{
CInterfaceManager *im = CInterfaceManager::getInstance();
if (!_ServerUserDefaultWeightHandsLeaf) _ServerUserDefaultWeightHandsLeaf = NLGUI::CDBManager::getInstance()->getDbProp("SERVER:USER:DEFAULT_WEIGHT_HANDS");
@@ -4591,7 +4591,7 @@ int CSPhraseComAdpater::luaGetCastRange(CLuaState &ls)
}
// ***************************************************************************
-int CSPhraseComAdpater::luaGetHpCost(CLuaState &ls)
+int CSPhraseComAdpater::luaGetChaScore1Cost(CLuaState &ls)
{
if (Phrase.Bricks.empty())
{
@@ -4599,15 +4599,15 @@ int CSPhraseComAdpater::luaGetHpCost(CLuaState &ls)
return 1;
}
CSPhraseManager *pPM = CSPhraseManager::getInstance();
- sint hpCost;
- sint hpCostMalus;
- pPM->getPhraseHpCost(this->Phrase, pPM->getTotalActionMalus(Phrase), hpCost, hpCostMalus);
- ls.push(hpCost + hpCostMalus);
+ sint ChaScore1Cost;
+ sint ChaScore1CostMalus;
+ pPM->getPhraseChaScore1Cost(this->Phrase, pPM->getTotalActionMalus(Phrase), ChaScore1Cost, ChaScore1CostMalus);
+ ls.push(ChaScore1Cost + ChaScore1CostMalus);
return 1;
}
// ***************************************************************************
-int CSPhraseComAdpater::luaGetSapCost(CLuaState &ls)
+int CSPhraseComAdpater::luaGetChaScore3Cost(CLuaState &ls)
{
if (Phrase.Bricks.empty())
{
@@ -4615,10 +4615,10 @@ int CSPhraseComAdpater::luaGetSapCost(CLuaState &ls)
return 1;
}
CSPhraseManager *pPM = CSPhraseManager::getInstance();
- sint sapCost;
- sint sapCostMalus;
- pPM->getPhraseSapCost(this->Phrase, pPM->getTotalActionMalus(Phrase), sapCost, sapCostMalus);
- ls.push(sapCost + sapCostMalus);
+ sint ChaScore3Cost;
+ sint ChaScore3CostMalus;
+ pPM->getPhraseChaScore3Cost(this->Phrase, pPM->getTotalActionMalus(Phrase), ChaScore3Cost, ChaScore3CostMalus);
+ ls.push(ChaScore3Cost + ChaScore3CostMalus);
return 1;
}
@@ -4637,7 +4637,7 @@ int CSPhraseComAdpater::luaGetSuccessRate(CLuaState &ls)
// ***************************************************************************
-int CSPhraseComAdpater::luaGetFocusCost(CLuaState &ls)
+int CSPhraseComAdpater::luaGetChaScore4Cost(CLuaState &ls)
{
if (Phrase.Bricks.empty())
{
@@ -4645,15 +4645,15 @@ int CSPhraseComAdpater::luaGetFocusCost(CLuaState &ls)
return 1;
}
CSPhraseManager *pPM = CSPhraseManager::getInstance();
- sint focusCost;
- sint focusCostMalus;
- pPM->getPhraseFocusCost(this->Phrase, pPM->getTotalActionMalus(Phrase), focusCost, focusCostMalus);
- ls.push(focusCost + focusCostMalus);
+ sint ChaScore4Cost;
+ sint ChaScore4CostMalus;
+ pPM->getPhraseChaScore4Cost(this->Phrase, pPM->getTotalActionMalus(Phrase), ChaScore4Cost, ChaScore4CostMalus);
+ ls.push(ChaScore4Cost + ChaScore4CostMalus);
return 1;
}
// ***************************************************************************
-int CSPhraseComAdpater::luaGetStaCost(CLuaState &ls)
+int CSPhraseComAdpater::luaGetChaScore2Cost(CLuaState &ls)
{
if (Phrase.Bricks.empty())
{
@@ -4661,10 +4661,10 @@ int CSPhraseComAdpater::luaGetStaCost(CLuaState &ls)
return 1;
}
CSPhraseManager *pPM = CSPhraseManager::getInstance();
- sint staCost;
- sint staCostMalus;
- pPM->getPhraseStaCost(this->Phrase, pPM->getTotalActionMalus(Phrase), staCost, staCostMalus);
- ls.push(staCost + staCostMalus);
+ sint ChaScore2Cost;
+ sint ChaScore2CostMalus;
+ pPM->getPhraseChaScore2Cost(this->Phrase, pPM->getTotalActionMalus(Phrase), ChaScore2Cost, ChaScore2CostMalus);
+ ls.push(ChaScore2Cost + ChaScore2CostMalus);
return 1;
}
diff --git a/code/ryzom/client/src/interface_v3/sphrase_manager.h b/code/ryzom/client/src/interface_v3/sphrase_manager.h
index d4c1b2092..ba48b8399 100644
--- a/code/ryzom/client/src/interface_v3/sphrase_manager.h
+++ b/code/ryzom/client/src/interface_v3/sphrase_manager.h
@@ -70,10 +70,10 @@ public:
REFLECT_EXPORT_START(CSPhraseComAdpater, CInterfaceElement)
REFLECT_LUA_METHOD("getCastTime", luaGetCastTime)
REFLECT_LUA_METHOD("getCastRange", luaGetCastRange)
- REFLECT_LUA_METHOD("getHpCost", luaGetHpCost)
- REFLECT_LUA_METHOD("getSapCost", luaGetSapCost)
- REFLECT_LUA_METHOD("getFocusCost", luaGetFocusCost)
- REFLECT_LUA_METHOD("getStaCost", luaGetStaCost)
+ REFLECT_LUA_METHOD("getChaScore1Cost", luaGetChaScore1Cost)
+ REFLECT_LUA_METHOD("getChaScore3Cost", luaGetChaScore3Cost)
+ REFLECT_LUA_METHOD("getChaScore4Cost", luaGetChaScore4Cost)
+ REFLECT_LUA_METHOD("getChaScore2Cost", luaGetChaScore2Cost)
REFLECT_LUA_METHOD("getName", luaGetName)
REFLECT_LUA_METHOD("getDesc", luaGetDesc)
REFLECT_LUA_METHOD("getSuccessRate", luaGetSuccessRate)
@@ -86,11 +86,11 @@ public:
REFLECT_EXPORT_END
int luaGetCastTime(CLuaState &ls);
int luaGetCastRange(CLuaState &ls);
- int luaGetHpCost(CLuaState &ls);
- int luaGetSapCost(CLuaState &ls);
+ int luaGetChaScore1Cost(CLuaState &ls);
+ int luaGetChaScore3Cost(CLuaState &ls);
int luaGetSuccessRate(CLuaState &ls);
- int luaGetFocusCost(CLuaState &ls);
- int luaGetStaCost(CLuaState &ls);
+ int luaGetChaScore4Cost(CLuaState &ls);
+ int luaGetChaScore2Cost(CLuaState &ls);
int luaGetName(CLuaState &ls);
int luaGetDesc(CLuaState &ls);
int luaIsMagicPhrase(CLuaState &ls);
@@ -343,14 +343,14 @@ public:
sint getForageExtractionPhraseSuccessRate(const CSPhraseCom &phrase, SKILLS::ESkills skill);
// return the fmt according to forage terrain specializing
ucstring getForageExtractionPhraseEcotypeFmt(const CSPhraseCom &phrase);
- // Get the Phrase Sap Cost
- void getPhraseSapCost(const CSPhraseCom &phrase, uint32 totalActionMalus, sint &cost, sint &costMalus);
- // Get the Phrase Sta Cost
- void getPhraseStaCost(const CSPhraseCom &phrase, uint32 totalActionMalus, sint &cost, sint &costMalus);
- // Get the Phrase Focus Cost
- void getPhraseFocusCost(const CSPhraseCom &phrase, uint32 totalActionMalus, sint &cost, sint &costMalus);
- // Get the Phrase Hp Cost
- void getPhraseHpCost(const CSPhraseCom &phrase, uint32 totalActionMalus, sint &cost, sint &costMalus);
+ // Get the Phrase ChaScore3 Cost
+ void getPhraseChaScore3Cost(const CSPhraseCom &phrase, uint32 totalActionMalus, sint &cost, sint &costMalus);
+ // Get the Phrase ChaScore2 Cost
+ void getPhraseChaScore2Cost(const CSPhraseCom &phrase, uint32 totalActionMalus, sint &cost, sint &costMalus);
+ // Get the Phrase ChaScore4 Cost
+ void getPhraseChaScore4Cost(const CSPhraseCom &phrase, uint32 totalActionMalus, sint &cost, sint &costMalus);
+ // Get the Phrase ChaScore1 Cost
+ void getPhraseChaScore1Cost(const CSPhraseCom &phrase, uint32 totalActionMalus, sint &cost, sint &costMalus);
// Get the Phrase Cast Time
void getPhraseCastTime(const CSPhraseCom &phrase, uint32 totalActionMalus, float &castTime, float &castTimeMalus);
// Get the Phrase Range
diff --git a/code/ryzom/client/src/net_manager.cpp b/code/ryzom/client/src/net_manager.cpp
index ead456a81..cf047551d 100644
--- a/code/ryzom/client/src/net_manager.cpp
+++ b/code/ryzom/client/src/net_manager.cpp
@@ -3168,18 +3168,18 @@ void impulseItemCloseRoomInventory(NLMISC::CBitMemStream &impulse)
void impulseUserBars(NLMISC::CBitMemStream &impulse)
{
uint8 msgNumber;
- sint32 hp, sap, sta, focus;
+ sint32 ChaScore1, ChaScore3, ChaScore2, ChaScore4;
impulse.serial(msgNumber);
- impulse.serial(hp);
- impulse.serial(sap);
- impulse.serial(sta);
- impulse.serial(focus);
+ impulse.serial(ChaScore1);
+ impulse.serial(ChaScore3);
+ impulse.serial(ChaScore2);
+ impulse.serial(ChaScore4);
if (PermanentlyBanned) return;
// Setup the user Bars
CBarManager::CBarInfo bi;
- CBarManager::getInstance()->setupUserBarInfo(msgNumber, hp, sap, sta, focus);
+ CBarManager::getInstance()->setupUserBarInfo(msgNumber, ChaScore1, ChaScore3, ChaScore2, ChaScore4);
}
//-----------------------------------------------
@@ -3437,19 +3437,19 @@ void impulseUserPopup(NLMISC::CBitMemStream &impulse)
//-----------------------------------------------
//-----------------------------------------------
-//extern void impulseCombatFlyingHpDelta(NLMISC::CBitMemStream &impulse);
-void impulseCombatFlyingHpDelta(NLMISC::CBitMemStream &impulse)
+//extern void impulseCombatFlyingChaScore1Delta(NLMISC::CBitMemStream &impulse);
+void impulseCombatFlyingChaScore1Delta(NLMISC::CBitMemStream &impulse)
{
uint32 entityID;
uint32 rgba;
- sint16 hpDelta;
+ sint16 ChaScore1Delta;
impulse.serial(entityID);
impulse.serial(rgba);
- impulse.serial(hpDelta);
+ impulse.serial(ChaScore1Delta);
CRGBA color((uint8)(rgba>>24&255), (uint8)(rgba>>16&255), (uint8)(rgba>>8&255), (uint8)(rgba&255));
CEntityCL *entity = EntitiesMngr.getEntityByCompressedIndex(entityID);
if (entity)
- entity->addHPOutput(ucstring(toString("%d", hpDelta)), color);
+ entity->addChaScore1Output(ucstring(toString("%d", ChaScore1Delta)), color);
}
void impulseCombatFlyingTextItemSpecialEffectProc(NLMISC::CBitMemStream &impulse)
@@ -3467,7 +3467,7 @@ void impulseCombatFlyingTextItemSpecialEffectProc(NLMISC::CBitMemStream &impulse
strFindReplace(text, "%param", toString("%d", param));
CEntityCL *entity = EntitiesMngr.getEntityByCompressedIndex(entityID);
if (entity)
- entity->addHPOutput(text, color);
+ entity->addChaScore1Output(text, color);
}
void impulseCombatFlyingText(NLMISC::CBitMemStream &impulse)
@@ -3532,7 +3532,7 @@ void impulseCombatFlyingText(NLMISC::CBitMemStream &impulse)
CEntityCL *entity = EntitiesMngr.getEntityByCompressedIndex(entityID);
if (entity)
- entity->addHPOutput(text, color, dt);
+ entity->addChaScore1Output(text, color, dt);
}
void impulseSetSeason(NLMISC::CBitMemStream &impulse)
@@ -3716,7 +3716,7 @@ void initializeNetwork()
GenericMsgHeaderMngr.setCallback( "OUTPOST:CHOOSE_SIDE", impulseOutpostChooseSide );
GenericMsgHeaderMngr.setCallback( "OUTPOST:DECLARE_WAR_ACK", impulseOutpostDeclareWarAck );
- GenericMsgHeaderMngr.setCallback( "COMBAT:FLYING_HP_DELTA", impulseCombatFlyingHpDelta );
+ GenericMsgHeaderMngr.setCallback( "COMBAT:FLYING_ChaScore1_DELTA", impulseCombatFlyingChaScore1Delta );
GenericMsgHeaderMngr.setCallback( "COMBAT:FLYING_TEXT_ISE", impulseCombatFlyingTextItemSpecialEffectProc );
GenericMsgHeaderMngr.setCallback( "COMBAT:FLYING_TEXT", impulseCombatFlyingText );
diff --git a/code/ryzom/client/src/r2/dmc/client_edition_module.h b/code/ryzom/client/src/r2/dmc/client_edition_module.h
index 54afda5cb..0cffdaa7a 100644
--- a/code/ryzom/client/src/r2/dmc/client_edition_module.h
+++ b/code/ryzom/client/src/r2/dmc/client_edition_module.h
@@ -264,7 +264,7 @@ Tbe bitfield returned let us know if the selected target is a botobject, if it i
- r2:updateAnimBarActions: called by CDynamicMapClient::onNpcAnimationTargeted, update the anim bar that contains action that can be done on the selecte npc
The DM can push button on the anim bar to do some DM functions like kill an npc, kill a group, despawn, heal, control, speak as
-- dssTarget with a parameter DESPAWN_NPC, ADD_HP, KILL_NPC, ADD_HP, GRP_KILL, GRP_HEAL, CONTROL, STOP_CONTROL, TALK_AS, STOP_TALK let the dm do dm functions.
+- dssTarget with a parameter DESPAWN_NPC, ADD_ChaScore1, KILL_NPC, ADD_ChaScore1, GRP_KILL, GRP_HEAL, CONTROL, STOP_CONTROL, TALK_AS, STOP_TALK let the dm do dm functions.
CONTROL / STOP_CONTROL
The DM can incarnate a npc: in this case he is tp at the npc position, he takes the speed of the npc.
@@ -294,10 +294,10 @@ Each Sentence that the npc would say is written in this dynamic channel.
- CServerAnimationModule handle the management of list (CServerAnimationModule::setTalkingAsPlayer)
- Ais handle the notification of the death of bot (useful for updating the list of controlled bot) (see CAisWrapper::askBotDespawnNotification)
-ADD_HP / KILL_NPC / ADD_HP / GRP_KILL / GRP_HEAL
-It is possible for the Dm to add/remove hp to a group/npc.
-- dssTarget with ADD_HP ok KILL_NPC or GRP_KILL or GRP_HEAL as parameter: heal/kill a npc/group
-Note: CServerAnimationModule will call CAiWrapper::setGrpHPLevel, CAiWrapper::setHPLevel that will call Ais native function (nf_npc_grp.cpp)
+ADD_ChaScore1 / KILL_NPC / ADD_ChaScore1 / GRP_KILL / GRP_HEAL
+It is possible for the Dm to add/remove ChaScore1 to a group/npc.
+- dssTarget with ADD_ChaScore1 ok KILL_NPC or GRP_KILL or GRP_HEAL as parameter: heal/kill a npc/group
+Note: CServerAnimationModule will call CAiWrapper::setGrpChaScore1Level, CAiWrapper::setChaScore1Level that will call Ais native function (nf_npc_grp.cpp)
Theses native functions set the life of a npc.
Its simple to add other AIS native function the same way.
@@ -741,9 +741,9 @@ public:
/*! Updates the DM admin bar. Send DM commands.
Called withou param this function update the DM action bar.
- Called with as parameter DESPAWN_NPC, ADD_HP, KILL_NPC, ADD_HP, GRP_KILL, GRP_HEAL, CONTROL, STOP_CONTROL, TALK_AS, STOP_TALK it launch DM function
+ Called with as parameter DESPAWN_NPC, ADD_ChaScore1, KILL_NPC, ADD_ChaScore1, GRP_KILL, GRP_HEAL, CONTROL, STOP_CONTROL, TALK_AS, STOP_TALK it launch DM function
\see CClientEditionModule for more info
- \parm args a list of optional argument may be empty or one of "DESPAWN_NPC" "ADD_HP" "KILL_NPC" "ADD_HP" "GRP_KILL" "GRP_HEAL" "CONTROL" "STOP_CONTROL" "TALK_AS" "STOP_TALK". Multi param could be useful for setting the aggro distance (NIY).
+ \parm args a list of optional argument may be empty or one of "DESPAWN_NPC" "ADD_ChaScore1" "KILL_NPC" "ADD_ChaScore1" "GRP_KILL" "GRP_HEAL" "CONTROL" "STOP_CONTROL" "TALK_AS" "STOP_TALK". Multi param could be useful for setting the aggro distance (NIY).
*/
void dssTarget( std::vector& args);
diff --git a/code/ryzom/client/src/r2/dmc/dmc.cpp b/code/ryzom/client/src/r2/dmc/dmc.cpp
index 0659f0a56..35a2ad54a 100644
--- a/code/ryzom/client/src/r2/dmc/dmc.cpp
+++ b/code/ryzom/client/src/r2/dmc/dmc.cpp
@@ -814,7 +814,7 @@ void CDynamicMapClient::onNpcAnimationTargeted(uint32 mode)
{
lua.push("r2ed_anim_kill");
if (mode & CAnimationProp::Grouped) { lua.push("r2ed_anim_grp_kill"); }
- lua.push("r2ed_anim_add_hp");
+ lua.push("r2ed_anim_add_ChaScore1");
if (mode & CAnimationProp::Grouped) { lua.push("r2ed_anim_grp_heal"); }
}
diff --git a/code/ryzom/client/src/user_entity.cpp b/code/ryzom/client/src/user_entity.cpp
index 1d0c27570..5ee47afff 100644
--- a/code/ryzom/client/src/user_entity.cpp
+++ b/code/ryzom/client/src/user_entity.cpp
@@ -2187,8 +2187,8 @@ void CUserEntity::applyBehaviour(const CBehaviourContext &behaviourContext) // v
{
startItemAttackFXs(_CurrentBehaviour.Combat.ImpactIntensity != 0 && _CurrentBehaviour.Combat.HitType != HITTYPE::Failed, _CurrentBehaviour.Combat.ImpactIntensity);
}
- // DeltaHP
- applyBehaviourFlyingHPs(behaviourContext, behaviour, targetHitDates);
+ // DeltaChaScore1
+ applyBehaviourFlyingChaScore1s(behaviourContext, behaviour, targetHitDates);
}
// In third person view (or camera mode), play the same way than for the others.
else
diff --git a/code/ryzom/common/data_common/chat/chat_static.occ b/code/ryzom/common/data_common/chat/chat_static.occ
index 9f3235086..8c3558301 100644
--- a/code/ryzom/common/data_common/chat/chat_static.occ
+++ b/code/ryzom/common/data_common/chat/chat_static.occ
@@ -74,7 +74,7 @@ BS_INVALID 1
BS_INVALID_TARGET 4
BS_ITEM_INCOMPATIBLE 1
BS_ITEM_INCOMPATIBLE_FOR_2_HANDS 1
-BS_LACK_STAMINA 1
+BS_LACK_ChaScore2 1
BS_MAGIC_SHIELD_DEAD 1
BS_MAGIC_SHIELD_I 1
BS_MISSES_EE 1
@@ -113,7 +113,7 @@ BS_SENTENCE_MAGIC_FAILED_S 1
BS_SUFFER_BENEFICIAL_SPELL_E 1
BS_SUFFER_NEUTRAL_SPELL_E 1
BS_SUFFER_OFFENSIVE_SPELL_E 1
-BS_SUFFER_PENALTY_NO_STAMINA 1
+BS_SUFFER_PENALTY_NO_ChaScore2 1
BS_TARGET_HIGHER_LEVEL 1
BS_TARGET_NOT_ATTACKABLE 1
BS_TARGET_PROTECTED 1
@@ -205,54 +205,54 @@ EGS_CANNOT_USE_ACTION_ON_MEKTOUB 1
EGS_CANNOT_USE_NULL_SKILL_S 1
EGS_CANT_BUY_ANOTHER_PACKER 1
EGS_CANT_SELL_ANYTHING 1
-EGS_CH_HIGH_REGEN_LIFE_E 1
-EGS_CH_HIGH_REGEN_SAP_E 1
-EGS_CH_HIGH_REGEN_STAMINA_E 1
-EGS_CH_HIGH_U_REGEN_LIFE_E 1
-EGS_CH_HIGH_U_REGEN_SAP_E 1
-EGS_CH_HIGH_U_REGEN_STAMINA_E 1
-EGS_CH_MAJOR_STEAL_HP_E 1
-EGS_CH_MAJOR_STEAL_HP_END 1
-EGS_CH_MAJOR_STEAL_SAP_E 1
-EGS_CH_MAJOR_STEAL_SAP_END 1
-EGS_CH_MAJOR_STEAL_STAMINA_E 1
-EGS_CH_MAJOR_STEAL_STAMINA_END 1
-EGS_CH_MAJOR_U_STEAL_HP_E 1
-EGS_CH_MAJOR_U_STEAL_SAP_E 1
-EGS_CH_MAJOR_U_STEAL_STAMINA_E 1
-EGS_CH_MINOR_ALCHEMY_HP_EI 1
-EGS_CH_MINOR_ALCHEMY_SAP_EI 1
-EGS_CH_MINOR_ALCHEMY_STA_EI 33
-EGS_CH_MINOR_LIFE_HEAL_EI 1
-EGS_CH_MINOR_LIFE_HEAL_SELF_I 1
-EGS_CH_MINOR_REGEN_LIFE_E 1
-EGS_CH_MINOR_REGEN_SAP_E 1
-EGS_CH_MINOR_REGEN_STAMINA_E 1
-EGS_CH_MINOR_SAP_HEAL_EI 1
-EGS_CH_MINOR_SAP_HEAL_SELF_I 1
-EGS_CH_MINOR_STAMINA_HEAL_EI 1
-EGS_CH_MINOR_STAMINA_HEAL_SELF_I 1
-EGS_CH_MINOR_STEAL_HP_EI 1
-EGS_CH_MINOR_STEAL_SAP_EI 1
-EGS_CH_MINOR_STEAL_STAMINA_EI 1
-EGS_CH_MINOR_U_ALCHEMY_HP_EI 1
-EGS_CH_MINOR_U_ALCHEMY_SAP_EI 1
-EGS_CH_MINOR_U_ALCHEMY_STA_EI 33
-EGS_CH_MINOR_U_LIFE_HEAL_EI 1
-EGS_CH_MINOR_U_REGEN_LIFE_E 1
-EGS_CH_MINOR_U_REGEN_SAP_E 1
-EGS_CH_MINOR_U_REGEN_STAMINA_E 1
-EGS_CH_MINOR_U_SAP_HEAL_EI 1
-EGS_CH_MINOR_U_STAMINA_HEAL_EI 1
-EGS_CH_MINOR_U_STEAL_HP_EI 1
-EGS_CH_MINOR_U_STEAL_SAP_EI 1
-EGS_CH_MINOR_U_STEAL_STAMINA_EI 1
-EGS_CH_SPECTATORS_MINOR_LIFE_HEAL_EEI 1
-EGS_CH_SPECTATORS_MINOR_LIFE_HEAL_SELF_EI 1
-EGS_CH_SPECTATORS_MINOR_SAP_HEAL_EEI 1
-EGS_CH_SPECTATORS_MINOR_SAP_HEAL_SELF_EI 1
-EGS_CH_SPECTATORS_MINOR_STAMINA_HEAL_EEI 1
-EGS_CH_SPECTATORS_MINOR_STAMINA_HEAL_SELF_EI 1
+EGS_CH_HIGH_REGEN_ChaScore1_E 1
+EGS_CH_HIGH_REGEN_ChaScore3_E 1
+EGS_CH_HIGH_REGEN_ChaScore2_E 1
+EGS_CH_HIGH_U_REGEN_ChaScore1_E 1
+EGS_CH_HIGH_U_REGEN_ChaScore3_E 1
+EGS_CH_HIGH_U_REGEN_ChaScore2_E 1
+EGS_CH_MAJOR_STEAL_ChaScore1_E 1
+EGS_CH_MAJOR_STEAL_ChaScore1_END 1
+EGS_CH_MAJOR_STEAL_ChaScore3_E 1
+EGS_CH_MAJOR_STEAL_ChaScore3_END 1
+EGS_CH_MAJOR_STEAL_ChaScore2_E 1
+EGS_CH_MAJOR_STEAL_ChaScore2_END 1
+EGS_CH_MAJOR_U_STEAL_ChaScore1_E 1
+EGS_CH_MAJOR_U_STEAL_ChaScore3_E 1
+EGS_CH_MAJOR_U_STEAL_ChaScore2_E 1
+EGS_CH_MINOR_ALCHEMY_ChaScore1_EI 1
+EGS_CH_MINOR_ALCHEMY_ChaScore3_EI 1
+EGS_CH_MINOR_ALCHEMY_ChaScore2_EI 33
+EGS_CH_MINOR_ChaScore1_HEAL_EI 1
+EGS_CH_MINOR_ChaScore1_HEAL_SELF_I 1
+EGS_CH_MINOR_REGEN_ChaScore1_E 1
+EGS_CH_MINOR_REGEN_ChaScore3_E 1
+EGS_CH_MINOR_REGEN_ChaScore2_E 1
+EGS_CH_MINOR_ChaScore3_HEAL_EI 1
+EGS_CH_MINOR_ChaScore3_HEAL_SELF_I 1
+EGS_CH_MINOR_ChaScore2_HEAL_EI 1
+EGS_CH_MINOR_ChaScore2_HEAL_SELF_I 1
+EGS_CH_MINOR_STEAL_ChaScore1_EI 1
+EGS_CH_MINOR_STEAL_ChaScore3_EI 1
+EGS_CH_MINOR_STEAL_ChaScore2_EI 1
+EGS_CH_MINOR_U_ALCHEMY_ChaScore1_EI 1
+EGS_CH_MINOR_U_ALCHEMY_ChaScore3_EI 1
+EGS_CH_MINOR_U_ALCHEMY_ChaScore2_EI 33
+EGS_CH_MINOR_U_ChaScore1_HEAL_EI 1
+EGS_CH_MINOR_U_REGEN_ChaScore1_E 1
+EGS_CH_MINOR_U_REGEN_ChaScore3_E 1
+EGS_CH_MINOR_U_REGEN_ChaScore2_E 1
+EGS_CH_MINOR_U_ChaScore3_HEAL_EI 1
+EGS_CH_MINOR_U_Chascore2_HEAL_EI 1
+EGS_CH_MINOR_U_STEAL_ChaScore1_EI 1
+EGS_CH_MINOR_U_STEAL_ChaScore3_EI 1
+EGS_CH_MINOR_U_STEAL_ChaScore2_EI 1
+EGS_CH_SPECTATORS_MINOR_ChaScore1_HEAL_EEI 1
+EGS_CH_SPECTATORS_MINOR_ChaScore1_HEAL_SELF_EI 1
+EGS_CH_SPECTATORS_MINOR_ChaScore3_HEAL_EEI 1
+EGS_CH_SPECTATORS_MINOR_ChaScore3_HEAL_SELF_EI 1
+EGS_CH_SPECTATORS_MINOR_ChaScore2_HEAL_EEI 1
+EGS_CH_SPECTATORS_MINOR_ChaScore2_HEAL_SELF_EI 1
EGS_COMBAT_CMS_DOWN 1
EGS_COMBAT_HITS_YOU_EIS 1
EGS_COMBAT_HITS_YOU_NULL_ES 1
@@ -283,7 +283,7 @@ EGS_EFFECT_FURIOUS_BOOST_END_E 1
EGS_EFFECT_LEAVES_FRENZY_E 1
EGS_EFFECT_LIGHTNING_PARRY_E 1
EGS_EFFECT_LIGHTNING_PARRY_END_E 1
-EGS_EFFECT_LOSE_HP_BLEED 1
+EGS_EFFECT_LOSE_ChaScore1_BLEED 1
EGS_EFFECT_MAJOR_FURIOUS_BOOST_E 1
EGS_EFFECT_MAJOR_FURIOUS_BOOST_END_E 1
EGS_EFFECT_MAJOR_RAPID_BURST_E 1
@@ -304,7 +304,7 @@ EGS_EFFECT_U_FEAR_END 1
EGS_EFFECT_U_FEAR_FRENZY_E 1
EGS_EFFECT_U_FEAR_FRENZY_END 1
EGS_EFFECT_U_LEAVE_FRENZY 1
-EGS_EFFECT_U_LOSE_HP_BLEED 1
+EGS_EFFECT_U_LOSE_ChaScore1_BLEED 1
EGS_EFFECT_U_RESIST_BLEED_E 1
EGS_EFFECT_U_RESIST_FEAR_E 1
EGS_EFFECT_U_RESIST_FEAR_FRENZY_E 1
@@ -390,44 +390,44 @@ EGS_LOOT_BS_I 1
EGS_LOOT_LS_I 1
EGS_LOOT_MS_I 1
EGS_LOOT_VBS_I 1
-EGS_LOSE_SAP_EI 1
-EGS_LOSE_STA_EI 1
+EGS_LOSE_ChaScore3_EI 1
+EGS_LOSE_ChaScore2_EI 1
EGS_MAGIC_BAD_TARGET 1
EGS_MAGIC_CASTER_NEW_LINK_E 1
EGS_MAGIC_CASTER_REMOVE_LINK_E 1
-EGS_MAGIC_CAST_OFFENSIVE_SPELL_HP_EEI 1
-EGS_MAGIC_CAST_OFFENSIVE_SPELL_SAP_EEI 1
-EGS_MAGIC_CAST_OFFENSIVE_SPELL_STA_EEI 1
-EGS_MAGIC_HEAL_SPELL_HP_EEI 1
-EGS_MAGIC_HEAL_SPELL_SAP_EEI 1
-EGS_MAGIC_HEAL_SPELL_STA_EEI 1
-EGS_MAGIC_SELFCAST_OFFENSIVE_SPELL_HP_EI 1
-EGS_MAGIC_SELFCAST_OFFENSIVE_SPELL_SAP_EI 1
-EGS_MAGIC_SELFCAST_OFFENSIVE_SPELL_STA_EI 1
-EGS_MAGIC_SELF_HEAL_HP_EI 1
-EGS_MAGIC_SELF_HEAL_SAP_EI 1
-EGS_MAGIC_SELF_HEAL_STA_EI 1
+EGS_MAGIC_CAST_OFFENSIVE_SPELL_ChaScore1_EEI 1
+EGS_MAGIC_CAST_OFFENSIVE_SPELL_ChaScore3_EEI 1
+EGS_MAGIC_CAST_OFFENSIVE_SPELL_ChaScore2_EEI 1
+EGS_MAGIC_HEAL_SPELL_ChaScore1_EEI 1
+EGS_MAGIC_HEAL_SPELL_ChasCore3_EEI 1
+EGS_MAGIC_HEAL_SPELL_ChaScore2_EEI 1
+EGS_MAGIC_SELFCAST_OFFENSIVE_SPELL_ChaScore1_EI 1
+EGS_MAGIC_SELFCAST_OFFENSIVE_SPELL_ChaScore3_EI 1
+EGS_MAGIC_SELFCAST_OFFENSIVE_SPELL_ChaScore2_EI 1
+EGS_MAGIC_SELF_HEAL_ChaScore1_EI 1
+EGS_MAGIC_SELF_HEAL_ChaScore3_EI 1
+EGS_MAGIC_SELF_HEAL_ChaScore2_EI 1
EGS_MAGIC_TARGET_NEW_LINK_E 1
EGS_MAGIC_TARGET_OUT_OF_RANGE 1
EGS_MAGIC_TARGET_REMOVE_LINK_E 1
-EGS_MAGIC_U_CAST_HEAL_SPELL_HP_EI 1
-EGS_MAGIC_U_CAST_HEAL_SPELL_SAP_EI 1
-EGS_MAGIC_U_CAST_HEAL_SPELL_STA_EI 1
-EGS_MAGIC_U_CAST_OFFENSIVE_SPELL_HP_EI 1
-EGS_MAGIC_U_CAST_OFFENSIVE_SPELL_SAP_EI 1
-EGS_MAGIC_U_CAST_OFFENSIVE_SPELL_STA_EI 1
-EGS_MAGIC_U_SELFCAST_OFFENSIVE_SPELL_HP_I 1
-EGS_MAGIC_U_SELFCAST_OFFENSIVE_SPELL_SAP_I 1
-EGS_MAGIC_U_SELFCAST_OFFENSIVE_SPELL_STA_I 1
-EGS_MAGIC_U_SELF_HEAL_HP_I 1
-EGS_MAGIC_U_SELF_HEAL_SAP_I 1
-EGS_MAGIC_U_SELF_HEAL_STA_I 1
-EGS_MAGIC_U_SUFFER_HEAL_SPELL_HP_EI 1
-EGS_MAGIC_U_SUFFER_HEAL_SPELL_SAP_EI 1
-EGS_MAGIC_U_SUFFER_HEAL_SPELL_STA_EI 1
-EGS_MAGIC_U_SUFFER_OFFENSIVE_SPELL_HP_EI 1
-EGS_MAGIC_U_SUFFER_OFFENSIVE_SPELL_SAP_EI 1
-EGS_MAGIC_U_SUFFER_OFFENSIVE_SPELL_STA_EI 1
+EGS_MAGIC_U_CAST_HEAL_SPELL_ChaScore1_EI 1
+EGS_MAGIC_U_CAST_HEAL_SPELL_ChaScore3_EI 1
+EGS_MAGIC_U_CAST_HEAL_SPELL_ChaScore2_EI 1
+EGS_MAGIC_U_CAST_OFFENSIVE_SPELL_ChaScore1_EI 1
+EGS_MAGIC_U_CAST_OFFENSIVE_SPELL_ChaScore3_EI 1
+EGS_MAGIC_U_CAST_OFFENSIVE_SPELL_ChaScore2_EI 1
+EGS_MAGIC_U_SELFCAST_OFFENSIVE_SPELL_ChaScore1_I 1
+EGS_MAGIC_U_SELFCAST_OFFENSIVE_SPELL_ChaScore3_I 1
+EGS_MAGIC_U_SELFCAST_OFFENSIVE_SPELL_ChaScore2_I 1
+EGS_MAGIC_U_SELF_HEAL_ChaScore1_I 1
+EGS_MAGIC_U_SELF_HEAL_ChaScore3_I 1
+EGS_MAGIC_U_SELF_HEAL_ChaScore2_I 1
+EGS_MAGIC_U_SUFFER_HEAL_SPELL_ChaScore1_EI 1
+EGS_MAGIC_U_SUFFER_HEAL_SPELL_ChaScore3_EI 1
+EGS_MAGIC_U_SUFFER_HEAL_SPELL_ChaScore2_EI 1
+EGS_MAGIC_U_SUFFER_OFFENSIVE_SPELL_ChaScore1_EI 1
+EGS_MAGIC_U_SUFFER_OFFENSIVE_SPELL_ChaScore3_EI 1
+EGS_MAGIC_U_SUFFER_OFFENSIVE_SPELL_ChaScore2_EI 1
EGS_MELEE_BESTIAL_RAGE_E 1
EGS_MELEE_BLIND_FURY_E 1
EGS_MELEE_DEFLECT_E 1
@@ -584,9 +584,9 @@ EGS_TARGET_HIT_RFOOT_EI 1
EGS_TARGET_HIT_RLEG_EI 1
EGS_TMP_GENERIC_EFFECT_BEGIN 1
EGS_TMP_GENERIC_EFFECT_END 1
-EGS_TOO_EXPENSIVE_HP 1
-EGS_TOO_EXPENSIVE_SAP 1
-EGS_TOO_EXPENSIVE_STAMINA 1
+EGS_TOO_EXPENSIVE_ChaScore1 1
+EGS_TOO_EXPENSIVE_ChaScore3 1
+EGS_TOO_EXPENSIVE_ChaScore2 1
EGS_TRACKING_DIRECTION_ES 1
EGS_TRACKING_END_E 1
EGS_TRACKING_START_E 1
@@ -597,12 +597,12 @@ EGS_TRAINING_FAILED_S 1
EGS_TRAINING_HIGH_DIFFICULTY 1
EGS_TRAINING_INVALID_MODE 1
EGS_TRAINING_LOW_QUALITY_TOOL 1
-EGS_TRAINING_NOT_ENOUGH_SAP 1
-EGS_TRAINING_NOT_ENOUGH_STAMINA 1
+EGS_TRAINING_NOT_ENOUGH_ChaScore3 1
+EGS_TRAINING_NOT_ENOUGH_ChaScore2 1
EGS_TRAINING_SUCCESS 1
EGS_USE_LAST_AMMO 1
-EGS_U_LOSE_SAP_EI 1
-EGS_U_LOSE_STA_EI 1
+EGS_U_LOSE_ChaScore3_EI 1
+EGS_U_LOSE_ChaScore2_EI 1
EGS_YOU_CRITICAL_HIT_E 1
EGS_YOU_EFFECT_ALREADY_PRESENT 1
EGS_YOU_FUMBLE 1
@@ -685,11 +685,11 @@ OPS_XP_MISSION_GAINXP_SKILL_S 1
OPS_XP_NORMAL_GAINXP_SKILL_S 1
OPS_XP_NO_GAINXP_SKILL_S 1
OPS_XP_PROGRESS_CHARACTERISTIC_S 1
-OPS_XP_PROGRESS_HP 1
+OPS_XP_PROGRESS_ChaScore1 1
OPS_XP_PROGRESS_RESIST_S 1
-OPS_XP_PROGRESS_SAP 1
-OPS_XP_PROGRESS_SKILL_S 70
-OPS_XP_PROGRESS_STAMINA 1
+OPS_XP_PROGRESS_ChaScore3 1
+OPS_XP_PROGRESS_ChaScore2_S 70
+OPS_XP_PROGRESS_ChaScore2 1
WOS_HARVEST_ALREADY_IN_PROGRESS 1
WOS_HARVEST_ALREADY_IN_PROGRESS_E 1
WOS_HARVEST_FAILED 5
diff --git a/code/ryzom/common/data_common/database.xml b/code/ryzom/common/data_common/database.xml
index fc0d1d209..bfa0c86e0 100644
--- a/code/ryzom/common/data_common/database.xml
+++ b/code/ryzom/common/data_common/database.xml
@@ -173,13 +173,13 @@
-
-
-
-
@@ -253,11 +253,11 @@
-
-
-
@@ -1025,21 +1025,21 @@
-
-
-
-
-
-
@@ -1512,6 +1512,8 @@
type="I5" />
+
+ description="server update the players Bars (fast message) $msgNumber $cha_score1 $cha_score3 $cha_score2 $cha_score4" />
diff --git a/code/ryzom/common/src/game_share/ai_wrapper.h b/code/ryzom/common/src/game_share/ai_wrapper.h
index c0bac40a2..de6206727 100644
--- a/code/ryzom/common/src/game_share/ai_wrapper.h
+++ b/code/ryzom/common/src/game_share/ai_wrapper.h
@@ -107,11 +107,11 @@ public:
{
}
- virtual void setHPLevel(NLMISC::CEntityId entityId, uint32 alias, float value)
+ virtual void setChaScore1Level(NLMISC::CEntityId entityId, uint32 alias, float value)
{
}
- virtual void setGrpHPLevel(NLMISC::CEntityId entityId, uint32 alias, float value)
+ virtual void setGrpChaScore1Level(NLMISC::CEntityId entityId, uint32 alias, float value)
{
}
@@ -176,8 +176,8 @@ public:
virtual void setAggroRange(NLMISC::CEntityId entityId, float range);
- virtual void setHPLevel(NLMISC::CEntityId entityId, uint32 alias, float value);
- virtual void setGrpHPLevel(NLMISC::CEntityId entityId, uint32 alias, float value);
+ virtual void setChaScore1Level(NLMISC::CEntityId entityId, uint32 alias, float value);
+ virtual void setGrpChaScore1Level(NLMISC::CEntityId entityId, uint32 alias, float value);
virtual void triggerGrpEvent(NLMISC::CEntityId entityId, float eventId);
diff --git a/code/ryzom/common/src/game_share/brick_families.cpp b/code/ryzom/common/src/game_share/brick_families.cpp
index ead3e827b..7e1616005 100644
--- a/code/ryzom/common/src/game_share/brick_families.cpp
+++ b/code/ryzom/common/src/game_share/brick_families.cpp
@@ -414,9 +414,9 @@ namespace BRICK_FAMILIES
// training & characteristics
NL_STRING_CONVERSION_TABLE_ENTRY(BTFOC)
- NL_STRING_CONVERSION_TABLE_ENTRY(BTHP)
- NL_STRING_CONVERSION_TABLE_ENTRY(BTSAP)
- NL_STRING_CONVERSION_TABLE_ENTRY(BTSTA)
+ NL_STRING_CONVERSION_TABLE_ENTRY(BTTRA)
+ NL_STRING_CONVERSION_TABLE_ENTRY(BTOBL)
+ NL_STRING_CONVERSION_TABLE_ENTRY(BTPAI)
NL_STRING_CONVERSION_TABLE_ENTRY(BPPC)
NL_STRING_CONVERSION_TABLE_ENTRY(BPPM)
diff --git a/code/ryzom/common/src/game_share/brick_families.h b/code/ryzom/common/src/game_share/brick_families.h
index b916ee2bd..837299e67 100644
--- a/code/ryzom/common/src/game_share/brick_families.h
+++ b/code/ryzom/common/src/game_share/brick_families.h
@@ -574,9 +574,9 @@ namespace BRICK_FAMILIES
// ********
BeginTraining,
BTFOC = BeginTraining,
- BTHP,
- BTSAP,
- BTSTA,
+ BTTRA,
+ BTOBL,
+ BTPAI,
// special for carac buying
BeginCharacBuy,
@@ -632,26 +632,26 @@ namespace BRICK_FAMILIES
BeginFightPowerParameter = BeginPowerParameter,
BSFMA = BeginFightPowerParameter, // taunt power
BSFMB, // shielding power
- BSFMC, // stamina aura
+ BSFMC, // ChaScore2 aura
BSFMD, // protection aura
BSFME, // umbrella aura
BSFMF, // berserk
BSFMG, // war cry
- BSFMH, // heal stamina
+ BSFMH, // heal ChaScore2
BSFMI, // fire wall
BSFMJ, // thorn wall
BSFMK, // water wall
BSFML, // lightning
EndFightPowerParameter = BSFML,
- BSXMA, // life aura
+ BSXMA, // ChaScore1 aura
BSXMB, // invulnerability
- BSXMC, // heal Hp
+ BSXMC, // heal ChaScore1
BSDMA, // speed
// G for general ??
- BSGMA, // heal focus
+ BSGMA, // heal ChaScore4
BSGMB, // enchant weapon
BSGMBA,
BSGMBC,
@@ -662,17 +662,17 @@ namespace BRICK_FAMILIES
BSGMBS,
BeginMagicPowerParameter,
- BSMMA = BeginMagicPowerParameter, // sap aura
+ BSMMA = BeginMagicPowerParameter, // ChaScore3 aura
BSMMB, // anti magic shield
- BSMMC, // balance hp
- BSMMD, // heal sap
+ BSMMC, // balance ChaScore1
+ BSMMD, // heal ChaScore3
EndMagicPowerParameter = BSMMD,
// consumable powers
- BSCMA, // heal Hp
- BSCMB, // heal Sap
- BSCMC, // heal Sta
- BSCMD, // heal Focus
+ BSCMA, // heal ChaScore1
+ BSCMB, // heal ChaScore3
+ BSCMC, // heal ChaScore2
+ BSCMD, // heal ChaScore4
EndPowerParameter = BSCMD,
BeginMagicPowerCredit,
diff --git a/code/ryzom/common/src/game_share/brick_flags.cpp b/code/ryzom/common/src/game_share/brick_flags.cpp
index 062b04d88..7709fc31e 100644
--- a/code/ryzom/common/src/game_share/brick_flags.cpp
+++ b/code/ryzom/common/src/game_share/brick_flags.cpp
@@ -53,13 +53,13 @@ namespace BRICK_FLAGS
NL_STRING_CONVERSION_TABLE_ENTRY (Taunt)
NL_STRING_CONVERSION_TABLE_ENTRY (SpeedingUp)
- NL_STRING_CONVERSION_TABLE_ENTRY (LifeConcentration)
- NL_STRING_CONVERSION_TABLE_ENTRY (StaminaConcentration)
- NL_STRING_CONVERSION_TABLE_ENTRY (SapConcentration)
- NL_STRING_CONVERSION_TABLE_ENTRY (ConvertStamina)
- NL_STRING_CONVERSION_TABLE_ENTRY (ConvertSap)
+ NL_STRING_CONVERSION_TABLE_ENTRY (ChaScore1Concentration)
+ NL_STRING_CONVERSION_TABLE_ENTRY (ChaScore2Concentration)
+ NL_STRING_CONVERSION_TABLE_ENTRY (ChaScore3Concentration)
+ NL_STRING_CONVERSION_TABLE_ENTRY (ConvertChaScore2)
+ NL_STRING_CONVERSION_TABLE_ENTRY (ConvertChaScore3)
NL_STRING_CONVERSION_TABLE_ENTRY (Berserk)
- NL_STRING_CONVERSION_TABLE_ENTRY (BalanceHp)
+ NL_STRING_CONVERSION_TABLE_ENTRY (BalanceChaScore1)
NL_STRING_CONVERSION_TABLE_ENTRY (Heal)
NL_STRING_CONVERSION_TABLE_ENTRY (Shielding)
NL_STRING_CONVERSION_TABLE_ENTRY (Invulnerability)
@@ -73,10 +73,10 @@ namespace BRICK_FLAGS
NL_STRING_CONVERSION_TABLE_ENTRY (ModRangeSuccess)
NL_STRING_CONVERSION_TABLE_ENTRY (ModMagicSuccess)
NL_STRING_CONVERSION_TABLE_ENTRY (ModForageSuccess)
- NL_STRING_CONVERSION_TABLE_ENTRY (HealHpC)
- NL_STRING_CONVERSION_TABLE_ENTRY (HealSapC)
- NL_STRING_CONVERSION_TABLE_ENTRY (HealStaC)
- NL_STRING_CONVERSION_TABLE_ENTRY (HealFocusC)
+ NL_STRING_CONVERSION_TABLE_ENTRY (HealChaScore1C)
+ NL_STRING_CONVERSION_TABLE_ENTRY (HealChaScore2C)
+ NL_STRING_CONVERSION_TABLE_ENTRY (HealChaScore3C)
+ NL_STRING_CONVERSION_TABLE_ENTRY (HealChaScore4C)
NL_STRING_CONVERSION_TABLE_ENTRY (Aura)
diff --git a/code/ryzom/common/src/game_share/brick_flags.h b/code/ryzom/common/src/game_share/brick_flags.h
index 0f0677b46..5ad959fcc 100644
--- a/code/ryzom/common/src/game_share/brick_flags.h
+++ b/code/ryzom/common/src/game_share/brick_flags.h
@@ -63,13 +63,13 @@ namespace BRICK_FLAGS
Taunt = BeginPowerFlags,
Shielding,
SpeedingUp,
- LifeConcentration,
- StaminaConcentration,
- SapConcentration,
- ConvertStamina,
- ConvertSap,
+ ChaScore1Concentration,
+ ChaScore2Concentration,
+ ChaScore3Concentration,
+ ConvertChaScore2,
+ ConvertChaScore3,
Berserk,
- BalanceHp,
+ BalanceChaScore1,
Heal,
Invulnerability,
EnchantWeapon,
@@ -81,11 +81,11 @@ namespace BRICK_FLAGS
ModMagicSuccess,
ModForageSuccess,
// consumable items related powers
- HealHpC,
- HealSapC,
- HealStaC,
- HealFocusC,
- EndPowerFlags = HealFocusC,
+ HealChaScore1C,
+ HealChaScore2C,
+ HealChaScore3C,
+ HealChaScore4C,
+ EndPowerFlags = HealChaScore4C,
NbPowerFlags = EndPowerFlags - 31,
diff --git a/code/ryzom/common/src/game_share/characteristics.cpp b/code/ryzom/common/src/game_share/characteristics.cpp
index f599c9a32..bc8fb5050 100644
--- a/code/ryzom/common/src/game_share/characteristics.cpp
+++ b/code/ryzom/common/src/game_share/characteristics.cpp
@@ -31,14 +31,14 @@ namespace CHARACTERISTICS
// The conversion table
const CStringConversion::CPair stringTable [] =
{
- { "Constitution", constitution }, //HP max
- { "Metabolism", metabolism }, //Hp Regen
- { "Intelligence", intelligence }, //Sap Max
- { "Wisdom", wisdom }, //Sap regen
- { "Strength", strength }, //Stamina Max
- { "WellBalanced", well_balanced }, //Stamina regen
- { "Dexterity", dexterity }, //Focus Max
- { "Will", will }, //Focus regen
+ { "Cha1", cha1 }, //Cha1 Max
+ { "Cha1Reg", cha1_reg }, //Cha1 Regeneration
+ { "Cha3", cha3 }, //Cha3 Max
+ { "Cha3Reg", cha3_reg }, //Cha3 Regeneration
+ { "Cha2", cha2 }, //Cha2 Max
+ { "Cha2Reg", cha2_reg }, //Cha2 Regeneration
+ { "Cha4", cha4 }, //Cha4 Max
+ { "Cha4Reg", cha4_reg }, //Cha4 Regeneration
{ "Unknown", Unknown },
@@ -73,14 +73,14 @@ namespace CHARACTERISTICS
// The code conversion table
const CStringConversion::CPair codeTable [] =
{
- { "c", constitution },
- { "m", metabolism },
- { "i", intelligence },
- { "w", wisdom },
- { "s", strength },
- { "b", well_balanced },
- { "d", dexterity },
- { "l", will },
+ { "s1", cha1 },
+ { "r1", cha1_reg },
+ { "s2", cha2 },
+ { "r2", cha2_reg },
+ { "s3", cha3 },
+ { "r3", cha3_reg },
+ { "s4", cha4 },
+ { "r4", cha4_reg },
};
CStringConversion codeCharac(codeTable, sizeof(codeTable) / sizeof(codeTable[0]), Unknown );
diff --git a/code/ryzom/common/src/game_share/characteristics.h b/code/ryzom/common/src/game_share/characteristics.h
index e2714fdf2..e632da097 100644
--- a/code/ryzom/common/src/game_share/characteristics.h
+++ b/code/ryzom/common/src/game_share/characteristics.h
@@ -27,17 +27,17 @@ namespace CHARACTERISTICS
{
enum TCharacteristics
{
- constitution = 0, //HP max
- metabolism, //Hp Regen
+ cha1 = 0, //Trauma max
+ cha1_reg, //Trauma Regeneration
- intelligence, //Sap Max
- wisdom, //Sap regen
+ cha3, //Oblivion Max
+ cha3_reg, //Oblivion Regeneration
- strength, //Stamina Max
- well_balanced, //Stamina regen
+ cha2, //Pain Max
+ cha2_reg, //Pain Regeneration
- dexterity, //Focus Max
- will, //Focus regen
+ cha4, //Focus Max
+ cha4_reg, //Focus regen
NUM_CHARACTERISTICS,
Unknown = NUM_CHARACTERISTICS
@@ -46,7 +46,7 @@ namespace CHARACTERISTICS
/**
* get the right characteristic enum from the input string
* \param str the input string
- * \return the ECharacteristics associated to this string (unknown if the string cannot be interpreted)
+ * \return the TCharacteristics associated to this string (unknown if the string cannot be interpreted)
*/
TCharacteristics toCharacteristic( const std::string &str );
diff --git a/code/ryzom/common/src/game_share/effect_families.cpp b/code/ryzom/common/src/game_share/effect_families.cpp
index 8d00cf200..05fdde2e3 100644
--- a/code/ryzom/common/src/game_share/effect_families.cpp
+++ b/code/ryzom/common/src/game_share/effect_families.cpp
@@ -96,10 +96,10 @@ namespace EFFECT_FAMILIES
NL_STRING_CONVERSION_TABLE_ENTRY( CombatDebuffCombatSkills )
NL_STRING_CONVERSION_TABLE_ENTRY( CombatDebuffDodge )
- NL_STRING_CONVERSION_TABLE_ENTRY( CombatDebuffStaminaRegen )
- NL_STRING_CONVERSION_TABLE_ENTRY( CombatDebuffSapRegen )
- NL_STRING_CONVERSION_TABLE_ENTRY( CombatDebuffHitPointsRegen )
- NL_STRING_CONVERSION_TABLE_ENTRY( CombatDebuffFocusRegen )
+ NL_STRING_CONVERSION_TABLE_ENTRY( CombatDebuffChaScore2Regen )
+ NL_STRING_CONVERSION_TABLE_ENTRY( CombatDebuffChaScore3Regen )
+ NL_STRING_CONVERSION_TABLE_ENTRY( CombatDebuffChaScore1Regen )
+ NL_STRING_CONVERSION_TABLE_ENTRY( CombatDebuffChaScore4Regen )
NL_STRING_CONVERSION_TABLE_ENTRY( CombatDoTRot )
NL_STRING_CONVERSION_TABLE_ENTRY( CombatDoTCold )
@@ -110,9 +110,9 @@ namespace EFFECT_FAMILIES
NL_STRING_CONVERSION_TABLE_ENTRY( CombatDoTShock )
NL_STRING_CONVERSION_TABLE_ENTRY( PowerShielding )
- NL_STRING_CONVERSION_TABLE_ENTRY( PowerLifeAura )
- NL_STRING_CONVERSION_TABLE_ENTRY( PowerStaminaAura )
- NL_STRING_CONVERSION_TABLE_ENTRY( PowerSapAura )
+ NL_STRING_CONVERSION_TABLE_ENTRY( PowerChaScore1Aura )
+ NL_STRING_CONVERSION_TABLE_ENTRY( PowerChaScore2Aura )
+ NL_STRING_CONVERSION_TABLE_ENTRY( PowerChaScore3Aura )
NL_STRING_CONVERSION_TABLE_ENTRY( PowerUmbrella )
NL_STRING_CONVERSION_TABLE_ENTRY( PowerProtection )
NL_STRING_CONVERSION_TABLE_ENTRY( PowerAntiMagicShield )
@@ -122,9 +122,9 @@ namespace EFFECT_FAMILIES
NL_STRING_CONVERSION_TABLE_ENTRY( PowerWaterWall )
NL_STRING_CONVERSION_TABLE_ENTRY( PowerLightningWall )
- NL_STRING_CONVERSION_TABLE_ENTRY( PowerRootLifeAura )
- NL_STRING_CONVERSION_TABLE_ENTRY( PowerRootStaminaAura )
- NL_STRING_CONVERSION_TABLE_ENTRY( PowerRootSapAura )
+ NL_STRING_CONVERSION_TABLE_ENTRY( PowerRootChaScore1Aura )
+ NL_STRING_CONVERSION_TABLE_ENTRY( PowerRootChaScore2Aura )
+ NL_STRING_CONVERSION_TABLE_ENTRY( PowerRootChaScore3Aura )
NL_STRING_CONVERSION_TABLE_ENTRY( PowerRootUmbrella )
NL_STRING_CONVERSION_TABLE_ENTRY( PowerRootProtection )
NL_STRING_CONVERSION_TABLE_ENTRY( PowerRootAntiMagicShield )
@@ -162,14 +162,14 @@ namespace EFFECT_FAMILIES
NL_STRING_CONVERSION_TABLE_ENTRY( ForageLocateDeposit )
- NL_STRING_CONVERSION_TABLE_ENTRY( TotemStatsHP )
- NL_STRING_CONVERSION_TABLE_ENTRY( TotemStatsSap )
- NL_STRING_CONVERSION_TABLE_ENTRY( TotemStatsSta )
- NL_STRING_CONVERSION_TABLE_ENTRY( TotemStatsFoc )
- NL_STRING_CONVERSION_TABLE_ENTRY( TotemRegenHP )
- NL_STRING_CONVERSION_TABLE_ENTRY( TotemRegenSap )
- NL_STRING_CONVERSION_TABLE_ENTRY( TotemRegenSta )
- NL_STRING_CONVERSION_TABLE_ENTRY( TotemRegenFoc )
+ NL_STRING_CONVERSION_TABLE_ENTRY( TotemStatsChaScore1 )
+ NL_STRING_CONVERSION_TABLE_ENTRY( TotemStatsChaScore3 )
+ NL_STRING_CONVERSION_TABLE_ENTRY( TotemStatsChaScore2 )
+ NL_STRING_CONVERSION_TABLE_ENTRY( TotemStatsChaScore4 )
+ NL_STRING_CONVERSION_TABLE_ENTRY( TotemRegenChaScore1 )
+ NL_STRING_CONVERSION_TABLE_ENTRY( TotemRegenChaScore3 )
+ NL_STRING_CONVERSION_TABLE_ENTRY( TotemRegenChaScore2 )
+ NL_STRING_CONVERSION_TABLE_ENTRY( TotemRegenChaScore4 )
NL_STRING_CONVERSION_TABLE_ENTRY( TotemHarvestAgg )
NL_STRING_CONVERSION_TABLE_ENTRY( TotemHarvestQty )
NL_STRING_CONVERSION_TABLE_ENTRY( TotemHarvestZRs )
@@ -311,9 +311,9 @@ namespace EFFECT_FAMILIES
{ "debuff_combat_skills.sbrick",CombatDebuffCombatSkills },
{ "shielding.sbrick", PowerShielding },
- { "life_aura.sbrick", PowerLifeAura },
- { "stamina_aura.sbrick", PowerStaminaAura },
- { "sap_aura.sbrick", PowerSapAura },
+ { "cha_score1_aura.sbrick", PowerChaScore1Aura },
+ { "cha_score2_aura.sbrick", PowerChaScore2Aura },
+ { "cha_score3_aura.sbrick", PowerChaScore3Aura },
{ "umbrella_aura.sbrick", PowerUmbrella },
{ "melee_protection_aura.sbrick",PowerProtection },
{ "anti_magic_shield_aura.sbrick",PowerAntiMagicShield },
diff --git a/code/ryzom/common/src/game_share/effect_families.h b/code/ryzom/common/src/game_share/effect_families.h
index e05b05a34..0207fd7a2 100644
--- a/code/ryzom/common/src/game_share/effect_families.h
+++ b/code/ryzom/common/src/game_share/effect_families.h
@@ -117,10 +117,10 @@ namespace EFFECT_FAMILIES
CombatDebuffCombatSkills,
CombatDebuffDodge,
- CombatDebuffStaminaRegen,
- CombatDebuffSapRegen,
- CombatDebuffHitPointsRegen,
- CombatDebuffFocusRegen,
+ CombatDebuffChaScore2Regen,
+ CombatDebuffChaScore3Regen,
+ CombatDebuffChaScore1Regen,
+ CombatDebuffChaScore4Regen,
CombatDoTRot,
CombatDoTCold,
@@ -134,9 +134,9 @@ namespace EFFECT_FAMILIES
BeginPowerEffects,
PowerShielding = BeginPowerEffects,
- PowerLifeAura,
- PowerStaminaAura,
- PowerSapAura,
+ PowerChaScore1Aura,
+ PowerChaScore2Aura,
+ PowerChaScore3Aura,
PowerUmbrella,
PowerProtection,
PowerAntiMagicShield,
@@ -147,9 +147,9 @@ namespace EFFECT_FAMILIES
PowerWaterWall,
PowerLightningWall,
- PowerRootLifeAura,
- PowerRootStaminaAura,
- PowerRootSapAura,
+ PowerRootChaScore1Aura,
+ PowerRootChaScore2Aura,
+ PowerRootChaScore3Aura,
PowerRootUmbrella,
PowerRootProtection,
PowerRootAntiMagicShield,
@@ -192,16 +192,16 @@ namespace EFFECT_FAMILIES
BeginTotemEffects,
// stats
- TotemStatsHP = BeginTotemEffects,
- TotemStatsSap,
- TotemStatsSta,
- TotemStatsFoc,
+ TotemStatsChaScore1 = BeginTotemEffects,
+ TotemStatsChaScore2,
+ TotemStatsChaScore3,
+ TotemStatsChaScore4,
// regen
- TotemRegenHP,
- TotemRegenSap,
- TotemRegenSta,
- TotemRegenFoc,
+ TotemRegenChaScore1,
+ TotemRegenChaScore2,
+ TotemRegenChaScore3,
+ TotemRegenChaScore4,
// harvest
TotemHarvestAgg,
diff --git a/code/ryzom/common/src/game_share/item_infos.cpp b/code/ryzom/common/src/game_share/item_infos.cpp
index 02af62f45..5e249117d 100644
--- a/code/ryzom/common/src/game_share/item_infos.cpp
+++ b/code/ryzom/common/src/game_share/item_infos.cpp
@@ -41,10 +41,10 @@ CItemInfos::CItemInfos()
MaxSlashingProtection = 0;
MaxBluntProtection = 0;
MaxPiercingProtection = 0;
- HpBuff = 0;
- SapBuff = 0;
- StaBuff = 0;
- FocusBuff = 0;
+ ChaScore1Buff = 0;
+ ChaScore3Buff = 0;
+ ChaScore2Buff = 0;
+ ChaScore4Buff = 0;
WearEquipmentMalus = 0.0f;
RequiredSkill = SKILLS::unknown;
@@ -107,10 +107,10 @@ void CItemInfos::serial(NLMISC::IStream & s)
s.serial( LacustreMagicResistance );
s.serial( JungleMagicResistance );
s.serial( PrimaryRootMagicResistance );
- s.serial( HpBuff );
- s.serial( SapBuff );
- s.serial( StaBuff );
- s.serial( FocusBuff );
+ s.serial( ChaScore1Buff );
+ s.serial( ChaScore3Buff );
+ s.serial( ChaScore2Buff );
+ s.serial( ChaScore4Buff );
s.serial( Enchantment );
s.serial( WearEquipmentMalus );
diff --git a/code/ryzom/common/src/game_share/item_infos.h b/code/ryzom/common/src/game_share/item_infos.h
index 1cb32ae41..24373ac64 100644
--- a/code/ryzom/common/src/game_share/item_infos.h
+++ b/code/ryzom/common/src/game_share/item_infos.h
@@ -105,10 +105,10 @@ public:
uint32 LacustreMagicResistance;
uint32 JungleMagicResistance;
uint32 PrimaryRootMagicResistance;
- sint32 HpBuff; // hp buff / debuff gived when item is equipped
- sint32 SapBuff; // sap buff / debuff gived when item is equipped
- sint32 StaBuff; // sta buff / debuff gived when item is equipped
- sint32 FocusBuff; // focus buff / debuff gived when item is equipped
+ sint32 ChaScore1Buff; // ChaScore1 buff / debuff gived when item is equipped
+ sint32 ChaScore2Buff; // ChaScore2 buff / debuff gived when item is equipped
+ sint32 ChaScore3Buff; // ChaScore3 buff / debuff gived when item is equipped
+ sint32 ChaScore4Buff; // ChaScore4 buff / debuff gived when item is equipped
SKILLS::ESkills RequiredSkill; // required skill
uint16 RequiredSkillLevel; // required skill level
diff --git a/code/ryzom/common/src/game_share/magic_fx.cpp b/code/ryzom/common/src/game_share/magic_fx.cpp
index b9371fdb4..cb6733159 100644
--- a/code/ryzom/common/src/game_share/magic_fx.cpp
+++ b/code/ryzom/common/src/game_share/magic_fx.cpp
@@ -153,36 +153,36 @@ namespace MAGICFX
}
// *************************************************************************************
- TMagicFx healtoMagicFx( sint32 healHp, sint32 healSap, sint32 healSta, bool link )
+ TMagicFx healtoMagicFx( sint32 healChaScore1, sint32 healChaScore3, sint32 healChaScore2, bool link )
{
if ( !link )
{
- if ( healHp > healSap )
+ if ( healChaScore1 > healChaScore3 )
{
- if ( healHp > healSta )
- return HealHP;
- return HealSta;
+ if ( healChaScore1 > healChaScore2 )
+ return HealChaScore1;
+ return HealChaScore2;
}
else
{
- if ( healSap > healSta )
- return HealSap;
- return HealSta;
+ if ( healChaScore3 > healChaScore2 )
+ return HealChaScore3;
+ return HealChaScore2;
}
}
else
{
- if ( healHp > healSap )
+ if ( healChaScore1 > healChaScore3 )
{
- if ( healHp > healSta )
- return HealHP;
- return HealSta;
+ if ( healChaScore1 > healChaScore2 )
+ return HealChaScore1;
+ return HealChaScore2;
}
else
{
- if ( healSap > healSta )
- return HealSap;
- return HealSta;
+ if ( healChaScore3 > healChaScore2 )
+ return HealChaScore3;
+ return HealChaScore2;
}
}
}
diff --git a/code/ryzom/common/src/game_share/magic_fx.h b/code/ryzom/common/src/game_share/magic_fx.h
index 2a46475e8..2438c3302 100644
--- a/code/ryzom/common/src/game_share/magic_fx.h
+++ b/code/ryzom/common/src/game_share/magic_fx.h
@@ -93,9 +93,9 @@ namespace MAGICFX
Fear = 18, // ok
// curatif
- HealHP = 15,
- HealSap = 16,
- HealSta = 17,
+ HealChaScore1 = 15,
+ HealChaScore3 = 16,
+ HealChaScore2 = 17,
Stun = 19,
@@ -113,7 +113,7 @@ namespace MAGICFX
};
TMagicFx toMagicFx( DMGTYPE::EDamageType type ,bool Link);
TMagicFx toMagicFx( EFFECT_FAMILIES::TEffectFamily effect);
- TMagicFx healtoMagicFx( sint32 healHp, sint32 healSap, sint32 healSta, bool link );
+ TMagicFx healtoMagicFx( sint32 healChaScore1, sint32 healChaScore3, sint32 healChaScore2, bool link );
// enum for the auras fxs
@@ -122,9 +122,9 @@ namespace MAGICFX
NoAura = 0,
Divinity = 1,
SpeedMove = 2,
- AuraSap = 3,
- AuraSta = 4,
- AuraHp = 5,
+ AuraChaScore3 = 3,
+ AuraChaScore2 = 4,
+ AuraChaScore1 = 5,
ProtectionMelee = 6,
ProtectionRange = 7,
ProtectionMagic = 8,
diff --git a/code/ryzom/common/src/game_share/mode_and_behaviour.cpp b/code/ryzom/common/src/game_share/mode_and_behaviour.cpp
index f6e4a100d..0925d1036 100644
--- a/code/ryzom/common/src/game_share/mode_and_behaviour.cpp
+++ b/code/ryzom/common/src/game_share/mode_and_behaviour.cpp
@@ -100,7 +100,7 @@ namespace MBEHAV
NL_STRING_CONVERSION_TABLE_ENTRY (CAST_ELEC)
NL_STRING_CONVERSION_TABLE_ENTRY (CAST_FEAR)
NL_STRING_CONVERSION_TABLE_ENTRY (CAST_FIRE)
- NL_STRING_CONVERSION_TABLE_ENTRY (CAST_HEALHP)
+ NL_STRING_CONVERSION_TABLE_ENTRY (CAST_HEALChaScore1)
NL_STRING_CONVERSION_TABLE_ENTRY (CAST_MAD)
NL_STRING_CONVERSION_TABLE_ENTRY (CAST_POISON)
NL_STRING_CONVERSION_TABLE_ENTRY (CAST_ROOT)
@@ -135,13 +135,6 @@ namespace MBEHAV
// Combat creature
NL_STRING_CONVERSION_TABLE_ENTRY (CREATURE_ATTACK_0)
NL_STRING_CONVERSION_TABLE_ENTRY (CREATURE_ATTACK_1)
- // New talents
- NL_STRING_CONVERSION_TABLE_ENTRY (JUGGLE)
- NL_STRING_CONVERSION_TABLE_ENTRY (DANSE)
- NL_STRING_CONVERSION_TABLE_ENTRY (PAINT_INIT)
- NL_STRING_CONVERSION_TABLE_ENTRY (PAINT_LOOP)
- NL_STRING_CONVERSION_TABLE_ENTRY (PAINT_END)
-
NL_END_STRING_CONVERSION_TABLE(EBehaviour, BehaviourConversion, UNKNOWN_BEHAVIOUR)
diff --git a/code/ryzom/common/src/game_share/mode_and_behaviour.h b/code/ryzom/common/src/game_share/mode_and_behaviour.h
index ca25c468a..59dc8c6e5 100644
--- a/code/ryzom/common/src/game_share/mode_and_behaviour.h
+++ b/code/ryzom/common/src/game_share/mode_and_behaviour.h
@@ -235,7 +235,7 @@ namespace MBEHAV
CAST_ELEC,
CAST_FEAR,
CAST_FIRE,
- CAST_HEALHP,
+ CAST_HEALChaScore1,
CAST_MAD,
CAST_POISON,
CAST_ROOT,
@@ -286,17 +286,7 @@ namespace MBEHAV
EMOTE_BEGIN, // 46
EMOTE_END = EMOTE_BEGIN+150,
- //--------- JUGGLE ----------//
- JUGGLE,
-
- //--------- DANSE ----------//,
- DANSE,
-
- //--------- PAINT ----------//
- PAINT_INIT,
- PAINT_LOOP,
- PAINT_END,
-
+
// IMPORTANT : IF YOU MODIFY THIS ENUM DO NOT FORGET TO CHANGE stringToBehaviour() TOO
NUMBER_OF_BEHAVIOURS
};
@@ -460,17 +450,17 @@ namespace MBEHAV
TBehaviour8 Behaviour;
- sint16 DeltaHP;
+ sint16 DeltaChaScore1;
uint16 Unused; /// Keep it, used to make the class size = 64 bits (sizeof(CBehaviour) MUST return 8 (bytes))
- inline CBehaviour() : Data(0), Data2(0), Behaviour(UNKNOWN_BEHAVIOUR), DeltaHP(0), Unused(0) {}
+ inline CBehaviour() : Data(0), Data2(0), Behaviour(UNKNOWN_BEHAVIOUR), DeltaChaScore1(0), Unused(0) {}
inline CBehaviour( EBehaviour behaviour )
{
Unused = 0;
Data = 0;
Data2 = 0;
- DeltaHP = 0;
+ DeltaChaScore1 = 0;
Behaviour = behaviour;
}
@@ -479,7 +469,7 @@ namespace MBEHAV
Unused = 0;
Data = data1;
Data2 = data2;
- DeltaHP = 0;
+ DeltaChaScore1 = 0;
Behaviour = behaviour;
}
@@ -495,19 +485,19 @@ namespace MBEHAV
/* Problem: Olivier use a (sint64*) cast on a CBehaviour*, so this operator isn't called ! :'( */
/* must use Member declaration order to match 'brutal' cast */
/************************************************************************/
- //return (((uint64)(DeltaHP)) << 32) + (((uint64)(Data2)) << 24) + (((uint64)(Data)) << 8) + Behaviour;
- return (((uint64)(DeltaHP)) << 32) + (((uint64)(Behaviour)) << 24) + (((uint64)(Data2)) << 16) + Data;
+ //return (((uint64)(DeltaChaScore1)) << 32) + (((uint64)(Data2)) << 24) + (((uint64)(Data)) << 8) + Behaviour;
+ return (((uint64)(DeltaChaScore1)) << 32) + (((uint64)(Behaviour)) << 24) + (((uint64)(Data2)) << 16) + Data;
}
inline CBehaviour& operator= ( uint64 raw )
{
/*
- DeltaHP = (sint16)(raw >> 32) ;
+ DeltaChaScore1 = (sint16)(raw >> 32) ;
Data2 = (uint8)(raw >> 24) ;
Data = (uint16)(raw >> 8) ;
Behaviour = TBehaviour8( (EBehaviour)(raw & 0xFF) );
*/
- DeltaHP = (sint16)(raw >> 32) ;
+ DeltaChaScore1 = (sint16)(raw >> 32) ;
Behaviour = TBehaviour8( (EBehaviour)((raw >> 24)& 0xFF) );
Data2 = uint8((raw >> 16) & 0xff);
Data = uint16(raw & 0xffff);
@@ -516,7 +506,7 @@ namespace MBEHAV
inline CBehaviour& operator= ( EBehaviour behaviour )
{
- DeltaHP = 0;
+ DeltaChaScore1 = 0;
Data = 0;
Data2 = 0;
Behaviour = behaviour;
@@ -524,13 +514,13 @@ namespace MBEHAV
}
inline CBehaviour& operator = ( const CBehaviour& p )
- { DeltaHP = p.DeltaHP; Behaviour = p.Behaviour; Data = p.Data; Data2 = p.Data2; return *this; }
+ { DeltaChaScore1 = p.DeltaChaScore1; Behaviour = p.Behaviour; Data = p.Data; Data2 = p.Data2; return *this; }
inline bool operator == ( const CBehaviour& p ) const
- { return (DeltaHP == p.DeltaHP && Behaviour == (EBehaviour)p.Behaviour && Data == p.Data && Data2 == p.Data2); }
+ { return (DeltaChaScore1 == p.DeltaChaScore1 && Behaviour == (EBehaviour)p.Behaviour && Data == p.Data && Data2 == p.Data2); }
inline bool operator != ( const CBehaviour& p ) const
- { return (Behaviour != (EBehaviour)p.Behaviour || Data != p.Data || Data2 != p.Data2 || DeltaHP != p.DeltaHP); }
+ { return (Behaviour != (EBehaviour)p.Behaviour || Data != p.Data || Data2 != p.Data2 || DeltaChaScore1 != p.DeltaChaScore1); }
inline void serial (NLMISC::IStream &f) throw (NLMISC::EStream)
{
@@ -551,7 +541,7 @@ namespace MBEHAV
/// methode toString()
inline std::string toString() const
{
- std::string text = behaviourToString( Behaviour ) + " " + NLMISC::toString(Data) + " "+NLMISC::toString(Data2)+" "+ NLMISC::toString(DeltaHP);
+ std::string text = behaviourToString( Behaviour ) + " " + NLMISC::toString(Data) + " "+NLMISC::toString(Data2)+" "+ NLMISC::toString(DeltaChaScore1);
return text;
}
diff --git a/code/ryzom/common/src/game_share/power_types.cpp b/code/ryzom/common/src/game_share/power_types.cpp
index 73020a9c3..38c8e5f52 100644
--- a/code/ryzom/common/src/game_share/power_types.cpp
+++ b/code/ryzom/common/src/game_share/power_types.cpp
@@ -28,21 +28,21 @@ namespace POWERS
NL_STRING_CONVERSION_TABLE_ENTRY(Taunt)
NL_STRING_CONVERSION_TABLE_ENTRY(Shielding)
NL_STRING_CONVERSION_TABLE_ENTRY(SpeedingUp)
- NL_STRING_CONVERSION_TABLE_ENTRY(LifeConcentration)
- NL_STRING_CONVERSION_TABLE_ENTRY(StaminaConcentration)
- NL_STRING_CONVERSION_TABLE_ENTRY(SapConcentration)
- NL_STRING_CONVERSION_TABLE_ENTRY(ConvertStamina)
- NL_STRING_CONVERSION_TABLE_ENTRY(ConvertSap)
+ NL_STRING_CONVERSION_TABLE_ENTRY(ChaScore1Concentration)
+ NL_STRING_CONVERSION_TABLE_ENTRY(ChaScore2Concentration)
+ NL_STRING_CONVERSION_TABLE_ENTRY(ChaScore3Concentration)
+ NL_STRING_CONVERSION_TABLE_ENTRY(ConvertChaScore2)
+ NL_STRING_CONVERSION_TABLE_ENTRY(ConvertChaScore3)
NL_STRING_CONVERSION_TABLE_ENTRY(Berserk)
- NL_STRING_CONVERSION_TABLE_ENTRY(BalanceHp)
+ NL_STRING_CONVERSION_TABLE_ENTRY(BalanceChaScore1)
NL_STRING_CONVERSION_TABLE_ENTRY(Heal)
NL_STRING_CONVERSION_TABLE_ENTRY(Invulnerability)
NL_STRING_CONVERSION_TABLE_ENTRY(EnchantWeapon)
- NL_STRING_CONVERSION_TABLE_ENTRY(HealHpC)
- NL_STRING_CONVERSION_TABLE_ENTRY(HealSapC)
- NL_STRING_CONVERSION_TABLE_ENTRY(HealStaC)
- NL_STRING_CONVERSION_TABLE_ENTRY(HealFocusC)
+ NL_STRING_CONVERSION_TABLE_ENTRY(HealChaScore1C)
+ NL_STRING_CONVERSION_TABLE_ENTRY(HealChaScore3C)
+ NL_STRING_CONVERSION_TABLE_ENTRY(HealChaScore2C)
+ NL_STRING_CONVERSION_TABLE_ENTRY(HealChaScore4C)
NL_STRING_CONVERSION_TABLE_ENTRY(ChgCharac)
NL_STRING_CONVERSION_TABLE_ENTRY(ModDefenseSkill)
@@ -60,9 +60,9 @@ namespace POWERS
NL_STRING_CONVERSION_TABLE_ENTRY(ModPrimaryRootForageSkill)
NL_STRING_CONVERSION_TABLE_ENTRY(ModMagicProtection)
- NL_STRING_CONVERSION_TABLE_ENTRY(LifeAura)
- NL_STRING_CONVERSION_TABLE_ENTRY(StaminaAura)
- NL_STRING_CONVERSION_TABLE_ENTRY(SapAura)
+ NL_STRING_CONVERSION_TABLE_ENTRY(ChaScore1Aura)
+ NL_STRING_CONVERSION_TABLE_ENTRY(ChaScore2Aura)
+ NL_STRING_CONVERSION_TABLE_ENTRY(ChaScore3Aura)
NL_STRING_CONVERSION_TABLE_ENTRY(MeleeProtection)
NL_STRING_CONVERSION_TABLE_ENTRY(Umbrella)
NL_STRING_CONVERSION_TABLE_ENTRY(AntiMagicShield)
diff --git a/code/ryzom/common/src/game_share/power_types.h b/code/ryzom/common/src/game_share/power_types.h
index 54c32a221..5a29dcbeb 100644
--- a/code/ryzom/common/src/game_share/power_types.h
+++ b/code/ryzom/common/src/game_share/power_types.h
@@ -33,22 +33,22 @@ namespace POWERS
Taunt = BeginPower,
Shielding,
SpeedingUp,
- LifeConcentration,
- StaminaConcentration,
- SapConcentration,
- ConvertStamina,
- ConvertSap,
+ ChaScore1Concentration,
+ ChaScore2Concentration,
+ ChaScore3Concentration,
+ ConvertChaScore2,
+ ConvertChaScore3,
Berserk,
- BalanceHp,
+ BalanceChaScore1,
Heal,
Invulnerability,
EnchantWeapon,
// consumable item related powers
- HealHpC,
- HealSapC,
- HealStaC,
- HealFocusC,
+ HealChaScore1C,
+ HealChaScore3C,
+ HealChaScore2C,
+ HealChaScore4C,
ChgCharac,
ModDefenseSkill,
ModDodgeSkill,
@@ -67,9 +67,9 @@ namespace POWERS
EndPower = ModMagicProtection,
BeginAuras,
- LifeAura = BeginAuras,
- StaminaAura,
- SapAura,
+ ChaScore1Aura = BeginAuras,
+ ChaScore2Aura,
+ ChaScore3Aura,
MeleeProtection,
Umbrella,
AntiMagicShield,
diff --git a/code/ryzom/common/src/game_share/ryzom_mirror_properties.cpp b/code/ryzom/common/src/game_share/ryzom_mirror_properties.cpp
index d8824c386..6406c99ae 100644
--- a/code/ryzom/common/src/game_share/ryzom_mirror_properties.cpp
+++ b/code/ryzom/common/src/game_share/ryzom_mirror_properties.cpp
@@ -44,8 +44,8 @@ TPropertyIndex DSPropertyENTITY_MOUNTED_ID = INVALID_PROPERTY_INDEX;
TPropertyIndex DSPropertyRIDER_ENTITY_ID = INVALID_PROPERTY_INDEX;
TPropertyIndex DSPropertyCELL = INVALID_PROPERTY_INDEX;
TPropertyIndex DSPropertyVISION_COUNTER = INVALID_PROPERTY_INDEX;
-TPropertyIndex DSPropertyCURRENT_HIT_POINTS = INVALID_PROPERTY_INDEX;
-TPropertyIndex DSPropertyMAX_HIT_POINTS = INVALID_PROPERTY_INDEX;
+TPropertyIndex DSPropertyCURRENT_ChaScore1 = INVALID_PROPERTY_INDEX;
+TPropertyIndex DSPropertyMAX_ChaScore1 = INVALID_PROPERTY_INDEX;
TPropertyIndex DSPropertyCURRENT_RUN_SPEED = INVALID_PROPERTY_INDEX;
TPropertyIndex DSPropertyCURRENT_WALK_SPEED = INVALID_PROPERTY_INDEX;
TPropertyIndex DSPropertyBEST_ROLE = INVALID_PROPERTY_INDEX;
@@ -137,8 +137,8 @@ void initRyzomVisualPropertyIndices( CMirroredDataSet& dataset )
assignProp( RIDER_ENTITY_ID, RiderEntity );
assignProp( CELL, Cell );
assignProp( VISION_COUNTER, VisionCounter );
- assignProp( CURRENT_HIT_POINTS, CurrentHitPoints );
- assignProp( MAX_HIT_POINTS, MaxHitPoints );
+ assignProp( CURRENT_ChaScore1, CurrentChaScore1 );
+ assignProp( MAX_ChaScore1, MaxChaScore1 );
assignProp( CURRENT_RUN_SPEED, CurrentRunSpeed );
assignProp( CURRENT_WALK_SPEED, CurrentWalkSpeed );
assignProp( BEST_ROLE, BestRole );
diff --git a/code/ryzom/common/src/game_share/ryzom_mirror_properties.h b/code/ryzom/common/src/game_share/ryzom_mirror_properties.h
index 134ebe38b..37463c4cc 100644
--- a/code/ryzom/common/src/game_share/ryzom_mirror_properties.h
+++ b/code/ryzom/common/src/game_share/ryzom_mirror_properties.h
@@ -53,8 +53,8 @@ extern TPropertyIndex DSPropertyENTITY_MOUNTED_ID;
extern TPropertyIndex DSPropertyRIDER_ENTITY_ID;
extern TPropertyIndex DSPropertyCELL;
extern TPropertyIndex DSPropertyVISION_COUNTER;
-extern TPropertyIndex DSPropertyCURRENT_HIT_POINTS;
-extern TPropertyIndex DSPropertyMAX_HIT_POINTS;
+extern TPropertyIndex DSPropertyCURRENT_ChaScore1;
+extern TPropertyIndex DSPropertyMAX_ChaScore1;
extern TPropertyIndex DSPropertyCURRENT_RUN_SPEED;
extern TPropertyIndex DSPropertyCURRENT_WALK_SPEED;
extern TPropertyIndex DSPropertyBEST_ROLE;
@@ -109,8 +109,8 @@ void initRyzomVisualPropertyIndices( CMirroredDataSet& dataset );
#define TYPE_CELL sint32
#define TYPE_VISION_COUNTER uint8
-#define TYPE_CURRENT_HIT_POINTS sint32
-#define TYPE_MAX_HIT_POINTS sint32
+#define TYPE_CURRENT_ChaScore1 sint32
+#define TYPE_MAX_ChaScore1 sint32
#define TYPE_RUNSPEED float
#define TYPE_WALKSPEED float
#define TYPE_BEST_ROLE uint16
diff --git a/code/ryzom/common/src/game_share/scores.cpp b/code/ryzom/common/src/game_share/scores.cpp
index 0df0d96f6..dc675f368 100644
--- a/code/ryzom/common/src/game_share/scores.cpp
+++ b/code/ryzom/common/src/game_share/scores.cpp
@@ -30,10 +30,10 @@ namespace SCORES
// The conversion table
const CStringConversion::CPair stringTable [] =
{
- { "HitPoints", hit_points },
- { "Stamina", stamina },
- { "Sap", sap },
- { "Focus", focus },
+ { "ChaScore1", cha_score1 },
+ { "ChaScore2", cha_score2 },
+ { "ChaScore3", cha_score3 },
+ { "ChaScore4", cha_score4 },
};
CStringConversion conversion(stringTable, sizeof(stringTable) / sizeof(stringTable[0]), unknown);
diff --git a/code/ryzom/common/src/game_share/scores.h b/code/ryzom/common/src/game_share/scores.h
index 1cde63af1..b47763990 100644
--- a/code/ryzom/common/src/game_share/scores.h
+++ b/code/ryzom/common/src/game_share/scores.h
@@ -27,10 +27,10 @@ namespace SCORES
{
enum TScores
{
- hit_points = 0,
- stamina,
- sap,
- focus,
+ cha_score1 = 0,
+ cha_score2,
+ cha_score3,
+ cha_score4,
NUM_SCORES,
unknown = NUM_SCORES
diff --git a/code/ryzom/common/src/game_share/server_animation_module.cpp b/code/ryzom/common/src/game_share/server_animation_module.cpp
index 199a983ef..aa83afd92 100644
--- a/code/ryzom/common/src/game_share/server_animation_module.cpp
+++ b/code/ryzom/common/src/game_share/server_animation_module.cpp
@@ -3145,13 +3145,13 @@ void CServerAnimationModule::onCharTargetReceived( NLNET::IModuleProxy *senderMo
if ( (animationProp & CAnimationProp::Alive) )
{
- if (args[0] == "ADD_HP") { CAiWrapper::getInstance().setHPLevel(rtNpc->EntityId, alias, 1); return; }
+ if (args[0] == "ADD_ChaScore1") { CAiWrapper::getInstance().setChaScore1Level(rtNpc->EntityId, alias, 1); return; }
- if (args[0] == "KILL_NPC" && alived) { CAiWrapper::getInstance().setHPLevel(rtNpc->EntityId, alias, 0); return; }
- if (args[0] == "ADD_HP") { CAiWrapper::getInstance().setHPLevel(rtNpc->EntityId, alias, 1); return; }
+ if (args[0] == "KILL_NPC" && alived) { CAiWrapper::getInstance().setChaScore1Level(rtNpc->EntityId, alias, 0); return; }
+ if (args[0] == "ADD_ChaScore1") { CAiWrapper::getInstance().setChaScore1Level(rtNpc->EntityId, alias, 1); return; }
- if (args[0] == "GRP_KILL" && alived) { CAiWrapper::getInstance().setGrpHPLevel(rtNpc->EntityId, alias, 0); return; }
- if (args[0] == "GRP_HEAL") { CAiWrapper::getInstance().setGrpHPLevel(rtNpc->EntityId, alias, 1); return; }
+ if (args[0] == "GRP_KILL" && alived) { CAiWrapper::getInstance().setGrpChaScore1Level(rtNpc->EntityId, alias, 0); return; }
+ if (args[0] == "GRP_HEAL") { CAiWrapper::getInstance().setGrpChaScore1Level(rtNpc->EntityId, alias, 1); return; }
diff --git a/code/ryzom/server/data_shard/mirror_sheets/fe_temp.dataset b/code/ryzom/server/data_shard/mirror_sheets/fe_temp.dataset
index b891b6252..2203ecc8e 100644
--- a/code/ryzom/server/data_shard/mirror_sheets/fe_temp.dataset
+++ b/code/ryzom/server/data_shard/mirror_sheets/fe_temp.dataset
@@ -178,14 +178,14 @@
-
+
-
+
diff --git a/code/ryzom/server/src/ai_service/ai.cpp b/code/ryzom/server/src/ai_service/ai.cpp
index 49144fa9d..8c8a642ed 100644
--- a/code/ryzom/server/src/ai_service/ai.cpp
+++ b/code/ryzom/server/src/ai_service/ai.cpp
@@ -415,22 +415,22 @@ void CAIS::update()
_FaunaDescriptionList.Bots.clear();
_FaunaDescriptionList.GrpAlias.clear();
}
- // send agglomerated hp changes
- if (!_CreatureChangeHPList.Entities.empty())
+ // send agglomerated ChaScore1 changes
+ if (!_CreatureChangeChaScore1List.Entities.empty())
{
- nlassert(_CreatureChangeHPList.Entities.size()==_CreatureChangeHPList.DeltaHp.size());
- _CreatureChangeHPList.send("EGS");
- _CreatureChangeHPList.Entities.clear();
- _CreatureChangeHPList.DeltaHp.clear();
+ nlassert(_CreatureChangeChaScore1List.Entities.size()==_CreatureChangeChaScore1List.DeltaChaScore1.size());
+ _CreatureChangeChaScore1List.send("EGS");
+ _CreatureChangeChaScore1List.Entities.clear();
+ _CreatureChangeChaScore1List.DeltaChaScore1.clear();
}
- if (!_CreatureChangeMaxHPList.Entities.empty())
+ if (!_CreatureChangeMaxChaScore1List.Entities.empty())
{
- nlassert(_CreatureChangeMaxHPList.Entities.size()==_CreatureChangeMaxHPList.MaxHp.size());
- nlassert(_CreatureChangeMaxHPList.Entities.size()==_CreatureChangeMaxHPList.SetFull.size());
- _CreatureChangeMaxHPList.send("EGS");
- _CreatureChangeMaxHPList.Entities.clear();
- _CreatureChangeMaxHPList.MaxHp.clear();
- _CreatureChangeMaxHPList.SetFull.clear();
+ nlassert(_CreatureChangeMaxChaScore1List.Entities.size()==_CreatureChangeMaxChaScore1List.MaxChaScore1.size());
+ nlassert(_CreatureChangeMaxChaScore1List.Entities.size()==_CreatureChangeMaxChaScore1List.SetFull.size());
+ _CreatureChangeMaxChaScore1List.send("EGS");
+ _CreatureChangeMaxChaScore1List.Entities.clear();
+ _CreatureChangeMaxChaScore1List.MaxChaScore1.clear();
+ _CreatureChangeMaxChaScore1List.SetFull.clear();
}
}
diff --git a/code/ryzom/server/src/ai_service/ai.h b/code/ryzom/server/src/ai_service/ai.h
index 57ff524ec..ce2754b8f 100644
--- a/code/ryzom/server/src/ai_service/ai.h
+++ b/code/ryzom/server/src/ai_service/ai.h
@@ -217,14 +217,14 @@ public:
{
return _FaunaDescriptionList;
}
- CChangeCreatureHPMsg &getCreatureChangeHP()
+ CChangeCreatureChaScore1Msg &getCreatureChangeChaScore1()
{
- return _CreatureChangeHPList;
+ return _CreatureChangeChaScore1List;
}
- CChangeCreatureMaxHPMsg &getCreatureChangeMaxHP()
+ CChangeCreatureMaxChaScore1Msg &getCreatureChangeMaxChaScore1()
{
- return _CreatureChangeMaxHPList;
+ return _CreatureChangeMaxChaScore1List;
}
enum TSearchType
@@ -292,8 +292,8 @@ private:
// Faunas descriptions to be sent each frame
CFaunaBotDescription _FaunaDescriptionList;
- CChangeCreatureHPMsg _CreatureChangeHPList;
- CChangeCreatureMaxHPMsg _CreatureChangeMaxHPList;
+ CChangeCreatureChaScore1Msg _CreatureChangeChaScore1List;
+ CChangeCreatureMaxChaScore1Msg _CreatureChangeMaxChaScore1List;
/// The emot identifiers
std::map _EmotNames;
diff --git a/code/ryzom/server/src/ai_service/ai_bot.cpp b/code/ryzom/server/src/ai_service/ai_bot.cpp
index 2fb47023a..65c8c3bb9 100644
--- a/code/ryzom/server/src/ai_service/ai_bot.cpp
+++ b/code/ryzom/server/src/ai_service/ai_bot.cpp
@@ -350,13 +350,13 @@ void CSpawnBot::sendInfoToEGS() const
if (!EGSHasMirrorReady)
return;
- const uint32& maxHp = getPersistent().getCustomMaxHp();
- if (maxHp > 0.f)
+ const uint32& maxChaScore1 = getPersistent().getCustomMaxChaScore1();
+ if (maxChaScore1 > 0.f)
{
- CChangeCreatureMaxHPMsg& msgList = CAIS::instance().getCreatureChangeMaxHP();
+ CChangeCreatureMaxChaScore1Msg& msgList = CAIS::instance().getCreatureChangeMaxChaScore1();
msgList.Entities.push_back(dataSetRow());
- msgList.MaxHp.push_back((uint32)(maxHp));
+ msgList.MaxChaScore1.push_back((uint32)(maxChaScore1));
msgList.SetFull.push_back((uint8)(1));
}
}
@@ -377,7 +377,7 @@ CBot::CBot(CGroup* owner, CAIAliasDescriptionNode* alias)
, _SetSheetData(NULL)
, _Observers(NULL)
, _ProfileData(NULL)
-, _CustomMaxHp(0)
+, _CustomMaxChaScore1(0)
{
}
@@ -392,7 +392,7 @@ CBot::CBot(CGroup* owner, uint32 alias, std::string const& name)
, _SetSheetData(NULL)
, _Observers(NULL)
, _ProfileData(NULL)
-, _CustomMaxHp(0.f)
+, _CustomMaxChaScore1(0.f)
{
}
diff --git a/code/ryzom/server/src/ai_service/ai_bot.h b/code/ryzom/server/src/ai_service/ai_bot.h
index 9810dcd41..a5cc1b5ed 100644
--- a/code/ryzom/server/src/ai_service/ai_bot.h
+++ b/code/ryzom/server/src/ai_service/ai_bot.h
@@ -257,8 +257,8 @@ public:
const ucstring& getCustomName() const { return _CustomName; }
void setCustomName(const ucstring &name) { _CustomName = name; }
- const uint32& getCustomMaxHp() const { return _CustomMaxHp; }
- void setCustomMaxHp(const uint32 &maxHp) { _CustomMaxHp = maxHp; }
+ const uint32& getCustomMaxChaScore1() const { return _CustomMaxChaScore1; }
+ void setCustomMaxChaScore1(const uint32 &maxChaScore1) { _CustomMaxChaScore1 = maxChaScore1; }
virtual void setClientSheet(const std::string & clientSheetName);
@@ -290,7 +290,7 @@ private:
bool _Healer;
bool _BuildingBot;
ucstring _CustomName;
- uint32 _CustomMaxHp;
+ uint32 _CustomMaxChaScore1;
CTimer _SetSheetTimer;
struct CSetSheetData
{
diff --git a/code/ryzom/server/src/ai_service/ai_bot_fauna.cpp b/code/ryzom/server/src/ai_service/ai_bot_fauna.cpp
index a6573d4bb..254b6847a 100644
--- a/code/ryzom/server/src/ai_service/ai_bot_fauna.cpp
+++ b/code/ryzom/server/src/ai_service/ai_bot_fauna.cpp
@@ -501,7 +501,7 @@ void CSpawnBotFauna::getBestTarget()
if ( canMove()
&& !player->isAggressive()
&& entity->wpos().isValid()
- && isPlaceAllowed(entity->getAStarFlag(), entity->wpos().getFlags()))
+ && (entity->wpos().getFlags()&entity->getAStarFlag())==0)
{
// Suppose we can go to him
bool canChange = true;
@@ -676,7 +676,7 @@ void CSpawnBotFauna::getBestTarget()
if (runSpeed()>entity->runSpeed())
{
// got enought life ? (more than 75%).
- if ((4*currentHitPoints())>(3*maxHitPoints()))
+ if ((4*currentChaScore1())>(3*maxChaScore1()))
{
// check if the herbivore is in the current place
const CAIPlace *place=spawnGrp().targetPlace();
@@ -706,7 +706,7 @@ void CSpawnBotFauna::getBestTarget()
if ( profile
&& profile->getAIProfileType()==ACTIVITY_CORPSE
&& botCreat->wpos().isValid()
- && isPlaceAllowed(botCreat->getAStarFlag(), botCreat->wpos().getFlags())
+ && !(botCreat->wpos().getFlags()&botCreat->getAStarFlag())
)
{
CCorpseFaunaProfile *corpseProfile=NLMISC::safe_cast(profile);
@@ -951,7 +951,7 @@ void CMovementMagnet::getNewDestination(RYAI_MAP_CRUNCH::CWorldPosition const& a
continue;
if ( !faunaBot->wpos().isValid()
- || !isPlaceAllowed(denyFlag, faunaBot->wpos().getFlags()))
+ || (faunaBot->wpos().getFlags()&denyFlag)!=0)
continue;
// can be optimize by in avoid inversion.
@@ -990,7 +990,7 @@ void CMovementMagnet::getNewDestination(RYAI_MAP_CRUNCH::CWorldPosition const& a
// check if its a nogo and water proof position.
if ( !wRndPos.isValid()
- || !isPlaceAllowed(denyFlag, wRndPos.getTopologyRef().getCstTopologyNode().getFlags()))
+ || (wRndPos.getTopologyRef().getCstTopologyNode().getFlags()&denyFlag)!=0 )
continue;
#if !FINAL_VERSION
@@ -1126,7 +1126,7 @@ CReturnMovementMagnet::CReturnMovementMagnet(RYAI_MAP_CRUNCH::CWorldPosition con
void CReturnMovementMagnet::getNewDestination(RYAI_MAP_CRUNCH::CWorldPosition const& alternativePos, RYAI_MAP_CRUNCH::TAStarFlag denyFlag)
{
- if (_ForcedDest.isValid() && isPlaceAllowed(denyFlag, _ForcedDest.getTopologyRef().getCstTopologyNode().getFlags()))
+ if (_ForcedDest.isValid() && (_ForcedDest.getTopologyRef().getCstTopologyNode().getFlags()&denyFlag)==0)
_PathCont.setDestination(_ForcedDest);
else
CMovementMagnet::getNewDestination(alternativePos, denyFlag);
diff --git a/code/ryzom/server/src/ai_service/ai_bot_npc.cpp b/code/ryzom/server/src/ai_service/ai_bot_npc.cpp
index 201cc517c..d408db9d6 100644
--- a/code/ryzom/server/src/ai_service/ai_bot_npc.cpp
+++ b/code/ryzom/server/src/ai_service/ai_bot_npc.cpp
@@ -46,7 +46,7 @@ static bool VerboseLog = false;
CSpawnBotNpc::CSpawnBotNpc(TDataSetRow const& row, CBot& owner, NLMISC::CEntityId const& id, float radius, uint32 level, RYAI_MAP_CRUNCH::TAStarFlag denyFlags)
: CSpawnBot(row, owner, id, radius, level, denyFlags)
{
- _OldHpPercentage = -1.f;
+ _OldChaScore1Percentage = -1.f;
_NbCurrentDynChats = 0;
_FacingTheta = 0;
_FacingTick = 0;
@@ -115,22 +115,22 @@ void CSpawnBotNpc::processEvent(CCombatInterface::CEvent const& event)
++AISStat::BotNpcUpdCtr;
{
- H_AUTO(AIHpTrig);
- // Fix for HP triggers
+ H_AUTO(AIChaScore1Trig);
+ // Fix for ChaScore1 triggers
// :FIXME: Clean that triggering stuff, make it generic
CGroupNpc& persGrp = spawnGrp().getPersistent();
- if (persGrp.haveHpTriggers())
+ if (persGrp.haveChaScore1Triggers())
{
- float newHpPercentage = getPhysical().hpPercentage();
- if (_OldHpPercentage>=0.f && newHpPercentage!=_OldHpPercentage)
+ float newChaScore1Percentage = getPhysical().ChaScore1Percentage();
+ if (_OldChaScore1Percentage>=0.f && newChaScore1Percentage!=_OldChaScore1Percentage)
{
- persGrp.hpTriggerCb(_OldHpPercentage, newHpPercentage);
+ persGrp.ChaScore1TriggerCb(_OldChaScore1Percentage, newChaScore1Percentage);
}
- _OldHpPercentage = newHpPercentage;
+ _OldChaScore1Percentage = newChaScore1Percentage;
}
else
{
- _OldHpPercentage = getPhysical().hpPercentage();
+ _OldChaScore1Percentage = getPhysical().ChaScore1Percentage();
}
}
diff --git a/code/ryzom/server/src/ai_service/ai_bot_npc.h b/code/ryzom/server/src/ai_service/ai_bot_npc.h
index 3455e7f58..7afe40c79 100644
--- a/code/ryzom/server/src/ai_service/ai_bot_npc.h
+++ b/code/ryzom/server/src/ai_service/ai_bot_npc.h
@@ -101,7 +101,7 @@ public:
private:
std::vector _ActiveChats; // vector of ptrs to players currently chatting with bot
- float _OldHpPercentage; // Fix for HP triggers
+ float _OldChaScore1Percentage; // Fix for ChaScore1 triggers
CNpcChatProfileImp _CurrentChatProfile;
sint32 _NbCurrentDynChats;
diff --git a/code/ryzom/server/src/ai_service/ai_entity_physical.h b/code/ryzom/server/src/ai_service/ai_entity_physical.h
index 5eb30b34f..000c22340 100644
--- a/code/ryzom/server/src/ai_service/ai_entity_physical.h
+++ b/code/ryzom/server/src/ai_service/ai_entity_physical.h
@@ -234,7 +234,7 @@ public:
CAICoord const& y() const { return _pos.y(); }
sint32 h() const { return _pos.h(); }
CAngle theta() const { return _pos.theta(); }
- float hpPercentage() const { return (float)currentHitPoints()/(float)maxHitPoints(); }
+ float ChaScore1Percentage() const { return (float)currentChaScore1()/(float)maxChaScore1(); }
TDataSetRow const& dataSetRow() const { return _dataSetRow; }
uint32 level() const { return _Level; }
RYAI_MAP_CRUNCH::CWorldPosition const& wpos() const { return _wpos; }
@@ -244,8 +244,8 @@ public:
/// @name Mirror accessors
//@{
- TYPE_CURRENT_HIT_POINTS currentHitPoints() const { return _CurrentHitPoint(); }
- TYPE_MAX_HIT_POINTS maxHitPoints() const { return _MaxHitPoint(); }
+ TYPE_CURRENT_ChaScore1 currentChaScore1() const { return _CurrentChaScore1(); }
+ TYPE_MAX_ChaScore1 maxChaScore1() const { return _MaxChaScore1(); }
TYPE_VISION_COUNTER currentVisionCounter() const { return _VisionCounter(); }
bool havePlayersAround() const;
@@ -345,8 +345,8 @@ private:
CMirrorPropValueRO _RunSpeed;
CMirrorPropValueRO _WalkSpeed;
- CMirrorPropValueRO _CurrentHitPoint;
- CMirrorPropValueRO _MaxHitPoint;
+ CMirrorPropValueRO _CurrentChaScore1;
+ CMirrorPropValueRO _MaxChaScore1;
CMirrorPropValueRO _VisionCounter;
CMirrorPropValue _InOutpostAlias;
CMirrorPropValue _InOutpostSide;
diff --git a/code/ryzom/server/src/ai_service/ai_entity_physical_inline.h b/code/ryzom/server/src/ai_service/ai_entity_physical_inline.h
index a865edb6f..e1766d2c0 100644
--- a/code/ryzom/server/src/ai_service/ai_entity_physical_inline.h
+++ b/code/ryzom/server/src/ai_service/ai_entity_physical_inline.h
@@ -64,8 +64,8 @@ CAIEntityPhysical::CAIEntityPhysical(CPersistentOfPhysical& owner, TDataSetRow c
_RunSpeed.init (*CMirrors::DataSet, entityIndex, DSPropertyCURRENT_RUN_SPEED);
_WalkSpeed.init (*CMirrors::DataSet, entityIndex, DSPropertyCURRENT_WALK_SPEED);
- _CurrentHitPoint.init (*CMirrors::DataSet, entityIndex, DSPropertyCURRENT_HIT_POINTS);
- _MaxHitPoint.init (*CMirrors::DataSet, entityIndex, DSPropertyMAX_HIT_POINTS);
+ _CurrentChaScore1.init (*CMirrors::DataSet, entityIndex, DSPropertyCURRENT_ChaScore1);
+ _MaxChaScore1.init (*CMirrors::DataSet, entityIndex, DSPropertyMAX_ChaScore1);
_VisionCounter.init (*CMirrors::DataSet, entityIndex, DSPropertyVISION_COUNTER);
_InOutpostAlias.init (*CMirrors::DataSet, entityIndex, DSPropertyIN_OUTPOST_ZONE_ALIAS);
_InOutpostSide.init (*CMirrors::DataSet, entityIndex, DSPropertyIN_OUTPOST_ZONE_SIDE);
diff --git a/code/ryzom/server/src/ai_service/ai_generic_fight.cpp b/code/ryzom/server/src/ai_service/ai_generic_fight.cpp
index cec456267..f605ab947 100644
--- a/code/ryzom/server/src/ai_service/ai_generic_fight.cpp
+++ b/code/ryzom/server/src/ai_service/ai_generic_fight.cpp
@@ -309,7 +309,7 @@ void CBotProfileFlee::updateProfile(uint ticksSinceLastUpdate)
{
RYAI_MAP_CRUNCH::CWorldPosition wpos=rootCell->getWorldPosition(_Bot->getPersistent().getChildIndex()&3);
if ( wpos.isValid()
- && isPlaceAllowed(_DenyFlags, wpos.getFlags())) // verify that we got some compatible flags ..
+ && (wpos.getFlags()&_DenyFlags)==0 ) // verify that we got some compatible flags ..
{
_LastDir=startDir;
_LastStartPos=_Bot->wpos();
@@ -378,12 +378,12 @@ bool CFightOrganizer::healIteration(CBot* bot, CBot* otherBot)
CSpawnBot* otherSpBot = otherBot->getSpawnObj();
if (spBot && otherSpBot && otherSpBot->isAlive())
{
- float hp = otherSpBot->hpPercentage();
+ float ChaScore1 = otherSpBot->ChaScore1Percentage();
int neededHealers = 0;
- if (hp<.90f) ++neededHealers;
- if (hp<.75f) ++neededHealers;
- if (hp<.50f) ++neededHealers;
- if (hp<.25f) ++neededHealers;
+ if (ChaScore1<.90f) ++neededHealers;
+ if (ChaScore1<.75f) ++neededHealers;
+ if (ChaScore1<.50f) ++neededHealers;
+ if (ChaScore1<.25f) ++neededHealers;
if (neededHealers > otherSpBot->getHealerCount())
{
IAIProfile* profile = spBot->getAIProfile();
diff --git a/code/ryzom/server/src/ai_service/ai_generic_fight_helpers.cpp b/code/ryzom/server/src/ai_service/ai_generic_fight_helpers.cpp
index f6d0af29d..f6051702a 100644
--- a/code/ryzom/server/src/ai_service/ai_generic_fight_helpers.cpp
+++ b/code/ryzom/server/src/ai_service/ai_generic_fight_helpers.cpp
@@ -374,7 +374,7 @@ bool s_move(
0.5f);
// If we can't follow the path or the computed pos is invalid
if ( status==CFollowPath::FOLLOW_NO_PATH
- || (_Bot->wpos().isValid() && !isPlaceAllowed(_Bot->getAStarFlag(), _Bot->wpos().getFlags())))
+ || (_Bot->wpos().isValid() && (_Bot->wpos().getFlags()&_Bot->getAStarFlag())!=0))
{
// Restore position
_Bot->setPos(lastPos);
@@ -534,7 +534,7 @@ static void s_updateProfile(
target = _Bot->getTarget();
}
// Assert target is valid and alive
- if (!target || !target->isAlive() || (heal && target->hpPercentage()>.9f))
+ if (!target || !target->isAlive() || (heal && target->ChaScore1Percentage()>.9f))
{
// If we are hitting an invalid or dead target just wait we finish hitting, else disengage
if (!_Bot->isHitting())
@@ -605,7 +605,7 @@ static void s_updateProfile(
_AtAttackDist = norm < _RangeMax;
// Check if target can be attacked
- bool const targetInForbiddenZone = ((!target->wpos().isValid())||!isPlaceAllowed(_Bot->getAStarFlag(), target->wpos().getFlags()));
+ bool const targetInForbiddenZone = ((!target->wpos().isValid())||(target->wpos().getFlags()&_Bot->getAStarFlag())!=0);
/****************************************************************************/
/* Profile main processing */
diff --git a/code/ryzom/server/src/ai_service/ai_grp_npc.cpp b/code/ryzom/server/src/ai_service/ai_grp_npc.cpp
index 056293a25..9d9dfb488 100644
--- a/code/ryzom/server/src/ai_service/ai_grp_npc.cpp
+++ b/code/ryzom/server/src/ai_service/ai_grp_npc.cpp
@@ -726,17 +726,17 @@ void CGroupNpc::addParameter(std::string const& parameter)
}
}
-void CGroupNpc::addHpUpTrigger(float threshold, int eventId)
+void CGroupNpc::addChaScore1UpTrigger(float threshold, int eventId)
{
- _hpUpTriggers.insert(std::make_pair(threshold, eventId));
+ _ChaScore1UpTriggers.insert(std::make_pair(threshold, eventId));
}
-void CGroupNpc::delHpUpTrigger(float threshold, int eventId)
+void CGroupNpc::delChaScore1UpTrigger(float threshold, int eventId)
{
- CGroupNpc::THpTriggerList& hpTriggers = _hpUpTriggers;
- CGroupNpc::THpTriggerList::iterator first, last, trigger;
- first = hpTriggers.lower_bound(threshold);
- last = hpTriggers.upper_bound(threshold);
+ CGroupNpc::TChaScore1TriggerList& ChaScore1Triggers = _ChaScore1UpTriggers;
+ CGroupNpc::TChaScore1TriggerList::iterator first, last, trigger;
+ first = ChaScore1Triggers.lower_bound(threshold);
+ last = ChaScore1Triggers.upper_bound(threshold);
for (; first!=last; ++first)
{
@@ -744,20 +744,20 @@ void CGroupNpc::delHpUpTrigger(float threshold, int eventId)
break;
}
if (first!=last)
- hpTriggers.erase(first);
+ ChaScore1Triggers.erase(first);
}
-void CGroupNpc::addHpDownTrigger(float threshold, int eventId)
+void CGroupNpc::addChaScore1DownTrigger(float threshold, int eventId)
{
- _hpDownTriggers.insert(std::make_pair(threshold, eventId));
+ _ChaScore1DownTriggers.insert(std::make_pair(threshold, eventId));
}
-void CGroupNpc::delHpDownTrigger(float threshold, int eventId)
+void CGroupNpc::delChaScore1DownTrigger(float threshold, int eventId)
{
- CGroupNpc::THpTriggerList& hpTriggers = _hpDownTriggers;
- CGroupNpc::THpTriggerList::iterator first, last, trigger;
- first = hpTriggers.lower_bound(threshold);
- last = hpTriggers.upper_bound(threshold);
+ CGroupNpc::TChaScore1TriggerList& ChaScore1Triggers = _ChaScore1DownTriggers;
+ CGroupNpc::TChaScore1TriggerList::iterator first, last, trigger;
+ first = ChaScore1Triggers.lower_bound(threshold);
+ last = ChaScore1Triggers.upper_bound(threshold);
for (; first!=last; ++first)
{
@@ -765,20 +765,20 @@ void CGroupNpc::delHpDownTrigger(float threshold, int eventId)
break;
}
if (first!=last)
- hpTriggers.erase(first);
+ ChaScore1Triggers.erase(first);
}
-void CGroupNpc::addHpUpTrigger(float threshold, std::string cbFunc)
+void CGroupNpc::addChaScore1UpTrigger(float threshold, std::string cbFunc)
{
- _hpUpTriggers2.insert(std::make_pair(threshold, cbFunc));
+ _ChaScore1UpTriggers2.insert(std::make_pair(threshold, cbFunc));
}
-void CGroupNpc::delHpUpTrigger(float threshold, std::string cbFunc)
+void CGroupNpc::delChaScore1UpTrigger(float threshold, std::string cbFunc)
{
- CGroupNpc::THpTriggerList2& hpTriggers = _hpUpTriggers2;
- CGroupNpc::THpTriggerList2::iterator first, last, trigger;
- first = hpTriggers.lower_bound(threshold);
- last = hpTriggers.upper_bound(threshold);
+ CGroupNpc::TChaScore1TriggerList2& ChaScore1Triggers = _ChaScore1UpTriggers2;
+ CGroupNpc::TChaScore1TriggerList2::iterator first, last, trigger;
+ first = ChaScore1Triggers.lower_bound(threshold);
+ last = ChaScore1Triggers.upper_bound(threshold);
for (; first!=last; ++first)
{
@@ -786,20 +786,20 @@ void CGroupNpc::delHpUpTrigger(float threshold, std::string cbFunc)
break;
}
if (first!=last)
- hpTriggers.erase(first);
+ ChaScore1Triggers.erase(first);
}
-void CGroupNpc::addHpDownTrigger(float threshold, std::string cbFunc)
+void CGroupNpc::addChaScore1DownTrigger(float threshold, std::string cbFunc)
{
- _hpDownTriggers2.insert(std::make_pair(threshold, cbFunc));
+ _ChaScore1DownTriggers2.insert(std::make_pair(threshold, cbFunc));
}
-void CGroupNpc::delHpDownTrigger(float threshold, std::string cbFunc)
+void CGroupNpc::delChaScore1DownTrigger(float threshold, std::string cbFunc)
{
- CGroupNpc::THpTriggerList2& hpTriggers = _hpDownTriggers2;
- CGroupNpc::THpTriggerList2::iterator first, last, trigger;
- first = hpTriggers.lower_bound(threshold);
- last = hpTriggers.upper_bound(threshold);
+ CGroupNpc::TChaScore1TriggerList2& ChaScore1Triggers = _ChaScore1DownTriggers2;
+ CGroupNpc::TChaScore1TriggerList2::iterator first, last, trigger;
+ first = ChaScore1Triggers.lower_bound(threshold);
+ last = ChaScore1Triggers.upper_bound(threshold);
for (; first!=last; ++first)
{
@@ -807,30 +807,30 @@ void CGroupNpc::delHpDownTrigger(float threshold, std::string cbFunc)
break;
}
if (first!=last)
- hpTriggers.erase(first);
+ ChaScore1Triggers.erase(first);
}
-bool CGroupNpc::haveHpTriggers()
+bool CGroupNpc::haveChaScore1Triggers()
{
- return (_hpUpTriggers.size()+_hpDownTriggers.size()+_hpUpTriggers2.size()+_hpDownTriggers2.size())>0;
+ return (_ChaScore1UpTriggers.size()+_ChaScore1DownTriggers.size()+_ChaScore1UpTriggers2.size()+_ChaScore1DownTriggers2.size())>0;
}
-void CGroupNpc::hpTriggerCb(float oldVal, float newVal)
+void CGroupNpc::ChaScore1TriggerCb(float oldVal, float newVal)
{
if (newVal>oldVal)
{
- CGroupNpc::THpTriggerList::const_iterator first, last, trigger, triggerProcessed;
- first = _hpUpTriggers.upper_bound(oldVal);
- last = _hpUpTriggers.upper_bound(newVal);
+ CGroupNpc::TChaScore1TriggerList::const_iterator first, last, trigger, triggerProcessed;
+ first = _ChaScore1UpTriggers.upper_bound(oldVal);
+ last = _ChaScore1UpTriggers.upper_bound(newVal);
for (trigger=first; trigger!=last;)
{
triggerProcessed = trigger;
++trigger;
processStateEvent(getEventContainer().EventUserEvent[triggerProcessed->second]);
}
- CGroupNpc::THpTriggerList2::const_iterator first2, last2, trigger2, triggerProcessed2;
- first2 = _hpUpTriggers2.upper_bound(oldVal);
- last2 = _hpUpTriggers2.upper_bound(newVal);
+ CGroupNpc::TChaScore1TriggerList2::const_iterator first2, last2, trigger2, triggerProcessed2;
+ first2 = _ChaScore1UpTriggers2.upper_bound(oldVal);
+ last2 = _ChaScore1UpTriggers2.upper_bound(newVal);
for (trigger2=first2; trigger2!=last2;)
{
triggerProcessed2 = trigger2;
@@ -840,18 +840,18 @@ void CGroupNpc::hpTriggerCb(float oldVal, float newVal)
}
if (newValsecond]);
}
- CGroupNpc::THpTriggerList2::const_iterator first2, last2, trigger2, triggerProcessed2;
- first2 = _hpDownTriggers2.lower_bound(newVal);
- last2 = _hpDownTriggers2.lower_bound(oldVal);
+ CGroupNpc::TChaScore1TriggerList2::const_iterator first2, last2, trigger2, triggerProcessed2;
+ first2 = _ChaScore1DownTriggers2.lower_bound(newVal);
+ last2 = _ChaScore1DownTriggers2.lower_bound(oldVal);
for (trigger2=first2; trigger2!=last2;)
{
triggerProcessed2 = trigger2;
diff --git a/code/ryzom/server/src/ai_service/ai_grp_npc.h b/code/ryzom/server/src/ai_service/ai_grp_npc.h
index bac75d1a9..390ba0e42 100644
--- a/code/ryzom/server/src/ai_service/ai_grp_npc.h
+++ b/code/ryzom/server/src/ai_service/ai_grp_npc.h
@@ -201,18 +201,18 @@ public:
AITYPES::CPropertySetWithExtraList const& friendFaction() const { return _friendFaction; }
public:
- void addHpUpTrigger(float threshold, int eventId);
- void delHpUpTrigger(float threshold, int eventId);
- void addHpUpTrigger(float threshold, std::string cbFunc);
- void delHpUpTrigger(float threshold, std::string cbFunc);
+ void addChaScore1UpTrigger(float threshold, int eventId);
+ void delChaScore1UpTrigger(float threshold, int eventId);
+ void addChaScore1UpTrigger(float threshold, std::string cbFunc);
+ void delChaScore1UpTrigger(float threshold, std::string cbFunc);
- void addHpDownTrigger(float threshold, int eventId);
- void delHpDownTrigger(float threshold, int eventId);
- void addHpDownTrigger(float threshold, std::string cbFunc);
- void delHpDownTrigger(float threshold, std::string cbFunc);
+ void addChaScore1DownTrigger(float threshold, int eventId);
+ void delChaScore1DownTrigger(float threshold, int eventId);
+ void addChaScore1DownTrigger(float threshold, std::string cbFunc);
+ void delChaScore1DownTrigger(float threshold, std::string cbFunc);
- bool haveHpTriggers();
- void hpTriggerCb(float oldVal, float newVal);
+ bool haveChaScore1Triggers();
+ void ChaScore1TriggerCb(float oldVal, float newVal);
void addNamedEntityListener(std::string const& name, std::string const& prop, int event);
void delNamedEntityListener(std::string const& name, std::string const& prop, int event);
@@ -258,12 +258,12 @@ private:
AITYPES::CPropertySetWithExtraList _ennemyFaction;
AITYPES::CPropertySetWithExtraList _friendFaction;
- typedef std::multimap THpTriggerList;
- typedef std::multimap THpTriggerList2;
- THpTriggerList _hpUpTriggers;
- THpTriggerList _hpDownTriggers;
- THpTriggerList2 _hpUpTriggers2;
- THpTriggerList2 _hpDownTriggers2;
+ typedef std::multimap TChaScore1TriggerList;
+ typedef std::multimap TChaScore1TriggerList2;
+ TChaScore1TriggerList _ChaScore1UpTriggers;
+ TChaScore1TriggerList _ChaScore1DownTriggers;
+ TChaScore1TriggerList2 _ChaScore1UpTriggers2;
+ TChaScore1TriggerList2 _ChaScore1DownTriggers2;
typedef std::multimap, int> TNamedEntityListenerList;
TNamedEntityListenerList _namedEntityListeners;
diff --git a/code/ryzom/server/src/ai_service/ai_player.cpp b/code/ryzom/server/src/ai_service/ai_player.cpp
index 3870cfa60..eef9f9d7d 100644
--- a/code/ryzom/server/src/ai_service/ai_player.cpp
+++ b/code/ryzom/server/src/ai_service/ai_player.cpp
@@ -277,7 +277,7 @@ void CManagerPlayer::update()
void CManagerPlayer::addSpawnedPlayer(TDataSetRow const& dataSetRow, NLMISC::CEntityId const& id)
{
- CBotPlayer* player = new CBotPlayer(this,dataSetRow,id,1); // :TODO: default player level calculation (skill & hp ?).
+ CBotPlayer* player = new CBotPlayer(this,dataSetRow,id,1); // :TODO: default player level calculation (skill & ChaScore1 ?).
addChild(player);
player->spawn();
diff --git a/code/ryzom/server/src/ai_service/ai_profile_npc.cpp b/code/ryzom/server/src/ai_service/ai_profile_npc.cpp
index 73c0bddcb..ad1d938ca 100644
--- a/code/ryzom/server/src/ai_service/ai_profile_npc.cpp
+++ b/code/ryzom/server/src/ai_service/ai_profile_npc.cpp
@@ -784,7 +784,7 @@ void CGrpProfileBandit::updateProfile(uint ticksSinceLastUpdate)
CAIEntityPhysical *ep = player->getSpawnObj();
if ( ep
&& ep->isAlive()
- && ep->currentHitPoints()>0.f)
+ && ep->currentChaScore1()>0.f)
{
const CRootCell *const rootCell=ep->wpos().getRootCell();
if ( rootCell
@@ -863,7 +863,7 @@ void CGrpProfileBandit::updateProfile(uint ticksSinceLastUpdate)
if ( ep
&& ep->isAlive()
- && ep->currentHitPoints()>0.f) // not in safe zone.
+ && ep->currentChaScore1()>0.f) // not in safe zone.
{
const CRootCell *const rootCell=ep->wpos().getRootCell();
if ( rootCell
@@ -1111,7 +1111,7 @@ void CGrpProfileGuard::updateProfile(uint ticksSinceLastUpdate)
CAIEntityPhysical *const ep = player->getSpawnObj();
if ( !ep
|| !ep->isAlive()
- || ep->currentHitPoints()<=0.f
+ || ep->currentChaScore1()<=0.f
|| ep->wpos().toAIVector().quickDistTo(centerPos)>aggroSize)
continue;
@@ -1281,7 +1281,7 @@ void CGrpProfileTribu::updateProfile(uint ticksSinceLastUpdate)
CAIEntityPhysical *const ep = player->getSpawnObj();
if ( !ep
|| !ep->isAlive()
- || ep->currentHitPoints()<=0.f)
+ || ep->currentChaScore1()<=0.f)
continue;
const CRootCell *const rootCell=ep->wpos().getRootCell();
@@ -3921,7 +3921,7 @@ void CGrpProfileFaction::checkTargetsAround()
CPersistentOfPhysical const* const popAssisted = (*itAssisted);
CAIEntityPhysical* const epAssisted = popAssisted->getSpawnObj();
// If entity is not alive skip it
- if (!epAssisted || !epAssisted->isAlive() || epAssisted->currentHitPoints()<=0.f)
+ if (!epAssisted || !epAssisted->isAlive() || epAssisted->currentChaScore1()<=0.f)
continue;
// If entity is not a friend skip it
if (!entityHavePartOfFactions(epAssisted, thisFriendFactions))
@@ -3946,7 +3946,7 @@ void CGrpProfileFaction::checkTargetsAround()
const CPersistentOfPhysical *const popAssisted = (*itAssisted);
CAIEntityPhysical *const epAssisted = popAssisted->getSpawnObj();
// If entity is not alive skip it
- if (!epAssisted || !epAssisted->isAlive() || epAssisted->currentHitPoints()<=0.f)
+ if (!epAssisted || !epAssisted->isAlive() || epAssisted->currentChaScore1()<=0.f)
continue;
// If entity is not a npc skip it
if (epAssisted->getRyzomType()!=RYZOMID::npc)
@@ -3981,7 +3981,7 @@ void CGrpProfileFaction::checkTargetsAround()
CPersistentOfPhysical const* const popAttacked = (*itAttacked);
CAIEntityPhysical const* const epAttacked = popAttacked->getSpawnObj();
// If entity is not alive skip it
- if (!epAttacked || !epAttacked->isAlive() || epAttacked->currentHitPoints()<=0.f)
+ if (!epAttacked || !epAttacked->isAlive() || epAttacked->currentChaScore1()<=0.f)
continue;
// If entity is not an ennemy skip it
if (!entityHavePartOfFactions(epAttacked, thisEnnemyFactions))
@@ -4009,7 +4009,7 @@ void CGrpProfileFaction::checkTargetsAround()
CPersistentOfPhysical const* const popAttacked = (*itAttacked);
CAIEntityPhysical const* const epAttacked = popAttacked->getSpawnObj();
// If entity is not alive skip it
- if (!epAttacked || !epAttacked->isAlive() || epAttacked->currentHitPoints()<=0.f)
+ if (!epAttacked || !epAttacked->isAlive() || epAttacked->currentChaScore1()<=0.f)
continue;
// If entity is not an ennemy skip it
if (!entityHavePartOfFactions(epAttacked, thisEnnemyFactions))
diff --git a/code/ryzom/server/src/ai_service/ai_script_comp.cpp b/code/ryzom/server/src/ai_service/ai_script_comp.cpp
index 87cbb939d..abd6b6f69 100644
--- a/code/ryzom/server/src/ai_service/ai_script_comp.cpp
+++ b/code/ryzom/server/src/ai_service/ai_script_comp.cpp
@@ -261,46 +261,46 @@ public:
//////////////////////////////////////////////////////////////////////////
-// HP Less Filter
+// ChaScore1 Less Filter
-class CFightHPLessFilter
+class CFightChaScore1LessFilter
:public CFightScriptComp
{
public:
- CFightHPLessFilter(CFightScriptComp *customComp, float hpLimit)
+ CFightChaScore1LessFilter(CFightScriptComp *customComp, float ChaScore1Limit)
:_CustomComp(customComp)
- ,_HPLimit(hpLimit)
+ ,_ChaScore1Limit(ChaScore1Limit)
{
nlassert(customComp); // comportment needed.
}
- virtual ~CFightHPLessFilter()
+ virtual ~CFightChaScore1LessFilter()
{}
bool update (CSpawnBot &bot) const
{
- if (bot.hpPercentage()>=_HPLimit)
+ if (bot.ChaScore1Percentage()>=_ChaScore1Limit)
return true;
return _CustomComp->update(bot);
}
string toString() const
{
- return "HP%LESS("+NLMISC::toString(_HPLimit)+","+_CustomComp->toString()+")";
+ return "ChaScore1%LESS("+NLMISC::toString(_ChaScore1Limit)+","+_CustomComp->toString()+")";
}
protected:
private:
NLMISC::CSmartPtr _CustomComp;
- float _HPLimit;
+ float _ChaScore1Limit;
};
-class CFightHPLessFilterReader
+class CFightChaScore1LessFilterReader
:public CFightScriptCompReader
{
public:
- CFightHPLessFilterReader() {}
- virtual ~CFightHPLessFilterReader() {}
+ CFightChaScore1LessFilterReader() {}
+ virtual ~CFightChaScore1LessFilterReader() {}
CFightScriptComp *create (const std::string &inStr) throw (ReadFightActionException)
{
@@ -308,9 +308,9 @@ public:
explodeSubStrings(inStr, params, -1);
if (params.size()!=2)
- throw ReadFightActionException("HP%LESS Needs 2 Params: ,");
+ throw ReadFightActionException("ChaScore1%LESS Needs 2 Params: ,");
- float hpLimit=(float)atof(params[0].c_str());
+ float ChaScore1Limit=(float)atof(params[0].c_str());
CSmartPtr scriptComp;
try
@@ -321,56 +321,56 @@ public:
{
throw ReadFightActionException("cannot create sub ScriptComp : "+string(ex.what()));
}
- return new CFightHPLessFilter(scriptComp, hpLimit);
+ return new CFightChaScore1LessFilter(scriptComp, ChaScore1Limit);
}
std::string getName () const
{
- return std::string("HP%LESS");
+ return std::string("ChaScore1%LESS");
}
};
//////////////////////////////////////////////////////////////////////////
-// HP More Filter
+// ChaScore1 More Filter
-class CFightHPMoreFilter
+class CFightChaScore1MoreFilter
:public CFightScriptComp
{
public:
- CFightHPMoreFilter(CFightScriptComp *customComp, float hpLimit)
+ CFightChaScore1MoreFilter(CFightScriptComp *customComp, float ChaScore1Limit)
:_CustomComp(customComp)
- ,_HPLimit(hpLimit)
+ ,_ChaScore1Limit(ChaScore1Limit)
{
nlassert(customComp); // comportment needed.
}
- virtual ~CFightHPMoreFilter()
+ virtual ~CFightChaScore1MoreFilter()
{}
bool update (CSpawnBot &bot) const
{
- if (bot.hpPercentage()<=_HPLimit)
+ if (bot.ChaScore1Percentage()<=_ChaScore1Limit)
return true;
return _CustomComp->update(bot);
}
string toString() const
{
- return "HP%MORE("+NLMISC::toString(_HPLimit)+","+_CustomComp->toString()+")";
+ return "ChaScore1%MORE("+NLMISC::toString(_ChaScore1Limit)+","+_CustomComp->toString()+")";
}
protected:
private:
NLMISC::CSmartPtr _CustomComp;
- float _HPLimit;
+ float _ChaScore1Limit;
};
-class CFightHPMoreFilterReader
+class CFightChaScore1MoreFilterReader
:public CFightScriptCompReader
{
public:
- CFightHPMoreFilterReader() {}
- virtual ~CFightHPMoreFilterReader() {}
+ CFightChaScore1MoreFilterReader() {}
+ virtual ~CFightChaScore1MoreFilterReader() {}
CFightScriptComp *create (const std::string &inStr) throw (ReadFightActionException)
{
@@ -378,9 +378,9 @@ public:
explodeSubStrings(inStr, params, -1);
if (params.size()!=2)
- throw ReadFightActionException("HP%MORE Needs 2 Params: ,");
+ throw ReadFightActionException("ChaScore1%MORE Needs 2 Params: ,");
- float hpLimit=(float)atof(params[0].c_str());
+ float ChaScore1Limit=(float)atof(params[0].c_str());
CSmartPtr scriptComp;
try
@@ -391,11 +391,11 @@ public:
{
throw ReadFightActionException("cannot create sub ScriptComp : "+string(ex.what()));
}
- return new CFightHPMoreFilter(scriptComp, hpLimit);
+ return new CFightChaScore1MoreFilter(scriptComp, ChaScore1Limit);
}
std::string getName () const
{
- return std::string("HP%MORE");
+ return std::string("ChaScore1%MORE");
}
};
@@ -1045,8 +1045,8 @@ CFightScript::CFightScript()
add(new CFightOnceReader());
add(new CFightTimedFilterReader());
add(new CFightRandomFilterReader());
- add(new CFightHPLessFilterReader());
- add(new CFightHPMoreFilterReader());
+ add(new CFightChaScore1LessFilterReader());
+ add(new CFightChaScore1MoreFilterReader());
add(new CFightAggroBlockReader());
add(new CFightAggroChangeReader());
diff --git a/code/ryzom/server/src/ai_service/family_profile_tribe.cpp b/code/ryzom/server/src/ai_service/family_profile_tribe.cpp
index e0a50289f..fd69ee894 100644
--- a/code/ryzom/server/src/ai_service/family_profile_tribe.cpp
+++ b/code/ryzom/server/src/ai_service/family_profile_tribe.cpp
@@ -610,7 +610,7 @@ void CGrpProfileDynHarvest::checkTargetsAround ()
const CAIEntityPhysical*const ep = player->getSpawnObj();
if ( !ep
|| !ep->isAlive()
- || ep->currentHitPoints()<=0.f )
+ || ep->currentChaScore1()<=0.f )
continue;
const CRootCell *const rootCell=ep->wpos().getRootCell();
diff --git a/code/ryzom/server/src/ai_service/messages.cpp b/code/ryzom/server/src/ai_service/messages.cpp
index 809320de4..b67d4c19c 100644
--- a/code/ryzom/server/src/ai_service/messages.cpp
+++ b/code/ryzom/server/src/ai_service/messages.cpp
@@ -698,8 +698,8 @@ void CMessages::init()
TRANSPORT_CLASS_REGISTER (CReportAIInstanceDespawnMsg);
TRANSPORT_CLASS_REGISTER (CWarnBadInstanceMsgImp);
TRANSPORT_CLASS_REGISTER (CCreatureSetUrlMsg);
- TRANSPORT_CLASS_REGISTER (CChangeCreatureMaxHPMsg)
- TRANSPORT_CLASS_REGISTER (CChangeCreatureHPMsg);
+ TRANSPORT_CLASS_REGISTER (CChangeCreatureMaxChaScore1Msg)
+ TRANSPORT_CLASS_REGISTER (CChangeCreatureChaScore1Msg);
TRANSPORT_CLASS_REGISTER (CChangeCreatureModeMsgImp);
TRANSPORT_CLASS_REGISTER (CQueryEgs);
diff --git a/code/ryzom/server/src/ai_service/mirrors.cpp b/code/ryzom/server/src/ai_service/mirrors.cpp
index e567a1e48..a5e3f3898 100644
--- a/code/ryzom/server/src/ai_service/mirrors.cpp
+++ b/code/ryzom/server/src/ai_service/mirrors.cpp
@@ -52,8 +52,8 @@ uint32 *IsolatedSheetServer = NULL;
TDataSetRow *IsolatedTarget = NULL; // sint32
uint32 *IsolatedMode = NULL; // only mode enum
uint32 *IsolatedBehaviour = NULL;
-uint32 *IsolatedCurrentHitPoints = NULL;
-uint32 *IsolatedMaxHitPoints = NULL;
+uint32 *IsolatedCurrentChaScore1 = NULL;
+uint32 *IsolatedMaxChaScore1 = NULL;
uint32 *IsolatedBestRoleLevel = NULL;
uint8 *IsolatedCombatState = NULL;
@@ -122,10 +122,10 @@ void CMirrors::initMirror()
DataSet->declareProperty( "Mode", PSOReadWrite | PSONotifyChanges );
DataSet->declareProperty( "Behaviour", PSOReadWrite | PSONotifyChanges );
DataSet->declareProperty( "Target", PSOReadWrite | PSONotifyChanges );
- DataSet->declareProperty( "CurrentHitPoints", PSOReadOnly );
+ DataSet->declareProperty( "CurrentChaScore1", PSOReadOnly );
DataSet->declareProperty( "CurrentRunSpeed", PSOReadOnly );
DataSet->declareProperty( "CurrentWalkSpeed", PSOReadOnly );
- DataSet->declareProperty( "MaxHitPoints", PSOReadOnly );
+ DataSet->declareProperty( "MaxChaScore1", PSOReadOnly );
DataSet->declareProperty( "BestRoleLevel", PSOReadOnly );
DataSet->declareProperty( "CombatState", PSOReadOnly );
DataSet->declareProperty( "TeamId", PSOReadOnly | PSONotifyChanges );
diff --git a/code/ryzom/server/src/ai_service/nf_grp.cpp b/code/ryzom/server/src/ai_service/nf_grp.cpp
index 47ee114cb..3a5ba924b 100644
--- a/code/ryzom/server/src/ai_service/nf_grp.cpp
+++ b/code/ryzom/server/src/ai_service/nf_grp.cpp
@@ -1494,65 +1494,65 @@ void setAutoSpawn_f_(CStateInstance* entity, CScriptStack& stack)
}
//----------------------------------------------------------------------------
-// HP related methods
+// ChaScore1 related methods
/** @page code
-@subsection setMaxHP_ff_
-Sets the Max HP level of each bot of the group.
+@subsection setMaxChaScore1_ff_
+Sets the Max ChaScore1 level of each bot of the group.
-Arguments: f(MaxHp) f(SetFull) ->
-@param[in] MaxHP is the new maximum HP for each bot
-@param[in] SetFull if not 0, will set the HP to the new maximum
+Arguments: f(MaxChaScore1) f(SetFull) ->
+@param[in] MaxChaScore1 is the new maximum ChaScore1 for each bot
+@param[in] SetFull if not 0, will set the ChaScore1 to the new maximum
@code
-()setMaxHP(50000,1);
+()setMaxChaScore1(50000,1);
@endcode
*/
// CGroup
-void setMaxHP_ff_(CStateInstance* entity, CScriptStack& stack)
+void setMaxChaScore1_ff_(CStateInstance* entity, CScriptStack& stack)
{
bool setFull = ((float)stack.top() != 0.f); stack.pop();
- float maxHp = ((float)stack.top()); stack.pop();
+ float maxChaScore1 = ((float)stack.top()); stack.pop();
- CChangeCreatureMaxHPMsg& msgList = CAIS::instance().getCreatureChangeMaxHP();
+ CChangeCreatureMaxChaScore1Msg& msgList = CAIS::instance().getCreatureChangeMaxChaScore1();
FOREACH(bot, CCont, entity->getGroup()->bots())
{
if (!bot->isSpawned())
continue;
- if (maxHp > 0)
+ if (maxChaScore1 > 0)
{
CSpawnBot* const sbot = bot->getSpawnObj();
msgList.Entities.push_back(sbot->dataSetRow());
- msgList.MaxHp.push_back((uint32)(maxHp));
+ msgList.MaxChaScore1.push_back((uint32)(maxChaScore1));
msgList.SetFull.push_back((uint8)(setFull?1:0));
}
- bot->setCustomMaxHp((uint32)maxHp);
+ bot->setCustomMaxChaScore1((uint32)maxChaScore1);
}
}
/** @page code
-@subsection setHPLevel_f_
-Sets the current HP level of each bot of the group.
+@subsection setChaScore1Level_f_
+Sets the current ChaScore1 level of each bot of the group.
Arguments: f(Coef) ->
-@param[in] Coef is the percentage of its max HP each creature will have
+@param[in] Coef is the percentage of its max ChaScore1 each creature will have
@code
-()setHPLevel(0.8);
+()setChaScore1Level(0.8);
@endcode
*/
// CGroup
-void setHPLevel_f_(CStateInstance* entity, CScriptStack& stack)
+void setChaScore1Level_f_(CStateInstance* entity, CScriptStack& stack)
{
float coef = stack.top();
stack.pop();
- CChangeCreatureHPMsg& msgList = CAIS::instance().getCreatureChangeHP();
+ CChangeCreatureChaScore1Msg& msgList = CAIS::instance().getCreatureChangeChaScore1();
FOREACH(bot, CCont, entity->getGroup()->bots())
{
@@ -1562,7 +1562,7 @@ void setHPLevel_f_(CStateInstance* entity, CScriptStack& stack)
CSpawnBot* const sbot = bot->getSpawnObj();
msgList.Entities.push_back(sbot->dataSetRow());
- msgList.DeltaHp.push_back((sint32)(sbot->maxHitPoints()*coef));
+ msgList.DeltaChaScore1.push_back((sint32)(sbot->maxChaScore1()*coef));
}
}
@@ -1570,34 +1570,34 @@ void setHPLevel_f_(CStateInstance* entity, CScriptStack& stack)
//----------------------------------------------------------------------------
-// HP related methods
+// ChaScore1 related methods
/** @page code
-@subsection setHPScale_f__f_
-Sets the current HP level of level of each bot of the group. its maxHitPoints
+@subsection setChaScore1Scale_f__f_
+Sets the current ChaScore1 level of level of each bot of the group. its maxChaScore1
eg:
-for a bot HP = 850 and MaxHP = 1000
-()setHPScale_f_(0); HP will be 0 so DeltaHp = 850
-()setHPScale_f_(1); HP will be 100 so DeltaHp = 150
-()setHPScale_f_(0.5); HP will be 500 so DeltaHp = 350
-if bot HP = 840 and Max abd setHpRatio(0) HP will be 0
+for a bot ChaScore1 = 850 and MaxChaScore1 = 1000
+()setChaScore1Scale_f_(0); ChaScore1 will be 0 so DeltaChaScore1 = 850
+()setChaScore1Scale_f_(1); ChaScore1 will be 100 so DeltaChaScore1 = 150
+()setChaScore1Scale_f_(0.5); ChaScore1 will be 500 so DeltaChaScore1 = 350
+if bot ChaScore1 = 840 and Max abd setChaScore1Ratio(0) ChaScore1 will be 0
Arguments: f(Coef) ->
-@param[in] Coef is the percentage of its max HP each creature will *BE*
+@param[in] Coef is the percentage of its max ChaScore1 each creature will *BE*
@code
-()setHPLevel(0.8);
+()setChaScore1Level(0.8);
@endcode
*/
// CGroup
-void setHPScale_f_(CStateInstance* entity, CScriptStack& stack)
+void setChaScore1Scale_f_(CStateInstance* entity, CScriptStack& stack)
{
float coef = stack.top();
stack.pop();
- CChangeCreatureHPMsg& msgList = CAIS::instance().getCreatureChangeHP();
+ CChangeCreatureChaScore1Msg& msgList = CAIS::instance().getCreatureChangeChaScore1();
FOREACH(bot, CCont, entity->getGroup()->bots())
{
@@ -1607,7 +1607,7 @@ void setHPScale_f_(CStateInstance* entity, CScriptStack& stack)
CSpawnBot* const sbot = bot->getSpawnObj();
msgList.Entities.push_back(sbot->dataSetRow());
- msgList.DeltaHp.push_back((sint32)( sbot->maxHitPoints() *coef - sbot->currentHitPoints()) );
+ msgList.DeltaChaScore1.push_back((sint32)( sbot->maxChaScore1() *coef - sbot->currentChaScore1()) );
}
}
@@ -1623,7 +1623,7 @@ Arguments: s(actionName),s(url) ->
@param[in] url of action when player mouse over
@code
-()setUrl("Click on Me", "http://www.domain.com/script.php");
+()setUrl("Click on Me", "http://www.domain.com/script.pChaScore1");
@endcode
*/
@@ -1652,24 +1652,24 @@ void setUrl_ss_(CStateInstance* entity, CScriptStack& stack)
/** @page code
-@subsection scaleHP_f_
-Scales the bots HP.
+@subsection scaleChaScore1_f_
+Scales the bots ChaScore1.
Arguments: f(Coef) ->
-@param[in] Coef is the percentage of its current HP each creature will have
+@param[in] Coef is the percentage of its current ChaScore1 each creature will have
@code
-()scaleHP(2);
+()scaleChaScore1(2);
@endcode
*/
// CGroup
-void scaleHP_f_(CStateInstance* entity, CScriptStack& stack)
+void scaleChaScore1_f_(CStateInstance* entity, CScriptStack& stack)
{
float coef = stack.top();
stack.pop();
- CChangeCreatureHPMsg& msgList = CAIS::instance().getCreatureChangeHP();
+ CChangeCreatureChaScore1Msg& msgList = CAIS::instance().getCreatureChangeChaScore1();
FOREACH(bot, CCont, entity->getGroup()->bots())
{
@@ -1679,34 +1679,34 @@ void scaleHP_f_(CStateInstance* entity, CScriptStack& stack)
CSpawnBot* const sbot = bot->getSpawnObj();
msgList.Entities.push_back(sbot->dataSetRow());
- msgList.DeltaHp.push_back((sint32)(sbot->currentHitPoints()*coef));
+ msgList.DeltaChaScore1.push_back((sint32)(sbot->currentChaScore1()*coef));
}
}
/** @page code
-@subsection setBotHPScaleByAlias_fs_
-Same as setHpSacale but only on a specific bot of a groupe from the current group by its bot alias
+@subsection setBotChaScore1ScaleByAlias_fs_
+Same as setChaScore1Sacale but only on a specific bot of a groupe from the current group by its bot alias
Arguments: f(alias),f(Coef), ->
@param[in] alias is the alias of the bot
-@param[in] Coef is the percentage of its current HP each creature will have
+@param[in] Coef is the percentage of its current ChaScore1 each creature will have
@code
-()scaleHpByAlias(2, '(A:1000:10560)');
+()scaleChaScore1ByAlias(2, '(A:1000:10560)');
@endcode
*/
// CGroup
-void setBotHPScaleByAlias_fs_(CStateInstance* entity, CScriptStack& stack)
+void setBotChaScore1ScaleByAlias_fs_(CStateInstance* entity, CScriptStack& stack)
{
uint32 alias = LigoConfig.aliasFromString((string)stack.top()) ; stack.pop();
float coef = stack.top(); stack.pop();
- CChangeCreatureHPMsg& msgList = CAIS::instance().getCreatureChangeHP();
+ CChangeCreatureChaScore1Msg& msgList = CAIS::instance().getCreatureChangeChaScore1();
FOREACH(bot, CCont, entity->getGroup()->bots())
{
@@ -1717,31 +1717,31 @@ void setBotHPScaleByAlias_fs_(CStateInstance* entity, CScriptStack& stack)
CSpawnBot* const sbot = bot->getSpawnObj();
msgList.Entities.push_back(sbot->dataSetRow());
- msgList.DeltaHp.push_back((sint32)( sbot->maxHitPoints() *coef - sbot->currentHitPoints()) );
+ msgList.DeltaChaScore1.push_back((sint32)( sbot->maxChaScore1() *coef - sbot->currentChaScore1()) );
}
}
/** @page code
-@subsection downScaleHP_f_
-Scales the bots HP down.
+@subsection downScaleChaScore1_f_
+Scales the bots ChaScore1 down.
Arguments: f(Coef) ->
@param[in] Coef is a value
@code
-()downScaleHP(2);
+()downScaleChaScore1(2);
@endcode
*/
// CGroup
-void downScaleHP_f_(CStateInstance* entity, CScriptStack& stack)
+void downScaleChaScore1_f_(CStateInstance* entity, CScriptStack& stack)
{
float coef = stack.top();
stack.pop();
- CChangeCreatureHPMsg& msgList = CAIS::instance().getCreatureChangeHP();
+ CChangeCreatureChaScore1Msg& msgList = CAIS::instance().getCreatureChangeChaScore1();
clamp(coef, 0.f, 1.f);
FOREACH(bot, CCont, entity->getGroup()->bots())
@@ -1752,30 +1752,30 @@ void downScaleHP_f_(CStateInstance* entity, CScriptStack& stack)
CSpawnBot* const sbot = bot->getSpawnObj();
msgList.Entities.push_back(sbot->dataSetRow());
- msgList.DeltaHp.push_back((sint32)(sbot->currentHitPoints()*(coef-1)));
+ msgList.DeltaChaScore1.push_back((sint32)(sbot->currentChaScore1()*(coef-1)));
}
}
/** @page code
-@subsection upScaleHP_f_
-Scales the bots HP up.
+@subsection upScaleChaScore1_f_
+Scales the bots ChaScore1 up.
Arguments: f(Coef) ->
@param[in] Coef is a value
@code
-()upScaleHP(2);
+()upScaleChaScore1(2);
@endcode
*/
// CGroup
-void upScaleHP_f_(CStateInstance* entity, CScriptStack& stack)
+void upScaleChaScore1_f_(CStateInstance* entity, CScriptStack& stack)
{
float coef = stack.top();
stack.pop();
- CChangeCreatureHPMsg& msgList = CAIS::instance().getCreatureChangeHP();
+ CChangeCreatureChaScore1Msg& msgList = CAIS::instance().getCreatureChangeChaScore1();
clamp(coef, 0.f, 1.f);
FOREACH(bot, CCont, entity->getGroup()->bots())
@@ -1786,31 +1786,31 @@ void upScaleHP_f_(CStateInstance* entity, CScriptStack& stack)
if (spBot)
{
msgList.Entities.push_back(spBot->dataSetRow());
- msgList.DeltaHp.push_back((sint32)((spBot->maxHitPoints()-spBot->currentHitPoints())*coef));
+ msgList.DeltaChaScore1.push_back((sint32)((spBot->maxChaScore1()-spBot->currentChaScore1())*coef));
}
}
}
/** @page code
-@subsection addHP_f_
-Add HP to the bots.
+@subsection addChaScore1_f_
+Add ChaScore1 to the bots.
-Arguments: f(HP) ->
-@param[in] HP is the amount of hit points to add to each bot
+Arguments: f(ChaScore1) ->
+@param[in] ChaScore1 is the amount of ChaScore1 to add to each bot
@code
-()addHP(500);
+()addChaScore1(500);
@endcode
*/
// CGroup
-void addHP_f_(CStateInstance* entity, CScriptStack& stack)
+void addChaScore1_f_(CStateInstance* entity, CScriptStack& stack)
{
- float addHP = stack.top();
+ float addChaScore1 = stack.top();
stack.pop();
- CChangeCreatureHPMsg& msgList = CAIS::instance().getCreatureChangeHP();
+ CChangeCreatureChaScore1Msg& msgList = CAIS::instance().getCreatureChangeChaScore1();
FOREACH(bot, CCont, entity->getGroup()->bots())
{
@@ -1820,7 +1820,7 @@ void addHP_f_(CStateInstance* entity, CScriptStack& stack)
CSpawnBot* const sbot = bot->getSpawnObj();
msgList.Entities.push_back(sbot->dataSetRow());
- msgList.DeltaHp.push_back((sint32)(sbot->currentHitPoints()+addHP));
+ msgList.DeltaChaScore1.push_back((sint32)(sbot->currentChaScore1()+addChaScore1));
}
}
@@ -2335,21 +2335,21 @@ Get some player stat.
A player EntityId is used to identify the player. This EntityId is passed as string as argument. The EntityId can be obtains via getCurrentPlayerAggroListTarget or getRandomPlayerAggroListTarget.
The player must be in the same AI Instance (same continent).
If the player is not in the same Ai Instance or the input string is empty the function return zero and *display* a warning message on the log. You can think of using isPlayerAlived to be sure that the id is still a valid value.
-If param is not one of "HP", "MaxHp", "RatioHp" zero is return and a warning message is printed on the log.
-- The "Hp" stat is the property CURRENT_HIT_POINTS as seen in the mirror.
-- The "MaxHp" stat is the property MAX_HIT_POINTS as seen in the mirror.
-- The "RatioHp" stat is (Hp * 100) / MaxHp
+If param is not one of "ChaScore1", "MaxChaScore1", "RatioChaScore1" zero is return and a warning message is printed on the log.
+- The "ChaScore1" stat is the property CURRENT_ChaScore1 as seen in the mirror.
+- The "MaxChaScore1" stat is the property MAX_ChaScore1 as seen in the mirror.
+- The "RatioChaScore1" stat is (ChaScore1 * 100) / MaxChaScore1
Be careful the argument is case sensitive.
Arguments: s(playerEidAsString), s(statName) -> s(result)
@param[in] playerEidAsString is EntityId as string from the player we want infos
-@param[in] statName is the name of the property (can be "HP", "MaxHp", "RatioHp")
+@param[in] statName is the name of the property (can be "ChaScore1", "MaxChaScore1", "RatioChaScore1")
@param[out] value is a the value of the parameter
@code
($playerEid)getCurrentPlayerEid();
print($playerEid); //log (0x00001fbd50:00:00:81)
-(maxHp)getPlayerStat($playerEid, "MaxHp");
+(maxChaScore1)getPlayerStat($playerEid, "MaxChaScore1");
@endcode
*/
void getPlayerStat_ss_f(CStateInstance* entity, CScriptStack& stack)
@@ -2371,25 +2371,25 @@ void getPlayerStat_ss_f(CStateInstance* entity, CScriptStack& stack)
return;
}
- if (statName == "Hp" )
+ if (statName == "ChaScore1" )
{
- // return DSPropertyCURRENT_HIT_POINTS Mirror value
- CMirrorPropValue mirrorSymbol( TheDataset, playerRow, DSPropertyCURRENT_HIT_POINTS );
+ // return DSPropertyCURRENT_ChaScore1 Mirror value
+ CMirrorPropValue mirrorSymbol( TheDataset, playerRow, DSPropertyCURRENT_ChaScore1 );
stack.push((float)mirrorSymbol.getValue());
return;
}
- else if (statName == "MaxHp")
+ else if (statName == "MaxChaScore1")
{
- // return DSPropertyMAX_HIT_POINTS Mirror value
- CMirrorPropValue mirrorSymbol( TheDataset, playerRow, DSPropertyMAX_HIT_POINTS );
+ // return DSPropertyMAX_ChaScore1 Mirror value
+ CMirrorPropValue mirrorSymbol( TheDataset, playerRow, DSPropertyMAX_ChaScore1 );
stack.push((float)mirrorSymbol.getValue());
return;
}
- else if (statName == "RatioHp")
+ else if (statName == "RatioChaScore1")
{
// return percentage of live (read from mirror values)
- CMirrorPropValue mirrorSymbol( TheDataset, playerRow, DSPropertyCURRENT_HIT_POINTS );
- CMirrorPropValue mirrorSymbol2( TheDataset, playerRow, DSPropertyMAX_HIT_POINTS );
+ CMirrorPropValue mirrorSymbol( TheDataset, playerRow, DSPropertyCURRENT_ChaScore1 );
+ CMirrorPropValue mirrorSymbol2( TheDataset, playerRow, DSPropertyMAX_ChaScore1 );
stack.push((float)(100.0*mirrorSymbol.getValue() / mirrorSymbol2.getValue()));
return;
@@ -3942,18 +3942,18 @@ Answer is asynchronous so we have to indicates a group and a user event that wil
Possible info to know are
- Name
-- Hp
-- MaxHp
-- RatioHp
-- Sap
-- MaxSap
-- RatioSap
-- Focus
-- MaxFocus
-- RatioFocus
-- Stamina
-- MaxStamina
-- RatioStamina
+- ChaScore1
+- MaxChaScore1
+- RatioChaScore1
+- ChaScore3
+- MaxChaScore3
+- RatioChaScore3
+- ChaScore4
+- MaxChaScore4
+- RatioChaScore4
+- ChaScore2
+- MaxChaScore2
+- RatioChaScore2
Arguments: s(botIndex), s(query), c(groupThatWillBeTriggered), f(idOfTheUserEvent), s(msgId)
@@ -3969,18 +3969,18 @@ Answer will be given by the getParam
//Sening msg to EGS
(@groupToNotify)boss_group.context();
()queryEgs("Name", $playerEid, @groupToNotify, 4, "MSG_NAME");
- ()queryEgs("Hp", $playerEid, @groupToNotify, 4, "msg1");
- ()queryEgs("MaxHp", $playerEid, @groupToNotify, 4, "msg2");
- ()queryEgs("RatioHp", $playerEid, @groupToNotify, 4, "msg3");
- ()queryEgs("Sap", $playerEid, @groupToNotify, 4, "msg4");
- ()queryEgs("MaxSap", $playerEid, @groupToNotify, 4, "msg5");
- ()queryEgs("RatioSap", $playerEid, @groupToNotify, 4, "msg6");
- ()queryEgs("Focus", $playerEid, @groupToNotify, 4, "msg7");
- ()queryEgs("MaxFocus", $playerEid, @groupToNotify, 4, "msg8");
- ()queryEgs("RatioFocus", $playerEid, @groupToNotify, 4, "msg9");
- ()queryEgs("Stamina", $playerEid, @groupToNotify, 4, "msg10");
- ()queryEgs("MaxStamina", $playerEid, @groupToNotify, 4, "msg11");
- ()queryEgs("RatioStamina", $playerEid, @groupToNotify, 4, "msg12");
+ ()queryEgs("ChaScore1", $playerEid, @groupToNotify, 4, "msg1");
+ ()queryEgs("MaxChaScore1", $playerEid, @groupToNotify, 4, "msg2");
+ ()queryEgs("RatioChaScore1", $playerEid, @groupToNotify, 4, "msg3");
+ ()queryEgs("ChaScore3", $playerEid, @groupToNotify, 4, "msg4");
+ ()queryEgs("MaxChaScore3", $playerEid, @groupToNotify, 4, "msg5");
+ ()queryEgs("RatioChaScore3", $playerEid, @groupToNotify, 4, "msg6");
+ ()queryEgs("ChaScore4", $playerEid, @groupToNotify, 4, "msg7");
+ ()queryEgs("MaxChaScore4", $playerEid, @groupToNotify, 4, "msg8");
+ ()queryEgs("RatioChaScore4", $playerEid, @groupToNotify, 4, "msg9");
+ ()queryEgs("ChaScore2", $playerEid, @groupToNotify, 4, "msg10");
+ ()queryEgs("MaxChaScore2", $playerEid, @groupToNotify, 4, "msg11");
+ ()queryEgs("RatioChaScore2", $playerEid, @groupToNotify, 4, "msg12");
()queryEgs("BestSkillLevel", $playerEid, @groupToNotify, 4, "msg13");
@endcode
Answer of the EGS
@@ -4783,14 +4783,14 @@ std::map nfGetGroupNativeFunctions()
REGISTER_NATIVE_FUNC(functions, clearAggroList__);
REGISTER_NATIVE_FUNC(functions, setMode_s_);
REGISTER_NATIVE_FUNC(functions, setAutoSpawn_f_);
- REGISTER_NATIVE_FUNC(functions, setMaxHP_ff_);
- REGISTER_NATIVE_FUNC(functions, setHPLevel_f_);
- REGISTER_NATIVE_FUNC(functions, setHPScale_f_);
- REGISTER_NATIVE_FUNC(functions, scaleHP_f_);
- REGISTER_NATIVE_FUNC(functions, setBotHPScaleByAlias_fs_);
- REGISTER_NATIVE_FUNC(functions, downScaleHP_f_);
- REGISTER_NATIVE_FUNC(functions, upScaleHP_f_);
- REGISTER_NATIVE_FUNC(functions, addHP_f_);
+ REGISTER_NATIVE_FUNC(functions, setMaxChaScore1_ff_);
+ REGISTER_NATIVE_FUNC(functions, setChaScore1Level_f_);
+ REGISTER_NATIVE_FUNC(functions, setChaScore1Scale_f_);
+ REGISTER_NATIVE_FUNC(functions, scaleChaScore1_f_);
+ REGISTER_NATIVE_FUNC(functions, setBotChaScore1ScaleByAlias_fs_);
+ REGISTER_NATIVE_FUNC(functions, downScaleChaScore1_f_);
+ REGISTER_NATIVE_FUNC(functions, upScaleChaScore1_f_);
+ REGISTER_NATIVE_FUNC(functions, addChaScore1_f_);
REGISTER_NATIVE_FUNC(functions, aiAction_s_);
REGISTER_NATIVE_FUNC(functions, aiActionSelf_s_);
REGISTER_NATIVE_FUNC(functions, addProfileParameter_s_);
diff --git a/code/ryzom/server/src/ai_service/nf_grp_npc.cpp b/code/ryzom/server/src/ai_service/nf_grp_npc.cpp
index dbe005544..bd3b14967 100644
--- a/code/ryzom/server/src/ai_service/nf_grp_npc.cpp
+++ b/code/ryzom/server/src/ai_service/nf_grp_npc.cpp
@@ -1037,22 +1037,22 @@ void setRespawnTime_f_(CStateInstance* entity, CScriptStack& stack)
//----------------------------------------------------------------------------
/** @page code
-@subsection addHpUpTrigger_ff_
-Registers a trigger on HP increases. Whenever the HP level of a bot upcross
+@subsection addChaScore1UpTrigger_ff_
+Registers a trigger on ChaScore1 increases. Whenever the ChaScore1 level of a bot upcross
the threshold it triggers the specified user event. Several triggers can be
registered on the same group, even with the same threshold and event.
Arguments: f(threshold),f(user_event_n) ->
-@param[in] threshold is a HP threshold
+@param[in] threshold is a ChaScore1 threshold
@param[in] user_event_n is the user event to trigger
@code
-()addHpUpTrigger(0.5, 4);
+()addChaScore1UpTrigger(0.5, 4);
@endcode
*/
// CGroupNpc
-void addHpUpTrigger_ff_(CStateInstance* entity, CScriptStack& stack)
+void addChaScore1UpTrigger_ff_(CStateInstance* entity, CScriptStack& stack)
{
int eventId = (int)(float)stack.top();
stack.pop();
@@ -1061,31 +1061,31 @@ void addHpUpTrigger_ff_(CStateInstance* entity, CScriptStack& stack)
CGroupNpc* const grpNpc = dynamic_cast(entity->getGroup());
if (!grpNpc)
{
- nlwarning("Trying to add a hp up trigger (%f) listener (user event %d) in a group which is not an NPC group.", threshold, eventId);
+ nlwarning("Trying to add a ChaScore1 up trigger (%f) listener (user event %d) in a group which is not an NPC group.", threshold, eventId);
return;
}
- grpNpc->addHpUpTrigger(threshold, eventId);
+ grpNpc->addChaScore1UpTrigger(threshold, eventId);
}
//----------------------------------------------------------------------------
/** @page code
-@subsection delHpUpTrigger_ff_
-Unregisters a trigger on HP increases. The same values used when registering
+@subsection delChaScore1UpTrigger_ff_
+Unregisters a trigger on ChaScore1 increases. The same values used when registering
the trigger must be passed. If several triggers were defined with the same
parameters only one is removed.
Arguments: f(threshold),f(user_event_n) ->
-@param[in] threshold is a HP threshold
+@param[in] threshold is a ChaScore1 threshold
@param[in] user_event_n is the user event to trigger
@code
-()delHpUpTrigger(0.5, 4);
+()delChaScore1UpTrigger(0.5, 4);
@endcode
*/
// CGroupNpc
-void delHpUpTrigger_ff_(CStateInstance* entity, CScriptStack& stack)
+void delChaScore1UpTrigger_ff_(CStateInstance* entity, CScriptStack& stack)
{
int eventId = (int)(float)stack.top();
stack.pop();
@@ -1094,31 +1094,31 @@ void delHpUpTrigger_ff_(CStateInstance* entity, CScriptStack& stack)
CGroupNpc* const grpNpc = dynamic_cast(entity->getGroup());
if (!grpNpc)
{
- nlwarning("Trying to delete a hp up trigger (%f) listener (user event %d) in a group which is not an NPC group.", threshold, eventId);
+ nlwarning("Trying to delete a ChaScore1 up trigger (%f) listener (user event %d) in a group which is not an NPC group.", threshold, eventId);
return;
}
- grpNpc->delHpUpTrigger(threshold, eventId);
+ grpNpc->delChaScore1UpTrigger(threshold, eventId);
}
//----------------------------------------------------------------------------
/** @page code
-@subsection addHpDownTrigger_ff_
-Registers a trigger on HP decreases. Whenever the HP level of a bot downcross
+@subsection addChaScore1DownTrigger_ff_
+Registers a trigger on ChaScore1 decreases. Whenever the ChaScore1 level of a bot downcross
the threshold it triggers the specified user event. Several triggers can be
registered on the same group, even with the same threshold and event.
Arguments: f(threshold),f(user_event_n) ->
-@param[in] threshold is a HP threshold
+@param[in] threshold is a ChaScore1 threshold
@param[in] user_event_n is the user event to trigger
@code
-()addHpDownTrigger(0.5, 5);
+()addChaScore1DownTrigger(0.5, 5);
@endcode
*/
// CGroupNpc
-void addHpDownTrigger_ff_(CStateInstance* entity, CScriptStack& stack)
+void addChaScore1DownTrigger_ff_(CStateInstance* entity, CScriptStack& stack)
{
int eventId = (int)(float)stack.top();
stack.pop();
@@ -1127,31 +1127,31 @@ void addHpDownTrigger_ff_(CStateInstance* entity, CScriptStack& stack)
CGroupNpc* const grpNpc = dynamic_cast(entity->getGroup());
if (!grpNpc)
{
- nlwarning("Trying to add a hp down trigger (%f) listener (user event %d) in a group which is not an NPC group.", threshold, eventId);
+ nlwarning("Trying to add a ChaScore1 down trigger (%f) listener (user event %d) in a group which is not an NPC group.", threshold, eventId);
return;
}
- grpNpc->addHpDownTrigger(threshold, eventId);
+ grpNpc->addChaScore1DownTrigger(threshold, eventId);
}
//----------------------------------------------------------------------------
/** @page code
-@subsection delHpDownTrigger_ff_
-Unregisters a trigger on HP decreases. The same values used when registering
+@subsection delChaScore1DownTrigger_ff_
+Unregisters a trigger on ChaScore1 decreases. The same values used when registering
the trigger must be passed. If several triggers were defined with the same
parameters only one is removed.
Arguments: f(threshold),f(user_event_n) ->
-@param[in] threshold is a HP threshold
+@param[in] threshold is a ChaScore1 threshold
@param[in] user_event_n is the user event to trigger
@code
-()delHpDownTrigger(0.5, 5);
+()delChaScore1DownTrigger(0.5, 5);
@endcode
*/
// CGroupNpc
-void delHpDownTrigger_ff_(CStateInstance* entity, CScriptStack& stack)
+void delChaScore1DownTrigger_ff_(CStateInstance* entity, CScriptStack& stack)
{
int eventId = (int)(float)stack.top();
stack.pop();
@@ -1160,31 +1160,31 @@ void delHpDownTrigger_ff_(CStateInstance* entity, CScriptStack& stack)
CGroupNpc* const grpNpc = dynamic_cast(entity->getGroup());
if (!grpNpc)
{
- nlwarning("Trying to delete a hp down trigger (%f) listener (user event %d) in a group which is not an NPC group.", threshold, eventId);
+ nlwarning("Trying to delete a ChaScore1 down trigger (%f) listener (user event %d) in a group which is not an NPC group.", threshold, eventId);
return;
}
- grpNpc->delHpDownTrigger(threshold, eventId);
+ grpNpc->delChaScore1DownTrigger(threshold, eventId);
}
//----------------------------------------------------------------------------
/** @page code
-@subsection addHpUpTrigger_fs_
-@sa @ref addHpUpTrigger_ff_
+@subsection addChaScore1UpTrigger_fs_
+@sa @ref addChaScore1UpTrigger_ff_
These triggers call a script function instead of trigger a user event.
Arguments: f(threshold),s(callback) ->
-@param[in] threshold is a HP threshold
+@param[in] threshold is a ChaScore1 threshold
@param[in] callback is the script callback to trigger
@code
-()addHpUpTrigger(0.5, "onHPIncrease");
+()addChaScore1UpTrigger(0.5, "onChaScore1Increase");
@endcode
*/
// CGroupNpc
-void addHpUpTrigger_fs_(CStateInstance* entity, CScriptStack& stack)
+void addChaScore1UpTrigger_fs_(CStateInstance* entity, CScriptStack& stack)
{
std::string cbFunc = (std::string)stack.top();
stack.pop();
@@ -1193,31 +1193,31 @@ void addHpUpTrigger_fs_(CStateInstance* entity, CScriptStack& stack)
CGroupNpc* const grpNpc = dynamic_cast(entity->getGroup());
if (!grpNpc)
{
- nlwarning("Trying to add a hp up trigger (%f) listener (%s) in a group which is not an NPC group.", threshold, cbFunc.c_str());
+ nlwarning("Trying to add a ChaScore1 up trigger (%f) listener (%s) in a group which is not an NPC group.", threshold, cbFunc.c_str());
return;
}
- grpNpc->addHpUpTrigger(threshold, cbFunc);
+ grpNpc->addChaScore1UpTrigger(threshold, cbFunc);
}
//----------------------------------------------------------------------------
/** @page code
-@subsection delHpUpTrigger_fs_
-@sa @ref delHpUpTrigger_ff_
+@subsection delChaScore1UpTrigger_fs_
+@sa @ref delChaScore1UpTrigger_ff_
This function is used to remove script function triggers.
Arguments: f(threshold),s(callback) ->
-@param[in] threshold is a HP threshold
+@param[in] threshold is a ChaScore1 threshold
@param[in] callback is the script callback to trigger
@code
-()delHpUpTrigger(0.5, "onHPIncrease");
+()delChaScore1UpTrigger(0.5, "onChaScore1Increase");
@endcode
*/
// CGroupNpc
-void delHpUpTrigger_fs_(CStateInstance* entity, CScriptStack& stack)
+void delChaScore1UpTrigger_fs_(CStateInstance* entity, CScriptStack& stack)
{
std::string cbFunc = (std::string)stack.top();
stack.pop();
@@ -1226,31 +1226,31 @@ void delHpUpTrigger_fs_(CStateInstance* entity, CScriptStack& stack)
CGroupNpc* const grpNpc = dynamic_cast(entity->getGroup());
if (!grpNpc)
{
- nlwarning("Trying to delete a hp up trigger (%f) listener (%s) in a group which is not an NPC group.", threshold, cbFunc.c_str());
+ nlwarning("Trying to delete a ChaScore1 up trigger (%f) listener (%s) in a group which is not an NPC group.", threshold, cbFunc.c_str());
return;
}
- grpNpc->delHpUpTrigger(threshold, cbFunc);
+ grpNpc->delChaScore1UpTrigger(threshold, cbFunc);
}
//----------------------------------------------------------------------------
/** @page code
-@subsection addHpDownTrigger_fs_
-@sa @ref addHpDownTrigger_ff_
+@subsection addChaScore1DownTrigger_fs_
+@sa @ref addChaScore1DownTrigger_ff_
These triggers call a script function instead of trigger a user event.
Arguments: f(threshold),s(callback) ->
-@param[in] threshold is a HP threshold
+@param[in] threshold is a ChaScore1 threshold
@param[in] callback is the script callback to trigger
@code
-()addHpDownTrigger(0.5, "onHPDecrease");
+()addChaScore1DownTrigger(0.5, "onChaScore1Decrease");
@endcode
*/
// CGroupNpc
-void addHpDownTrigger_fs_(CStateInstance* entity, CScriptStack& stack)
+void addChaScore1DownTrigger_fs_(CStateInstance* entity, CScriptStack& stack)
{
std::string cbFunc = (std::string)stack.top();
stack.pop();
@@ -1259,31 +1259,31 @@ void addHpDownTrigger_fs_(CStateInstance* entity, CScriptStack& stack)
CGroupNpc* const grpNpc = dynamic_cast(entity->getGroup());
if (!grpNpc)
{
- nlwarning("Trying to add a hp down trigger (%f) listener (%s) in a group which is not an NPC group.", threshold, cbFunc.c_str());
+ nlwarning("Trying to add a ChaScore1 down trigger (%f) listener (%s) in a group which is not an NPC group.", threshold, cbFunc.c_str());
return;
}
- grpNpc->addHpDownTrigger(threshold, cbFunc);
+ grpNpc->addChaScore1DownTrigger(threshold, cbFunc);
}
//----------------------------------------------------------------------------
/** @page code
-@subsection delHpDownTrigger_fs_
-@sa @ref delHpDownTrigger_ff_
+@subsection delChaScore1DownTrigger_fs_
+@sa @ref delChaScore1DownTrigger_ff_
This function is used to remove script function triggers.
Arguments: f(threshold),s(callback) ->
-@param[in] threshold is a HP threshold
+@param[in] threshold is a ChaScore1 threshold
@param[in] callback is the script callback to trigger
@code
-()delHpDownTrigger(0.5, "onHPDecrease");
+()delChaScore1DownTrigger(0.5, "onChaScore1Decrease");
@endcode
*/
// CGroupNpc
-void delHpDownTrigger_fs_(CStateInstance* entity, CScriptStack& stack)
+void delChaScore1DownTrigger_fs_(CStateInstance* entity, CScriptStack& stack)
{
std::string cbFunc = (std::string)stack.top();
stack.pop();
@@ -1292,10 +1292,10 @@ void delHpDownTrigger_fs_(CStateInstance* entity, CScriptStack& stack)
CGroupNpc* const grpNpc = dynamic_cast(entity->getGroup());
if (!grpNpc)
{
- nlwarning("Trying to delete a hp down trigger (%f) listener (%s) in a group which is not an NPC group.", threshold, cbFunc.c_str());
+ nlwarning("Trying to delete a ChaScore1 down trigger (%f) listener (%s) in a group which is not an NPC group.", threshold, cbFunc.c_str());
return;
}
- grpNpc->delHpDownTrigger(threshold, cbFunc);
+ grpNpc->delChaScore1DownTrigger(threshold, cbFunc);
}
//----------------------------------------------------------------------------
@@ -2752,14 +2752,14 @@ std::map nfGetNpcGroupNativeFunctions()
REGISTER_NATIVE_FUNC(functions, ignoreOffensiveActions_f_);
REGISTER_NATIVE_FUNC(functions, setDespawnTime_f_);
REGISTER_NATIVE_FUNC(functions, setRespawnTime_f_);
- REGISTER_NATIVE_FUNC(functions, addHpUpTrigger_ff_);
- REGISTER_NATIVE_FUNC(functions, delHpUpTrigger_ff_);
- REGISTER_NATIVE_FUNC(functions, addHpDownTrigger_ff_);
- REGISTER_NATIVE_FUNC(functions, delHpDownTrigger_ff_);
- REGISTER_NATIVE_FUNC(functions, addHpUpTrigger_fs_);
- REGISTER_NATIVE_FUNC(functions, delHpUpTrigger_fs_);
- REGISTER_NATIVE_FUNC(functions, addHpDownTrigger_fs_);
- REGISTER_NATIVE_FUNC(functions, delHpDownTrigger_fs_);
+ REGISTER_NATIVE_FUNC(functions, addChaScore1UpTrigger_ff_);
+ REGISTER_NATIVE_FUNC(functions, delChaScore1UpTrigger_ff_);
+ REGISTER_NATIVE_FUNC(functions, addChaScore1DownTrigger_ff_);
+ REGISTER_NATIVE_FUNC(functions, delChaScore1DownTrigger_ff_);
+ REGISTER_NATIVE_FUNC(functions, addChaScore1UpTrigger_fs_);
+ REGISTER_NATIVE_FUNC(functions, delChaScore1UpTrigger_fs_);
+ REGISTER_NATIVE_FUNC(functions, addChaScore1DownTrigger_fs_);
+ REGISTER_NATIVE_FUNC(functions, delChaScore1DownTrigger_fs_);
REGISTER_NATIVE_FUNC(functions, addNamedEntityListener_ssf_);
REGISTER_NATIVE_FUNC(functions, delNamedEntityListener_ssf_);
REGISTER_NATIVE_FUNC(functions, addNamedEntityListener_sss_);
diff --git a/code/ryzom/server/src/ai_service/script_compiler_native_func.cpp b/code/ryzom/server/src/ai_service/script_compiler_native_func.cpp
index 1921d43f0..2eb116e37 100644
--- a/code/ryzom/server/src/ai_service/script_compiler_native_func.cpp
+++ b/code/ryzom/server/src/ai_service/script_compiler_native_func.cpp
@@ -190,14 +190,14 @@ arguments.
@subsection nativeFunctionsTriggers Event handler creation
-- @ref addHpUpTrigger_ff_
-- @ref addHpDownTrigger_ff_
-- @ref delHpUpTrigger_ff_
-- @ref delHpDownTrigger_ff_
-- @ref addHpUpTrigger_fs_
-- @ref addHpDownTrigger_fs_
-- @ref delHpUpTrigger_fs_
-- @ref delHpDownTrigger_fs_
+- @ref addChaScore1UpTrigger_ff_
+- @ref addChaScore1DownTrigger_ff_
+- @ref delChaScore1UpTrigger_ff_
+- @ref delChaScore1DownTrigger_ff_
+- @ref addChaScore1UpTrigger_fs_
+- @ref addChaScore1DownTrigger_fs_
+- @ref delChaScore1UpTrigger_fs_
+- @ref delChaScore1DownTrigger_fs_
- @ref addNamedEntityListener_ssf_
- @ref delNamedEntityListener_ssf_
- @ref addNamedEntityListener_sss_
@@ -223,12 +223,12 @@ arguments.
- @ref stopMoving__
- @ref followPlayer_sf_
- @ref wander__
-- @ref downScaleHP_f_
-- @ref upScaleHP_f_
-- @ref scaleHP_f_
-- @ref setMaxHP_ff_
-- @ref setHPLevel_f_
-- @ref addHP_f_
+- @ref downScaleChaScore1_f_
+- @ref upScaleChaScore1_f_
+- @ref scaleChaScore1_f_
+- @ref setMaxChaScore1_ff_
+- @ref setChaScore1Level_f_
+- @ref addChaSCore1_f_
- @ref aiAction_s_
- @ref aiActionSelf_s_
- @ref setPlayerController_ss_
@@ -507,11 +507,11 @@ setAutoSpawn_f_
setFactionProp_ss_
-downScaleHP_f_
-upScaleHP_f_
-scaleHP_f_
-setHPLevel_f_
-addHP_f_
+downScaleChaScore1_f_
+upScaleChaScore1_f_
+scaleChaScore1_f_
+setChaScore1Level_f_
+addChaScore1_f_
clamp_fff_f
min_ff_f
@@ -546,14 +546,14 @@ loadFile_s_
break__
groupName_c_s
-addHpUpTrigger_ff_
-addHpDownTrigger_ff_
-delHpUpTrigger_ff_
-delHpDownTrigger_ff_
-addHpUpTrigger_fs_
-addHpDownTrigger_fs_
-delHpUpTrigger_fs_
-delHpDownTrigger_fs_
+addChaScore1UpTrigger_ff_
+addChaScore1DownTrigger_ff_
+delChaScore1UpTrigger_ff_
+delChaScore1DownTrigger_ff_
+addChaScore1UpTrigger_fs_
+addChaScore1DownTrigger_fs_
+delChaScore1UpTrigger_fs_
+delChaScore1DownTrigger_fs_
aiAction_s_
aiActionSelf_s_
diff --git a/code/ryzom/server/src/ai_share/ai_event_report.cpp b/code/ryzom/server/src/ai_share/ai_event_report.cpp
index a9be0866f..e6f7649c5 100644
--- a/code/ryzom/server/src/ai_share/ai_event_report.cpp
+++ b/code/ryzom/server/src/ai_share/ai_event_report.cpp
@@ -27,9 +27,9 @@ namespace AI_EVENT_REPORT
// The conversion table
const CStringConversion::CPair stringTable [] =
{
- { "HitPoints", HitPoints },
- { "Stamina", Stamina },
- { "Sap", Sap },
+ { "ChaScore1", ChaScore1 },
+ { "ChaScore2", ChaScore2 },
+ { "ChaScore2", ChaScore3 },
{ "Unknown", Unknown },
};
diff --git a/code/ryzom/server/src/ai_share/ai_event_report.h b/code/ryzom/server/src/ai_share/ai_event_report.h
index 804ebd451..470c5ddc5 100644
--- a/code/ryzom/server/src/ai_share/ai_event_report.h
+++ b/code/ryzom/server/src/ai_share/ai_event_report.h
@@ -29,9 +29,9 @@ namespace AI_EVENT_REPORT
{
enum TAIReportStat
{
- HitPoints = 0,
- Stamina,
- Sap,
+ ChaScore1 = 0,
+ ChaScore2,
+ ChaScore3,
Unknown,
};
@@ -100,7 +100,7 @@ struct CAiEventReport
TDataSetRow Originator;
/// Target
TDataSetRow Target;
- /// the affected stats (Hp, sap...)
+ /// the affected stats (ChaScore1, ChaScore2...)
std::vector AffectedStats;
/// the delta values
std::vector DeltaValue;
diff --git a/code/ryzom/server/src/ai_share/ai_types.h b/code/ryzom/server/src/ai_share/ai_types.h
index c9ff5a238..0a2e76bf2 100644
--- a/code/ryzom/server/src/ai_share/ai_types.h
+++ b/code/ryzom/server/src/ai_share/ai_types.h
@@ -291,8 +291,8 @@ namespace AITYPES
// EffectCurseHatredDegeneres,
//
// EffectHeal,
-// EffectStamina,
-// EffectSap,
+// EffectChaScore2,
+// EffectChaScore3,
//
// EffectDotShock,
// EffectDotSlash,
diff --git a/code/ryzom/server/src/ai_share/ai_wrapper_server.cpp b/code/ryzom/server/src/ai_share/ai_wrapper_server.cpp
index 70fd09aed..0a684edf2 100644
--- a/code/ryzom/server/src/ai_share/ai_wrapper_server.cpp
+++ b/code/ryzom/server/src/ai_share/ai_wrapper_server.cpp
@@ -219,39 +219,39 @@ void CAiWrapperServer::despawnEntity(NLMISC::CEntityId entityId, uint32 alias)
CUnifiedNetwork::getInstance()->send("AIS",msgout);
}
-void CAiWrapperServer::setGrpHPLevel(NLMISC::CEntityId entityId, uint32 alias, float hp)
+void CAiWrapperServer::setGrpChaScore1Level(NLMISC::CEntityId entityId, uint32 alias, float ChaScore1)
{
uint32 messageVersion = 1;
uint32 nbString=2;
std::string eid = entityId.toString();
- std::string hpstr = NLMISC::toString("()setHPScale(%f);", hp);
+ std::string ChaScore1str = NLMISC::toString("()setChaScore1Scale(%f);", ChaScore1);
//CMessage msgout("EVENT_NPC_GROUP_SCRIPT");
CMessage msgout("R2_NPC_BOT_SCRIPT_BY_ID");
msgout.serial(messageVersion);
msgout.serial(nbString);
msgout.serial(eid);
- msgout.serial(hpstr);
+ msgout.serial(ChaScore1str);
CUnifiedNetwork::getInstance()->send("AIS",msgout);
}
-void CAiWrapperServer::setHPLevel(NLMISC::CEntityId entityId, uint32 alias, float hp)
+void CAiWrapperServer::setChaScore1Level(NLMISC::CEntityId entityId, uint32 alias, float ChaScore1)
{
uint32 messageVersion = 1;
uint32 nbString=2;
std::string eid = entityId.toString();
- std::string hpstr = NLMISC::toString("()setBotHPScaleByAlias(%f, \"%s\");", hp, aliasToString(alias).c_str());
+ std::string ChaScore1str = NLMISC::toString("()setBotChaScore1ScaleByAlias(%f, \"%s\");", ChaScore1, aliasToString(alias).c_str());
//CMessage msgout("EVENT_NPC_GROUP_SCRIPT");
CMessage msgout("R2_NPC_BOT_SCRIPT_BY_ID");
msgout.serial(messageVersion);
msgout.serial(nbString);
msgout.serial(eid);
- msgout.serial(hpstr);
+ msgout.serial(ChaScore1str);
CUnifiedNetwork::getInstance()->send("AIS",msgout);
}
diff --git a/code/ryzom/server/src/entities_game_service/admin.cpp b/code/ryzom/server/src/entities_game_service/admin.cpp
index e92657c3e..1ffcff1a4 100644
--- a/code/ryzom/server/src/entities_game_service/admin.cpp
+++ b/code/ryzom/server/src/entities_game_service/admin.cpp
@@ -299,8 +299,8 @@ AdminCommandsInit[] =
"Invulnerable", true,
"ShowFactionChannels", true,
"CreateCharacterStartSkillsValue", false,
- "HP", true,
- "MaxHP", true,
+ "ChaScore1", true,
+ "MaxChaScore1", true,
"Speed", true,
"Money", true,
"MoneyGuild", true,
@@ -936,35 +936,35 @@ void GET_CHARACTER_Helper(std::string& command, const NLMISC::CEntityId& id, con
// Don't forget to add your command in the AdminCommandsInit array if you want the command to be executed on the client
//
-ENTITY_VARIABLE(HP, "Hit points of a player")
+ENTITY_VARIABLE(ChaScore1, "ChaScore1 of a player")
{
ENTITY_GET_ENTITY
if (get)
{
- value = toString (e->currentHp());
+ value = toString (e->currentChaScore1());
}
else
{
sint32 v;
NLMISC::fromString(value, v);
- e->getScores()._PhysicalScores[SCORES::hit_points].Current = v;
+ e->getScores()._PhysicalScores[SCORES::cha_score1].Current = v;
}
}
-ENTITY_VARIABLE(MaxHP, "Max hit points of a player")
+ENTITY_VARIABLE(MaxChaScore1, "Max ChaScore1 of a player")
{
ENTITY_GET_ENTITY
if (get)
{
- value = toString (e->maxHp());
+ value = toString (e->maxChaScore1());
}
else
{
sint32 v;
NLMISC::fromString(value, v);
- e->getScores()._PhysicalScores[SCORES::hit_points].Max = v;
+ e->getScores()._PhysicalScores[SCORES::cha_score1].Max = v;
}
}
@@ -1821,7 +1821,7 @@ NLMISC_COMMAND (forceTargetToDie, "(debug) Force entity target to die", "")
if (target)
{
if (!target->isDead())
- target->changeCurrentHp(-100000);
+ target->changeCurrentChaScore1(-100000);
BotDeathReport.Bots.push_back(target->getEntityRowId());
TDataSetRow emptyRow;
@@ -2801,7 +2801,7 @@ NLMISC_COMMAND(respawnAfterDeath,"respawnAfterDeath at re-spawn point name, it m
//-----------------------------------------------
// Simulate Resurrection by other PC until UI is ready
//-----------------------------------------------
-NLMISC_COMMAND(resurrected,"Another PC resurrect PC by giving some energy","")
+NLMISC_COMMAND(resurrected,"Another PC resurrect PC by giving some energy","")
{
if( args.size() == 1 )
{
@@ -3716,7 +3716,7 @@ NLMISC_COMMAND( killMob, "kill a mob ( /a killMob )", "" )
return true;
}
}
- creature->getScores()._PhysicalScores[SCORES::hit_points].Current = 0;
+ creature->getScores()._PhysicalScores[SCORES::cha_score1].Current = 0;
return true;
}
@@ -4121,9 +4121,9 @@ NLMISC_COMMAND (targetInfos, "give infos on the target", "")
answer = "invalid creature target";
else
{
- answer = NLMISC::toString( "HP : %u / %u",
- target->getScores()._PhysicalScores[SCORES::hit_points].Current(),
- target->getScores()._PhysicalScores[SCORES::hit_points].Max() );
+ answer = NLMISC::toString( "ChaScore1 : %u / %u",
+ target->getScores()._PhysicalScores[SCORES::cha_score1].Current(),
+ target->getScores()._PhysicalScores[SCORES::cha_score1].Max() );
}
}
else if ( c->getTarget().getType() == RYZOMID::player )
@@ -4134,11 +4134,11 @@ NLMISC_COMMAND (targetInfos, "give infos on the target", "")
else
{
const std::vector< SCharacteristicsAndScores > & scores = target->getScores()._PhysicalScores;
- answer = NLMISC::toString( "HP : %d / %d \nSAP : %d / %d \nSTA : %d / %d \nFOCUS : %d / %d \n",
- scores[SCORES::hit_points].Current(),scores[SCORES::hit_points].Max(),
- scores[SCORES::sap].Current(),scores[SCORES::sap].Max(),
- scores[SCORES::stamina].Current(),scores[SCORES::stamina].Max(),
- scores[SCORES::focus].Current(),scores[SCORES::focus].Max() );
+ answer = NLMISC::toString( "ChaScore1 : %d / %d \nChaScore3 : %d / %d \nChaScore2 : %d / %d \nChaScore4 : %d / %d \n",
+ scores[SCORES::cha_score1].Current(),scores[SCORES::cha_score1].Max(),
+ scores[SCORES::cha_score3].Current(),scores[SCORES::cha_score3].Max(),
+ scores[SCORES::cha_score2].Current(),scores[SCORES::cha_score2].Max(),
+ scores[SCORES::cha_score4].Current(),scores[SCORES::cha_score4].Max() );
answer += "\n Displaying skills > 1:\n";
for ( uint i = 0; i < target->getSkills()._Skills.size();i++ )
{
diff --git a/code/ryzom/server/src/entities_game_service/building_manager/building_physical.cpp b/code/ryzom/server/src/entities_game_service/building_manager/building_physical.cpp
index 30374ec3d..c4f6c5d96 100644
--- a/code/ryzom/server/src/entities_game_service/building_manager/building_physical.cpp
+++ b/code/ryzom/server/src/entities_game_service/building_manager/building_physical.cpp
@@ -90,7 +90,7 @@ bool IBuildingPhysical::addUser(CCharacter * user, uint16 roomIdx, uint16 ownerI
}
- if (user->currentHp() <= 0 )
+ if (user->currentChaScore1() <= 0 )
{
nlwarning("user %s is dead",user->getId().toString().c_str());
return false;
diff --git a/code/ryzom/server/src/entities_game_service/creature_manager/creature.cpp b/code/ryzom/server/src/entities_game_service/creature_manager/creature.cpp
index 5a0f8873a..869c1fb4b 100644
--- a/code/ryzom/server/src/entities_game_service/creature_manager/creature.cpp
+++ b/code/ryzom/server/src/entities_game_service/creature_manager/creature.cpp
@@ -239,12 +239,12 @@ CCreature * CCreature::getCreatureCopy( const NLMISC::CEntityId & entityId, sint
CMirrorPropValue value3Src( TheDataset, _EntityRowId, DSPropertyVPA );
value3Dest = value3Src.getValue();
- CMirrorPropValue value4Dest( TheDataset, entityRowId, DSPropertyCURRENT_HIT_POINTS );
- CMirrorPropValue value4Src( TheDataset, _EntityRowId, DSPropertyCURRENT_HIT_POINTS );
+ CMirrorPropValue value4Dest( TheDataset, entityRowId, DSPropertyCURRENT_ChaScore1 );
+ CMirrorPropValue value4Src( TheDataset, _EntityRowId, DSPropertyCURRENT_ChaScore1 );
value4Dest = value4Src.getValue();
- CMirrorPropValue value5Dest( TheDataset, entityRowId, DSPropertyMAX_HIT_POINTS );
- CMirrorPropValue value5Src( TheDataset, _EntityRowId, DSPropertyMAX_HIT_POINTS );
+ CMirrorPropValue value5Dest( TheDataset, entityRowId, DSPropertyMAX_ChaScore1 );
+ CMirrorPropValue value5Src( TheDataset, _EntityRowId, DSPropertyMAX_ChaScore1 );
value5Dest = value5Src.getValue();
CMirrorPropValue value6Dest( TheDataset, entityRowId, DSPropertySHEET );
@@ -450,11 +450,11 @@ void CCreature::displayModifiedAttributes(CEntityId id, NLMISC::CLog &log)
log.displayNL("Size : %i [%i]", _Size, baseForm->getSize());
log.displayNL("Faction : %d [%d]", _Faction, baseForm->getFaction());
log.displayNL("FameByKill : %d [%d]", _FameByKill, baseForm->getFameByKill());
- log.displayNL("HP : %d [%d]", _PhysScores._PhysicalScores[SCORES::hit_points].Base, baseForm->getScores(SCORES::hit_points));
+ log.displayNL("ChaScore1 : %d [%d]", _PhysScores._PhysicalScores[SCORES::cha_score1].Base, baseForm->getScores(SCORES::cha_score1));
//attributes only present in sheets, are they really used?
log.displayNL("Ecosystem : %s [%s]", ECOSYSTEM::toString(_Form->getEcosystem()).c_str(), ECOSYSTEM::toString(baseForm->getEcosystem()).c_str());
/*log.displayNL("NbPlayers : %i [%i]", _NbPlayers, ???);
- log.displayNL("PlayerHpLevel: %d [%d]", _);
+ log.displayNL("PlayerChaScore1Level: %d [%d]", _);
log.displayNL("NbHitToKillPlayer: %d [%d]", _);
log.displayNL("AttackLevel : %i [%i]", _AttackLevel, baseForm->getAttackLevel());
log.displayNL("AttackSpeed : %d [%d]", _AttackLatency, baseForm->getAttackLatency());
@@ -462,7 +462,7 @@ void CCreature::displayModifiedAttributes(CEntityId id, NLMISC::CLog &log)
log.displayNL("XPLevel : %i [%i]", _XPLevel, baseForm->getXPLevel());
log.displayNL("TauntLevel : %i [%i]", _TauntLevel, baseForm->getTauntLevel());
log.displayNL("XPGainOnCreature : %f [%f]", _XPGainOnCreature, baseForm->getXPGainOnCreature());*/
- log.displayNL("Regen: %f [%f]",_PhysScores._PhysicalScores[SCORES::hit_points].CurrentRegenerate, baseForm->getRegen(SCORES::hit_points));
+ log.displayNL("Regen: %f [%f]",_PhysScores._PhysicalScores[SCORES::cha_score1].CurrentRegenerate, baseForm->getRegen(SCORES::cha_score1));
log.displayNL("DodgeAsDefense : %d [%d]", _DodgeAsDefense, baseForm->getDodgeAsDefense());
}
}
@@ -531,13 +531,13 @@ void CCreature::loadSheetCreature( NLMISC::CSheetId sheetId )
_PhysScores._PhysicalScores[ i ].BaseRegenerateAction = _Form->getRegen( i );
}
- if( _PhysScores._PhysicalScores[ SCORES::hit_points ].Base == 0 || _PhysScores._PhysicalScores[ SCORES::hit_points ].Current == 0)
+ if( _PhysScores._PhysicalScores[ SCORES::cha_score1 ].Base == 0 || _PhysScores._PhysicalScores[ SCORES::cha_score1 ].Current == 0)
{
const sint32 score = (sint32) ( (2*_Form->getDefenseLevel()*_Form->getNbPlayers() + 0.5)*(MinDamage + DamageStep * _Form->getDefenseLevel())*0.65 );
- nlwarning("CREATURE : spawning a creature with 0 Hit Points ! (SHEET %s), set the hp to %d", sheetId.toString().c_str(), score);
- _PhysScores._PhysicalScores[ SCORES::hit_points ].Base = max(score,sint32(1));
- _PhysScores._PhysicalScores[ SCORES::hit_points ].Current = max(score,sint32(1));
- _PhysScores._PhysicalScores[ SCORES::hit_points ].Max = max(score,sint32(1));
+ nlwarning("CREATURE : spawning a creature with 0 ChaScore1 ! (SHEET %s), set the ChaScore1 to %d", sheetId.toString().c_str(), score);
+ _PhysScores._PhysicalScores[ SCORES::cha_score1 ].Base = max(score,sint32(1));
+ _PhysScores._PhysicalScores[ SCORES::cha_score1 ].Current = max(score,sint32(1));
+ _PhysScores._PhysicalScores[ SCORES::cha_score1 ].Max = max(score,sint32(1));
}
///////////////////////////////////////////////////////
@@ -614,7 +614,7 @@ void CCreature::loadSheetCreature( NLMISC::CSheetId sheetId )
// Damage Shield
///////////////////////////////////////////////////////
_DamageShieldDamage = _Form->getDamageShieldDamage();
- _DamageShieldHpDrain= _Form->getDamageShieldHpDrain();
+ _DamageShieldChaScore1Drain= _Form->getDamageShieldChaScore1Drain();
///////////////////////////////////////////////////////
// defense mode
@@ -1724,7 +1724,7 @@ void CCreature::kill(TDataSetRow killerRowId)
removeAllSpells();
- _PhysScores._PhysicalScores[SCORES::hit_points].Current = 0;
+ _PhysScores._PhysicalScores[SCORES::cha_score1].Current = 0;
setBars(0);
BotDeathReport.Bots.push_back(_EntityRowId);
@@ -2046,12 +2046,12 @@ uint32 CCreature::tickUpdate()
if( _GodMode || _Invulnerable )
{
- if( _PhysScores._PhysicalScores[ SCORES::hit_points ].Current <= 0 )
- _PhysScores._PhysicalScores[ SCORES::hit_points ].Current = _PhysScores._PhysicalScores[ SCORES::hit_points ].Base;
+ if( _PhysScores._PhysicalScores[ SCORES::cha_score1 ].Current <= 0 )
+ _PhysScores._PhysicalScores[ SCORES::cha_score1 ].Current = _PhysScores._PhysicalScores[ SCORES::cha_score1 ].Base;
}
// Check if death of entity occurs
- if (_PhysScores._PhysicalScores[ SCORES::hit_points ].Current <= 0 && _Mode.getValue().Mode != MBEHAV::DEATH )
+ if (_PhysScores._PhysicalScores[ SCORES::cha_score1 ].Current <= 0 && _Mode.getValue().Mode != MBEHAV::DEATH )
{
kill();
}
@@ -2079,7 +2079,7 @@ uint32 CCreature::tickUpdate()
}
}
- if (currentHp()!=maxHp() && !isDead()) return 12;
+ if (currentChaScore1()!=maxChaScore1() && !isDead()) return 12;
return 24;
} // tickUpdate //
diff --git a/code/ryzom/server/src/entities_game_service/creature_manager/creature_manager.cpp b/code/ryzom/server/src/entities_game_service/creature_manager/creature_manager.cpp
index 9fe263a31..5d3f3d2d6 100644
--- a/code/ryzom/server/src/entities_game_service/creature_manager/creature_manager.cpp
+++ b/code/ryzom/server/src/entities_game_service/creature_manager/creature_manager.cpp
@@ -184,33 +184,33 @@ void CCreatureCompleteHealImp::callback(const string &, NLNET::TServiceId sid)
{
H_AUTO(CCreatureCompleteHealImp);
- // for each creature, restore full HP
+ // for each creature, restore full ChaScore1
for ( uint i = 0; i < Entities.size(); ++i )
{
CCreature * c = CreatureManager.getCreature( Entities[i] );
if ( c )
{
- c->changeCurrentHp( c->maxHp() - c->currentHp() );
+ c->changeCurrentChaScore1( c->maxChaScore1() - c->currentChaScore1() );
}
}
}
//--------------------------------------------------------------
-// CChangeCreatureMaxHPImp ::callback()
+// CChangeCreatureMaxChaScore1Imp ::callback()
//--------------------------------------------------------------
-void CChangeCreatureMaxHPImp::callback(const string &, NLNET::TServiceId sid)
+void CChangeCreatureMaxChaScore1Imp::callback(const string &, NLNET::TServiceId sid)
{
- H_AUTO(CChangeCreatureMaxHPImp);
+ H_AUTO(CChangeCreatureMaxChaScore1Imp);
- // for each creature, restore full HP
+ // for each creature, restore full ChaScore1
for ( uint i = 0; i < Entities.size(); ++i )
{
CCreature * c = CreatureManager.getCreature( Entities[i] );
if ( c )
{
- c->getScores()._PhysicalScores[SCORES::hit_points].Max = MaxHp[i];
+ c->getScores()._PhysicalScores[SCORES::cha_score1].Max = MaxChaScore1[i];
if (SetFull[i] != 0)
- c->changeCurrentHp( c->maxHp() - c->currentHp() );
+ c->changeCurrentChaScore1( c->maxChaScore1() - c->currentChaScore1() );
}
}
}
@@ -218,34 +218,34 @@ void CChangeCreatureMaxHPImp::callback(const string &, NLNET::TServiceId sid)
//--------------------------------------------------------------
-// CChangeCreatureHPImp ::callback()
+// CChangeCreatureChaScore1Imp ::callback()
//--------------------------------------------------------------
-void CChangeCreatureHPImp::callback(const string &, NLNET::TServiceId sid)
+void CChangeCreatureChaScore1Imp::callback(const string &, NLNET::TServiceId sid)
{
- H_AUTO(CChangeCreatureHPImp);
+ H_AUTO(CChangeCreatureChaScore1Imp);
uint16 size = (uint16)Entities.size();
- if (Entities.size() != DeltaHp.size() )
+ if (Entities.size() != DeltaChaScore1.size() )
{
- nlwarning("Entities.size() != DeltaHp.size()");
+ nlwarning("Entities.size() != DeltaChaScore1.size()");
- size = (uint16)min(Entities.size(),DeltaHp.size());
+ size = (uint16)min(Entities.size(),DeltaChaScore1.size());
}
- // for each creature, change HP
+ // for each creature, change ChaScore1
for ( uint i = 0; i < size; ++i )
{
CCreature * c = CreatureManager.getCreature( Entities[i] );
if ( c )
{
- if( c->currentHp()+DeltaHp[i] > c->maxHp() )
+ if( c->currentChaScore1()+DeltaChaScore1[i] > c->maxChaScore1() )
{
- // clamp hp
- c->changeCurrentHp( c->maxHp() - c->currentHp() );
+ // clamp ChaScore1
+ c->changeCurrentChaScore1( c->maxChaScore1() - c->currentChaScore1() );
}
else
{
- c->changeCurrentHp( DeltaHp[i] );
+ c->changeCurrentChaScore1( DeltaChaScore1[i] );
}
}
}
diff --git a/code/ryzom/server/src/entities_game_service/creature_manager/creature_manager.h b/code/ryzom/server/src/entities_game_service/creature_manager/creature_manager.h
index ccb9468f0..9b8d9e4ad 100644
--- a/code/ryzom/server/src/entities_game_service/creature_manager/creature_manager.h
+++ b/code/ryzom/server/src/entities_game_service/creature_manager/creature_manager.h
@@ -72,18 +72,18 @@ public:
};
/**
- * Implementation of the set Max HP message for creatures
+ * Implementation of the set Max ChaScore1 message for creatures
*/
-class CChangeCreatureMaxHPImp : public CChangeCreatureMaxHPMsg
+class CChangeCreatureMaxChaScore1Imp : public CChangeCreatureMaxChaScore1Msg
{
public:
virtual void callback (const std::string &name, NLNET::TServiceId id);
};
/**
- * Implementation of the change HP message for creatures
+ * Implementation of the change ChaScore1 message for creatures
*/
-class CChangeCreatureHPImp : public CChangeCreatureHPMsg
+class CChangeCreatureChaScore1Imp : public CChangeCreatureChaScore1Msg
{
public:
virtual void callback (const std::string &name, NLNET::TServiceId id);
diff --git a/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_ai_action.cpp b/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_ai_action.cpp
index 57f4cca12..77ca67ac9 100644
--- a/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_ai_action.cpp
+++ b/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_ai_action.cpp
@@ -330,8 +330,8 @@ void CSpellParams::serial(class NLMISC::IStream &f)
f.serial(CastingTime);
f.serial(PostActionTime);
f.serial(Stackable);
- f.serial(SapCost);
- f.serial(HpCost);
+ f.serial(ChaScore3Cost);
+ f.serial(ChaScore1Cost);
f.serial(SpellParamValue);
f.serial(SpellParamValue2);
f.serial(SpellPowerFactor);
@@ -386,8 +386,8 @@ void CSpellParams::readForm (const UFormElm &root, const NLMISC::CSheetId &sheet
else
Stackable = false;
- root.getValueByName( SapCost, "SapCost" );
- root.getValueByName( HpCost, "HpCost" );
+ root.getValueByName( ChaScore3Cost, "ChaScore3Cost" );
+ root.getValueByName( ChaScore1Cost, "ChaScore1Cost" );
root.getValueByName(SpellLevel, "SpellLevel");
if (root.getValueByName( value, "Skill" ))
diff --git a/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_ai_action.h b/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_ai_action.h
index 69f2eede9..4600e7b11 100644
--- a/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_ai_action.h
+++ b/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_ai_action.h
@@ -138,7 +138,7 @@ struct CCombatParams
EffectTime = 0;
EffectUpdateFrequency = 10;
EffectDamageType = DMGTYPE::UNDEFINED;
- EffectAffectedScore = SCORES::hit_points;
+ EffectAffectedScore = SCORES::cha_score1;
Critic = 0.0f;
Behaviour = MBEHAV::UNKNOWN_BEHAVIOUR;
ArmorFactor = 1.0f;
@@ -193,10 +193,10 @@ struct CSpellParams
{
CastingTime = 0;
PostActionTime = 0;
- SapCost = 0;
- HpCost = 0;
+ ChaScore3Cost = 0;
+ ChaScore1Cost = 0;
Skill = SKILLS::unknown;
- AffectedScore = SCORES::hit_points;
+ AffectedScore = SCORES::cha_score1;
DamageType = DMGTYPE::UNDEFINED;
SpellParamValue = 0;
SpellParamValue2 = 0;
@@ -215,8 +215,8 @@ struct CSpellParams
NLMISC::TGameCycle CastingTime; // in ticks
NLMISC::TGameCycle PostActionTime; // in ticks
SKILLS::ESkills Skill;
- uint16 SapCost;
- uint16 HpCost;
+ uint16 ChaScore3Cost;
+ uint16 ChaScore1Cost;
SCORES::TScores AffectedScore;
float SpellParamValue;
float SpellParamValue2;
diff --git a/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_brick.cpp b/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_brick.cpp
index 92356286a..77a580dcc 100644
--- a/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_brick.cpp
+++ b/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_brick.cpp
@@ -644,35 +644,35 @@ void addParam(const std::string ¶mStr, std::vector &Par
/************************************************************************/
/* General Params */
/************************************************************************/
- case TBrickParam::SAP:
- // $*STRUCT CSBrickParamSap TBrickParam::SAP
- // $*-i unsigned Sap=0 // quantity of SAP to use
- Params.push_back(new CSBrickParamSap(tail));
+ case TBrickParam::ChaScore3:
+ // $*STRUCT CSBrickParamChaScore3 TBrickParam::ChaScore3
+ // $*-i unsigned ChaScore3=0 // quantity of ChaScore3 to use
+ Params.push_back(new CSBrickParamChaScore3(tail));
break;
- case TBrickParam::HP:
- // $*STRUCT CSBrickParamHp TBrickParam::HP
- // $*-i unsigned Hp=0 // quantity of HP to use
- Params.push_back(new CSBrickParamHp(tail));
+ case TBrickParam::ChaScore1:
+ // $*STRUCT CSBrickParamChaScore1 TBrickParam::ChaScore1
+ // $*-i unsigned ChaScore1=0 // quantity of ChaScore1 to use
+ Params.push_back(new CSBrickParamChaScore1(tail));
break;
- case TBrickParam::STA:
- // $*STRUCT CSBrickParamSta TBrickParam::STA
- // $*-i unsigned Sta=0 // quantity of STA to use
- Params.push_back(new CSBrickParamSta(tail));
+ case TBrickParam::ChaScore2:
+ // $*STRUCT CSBrickParamChaScore2 TBrickParam::ChaScore2
+ // $*-i unsigned ChaScore2=0 // quantity of ChaScore2 to use
+ Params.push_back(new CSBrickParamChaScore2(tail));
break;
- case TBrickParam::STA_WEIGHT_FACTOR:
- // $*STRUCT CSBrickParamStaWeightFactor TBrickParam::STA_WEIGHT_FACTOR
- // $*-i float StaFactor=0 // quantity of STA FACTOR of WEIGHT to use
- // $*-i unsigned StaConst=0 // quantity of STA Constante to use, used STA = StaFactor * (weight of equipped weapons) + StaConst
- Params.push_back(new CSBrickParamStaWeightFactor(tail));
+ case TBrickParam::ChaScore2_WEIGHT_FACTOR:
+ // $*STRUCT CSBrickParamChaScore2WeightFactor TBrickParam::ChaScore2_WEIGHT_FACTOR
+ // $*-i float ChaScore2Factor=0 // quantity of ChaScore2 FACTOR of WEIGHT to use
+ // $*-i unsigned ChaScore2Const=0 // quantity of ChaScore2 Constante to use, used ChaScore2 = ChaScore2Factor * (weight of equipped weapons) + ChaScore2Const
+ Params.push_back(new CSBrickParamChaScore2WeightFactor(tail));
break;
- case TBrickParam::FOCUS:
- // $*STRUCT CSBrickParamFocus TBrickParam::FOCUS
- // $*-i unsigned Focus=0 // quantity of FOCUS to use
- Params.push_back(new CSBrickParamFocus(tail));
+ case TBrickParam::ChaScore4:
+ // $*STRUCT CSBrickParamChaScore4 TBrickParam::ChaScore4
+ // $*-i unsigned ChaScore4=0 // quantity of ChaScore4 to use
+ Params.push_back(new CSBrickParamChaScore4(tail));
break;
case TBrickParam::SET_BEHAVIOUR:
@@ -705,19 +705,19 @@ void addParam(const std::string ¶mStr, std::vector &Par
}
break;
- case TBrickParam::STA_LOSS_FACTOR:
+ case TBrickParam::ChaScore2_LOSS_FACTOR:
{
- // $*STRUCT CSBrickParamStaLossFactor TBrickParam::STA_LOSS_FACTOR
- // $*-f float MinFactor = 0.0 // min factor of damage also applied to stamina
- // $*-f float MaxFactor = 0.0 // max factor of damage also applied to stamina
- Params.push_back(new CSBrickParamStaLossFactor(tail));
+ // $*STRUCT CSBrickParamChaScore2LossFactor TBrickParam::ChaScore2_LOSS_FACTOR
+ // $*-f float MinFactor = 0.0 // min factor of damage also applied to ChaScore2
+ // $*-f float MaxFactor = 0.0 // max factor of damage also applied to ChaScore2
+ Params.push_back(new CSBrickParamChaScore2LossFactor(tail));
}
break;
case TBrickParam::DEBUFF_REGEN:
{
// $*STRUCT CSBrickParamDebuffRegen TBrickParam::DEBUFF_REGEN
- // $*-s std::string Score // affected score regen (Sap, Stamina, HitPoints, Focus)
+ // $*-s std::string Score // affected score regen (ChaScore3, ChaScore2, ChaScore1, ChaScore4)
// $*-f float Duration = 0.0 // duration in seconds
// $*-f float MinFactor = 0.0 // min factor of regen debuff
// $*-f float MaxFactor = 0.0 // max factor of regen debuff
@@ -725,12 +725,12 @@ void addParam(const std::string ¶mStr, std::vector &Par
}
break;
- case TBrickParam::SAP_LOSS_FACTOR:
+ case TBrickParam::ChaScore3_LOSS_FACTOR:
{
- // $*STRUCT CSBrickParamSapLossFactor TBrickParam::SAP_LOSS_FACTOR
- // $*-f float MinFactor = 0.0 // min factor of damage also applied to sap
- // $*-f float MaxFactor = 0.0 // max factor of damage also applied to sap
- Params.push_back(new CSBrickParamSapLossFactor(tail));
+ // $*STRUCT CSBrickParamChaScore3LossFactor TBrickParam::ChaScore3_LOSS_FACTOR
+ // $*-f float MinFactor = 0.0 // min factor of damage also applied to ChaScore3
+ // $*-f float MaxFactor = 0.0 // max factor of damage also applied to ChaScore3
+ Params.push_back(new CSBrickParamChaScore3LossFactor(tail));
}
break;
@@ -984,16 +984,16 @@ void addParam(const std::string ¶mStr, std::vector &Par
case TBrickParam::MA_DMG:
// $*STRUCT CSBrickParamMagicDmg TBrickParam::MA_DMG
- // $*-i sint32 Hp = 0 // fixed modifier on energy
- // $*-i sint32 Sap = 0 // fixed modifier on energy
- // $*-i sint32 Sta = 0 // fixed modifier on energy
+ // $*-i sint32 ChaScore1 = 0 // fixed modifier on energy
+ // $*-i sint32 ChaScore3 = 0 // fixed modifier on energy
+ // $*-i sint32 ChaScore2 = 0 // fixed modifier on energy
Params.push_back(new CSBrickParamMagicDmg(tail));
break;
case TBrickParam::MA_HEAL:
// $*STRUCT CSBrickParamMagicHeal TBrickParam::MA_HEAL
- // $*-i sint32 Hp = 0 // fixed modifier on energy
- // $*-i sint32 Sap = 0 // fixed modifier on energy
- // $*-i sint32 Sta = 0 // fixed modifier on energy
+ // $*-i sint32 ChaScore1 = 0 // fixed modifier on energy
+ // $*-i sint32 ChaScore3 = 0 // fixed modifier on energy
+ // $*-i sint32 ChaScore2 = 0 // fixed modifier on energy
Params.push_back(new CSBrickParamMagicHeal(tail));
break;
case TBrickParam::MA_RANGE:
@@ -1054,25 +1054,25 @@ void addParam(const std::string ¶mStr, std::vector &Par
// $*-i uint32 Recommended
Params.push_back(new CSBrickParamCraftRecommended(tail));
break;
- case TBrickParam::CR_HP:
- // $*STRUCT CSBrickParamCraftHP TBrickParam::CR_HP
- // $*-i sint32 HitPoint
- Params.push_back(new CSBrickParamCraftHP(tail));
+ case TBrickParam::CR_ChaScore1:
+ // $*STRUCT CSBrickParamCraftChaScore1 TBrickParam::CR_ChaScore1
+ // $*-i sint32 ChaScore1
+ Params.push_back(new CSBrickParamCraftChaScore1(tail));
break;
- case TBrickParam::CR_SAP:
- // $*STRUCT CSBrickParamCraftSap TBrickParam::CR_SAP
- // $*-i sint32 Sap
- Params.push_back(new CSBrickParamCraftSap(tail));
+ case TBrickParam::CR_ChaScore3:
+ // $*STRUCT CSBrickParamCraftChaScore3 TBrickParam::CR_ChaScore3
+ // $*-i sint32 ChaScore3
+ Params.push_back(new CSBrickParamCraftChaScore3(tail));
break;
- case TBrickParam::CR_STA:
- // $*STRUCT CSBrickParamCraftSta TBrickParam::CR_STA
- // $*-i sint32 Stamina
- Params.push_back(new CSBrickParamCraftSta(tail));
+ case TBrickParam::CR_ChaScore2:
+ // $*STRUCT CSBrickParamCraftChaScore2 TBrickParam::CR_ChaScore2
+ // $*-i sint32 ChaScore2
+ Params.push_back(new CSBrickParamCraftChaScore2(tail));
break;
- case TBrickParam::CR_FOCUS:
- // $*STRUCT CSBrickParamCraftFocus TBrickParam::CR_FOCUS
- // $*-i uint32 Focus
- Params.push_back(new CSBrickParamCraftFocus(tail));
+ case TBrickParam::CR_ChaScore4:
+ // $*STRUCT CSBrickParamCraftChaScore4 TBrickParam::CR_ChaScore4
+ // $*-i uint32 ChaScore4
+ Params.push_back(new CSBrickParamCraftChaScore4(tail));
break;
case TBrickParam::CR_QUALITY:
// $*STRUCT CSBrickParamCraftQuality TBrickParam::CR_QUALITY
@@ -1299,64 +1299,64 @@ void addParam(const std::string ¶mStr, std::vector &Par
Params.push_back(new CSBrickParamShielding(tail));
break;
- case TBrickParam::SP_LIFE_AURA:
- // $*STRUCT CSBrickParamLifeAura TBrickParam::SP_LIFE_AURA
+ case TBrickParam::SP_ChaScore1_AURA:
+ // $*STRUCT CSBrickParamChaScore1Aura TBrickParam::SP_ChaScore1_AURA
// $*-i uint16 RegenMod // regen modifier (in %)
// $*-f float Duration // duration in seconds
// $*-f float Radius // aura radius in meters
- // $*-f float TargetDisableTime // disable life aura for x seconds on targets
- // $*-f float UserDisableTime // disable life aura for x seconds on user
- Params.push_back(new CSBrickParamLifeAura(tail));
+ // $*-f float TargetDisableTime // disable ChaScore1 aura for x seconds on targets
+ // $*-f float UserDisableTime // disable ChaScore1 aura for x seconds on user
+ Params.push_back(new CSBrickParamChaScore1Aura(tail));
break;
- case TBrickParam::SP_LIFE_AURA2:
- // $*STRUCT CSBrickParamLifeAura2 TBrickParam::SP_LIFE_AURA2
+ case TBrickParam::SP_ChaScore1_AURA2:
+ // $*STRUCT CSBrickParamChaScore1Aura2 TBrickParam::SP_ChaScore1_AURA2
// $*-i uint16 RegenMod // regen modifier (in %) proportionally to item level
// $*-f float Duration // duration in seconds
// $*-f float Radius // aura radius in meters
- // $*-f float TargetDisableTime // disable life aura for x seconds on targets
- // $*-f float UserDisableTime // disable life aura for x seconds on user
- Params.push_back(new CSBrickParamLifeAura2(tail));
+ // $*-f float TargetDisableTime // disable ChaScore1 aura for x seconds on targets
+ // $*-f float UserDisableTime // disable ChaScore1 aura for x seconds on user
+ Params.push_back(new CSBrickParamChaScore1Aura2(tail));
break;
- case TBrickParam::SP_STAMINA_AURA:
- // $*STRUCT CSBrickParamStaminaAura TBrickParam::SP_STAMINA_AURA
+ case TBrickParam::SP_ChaScore2_AURA:
+ // $*STRUCT CSBrickParamChaScore2Aura TBrickParam::SP_ChaScore2_AURA
// $*-i uint16 RegenMod // regen modifier (in %)
// $*-f float Duration // duration in seconds
// $*-f float Radius // aura radius in meters
- // $*-f float TargetDisableTime // disable life aura for x seconds on targets
- // $*-f float UserDisableTime // disable life aura for x seconds on user
- Params.push_back(new CSBrickParamStaminaAura(tail));
+ // $*-f float TargetDisableTime // disable ChaScore2 aura for x seconds on targets
+ // $*-f float UserDisableTime // disable ChaScore2 aura for x seconds on user
+ Params.push_back(new CSBrickParamChaScore2Aura(tail));
break;
- case TBrickParam::SP_STAMINA_AURA2:
- // $*STRUCT CSBrickParamStaminaAura2 TBrickParam::SP_STAMINA_AURA2
+ case TBrickParam::SP_ChaScore2_AURA2:
+ // $*STRUCT CSBrickParamChaScore2Aura2 TBrickParam::SP_ChaScore2_AURA2
// $*-i uint16 RegenMod // regen modifier (in %) proportionally to item level
// $*-f float Duration // duration in seconds
// $*-f float Radius // aura radius in meters
- // $*-f float TargetDisableTime // disable life aura for x seconds on targets
- // $*-f float UserDisableTime // disable life aura for x seconds on user
- Params.push_back(new CSBrickParamStaminaAura2(tail));
+ // $*-f float TargetDisableTime // disable ChaScore2 aura for x seconds on targets
+ // $*-f float UserDisableTime // disable ChaScore2 aura for x seconds on user
+ Params.push_back(new CSBrickParamChaScore2Aura2(tail));
break;
- case TBrickParam::SP_SAP_AURA:
- // $*STRUCT CSBrickParamSapAura TBrickParam::SP_SAP_AURA
+ case TBrickParam::SP_ChaScore3_AURA:
+ // $*STRUCT CSBrickParamChaScore3Aura TBrickParam::SP_ChaScore3_AURA
// $*-i uint16 RegenMod // regen modifier (in %)
// $*-f float Duration // duration in seconds
// $*-f float Radius // aura radius in meters
- // $*-f float TargetDisableTime // disable life aura for x seconds on targets
- // $*-f float UserDisableTime // disable life aura for x seconds on user
- Params.push_back(new CSBrickParamSapAura(tail));
+ // $*-f float TargetDisableTime // disable ChaScore3 aura for x seconds on targets
+ // $*-f float UserDisableTime // disable ChaScore3 aura for x seconds on user
+ Params.push_back(new CSBrickParamChaScore3Aura(tail));
break;
- case TBrickParam::SP_SAP_AURA2:
- // $*STRUCT CSBrickParamSapAura2 TBrickParam::SP_SAP_AURA2
+ case TBrickParam::SP_ChaScore3_AURA2:
+ // $*STRUCT CSBrickParamChaScore3Aura2 TBrickParam::SP_ChaScore3_AURA2
// $*-i uint16 RegenMod // regen modifier (in %) proportionally to item level
// $*-f float Duration // duration in seconds
// $*-f float Radius // aura radius in meters
- // $*-f float TargetDisableTime // disable life aura for x seconds on targets
- // $*-f float UserDisableTime // disable life aura for x seconds on user
- Params.push_back(new CSBrickParamSapAura2(tail));
+ // $*-f float TargetDisableTime // disable ChaScore3 aura for x seconds on targets
+ // $*-f float UserDisableTime // disable ChaScore3 aura for x seconds on user
+ Params.push_back(new CSBrickParamChaScore3Aura2(tail));
break;
case TBrickParam::SP_SPEEDING_UP:
@@ -1501,7 +1501,7 @@ void addParam(const std::string ¶mStr, std::vector &Par
// $*-i sint32 HealValue // value added to affected score
// $*-f float HealFactorValue // value added to affected score in % of max target score
// $*-f float DisableTime // disable power for x seconds
- // $*-s std::string PowerType // type of power (Heal, HealHpC ...)
+ // $*-s std::string PowerType // type of power (Heal, HealChaScore1C ...)
Params.push_back(new CSBrickParamHeal(tail));
break;
@@ -1744,10 +1744,10 @@ void CStaticBrick::loadFaber( const UFormElm &root, const CSheetId &sheetId )
root.getValueByName( Faber->DefensiveAfflictionCastingTimeFactor, "faber.Defensive Affliction Casting Time Factor" );
root.getValueByName( Faber->DefensiveAfflictionPowerFactor, "faber.Defensive Affliction Power Factor" );
- root.getValueByName( Faber->HpBonusPerLevel, "faber.HpBonusPerLevel" );
- root.getValueByName( Faber->SapBonusPerLevel, "faber.SapBonusPerLevel" );
- root.getValueByName( Faber->StaBonusPerLevel, "faber.StaBonusPerLevel" );
- root.getValueByName( Faber->FocusBonusPerLevel, "faber.FocusBonusPerLevel" );
+ root.getValueByName( Faber->ChaScore1BonusPerLevel, "faber.ChaScore1BonusPerLevel" );
+ root.getValueByName( Faber->ChaScore3BonusPerLevel, "faber.ChaScore3BonusPerLevel" );
+ root.getValueByName( Faber->ChaScore2BonusPerLevel, "faber.ChaScore2BonusPerLevel" );
+ root.getValueByName( Faber->ChaScore4BonusPerLevel, "faber.ChaScore4BonusPerLevel" );
root.getValueByName( Faber->AllowPartialSuccess, "faber.AllowPartialSuccess" );
diff --git a/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_brick.cpp.h b/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_brick.cpp.h
index 2a2946bcf..f933a925b 100644
--- a/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_brick.cpp.h
+++ b/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_brick.cpp.h
@@ -24,18 +24,18 @@ class TBrickParam
public:
enum TValueType
{
- SAP,
- HP,
- STA,
- STA_WEIGHT_FACTOR,
- FOCUS,
+ ChaScore3,
+ ChaScore1,
+ ChaScore2,
+ ChaScore2_WEIGHT_FACTOR,
+ ChaScore4,
SET_BEHAVIOUR,
DEFINE_FLAG,
BYPASS_CHECK,
LATENCY_FACTOR,
- STA_LOSS_FACTOR,
+ ChaScore2_LOSS_FACTOR,
DEBUFF_REGEN,
- SAP_LOSS_FACTOR,
+ ChaScore3_LOSS_FACTOR,
AIM,
ATT_SKILL_MOD,
DEFENSE_MOD,
@@ -78,10 +78,10 @@ public:
MA_VAMPIRISE,
MA_VAMPIRISE_RATIO,
CR_RECOMMENDED,
- CR_HP,
- CR_SAP,
- CR_STA,
- CR_FOCUS,
+ CR_ChaScore1,
+ CR_ChaScore3,
+ CR_ChaScore2,
+ CR_ChaScore4,
CR_QUALITY,
CR_DURABILITY,
CR_DAMAGE,
@@ -122,12 +122,12 @@ public:
FG_ITEMPART_FILT,
SP_TAUNT,
SP_SHIELDING,
- SP_LIFE_AURA,
- SP_LIFE_AURA2,
- SP_STAMINA_AURA,
- SP_STAMINA_AURA2,
- SP_SAP_AURA,
- SP_SAP_AURA2,
+ SP_ChaScore1_AURA,
+ SP_ChaScore1_AURA2,
+ SP_ChaScore2_AURA,
+ SP_ChaScore2_AURA2,
+ SP_ChaScore3_AURA,
+ SP_ChaScore3_AURA2,
SP_SPEEDING_UP,
SP_INVULNERABILITY,
SP_MELEE_PROTECTION_AURA,
@@ -203,18 +203,18 @@ public:
if (copyOfStr[i]>='A' && copyOfStr[i]<='Z')
copyOfStr[i]^=('A'^'a');
- if (copyOfStr=="sap") {_Value=SAP; return *this;}
- if (copyOfStr=="hp") {_Value=HP; return *this;}
- if (copyOfStr=="sta") {_Value=STA; return *this;}
- if (copyOfStr=="sta_weight_factor") {_Value=STA_WEIGHT_FACTOR; return *this;}
- if (copyOfStr=="focus") {_Value=FOCUS; return *this;}
+ if (copyOfStr=="ChaScore3") {_Value=ChaScore3; return *this;}
+ if (copyOfStr=="ChaScore1") {_Value=ChaScore1; return *this;}
+ if (copyOfStr=="ChaScore2") {_Value=ChaScore2; return *this;}
+ if (copyOfStr=="ChaScore2_weight_factor") {_Value=ChaScore2_WEIGHT_FACTOR; return *this;}
+ if (copyOfStr=="ChaScore4") {_Value=ChaScore4; return *this;}
if (copyOfStr=="set_behaviour") {_Value=SET_BEHAVIOUR; return *this;}
if (copyOfStr=="define_flag") {_Value=DEFINE_FLAG; return *this;}
if (copyOfStr=="bypass_check") {_Value=BYPASS_CHECK; return *this;}
if (copyOfStr=="latency_factor") {_Value=LATENCY_FACTOR; return *this;}
- if (copyOfStr=="sta_loss_factor") {_Value=STA_LOSS_FACTOR; return *this;}
+ if (copyOfStr=="ChaScore2_loss_factor") {_Value=ChaScore2_LOSS_FACTOR; return *this;}
if (copyOfStr=="debuff_regen") {_Value=DEBUFF_REGEN; return *this;}
- if (copyOfStr=="sap_loss_factor") {_Value=SAP_LOSS_FACTOR; return *this;}
+ if (copyOfStr=="ChaScore3_loss_factor") {_Value=ChaScore3_LOSS_FACTOR; return *this;}
if (copyOfStr=="aim") {_Value=AIM; return *this;}
if (copyOfStr=="att_skill_mod") {_Value=ATT_SKILL_MOD; return *this;}
if (copyOfStr=="defense_mod") {_Value=DEFENSE_MOD; return *this;}
@@ -257,10 +257,10 @@ public:
if (copyOfStr=="ma_vampirise") {_Value=MA_VAMPIRISE; return *this;}
if (copyOfStr=="ma_vampirise_ratio") {_Value=MA_VAMPIRISE_RATIO; return *this;}
if (copyOfStr=="cr_recommended") {_Value=CR_RECOMMENDED; return *this;}
- if (copyOfStr=="cr_hp") {_Value=CR_HP; return *this;}
- if (copyOfStr=="cr_sap") {_Value=CR_SAP; return *this;}
- if (copyOfStr=="cr_sta") {_Value=CR_STA; return *this;}
- if (copyOfStr=="cr_focus") {_Value=CR_FOCUS; return *this;}
+ if (copyOfStr=="cr_ChaScore1") {_Value=CR_ChaScore1; return *this;}
+ if (copyOfStr=="cr_ChaScore3") {_Value=CR_ChaScore3; return *this;}
+ if (copyOfStr=="cr_ChaScore2") {_Value=CR_ChaScore2; return *this;}
+ if (copyOfStr=="cr_ChaScore4") {_Value=CR_ChaScore4; return *this;}
if (copyOfStr=="cr_quality") {_Value=CR_QUALITY; return *this;}
if (copyOfStr=="cr_durability") {_Value=CR_DURABILITY; return *this;}
if (copyOfStr=="cr_damage") {_Value=CR_DAMAGE; return *this;}
@@ -301,12 +301,12 @@ public:
if (copyOfStr=="fg_itempart_filt") {_Value=FG_ITEMPART_FILT; return *this;}
if (copyOfStr=="sp_taunt") {_Value=SP_TAUNT; return *this;}
if (copyOfStr=="sp_shielding") {_Value=SP_SHIELDING; return *this;}
- if (copyOfStr=="sp_life_aura") {_Value=SP_LIFE_AURA; return *this;}
- if (copyOfStr=="sp_life_aura2") {_Value=SP_LIFE_AURA2; return *this;}
- if (copyOfStr=="sp_stamina_aura") {_Value=SP_STAMINA_AURA; return *this;}
- if (copyOfStr=="sp_stamina_aura2") {_Value=SP_STAMINA_AURA2; return *this;}
- if (copyOfStr=="sp_sap_aura") {_Value=SP_SAP_AURA; return *this;}
- if (copyOfStr=="sp_sap_aura2") {_Value=SP_SAP_AURA2; return *this;}
+ if (copyOfStr=="sp_ChaScore1_aura") {_Value=SP_ChaScore1_AURA; return *this;}
+ if (copyOfStr=="sp_ChaScore1_aura2") {_Value=SP_ChaScore1_AURA2; return *this;}
+ if (copyOfStr=="sp_ChaScore2_aura") {_Value=SP_ChaScore2_AURA; return *this;}
+ if (copyOfStr=="sp_ChaScore2_aura2") {_Value=SP_ChaScore2_AURA2; return *this;}
+ if (copyOfStr=="sp_ChaScore3_aura") {_Value=SP_ChaScore3_AURA; return *this;}
+ if (copyOfStr=="sp_ChaScore3_aura2") {_Value=SP_ChaScore3_AURA2; return *this;}
if (copyOfStr=="sp_speeding_up") {_Value=SP_SPEEDING_UP; return *this;}
if (copyOfStr=="sp_invulnerability") {_Value=SP_INVULNERABILITY; return *this;}
if (copyOfStr=="sp_melee_protection_aura") {_Value=SP_MELEE_PROTECTION_AURA; return *this;}
@@ -377,24 +377,24 @@ private:
TValueType _Value;
};
-struct CSBrickParamSap : public TBrickParam::IId
+struct CSBrickParamChaScore3 : public TBrickParam::IId
{
- // quantity of SAP to use
- unsigned Sap;
+ // quantity of ChaScore3 to use
+ unsigned ChaScore3;
- CSBrickParamSap():
- Sap(0)
+ CSBrickParamChaScore3():
+ ChaScore3(0)
{
- _Id = TBrickParam::SAP;
+ _Id = TBrickParam::ChaScore3;
}
- CSBrickParamSap(const std::string&str)
+ CSBrickParamChaScore3(const std::string&str)
{
- *this=CSBrickParamSap();
+ *this=CSBrickParamChaScore3();
*this=str;
}
- const CSBrickParamSap& operator=(const std::string& input)
+ const CSBrickParamChaScore3& operator=(const std::string& input)
{
std::vector args;
convertInput(args, input);
@@ -403,31 +403,31 @@ struct CSBrickParamSap : public TBrickParam::IId
return *this;
ParsedOk=true;
- NLMISC::fromString(args[0], Sap);
+ NLMISC::fromString(args[0], ChaScore3);
return *this;
}
};
-struct CSBrickParamHp : public TBrickParam::IId
+struct CSBrickParamChaScore1 : public TBrickParam::IId
{
- // quantity of HP to use
- unsigned Hp;
+ // quantity of ChaScore1 to use
+ unsigned ChaScore1;
- CSBrickParamHp():
- Hp(0)
+ CSBrickParamChaScore1():
+ ChaScore1(0)
{
- _Id = TBrickParam::HP;
+ _Id = TBrickParam::ChaScore1;
}
- CSBrickParamHp(const std::string&str)
+ CSBrickParamChaScore1(const std::string&str)
{
- *this=CSBrickParamHp();
+ *this=CSBrickParamChaScore1();
*this=str;
}
- const CSBrickParamHp& operator=(const std::string& input)
+ const CSBrickParamChaScore1& operator=(const std::string& input)
{
std::vector args;
convertInput(args, input);
@@ -436,31 +436,31 @@ struct CSBrickParamHp : public TBrickParam::IId
return *this;
ParsedOk=true;
- NLMISC::fromString(args[0], Hp);
+ NLMISC::fromString(args[0], ChaScore1);
return *this;
}
};
-struct CSBrickParamSta : public TBrickParam::IId
+struct CSBrickParamChaScore2 : public TBrickParam::IId
{
- // quantity of STA to use
- unsigned Sta;
+ // quantity of ChaScore2 to use
+ unsigned ChaScore2;
- CSBrickParamSta():
- Sta(0)
+ CSBrickParamChaScore2():
+ ChaScore2(0)
{
- _Id = TBrickParam::STA;
+ _Id = TBrickParam::ChaScore2;
}
- CSBrickParamSta(const std::string&str)
+ CSBrickParamChaScore2(const std::string&str)
{
- *this=CSBrickParamSta();
+ *this=CSBrickParamChaScore2();
*this=str;
}
- const CSBrickParamSta& operator=(const std::string& input)
+ const CSBrickParamChaScore2& operator=(const std::string& input)
{
std::vector args;
convertInput(args, input);
@@ -469,35 +469,35 @@ struct CSBrickParamSta : public TBrickParam::IId
return *this;
ParsedOk=true;
- NLMISC::fromString(args[0], Sta);
+ NLMISC::fromString(args[0], ChaScore2);
return *this;
}
};
-struct CSBrickParamStaWeightFactor : public TBrickParam::IId
+struct CSBrickParamChaScore2WeightFactor : public TBrickParam::IId
{
- // STA factor of weight to use
- float StaFactor;
+ // ChaScore2 factor of weight to use
+ float ChaScore2Factor;
- // STA constante used
- unsigned StaConst;
+ // ChaScore2 constante used
+ unsigned ChaScore2Const;
- CSBrickParamStaWeightFactor():
- StaFactor(0.0f),
- StaConst(0)
+ CSBrickParamChaScore2WeightFactor():
+ ChaScore2Factor(0.0f),
+ ChaScore2Const(0)
{
- _Id = TBrickParam::STA_WEIGHT_FACTOR;
+ _Id = TBrickParam::ChaScore2_WEIGHT_FACTOR;
}
- CSBrickParamStaWeightFactor(const std::string&str)
+ CSBrickParamChaScore2WeightFactor(const std::string&str)
{
- *this=CSBrickParamStaWeightFactor();
+ *this=CSBrickParamChaScore2WeightFactor();
*this=str;
}
- const CSBrickParamStaWeightFactor& operator=(const std::string& input)
+ const CSBrickParamChaScore2WeightFactor& operator=(const std::string& input)
{
std::vector args;
convertInput(args, input);
@@ -506,32 +506,32 @@ struct CSBrickParamStaWeightFactor : public TBrickParam::IId
return *this;
ParsedOk=true;
- StaFactor=(float)atof(args[0].c_str());
- NLMISC::fromString(args[1], StaConst);
+ ChaScore2Factor=(float)atof(args[0].c_str());
+ NLMISC::fromString(args[1], ChaScore2Const);
return *this;
}
};
-struct CSBrickParamFocus : public TBrickParam::IId
+struct CSBrickParamChaScore4 : public TBrickParam::IId
{
- // quantity of FOCUS to use
- unsigned Focus;
+ // quantity of ChaScore4 to use
+ unsigned ChaScore4;
- CSBrickParamFocus():
- Focus(0)
+ CSBrickParamChaScore4():
+ ChaScore4(0)
{
- _Id = TBrickParam::FOCUS;
+ _Id = TBrickParam::ChaScore4;
}
- CSBrickParamFocus(const std::string&str)
+ CSBrickParamChaScore4(const std::string&str)
{
- *this=CSBrickParamFocus();
+ *this=CSBrickParamChaScore4();
*this=str;
}
- const CSBrickParamFocus& operator=(const std::string& input)
+ const CSBrickParamChaScore4& operator=(const std::string& input)
{
std::vector args;
convertInput(args, input);
@@ -540,7 +540,7 @@ struct CSBrickParamFocus : public TBrickParam::IId
return *this;
ParsedOk=true;
- NLMISC::fromString(args[0], Focus);
+ NLMISC::fromString(args[0], ChaScore4);
return *this;
}
@@ -683,27 +683,27 @@ struct CSBrickParamLatencyFactor : public TBrickParam::IId
};
-struct CSBrickParamStaLossFactor : public TBrickParam::IId
+struct CSBrickParamChaScore2LossFactor : public TBrickParam::IId
{
- // min factor of damage also applied to stamina
+ // min factor of damage also applied to ChaScore2
float MinFactor;
- // max factor of damage also applied to stamina
+ // max factor of damage also applied to ChaScore2
float MaxFactor;
- CSBrickParamStaLossFactor():
+ CSBrickParamChaScore2LossFactor():
MinFactor(0.0),
MaxFactor(0.0)
{
- _Id = TBrickParam::STA_LOSS_FACTOR;
+ _Id = TBrickParam::ChaScore2_LOSS_FACTOR;
}
- CSBrickParamStaLossFactor(const std::string&str)
+ CSBrickParamChaScore2LossFactor(const std::string&str)
{
- *this=CSBrickParamStaLossFactor();
+ *this=CSBrickParamChaScore2LossFactor();
*this=str;
}
- const CSBrickParamStaLossFactor& operator=(const std::string& input)
+ const CSBrickParamChaScore2LossFactor& operator=(const std::string& input)
{
std::vector args;
convertInput(args, input);
@@ -722,7 +722,7 @@ struct CSBrickParamStaLossFactor : public TBrickParam::IId
struct CSBrickParamDebuffRegen : public TBrickParam::IId
{
- // affected score regen (Sap, Stamina, HitPoints, Focus)
+ // affected score regen (ChaScore3, ChaScore2, ChaScore1, ChaScore4)
std::string Score;
// duration in seconds
float Duration;
@@ -765,27 +765,27 @@ struct CSBrickParamDebuffRegen : public TBrickParam::IId
};
-struct CSBrickParamSapLossFactor : public TBrickParam::IId
+struct CSBrickParamChaScore3LossFactor : public TBrickParam::IId
{
- // min factor of damage also applied to sap
+ // min factor of damage also applied to ChaScore3
float MinFactor;
- // max factor of damage also applied to sap
+ // max factor of damage also applied to ChaScore3
float MaxFactor;
- CSBrickParamSapLossFactor():
+ CSBrickParamChaScore3LossFactor():
MinFactor(0.0),
MaxFactor(0.0)
{
- _Id = TBrickParam::SAP_LOSS_FACTOR;
+ _Id = TBrickParam::ChaScore3_LOSS_FACTOR;
}
- CSBrickParamSapLossFactor(const std::string&str)
+ CSBrickParamChaScore3LossFactor(const std::string&str)
{
- *this=CSBrickParamSapLossFactor();
+ *this=CSBrickParamChaScore3LossFactor();
*this=str;
}
- const CSBrickParamSapLossFactor& operator=(const std::string& input)
+ const CSBrickParamChaScore3LossFactor& operator=(const std::string& input)
{
std::vector args;
convertInput(args, input);
@@ -1899,16 +1899,16 @@ struct CSBrickParamMagicDmgType : public TBrickParam::IId
struct CSBrickParamMagicDmg : public TBrickParam::IId
{
// fixed modifier on energy
- sint32 Hp;
+ sint32 ChaScore1;
// fixed modifier on energy
- sint32 Sap;
+ sint32 ChaScore3;
// fixed modifier on energy
- sint32 Sta;
+ sint32 ChaScore2;
CSBrickParamMagicDmg():
- Hp(0),
- Sap(0),
- Sta(0)
+ ChaScore1(0),
+ ChaScore3(0),
+ ChaScore2(0)
{
_Id = TBrickParam::MA_DMG;
}
@@ -1928,9 +1928,9 @@ struct CSBrickParamMagicDmg : public TBrickParam::IId
return *this;
ParsedOk=true;
- NLMISC::fromString(args[0], Hp);
- NLMISC::fromString(args[1], Sap);
- NLMISC::fromString(args[2], Sta);
+ NLMISC::fromString(args[0], ChaScore1);
+ NLMISC::fromString(args[1], ChaScore3);
+ NLMISC::fromString(args[2], ChaScore2);
return *this;
}
@@ -1940,16 +1940,16 @@ struct CSBrickParamMagicDmg : public TBrickParam::IId
struct CSBrickParamMagicHeal : public TBrickParam::IId
{
// fixed modifier on energy
- sint32 Hp;
+ sint32 ChaScore1;
// fixed modifier on energy
- sint32 Sap;
+ sint32 ChaScore3;
// fixed modifier on energy
- sint32 Sta;
+ sint32 ChaScore2;
CSBrickParamMagicHeal():
- Hp(0),
- Sap(0),
- Sta(0)
+ ChaScore1(0),
+ ChaScore3(0),
+ ChaScore2(0)
{
_Id = TBrickParam::MA_HEAL;
}
@@ -1969,9 +1969,9 @@ struct CSBrickParamMagicHeal : public TBrickParam::IId
return *this;
ParsedOk=true;
- NLMISC::fromString(args[0], Hp);
- NLMISC::fromString(args[1], Sap);
- NLMISC::fromString(args[2], Sta);
+ NLMISC::fromString(args[0], ChaScore1);
+ NLMISC::fromString(args[1], ChaScore3);
+ NLMISC::fromString(args[2], ChaScore2);
return *this;
}
@@ -2312,24 +2312,24 @@ struct CSBrickParamCraftRecommended : public TBrickParam::IId
};
-struct CSBrickParamCraftHP : public TBrickParam::IId
+struct CSBrickParamCraftChaScore1 : public TBrickParam::IId
{
- sint32 HitPoint;
+ sint32 ChaScore1;
- CSBrickParamCraftHP():
- HitPoint()
+ CSBrickParamCraftChaScore1():
+ ChaScore1()
{
- _Id = TBrickParam::CR_HP;
+ _Id = TBrickParam::CR_ChaScore1;
}
- CSBrickParamCraftHP(const std::string&str)
+ CSBrickParamCraftChaScore1(const std::string&str)
{
- *this=CSBrickParamCraftHP();
+ *this=CSBrickParamCraftChaScore1();
*this=str;
}
- const CSBrickParamCraftHP& operator=(const std::string& input)
+ const CSBrickParamCraftChaScore1& operator=(const std::string& input)
{
std::vector args;
convertInput(args, input);
@@ -2338,31 +2338,31 @@ struct CSBrickParamCraftHP : public TBrickParam::IId
return *this;
ParsedOk=true;
- NLMISC::fromString(args[0], HitPoint);
+ NLMISC::fromString(args[0], ChaScore1);
return *this;
}
};
-struct CSBrickParamCraftSap : public TBrickParam::IId
+struct CSBrickParamCraftChaScore3 : public TBrickParam::IId
{
- sint32 Sap;
+ sint32 ChaScore3;
- CSBrickParamCraftSap():
- Sap()
+ CSBrickParamCraftChaScore3():
+ ChaScore3()
{
- _Id = TBrickParam::CR_SAP;
+ _Id = TBrickParam::CR_ChaScore3;
}
- CSBrickParamCraftSap(const std::string&str)
+ CSBrickParamCraftChaScore3(const std::string&str)
{
- *this=CSBrickParamCraftSap();
+ *this=CSBrickParamCraftChaScore3();
*this=str;
}
- const CSBrickParamCraftSap& operator=(const std::string& input)
+ const CSBrickParamCraftChaScore3& operator=(const std::string& input)
{
std::vector args;
convertInput(args, input);
@@ -2371,31 +2371,31 @@ struct CSBrickParamCraftSap : public TBrickParam::IId
return *this;
ParsedOk=true;
- NLMISC::fromString(args[0], Sap);
+ NLMISC::fromString(args[0], ChaScore3);
return *this;
}
};
-struct CSBrickParamCraftSta : public TBrickParam::IId
+struct CSBrickParamCraftChaScore2 : public TBrickParam::IId
{
- sint32 Stamina;
+ sint32 ChaScore2;
- CSBrickParamCraftSta():
- Stamina()
+ CSBrickParamCraftChaScore2():
+ ChaScore2()
{
- _Id = TBrickParam::CR_STA;
+ _Id = TBrickParam::CR_ChaScore2;
}
- CSBrickParamCraftSta(const std::string&str)
+ CSBrickParamCraftChaScore2(const std::string&str)
{
- *this=CSBrickParamCraftSta();
+ *this=CSBrickParamCraftChaScore2();
*this=str;
}
- const CSBrickParamCraftSta& operator=(const std::string& input)
+ const CSBrickParamCraftChaScore2& operator=(const std::string& input)
{
std::vector args;
convertInput(args, input);
@@ -2404,31 +2404,31 @@ struct CSBrickParamCraftSta : public TBrickParam::IId
return *this;
ParsedOk=true;
- NLMISC::fromString(args[0], Stamina);
+ NLMISC::fromString(args[0], ChaScore2);
return *this;
}
};
-struct CSBrickParamCraftFocus : public TBrickParam::IId
+struct CSBrickParamCraftChaScore4 : public TBrickParam::IId
{
- uint32 Focus;
+ uint32 ChaScore4;
- CSBrickParamCraftFocus():
- Focus()
+ CSBrickParamCraftChaScore4():
+ ChaScore4()
{
- _Id = TBrickParam::CR_FOCUS;
+ _Id = TBrickParam::CR_ChaScore4;
}
- CSBrickParamCraftFocus(const std::string&str)
+ CSBrickParamCraftChaScore4(const std::string&str)
{
- *this=CSBrickParamCraftFocus();
+ *this=CSBrickParamCraftChaScore4();
*this=str;
}
- const CSBrickParamCraftFocus& operator=(const std::string& input)
+ const CSBrickParamCraftChaScore4& operator=(const std::string& input)
{
std::vector args;
convertInput(args, input);
@@ -2437,7 +2437,7 @@ struct CSBrickParamCraftFocus : public TBrickParam::IId
return *this;
ParsedOk=true;
- NLMISC::fromString(args[0], Focus);
+ NLMISC::fromString(args[0], ChaScore4);
return *this;
}
@@ -3800,7 +3800,7 @@ struct CSBrickParamShielding : public TBrickParam::IId
};
-struct CSBrickParamLifeAura : public TBrickParam::IId
+struct CSBrickParamChaScore1Aura : public TBrickParam::IId
{
// regen modifier (in %)
uint16 RegenMod;
@@ -3808,28 +3808,28 @@ struct CSBrickParamLifeAura : public TBrickParam::IId
float Duration;
// aura radius in meters
float Radius;
- // disable life aura for x seconds on targets
+ // disable ChaScore1 aura for x seconds on targets
float TargetDisableTime;
- // disable life aura for x seconds on user
+ // disable ChaScore1 aura for x seconds on user
float UserDisableTime;
- CSBrickParamLifeAura():
+ CSBrickParamChaScore1Aura():
RegenMod(),
Duration(),
Radius(),
TargetDisableTime(),
UserDisableTime()
{
- _Id = TBrickParam::SP_LIFE_AURA;
+ _Id = TBrickParam::SP_ChaScore1_AURA;
}
- CSBrickParamLifeAura(const std::string&str)
+ CSBrickParamChaScore1Aura(const std::string&str)
{
- *this=CSBrickParamLifeAura();
+ *this=CSBrickParamChaScore1Aura();
*this=str;
}
- const CSBrickParamLifeAura& operator=(const std::string& input)
+ const CSBrickParamChaScore1Aura& operator=(const std::string& input)
{
std::vector args;
convertInput(args, input);
@@ -3849,7 +3849,7 @@ struct CSBrickParamLifeAura : public TBrickParam::IId
};
-struct CSBrickParamLifeAura2 : public TBrickParam::IId
+struct CSBrickParamChaScore1Aura2 : public TBrickParam::IId
{
// regen modifier (in %)
uint16 RegenMod;
@@ -3857,28 +3857,28 @@ struct CSBrickParamLifeAura2 : public TBrickParam::IId
float Duration;
// aura radius in meters
float Radius;
- // disable life aura for x seconds on targets
+ // disable ChaScore1 aura for x seconds on targets
float TargetDisableTime;
- // disable life aura for x seconds on user
+ // disable ChaScore1 aura for x seconds on user
float UserDisableTime;
- CSBrickParamLifeAura2():
+ CSBrickParamChaScore1Aura2():
RegenMod(),
Duration(),
Radius(),
TargetDisableTime(),
UserDisableTime()
{
- _Id = TBrickParam::SP_LIFE_AURA2;
+ _Id = TBrickParam::SP_ChaScore1_AURA2;
}
- CSBrickParamLifeAura2(const std::string&str)
+ CSBrickParamChaScore1Aura2(const std::string&str)
{
- *this=CSBrickParamLifeAura2();
+ *this=CSBrickParamChaScore1Aura2();
*this=str;
}
- const CSBrickParamLifeAura2& operator=(const std::string& input)
+ const CSBrickParamChaScore1Aura2& operator=(const std::string& input)
{
std::vector args;
convertInput(args, input);
@@ -3897,7 +3897,7 @@ struct CSBrickParamLifeAura2 : public TBrickParam::IId
}
};
-struct CSBrickParamStaminaAura : public TBrickParam::IId
+struct CSBrickParamChaScore2Aura : public TBrickParam::IId
{
// regen modifier (in %)
uint16 RegenMod;
@@ -3905,28 +3905,28 @@ struct CSBrickParamStaminaAura : public TBrickParam::IId
float Duration;
// aura radius in meters
float Radius;
- // disable life aura for x seconds on targets
+ // disable ChaScore2 aura for x seconds on targets
float TargetDisableTime;
- // disable life aura for x seconds on user
+ // disable ChaScore2 aura for x seconds on user
float UserDisableTime;
- CSBrickParamStaminaAura():
+ CSBrickParamChaScore2Aura():
RegenMod(),
Duration(),
Radius(),
TargetDisableTime(),
UserDisableTime()
{
- _Id = TBrickParam::SP_STAMINA_AURA;
+ _Id = TBrickParam::SP_ChaScore2_AURA;
}
- CSBrickParamStaminaAura(const std::string&str)
+ CSBrickParamChaScore2Aura(const std::string&str)
{
- *this=CSBrickParamStaminaAura();
+ *this=CSBrickParamChaScore2Aura();
*this=str;
}
- const CSBrickParamStaminaAura& operator=(const std::string& input)
+ const CSBrickParamChaScore2Aura& operator=(const std::string& input)
{
std::vector args;
convertInput(args, input);
@@ -3945,7 +3945,7 @@ struct CSBrickParamStaminaAura : public TBrickParam::IId
}
};
-struct CSBrickParamStaminaAura2 : public TBrickParam::IId
+struct CSBrickParamChaScore2Aura2 : public TBrickParam::IId
{
// regen modifier (in %)
uint16 RegenMod;
@@ -3953,28 +3953,28 @@ struct CSBrickParamStaminaAura2 : public TBrickParam::IId
float Duration;
// aura radius in meters
float Radius;
- // disable life aura for x seconds on targets
+ // disable ChaScore2 aura for x seconds on targets
float TargetDisableTime;
- // disable life aura for x seconds on user
+ // disable ChaScore2 aura for x seconds on user
float UserDisableTime;
- CSBrickParamStaminaAura2():
+ CSBrickParamChaScore2Aura2():
RegenMod(),
Duration(),
Radius(),
TargetDisableTime(),
UserDisableTime()
{
- _Id = TBrickParam::SP_STAMINA_AURA2;
+ _Id = TBrickParam::SP_ChaScore2_AURA2;
}
- CSBrickParamStaminaAura2(const std::string&str)
+ CSBrickParamChaScore2Aura2(const std::string&str)
{
- *this=CSBrickParamStaminaAura2();
+ *this=CSBrickParamChaScore2Aura2();
*this=str;
}
- const CSBrickParamStaminaAura2& operator=(const std::string& input)
+ const CSBrickParamChaScore2Aura2& operator=(const std::string& input)
{
std::vector args;
convertInput(args, input);
@@ -3992,7 +3992,7 @@ struct CSBrickParamStaminaAura2 : public TBrickParam::IId
return *this;
}
};
-struct CSBrickParamSapAura : public TBrickParam::IId
+struct CSBrickParamChaScore3Aura : public TBrickParam::IId
{
// regen modifier (in %)
uint16 RegenMod;
@@ -4000,28 +4000,28 @@ struct CSBrickParamSapAura : public TBrickParam::IId
float Duration;
// aura radius in meters
float Radius;
- // disable life aura for x seconds on targets
+ // disable ChaScore3 aura for x seconds on targets
float TargetDisableTime;
- // disable life aura for x seconds on user
+ // disable ChaScore3 aura for x seconds on user
float UserDisableTime;
- CSBrickParamSapAura():
+ CSBrickParamChaScore3Aura():
RegenMod(),
Duration(),
Radius(),
TargetDisableTime(),
UserDisableTime()
{
- _Id = TBrickParam::SP_SAP_AURA;
+ _Id = TBrickParam::SP_ChaScore3_AURA;
}
- CSBrickParamSapAura(const std::string&str)
+ CSBrickParamChaScore3Aura(const std::string&str)
{
- *this=CSBrickParamSapAura();
+ *this=CSBrickParamChaScore3Aura();
*this=str;
}
- const CSBrickParamSapAura& operator=(const std::string& input)
+ const CSBrickParamChaScore3Aura& operator=(const std::string& input)
{
std::vector args;
convertInput(args, input);
@@ -4040,7 +4040,7 @@ struct CSBrickParamSapAura : public TBrickParam::IId
}
};
-struct CSBrickParamSapAura2 : public TBrickParam::IId
+struct CSBrickParamChaScore3Aura2 : public TBrickParam::IId
{
// regen modifier (in %)
uint16 RegenMod;
@@ -4048,28 +4048,28 @@ struct CSBrickParamSapAura2 : public TBrickParam::IId
float Duration;
// aura radius in meters
float Radius;
- // disable life aura for x seconds on targets
+ // disable ChaScore3 aura for x seconds on targets
float TargetDisableTime;
- // disable life aura for x seconds on user
+ // disable ChaScore3 aura for x seconds on user
float UserDisableTime;
- CSBrickParamSapAura2():
+ CSBrickParamChaScore3Aura2():
RegenMod(),
Duration(),
Radius(),
TargetDisableTime(),
UserDisableTime()
{
- _Id = TBrickParam::SP_SAP_AURA2;
+ _Id = TBrickParam::SP_ChaScore3_AURA2;
}
- CSBrickParamSapAura2(const std::string&str)
+ CSBrickParamChaScore3Aura2(const std::string&str)
{
- *this=CSBrickParamSapAura2();
+ *this=CSBrickParamChaScore3Aura2();
*this=str;
}
- const CSBrickParamSapAura2& operator=(const std::string& input)
+ const CSBrickParamChaScore3Aura2& operator=(const std::string& input)
{
std::vector args;
convertInput(args, input);
@@ -4772,7 +4772,7 @@ struct CSBrickParamHeal : public TBrickParam::IId
float HealFactorValue;
// disable power for x seconds
float DisableTime;
- // type of power (Heal, HealHpC ...)
+ // type of power (Heal, HealChaScore1C ...)
std::string PowerType;
CSBrickParamHeal():
diff --git a/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_brick.h b/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_brick.h
index 2eef41e0d..0745848af 100644
--- a/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_brick.h
+++ b/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_brick.h
@@ -169,10 +169,10 @@ public:
DefensiveAfflictionCastingTimeFactor = 1.0f;
DefensiveAfflictionPowerFactor = 1.0f;
- HpBonusPerLevel = 0.0f;
- SapBonusPerLevel = 0.0f;
- StaBonusPerLevel = 0.0f;
- FocusBonusPerLevel = 0.0f;
+ ChaScore1BonusPerLevel = 0.0f;
+ ChaScore2BonusPerLevel = 0.0f;
+ ChaScore3BonusPerLevel = 0.0f;
+ ChaScore4BonusPerLevel = 0.0f;
AllowPartialSuccess= true;
}
@@ -221,10 +221,10 @@ public:
f.serial( DefensiveAfflictionCastingTimeFactor );
f.serial( DefensiveAfflictionPowerFactor );
- f.serial( HpBonusPerLevel );
- f.serial( SapBonusPerLevel );
- f.serial( StaBonusPerLevel );
- f.serial( FocusBonusPerLevel );
+ f.serial( ChaScore1BonusPerLevel );
+ f.serial( ChaScore2BonusPerLevel );
+ f.serial( ChaScore3BonusPerLevel );
+ f.serial( ChaScore4BonusPerLevel );
f.serial( AllowPartialSuccess );
@@ -313,10 +313,10 @@ public:
float DefensiveAfflictionPowerFactor;
/// stats factor
- float HpBonusPerLevel;
- float SapBonusPerLevel;
- float StaBonusPerLevel;
- float FocusBonusPerLevel;
+ float ChaScore1BonusPerLevel;
+ float ChaScore2BonusPerLevel;
+ float ChaScore3BonusPerLevel;
+ float ChaScore4BonusPerLevel;
/// Some Plans can Force no Partial Success (instead replace full success)
bool AllowPartialSuccess;
diff --git a/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_game_item.cpp b/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_game_item.cpp
index 42517c190..773dc6ff5 100644
--- a/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_game_item.cpp
+++ b/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_game_item.cpp
@@ -893,10 +893,10 @@ void loadRawMaterial( UFormElm &root, CStaticItem *item, const CSheetId &sheetId
mpFaberParameter->getValueByName( civS, "CraftCivSpec" );
v.CraftCivSpec = ITEM_ORIGIN::stringToEnum( civS );
- mpFaberParameter->getValueByName( v.HpBuff, "HpBuff" );
- mpFaberParameter->getValueByName( v.SapBuff, "SapBuff" );
- mpFaberParameter->getValueByName( v.StaBuff, "StaBuff" );
- mpFaberParameter->getValueByName( v.FocusBuff, "FocusBuff" );
+ mpFaberParameter->getValueByName( v.ChaScore1Buff, "ChaScore1Buff" );
+ mpFaberParameter->getValueByName( v.ChaScore2Buff, "ChaScore2Buff" );
+ mpFaberParameter->getValueByName( v.ChaScore3Buff, "ChaScore3Buff" );
+ mpFaberParameter->getValueByName( v.ChaScore3Buff, "ChaScore3Buff" );
item->Mp->MpFaberParameters.push_back( v );
}
diff --git a/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_game_item.h b/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_game_item.h
index 96aae2e98..a81d5502c 100644
--- a/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_game_item.h
+++ b/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_game_item.h
@@ -524,10 +524,10 @@ public:
float DefensiveAfflictionPowerFactor;
// armor and jewel buff
- sint32 HpBuff;
- sint32 SapBuff;
- sint32 StaBuff;
- sint32 FocusBuff;
+ sint32 ChaScore1Buff;
+ sint32 ChaScore2Buff;
+ sint32 ChaScore3Buff;
+ sint32 ChaScore4Buff;
TMpFaberParameters()
{
@@ -574,10 +574,10 @@ public:
DefensiveAfflictionPowerFactor = 0.0f;
// armor and jewel buff
- HpBuff = 0;
- SapBuff = 0;
- StaBuff = 0;
- FocusBuff = 0;
+ ChaScore1Buff = 0;
+ ChaScore2Buff = 0;
+ ChaScore3Buff = 0;
+ ChaScore4Buff = 0;
}
inline void serial(class NLMISC::IStream &f)
@@ -623,10 +623,10 @@ public:
f.serial( DefensiveAfflictionPowerFactor );
// armor and jewel buff
- f.serial( HpBuff );
- f.serial( SapBuff );
- f.serial( StaBuff );
- f.serial( FocusBuff );
+ f.serial( ChaScore1Buff );
+ f.serial( ChaScore2Buff );
+ f.serial( ChaScore3Buff );
+ f.serial( ChaScore4Buff );
if (f.isReading())
{
diff --git a/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_game_sheet.cpp b/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_game_sheet.cpp
index 0cc44399d..bc2b26810 100644
--- a/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_game_sheet.cpp
+++ b/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_game_sheet.cpp
@@ -465,9 +465,9 @@ void CStaticPacts::readGeorges( const NLMISC::CSmartPtr &form,
float duration;
// variable is used for calculate pact effect in differential between pacts type
- sint16 LoseHitPoints = 0;
- sint16 LoseStamina = 0;
- sint16 LoseSap = 0;
+ sint16 LoseChaScore1 = 0;
+ sint16 LoseChaScore2 = 0;
+ sint16 LoseChaScore3 = 0;
sint16 LoseSkills = 0;
sint16 value;
@@ -479,20 +479,20 @@ void CStaticPacts::readGeorges( const NLMISC::CSmartPtr &form,
if( node )
{
- node->getValueByName( value, "HitPoints" );
- value = 0 - value - LoseHitPoints;
- LoseHitPoints += value;
- PactLose[ i ].LoseHitPointsLevel = value;
+ node->getValueByName( value, "ChaScore1" );
+ value = 0 - value - LoseChaScore1;
+ LoseChaScore1 += value;
+ PactLose[ i ].LoseChaScore1Level = value;
- node->getValueByName( value, "Stamina" );
- value = 0 - value - LoseStamina;
- LoseStamina += value;
- PactLose[ i ].LoseStaminaLevel = value;
+ node->getValueByName( value, "ChaScore2" );
+ value = 0 - value - LoseChaScore2;
+ LoseChaScore2 += value;
+ PactLose[ i ].LoseChaScore2Level = value;
- node->getValueByName( value, "Sap" );
- value = 0 - value - LoseSap;
- LoseSap += value;
- PactLose[ i ].LoseSapLevel = value;
+ node->getValueByName( value, "ChaScore3" );
+ value = 0 - value - LoseChaScore3;
+ LoseChaScore3 += value;
+ PactLose[ i ].LoseChaScore3Level = value;
node->getValueByName( value, "Skills" );
value = 0 - value - LoseSkills;
@@ -598,39 +598,39 @@ void CStaticCreatures::readGeorges( const NLMISC::CSmartPtr &f
uint32 playerSkillLevel = 1;
if ( !root.getValueByName( playerSkillLevel, "Basics.PlayerSkillLevel" ) )
{
- nlwarning("ERROR For creature sheet %s, cannot read Basics.PlayerSkillLevel, creature HP may be inacurate !", sheetId.toString().c_str() );
+ nlwarning("ERROR For creature sheet %s, cannot read Basics.PlayerSkillLevel, creature ChaScore1 may be inacurate !", sheetId.toString().c_str() );
}
_NbPlayers = 1;
if ( !root.getValueByName( _NbPlayers, "Basics.NbPlayers" ) )
{
- nlwarning("ERROR For creature sheet %s, cannot read Basics.NbPlayers, creature HP may be inacurate !", sheetId.toString().c_str() );
+ nlwarning("ERROR For creature sheet %s, cannot read Basics.NbPlayers, creature ChaScore1 may be inacurate !", sheetId.toString().c_str() );
}
- sint32 hp;
- root.getValueByName( hp, "Basics.life" );
+ sint32 ChaScore1;
+ root.getValueByName( ChaScore1, "Basics.ChaScore1" );
float regen;
- root.getValueByName( regen, "Basics.LifeRegen" );
+ root.getValueByName( regen, "Basics.ChaScore1Regen" );
- if (hp == 0)
+ if (ChaScore1 == 0)
{
- nlwarning("CStaticCreatures::readGeorges : spawning a creature with 0 Hit Points ! (SHEET %s), set the hp to 100", sheetId.toString().c_str());
- hp = 100;
+ nlwarning("CStaticCreatures::readGeorges : spawning a creature with 0 ChaScore1 ! (SHEET %s), set the ChaScore1 to 100", sheetId.toString().c_str());
+ ChaScore1 = 100;
}
for( i = 0; i < SCORES::NUM_SCORES; ++i )
{
- _Scores[ i ] = hp;
+ _Scores[ i ] = ChaScore1;
_Regen[ i ] = regen;
}
///////////////////////////////////////////////////////
// Creature Damage Per Hit
///////////////////////////////////////////////////////
- _PlayerHpLevel = 1;
+ _PlayerChaScore1Level = 1;
_NbHitToKillPlayer = 10.0f;
- if ( !root.getValueByName( _PlayerHpLevel, "Basics.PlayerHpLevel" ) )
+ if ( !root.getValueByName( _PlayerChaScore1Level, "Basics.PlayerChaScore1Level" ) )
{
- nlwarning("ERROR For creature sheet %s, cannot read Basics.PlayerHpLevel, creature damage may be inacurate !", sheetId.toString().c_str() );
+ nlwarning("ERROR For creature sheet %s, cannot read Basics.PlayerChaScore1Level, creature damage may be inacurate !", sheetId.toString().c_str() );
}
if ( !root.getValueByName( _NbHitToKillPlayer, "Basics.NbHitToKillPlayer" ) )
{
@@ -643,7 +643,7 @@ void CStaticCreatures::readGeorges( const NLMISC::CSmartPtr &f
_NbHitToKillPlayer = 3.0f;
}
- _CreatureDamagePerHitWithoutAverageDodge = uint32( (100*_PlayerHpLevel) / _NbHitToKillPlayer );
+ _CreatureDamagePerHitWithoutAverageDodge = uint32( (100*_PlayerChaScore1Level) / _NbHitToKillPlayer );
compileCreatureDamagePerHit();
@@ -861,8 +861,8 @@ void CStaticCreatures::readGeorges( const NLMISC::CSmartPtr &f
// damage shield
_DamageShieldDamage = 0;
root.getValueByName( _DamageShieldDamage, "Damage Shield.Damage");
- _DamageShieldHpDrain = 0;
- root.getValueByName( _DamageShieldHpDrain, "Damage Shield.Drained HP");
+ _DamageShieldChaScore1Drain = 0;
+ root.getValueByName( _DamageShieldChaScore1Drain, "Damage Shield.Drained ChaScore1");
// action on death
if ( root.getValueByName(value, "ActionOnDeath") )
@@ -978,7 +978,7 @@ void CStaticCreatures::serial(class NLMISC::IStream &f) throw(NLMISC::EStream)
f.serial( _BagInventorySheet );
f.serial(_DamageShieldDamage);
- f.serial(_DamageShieldHpDrain);
+ f.serial(_DamageShieldChaScore1Drain);
}
///////////////////////////////////////////////////////////////////////////
@@ -1023,14 +1023,14 @@ CAttributeMapping::CAttributeMapping()
_StaticAttributeMap.insert(make_pair(std::string("basics.level"), at_level));
_StaticAttributeMap.insert(make_pair(std::string("basics.playerskilllevel"), at_player_skill_level));
_StaticAttributeMap.insert(make_pair(std::string("basics.nbplayers"), at_nb_players));
- _StaticAttributeMap.insert(make_pair(std::string("basics.playerhplevel"), at_player_hp_level));
+ _StaticAttributeMap.insert(make_pair(std::string("basics.playerChaScore1level"), at_player_ChaScore1_level));
_StaticAttributeMap.insert(make_pair(std::string("basics.nbhittokillplayer"), at_nb_hit_to_kill_player));
_StaticAttributeMap.insert(make_pair(std::string("basics.ecosystem"), at_ecosystem));
_StaticAttributeMap.insert(make_pair(std::string("basics.type"), at_type));
_StaticAttributeMap.insert(make_pair(std::string("basics.fame"), at_fame));
_StaticAttributeMap.insert(make_pair(std::string("basics.famebykill"), at_fame_by_kill));
- _StaticAttributeMap.insert(make_pair(std::string("basics.life"), at_life));
- _StaticAttributeMap.insert(make_pair(std::string("basics.liferegen"), at_liferegen));
+ _StaticAttributeMap.insert(make_pair(std::string("basics.ChaScore1"), at_ChaScore1));
+ _StaticAttributeMap.insert(make_pair(std::string("basics.ChaScore1regen"), at_ChaScore1regen));
_StaticAttributeMap.insert(make_pair(std::string("basics.attackspeed"), at_attack_speed ));
_StaticAttributeMap.insert(make_pair(std::string("basics.attacklevel"), at_attack_level));
_StaticAttributeMap.insert(make_pair(std::string("basics.defenselevel"), at_defense_level ));
@@ -1199,11 +1199,11 @@ bool CStaticCreatures::applyUserModel(CCustomElementId userModelId, const std::v
break;
}
- case at_player_hp_level:
+ case at_player_ChaScore1_level:
{
- nldebug(" Applying '%s': setting playerHpLevel to '%s'", modelId.c_str(), scriptLine[1].c_str());
- NLMISC::fromString(scriptLine[1], _PlayerHpLevel);
- _CreatureDamagePerHitWithoutAverageDodge = uint32( (100*_PlayerHpLevel) / _NbHitToKillPlayer );
+ nldebug(" Applying '%s': setting playerChaScore1Level to '%s'", modelId.c_str(), scriptLine[1].c_str());
+ NLMISC::fromString(scriptLine[1], _PlayerChaScore1Level);
+ _CreatureDamagePerHitWithoutAverageDodge = uint32( (100*_PlayerChaScore1Level) / _NbHitToKillPlayer );
compileCreatureDamagePerHit();
break;
}
@@ -1223,7 +1223,7 @@ bool CStaticCreatures::applyUserModel(CCustomElementId userModelId, const std::v
errors = true;
}
- _CreatureDamagePerHitWithoutAverageDodge = uint32( (100*_PlayerHpLevel) / _NbHitToKillPlayer );
+ _CreatureDamagePerHitWithoutAverageDodge = uint32( (100*_PlayerChaScore1Level) / _NbHitToKillPlayer );
compileCreatureDamagePerHit();
break;
}
@@ -1258,39 +1258,39 @@ bool CStaticCreatures::applyUserModel(CCustomElementId userModelId, const std::v
break;
}
- case at_life:
+ case at_ChaScore1:
{
- sint32 hp;
- NLMISC::fromString(scriptLine[1], hp);
+ sint32 ChaScore1;
+ NLMISC::fromString(scriptLine[1], ChaScore1);
- if (hp == 0)
+ if (ChaScore1 == 0)
{
- nlwarning("Error while applying user model '%s' : spawning a creature with 0 Hit Points ! set the hp to 100", modelId.c_str());
- hp = 100;
+ nlwarning("Error while applying user model '%s' : spawning a creature with 0 ChaScore1 ! set the ChaScore1 to 100", modelId.c_str());
+ ChaScore1 = 100;
errors = true;
}
- nldebug(" Applying '%s': setting Hp to '%u'", modelId.c_str(), hp);
+ nldebug(" Applying '%s': setting ChaScore1 to '%u'", modelId.c_str(), ChaScore1);
- _Scores[SCORES::hit_points] = hp;
+ _Scores[SCORES::cha_score1] = ChaScore1;
break;
}
- case at_liferegen:
+ case at_ChaScore1regen:
{
char *ptr = NULL;
- float lifeRegen = static_cast(strtod(scriptLine[1].c_str(), &ptr));
+ float ChaScore1Regen = static_cast(strtod(scriptLine[1].c_str(), &ptr));
if (ptr != NULL && *ptr == '\0' && errno != ERANGE)
{
- _Regen[SCORES::hit_points] = lifeRegen;
- nldebug(" Applying '%s' : setting lifeRegen to %f", modelId.c_str(), lifeRegen);
+ _Regen[SCORES::cha_score1] = ChaScore1Regen;
+ nldebug(" Applying '%s' : setting ChaScore1Regen to %f", modelId.c_str(), ChaScore1Regen);
}
else
{
- _Regen[SCORES::hit_points] = 1;
- nlwarning("Error while applying user model '%s': cannot read Basics.LifeRegen, set it to 1.0!", modelId.c_str() );
+ _Regen[SCORES::cha_score1] = 1;
+ nlwarning("Error while applying user model '%s': cannot read Basics.ChaScore1Regen, set it to 1.0!", modelId.c_str() );
errors = true;
}
break;
diff --git a/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_game_sheet.h b/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_game_sheet.h
index 527f5ee09..6e42a3498 100644
--- a/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_game_sheet.h
+++ b/code/ryzom/server/src/entities_game_service/egs_sheets/egs_static_game_sheet.h
@@ -239,17 +239,17 @@ class CStaticPacts
public:
struct SPact
{
- uint16 LoseHitPointsLevel;
- uint16 LoseStaminaLevel;
- uint16 LoseSapLevel;
+ uint16 LoseChaScore1Level;
+ uint16 LoseChaScore2Level;
+ uint16 LoseChaScore3Level;
uint16 LoseSkillsLevel;
NLMISC::TGameCycle Duration;
void serial(class NLMISC::IStream &f) throw(NLMISC::EStream)
{
- f.serial( LoseHitPointsLevel);
- f.serial( LoseStaminaLevel );
- f.serial( LoseSapLevel );
+ f.serial( LoseChaScore1Level);
+ f.serial( LoseChaScore2Level );
+ f.serial( LoseChaScore3Level );
f.serial( LoseSkillsLevel );
f.serial( Duration );
}
@@ -342,7 +342,7 @@ public:
// damage shield
virtual uint16 getDamageShieldDamage() const = 0;
- virtual uint16 getDamageShieldHpDrain() const = 0;
+ virtual uint16 getDamageShieldChaScore1Drain() const = 0;
//@}
///@name Methods
@@ -413,7 +413,7 @@ public:
virtual float getColWidth() const { return _Sheet->getColWidth(); }
virtual uint16 getDamageShieldDamage() const { return _Sheet->getDamageShieldDamage(); }
- virtual uint16 getDamageShieldHpDrain() const { return _Sheet->getDamageShieldHpDrain(); }
+ virtual uint16 getDamageShieldChaScore1Drain() const { return _Sheet->getDamageShieldChaScore1Drain(); }
virtual std::vector const& getMps() const { return _Sheet->getMps(); }
@@ -439,15 +439,15 @@ enum TAttributeType
at_level,
at_player_skill_level,
at_nb_players,
- at_player_hp_level,
+ at_player_ChaScore1_level,
at_nb_hit_to_kill_player,
at_ecosystem,
at_type,
at_fame,
at_fame_by_kill,
at_fame_for_guard_attack,
- at_life,
- at_liferegen,
+ at_ChaScore1,
+ at_ChaScore1regen,
at_attack_speed,
at_attack_level,
at_defense_level,
@@ -566,7 +566,7 @@ public:
virtual float getColWidth() const { return _ColWidth; }
virtual uint16 getDamageShieldDamage() const { return _DamageShieldDamage; }
- virtual uint16 getDamageShieldHpDrain() const { return _DamageShieldHpDrain; }
+ virtual uint16 getDamageShieldChaScore1Drain() const { return _DamageShieldChaScore1Drain; }
virtual std::vector const& getMps() const { return CStaticHarvestable::getMps(); }
@@ -578,7 +578,7 @@ private:
uint8 _Gender;
uint8 _Size;
uint16 _Level;
- uint32 _PlayerHpLevel;
+ uint32 _PlayerChaScore1Level;
float _NbHitToKillPlayer;
uint16 _AttackLevel;
uint16 _DefenseLevel;
@@ -632,7 +632,7 @@ private:
// damage shield
uint16 _DamageShieldDamage;
- uint16 _DamageShieldHpDrain;
+ uint16 _DamageShieldChaScore1Drain;
public:
/// read the sheet
diff --git a/code/ryzom/server/src/entities_game_service/egs_variables.cpp b/code/ryzom/server/src/entities_game_service/egs_variables.cpp
index a96452aca..25b26345c 100644
--- a/code/ryzom/server/src/entities_game_service/egs_variables.cpp
+++ b/code/ryzom/server/src/entities_game_service/egs_variables.cpp
@@ -135,7 +135,7 @@ CVariable ForageKamiAngerThreshold2(
CVariable ForageKamiAngerPunishDamage(
"egs",
- "ForageKamiPunishDamage", "Max HP hit once by an angry (invisible) kami",
+ "ForageKamiPunishDamage", "Max ChaScore1 hit once by an angry (invisible) kami",
6000,
0, true );
@@ -304,7 +304,7 @@ CVariable MaxCharacteristicValue("egs","MaxCharacteristicValue", "Max
// factor on creature and npc damage
CVariable BotDamageFactor("egs","BotDamageFactor", "Factor applied on all Bots (creature and npcs) damage", 1.0f, 0, true );
-CVariable HitChestStaLossFactor("egs","HitChestStaLossFactor", "factor of damage also lost in sta when hit to chest", 0.5f, 0, true );
+CVariable HitChestChaScore2LossFactor("egs","HitChestChaScore2LossFactor", "factor of damage also lost in ChaScore2 when hit to chest", 0.5f, 0, true );
CVariable HitHeadStunDuration("egs","HitHeadStunDuration", "duration (in seconds) of a stun when hit to head", 2.5f, 0, true );
CVariable HitArmsSlowDuration("egs","HitArmsSlowDuration", "duration (in seconds) of a slow attack when hit to arms", 5.0f, 0, true );
CVariable HitArmsSlowFactor("egs","HitArmsSlowFactor", "slowing factor when hit to arms (+20 = +20% to attack latency)", 50, 0, true );
@@ -375,7 +375,7 @@ CVariable ForageExtractionCareEcoSpecFactor( "egs", "ForageExtractionCare
CVariable ForageExtractionNaturalDDeltaPerTick( "egs", "ForageExtractionNaturalDDeltaPerTick", "D increase per tick", 0.1f, 0, true );
CVariable ForageExtractionNaturalEDeltaPerTick( "egs", "ForageExtractionNaturalEDeltaPerTick", "E increase per tick", 0.1f, 0, true );
-CVariable ForageHPRatioPerSourceLifeImpact( "egs", "HPRatioPerSourceLifeImpact", "Ratio of HP damaged per source life (D) impact value", 0.003937f, 0, true ); // 1/127 / 2
+CVariable ForageChaScore1RatioPerSourceLifeImpact( "egs", "ChaScore1RatioPerSourceLifeImpact", "Ratio of ChaScore1 damaged per source life (D) impact value", 0.003937f, 0, true ); // 1/127 / 2
CVariable ForageCareFactor( "egs","ForageCareFactor","Factor for care delta", 4.0f,0, true );
CVariable ForageCareBeginZone( "egs", "ForageCareBeginZone", "", 5.0f, 0, true );
@@ -384,8 +384,8 @@ CVariable ForageExtractionXPFactor( "egs", "ForageExtractionXPFactor", ""
CVariable ForageExtractionNbParticipantsXPBonusRatio( "egs", "ForageExtractionNbParticipantsXPBonusRatio", "", 0.1f, 0, true );
CVariable ForageExtractionNastyEventXPMalusRatio( "egs", "ForageExtractionNastyEventXPMalusRatio", "", 0.1f, 0, true );
-CVariable ToxicCloudDamage( "egs","ToxicCloudDamage", "Max HP hit by a toxic cloud at ToxicCloudUpdateFrequency", 800.0f, true );
-CVariable ForageExplosionDamage( "egs","ForageExplosionDamage", "Max HP hit once by a forage explosion", 4000.0f, true );
+CVariable ToxicCloudDamage( "egs","ToxicCloudDamage", "Max ChaScore1 hit by a toxic cloud at ToxicCloudUpdateFrequency", 800.0f, true );
+CVariable ForageExplosionDamage( "egs","ForageExplosionDamage", "Max ChaScore1 hit once by a forage explosion", 4000.0f, true );
CVariable FameByKill( "egs","FameByKill", "Number of fame point lost for a kill", -5000, true );
@@ -441,7 +441,7 @@ CVariable ForageKamiOfferingSpeed( "egs","ForageKamiOfferingSpeed",
CVariable ForageReduceDamageTimeWindow( "egs", "ForageReduceDamageTimeWindow", "Time in tick before a blowing up when Reduce Damage actions are taken into account", 30, 0, true ); // 3 s
CVariable ForageDebug( "egs","ForageDebug",
- "Debug mode for forage phrases (0=normal 2=focusOnly 5=focus+skill 7=prospectionWithVariables 10=fullCheat)", 0,
+ "Debug mode for forage phrases (0=normal 2=ChaScore4Only 5=ChaScore4+skill 7=prospectionWithVariables 10=fullCheat)", 0,
0, true );
CVariable ForageSourceSpawnDelay( "egs","ForageSourceSpawnDelay",
"Time (ticks) between end of prospection & spawning the source(s)",
@@ -453,7 +453,7 @@ CVariable ForageValidateSourcesSpawnPos( "egs", "ForageValidateSourcesSpaw
CVariable ForageRange( "egs","ForageRange", "", 0, 0, false );
CVariable ForageAngle( "egs","ForageAngle", "", 0, 0, false );
CVariable ForageLevel( "egs","ForageLevel", "", 0, 0, false );
-CVariable ForageFocusRatioOfLocateDeposit( "egs", "ForageFocusRatioOfLocateDeposit", "", 10, 0, true );
+CVariable ForageChaScore4RatioOfLocateDeposit( "egs", "ForageChaScore4RatioOfLocateDeposit", "", 10, 0, true );
CVariable ForageQuantityXPDeltaLevelBonusRate( "egs", "ForageQuantityXPDeltaLevelBonusRate", "Delta level increase per qtty unit (except 1st one)", 2.0f, 0, true );
CVariable QuarteringQuantityAverageForCraftHerbivore( "egs", "QuarteringQuantityAverageForCraftHerbivore", "Control the global quantity in quartering for craft RMs of herbivores (H/B/P)", 1.0f, 0, true );
@@ -488,7 +488,7 @@ NLMISC::CVariable MessageOfTheDay("egs","MessageOfTheDay", "Message
NLMISC::CVariable MaxDistanceGooDamage("egs","MaxDistanceGooDamage", "the maximum distance when character take damage from goo path", 100.0f, 0, true );
NLMISC::CVariable DeathGooDistance("egs","DeathGooDistance", "the distance when character take 100% damage from goo path", 1.0f, 0, true );
-NLMISC::CVariable MaxGooDamageRatio("egs","MaxGooDamageRatio", "the factor applied goo damage for calculate effective goo damage (distance = 0 - 100% * ratio * base hp = damages)", 0.5f, 0, true );
+NLMISC::CVariable MaxGooDamageRatio("egs","MaxGooDamageRatio", "the factor applied goo damage for calculate effective goo damage (distance = 0 - 100% * ratio * base ChaScore1 = damages)", 0.5f, 0, true );
NLMISC::CVariable NBTickForGooDamageRate("egs","NBTickForGooDamageRate", "nb tick needed for apply goo damage again", 5, 0, true );
NLMISC::CVariable NBTickForNewbieGooDamageRate("egs","NBTickForNewbieGooDamageRate", "nb tick needed for apply goo damage again in newbieland", 10, 0, true );
NLMISC::CVariable NewbieGooDamageFactor("egs","NewbieGooDamageFactor", "percentage of life lost at maximum from goo in newbieland", .2f, 0, true );
diff --git a/code/ryzom/server/src/entities_game_service/egs_variables.h b/code/ryzom/server/src/entities_game_service/egs_variables.h
index 661564987..21ba34858 100644
--- a/code/ryzom/server/src/entities_game_service/egs_variables.h
+++ b/code/ryzom/server/src/entities_game_service/egs_variables.h
@@ -187,7 +187,7 @@ extern NLMISC::CVariable RegenReposFactor;
extern NLMISC::CVariable RegenOffset;
extern NLMISC::CVariable MaxCharacteristicValue;
extern NLMISC::CVariable BotDamageFactor;
-extern NLMISC::CVariable HitChestStaLossFactor;
+extern NLMISC::CVariable HitChestChaScore2LossFactor;
extern NLMISC::CVariable HitHeadStunDuration;
extern NLMISC::CVariable HitArmsSlowDuration;
extern NLMISC::CVariable HitArmsSlowFactor;
@@ -259,7 +259,7 @@ extern NLMISC::CVariable ForageExtractionAbsorptionEcoSpecMax;
extern NLMISC::CVariable