116
149
//-----------------------------------------------------------------------------
151
//! A permanent record of a Hero searching a Ruin and finding a sage.
118
152
class History_FoundSage : public History
155
//! Default constructor.
121
156
History_FoundSage();
157
//! Copy constructor.
158
History_FoundSage(const History_FoundSage &history);
159
//! Load the historical event from an opened saved-game file.
122
160
History_FoundSage(XML_Helper* helper);
123
162
~History_FoundSage();
164
//! Return some debug information about this historical event.
125
165
std::string dump() const;
167
//! Save the historical event to an opened saved-game file.
126
168
bool save(XML_Helper* helper) const;
170
//! Populate the event with the Hero who found the sage.
128
171
bool fillData(Hero *hero);
173
//! Get the name of the Hero who found the sage.
129
174
std::string getHeroName() const {return d_hero;}
177
//! The name of the Hero.
132
178
std::string d_hero;
135
181
//-----------------------------------------------------------------------------
183
//! A permanent record of the amount of gold pieces a player has.
137
184
class History_GoldTotal : public History
187
//! Default constructor.
140
188
History_GoldTotal();
189
//! Copy constructor.
190
History_GoldTotal(const History_GoldTotal &history);
191
//! Load the historical event from an opened saved-game file.
141
192
History_GoldTotal(XML_Helper* helper);
142
194
~History_GoldTotal();
196
//! Return some debug information about this historical event.
144
197
std::string dump() const;
199
//! Save the historical event to an opened saved-game file.
145
200
bool save(XML_Helper* helper) const;
202
//! Populate the event with the amount of gold pieces the Player has.
147
203
bool fillData(int gold);
205
//! Get the amount of gold associated with this event.
148
206
int getGold() const {return d_gold;}
209
//! The amount of gold pieces the player has at a point in time.
154
213
//-----------------------------------------------------------------------------
215
//! A permanent record of a new Hero emerging in a City.
156
216
class History_HeroEmerges : public History
219
//! Default constructor.
159
220
History_HeroEmerges();
221
//! Copy constructor.
222
History_HeroEmerges(const History_HeroEmerges &history);
223
//! Load the historical event from an opened saved-game file.
160
224
History_HeroEmerges(XML_Helper* helper);
161
226
~History_HeroEmerges();
228
//! Return some debug information about this historical event.
163
229
std::string dump() const;
231
//! Save the historical event to an opened saved-game file.
164
232
bool save(XML_Helper* helper) const;
234
//! Populate the event with pertinent data.
236
* Populate the event with the new Hero who has showed up and
237
* the City where it has appeared.
239
* @param hero The Hero that has emergerd.
240
* @param city The City where the Hero has emerged.
166
242
bool fillData(Hero *hero, City *city);
244
//! Get the name of the Hero who appeared.
167
245
std::string getHeroName() const {return d_hero;}
247
//! Get the name of the City where the Hero has emerged.
168
248
std::string getCityName() const {return d_city;}
251
//! The name of the Hero who emerged.
171
252
std::string d_hero;
254
//! The name of the City where the Hero emerged.
172
255
std::string d_city;
175
258
//-----------------------------------------------------------------------------
260
//! A permanent record of an enemy city being defeated.
177
261
class History_CityWon : public History
264
//! Default constructor.
180
265
History_CityWon();
266
//! Copy constructor.
267
History_CityWon(const History_CityWon &history);
268
//! Load the historical event from an opened saved-game file.
181
269
History_CityWon(XML_Helper* helper);
182
271
~History_CityWon();
273
//! Return some debug information about this historical event.
184
274
std::string dump() const;
276
//! Save the historical event to an opened saved-game file.
185
277
bool save(XML_Helper* helper) const;
279
//! Populate the record with the City that the Player defeated.
188
280
bool fillData(City *city);
282
//! Get the Id of the City object that was defeated.
189
283
Uint32 getCityId() const {return d_city;}
286
//! The Id of the City object that was defeated.
195
290
//-----------------------------------------------------------------------------
292
//! A permanent record of an enemy city being defeated by a Hero.
197
293
class History_HeroCityWon: public History
296
//! Default constructor.
200
297
History_HeroCityWon();
298
//! Copy constructor.
299
History_HeroCityWon(const History_HeroCityWon &history);
300
//! Load the historical event from an opened saved-game file.
201
301
History_HeroCityWon(XML_Helper* helper);
202
303
~History_HeroCityWon();
305
//! Return some debug information about this historical event.
204
306
std::string dump() const;
308
//! Save the historical event to an opened saved-game file.
205
309
bool save(XML_Helper* helper) const;
311
//! Populate the event with pertinent data.
313
* Populate the event with the City that was defeated and the
314
* Hero that assisted in the conquering.
316
* @param city The City that was conquered.
317
* @param hero The Hero who lead the conquering of the City.
207
319
bool fillData(Hero *hero, City *city);
321
//! Get the name of the Hero who conquered the City.
208
322
std::string getHeroName() const {return d_hero;}
324
//! Get the name of the City that was conquered.
209
325
std::string getCityName() const {return d_city;}
328
//! The name of the Hero who helped in conquering the City.
212
329
std::string d_hero;
331
//! The name of the City that was conquered.
213
332
std::string d_city;
216
335
//-----------------------------------------------------------------------------
337
//! A permanent record of an enemy city being razed.
218
338
class History_CityRazed : public History
341
//! Default constructor.
221
342
History_CityRazed();
343
//! Copy constructor.
344
History_CityRazed(const History_CityRazed &history);
345
//! Load the historical event from an opened saved-game file.
222
346
History_CityRazed(XML_Helper* helper);
223
348
~History_CityRazed();
350
//! Return some debug information about this historical event.
225
351
std::string dump() const;
353
//! Save the historical event to an opened saved-game file.
226
354
bool save(XML_Helper* helper) const;
356
//! Populate the event with the City that was razed.
228
357
bool fillData(City *city);
359
//! Get the Id of the City object that was razed.
229
360
Uint32 getCityId() const {return d_city;}
363
//! The Id of the City that was razed.
235
367
//-----------------------------------------------------------------------------
369
//! A permanent record of a Hero initiating a Quest.
237
370
class History_HeroQuestStarted : public History
373
//! Default constructor.
240
374
History_HeroQuestStarted();
375
//! Copy constructor.
376
History_HeroQuestStarted(const History_HeroQuestStarted &history);
377
//! Load the historical event from an opened saved-game file.
241
378
History_HeroQuestStarted(XML_Helper* helper);
242
380
~History_HeroQuestStarted();
382
//! Return some debug information about this historical event.
244
383
std::string dump() const;
385
//! Save the historical event to an opened saved-game file.
245
386
bool save(XML_Helper* helper) const;
388
//! Populate the event with the Hero who initiated a new Quest.
247
389
bool fillData(Hero *hero);
391
//! Get the name of the Hero who started a Quest.
248
392
std::string getHeroName() const {return d_hero;}
395
//! The name of the Hero who started the Quest.
251
396
std::string d_hero;
254
399
//-----------------------------------------------------------------------------
401
//! A permanent record of a Hero completing a Quest.
256
402
class History_HeroQuestCompleted: public History
405
//! Default constructor.
259
406
History_HeroQuestCompleted();
407
//! Copy constructor.
408
History_HeroQuestCompleted(const History_HeroQuestCompleted &history);
409
//! Load the historical event from an opened saved-game file.
260
410
History_HeroQuestCompleted(XML_Helper* helper);
261
412
~History_HeroQuestCompleted();
414
//! Return some debug information about this historical event.
263
415
std::string dump() const;
417
//! Save the historical event to an opened saved-game file.
264
418
bool save(XML_Helper* helper) const;
420
//! Populate the event with the Hero who finished a Quest.
266
421
bool fillData(Hero *hero);
423
//! Get the name of the Hero who finished a Quest.
267
424
std::string getHeroName() const {return d_hero;}
427
//! The name of the Hero who completed the Quest.
270
428
std::string d_hero;
273
431
//-----------------------------------------------------------------------------
433
//! A permanent record of a Hero killed in the defense or attack of a City.
275
434
class History_HeroKilledInCity : public History
437
//! Default constructor.
278
438
History_HeroKilledInCity();
439
//! Copy constructor.
440
History_HeroKilledInCity(const History_HeroKilledInCity &history);
441
//! Load the historical event from an opened saved-game file.
279
442
History_HeroKilledInCity(XML_Helper* helper);
280
444
~History_HeroKilledInCity();
446
//! Return some debug information about this historical event.
282
447
std::string dump() const;
449
//! Save the historical event to an opened saved-game file.
283
450
bool save(XML_Helper* helper) const;
452
//! Populate the event with pertinent data.
454
* Populate the event with the Hero who was killed and the City where
457
* @param hero The Hero who died.
458
* @param city The City that houses the Hero's broken corpse.
285
460
bool fillData(Hero *hero, City *city);
462
//! Get the name of the Hero who died.
286
463
std::string getHeroName() const {return d_hero;}
465
//! Get the name of the City where the Hero died.
287
466
std::string getCityName() const {return d_city;}
469
//! Get the name of the Hero who was killed.
290
470
std::string d_hero;
472
//! Get the name of the City where the Hero was killed.
291
473
std::string d_city;
294
476
//-----------------------------------------------------------------------------
478
//! A permanent record of a Hero killed in battle outside of a City.
296
479
class History_HeroKilledInBattle: public History
482
//! Default constructor.
299
483
History_HeroKilledInBattle();
484
//! Copy constructor.
485
History_HeroKilledInBattle(const History_HeroKilledInBattle &history);
486
//! Load the historical event from an opened saved-game file.
300
487
History_HeroKilledInBattle(XML_Helper* helper);
301
489
~History_HeroKilledInBattle();
491
//! Return some debug information about this historical event.
303
492
std::string dump() const;
494
//! Save the historical event to an opened saved-game file.
304
495
bool save(XML_Helper* helper) const;
497
//! Populate the event with the Hero who was killed in battle.
306
498
bool fillData(Hero *hero);
500
//! Get the name of the Hero who died in battle outside of a City.
307
501
std::string getHeroName() const {return d_hero;}
504
//! The name of the Hero who died in battle outside of a City.
310
505
std::string d_hero;
313
508
//-----------------------------------------------------------------------------
510
//! A permanent record of a Hero killed while searching a Ruin.
315
511
class History_HeroKilledSearching: public History
514
//! Default constructor.
318
515
History_HeroKilledSearching();
516
//! Copy constructor.
517
History_HeroKilledSearching(const History_HeroKilledSearching &history);
518
//! Load the historical event from an opened saved-game file.
319
519
History_HeroKilledSearching(XML_Helper* helper);
320
521
~History_HeroKilledSearching();
523
//! Return some debug information about this historical event.
322
524
std::string dump() const;
526
//! Save the historical event to an opened saved-game file.
323
527
bool save(XML_Helper* helper) const;
529
//! Populate the event with the Hero who was killed while searching.
325
530
bool fillData(Hero *hero);
532
//! Get the name of the Hero who died while searching a Ruin.
326
533
std::string getHeroName() const {return d_hero;}
536
//! The name of the Hero who died while searching a Ruin.
329
537
std::string d_hero;
332
540
//-----------------------------------------------------------------------------
542
//! A permanent record of the player's score.
334
543
class History_Score: public History
546
//! Default constructor.
548
//! Copy constructor.
549
History_Score(const History_Score &history);
550
//! Load the historical event from an opened saved-game file.
338
551
History_Score(XML_Helper* helper);
339
553
~History_Score();
555
//! Return some debug information about this historical event.
341
556
std::string dump() const;
558
//! Save the historical event to an opened saved-game file.
342
559
bool save(XML_Helper* helper) const;
561
//! Populate the event with the player's score for this turn.
344
562
bool fillData(Uint32 score);
564
//! Get the player's score for this turn.
345
565
Uint32 getScore() const {return d_score;}
568
//! The player's score.
351
572
//-----------------------------------------------------------------------------
574
//! A permanent record of the player being utterly defeated.
353
575
class History_PlayerVanquished: public History
578
//! Default constructor.
356
579
History_PlayerVanquished();
580
//! Copy constructor.
581
History_PlayerVanquished(const History_PlayerVanquished &history);
582
//! Load the historical event from an opened saved-game file.
357
583
History_PlayerVanquished(XML_Helper* helper);
358
585
~History_PlayerVanquished();
587
//! Return some debug information about this historical event.
360
588
std::string dump() const;
590
//! Save the historical event to an opened saved-game file.
361
591
bool save(XML_Helper* helper) const;
365
595
//-----------------------------------------------------------------------------
597
//! A permanent record of the player making peace with an opponent.
367
598
class History_DiplomacyPeace : public History
601
//! Default constructor.
370
602
History_DiplomacyPeace();
603
//! Copy constructor.
604
History_DiplomacyPeace(const History_DiplomacyPeace &history);
605
//! Load the historical event from an opened saved-game file.
371
606
History_DiplomacyPeace(XML_Helper* helper);
372
608
~History_DiplomacyPeace();
610
//! Return some debug information about this historical event.
374
611
std::string dump() const;
613
//! Save the historical event to an opened saved-game file.
375
614
bool save(XML_Helper* helper) const;
616
//! Populate the event with the Player who we are at peace with.
377
617
bool fillData(Player *opponent);
619
//! Get the Id of the Player object we are at peace with.
378
620
Uint32 getOpponentId() const {return d_opponent_id;}
623
//! The Id of the Player object we are at peace with.
381
624
Uint32 d_opponent_id;
384
627
//-----------------------------------------------------------------------------
629
//! A permanent record of the player going to war with an opponent.
386
630
class History_DiplomacyWar: public History
633
//! Default constructor.
389
634
History_DiplomacyWar();
635
//! Copy constructor.
636
History_DiplomacyWar(const History_DiplomacyWar &history);
637
//! Load the historical event from an opened saved-game file.
390
638
History_DiplomacyWar(XML_Helper* helper);
391
640
~History_DiplomacyWar();
642
//! Return some debug information about this historical event.
393
643
std::string dump() const;
645
//! Save the historical event to an opened saved-game file.
394
646
bool save(XML_Helper* helper) const;
648
//! Populate the event with the Player who we are at war with.
396
649
bool fillData(Player *opponent);
651
//! Get the Id of the Player object we are at war with.
397
652
Uint32 getOpponentId() const {return d_opponent_id;}
655
// The Id of the Player object we are at war with.
400
656
Uint32 d_opponent_id;
403
659
//-----------------------------------------------------------------------------
661
//! A permanent record of the player being treacherous to an opponent.
405
662
class History_DiplomacyTreachery: public History
665
//! Default constructor.
408
666
History_DiplomacyTreachery();
667
//! Copy constructor.
668
History_DiplomacyTreachery(const History_DiplomacyTreachery &history);
669
//! Load the historical event from an opened saved-game file.
409
670
History_DiplomacyTreachery(XML_Helper* helper);
410
672
~History_DiplomacyTreachery();
674
//! Return some debug information about this historical event.
412
675
std::string dump() const;
677
//! Save the historical event to an opened saved-game file.
413
678
bool save(XML_Helper* helper) const;
680
//! Populate the event with the Player we performed treachery on.
415
681
bool fillData(Player *opponent);
683
//! Get the Id of the Player object that we peformed treachery on.
416
684
Uint32 getOpponentId() const {return d_opponent_id;}
687
//! The Id of the Player object that we peformed treachery on.
419
688
Uint32 d_opponent_id;
422
691
//-----------------------------------------------------------------------------
693
//! A permanent record of a Hero finding powerful allies.
424
694
class History_HeroFindsAllies : public History
697
//! Default constructor.
427
698
History_HeroFindsAllies();
699
//! Copy constructor.
700
History_HeroFindsAllies(const History_HeroFindsAllies &history);
701
//! Load the historical event from an opened saved-game file.
428
702
History_HeroFindsAllies(XML_Helper* helper);
429
704
~History_HeroFindsAllies();
706
//! Return some debug information about this historical event.
431
707
std::string dump() const;
709
//! Save the historical event to an opened saved-game file.
432
710
bool save(XML_Helper* helper) const;
712
//! Populate the event with the name of the Hero who found allies.
434
713
bool fillData(Hero *hero);
715
//! Get the name of the Hero who found powerful allies.
435
716
std::string getHeroName() const {return d_hero;}
719
//! The name of the Hero who found powerful allies at a Ruin.
438
720
std::string d_hero;