diff --git a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.chn b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.chn
index f692c04..510b4ea 100644
--- a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.chn
+++ b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.chn
@@ -1,8 +1,8 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="未来战斗"
-AbilityTreeTitles[1]="战争机器"
-AbilityTreeTitles[2]="XCOM"
-
[UISL_CPS]
strDisablePopup = "不要再显示此消息"
-strPopupText = "\n你好, 这是你的Mod [WOTC] Community Promotion Screen\n\n我检测到你所使用的Mod [WOTC] New Promotion Screen by Default是旧的版本. Mod[WOTC] New Promotion Screen by Default仍会生效, 但是你并不需要它\n\n我会代替处理[WOTC] New Promotion Screen by Default的一切以及更多,同时兼容其他所需要它的Mod. 因此建议你停用或卸载[WOTC] New Promotion Screen by Default"
\ No newline at end of file
+strPopupText = "\n你好, 这是你的Mod [WOTC] Community Promotion Screen\n\n我检测到你所使用的Mod [WOTC] New Promotion Screen by Default是旧的版本. Mod[WOTC] New Promotion Screen by Default仍会生效, 但是你并不需要它\n\n我会代替处理[WOTC] New Promotion Screen by Default的一切以及更多,同时兼容其他所需要它的Mod. 因此建议你停用或卸载[WOTC] New Promotion Screen by Default"
+
+[X2EventListener_PromotionScreenOverrides]
+SparkAbilityTreeTitles[0]="未来战斗"
+SparkAbilityTreeTitles[1]="战争机器"
+SparkAbilityTreeTitles[2]="XCOM"
diff --git a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.cht b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.cht
index f468530..aea29ae 100644
--- a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.cht
+++ b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.cht
@@ -1,9 +1,8 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="未來戰鬥"
-AbilityTreeTitles[1]="戰爭機器"
-AbilityTreeTitles[2]="XCOM"
-
[UISL_CPS]
strDisablePopup = "不要再顯示此消息"
strPopupText = "\n你好, 這是你的Mod [WOTC] Community Promotion Screen\n\n我檢測到你所使用的Mod [WOTC] New Promotion Screen by Default是舊的版本.Mod[WOTC] New Promotion Screen by Default仍會生效, 但是你並不需要它\n\n我會代替處理[WOTC] New Promotion Screen by Default的一切以及更多,同時兼容其他所需要它的Mod. 因此建議你停用或卸載[WOTC] New Promotion Screen by Default"
+[X2EventListener_PromotionScreenOverrides]
+SparkAbilityTreeTitles[0]="未來戰鬥"
+SparkAbilityTreeTitles[1]="戰爭機器"
+SparkAbilityTreeTitles[2]="XCOM"
diff --git a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.deu b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.deu
index f17a387..2b09a8b 100644
--- a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.deu
+++ b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.deu
@@ -1,8 +1,8 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="Kampf der Zukunft"
-AbilityTreeTitles[1]="Kriegsmaschine"
-AbilityTreeTitles[2]="XCOM"
-
[UISL_CPS]
strDisablePopup = "NICHT WIEDER ZEIGEN"
strPopupText = "\nHallo, hier spricht eine deiner Modifikationen, [WOTC] Community Promotion Screenn\nIch stelle fest das du eine überholte Version verwendest: [WOTC] Community Promotion Screen. Diese Version funktioniert weiterhin, aber du brauchst sie nicht.\n\nIch habe alle Funktionen von [WOTC] Community Promotion Screen und noch mehr, und alle Modifikationen, die diese alte Version benötigen, funktionieren auch mit mir.\n\nEs ist empfohlen dass du [WOTC] Community Promotion Screen deaktivierst oder deinstallierst. Ich übernehme alle ihre Aufgaben."
+
+[X2EventListener_PromotionScreenOverrides]
+SparkAbilityTreeTitles[0]="Kampf der Zukunft"
+SparkAbilityTreeTitles[1]="Kriegsmaschine"
+SparkAbilityTreeTitles[2]="XCOM"
diff --git a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.esn b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.esn
index c90eec3..0901cf2 100644
--- a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.esn
+++ b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.esn
@@ -1,8 +1,8 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="Combate del futuro"
-AbilityTreeTitles[1]="Máquina de guerra"
-AbilityTreeTitles[2]="XCOM"
-
[UISL_CPS]
strDisablePopup = "DESACTIVAR ESTE MENSAJE"
strPopupText = "\nBienvenido. Éste es tu mod en uso, [WOTC] Community Promotion Screen.\n\nVeo que también tienes activada otra versión más antigua: [WOTC] New Promotion Screen by Default. Funciona, pero no es necesario.\n\nYo ([WOTC] Community Promotion Screen) hago todo lo que [WOTC] New Promotion Screen by Default puede y más; por tanto, funciono también con cualquier mod que requiere [WOTC] New Promotion Screen by Default.\n\nSe recomienda que desactives o desinstales [WOTC] New Promotion Screen by Default. [WOTC] Community Promotion Screen ejecutará las misjmas funciones."
+
+[X2EventListener_PromotionScreenOverrides]
+SparkAbilityTreeTitles[0]="Combate del futuro"
+SparkAbilityTreeTitles[1]="Máquina de guerra"
+SparkAbilityTreeTitles[2]="XCOM"
diff --git a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.fra b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.fra
index 6b8bbd0..9fcf042 100644
--- a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.fra
+++ b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.fra
@@ -1,8 +1,8 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="Combat du futur"
-AbilityTreeTitles[1]="Machine de guerre"
-AbilityTreeTitles[2]="XCOM"
-
[UISL_CPS]
strDisablePopup = "NE PLUS AFFICHER CE MESSAGE"
-strPopupText = "\nBonjour, c'est votre mod, [WOTC] Community Promotion Screen.\n\nJe vois que vous utilisez une version désuète: [WOTC] New Promotion Screen by Default. Elle fonctionne, mais vous n'en avez plus besoin.\n\nJe fais tout ce que [WOTC] New Promotion Screen by Default fait et plus encore et je fonctionne avec avec tous les mods qui en ont besoin.\n\nJe vous recommande de désactiver ou désinstaller [WOTC] New Promotion Screen by Default. Je prendrai en charge ses fonctions."
\ No newline at end of file
+strPopupText = "\nBonjour, c'est votre mod, [WOTC] Community Promotion Screen.\n\nJe vois que vous utilisez une version désuète: [WOTC] New Promotion Screen by Default. Elle fonctionne, mais vous n'en avez plus besoin.\n\nJe fais tout ce que [WOTC] New Promotion Screen by Default fait et plus encore et je fonctionne avec avec tous les mods qui en ont besoin.\n\nJe vous recommande de désactiver ou désinstaller [WOTC] New Promotion Screen by Default. Je prendrai en charge ses fonctions."
+
+[X2EventListener_PromotionScreenOverrides]
+SparkAbilityTreeTitles[0]="Combat du futur"
+SparkAbilityTreeTitles[1]="Machine de guerre"
+SparkAbilityTreeTitles[2]="XCOM"
diff --git a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.int b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.int
index 359900a..478d42c 100644
--- a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.int
+++ b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.int
@@ -26,3 +26,8 @@ DISABLE_NEWCLASS_POPUPS_Tips = "Normally a popup is displayed each time a rookie
DISABLE_COMINT_POPUPS_Label = "Disable Combat Intelligence tutorial popup"
DISABLE_COMINT_POPUPS_Tips = "Normally a popup is displayed when you enter the promotion screen of a high Combat Intelligence soldier for the first time in a campaign. You can disable this popup here."
+
+[X2EventListener_PromotionScreenOverrides]
+SparkAbilityTreeTitles[0]="Future Combat"
+SparkAbilityTreeTitles[1]="War Machine"
+SparkAbilityTreeTitles[2]="XCOM"
diff --git a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.ita b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.ita
index 0b62e6d..50608a9 100644
--- a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.ita
+++ b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.ita
@@ -1,8 +1,8 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="Guerra del futuro"
-AbilityTreeTitles[1]="Macchina da guerra"
-AbilityTreeTitles[2]="XCOM"
-
[UISL_CPS]
strDisablePopup = "NON MOSTRARE DI NUOVO"
strPopupText = "\nCiao, questo è un messaggio della mod [WOTC] Community Promotion Screen.\n\nStai usando una versione obsoleta di questa mod, [WOTC] New Promotion Screen by Default. La cosa non creerà alcun conflitto, ma non è necessario tenerla attiva.\n\n[WOTC] Community Promotion Screen ha tutte le funzionalità di [WOTC] New Promotion Screen by Default ed oltre, e funziona con tutte le mod che la indicano come mod necessaria.\n\nÈ consigliato disinstallare o disabilitare [WOTC] New Promotion Screen by Default."
+
+[X2EventListener_PromotionScreenOverrides]
+SparkAbilityTreeTitles[0]="Guerra del futuro"
+SparkAbilityTreeTitles[1]="Macchina da guerra"
+SparkAbilityTreeTitles[2]="XCOM"
diff --git a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.jpn b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.jpn
index d5976a6..7046b6b 100644
--- a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.jpn
+++ b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.jpn
@@ -1,8 +1,8 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="未来の戦闘"
-AbilityTreeTitles[1]="ウォー・マシーン"
-AbilityTreeTitles[2]="XCOM"
-
[UISL_CPS]
strDisablePopup = "次回から表示しない"
strPopupText = "\nこんにちは、[WOTC] Community Promotion Screenです。\n\n[WOTC] New Promotion Screen by Defaultを使用しているようですが、[WOTC] Community Promotion Screenは[WOTC] New Promotion Screen by Defaultの上位互換となっており、かつ[WOTC] New Promotion Screen by Defaultが前提とするMODにも互換性がありますので、[WOTC] New Promotion Screen by Defaultを無効化、あるいはアンインストールすることをお勧めします。"
+
+[X2EventListener_PromotionScreenOverrides]
+SparkAbilityTreeTitles[0]="未来の戦闘"
+SparkAbilityTreeTitles[1]="ウォー・マシーン"
+SparkAbilityTreeTitles[2]="XCOM"
diff --git a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.kor b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.kor
index d99a5df..8a1ca3f 100644
--- a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.kor
+++ b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.kor
@@ -1,8 +1,8 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="미래 전투"
-AbilityTreeTitles[1]="워머신"
-AbilityTreeTitles[2]="XCOM"
-
[UISL_CPS]
strDisablePopup = "다시 표시하지 않음."
strPopupText = "\n안녕하세요 이것은 당신이 설치한 모드 [WOTC] Community Promotion Screen 입니다.\n\n구버전인 [WOTC] New Promotion Screen by Default를 사용하고 있습니다. 작동은 하지만, 필요하지 않습니다.\n\n이는 [WOTC] New Promotion Screen by Default가 하는 일이나 그 이상의 일을 하고 있으며, 그것을 필요로 하는 모든 모드와 함께 작동합니다.\n\n[WOTC] New Promotion Screen by Default를 비활성화하거나 제거하는 것이 좋습니다."
+
+[X2EventListener_PromotionScreenOverrides]
+SparkAbilityTreeTitles[0]="미래 전투"
+SparkAbilityTreeTitles[1]="워머신"
+SparkAbilityTreeTitles[2]="XCOM"
diff --git a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.pol b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.pol
index a64dd9e..8b72e65 100644
--- a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.pol
+++ b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.pol
@@ -1,8 +1,8 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="Walka przyszłości"
-AbilityTreeTitles[1]="Machina bojowa"
-AbilityTreeTitles[2]="XCOM"
-
[UISL_CPS]
strDisablePopup = "Wyłącz tę wiadomość"
strPopupText = "\nCześć, tu twój mod [WOTC] Community Promotion Screen.\n\nWidzę że używasz przestarzałą wersję: [WOTC] New Promotion Screen by Default.\n\nOna działa, ale jej nie potrzebujesz. Robię wszystko co [WOTC] New Promotion Screen by Default robi I więcej, i działam z wszystkimi wymaganymi modami.\n\nZalecam aby zdezaktywować lub usunąć [WOTC] New Promotion Screen by Default, gdyż przejmę jej funkcje."
+
+[X2EventListener_PromotionScreenOverrides]
+SparkAbilityTreeTitles[0]="Walka przyszłości"
+SparkAbilityTreeTitles[1]="Machina bojowa"
+SparkAbilityTreeTitles[2]="XCOM"
diff --git a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.rus b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.rus
index 1f427be..18bca5a 100644
--- a/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.rus
+++ b/X2WOTCCommunityPromotionScreen/Localization/X2WOTCCommunityPromotionScreen.rus
@@ -1,8 +1,8 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="Битва будущего"
-AbilityTreeTitles[1]="Боевая машина"
-AbilityTreeTitles[2]="XCOM"
-
[UISL_CPS]
strDisablePopup = "ОТКЛЮЧИТЬ ЭТО СООБЩЕНИЕ"
strPopupText = "\nПривет, это ваш мод - [WOTC] Community Promotion Screen.\n\nЯ вижу, вы используете одновременно со мной устаревшую версию - [WOTC] New Promotion Screen by Default. С ней всё нормально, но вам она уже не нужна.\n\nЯ умею всё, что делал [WOTC] New Promotion Screen by Default и многое другое, и я работаю со всеми модами, что его требуют.\n\nРекомендуется отключить или удалить [WOTC] New Promotion Screen by Default - я возьму его функции на себя."
+
+[X2EventListener_PromotionScreenOverrides]
+SparkAbilityTreeTitles[0]="Битва будущего"
+SparkAbilityTreeTitles[1]="Боевая машина"
+SparkAbilityTreeTitles[2]="XCOM"
diff --git a/X2WOTCCommunityPromotionScreen/Localization/XComGame.chn b/X2WOTCCommunityPromotionScreen/Localization/XComGame.chn
deleted file mode 100644
index b97f957..0000000
--- a/X2WOTCCommunityPromotionScreen/Localization/XComGame.chn
+++ /dev/null
@@ -1,4 +0,0 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="未来战斗"
-AbilityTreeTitles[1]="战争机器"
-AbilityTreeTitles[2]="XCOM"
\ No newline at end of file
diff --git a/X2WOTCCommunityPromotionScreen/Localization/XComGame.cht b/X2WOTCCommunityPromotionScreen/Localization/XComGame.cht
deleted file mode 100644
index 1089893..0000000
--- a/X2WOTCCommunityPromotionScreen/Localization/XComGame.cht
+++ /dev/null
@@ -1,4 +0,0 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="未來戰鬥"
-AbilityTreeTitles[1]="戰爭機器"
-AbilityTreeTitles[2]="XCOM"
\ No newline at end of file
diff --git a/X2WOTCCommunityPromotionScreen/Localization/XComGame.deu b/X2WOTCCommunityPromotionScreen/Localization/XComGame.deu
deleted file mode 100644
index be160da..0000000
--- a/X2WOTCCommunityPromotionScreen/Localization/XComGame.deu
+++ /dev/null
@@ -1,4 +0,0 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="Kampf der Zukunft"
-AbilityTreeTitles[1]="Kriegsmaschine"
-AbilityTreeTitles[2]="XCOM"
\ No newline at end of file
diff --git a/X2WOTCCommunityPromotionScreen/Localization/XComGame.esn b/X2WOTCCommunityPromotionScreen/Localization/XComGame.esn
deleted file mode 100644
index 2bb7bf8..0000000
--- a/X2WOTCCommunityPromotionScreen/Localization/XComGame.esn
+++ /dev/null
@@ -1,4 +0,0 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="Combate del futuro"
-AbilityTreeTitles[1]="Máquina de guerra"
-AbilityTreeTitles[2]="XCOM"
\ No newline at end of file
diff --git a/X2WOTCCommunityPromotionScreen/Localization/XComGame.fra b/X2WOTCCommunityPromotionScreen/Localization/XComGame.fra
deleted file mode 100644
index be4b31e..0000000
--- a/X2WOTCCommunityPromotionScreen/Localization/XComGame.fra
+++ /dev/null
@@ -1,4 +0,0 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="Combat du futur"
-AbilityTreeTitles[1]="Machine de guerre"
-AbilityTreeTitles[2]="XCOM"
\ No newline at end of file
diff --git a/X2WOTCCommunityPromotionScreen/Localization/XComGame.int b/X2WOTCCommunityPromotionScreen/Localization/XComGame.int
deleted file mode 100644
index 279801d..0000000
--- a/X2WOTCCommunityPromotionScreen/Localization/XComGame.int
+++ /dev/null
@@ -1,4 +0,0 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="Future Combat"
-AbilityTreeTitles[1]="War Machine"
-AbilityTreeTitles[2]="XCOM"
\ No newline at end of file
diff --git a/X2WOTCCommunityPromotionScreen/Localization/XComGame.ita b/X2WOTCCommunityPromotionScreen/Localization/XComGame.ita
deleted file mode 100644
index 702b14a..0000000
--- a/X2WOTCCommunityPromotionScreen/Localization/XComGame.ita
+++ /dev/null
@@ -1,4 +0,0 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="Guerra del futuro"
-AbilityTreeTitles[1]="Macchina da guerra"
-AbilityTreeTitles[2]="XCOM"
\ No newline at end of file
diff --git a/X2WOTCCommunityPromotionScreen/Localization/XComGame.jpn b/X2WOTCCommunityPromotionScreen/Localization/XComGame.jpn
deleted file mode 100644
index e19648d..0000000
--- a/X2WOTCCommunityPromotionScreen/Localization/XComGame.jpn
+++ /dev/null
@@ -1,4 +0,0 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="未来の戦闘"
-AbilityTreeTitles[1]="ウォー・マシーン"
-AbilityTreeTitles[2]="XCOM"
\ No newline at end of file
diff --git a/X2WOTCCommunityPromotionScreen/Localization/XComGame.kor b/X2WOTCCommunityPromotionScreen/Localization/XComGame.kor
deleted file mode 100644
index 7dc9ede..0000000
--- a/X2WOTCCommunityPromotionScreen/Localization/XComGame.kor
+++ /dev/null
@@ -1,4 +0,0 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="미래 전투"
-AbilityTreeTitles[1]="워머신"
-AbilityTreeTitles[2]="XCOM"
\ No newline at end of file
diff --git a/X2WOTCCommunityPromotionScreen/Localization/XComGame.pol b/X2WOTCCommunityPromotionScreen/Localization/XComGame.pol
deleted file mode 100644
index 383238d..0000000
--- a/X2WOTCCommunityPromotionScreen/Localization/XComGame.pol
+++ /dev/null
@@ -1,4 +0,0 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="Walka przyszłości"
-AbilityTreeTitles[1]="Machina bojowa"
-AbilityTreeTitles[2]="XCOM"
\ No newline at end of file
diff --git a/X2WOTCCommunityPromotionScreen/Localization/XComGame.rus b/X2WOTCCommunityPromotionScreen/Localization/XComGame.rus
deleted file mode 100644
index 3faf41e..0000000
--- a/X2WOTCCommunityPromotionScreen/Localization/XComGame.rus
+++ /dev/null
@@ -1,4 +0,0 @@
-[Spark X2SoldierClassTemplate]
-AbilityTreeTitles[0]="Битва будущего"
-AbilityTreeTitles[1]="Боевая машина"
-AbilityTreeTitles[2]="XCOM"
\ No newline at end of file
diff --git a/X2WOTCCommunityPromotionScreen/Src/X2WOTCCommunityPromotionScreen/Classes/X2EventListener_PromotionScreenOverrides.uc b/X2WOTCCommunityPromotionScreen/Src/X2WOTCCommunityPromotionScreen/Classes/X2EventListener_PromotionScreenOverrides.uc
index 82edf2b..ee5786b 100644
--- a/X2WOTCCommunityPromotionScreen/Src/X2WOTCCommunityPromotionScreen/Classes/X2EventListener_PromotionScreenOverrides.uc
+++ b/X2WOTCCommunityPromotionScreen/Src/X2WOTCCommunityPromotionScreen/Classes/X2EventListener_PromotionScreenOverrides.uc
@@ -6,6 +6,11 @@
//---------------------------------------------------------------------------------------
class X2EventListener_PromotionScreenOverrides extends X2EventListener config(PromotionUIMod);
+// Issue #44
+// The SPARK ability tree titles to use if no other mod has set
+// them (since the base game doesn't provide any itself).
+var localized array SparkAbilityTreeTitles;
+
static function array CreateTemplates()
{
local array Templates;
@@ -25,74 +30,106 @@ static function CHEventListenerTemplate CreateListeners()
// they can do so even with default priority.
Template.AddCHEvent('OverridePromotionBlueprintTagPrefix', OverridePromotionBlueprintTagPrefix, ELD_Immediate, 40);
Template.AddCHEvent('OverridePromotionUIClass', OverridePromotionUIClass, ELD_Immediate, 40);
+ Template.AddCHEvent('OverrideLocalizedAbilityTreeTitle', FixSparkAbilityTitles, ELD_Immediate, 30);
Template.RegisterInStrategy = true;
return Template;
}
static function EventListenerReturn OverridePromotionBlueprintTagPrefix(
- Object EventData,
- Object EventSource,
- XComGameState GameState,
- Name InEventID,
- Object CallbackData)
+ Object EventData,
+ Object EventSource,
+ XComGameState GameState,
+ Name InEventID,
+ Object CallbackData)
{
local XComLWTuple Tuple;
local XComGameState_Unit UnitState;
local UIAfterAction AfterActionScreen;
Tuple = XComLWTuple(EventData);
- if (Tuple == none)
- {
- return ELR_NoInterrupt;
- }
+ if (Tuple == none)
+ {
+ return ELR_NoInterrupt;
+ }
UnitState = XComGameState_Unit(Tuple.Data[0].o);
if (UnitState == none)
{
return ELR_NoInterrupt;
- }
+ }
- AfterActionScreen = UIAfterAction(EventSource);
+ AfterActionScreen = UIAfterAction(EventSource);
if (AfterActionScreen == none)
{
return ELR_NoInterrupt;
- }
+ }
// CPS will change the soldier's position on the promotion screen, unless they are a psi operative.
- if (!UnitState.IsPsiOperative())
- {
- Tuple.Data[1].s = UnitState.IsGravelyInjured() ?
- AfterActionScreen.UIBlueprint_PrefixHero_Wounded :
- AfterActionScreen.UIBlueprint_PrefixHero;
- }
-
- return ELR_NoInterrupt;
+ if (!UnitState.IsPsiOperative())
+ {
+ Tuple.Data[1].s = UnitState.IsGravelyInjured() ?
+ AfterActionScreen.UIBlueprint_PrefixHero_Wounded :
+ AfterActionScreen.UIBlueprint_PrefixHero;
+ }
+
+ return ELR_NoInterrupt;
}
static function EventListenerReturn OverridePromotionUIClass(
- Object EventData,
- Object EventSource,
- XComGameState GameState,
- Name InEventID,
- Object CallbackData)
+ Object EventData,
+ Object EventSource,
+ XComGameState GameState,
+ Name InEventID,
+ Object CallbackData)
{
- local XComLWTuple Tuple;
- local CHLPromotionScreenType ScreenType;
+ local XComLWTuple Tuple;
+ local CHLPromotionScreenType ScreenType;
Tuple = XComLWTuple(EventData);
- if (Tuple == none)
- {
- return ELR_NoInterrupt;
- }
+ if (Tuple == none)
+ {
+ return ELR_NoInterrupt;
+ }
- ScreenType = CHLPromotionScreenType(Tuple.Data[0].i);
+ ScreenType = CHLPromotionScreenType(Tuple.Data[0].i);
// CPS will always replace standard and hero promotion screens.
- if (ScreenType == eCHLPST_Hero || ScreenType == eCHLPST_Standard)
- {
- Tuple.Data[1].o = class'X2WOTCCommunityPromotionScreen.CPS_UIArmory_PromotionHero';
- }
+ if (ScreenType == eCHLPST_Hero || ScreenType == eCHLPST_Standard)
+ {
+ Tuple.Data[1].o = class'X2WOTCCommunityPromotionScreen.CPS_UIArmory_PromotionHero';
+ }
+
+ return ELR_NoInterrupt;
+}
- return ELR_NoInterrupt;
-}
\ No newline at end of file
+// Issue #44: Add ability tree titles for SPARKs if there aren't any set up yet
+static function EventListenerReturn FixSparkAbilityTitles(
+ Object EventData,
+ Object EventSource,
+ XComGameState GameState,
+ Name InEventID,
+ Object CallbackData)
+{
+ local XComGameState_Unit UnitState;
+ local XComLWTuple Tuple;
+ local int Row, i;
+
+ Tuple = XComLWTuple(EventData);
+ if (Tuple == none)
+ return ELR_NoInterrupt;
+
+ UnitState = XComGameState_Unit(EventSource);
+ if (UnitState == none)
+ return ELR_NoInterrupt;
+
+ Row = Tuple.Data[0].i;
+
+ if (UnitState.GetSoldierClassTemplateName() == 'Spark' &&
+ UnitState.GetSoldierClassTemplate().AbilityTreeTitles.Length == 0)
+ {
+ Tuple.Data[1].s = default.SparkAbilityTreeTitles[Row];
+ }
+
+ return ELR_NoInterrupt;
+}