OTALKFRE.cpp 31 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358
  1. /*
  2. * Seven Kingdoms: Ancient Adversaries
  3. *
  4. * Copyright 1997,1998 Enlight Software Ltd.
  5. *
  6. * This program is free software: you can redistribute it and/or modify
  7. * it under the terms of the GNU General Public License as published by
  8. * the Free Software Foundation, either version 2 of the License, or
  9. * (at your option) any later version.
  10. *
  11. * This program is distributed in the hope that it will be useful,
  12. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  14. * GNU General Public License for more details.
  15. *
  16. * You should have received a copy of the GNU General Public License
  17. * along with this program. If not, see <http://www.gnu.org/licenses/>.
  18. *
  19. */
  20. //Filename : OTALKFRE.CPP
  21. //Description : French version of the talk messages
  22. #if(defined(FRENCH))
  23. #include <OMOUSE.h>
  24. #include <OSYS.h>
  25. #include <OVGA.h>
  26. #include <OINFO.h>
  27. #include <OFONT.h>
  28. #include <OTECHRES.h>
  29. #include <OGAMESET.h>
  30. #include <ONEWS.h>
  31. #include <ONATION.h>
  32. #include <OTALKRES.h>
  33. //-------- define static vars --------//
  34. static String str; // these vars don't have to be saved as their are only used by msg_str() for passing vars to other functions
  35. static short viewing_nation_recno;
  36. static char should_disp_reply;
  37. static char disp_second_line;
  38. //------- Begin of function TalkMsg::msg_str --------//
  39. //
  40. // Return the text of this message.
  41. //
  42. // <int> viewingNationRecno = the recno of the nation viewing this message
  43. // [int] dispReply = whether display the reply if there is one
  44. // (default: 1)
  45. // [int] dispSecondLine = whether should display the second line of the
  46. // message (default: 0)
  47. //
  48. char* TalkMsg::msg_str(int viewingNationRecno, int dispReply, int dispSecondLine)
  49. {
  50. viewing_nation_recno = viewingNationRecno;
  51. should_disp_reply = dispReply;
  52. disp_second_line = dispSecondLine;
  53. //-------- compose the message str -------//
  54. switch(talk_id)
  55. {
  56. case TALK_PROPOSE_TRADE_TREATY:
  57. propose_treaty("accord commercial");
  58. break;
  59. case TALK_PROPOSE_FRIENDLY_TREATY:
  60. propose_treaty("pacte de non-agression");
  61. break;
  62. case TALK_PROPOSE_ALLIANCE_TREATY:
  63. propose_treaty("traité d'alliance");
  64. break;
  65. case TALK_END_TRADE_TREATY:
  66. end_treaty("accord commercial");
  67. break;
  68. case TALK_END_FRIENDLY_TREATY:
  69. end_treaty("pacte de non-agression");
  70. break;
  71. case TALK_END_ALLIANCE_TREATY:
  72. end_treaty("traité d'alliance");
  73. break;
  74. case TALK_REQUEST_MILITARY_AID:
  75. request_military_aid();
  76. break;
  77. case TALK_REQUEST_TRADE_EMBARGO:
  78. request_trade_embargo();
  79. break;
  80. case TALK_REQUEST_CEASE_WAR:
  81. request_cease_war();
  82. break;
  83. case TALK_REQUEST_DECLARE_WAR:
  84. request_declare_war();
  85. break;
  86. case TALK_REQUEST_BUY_FOOD:
  87. request_buy_food();
  88. break;
  89. case TALK_DECLARE_WAR:
  90. declare_war();
  91. break;
  92. case TALK_GIVE_TRIBUTE:
  93. give_tribute("tribut");
  94. break;
  95. case TALK_DEMAND_TRIBUTE:
  96. demand_tribute(0); // 1-is tribute, not aid
  97. break;
  98. case TALK_GIVE_AID:
  99. give_tribute("aide");
  100. break;
  101. case TALK_DEMAND_AID:
  102. demand_tribute(1); // 1-is aid, not tribute
  103. break;
  104. case TALK_GIVE_TECH:
  105. give_tech();
  106. break;
  107. case TALK_DEMAND_TECH:
  108. demand_tech();
  109. break;
  110. case TALK_REQUEST_SURRENDER:
  111. request_surrender();
  112. break;
  113. case TALK_SURRENDER:
  114. surrender();
  115. break;
  116. default:
  117. err_here();
  118. }
  119. return str;
  120. }
  121. //-------- End of function TalkMsg::msg_str ---------//
  122. //----- Begin of function TalkMsg::propose_treaty ------//
  123. //
  124. // talk_para1 - duration of the treaty (no. of years).
  125. //
  126. void TalkMsg::propose_treaty(char* treatyTypeStr)
  127. {
  128. //---------------------------------------------//
  129. //
  130. // Send:
  131. //
  132. // <King>'s Kingdom proposes a/an friendly/alliance treaty to you.
  133. // You propose a/an friendly/alliance treaty to <King>'s Kingdom.
  134. //
  135. // Reply:
  136. //
  137. // <King>'s Kingdom accepts/rejects your proposed
  138. // friendly/alliance treaty.
  139. //
  140. // You accept/reject the friendly/alliance treaty
  141. // proposed by <King>'s Kingdom.
  142. //
  143. //---------------------------------------------//
  144. //
  145. // Envoyer:
  146. //
  147. // Le Royaume de <King> vous propose un pacte_de_non-agression/traité_d'alliance.
  148. //
  149. // Vous proposez un pacte_de_non-agression/traité_d'alliance au Royaume de
  150. // <King>.
  151. //
  152. // Répondre:
  153. //
  154. // Le Royaume de <King> accepte/rejette votre proposition de
  155. // pacte_de_non-agression/traité_d'alliance.
  156. //
  157. // Vous acceptez/rejetez le pacte_de_non-agression/traité_d'alliance
  158. // proposé par le Royaume de <King>.
  159. //
  160. //---------------------------------------------//
  161. //--------------------------------------//
  162. if( reply_type == REPLY_WAITING || !should_disp_reply )
  163. {
  164. if( viewing_nation_recno == from_nation_recno )
  165. {
  166. str = "Vous proposez un ";
  167. str += treatyTypeStr;
  168. str += " au ";
  169. str += to_nation_name();
  170. str += ".";
  171. }
  172. else
  173. {
  174. str = "Le ";
  175. str += from_nation_name();
  176. str += " vous propose un ";
  177. str += treatyTypeStr;
  178. str += ".";
  179. }
  180. }
  181. else
  182. {
  183. if( viewing_nation_recno == from_nation_recno )
  184. {
  185. str = "Le ";
  186. str += to_nation_name();
  187. if( reply_type == REPLY_ACCEPT )
  188. str += " accepte votre proposition de ";
  189. else
  190. str += " rejette votre proposition de ";
  191. str += treatyTypeStr;
  192. str += ".";
  193. }
  194. else
  195. {
  196. if( reply_type == REPLY_ACCEPT )
  197. str = "Vous acceptez le ";
  198. else
  199. str = "Vous acceptez le ";
  200. str += treatyTypeStr;
  201. str += " proposé par le ";
  202. str += from_nation_name();
  203. str += ".";
  204. }
  205. }
  206. }
  207. //------- End of function TalkMsg::propose_treaty ------//
  208. //----- Begin of function TalkMsg::end_treaty ------//
  209. //
  210. // talk_para1 - treaty type, NATION_FRIENDLY or NATION_ALLIANCE.
  211. //
  212. void TalkMsg::end_treaty(char* treatyTypeStr)
  213. {
  214. //---------------------------------------------//
  215. //
  216. // Send:
  217. // <King>'s Kingdom terminates its friendly/alliance treaty with you.
  218. // You terminate your friendly/alliance treaty with <King>'s Kingdom.
  219. //
  220. //---------------------------------------------//
  221. //
  222. // Envoyer:
  223. // Le Royaume de <King> met fin à son pacte_de_non-agression/traité_d'alliance
  224. // avec vous.
  225. //
  226. // Vous mettez fin au pacte_de_non-agression/traité_d'alliance
  227. // avec le Royaume de <King>.
  228. //
  229. //---------------------------------------------//
  230. if( viewing_nation_recno == from_nation_recno )
  231. {
  232. str = "Vous mettez fin au ";
  233. str += treatyTypeStr;
  234. str += " avec le ";
  235. str += to_nation_name();
  236. str += ".";
  237. }
  238. else
  239. {
  240. str = "Le ";
  241. str += from_nation_name();
  242. str += " met fin à son ";
  243. str += treatyTypeStr;
  244. str += " avec vous.";
  245. }
  246. }
  247. //------- End of function TalkMsg::end_treaty ------//
  248. //----- Begin of function TalkMsg::request_cease_war ------//
  249. //
  250. void TalkMsg::request_cease_war()
  251. {
  252. //---------------------------------------------//
  253. //
  254. // Send:
  255. // <King>'s Kingdom requests a cease-fire.
  256. // You request a cease-fire with <King>'s Kingdom.
  257. //
  258. // Reply:
  259. // <King>'s Kingdom agrees to a cease-fire.
  260. // <King>'s Kingdom refuses a cease-fire.
  261. // You agree to a cease-fire with <King>'s Kingdom.
  262. // You refuse a cease-fire with <King>'s Kingdom.
  263. //
  264. //---------------------------------------------//
  265. //
  266. // Envoyer:
  267. // Le Royaume de <King> demande un cessez-le-feu.
  268. // Vous demandez un cessez-le-feu au Royaume de <King>.
  269. //
  270. // Répondre:
  271. // Le Royaume de <King> accepte un cessez-le-feu.
  272. // Le Royaume de <King> refuse un cessez-le-feu.
  273. // Vous acceptez un cessez-le-feu avec le Royaume de <King>.
  274. // Vous refusez un cessez-le-feu avec le Royaume de <King>.
  275. //
  276. //---------------------------------------------//
  277. if( reply_type == REPLY_WAITING || !should_disp_reply )
  278. {
  279. if( viewing_nation_recno == from_nation_recno )
  280. {
  281. str = "Vous demandez un cessez-le-feu au ";
  282. str += to_nation_name();
  283. str += ".";
  284. }
  285. else
  286. {
  287. str = "Le ";
  288. str += from_nation_name();
  289. str += " demande un cessez-le-feu.";
  290. }
  291. }
  292. else
  293. {
  294. if( viewing_nation_recno == from_nation_recno )
  295. {
  296. str = "Le ";
  297. str += to_nation_name();
  298. if( reply_type == REPLY_ACCEPT )
  299. str += " accepte";
  300. else
  301. str += " refuse";
  302. str += " cessez-le-feu.";
  303. }
  304. else
  305. {
  306. if( reply_type == REPLY_ACCEPT )
  307. str = "Vous acceptez ";
  308. else
  309. str = "Vous refusez";
  310. str += " un cessez-le-feu avec le ";
  311. str += from_nation_name();
  312. str += ".";
  313. }
  314. }
  315. }
  316. //------- End of function TalkMsg::request_cease_war ------//
  317. //----- Begin of function TalkMsg::request_declare_war ------//
  318. //
  319. // talk_para1 - the recno of the nation to declare war with.
  320. //
  321. void TalkMsg::request_declare_war()
  322. {
  323. //---------------------------------------------//
  324. //
  325. // Send:
  326. // <King>'s Kingdom requests that you declare war on <King B>'s Kingdom.
  327. // You request <King>'s Kingdom to declare war on <King B>'s Kingdom.
  328. //
  329. // Reply:
  330. // <King>'s Kingdom agrees/refuses to declare war on <King B>'s Kingdom.
  331. // You agree/refuse to declare war on <King B>'s Kingdom.
  332. //
  333. //---------------------------------------------//
  334. //
  335. // Envoyer:
  336. // Le Royaume de <King> demande que vous déclariez la guerre au
  337. // Royaume de <King B>.
  338. //
  339. // Vous demandez au Royaume de <King> de déclarer la guerre au
  340. // Royaume de <King B>.
  341. //
  342. // Répondre:
  343. // Le Royaume de <King> accepte/refuse de déclarer la guerre au
  344. // Royaume de <King B>.
  345. //
  346. // Vous acceptez/refusez de déclarer la guerre au Royaume de <King B>.
  347. //
  348. //---------------------------------------------//
  349. if( reply_type == REPLY_WAITING || !should_disp_reply )
  350. {
  351. if( viewing_nation_recno == from_nation_recno )
  352. {
  353. str = "Vous demandez au ";
  354. str += to_nation_name();
  355. str += " de";
  356. }
  357. else
  358. {
  359. str = "Le ";
  360. str += from_nation_name();
  361. str += " demande que vous";
  362. }
  363. str += " déclarer la guerre au ";
  364. str += nation_array[talk_para1]->nation_name();
  365. str += nation_color_code_str(talk_para1);
  366. str += ".";
  367. }
  368. else
  369. {
  370. if( viewing_nation_recno == from_nation_recno )
  371. {
  372. str = "Le ";
  373. str += to_nation_name();
  374. if( reply_type == REPLY_ACCEPT )
  375. str += " accepte";
  376. else
  377. str += " refuse";
  378. }
  379. else
  380. {
  381. if( reply_type == REPLY_ACCEPT )
  382. str = "Vous acceptez";
  383. else
  384. str = "Vous refusez";
  385. }
  386. str += " de déclarer la guerre au ";
  387. str += nation_array[talk_para1]->nation_name();
  388. str += nation_color_code_str(talk_para1);
  389. str += ".";
  390. }
  391. }
  392. //------- End of function TalkMsg::request_declare_war ------//
  393. //----- Begin of function TalkMsg::request_buy_food ------//
  394. //
  395. // talk_para1 - the qty of food the nation wants to buy.
  396. // talk_para2 - price offered for 10 qty of food.
  397. //
  398. void TalkMsg::request_buy_food()
  399. {
  400. //---- display the second line in the reply question ----//
  401. //
  402. // <King>'s Kingdom offers $10 for 10 units of food.
  403. //
  404. //-------------------------------------------------------//
  405. //
  406. // Le Royaume de <King> vous offre $10 pour 10 unités de nourriture.
  407. //
  408. //-------------------------------------------------------//
  409. if( disp_second_line )
  410. {
  411. str = "Le ";
  412. str += from_nation_name();
  413. str += " vous offre ";
  414. str += m.format(talk_para2,2);
  415. str += " pour 10 unités de nourriture.";
  416. return;
  417. }
  418. //---------------------------------------------//
  419. //
  420. // Send:
  421. // <King>'s Kingdom requests to purchase <amount>
  422. // units of food from you.
  423. //
  424. // You request to purchase <amount> units of food
  425. // from <King>'s Kingdom.
  426. //
  427. // Reply:
  428. // <King>'s Kingdom agrees/refuses to sell <amount> units
  429. // of food to you.
  430. //
  431. // You agree/refuse to sell <amount> units of food to
  432. // <King>'s Kingdom.
  433. //
  434. //---------------------------------------------//
  435. //
  436. // Envoyer:
  437. // Le Royaume de <King> demande que vous lui vendiez <amount>
  438. // unités de nourriture.
  439. //
  440. // Vous demandez à acheter <amount> unités de nourriture
  441. // au Royaume de <King>.
  442. //
  443. // Répondre:
  444. // Le Royaume de <King> accepte/refuse de vous vendre <amount> unités
  445. // de nourriture.
  446. //
  447. // Vous acceptez/refusez de vendre <amount> unités de nourriture
  448. // au Royaume de <King>.
  449. //
  450. //---------------------------------------------//
  451. if( reply_type == REPLY_WAITING || !should_disp_reply )
  452. {
  453. if( viewing_nation_recno == from_nation_recno )
  454. {
  455. str = "Vous demandez à acheter ";
  456. str += talk_para1;
  457. str += " unités de nourriture au ";
  458. str += to_nation_name();
  459. str += ".";
  460. }
  461. else
  462. {
  463. str = "Le ";
  464. str += from_nation_name();
  465. str += " demande que vous lui vendiez ";
  466. str += talk_para1;
  467. str += " unités de nourriture.";
  468. }
  469. }
  470. else
  471. {
  472. if( viewing_nation_recno == from_nation_recno )
  473. {
  474. str = "Le ";
  475. str += to_nation_name();
  476. if( reply_type == REPLY_ACCEPT )
  477. str += " accepte";
  478. else
  479. str += " refuse";
  480. str += " de vous vendre ";
  481. str += talk_para1;
  482. str += " unités of de nourriture.";
  483. }
  484. else
  485. {
  486. if( reply_type == REPLY_ACCEPT )
  487. str = "Vous acceptez";
  488. else
  489. str = "Vous refusez";
  490. str += " de vendre ";
  491. str += talk_para1;
  492. str += " unités de nourriture au ";
  493. str += from_nation_name();
  494. str += ".";
  495. }
  496. }
  497. }
  498. //------- End of function TalkMsg::request_buy_food ------//
  499. //----- Begin of function TalkMsg::declare_war ------//
  500. //
  501. void TalkMsg::declare_war()
  502. {
  503. //---------------------------------------------//
  504. //
  505. // Send:
  506. // <King>'s Kingdom declares war on you.
  507. // You declare war on <King>'s Kingdom.
  508. //
  509. //---------------------------------------------//
  510. //
  511. // Envoyer:
  512. // Le Royaume de <King> vous déclare la guerre.
  513. // Vous déclarez la guerre au Royaume de <King>.
  514. //
  515. //---------------------------------------------//
  516. if( viewing_nation_recno == from_nation_recno )
  517. {
  518. str = "Vous déclarez la guerre au ";
  519. str += to_nation_name();
  520. str += ".";
  521. }
  522. else
  523. {
  524. str = "Le ";
  525. str += from_nation_name();
  526. str += " vous déclare la guerre.";
  527. }
  528. }
  529. //------- End of function TalkMsg::declare_war ------//
  530. //----- Begin of function TalkMsg::give_tribute ------//
  531. //
  532. // <char*> tributeStr - either "tribute" or "aid".
  533. //
  534. // talk_para1 - amount of the tribute.
  535. //
  536. void TalkMsg::give_tribute(char* tributeStr)
  537. {
  538. char *article = "un";
  539. char *verb = "paie";
  540. char *youVerb = "payez";
  541. if(tributeStr[0] == 'a') // aide
  542. {
  543. article = "une";
  544. verb = "offre";
  545. youVerb = "offrez";
  546. }
  547. //---------------------------------------------//
  548. //
  549. // Send:
  550. // <King>'s Kingdom offers you <$999> in aid/tribute.
  551. // You offer <King>'s Kingdom <$999> in aid/tribute.
  552. //
  553. // Reply:
  554. // <King>'s Kingdom accepts/rejects your aid/tribute of <$999>.
  555. // You accept/reject the <$999> in aid/tribute from <King>'s Kingdom.
  556. //
  557. //---------------------------------------------//
  558. //
  559. // Envoyer:
  560. // Le Royaume de <King> vous offre/paie une/un aide/tribut de <$999>.
  561. // Vous offrez/payez une/un aide/tribut de <$999> au Royaume de <King>.
  562. //
  563. // Répondre:
  564. // Le Royaume de <King> accepte/refuse votre aide/tribut de <$999>.
  565. //
  566. // Vous acceptez/refusez une/un aide/tribut de <$999> de la part du
  567. // Royaume de <King>.
  568. //
  569. //---------------------------------------------//
  570. if( reply_type == REPLY_WAITING || !should_disp_reply )
  571. {
  572. if( viewing_nation_recno == from_nation_recno )
  573. {
  574. str = "Vous ";
  575. str += youVerb;
  576. str += " ";
  577. str += article;
  578. str += " ";
  579. str += tributeStr;
  580. str += " de ";
  581. str += m.format(talk_para1, 2);
  582. str += " au ";
  583. str += to_nation_name();
  584. str += ".";
  585. }
  586. else
  587. {
  588. str = "Le ";
  589. str += from_nation_name();
  590. str += " vous ";
  591. str += verb;
  592. str += " ";
  593. str += article;
  594. str += " ";
  595. str += tributeStr;
  596. str += " de ";
  597. str += m.format(talk_para1, 2);
  598. str += ".";
  599. }
  600. }
  601. else
  602. {
  603. if( viewing_nation_recno == from_nation_recno )
  604. {
  605. str = "Le ";
  606. str += to_nation_name();
  607. if( reply_type == REPLY_ACCEPT )
  608. str += " accepte votre ";
  609. else
  610. str += " refuse votre ";
  611. str += tributeStr;
  612. str += " de ";
  613. str += m.format(talk_para1, 2);
  614. str += ".";
  615. }
  616. else
  617. {
  618. if( reply_type == REPLY_ACCEPT )
  619. str = "Vous acceptez ";
  620. else
  621. str = "Vous refusez ";
  622. str += article;
  623. str += " ";
  624. str += tributeStr;
  625. str += " de ";
  626. str += m.format(talk_para1, 2);
  627. str += " de la part du ";
  628. str += from_nation_name();
  629. str += ".";
  630. }
  631. }
  632. }
  633. //------- End of function TalkMsg::give_tribute ------//
  634. //----- Begin of function TalkMsg::demand_tribute ------//
  635. //
  636. // <int> isAid - 1 if it's a aid, 0 if it's a tribute.
  637. //
  638. // talk_para1 - the amount of the tribute.
  639. //
  640. void TalkMsg::demand_tribute(int isAid)
  641. {
  642. //---------------------------------------------//
  643. //
  644. // Send:
  645. // <King>'s Kingdom requests/demands <tribute amount> in aid/tribute
  646. // from you.
  647. //
  648. // You request/demand <tribute amount> in aid/tribute from
  649. // <King>'s Kingdom.
  650. //
  651. // Reply:
  652. // <King>'s Kingdom agrees/refuses to give/pay you <tribute amount>
  653. // in aid/tribute.
  654. //
  655. // You agree/refuse to give/pay <King>'s Kingdom <tribute amount>
  656. // in aid/tribute.
  657. //
  658. //---------------------------------------------//
  659. //
  660. // Envoyer:
  661. // Le Royaume de <King> demande/exige une/un aide/tribut de
  662. // <tribute amount> de votre part.
  663. //
  664. // Vous demandez/exigez une/un aide/tribut de <tribute amount> de la
  665. // part du Royaume de <King>.
  666. //
  667. // Répondre:
  668. // Le Royaume de <King> accepte/refuse de vous donner/payer une/un
  669. // aide/tribut de <tribute amount>.
  670. //
  671. // Vous acceptez/refusez de donner/payer une/un aide/tribut de
  672. // <tribute amount> au Royaume de <King>.
  673. //
  674. //---------------------------------------------//
  675. // char* aidStr;
  676. // if( isAid )
  677. // aidStr = "aid";
  678. // else
  679. // aidStr = "tribute";
  680. if( reply_type == REPLY_WAITING || !should_disp_reply )
  681. {
  682. if( viewing_nation_recno == from_nation_recno )
  683. {
  684. if( isAid )
  685. str = "Vous demandez une aide de ";
  686. else
  687. str = "Vous exigez un tribut de ";
  688. str += m.format(talk_para1,2);
  689. str += " de la part du ";
  690. str += to_nation_name();
  691. str += ".";
  692. }
  693. else
  694. {
  695. str = "Le ";
  696. str += from_nation_name();
  697. if( isAid )
  698. str += " demande une aide de ";
  699. else
  700. str += " exige un tribut de ";
  701. str += m.format(talk_para1,2);
  702. str += " de votre part.";
  703. }
  704. }
  705. else
  706. {
  707. if( viewing_nation_recno == from_nation_recno )
  708. {
  709. str = "Le ";
  710. str += to_nation_name();
  711. if( reply_type == REPLY_ACCEPT )
  712. str += " accepte";
  713. else
  714. str += " refuse";
  715. if( isAid )
  716. str += " de vous donner une aide de ";
  717. else
  718. str += " de vous payer un tribut de ";
  719. str += m.format(talk_para1,2);
  720. str += ".";
  721. }
  722. else
  723. {
  724. if( reply_type == REPLY_ACCEPT )
  725. str = "Vous acceptez";
  726. else
  727. str = "Vous refusez";
  728. if( isAid )
  729. str += " de donner une adie de ";
  730. else
  731. str += " de payer un tribut de ";
  732. str += m.format(talk_para1,2);
  733. str += " au ";
  734. str += from_nation_name();
  735. str += ".";
  736. }
  737. }
  738. }
  739. //------- End of function TalkMsg::demand_tribute ------//
  740. //----- Begin of function TalkMsg::give_tech ------//
  741. //
  742. // talk_para1 - id. of the tech given.
  743. // talk_para2 - version of the tech.
  744. //
  745. void TalkMsg::give_tech()
  746. {
  747. //---------------------------------------------//
  748. //
  749. // Send:
  750. // <King>'s Kingdom offers <tech><version> technology to you.
  751. //
  752. // You offer <tech><version> technology to <King>'s Kingdom.
  753. //
  754. // Reply:
  755. // <King>'s Kingdom accepts/rejects your gift of <tech><version>
  756. // technology.
  757. //
  758. // You accept/reject the gift of <tech><version> technology
  759. // from <King>'s Kingdom.
  760. //
  761. //---------------------------------------------//
  762. //
  763. // Envoyer:
  764. // Le Royaume de <King> vous offre la technologie <tech><version>.
  765. //
  766. // Vous offrez la technologie <tech><version> au Royaume de <King>.
  767. //
  768. // Répondre:
  769. // Le Royaume de <King> accepte/refuse votre offre de la technologie
  770. // <tech><version>.
  771. //
  772. // Vous acceptez/refusez l'offre du Royaume de <King> concernant la
  773. // technologie <tech><version>.
  774. //
  775. //---------------------------------------------//
  776. if( reply_type == REPLY_WAITING || !should_disp_reply )
  777. {
  778. if( viewing_nation_recno == from_nation_recno )
  779. {
  780. str = "Vous offrez la technologie ";
  781. str += tech_res[talk_para1]->tech_des();
  782. if( talk_para2 ) // Ships do not have different versions
  783. {
  784. str += " ";
  785. str += m.roman_number(talk_para2);
  786. }
  787. str += " au ";
  788. str += to_nation_name();
  789. str += ".";
  790. }
  791. else
  792. {
  793. str = "Le ";
  794. str += from_nation_name();
  795. str += " vous offre la technologie ";
  796. str += tech_res[talk_para1]->tech_des();
  797. if( talk_para2 ) // Ships do not have different versions
  798. {
  799. str += " ";
  800. str += m.roman_number(talk_para2);
  801. }
  802. str += ".";
  803. }
  804. }
  805. else
  806. {
  807. if( viewing_nation_recno == from_nation_recno )
  808. {
  809. str = "Le ";
  810. str += to_nation_name();
  811. if( reply_type == REPLY_ACCEPT )
  812. str += " accepte";
  813. else
  814. str += " refuse";
  815. str += " votre offre de la technologie ";
  816. str += tech_res[talk_para1]->tech_des();
  817. if( talk_para2 ) // Ships do not have different versions
  818. {
  819. str += " ";
  820. str += m.roman_number(talk_para2);
  821. }
  822. str += ".";
  823. }
  824. else
  825. {
  826. if( reply_type == REPLY_ACCEPT )
  827. str = "Vous acceptez l'offre du ";
  828. else
  829. str = "Vous refusez l'offre du ";
  830. str += from_nation_name();
  831. str += " concernant la technologie ";
  832. str += tech_res[talk_para1]->tech_des();
  833. if( talk_para2 ) // Ships do not have different versions
  834. {
  835. str += " ";
  836. str += m.roman_number(talk_para2);
  837. }
  838. str += ".";
  839. }
  840. }
  841. }
  842. //------- End of function TalkMsg::give_tech ------//
  843. //----- Begin of function TalkMsg::demand_tech ------//
  844. //
  845. // Demand for the latest version of the technology.
  846. //
  847. // talk_para1 - id. of the tech demanded.
  848. // talk_para2 - version of the tech if the nation agrees to transfer
  849. // technology.
  850. //
  851. void TalkMsg::demand_tech()
  852. {
  853. //---------------------------------------------//
  854. //
  855. // Send:
  856. // <King>'s Kingdom demands/requests the latest
  857. // <tech> technology from you.
  858. //
  859. // You demand/request the latest <tech> technology from
  860. // <King>'s Kingdom.
  861. //
  862. // Reply:
  863. // <King>'s Kingdom agrees/refuses to transfer its latest <tech>
  864. // technology to you.
  865. //
  866. // You agree/refuse to transfer your <tech> technology to
  867. // <King>'s Kingdom.
  868. //
  869. //---------------------------------------------//
  870. //
  871. // Envoyer:
  872. // Le Royaume de <King> exige/demande votre dernière version de
  873. // <tech>.
  874. //
  875. // Vous exigez/demandez sa dernière version de <tech> au
  876. // Royaume de <King>.
  877. //
  878. // Répondre:
  879. // Le Royaume de <King> accepte/refuse de vous livrer sa dernière version
  880. // de <tech>.
  881. //
  882. // Vous acceptez/refusez de livrer votre dernière version de <tech> au
  883. // Royaume de <King>.
  884. //
  885. //---------------------------------------------//
  886. char* requestStr;
  887. if( nation_array[from_nation_recno]->get_relation_status(to_nation_recno)
  888. >= NATION_FRIENDLY )
  889. {
  890. requestStr = "demande";
  891. }
  892. else
  893. {
  894. requestStr = "exige";
  895. }
  896. //------------------------------------------//
  897. if( reply_type == REPLY_WAITING || !should_disp_reply )
  898. {
  899. if( viewing_nation_recno == from_nation_recno )
  900. {
  901. str = "Vous ";
  902. str += requestStr;
  903. str += "z sa dernière version de ";
  904. str += tech_res[talk_para1]->tech_des();
  905. str += " au ";
  906. str += to_nation_name();
  907. str += ".";
  908. }
  909. else
  910. {
  911. str = "Le ";
  912. str += from_nation_name();
  913. str += " ";
  914. str += requestStr;
  915. str += " votre dernière version de ";
  916. str += tech_res[talk_para1]->tech_des();
  917. str += ".";
  918. }
  919. }
  920. else
  921. {
  922. if( viewing_nation_recno == from_nation_recno )
  923. {
  924. str = "Le ";
  925. str += to_nation_name();
  926. if( reply_type == REPLY_ACCEPT )
  927. str += " accepte";
  928. else
  929. str += " refuse";
  930. str += " de vous livrer sa dernière version de ";
  931. str += tech_res[talk_para1]->tech_des();
  932. str += ".";
  933. }
  934. else
  935. {
  936. if( reply_type == REPLY_ACCEPT )
  937. str = "Vous acceptez";
  938. else
  939. str = "Vous refusez";
  940. str += " de livrer votre dernière version de ";
  941. str += tech_res[talk_para1]->tech_des();
  942. str += " au ";
  943. str += from_nation_name();
  944. str += ".";
  945. }
  946. }
  947. }
  948. //------- End of function TalkMsg::demand_tech ------//
  949. //----- Begin of function TalkMsg::request_military_aid ------//
  950. //
  951. void TalkMsg::request_military_aid()
  952. {
  953. //---------------------------------------------//
  954. //
  955. // Send:
  956. // <King>'s Kingdom requests immediate military aid from you.
  957. // You request immediate military aid from <King>'s Kingdom.
  958. //
  959. // Reply:
  960. // <King>'s Kingdom agrees to immediately send your requested
  961. // military aid.
  962. // <King>'s Kingdom denies you your requested military aid.
  963. //
  964. // You agree to immediately send military aid to <King>'s Kingdom.
  965. // You refuse to send military aid to <King>'s Kingdom.
  966. //
  967. //---------------------------------------------//
  968. //
  969. // Envoyer:
  970. // Le Royaume de <King> vous demande un soutien militaire immédiat.
  971. // Vous demandez un soutien militaire immédiat au Royaume de <King>.
  972. //
  973. // Répondre:
  974. // Le Royaume de <King> vous apporte un soutien militaire immédiat.
  975. // Le Royaume de <King> refuse de vous apporter un soutien militaire
  976. // immédiat.
  977. //
  978. // Vous apportez un soutien militaire immédiat au Royaume de <King>.
  979. // Vous refusez d'apporter un soutien militaire immédiat au Royaume de
  980. // <King>.
  981. //
  982. //---------------------------------------------//
  983. if( reply_type == REPLY_WAITING || !should_disp_reply )
  984. {
  985. if( viewing_nation_recno == from_nation_recno )
  986. {
  987. str = "Vous demandez un soutien militaire immédiat au ";
  988. str += to_nation_name();
  989. str += ".";
  990. }
  991. else
  992. {
  993. str = "Le ";
  994. str += from_nation_name();
  995. str += " vous demande un soutien militaire immédiat.";
  996. }
  997. }
  998. else
  999. {
  1000. if( viewing_nation_recno == from_nation_recno )
  1001. {
  1002. str = "Le ";
  1003. str += to_nation_name();
  1004. if( reply_type == REPLY_ACCEPT )
  1005. str += " vous apporte un soutien militaire immédiat.";
  1006. else
  1007. str += " refuse de vous apporter un soutien militaire immédiat.";
  1008. }
  1009. else
  1010. {
  1011. if( reply_type == REPLY_ACCEPT )
  1012. str = "Vous apportez un soutien militaire immédiat au ";
  1013. else
  1014. str = "Vous refusez d'apporter un soutien militaire immédiat au ";
  1015. str += from_nation_name();
  1016. str += ".";
  1017. }
  1018. }
  1019. }
  1020. //------- End of function TalkMsg::request_military_aid ------//
  1021. //----- Begin of function TalkMsg::request_trade_embargo ------//
  1022. //
  1023. // talk_para1 - the nation to have a trade embargo on.
  1024. //
  1025. void TalkMsg::request_trade_embargo()
  1026. {
  1027. //---------------------------------------------//
  1028. //
  1029. // Send:
  1030. // <King>'s Kingdom requests you to join an embargo on trade with
  1031. // <King B>'s Kingdom.
  1032. //
  1033. // You request <King>'s Kingdom to join an embargo on trade with
  1034. // <King B>'s Kingdom.
  1035. //
  1036. // Reply:
  1037. // <King>'s Kingdom agrees/refuses to join an embargo on trade
  1038. // with <King B>'s Kingdom.
  1039. //
  1040. // You agree/refuse to join an embargo on trade with <King B>'s Kingdom
  1041. // as requested by <King>'s Kingdom.
  1042. //
  1043. //---------------------------------------------//
  1044. //
  1045. // Envoyer:
  1046. // Le Royaume de <King> demande que vous preniez part à un embargo
  1047. // commercial contre le Royaume de <King B>.
  1048. //
  1049. // Vous demandez au Royaume de <King> de prendre part à un embargo
  1050. // commercial contre le Royaume de <King B>.
  1051. //
  1052. // Répondre:
  1053. // Le Royaume de <King> accepte/refuse de prendre part à un embargo
  1054. // commercial contre le Royaume de <King B>.
  1055. //
  1056. // Vous acceptez/refusez de prendre part à l'embargo commercial contre
  1057. // le Royaume de <King B>, organisé par le Royaume de <King>.
  1058. //
  1059. //---------------------------------------------//
  1060. if( reply_type == REPLY_WAITING || !should_disp_reply )
  1061. {
  1062. if( viewing_nation_recno == from_nation_recno )
  1063. {
  1064. str = "Vous demandez au ";
  1065. str += to_nation_name();
  1066. str += " de prendre part";
  1067. }
  1068. else
  1069. {
  1070. str = "Le ";
  1071. str += from_nation_name();
  1072. str += " demande que vous preniez part";
  1073. }
  1074. str += " à un embargo commercial contre le ";
  1075. str += nation_array[talk_para1]->nation_name();
  1076. str += nation_color_code_str(talk_para1);
  1077. str += ".";
  1078. }
  1079. else
  1080. {
  1081. if( viewing_nation_recno == from_nation_recno )
  1082. {
  1083. str = "Le ";
  1084. str += to_nation_name();
  1085. if( reply_type == REPLY_ACCEPT )
  1086. str += " accepte";
  1087. else
  1088. str += " refuse";
  1089. str += " de prendre part à un embargo commercial contre le ";
  1090. str += nation_array[talk_para1]->nation_name();
  1091. str += nation_color_code_str(talk_para1);
  1092. str += ".";
  1093. }
  1094. else
  1095. {
  1096. if( reply_type == REPLY_ACCEPT )
  1097. str = "Vous acceptez";
  1098. else
  1099. str = "Vous refusez";
  1100. str += " de prendre part à l'embargo commercial contre le ";
  1101. str += nation_array[talk_para1]->nation_name();
  1102. str += nation_color_code_str(talk_para1);
  1103. str += ", organisé par le ";
  1104. str += from_nation_name();
  1105. str += ".";
  1106. }
  1107. }
  1108. }
  1109. //------- End of function TalkMsg::request_trade_embargo ------//
  1110. //----- Begin of function TalkMsg::request_surrender ------//
  1111. //
  1112. void TalkMsg::request_surrender()
  1113. {
  1114. //---------------------------------------------//
  1115. //
  1116. // Send:
  1117. //
  1118. // To unite our two Kingdoms under his rule, King
  1119. // <King name> offers <amount> for your throne.
  1120. //
  1121. // You offer <amount> for the throne of <King>'s
  1122. // Kingdom.
  1123. //
  1124. // Reply:
  1125. //
  1126. // King <king name> refuses to dishonor himself by
  1127. // selling his throne!
  1128. //
  1129. // King <king name> agrees to take your money in
  1130. // exchange for his throne.
  1131. //
  1132. // You refuse to dishonor yourself by selling your
  1133. // throne to <King>'s kingdom.
  1134. //
  1135. //---------------------------------------------//
  1136. //
  1137. // Envoyer:
  1138. //
  1139. // Afin d'unifier vos deux Royaumes sous son règne, le Roi <King name>
  1140. // vous offre <amount> pour votre trône.
  1141. //
  1142. // Vous offrez <amount> pour régner sur le Royaume de <King>.
  1143. //
  1144. // Répondre:
  1145. //
  1146. // Le Roi <king name> refuse de se déshonorer en bradant son trône !
  1147. //
  1148. // Le Roi <king name> accepte votre or en échange de son trône.
  1149. //
  1150. // Vous refusez de vous déshonorer en bradant votre trône au Royaume de
  1151. // <King>.
  1152. //
  1153. //---------------------------------------------//
  1154. if( reply_type == REPLY_WAITING || !should_disp_reply )
  1155. {
  1156. if( viewing_nation_recno == from_nation_recno )
  1157. {
  1158. str = "Vous offrez ";
  1159. str += talk_para1*10; // *10 to restore its original value.
  1160. str += " pour régner sur le ";
  1161. str += to_nation_name();
  1162. str += ".";
  1163. }
  1164. else
  1165. {
  1166. str = "Afin d'unifier vos deux Royaumes sous son règne, le Roi ";
  1167. str += from_king_name();
  1168. str += " vous offre ";
  1169. str += talk_para1*10; // *10 to restore its original value.
  1170. str += " pour votre trône.";
  1171. }
  1172. }
  1173. else
  1174. {
  1175. if( viewing_nation_recno == from_nation_recno )
  1176. {
  1177. str = "Le Roi ";
  1178. str += to_king_name();
  1179. if( reply_type == REPLY_ACCEPT )
  1180. str += " accepte votre or en échange de son trône.";
  1181. else
  1182. str += " refuse de se déshonorer en bradant son trône !";
  1183. }
  1184. else
  1185. {
  1186. if( reply_type == REPLY_ACCEPT )
  1187. {
  1188. str = "You agree to take the money in exchange for your throne.";
  1189. }
  1190. else
  1191. {
  1192. str = "Vous refusez de vous déshonorer en bradant votre trône au ";
  1193. str += from_nation_name();
  1194. str += ".";
  1195. }
  1196. }
  1197. }
  1198. }
  1199. //------- End of function TalkMsg::request_surrender ------//
  1200. //----- Begin of function TalkMsg::surrender ------//
  1201. //
  1202. void TalkMsg::surrender()
  1203. {
  1204. //---------------------------------------------//
  1205. //
  1206. // Send:
  1207. // <King>'s Kingdom offerrrendered to you.
  1208. // You have surrendered to <King>'s Kingdom.
  1209. //
  1210. //---------------------------------------------//
  1211. //
  1212. // Envoyer:
  1213. // Le Royaume de <King> s'est soumis à vous.
  1214. // Vous abandonnez votre Royaume au Royaume de <King>.
  1215. //
  1216. //---------------------------------------------//
  1217. if( viewing_nation_recno == from_nation_recno )
  1218. {
  1219. str = "Vous abandonnez votre Royaume au ";
  1220. str += to_nation_name();
  1221. str += ".";
  1222. }
  1223. else
  1224. {
  1225. str = "Le ";
  1226. str += from_nation_name();
  1227. str += " s'est soumis à vous.";
  1228. }
  1229. }
  1230. //------- End of function TalkMsg::surrender ------//
  1231. #endif