Thread: Text-Based RPG

  1. #1
    Registered User
    Join Date
    Sep 2009
    Posts
    14

    Text-Based RPG

    Does anyone think this would be a decent system for a text-based RPG? I'm just starting to learn C++ so any constructive criticism is welcome.

    Code:
    //Program: Role-Playing Game
    //Programmer: MartinThatcher
    //Programming Date: 9/10/09
    
    #include <iostream>
    #include <string>
    
    using namespace std;
    
    int main()
    {
    	int choice = 0, workHours = 0, upgradeChoice = 0, trainingChoice = 0;
    	int attack = 10, defense = 10, gold = 500, pay = 0;
    	int combatExperience = 0, defenseExperience = 0;
    	int swordLevel = 1, combatTraining = 0;
    	int shieldLevel = 1, defenseTraining = 0;
    	int swordCost = 0, shieldCost = 0;
    	int combatCost = 0, defenseCost = 0;
    	int combatPtsNeeded = 0;
    	int defensePtsNeeded = 0;
    
    	cout << "\t\t\tWelcome to Role-Playing Game!";
    
    	while(true)
    	{
    		cout << "\n\nAttack: " << attack << "\nDefense: " << defense
    			<< "\nGold: " << gold << "\n\n";
    		cout << "\n\nWhat would you like to do?\n\n";
    		cout << "1 - Work\n2 - Shop\n3 - Train\n4 - Quit\n\n";
    
    		cin >> choice;
    
    		switch (choice)
    		{
    		case 1:
    			cout << "\n\nHow long would you like to work? (eight-hour maximum) ";
    			cin >> workHours;
    			pay = workHours * 100;
    
    			if (workHours > 8)
    			{
    				workHours = 8;
    			}
    
    			if (workHours >= 1)
    			{
    				cout << "\n\nYou worked for " << workHours
    					 << " hour(s) and earned " << pay << " gold piece(s)!\n\n";
    
    				gold += pay;
    			}
    			else
    			{
    				cout << "You did not work.\n\n";
    			}
    
    			break;
    			
    		case 2:
    			swordCost = swordLevel * 100;
    			shieldCost = shieldLevel * 100;
    			cout << "Welcome to the Shop!\n";
    			cout << "What would you like to upgrade?\n\n1 - Sword\n2 - Shield\n\n";
    
    			cin >> upgradeChoice;
    
    			if (upgradeChoice == 1 && gold >= swordCost)
    			{
    				swordLevel++;
    				cout << "You paid the blacksmith " << swordCost
    					<< " gold pieces.\nYour sword has been upgraded to level "
    					<< swordLevel << "!\n\n";
    
    				gold -= swordCost;
    			}
    			else if (upgradeChoice == 2 && gold >= shieldCost)
    			{
    				shieldLevel++;
    				cout << "You paid the blacksmith " << shieldCost
    					<< " gold pieces.\nYour shield has been upgraded to level "
    					<< shieldLevel << "!\n\n";
    
    				gold -= shieldCost;
    			}
    			else if (upgradeChoice != 1 && upgradeChoice != 2
    					|| gold < swordCost || gold < shieldCost)
    			{
    				cout << "You have entered an illegal value, or you do not have enough money.\n\n";
    			}
    			
    			break;
    
    		case 3:
    			combatCost = attack * 10;
    			defenseCost = defense * 10;
    			combatTraining = swordLevel * 5;
    			defenseTraining = shieldLevel * 5;
    			cout << "Welcome to the dojo!\nHow would you like to train?\n\n";
    			cout << "1 - Combat\n2 - Defense\n\n";
    
    			cin >> trainingChoice;
    
    			if (trainingChoice == 1 && gold >= combatCost)
    			{
    				combatExperience += combatTraining;
    				combatPtsNeeded = attack * 10 - combatExperience;
    				cout << "You pay your trainer " << combatCost
    					<< " gold pieces and train with him.\nYou have earned "
    					<< combatTraining << " experience points.\n";
    				cout << "You still need " << combatPtsNeeded
    					<< " point(s) in order to level up.\n\n";
    
    				gold -= combatCost;
    
    				if (combatPtsNeeded <= 0)
    				{
    					cout << "Congratulations! You have gained an attack level!";
    					combatExperience = 0;
    					++attack;
    				}
    			}
    			else if (trainingChoice == 2 && gold >= defenseCost)
    			{
    				defenseExperience += defenseTraining;
    				defensePtsNeeded = defense * 10 - defenseExperience;
    				cout << "You pay your trainer " << defenseCost
    					<< " gold pieces and train with him.\nYou have earned "
    					<< defenseTraining << " experience points.\n";
    				cout << "You still need " << defensePtsNeeded
    					<< " point(s) in order to level up.\n\n";
    
    				gold -= defenseCost;
    
    				if (defensePtsNeeded <= 0)
    				{
    					cout << "Congratulations! You have gained a defense level!";
    					defenseExperience = 0;
    					++defense;
    				}
    			}
    			else if (trainingChoice < 1 || trainingChoice > 2
    					|| gold < combatCost || gold < defenseCost)
    			{
    				cout << "You have entered an illegal value, or you do not have enough money.\n\n";
    			}
    
    			break;
    
    		case 4:
    			cout << "\nGoodbye!\n\n";
    			
    			system("pause");
    			return 0;
    
    			break;
    
    		default:
    			cout << "You have entered an illegal value.\n\n";
    
    			system("pause");
    			return 0;
    
    		}
    	}
    }
    Please note that I am planning to add a variable to hold the player's name, and to randomly generate the player's stats.

    I apologize if this isn't in the right section. It seemed like a sensible section to place it in, though.
    Last edited by MartinThatcher; 09-11-2009 at 01:52 AM.

  2. #2
    Registered User
    Join Date
    Aug 2003
    Posts
    1,218
    It looks ok but I would break it down into more functions. Work can be 1 function, shop 1, train 1 and so on. This will make it easier to keep track of and eventually expand it.

  3. #3
    Registered User
    Join Date
    Sep 2009
    Posts
    14
    Thanks for the advice. I'm pretty new to C++, this is the end of my third week with it.

  4. #4
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    You'll find classes enlightening. Really useful for games in the end.
    Of course, take your time.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  5. #5
    Registered User
    Join Date
    Sep 2009
    Posts
    14
    Okay, I'll see what I can do with classes once I learn about them.

    If you're interested, here's the updated code:
    Code:
    //Program: Role-Playing Game
    //Programmer: Jeremy Hansen
    //Programming Date: 9/10/09
    
    #include <iostream>
    #include <string>
    #include <ctime>
    #include <cstdlib>
    
    using namespace std;
    
    int gold = 500, workHours = 0, pay = 0;
    int choice = 0, upgradeChoice = 0, trainingChoice = 0;
    int attack = 10, defense = 10, hitPoints = 0, magic = 0, accuracy = 0;
    int combatExperience = 0, defenseExperience = 0, accuracyExperience = 0, magicExperience = 0;
    int swordLevel = 1, combatTraining = 0;
    int shieldLevel = 1, defenseTraining = 0;
    int bowLevel = 1, staffLevel = 1;
    int accuracyTraining = 0, magicTraining = 0;
    int swordCost = 0, shieldCost = 0, bowCost = 0, staffCost = 0;
    int combatCost = 0, defenseCost = 0, accuracyCost = 0, magicCost = 0;
    int combatPtsNeeded = 0;
    int defensePtsNeeded = 0;
    int accuracyPtsNeeded = 0;
    int magicPtsNeeded = 0;
    int charClass = 0;
    
    char recreate = 'n';
    
    string charName = "";
    
    int charCreation()
    {
    	srand(time(0));
    	while (recreate == 'n')
    	{
    		cout << "\n\nName Thyself: ";
    		cin >> charName;
    
    		cout << "Choose a class: Press '1' for Warrior, '2' for Ranger, or '3' for Mage.\n";
    		cin >> charClass;
    
    		switch (charClass)
    		{
    		case 1:
    			hitPoints = rand() % 50 + 50;
    			attack = rand() % 15 + 5;
    			defense = rand() % 15 + 5;
    			magic = rand() % 5 + 5;
    			accuracy = rand() % 5 + 10;
    
    			cout << "Name: " << charName << endl;
    			cout << "Class: Warrior\n";
    			cout << "HP: " << hitPoints << endl;
    			cout << "ATK: " << attack << endl;
    			cout << "DEF: " << defense << endl;
    			cout << "MGK: " << magic << endl;
    			cout << "ACC: " << accuracy << endl;
    			cout << "\nIs this information correct? (y/n) ";
    
    			cin >> recreate;
    
    			if (recreate != 'n' && recreate != 'y')
    			{
    				cout << "\nYou have entered an invalid character.";
    				recreate = 'n';
    			}
    
    			break;
    			
    		case 2:
    			hitPoints = rand() % 50 + 50;
    			attack = rand() % 15 + 5;
    			defense = rand() % 15 + 5;
    			magic = rand() % 5 + 5;
    			accuracy = rand() % 20 + 20;
    			cout << "Name: " << charName << endl;
    			cout << "Class: Ranger\n";
    			cout << "HP: " << hitPoints << endl;
    			cout << "ATK: " << attack << endl;
    			cout << "DEF: " << defense << endl;
    			cout << "MGK: " << magic << endl;
    			cout << "ACC: " << accuracy << endl;
    			cout << "\nIs this information correct? (y/n) ";
    
    			cin >> recreate;
    
    			if (recreate != 'n' && recreate != 'y')
    			{
    				cout << "\nYou have entered an invalid character.";
    				recreate = 'n';
    			}
    
    			break;
    
    		case 3:
    			hitPoints = rand() % 20 + 30;
    			attack = rand() % 5 + 5;
    			defense = rand() % 5 + 5;
    			magic = rand() % 50 + 50;
    			accuracy = rand() % 20 + 20;
    			cout << "Name: " << charName << endl;
    			cout << "Class: Mage\n";
    			cout << "HP: " << hitPoints << endl;
    			cout << "ATK: " << attack << endl;
    			cout << "DEF: " << defense << endl;
    			cout << "MGK: " << magic << endl;
    			cout << "ACC: " << accuracy << endl;
    			cout << "\nIs this information correct? (y/n) ";
    
    			cin >> recreate;
    
    			if (recreate != 'n' && recreate != 'y')
    			{
    				cout << "\nYou have entered an invalid character.";
    				recreate = 'n';
    			}
    
    			break;
    
    		default:
    			cout << "You have entered an invalid number.\n\n";
    			system("pause");
    			return 0;
    	}
    
    
    	}
    }
    
    void work()
    {
    	cout << "\n\nHow long would you like to work? (eight-hour maximum) ";
    	cin >> workHours;
    	pay = workHours * 100;
    
    	if (workHours > 8)
    	{
    		workHours = 8;
    	}
    
    	if (workHours >= 1)
    	{
    		cout << "\n\nYou worked for " << workHours
    			 << " hour(s) and earned " << pay << " gold piece(s)!\n\n";
    
    		gold += pay;
    	}
    	else
    	{
    		cout << "You did not work.\n\n";
    	}
    }
    
    void shop()
    {
    	swordCost = swordLevel * 100;
    	shieldCost = shieldLevel * 100;
    	bowCost = bowLevel * 100;
    	staffCost = staffLevel * 1000;
    	cout << "\nWelcome to the Shop!\n";
    	cout << "What would you like to upgrade?\n\n1 - Sword\n2 - Shield\n3 - Bow\n4 - Staff\n\n";
    
    	cin >> upgradeChoice;
    
    	if (upgradeChoice == 1 && gold >= swordCost)
    	{
    		swordLevel++;
    		cout << "You paid the blacksmith " << swordCost
    			<< " gold pieces.\nYour sword has been upgraded to level "
    			<< swordLevel << "!\n\n";
    
    		gold -= swordCost;
    	}
    	else if (upgradeChoice == 2 && gold >= shieldCost)
    	{
    		shieldLevel++;
    		cout << "You paid the blacksmith " << shieldCost
    			<< " gold pieces.\nYour shield has been upgraded to level "
    			<< shieldLevel << "!\n\n";
    
    		gold -= shieldCost;
    	}
    	else if (upgradeChoice == 3 && gold >= bowCost)
    	{
    		bowLevel++;
    		cout << "You paid the blacksmith " << bowCost
    			<< " gold pieces.\nYour bow has been upgraded to level "
    			<< bowLevel << "!\n\n";
    
    		gold -= bowCost;
    	}
    	else if (upgradeChoice == 4 && gold >= staffCost)
    	{
    		staffLevel++;
    		cout << "You paid the blacksmith " << staffCost
    			<< " gold pieces.\nYour staff has been upgraded to level "
    			<< staffLevel << "!\n\n";
    
    		gold -= staffCost;
    	}
    	else if (upgradeChoice < 1 || upgradeChoice > 4
    			|| gold < swordCost || gold < shieldCost
    			|| gold < bowCost || gold < staffCost)
    	{
    		cout << "You have entered an illegal value, or you do not have enough money.\n\n";
    	}
    }
    
    void train()
    {
    	combatCost = attack * 10;
    	defenseCost = defense * 10;
    	accuracyCost = accuracy * 10;
    	magicCost = magic * 10;
    	combatTraining = swordLevel * 5;
    	defenseTraining = shieldLevel * 5;
    	accuracyTraining = bowLevel * 5;
    	magicTraining = staffLevel * 5;
    	cout << "\nWelcome to the dojo!\nHow would you like to train?\n\n";
    	cout << "1 - Combat\n2 - Defense\n3 - Accuracy\n4 - Magic\n\n";
    
    	cin >> trainingChoice;
    
    	if (trainingChoice == 1 && gold >= combatCost)
    	{
    		combatExperience += combatTraining;
    		combatPtsNeeded = attack * 10 - combatExperience;
    		cout << "You pay your trainer " << combatCost
    			<< " gold pieces and train with him.\nYou have earned "
    			<< combatTraining << " experience points.\n";
    		cout << "You still need " << combatPtsNeeded
    			<< " point(s) in order to level up.\n\n";
    
    		gold -= combatCost;
    
    		if (combatPtsNeeded <= 0)
    		{
    			cout << "Congratulations! You have gained an attack level!";
    			combatExperience = 0;
    			++attack;
    		}
    	}
    	else if (trainingChoice == 2 && gold >= defenseCost)
    	{
    		defenseExperience += defenseTraining;
    		defensePtsNeeded = defense * 10 - defenseExperience;
    		cout << "You pay your trainer " << defenseCost
    			<< " gold pieces and train with him.\nYou have earned "
    			<< defenseTraining << " experience points.\n";
    		cout << "You still need " << defensePtsNeeded
    			<< " point(s) in order to level up.\n\n";
    
    		gold -= defenseCost;
    
    		if (defensePtsNeeded <= 0)
    		{
    			cout << "Congratulations! You have gained a defense level!";
    			defenseExperience = 0;
    			++defense;
    		}
    	}
    	else if (trainingChoice == 3 && gold >= accuracyCost)
    	{
    		accuracyExperience += accuracyTraining;
    		accuracyPtsNeeded = accuracy * 10 - accuracyExperience;
    		cout << "You pay your trainer " << accuracyCost
    			<< " gold pieces and train with him.\nYou have earned "
    			<< accuracyTraining << " experience points.\n";
    		cout << "You still need " << accuracyPtsNeeded
    			<< " point(s) in order to level up.\n\n";
    
    		gold -= accuracyCost;
    
    		if (accuracyPtsNeeded <= 0)
    		{
    			cout << "Congratulations! You have gained an accuracy level!";
    			accuracyExperience = 0;
    			++accuracy;
    		}
    	}
    	else if (trainingChoice == 4 && gold >= magicCost)
    	{
    		magicExperience += magicTraining;
    		magicPtsNeeded = magic * 10 - magicExperience;
    		cout << "You pay your trainer " << magicCost
    			<< " gold pieces and train with him.\nYou have earned "
    			<< magicTraining << " experience points.\n";
    		cout << "You still need " << magicPtsNeeded
    			<< " point(s) in order to level up.\n\n";
    
    		gold -= magicCost;
    
    		if (magicPtsNeeded <= 0)
    		{
    			cout << "Congratulations! You have gained a magic level!";
    			magicExperience = 0;
    			++magic;
    		}
    	}
    	else if (trainingChoice < 1 || trainingChoice > 4
    			|| gold < combatCost || gold < defenseCost
    			|| gold < accuracyCost || gold < magicCost)
    	{
    		cout << "You have entered an illegal value, or you do not have enough money.\n\n";
    	}
    }
    
    int main()
    {
    	cout << "\t\t\tWelcome to Role-Playing Game!";
    
    	charCreation();
    
    	while(true)
    	{
    		cout << "\n\nHitpoints: " <<"\nAttack: " << attack << "\nDefense: "
    			<< defense << "\nAccuracy: " << accuracy << "\nMagic: " << magic
    			<< "\nGold: " << gold << "\n\n";
    		cout << "\n\nWhat would you like to do?\n\n";
    		cout << "1 - Work\n2 - Shop\n3 - Train\n4 - Quit\n\n";
    
    		cin >> choice;
    
    		switch (choice)
    		{
    		case 1:
    			work();
    
    			break;
    			
    		case 2:
    			shop();
    			
    			break;
    
    		case 3:
    			train();
    
    			break;
    
    		case 4:
    			cout << "\nGoodbye!\n\n";
    			
    			system("pause");
    			return 0;
    
    			break;
    
    		default:
    			cout << "You have entered an illegal value.\n\n";
    
    			system("pause");
    			return 0;
    
    		}
    	}
    }

  6. #6
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Global variables are often considered bad practice. Consider passing them as arguments instead. Possibly by reference.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  7. #7
    Registered User
    Join Date
    Sep 2009
    Posts
    14
    What you just posted made no sense to me, but I'm sure it will make sense soon enough.

  8. #8
    spurious conceit MK27's Avatar
    Join Date
    Jul 2008
    Location
    segmentation fault
    Posts
    8,300
    Quote Originally Posted by MartinThatcher View Post
    What you just posted made no sense to me, but I'm sure it will make sense soon enough.
    I think what she means is that global variables are okay for beginners, but once you get comfortable with prototyping and using functions, you will start to find them silly, irritating and/or awkward as well.

    Speaking of prototyping, it is a good idea to include them at the top, so that you do not have fuss about what order the functions appear in. This also may make it easier to perceive ways in which a global may be converted into a parameter, since they will all be listed together.
    C programming resources:
    GNU C Function and Macro Index -- glibc reference manual
    The C Book -- nice online learner guide
    Current ISO draft standard
    CCAN -- new CPAN like open source library repository
    3 (different) GNU debugger tutorials: #1 -- #2 -- #3
    cpwiki -- our wiki on sourceforge

  9. #9
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Instead of:
    Code:
    int myvar;
    int main() { ... }
    void myfunc() { ... }
    Consider:
    Code:
    int main()
    {
        int myvar;
        myfunc(myvar);
        ...
    }
    
    void myfunc(int myvar)
    {
        ...
    }
    And references:
    Code:
    // As above
    void myfunc(int& myvar)
    {
        ...
    }
    Passing by reference will allow myfunc to modify the variable and the changes to the variable will also be seen in main (the first example will not allow you to do that).
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  10. #10
    Registered User
    Join Date
    Sep 2009
    Posts
    14
    Okay, I get what you're saying now, but I have a question. Do I need to put "int&" before every integer I pass to the function?

  11. #11
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    The & indicates a reference. Put it after the type of each parameter in the function header where you want want to pass a reference.
    You pass an argument just as before. Look at the example to see what I mean.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  12. #12
    Registered User
    Join Date
    Sep 2009
    Posts
    14
    Right, I get that.

    What I'm asking is:
    Code:
    //Do I need all of these "int&"s?
    void shop(int& swordCost, int& swordLevel, int& shieldCost, int& shieldLevel,
    	  int& bowCost, int& bowLevel, int& staffCost, int& staffLevel,
    	  int& upgradeChoice, int& gold)

  13. #13
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    For all variables you want to pass by reference, yes.
    If you do NOT need to pass them by reference, then you don't need the &.

    Ask yourself this: should this function be able to modify the original variables or is it enough that it can just read the information? If it's the former, then yes, you need the & to create a reference.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  14. #14
    Registered User
    Join Date
    Sep 2009
    Posts
    14
    Okay, thank you.

  15. #15
    Registered User VirtualAce's Avatar
    Join Date
    Aug 2001
    Posts
    9,607
    Your shop() function could just as well take a structure and you could pass it by reference which would simplify the code a bit and would rid you of the 15 parameters you have to pass. Also just because you can modify a variable passed on the stack does not mean you have to do it this way. If you find you are altering a lot of parameters that are passed to the function you may want to revisit the design.

    Shop() only needs the parameters passed by reference if it intends on modifying the parameters. In fact when I see a pass by reference without a const it tells me that the function DOES modify the parameter.

    Example:
    Code:
    void MatrixMultiply(Matrix &result,const Matrix &matrix1,const Matrix &matrix2)
    {
    }
    This function very clearly tells the programmer that it will concatenate matrix1 and matrix2 and result will be the result of the concatenation. Matrix1 and Matrix2 are passed by reference to avoid a copy constructor call which would happen if they were passed by value. The const indicates that the function will not modify matrix1 nor matrix2. The lack of const for result clearly indicates to the programmer that result will be modified by the function. What the function prototype does not indicate is the order of operations. Since Matrix1 * Matrix2 != Matrix2 * Matrix1 this function would need a comment specifying the order in which the matrices are concatenated. One could say that since they are labeled as 1 and 2 it would indicate Matrix1 * Matrix2 but there is nothing in the prototype that would beyond a shadow of a doubt indicate the order of concatenation.

    Note that this function is a bit unwieldy since it cannot be used as an rvalue which would be quite handy.
    Last edited by VirtualAce; 09-11-2009 at 05:00 PM.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. A bunch of Linker Errors...
    By Junior89 in forum Windows Programming
    Replies: 4
    Last Post: 01-06-2006, 02:59 PM
  2. text rpg help
    By xxwerdxx in forum Game Programming
    Replies: 1
    Last Post: 11-26-2005, 08:16 PM
  3. Check out My Text Rpg Game
    By knight543 in forum C++ Programming
    Replies: 3
    Last Post: 05-17-2002, 10:40 PM
  4. Text based GUI?
    By jon_nc17 in forum C++ Programming
    Replies: 1
    Last Post: 05-16-2002, 11:45 AM
  5. Text Based Game
    By drdroid in forum C++ Programming
    Replies: 2
    Last Post: 02-18-2002, 06:21 PM