Path: chuka.playstation.co.uk!news From: Philip Gooch Newsgroups: scee.yaroze.beginners,scee.yaroze.programming.codewarrior,scee.yaroze.programming.2d_graphics Subject: Re: Still strugglin' with the basics: broken sprite code (long) Date: Wed, 15 Jul 1998 23:34:58 +0100 Organization: philg@nospam.easynet.co.uk Lines: 33 Message-ID: <35AD2E8E.DEF2C169@nospam.easynet.co.uk> References: <35AC71D4.AA79EB4A@easynet.co.uk> <35AD10B6.153EE9C5@compuserve.com> Reply-To: philg@nospam.easynet.co.uk NNTP-Posting-Host: philg.easynet.co.uk Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii; x-mac-type="54455854"; x-mac-creator="4D4F5353" Content-Transfer-Encoding: 7bit X-Mailer: Mozilla 4.04 (Macintosh; I; PPC) Xref: chuka.playstation.co.uk scee.yaroze.beginners:413 scee.yaroze.programming.codewarrior:301 scee.yaroze.programming.2d_graphics:440 Nick Slaven wrote: > Philip Gooch wrote: > > What happens is that when I run the program I get the Yaroze boot-up > > screen, then the screen flashes briefly before returning to the boot-up > > screen. > > I've had crashes like this when I made the packet area too big, and when > its too small. Try making PACKET GpuPacketArea[2][MAX_SPRITES*24]; > bigger - you are sorting a clear screen command in here as well as the sprite. > Also I noticed that you've got OTTags as local in one > of your functions - try making it global - or static. > > cheers > > Nick (S) YES!! This works. Thanks guys. I wouldn't have sussed this out on my own. I really appreciate you help. Cheers Nick, Herbs and George. Turned out not to be a Codewarrior problem after all! Sorry about the cross-posting. But what confuses me is: Why does OTTags need to be a global if I'm only using it in one function - InitGraphics()? Is GsOT_TAG somehow used by the OS throughout the program and so needs to be aware of it whenever it needs it? Sorry, I'm really dim on the low-level stuff. I'm better at algorithms - honest! Thanks again. Phil