Loaded some descriptions
I wrote a few descriptions for monster ideas. I also managed to load the basic crawl monster descriptions into a vector. I'm studying containers right now for Strousrup's book, _The C++ Programming Language_, St. Ed. I guess I should use a map instead.
Here's what I have right now:
//Note.cc
using namespace std;
#include
#include
#include
string describe_monsters( int );
class Note
{
friend ostream &operator<<( ostream&, const Note & );
public:
Note( string s){ description = s; }
void displayNote(){ cout << description; }
private:
string description;
};
ostream &operator<<( ostream &output, const Note &n )
{
output << n.description;
return output;
}
//cwde
int main()
{
vector monsterDescriptions;
monsterDescriptions.push_back("Rats are rats. This rat's fat.");
monsterDescriptions.push_back("No bats are good bats.");
monsterDescriptions.push_back("\"Yip! yip!yip! Yip! yip!yip! Yip! yip!yip!.....Rar!Rar!Rar!Rar!rar!" );
monsterDescriptions.push_back("\"I give your head to Blork. He eat your brain for breakfast. Maybe me get an eyeball. No....I eat your brain.");
monsterDescriptions.push_back("\"Mead tastes good! So do Dwarfs! I soak my Dwarf's corpse in mead, of course!\"" );
monsterDescriptions.push_back( "A filthy, dirty creature." );
monsterDescriptions.push_back( "\"Eves? Giv' me a break. Eve's don't botta us. I dunno why; maybe we too tough. Heh.\"");
/* eves
eves are psychic beings that mutate by stealing players skills and abilities. Some, like wichoreveda, are completely or mostly unformed; while others, like raceevelst, are created from a spiritual seed. For the raceevelst, the seed is the spirit of a centaur that is lost from it's body.
*/
monsterDescriptions.push_back( "Your mentor; no, your enemy; no, your lover; no, you can't remember. Everytime you think about this creature, it changes in your mind. Should you kill it? Is it your ally? Is it beautiful, hideous, or bland? You can't remember." ); //unformed eve
monsterDescriptions.push_back( "A pregnant woman with heavy eyes." ); //angry pregnant human eve
monsterDescriptions.push_back("The centaur glances about frenetically. 'Til he sees you of course." ); // lost centaur eve
//crawl descriptions
for ( int i = 0; i < 440; ++i )
{
monsterDescriptions.push_back( describe_monsters( i ) );
}
for ( int i = 0; i < monsterDescriptions.size(); i++ )
cout << i << monsterDescriptions[i] << endl;
return 0;
}
// From enum.h
// note this order is very sensitive... look at mons_is_unique()
enum monster_type // (int) menv[].type
{
MONS_GIANT_ANT, // 0
MONS_GIANT_BAT,
MONS_CENTAUR,
MONS_RED_DEVIL,
MONS_ETTIN,
MONS_FUNGUS, // 5
...
// from describe.cc
//---------------------------------------------------------------
//
// describe_monsters
//
// Contains sketchy descriptions of every monster in the game.
//
//---------------------------------------------------------------
string describe_monsters(int class_described )
{
std::string description;
description.reserve(200);
/*
#ifdef DOS_TERM
char buffer[4000];
gettext(1, 1, 80, 25, buffer);
// window(25, 1, 80, 25);
#endif
*/
/* I don't understand this part yet.
clrscr();
description = ptr_monam( &(menv[ which_mons ]), DESC_CAP_A );
description += "$$";
*/
switch (class_described)
{
// (missing) case 423 - MONS_ANOTHER_LAVA_THING ??? 15jan2000 {dlb}
// no entry in m_list.h 17jan200 {dlb}
// monster has no stats!
// mv: changed ANOTHER_LAVA_THING to SALAMANDER, added stats and
// description
// (missing) case 250 - MONS_PROGRAM_BUG ??? 16jan2000 {dlb}
case MONS_KILLER_BEE_LARVA:
description += "A small, powerless larva of killer bee.";
break;
case MONS_QUASIT:
description += "A small twisted demon with long sharply pointed tail.";
break;
case MONS_ANGEL:
description += "A winged holy being of unnatural beauty. "
"It's surrounded by aura of brilliant golden light. ";
break;
case MONS_HUMAN:
// These should only be possible from polymorphing or shapeshifting.
description += "A remarkably nondescript person. How odd!";
break;
...
Here's what I have right now:
//Note.cc
using namespace std;
#include
#include
#include
string describe_monsters( int );
class Note
{
friend ostream &operator<<( ostream&, const Note & );
public:
Note( string s){ description = s; }
void displayNote(){ cout << description; }
private:
string description;
};
ostream &operator<<( ostream &output, const Note &n )
{
output << n.description;
return output;
}
//cwde
int main()
{
vector
monsterDescriptions.push_back("Rats are rats. This rat's fat.");
monsterDescriptions.push_back("No bats are good bats.");
monsterDescriptions.push_back("\"Yip! yip!yip! Yip! yip!yip! Yip! yip!yip!.....Rar!Rar!Rar!Rar!rar!" );
monsterDescriptions.push_back("\"I give your head to Blork. He eat your brain for breakfast. Maybe me get an eyeball. No....I eat your brain.");
monsterDescriptions.push_back("\"Mead tastes good! So do Dwarfs! I soak my Dwarf's corpse in mead, of course!\"" );
monsterDescriptions.push_back( "A filthy, dirty creature." );
monsterDescriptions.push_back( "\"Eves? Giv' me a break. Eve's don't botta us. I dunno why; maybe we too tough. Heh.\"");
/* eves
eves are psychic beings that mutate by stealing players skills and abilities. Some, like wichoreveda, are completely or mostly unformed; while others, like raceevelst, are created from a spiritual seed. For the raceevelst, the seed is the spirit of a centaur that is lost from it's body.
*/
monsterDescriptions.push_back( "Your mentor; no, your enemy; no, your lover; no, you can't remember. Everytime you think about this creature, it changes in your mind. Should you kill it? Is it your ally? Is it beautiful, hideous, or bland? You can't remember." ); //unformed eve
monsterDescriptions.push_back( "A pregnant woman with heavy eyes." ); //angry pregnant human eve
monsterDescriptions.push_back("The centaur glances about frenetically. 'Til he sees you of course." ); // lost centaur eve
//crawl descriptions
for ( int i = 0; i < 440; ++i )
{
monsterDescriptions.push_back( describe_monsters( i ) );
}
for ( int i = 0; i < monsterDescriptions.size(); i++ )
cout << i << monsterDescriptions[i] << endl;
return 0;
}
// From enum.h
// note this order is very sensitive... look at mons_is_unique()
enum monster_type // (int) menv[].type
{
MONS_GIANT_ANT, // 0
MONS_GIANT_BAT,
MONS_CENTAUR,
MONS_RED_DEVIL,
MONS_ETTIN,
MONS_FUNGUS, // 5
...
// from describe.cc
//---------------------------------------------------------------
//
// describe_monsters
//
// Contains sketchy descriptions of every monster in the game.
//
//---------------------------------------------------------------
string describe_monsters(int class_described )
{
std::string description;
description.reserve(200);
/*
#ifdef DOS_TERM
char buffer[4000];
gettext(1, 1, 80, 25, buffer);
// window(25, 1, 80, 25);
#endif
*/
/* I don't understand this part yet.
clrscr();
description = ptr_monam( &(menv[ which_mons ]), DESC_CAP_A );
description += "$$";
*/
switch (class_described)
{
// (missing) case 423 - MONS_ANOTHER_LAVA_THING ??? 15jan2000 {dlb}
// no entry in m_list.h 17jan200 {dlb}
// monster has no stats!
// mv: changed ANOTHER_LAVA_THING to SALAMANDER, added stats and
// description
// (missing) case 250 - MONS_PROGRAM_BUG ??? 16jan2000 {dlb}
case MONS_KILLER_BEE_LARVA:
description += "A small, powerless larva of killer bee.";
break;
case MONS_QUASIT:
description += "A small twisted demon with long sharply pointed tail.";
break;
case MONS_ANGEL:
description += "A winged holy being of unnatural beauty. "
"It's surrounded by aura of brilliant golden light. ";
break;
case MONS_HUMAN:
// These should only be possible from polymorphing or shapeshifting.
description += "A remarkably nondescript person. How odd!";
break;
...

1 Comments:
Hi,
I mostly visits this website[url=http://www.weightrapidloss.com/lose-10-pounds-in-2-weeks-quick-weight-loss-tips].[/url]You have really contiributed very good info here crawl7drl.blogspot.com. Let me tell you one thing guys, some time we really forget to pay attention towards our health. Here is a fact for you. Research points that almost 70% of all U.S. adults are either chubby or weighty[url=http://www.weightrapidloss.com/lose-10-pounds-in-2-weeks-quick-weight-loss-tips].[/url] So if you're one of these people, you're not alone. Its true that we all can't be like Brad Pitt, Angelina Jolie, Megan Fox, and have sexy and perfect six pack abs. Now the question is how you are planning to have quick weight loss? [url=http://www.weightrapidloss.com/lose-10-pounds-in-2-weeks-quick-weight-loss-tips]Quick weight loss[/url] is not like piece of cake. If you improve some of your daily diet habbits then, its like piece of cake to quickly lose weight.
About me: I am author of [url=http://www.weightrapidloss.com/lose-10-pounds-in-2-weeks-quick-weight-loss-tips]Quick weight loss tips[/url]. I am also health expert who can help you lose weight quickly. If you do not want to go under hard training program than you may also try [url=http://www.weightrapidloss.com/acai-berry-for-quick-weight-loss]Acai Berry[/url] or [url=http://www.weightrapidloss.com/colon-cleanse-for-weight-loss]Colon Cleansing[/url] for effortless weight loss.
Post a Comment
<< Home