public class MedievalTextAdventure
{
public static void main (String args[])
{
System.out.println("loading...");
boolean NOTE = false, HOUSE = false, TREASURE = false,
HAMMER = false, FROGS = false, FISH = false,
FISHINGROD = false, GOLD = false, DOCTOR = false,
OLDKEY = false, BUTTERFLYNET = false, HOUSE1 = false,
HOUSE2 = false, HOUSE3 = false, HOUSE4 = false,
HOUSE5 = false, ABANDONEDHOUSE = false, LAKE1 = false,
LAKE2 = false, LAKE3 = false, LAKE4 = false,
LAKE5 = false, LAKE6 = false, DOCTORSHOUSE = false,
FISHMONGERY = false, gamerunning = true, alive = true,
LICORICE = true, JEWEL = true, SHIELD = true, WRENCH = true;
int points = 0;
int vertical = 4;
int horizontal = 9;
String sNOTE = new String("NOTE");
String sHOUSE = new String("HOUSE");
String sTREASURE = new String("TREASURE");
String sHAMMER = new String("HAMMER");
String sFROGS = new String("FROGS");
String sFISH = new String("FISH");
String sFISHINGROD = new String("FISHINGROD");
String sGOLD = new String("GOLD");
String sDOCTOR = new String("DOCTOR");
String sOLDKEY = new String("OLDKEY");
String sBUTTERFLYNET = new String("BUTTERFLYNET");
String sABANDONEDHOUSE = new String("ABANDONEDHOUSE");
String sLAKE = new String("LAKE");
String sFISHMONGERY = new String("FISHMONGERY");
String sOLDWOMAN = new String("OLDWOMAN");
String sWOMAN = new String("WOMAN");
String sMOTHER = new String("MOTHER");
String sGUARD = new String("GUARD");
String sFIELD = new String("FIELD");
String sPEASANT = new String("PEASANT");
String sGRASS = new String("GRASS");
String sHUNGRYPEASANT = new String("HUNGRYPEASANT");
String sPOORPEASANT = new String("POORPEASANT");
String sLICORICE = new String("LICORICE");
String sJEWEL = new String("JEWEL");
String sWRENCH = new String("VASE");
String sSHIELD = new String("SHIELD");
String sPOND = new String("POND");
String sDIRT = new String("DIRT");
String sWEST = new String("WEST");
String sNORTH = new String("NORTH");
String sEAST = new String("EAST");
String sSOUTH = new String("SOUTH");
String sUSE = new String("USE");
String sTALK = new String("TALK");
String sGIVE = new String("GIVE");
String sGO = new String("GO");
String sJUMP = new String("JUMP");
String sSEARCH = new String("SEARCH");
String sUNLOCK = new String("UNLOCK");
String sENTER = new String("ENTER");
for ( ; gamerunning == true ; )
{
for ( boolean loopcontrol = true ; loopcontrol == true ; loopcontrol = false )
{
if ( vertical == 1)
{
if ( horizontal == 1)
{
}
else if ( horizontal == 2)
{
}
else if ( horizontal == 3 )
{
}
else if ( horizontal == 4 )
{
}
else if ( horizontal == 5 )
{
}
else if ( horizontal == 6 )
{
}
else if ( horizontal == 7 )
{
}
else if ( horizontal == 8 )
{
}
else if ( horizontal == 9 )
{
}
else if ( horizontal == 10 )
{
}
}
else if ( vertical == 2)
{
if ( horizontal == 1)
{
}
else if ( horizontal == 2 )
{
}
else if ( horizontal == 3 )
{
}
else if ( horizontal == 4 )
{
}
else if ( horizontal == 5 )
{
}
else if ( horizontal == 6 )
{
}
else if ( horizontal == 7 )
{
}
else if ( horizontal == 8 )
{
}
else if ( horizontal == 9 )
{
}
else if ( horizontal == 10 )
{
}
}
else if ( vertical == 3)
{
if ( horizontal == 1 )
{
}
else if ( horizontal == 2 )
{
}
else if ( horizontal == 3 )
{
}
else if ( horizontal == 4 )
{
}
else if ( horizontal == 5 )
{
}
else if ( horizontal == 6 )
{
}
else if ( horizontal == 7 )
{
}
else if ( horizontal == 8 )
{
}
else if ( horizontal == 9 )
{
}
else if ( horizontal == 10 )
{
}
}
else if ( vertical == 4)
{
if ( horizontal == 1 )
{
}
else if ( horizontal == 2 )
{
}
else if ( horizontal == 3 )
{
}
else if ( horizontal == 4 )
{
}
else if ( horizontal == 5 )
{
}
else if ( horizontal == 6 )
{
}
else if ( horizontal == 7 )
{
}
else if ( horizontal == 8 )
{
}
else if ( horizontal == 9 )
{
}
else if ( horizontal == 10 )
{
}
}
else if ( vertical == 5)
{
if ( horizontal == 1 )
{
}
else if ( horizontal == 2 )
{
}
else if ( horizontal == 3 )
{
}
else if ( horizontal == 4 )
{
}
else if ( horizontal == 5 )
{
}
else if ( horizontal == 6 )
{
}
else if ( horizontal == 7 )
{
}
else if ( horizontal == 8 )
{
}
else if ( horizontal == 9 )
{
}
else if ( horizontal == 10 )
{
}
}
else if ( vertical == 6)
{
if ( horizontal == 1 )
{
}
else if ( horizontal == 2 )
{
}
else if ( horizontal == 3 )
{
}
else if ( horizontal == 4 )
{
}
else if ( horizontal == 5 )
{
}
else if ( horizontal == 6 )
{
}
else if ( horizontal == 7 )
{
}
else if ( horizontal == 8 )
{
}
else if ( horizontal == 9 )
{
}
else if ( horizontal == 10 )
{
}
}
else if ( vertical == 7)
{
if ( horizontal == 1 )
{
}
else if ( horizontal == 2 )
{
}
else if ( horizontal == 3 )
{
}
else if ( horizontal == 4 )
{
}
else if ( horizontal == 5 )
{
}
else if ( horizontal == 6 )
{
}
else if ( horizontal == 7 )
{
}
else if ( horizontal == 8 )
{
}
else if ( horizontal == 9 )
{
}
else if ( horizontal == 10 )
{
}
}
}
}
}
}
6 Comments On This Entry
Page 1 of 1
modi123_1
06 November 2012 - 08:02 AM
Wow... one word - classes! Object all that up! Also, any screen shots?
fromTheSprawl
07 November 2012 - 02:15 AM
With classes, you can divide up your game to modular parts. You can theoretically do a Character class for starters, then maybe Monsters for the enemies, an Inventory to hold an Item class, the list goes on and on.
fromTheSprawl
07 November 2012 - 05:51 PM
How about each scenarios? Locations, maybe? Don't worry bud, once you realize the beauty of OOP you'll never look back.
Page 1 of 1
Trackbacks for this entry [ Trackback URL ]
Tags
My Blog Links
Recent Entries
Recent Comments
Search My Blog
0 user(s) viewing
0 Guests
0 member(s)
0 anonymous member(s)
0 member(s)
0 anonymous member(s)
Categories
|
|



6 Comments









|