diff --git a/GameEngine/Alliance.php b/GameEngine/Alliance.php index 20d2d556..b2383ca6 100755 --- a/GameEngine/Alliance.php +++ b/GameEngine/Alliance.php @@ -271,11 +271,8 @@ class Alliance { ); // Trimite invitație și prin mesaj în joc (dacă este activată funcționalitatea nouă) if (NEW_FUNCTIONS_ALLIANCE_INVITATION) { - $messageBody = "Hi, " . $UserData['username'] . "!\n\n" . - "This is to inform you that you have been invited to join an alliance. " . - "To accept this invitation, please visit your Embassy.\n\n" . - "Yours sincerely,\nServer Robot :)"; - $database->sendMessage($UserData['id'], 4, 'Invitation to Alliance', $database->escape($messageBody), 0, 0, 0, 0, 0, true); + $messageBody = rc_tok('MSG_INVITE_BODY', $UserData['username']); + $database->sendMessage($UserData['id'], 4, rc_tok('MSG_INVITE_ALLIANCE'), $database->escape($messageBody), 0, 0, 0, 0, 0, true); } } } @@ -599,7 +596,7 @@ class Alliance { } if (!$valid) { $form->addError("founder", FOUNDER_LEAVE_INVALID); return; } // Mesaj specific pentru quit voluntar - $messageBody = "Hi!\n\nThis is to inform you that the former leader of your alliance - " . $database->escape($session->username) . ", has decided to quit and elected you as his replacement. You now gain full access, administration and responsibilities to your alliance.\n\nGood luck!\n\nYours sincerely,\nServer Robot :)"; + $messageBody = rc_tok('MSG_QUIT_REPLACEMENT_BODY', "" . $database->escape($session->username) . ""); // Folosim metoda centralizată cu mesaj custom $database->promoteNewAllianceLeader($allyId, $newFounderID, $uid, $newFounderName, ['username' => $session->username, 'id' => $uid], $messageBody); $_SESSION['alliance_user'] = 0; diff --git a/GameEngine/Database.php b/GameEngine/Database.php index 52484110..4135fe9d 100755 --- a/GameEngine/Database.php +++ b/GameEngine/Database.php @@ -3016,8 +3016,13 @@ class MYSQLi_DB implements IDbConnection { $this->sendMessage( (int) $row['owner'], 4, - 'New Message in Forum', - "Hi!\n\n".$this->escape($session->username)." posted a new message into your common topic. Here\\'s a link that will get you there: forum link\n\nYours sincerely,\nServer Robot :)", + rc_tok('MSG_FORUM_NEW_TITLE'), + rc_tok( + 'MSG_FORUM_NEW_BODY', + rtrim(SERVER, '/')."/spieler.php?uid=".(int) $session->uid, + $this->escape($session->username), + rtrim(SERVER, '/')."/allianz.php?s=2&pid=2&fid2=$fid2&tid=$tids" + ), 0, 0, 0, @@ -5038,10 +5043,10 @@ $q = "INSERT INTO ".TB_PREFIX."demolition VALUES ( $this->evictUserFromAlliance($userData['id']); $this->deleteAlliPermissions($userData['id']); - $msgTitle = $demolition ? 'You left the alliance' : 'An attack has forced you to leave the alliance'; + $msgTitle = $demolition ? rc_tok('MSG_LEFT_ALLIANCE_TITLE') : rc_tok('MSG_FORCED_LEAVE_TITLE'); $msgBody = $demolition - ? "Hi, ".$userData['username']."!\n\nThis is to inform you that due to a finished demolition of your last Embassy, you have now successfully left your alliance.\n\nYours sincerely,\nServer Robot :)" - : "Hi, ".$userData['username']."!\n\nThis is to inform you that due to a successful attack and destruction of your last Embassy, you have been forced to leave your alliance.\n\nTo re-establish your position in this alliance, you will need to build a new Embassy and ask the leader to send you an invite again.\n\nYours sincerely,\nServer Robot :)"; + ? rc_tok('MSG_LEFT_DEMOLITION_BODY', $userData['username']) + : rc_tok('MSG_LEFT_ATTACK_BODY', $userData['username']); $this->sendMessage($userData['id'], 4, $msgTitle, $this->escape($msgBody), 0,0,0,0,0,true); @@ -5078,10 +5083,10 @@ $q = "INSERT INTO ".TB_PREFIX."demolition VALUES ( foreach ($members as $member) { $evicts[] = $member['id']; $isOwner = ($member['id'] == $ownerData['id']); - $title = 'Your alliance was disbanded'; + $title = rc_tok('MSG_DISBAND_TITLE'); $body = $isOwner - ? "Hi, ".$ownerData['username']."!\n\nThis is to inform you that due to a finished demolition of your last Embassy at level 3, and the fact that you were the leader of your alliance, this alliance has been disbanded.\n\nIn order to found a new alliance, please build a level 3 Embassy again in one of your villages.\n\nYours sincerely,\nServer Robot :)" - : "Hi, ".$member['username']."!\n\nThis is to inform you that due to a demolition of your alliance founder's last Embassy below level 3, this alliance has been disbanded.\n\nYou can now accept invitations from other alliances or found a new alliance yourself.\n\nYours sincerely,\nServer Robot :)"; + ? rc_tok('MSG_DISBAND_OWNER_BODY', $ownerData['username']) + : rc_tok('MSG_DISBAND_MEMBER_BODY', $member['username']); $this->sendMessage($member['id'], 4, $title, $this->escape($body), 0,0,0,0,0,true); $this->deleteAlliPermissions($member['id']); @@ -5123,11 +5128,11 @@ $q = "INSERT INTO ".TB_PREFIX."demolition VALUES ( $this->updateAlliPermissions($oldLeaderId, $allyId, "Former Leader", 0,0,0,0,0,0,0); if ($customMessage === null) { - $msg = "Hi, $newLeaderName!\n\nThis is to inform you that there was a successful attack on player ".$oldLeaderData['username']." which has damaged their Embassy badly enough that they are no longer able to sustain the leadership of your alliance.\n\nSince your Embassy level is of a sufficient level, you have been auto-elected to the position of a new leader of your alliance with all duties and responsibilities thereof.\n\nYours sincerely,\nServer Robot :)"; - $title = 'You are now the alliance leader'; + $msg = rc_tok('MSG_PROMOTE_BODY', $newLeaderName, $oldLeaderId, $oldLeaderData['username']); + $title = rc_tok('MSG_NOW_ALLIANCE_LEADER_TITLE'); } else { $msg = $customMessage; - $title = 'You are now leader of your alliance'; + $title = rc_tok('MSG_NOW_LEADER_TITLE'); } $this->sendMessage($newLeaderId, 4, $title, $this->escape($msg), 0,0,0,0,0,true); $this->clearQueryCache('alliance'); @@ -5140,10 +5145,14 @@ $q = "INSERT INTO ".TB_PREFIX."demolition VALUES ( } foreach ($members as $m) { $isOwner = ($m['id'] == $ownerData['id']); - $title = 'Your alliance was dispersed'; - $body = $isOwner - ? "Hi, ".$ownerData['username']."!\n\nThis is to inform you that due to a successful attack that has degraded your last Embassy to a level ".($membersCount>1?"which is unable to hold all $membersCount alliance members, and because there was no other alliance member with an Embassy on a high enough level to overtake the leadership,":"lower then 3 - which is required to found and hold your own alliance - ")." your alliance has been dispersed.\n\nYours sincerely,\nServer Robot :)" - : "Hi, ".$m['username']."!\n\nThis is to inform you that due to a successful attack on your alliance leader's Embassy by another player that degraded it below threshold allowed to hold all $membersCount alliance members, and because there was no other alliance member with an Embassy on a high enough level to overtake the leadership, your alliance has been dispersed.\n\nYours sincerely,\nServer Robot :)"; + $title = rc_tok('MSG_DISPERSE_TITLE'); + if ($isOwner) { + $body = ($membersCount > 1) + ? rc_tok('MSG_DISPERSE_OWNER_BODY_MANY', $ownerData['username'], $membersCount) + : rc_tok('MSG_DISPERSE_OWNER_BODY_FEW', $ownerData['username']); + } else { + $body = rc_tok('MSG_DISPERSE_MEMBER_BODY', $m['username'], $membersCount); + } $this->sendMessage($m['id'], 4, $title, $this->escape($body), 0,0,0,0,0,true); $this->deleteAlliPermissions($m['id']); } @@ -5159,17 +5168,17 @@ $q = "INSERT INTO ".TB_PREFIX."demolition VALUES ( if (!$keepOwner && $m['id'] == $ownerData['id']) continue; $isOwner = ($m['id'] == $ownerData['id']); - $title = 'Your alliance has a new leader'; + $title = rc_tok('MSG_NEW_LEADER_TITLE'); $body = $isOwner - ? "Hi, ".$ownerData['username']."!\n\nThis is to inform you that due to a successful attack that has degraded your last Embassy to a level which is unable to hold all ".count($members)." alliance members, another alliance member who meets these criteria has been auto-elected as a new alliance leader.\n\nAdditionally - due to the Embassy destruction - you have been forcefuly evicted from your alliance.\n\nPlease re-establish the connection with your alliance by building a new Embassy and contacting the new leader for an invitation.\n\nYours sincerely,\nServer Robot :)" - : "Hi, ".$m['username']."!\n\nThis is to inform you that due to a successful attack on your alliance leader's Embassy by another player, another alliance member with enough Embassy capacity has been auto-elected as the new alliance leader.\n\nYours sincerely,\nServer Robot :)"; + ? rc_tok('MSG_NEWLEADER_OWNER_BODY', $ownerData['username'], count($members), $newLeaderId) + : rc_tok('MSG_NEWLEADER_MEMBER_BODY', $m['username'], $newLeaderId); $this->sendMessage($m['id'], 4, $title, $this->escape($body), 0,0,0,0,0,true); } if (!$keepOwner) { $this->evictUserFromAlliance($ownerData['id']); - $msg = "Hi, ".$ownerData['username']."!\n\nThis is to inform you that due to a successful attack and destruction of your last Embassy, you have been forced to leave your alliance.\n\nTo re-establish your position in this alliance, you will need to build a new Embassy and ask the newly auto-elected leader to send you an invite again.\n\nYours sincerely,\nServer Robot :)"; - $this->sendMessage($ownerData['id'], 4, 'An attack has forced you to leave the alliance', $this->escape($msg), 0,0,0,0,0,true); + $msg = rc_tok('MSG_FORCED_LEAVE_BODY', $ownerData['username'], $newLeaderId); + $this->sendMessage($ownerData['id'], 4, rc_tok('MSG_FORCED_LEAVE_TITLE'), $this->escape($msg), 0,0,0,0,0,true); } $this->deleteAlliance($ownerData['alliance']); return true; diff --git a/GameEngine/Lang/en.php b/GameEngine/Lang/en.php index c1bb52c0..d1b2281a 100755 --- a/GameEngine/Lang/en.php +++ b/GameEngine/Lang/en.php @@ -256,6 +256,30 @@ tz_def('RC_AND_FRIENDLY_TROOPS', 'and %s friendly troops'); // Troop return tz_def('RC_NONE_RETURNED', 'None of your soldiers returned.'); // === End battle report strings === +// === System / alliance in-game messages (sendMessage), rendered per reader === +tz_def('MSG_INVITE_ALLIANCE', 'Invitation to Alliance'); +tz_def('MSG_FORUM_NEW_TITLE', 'New Message in Forum'); +tz_def('MSG_FORUM_NEW_BODY', "Hi!\n\n%s posted a new message into your common topic. Here's a link that will get you there: forum link\n\nYours sincerely,\nServer Robot :)"); +tz_def('MSG_LEFT_ALLIANCE_TITLE', 'You left the alliance'); +tz_def('MSG_FORCED_LEAVE_TITLE', 'An attack has forced you to leave the alliance'); +tz_def('MSG_LEFT_DEMOLITION_BODY', "Hi, %s!\n\nThis is to inform you that due to a finished demolition of your last Embassy, you have now successfully left your alliance.\n\nYours sincerely,\nServer Robot :)"); +tz_def('MSG_LEFT_ATTACK_BODY', "Hi, %s!\n\nThis is to inform you that due to a successful attack and destruction of your last Embassy, you have been forced to leave your alliance.\n\nTo re-establish your position in this alliance, you will need to build a new Embassy and ask the leader to send you an invite again.\n\nYours sincerely,\nServer Robot :)"); +tz_def('MSG_DISBAND_TITLE', 'Your alliance was disbanded'); +tz_def('MSG_DISBAND_OWNER_BODY', "Hi, %s!\n\nThis is to inform you that due to a finished demolition of your last Embassy at level 3, and the fact that you were the leader of your alliance, this alliance has been disbanded.\n\nIn order to found a new alliance, please build a level 3 Embassy again in one of your villages.\n\nYours sincerely,\nServer Robot :)"); +tz_def('MSG_DISBAND_MEMBER_BODY', "Hi, %s!\n\nThis is to inform you that due to a demolition of your alliance founder's last Embassy below level 3, this alliance has been disbanded.\n\nYou can now accept invitations from other alliances or found a new alliance yourself.\n\nYours sincerely,\nServer Robot :)"); +tz_def('MSG_NOW_ALLIANCE_LEADER_TITLE', 'You are now the alliance leader'); +tz_def('MSG_NOW_LEADER_TITLE', 'You are now leader of your alliance'); +tz_def('MSG_PROMOTE_BODY', "Hi, %s!\n\nThis is to inform you that there was a successful attack on player %s which has damaged their Embassy badly enough that they are no longer able to sustain the leadership of your alliance.\n\nSince your Embassy level is of a sufficient level, you have been auto-elected to the position of a new leader of your alliance with all duties and responsibilities thereof.\n\nYours sincerely,\nServer Robot :)"); +tz_def('MSG_DISPERSE_TITLE', 'Your alliance was dispersed'); +tz_def('MSG_DISPERSE_OWNER_BODY_MANY', "Hi, %s!\n\nThis is to inform you that due to a successful attack that has degraded your last Embassy to a level which is unable to hold all %s alliance members, and because there was no other alliance member with an Embassy on a high enough level to overtake the leadership, your alliance has been dispersed.\n\nYours sincerely,\nServer Robot :)"); +tz_def('MSG_DISPERSE_OWNER_BODY_FEW', "Hi, %s!\n\nThis is to inform you that due to a successful attack that has degraded your last Embassy to a level lower then 3 - which is required to found and hold your own alliance - your alliance has been dispersed.\n\nYours sincerely,\nServer Robot :)"); +tz_def('MSG_DISPERSE_MEMBER_BODY', "Hi, %s!\n\nThis is to inform you that due to a successful attack on your alliance leader's Embassy by another player that degraded it below threshold allowed to hold all %s alliance members, and because there was no other alliance member with an Embassy on a high enough level to overtake the leadership, your alliance has been dispersed.\n\nYours sincerely,\nServer Robot :)"); +tz_def('MSG_NEW_LEADER_TITLE', 'Your alliance has a new leader'); +tz_def('MSG_NEWLEADER_OWNER_BODY', "Hi, %s!\n\nThis is to inform you that due to a successful attack that has degraded your last Embassy to a level which is unable to hold all %s alliance members, another alliance member who meets these criteria has been auto-elected as a new alliance leader.\n\nAdditionally - due to the Embassy destruction - you have been forcefuly evicted from your alliance.\n\nPlease re-establish the connection with your alliance by building a new Embassy and contacting the new leader for an invitation.\n\nYours sincerely,\nServer Robot :)"); +tz_def('MSG_NEWLEADER_MEMBER_BODY', "Hi, %s!\n\nThis is to inform you that due to a successful attack on your alliance leader's Embassy by another player, another alliance member with enough Embassy capacity has been auto-elected as the new alliance leader.\n\nYours sincerely,\nServer Robot :)"); +tz_def('MSG_FORCED_LEAVE_BODY', "Hi, %s!\n\nThis is to inform you that due to a successful attack and destruction of your last Embassy, you have been forced to leave your alliance.\n\nTo re-establish your position in this alliance, you will need to build a new Embassy and ask the newly auto-elected leader to send you an invite again.\n\nYours sincerely,\nServer Robot :)"); +tz_def('MSG_INVITE_BODY', "Hi, %s!\n\nThis is to inform you that you have been invited to join an alliance. To accept this invitation, please visit your Embassy.\n\nYours sincerely,\nServer Robot :)"); +tz_def('MSG_QUIT_REPLACEMENT_BODY', "Hi!\n\nThis is to inform you that the former leader of your alliance - %s, has decided to quit and elected you as his replacement. You now gain full access, administration and responsibilities to your alliance.\n\nGood luck!\n\nYours sincerely,\nServer Robot :)"); // Embassy-destruction status lines, appended to the catapult battle report. tz_def('MSG_ALLIANCE_DISPERSED_STATUS', "This player's alliance has been dispersed."); tz_def('MSG_FORCED_LEAVE_STATUS', 'Player was forced to leave their alliance.'); diff --git a/GameEngine/Lang/fr.php b/GameEngine/Lang/fr.php index cbfcfe72..a158622a 100644 --- a/GameEngine/Lang/fr.php +++ b/GameEngine/Lang/fr.php @@ -253,6 +253,30 @@ define('RC_AND_FRIENDLY_TROOPS', 'et %s troupes alliées'); // Troop return define('RC_NONE_RETURNED', "Aucun de vos soldats n'est revenu."); // === End battle report strings === +// === System / alliance in-game messages (sendMessage), rendered per reader === +define('MSG_INVITE_ALLIANCE', "Invitation à l'alliance"); +define('MSG_FORUM_NEW_TITLE', 'Nouveau message sur le forum'); +define('MSG_FORUM_NEW_BODY', "Bonjour !\n\n%s a publié un nouveau message dans votre sujet commun. Voici un lien qui vous y mènera : lien du forum\n\nCordialement,\nRobot du serveur :)"); +define('MSG_LEFT_ALLIANCE_TITLE', "Vous avez quitté l'alliance"); +define('MSG_FORCED_LEAVE_TITLE', "Une attaque vous a forcé à quitter l'alliance"); +define('MSG_LEFT_DEMOLITION_BODY', "Bonjour, %s !\n\nNous vous informons que suite à la démolition achevée de votre dernière Ambassade, vous avez désormais quitté votre alliance.\n\nCordialement,\nRobot du serveur :)"); +define('MSG_LEFT_ATTACK_BODY', "Bonjour, %s !\n\nNous vous informons que suite à une attaque réussie et à la destruction de votre dernière Ambassade, vous avez été forcé de quitter votre alliance.\n\nPour rétablir votre position dans cette alliance, vous devrez construire une nouvelle Ambassade et demander au chef de vous envoyer une nouvelle invitation.\n\nCordialement,\nRobot du serveur :)"); +define('MSG_DISBAND_TITLE', 'Votre alliance a été dissoute'); +define('MSG_DISBAND_OWNER_BODY', "Bonjour, %s !\n\nNous vous informons que suite à la démolition achevée de votre dernière Ambassade de niveau 3, et du fait que vous étiez le chef de votre alliance, cette alliance a été dissoute.\n\nPour fonder une nouvelle alliance, veuillez reconstruire une Ambassade de niveau 3 dans l'un de vos villages.\n\nCordialement,\nRobot du serveur :)"); +define('MSG_DISBAND_MEMBER_BODY', "Bonjour, %s !\n\nNous vous informons que suite à la démolition de la dernière Ambassade du fondateur de votre alliance en dessous du niveau 3, cette alliance a été dissoute.\n\nVous pouvez désormais accepter des invitations d'autres alliances ou fonder vous-même une nouvelle alliance.\n\nCordialement,\nRobot du serveur :)"); +define('MSG_NOW_ALLIANCE_LEADER_TITLE', "Vous êtes désormais le chef de l'alliance"); +define('MSG_NOW_LEADER_TITLE', 'Vous êtes désormais le chef de votre alliance'); +define('MSG_PROMOTE_BODY', "Bonjour, %s !\n\nNous vous informons qu'une attaque réussie a visé le joueur %s, endommageant son Ambassade au point qu'il ne peut plus assumer la direction de votre alliance.\n\nComme votre Ambassade est d'un niveau suffisant, vous avez été automatiquement élu nouveau chef de votre alliance, avec tous les devoirs et responsabilités qui en découlent.\n\nCordialement,\nRobot du serveur :)"); +define('MSG_DISPERSE_TITLE', 'Votre alliance a été dispersée'); +define('MSG_DISPERSE_OWNER_BODY_MANY', "Bonjour, %s !\n\nNous vous informons que suite à une attaque réussie ayant rabaissé votre dernière Ambassade à un niveau incapable de contenir l'ensemble des %s membres de l'alliance, et parce qu'aucun autre membre ne disposait d'une Ambassade d'un niveau suffisant pour reprendre la direction, votre alliance a été dispersée.\n\nCordialement,\nRobot du serveur :)"); +define('MSG_DISPERSE_OWNER_BODY_FEW', "Bonjour, %s !\n\nNous vous informons que suite à une attaque réussie ayant rabaissé votre dernière Ambassade à un niveau inférieur à 3 - requis pour fonder et maintenir votre propre alliance - votre alliance a été dispersée.\n\nCordialement,\nRobot du serveur :)"); +define('MSG_DISPERSE_MEMBER_BODY', "Bonjour, %s !\n\nNous vous informons que suite à une attaque réussie d'un autre joueur sur l'Ambassade du chef de votre alliance, qui l'a rabaissée sous le seuil permettant de contenir l'ensemble des %s membres, et parce qu'aucun autre membre ne disposait d'une Ambassade d'un niveau suffisant pour reprendre la direction, votre alliance a été dispersée.\n\nCordialement,\nRobot du serveur :)"); +define('MSG_NEW_LEADER_TITLE', 'Votre alliance a un nouveau chef'); +define('MSG_NEWLEADER_OWNER_BODY', "Bonjour, %s !\n\nNous vous informons que suite à une attaque réussie ayant rabaissé votre dernière Ambassade à un niveau incapable de contenir l'ensemble des %s membres de l'alliance, un autre membre répondant à ces critères a été automatiquement élu nouveau chef de l'alliance.\n\nDe plus - en raison de la destruction de l'Ambassade - vous avez été expulsé de votre alliance.\n\nVeuillez rétablir le lien avec votre alliance en construisant une nouvelle Ambassade et en contactant le nouveau chef pour obtenir une invitation.\n\nCordialement,\nRobot du serveur :)"); +define('MSG_NEWLEADER_MEMBER_BODY', "Bonjour, %s !\n\nNous vous informons que suite à une attaque réussie d'un autre joueur sur l'Ambassade du chef de votre alliance, un autre membre de l'alliance disposant d'une capacité d'Ambassade suffisante a été automatiquement élu nouveau chef de l'alliance.\n\nCordialement,\nRobot du serveur :)"); +define('MSG_FORCED_LEAVE_BODY', "Bonjour, %s !\n\nNous vous informons que suite à une attaque réussie et à la destruction de votre dernière Ambassade, vous avez été forcé de quitter votre alliance.\n\nPour rétablir votre position dans cette alliance, vous devrez construire une nouvelle Ambassade et demander au chef nouvellement élu de vous envoyer une nouvelle invitation.\n\nCordialement,\nRobot du serveur :)"); +define('MSG_INVITE_BODY', "Bonjour, %s !\n\nNous vous informons que vous avez été invité à rejoindre une alliance. Pour accepter cette invitation, veuillez vous rendre à votre Ambassade.\n\nCordialement,\nRobot du serveur :)"); +define('MSG_QUIT_REPLACEMENT_BODY', "Bonjour !\n\nNous vous informons que l'ancien chef de votre alliance - %s - a décidé de partir et vous a désigné comme son remplaçant. Vous obtenez désormais l'accès complet, l'administration et les responsabilités de votre alliance.\n\nBonne chance !\n\nCordialement,\nRobot du serveur :)"); // Embassy-destruction status lines, appended to the catapult battle report. define('MSG_ALLIANCE_DISPERSED_STATUS', "L'alliance de ce joueur a été dispersée."); define('MSG_FORCED_LEAVE_STATUS', "Le joueur a été forcé de quitter son alliance."); diff --git a/GameEngine/Lang/ro.php b/GameEngine/Lang/ro.php index f98326e3..0b71ff85 100644 --- a/GameEngine/Lang/ro.php +++ b/GameEngine/Lang/ro.php @@ -253,6 +253,30 @@ define('RC_AND_FRIENDLY_TROOPS', 'și %s trupe aliate'); // Troop return define('RC_NONE_RETURNED', 'Niciunul dintre soldații tăi nu s-a întors.'); // === End battle report strings === +// === System / alliance in-game messages (sendMessage), rendered per reader === +define('MSG_INVITE_ALLIANCE', 'Invitație în alianță'); +define('MSG_FORUM_NEW_TITLE', 'Mesaj nou pe forum'); +define('MSG_FORUM_NEW_BODY', "Salut!\n\n%s a publicat un mesaj nou în subiectul vostru comun. Iată un link care te va duce acolo: link forum\n\nCu stimă,\nRobotul serverului :)"); +define('MSG_LEFT_ALLIANCE_TITLE', 'Ai părăsit alianța'); +define('MSG_FORCED_LEAVE_TITLE', 'Un atac te-a forțat să părăsești alianța'); +define('MSG_LEFT_DEMOLITION_BODY', "Salut, %s!\n\nTe informăm că, în urma demolării finalizate a ultimei tale Ambasade, ai părăsit acum cu succes alianța.\n\nCu stimă,\nRobotul serverului :)"); +define('MSG_LEFT_ATTACK_BODY', "Salut, %s!\n\nTe informăm că, în urma unui atac reușit și a distrugerii ultimei tale Ambasade, ai fost forțat să părăsești alianța.\n\nPentru a-ți restabili poziția în această alianță, va trebui să construiești o nouă Ambasadă și să-i ceri liderului să-ți trimită din nou o invitație.\n\nCu stimă,\nRobotul serverului :)"); +define('MSG_DISBAND_TITLE', 'Alianța ta a fost desființată'); +define('MSG_DISBAND_OWNER_BODY', "Salut, %s!\n\nTe informăm că, în urma demolării finalizate a ultimei tale Ambasade de nivel 3 și a faptului că erai liderul alianței, această alianță a fost desființată.\n\nPentru a fonda o nouă alianță, te rugăm să construiești din nou o Ambasadă de nivel 3 într-unul dintre satele tale.\n\nCu stimă,\nRobotul serverului :)"); +define('MSG_DISBAND_MEMBER_BODY', "Salut, %s!\n\nTe informăm că, în urma demolării ultimei Ambasade a fondatorului alianței tale sub nivelul 3, această alianță a fost desființată.\n\nAcum poți accepta invitații de la alte alianțe sau poți fonda tu însuți o nouă alianță.\n\nCu stimă,\nRobotul serverului :)"); +define('MSG_NOW_ALLIANCE_LEADER_TITLE', 'Acum ești liderul alianței'); +define('MSG_NOW_LEADER_TITLE', 'Acum ești liderul alianței tale'); +define('MSG_PROMOTE_BODY', "Salut, %s!\n\nTe informăm că a avut loc un atac reușit asupra jucătorului %s, care i-a avariat Ambasada suficient de mult încât nu mai poate susține conducerea alianței tale.\n\nDeoarece nivelul Ambasadei tale este suficient, ai fost ales automat în poziția de nou lider al alianței, cu toate îndatoririle și responsabilitățile aferente.\n\nCu stimă,\nRobotul serverului :)"); +define('MSG_DISPERSE_TITLE', 'Alianța ta a fost dispersată'); +define('MSG_DISPERSE_OWNER_BODY_MANY', "Salut, %s!\n\nTe informăm că, în urma unui atac reușit care ți-a degradat ultima Ambasadă la un nivel care nu poate susține toți cei %s membri ai alianței și deoarece niciun alt membru nu avea o Ambasadă de nivel suficient de înalt pentru a prelua conducerea, alianța ta a fost dispersată.\n\nCu stimă,\nRobotul serverului :)"); +define('MSG_DISPERSE_OWNER_BODY_FEW', "Salut, %s!\n\nTe informăm că, în urma unui atac reușit care ți-a degradat ultima Ambasadă la un nivel sub 3 - necesar pentru a fonda și menține propria alianță - alianța ta a fost dispersată.\n\nCu stimă,\nRobotul serverului :)"); +define('MSG_DISPERSE_MEMBER_BODY', "Salut, %s!\n\nTe informăm că, în urma unui atac reușit al altui jucător asupra Ambasadei liderului alianței tale, care a degradat-o sub pragul necesar pentru a susține toți cei %s membri, și deoarece niciun alt membru nu avea o Ambasadă de nivel suficient de înalt pentru a prelua conducerea, alianța ta a fost dispersată.\n\nCu stimă,\nRobotul serverului :)"); +define('MSG_NEW_LEADER_TITLE', 'Alianța ta are un nou lider'); +define('MSG_NEWLEADER_OWNER_BODY', "Salut, %s!\n\nTe informăm că, în urma unui atac reușit care ți-a degradat ultima Ambasadă la un nivel ce nu poate susține toți cei %s membri ai alianței, un alt membru care îndeplinește aceste criterii a fost ales automat ca nou lider al alianței.\n\nÎn plus - din cauza distrugerii Ambasadei - ai fost expulzat din alianța ta.\n\nTe rugăm să restabilești legătura cu alianța ta construind o nouă Ambasadă și contactând noul lider pentru o invitație.\n\nCu stimă,\nRobotul serverului :)"); +define('MSG_NEWLEADER_MEMBER_BODY', "Salut, %s!\n\nTe informăm că, în urma unui atac reușit al altui jucător asupra Ambasadei liderului alianței tale, un alt membru al alianței cu o capacitate de Ambasadă suficientă a fost ales automat ca nou lider al alianței.\n\nCu stimă,\nRobotul serverului :)"); +define('MSG_FORCED_LEAVE_BODY', "Salut, %s!\n\nTe informăm că, în urma unui atac reușit și a distrugerii ultimei tale Ambasade, ai fost forțat să părăsești alianța.\n\nPentru a-ți restabili poziția în această alianță, va trebui să construiești o nouă Ambasadă și să-i ceri noului lider ales să-ți trimită din nou o invitație.\n\nCu stimă,\nRobotul serverului :)"); +define('MSG_INVITE_BODY', "Salut, %s!\n\nTe informăm că ai fost invitat să te alături unei alianțe. Pentru a accepta această invitație, te rugăm să vizitezi Ambasada ta.\n\nCu stimă,\nRobotul serverului :)"); +define('MSG_QUIT_REPLACEMENT_BODY', "Salut!\n\nTe informăm că fostul lider al alianței tale - %s - a decis să plece și te-a ales ca înlocuitor. Acum primești acces complet, administrare și responsabilități asupra alianței tale.\n\nMult succes!\n\nCu stimă,\nRobotul serverului :)"); // Embassy-destruction status lines, appended to the catapult battle report. define('MSG_ALLIANCE_DISPERSED_STATUS', 'Alianța acestui jucător a fost dispersată.'); define('MSG_FORCED_LEAVE_STATUS', 'Jucătorul a fost forțat să-și părăsească alianța.'); diff --git a/Templates/Message/archive.tpl b/Templates/Message/archive.tpl index 1353c7f3..5abedb84 100644 --- a/Templates/Message/archive.tpl +++ b/Templates/Message/archive.tpl @@ -107,7 +107,7 @@ // SUBJECT // ====================================================== echo " - " . $msg['topic'] . ""; + " . tz_expand_report($msg['topic']) . ""; if ($msg['viewed'] == 0) { echo " (new)"; diff --git a/Templates/Message/inbox.tpl b/Templates/Message/inbox.tpl index 98378e71..e4614b56 100644 --- a/Templates/Message/inbox.tpl +++ b/Templates/Message/inbox.tpl @@ -162,7 +162,7 @@ // SUBJECT // ====================================================== echo " - " . $msg['topic'] . ""; + " . tz_expand_report($msg['topic']) . ""; if ($msg['viewed'] == 0) { echo " (new)"; diff --git a/Templates/Message/read.tpl b/Templates/Message/read.tpl index ba96ce5e..3b39a5eb 100644 --- a/Templates/Message/read.tpl +++ b/Templates/Message/read.tpl @@ -10,7 +10,7 @@ // ====================================================== $reading = $message->reading; -$input = $reading['message']; +$input = tz_expand_report($reading['message']); $alliance = $reading['alliance']; $player = $reading['player']; $coor = $reading['coor']; @@ -77,7 +77,7 @@ $date = $generator->procMtime($reading['time']); -
+
diff --git a/Templates/Message/sent.tpl b/Templates/Message/sent.tpl index 7e446b8b..7413ebd4 100644 --- a/Templates/Message/sent.tpl +++ b/Templates/Message/sent.tpl @@ -156,7 +156,7 @@ for ($i = (1 + $s); $i <= (10 + $s); $i++) { // SUBJECT // ====================================================== echo " - " . $msg['topic'] . ""; + " . tz_expand_report($msg['topic']) . ""; if ($msg['viewed'] == 0) { echo " (unread)";