realbasic-games
[Top] [All Lists]

Re: Joe Strout's 3D Chess Demo: Two Questions

To: REALbasic Games <realbasic-games at lists dot realsoftware dot com>
Subject: Re: Joe Strout's 3D Chess Demo: Two Questions
From: Phil Mobley <phil at mobleybros dot com>
Date: Thu, 29 Jul 2004 08:21:40 -0700
Delivered-to: realbasic-games at lists dot realsoftware dot com
References: <006d01c4757d$e2136460$6501a8c0 at travergateway>
On Jul 29, 2004, at 8:08 AM, B Traver wrote:

My concern is more with the re-initialization process. I know how to re-initialize _my_ variables, etc., _but_ I don't know exactly what is involved in re-initializing the 3D graphics (as I've admitted elsewhere, just because I put Joe Strout's code to good use doesn't mean I understand any of it!). That's why I was so interested in seeing whether there was a way, say, to get the program to do the equivalent of running again from scratch.

The method that I use in my game is that my GameModel which controls where all of the game pieces are located is a Class. When I start a new game, I destroy the old game instance and create a new one.

This game instance stores the positions of all of the pieces and all of the game logic. Then there is a separate class to get the current positions of objects and draw them on the screen.

Just thinking out loud.... Perhaps one possibility (albeit a klutzy one) would be to use a "shell" sort of approach, where the original program would load in another instance of itself and then the original program would shut itself down.

I don't think this is a good idea... it wouldn't be what the user expects. Would you expect a major software program to shutdown and restart when you just wanted to create a new document?

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://www.realsoftware.com/listarchives/lists.html>

<Prev in Thread] Current Thread [Next in Thread>