delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/03/27/22:00:36

From: dmt AT bigfoot DOT com (Jeff W./DMT)
Newsgroups: comp.os.msdos.djgpp
Subject: Why does this crash?????
Date: Sat, 28 Mar 1998 02:00:02 GMT
Organization: ZipLink -- America's Hottest ISP
Lines: 51
Message-ID: <351c58e7.313662@news.ziplink.net>
NNTP-Posting-Host: chi-ip-1-97.ziplink.net
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

I have the following class declared:

class WorldClass
{
 TileType Tile[WORLD_HEIGHT+1][WORLD_WIDTH+1];
 ObjType  Obj[WORLD_HEIGHT+1][WORLD_WIDTH+1];

 public:
  int  Load(void); //reads in all map data
  void Blit(BITMAP *buffer, DATAFILE *data); //blits world map to
buffer

};

and hye following types:

typedef struct TileType
{
 int flag;
 int tileno;
};

typedef struct ObjType
{
 int flag;
 int tileno;
 int active;
};

WORLD_HEIGHT is set at 14, WORLD_WIDTH is set at 19.

I have declared a variable, "World" of type WorldClass.  No matter
where I put the following line of code:

World.Load();

my program crashes on me.  I tried setting a breakpoint there, and as
soon as I hit F7 to trace into it, it crashes for no apparent reason.
I'm not passing any variables, just calling a function.  Can anyone
help me with this??  Thanks a bunch.
 --Jeff W.

 "The finding of DMT in normal human body fluids
 opens up interesting moral and legal questions.
 Since DMT is illegal, as is 'any substance, compound
 or mixture' containing DMT, it would seem that we
 are all guilty of possesion of a controlled substance"
 -Jonathon Ott

 My weird, trippy page:
 http://www.geocities.com/SunsetStrip/Alley/3450/index.html

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019