in reply to RPG Engine Location Tracking (Large Three Dimentional Array?)

Thanks for the ideas everyone, unfortunately many of them rely on having it indoors... much of the world I'm attempting to design is actually outdoors... So I need to be able to keep track of where everything is in relation to anythign else quickly, for example, a 10x10x10 'Viewing Window' in which the player can see everything...

I've had an idea though, I cannot say how well it will work. I'm considering using a flat-file database to store object id's (theres an item array already in use) and look up all the item id's in the given area.

I'm currently looking at DBI-Sprite, however I don't know if it's the best idea as I don't know how it works...

Anyone know if using DBI-Sprite is a good idea? Or with my expanded explanation can anything else be thought of?

(I realize that this is rather poorly worded, I just came back from school and I'm kinda tired at the moment...)


"Weird things happen, get used to it"

Flame ~ Lead Programmer: GMS
http://gms.uoe.org

Replies are listed 'Best First'.
*EDIT* Re: Well... (Database?)
by Flame (Deacon) on Oct 26, 2001 at 00:29 UTC
    Edit: Added Error and the code

    Well, after a bit of experementation, I don't think Sprite is going to help... (I can't even get it to set up a table...)

    Anyone know what this is suppost to mean?
    perl worldbuild.pl
    
    Oops! Sprite encountered the following error when processing your request:
    
        Cannot write the database to output file. (\\world.stb)
    
    Here's some more information to help you:
    
            file:
        No such file or directory
    
    DBD::Sprite::db do failed: -511:Cannot write the database to output file.(\\worl
    d.stb) at worldbuild.pl line 8.
    
    


    This is the code:
    use strict; use DBI; my $DBI; $ENV{SPRITE_HOME} = "E:\\PRPG\\World\\"; $DBI = DBI->connect('DBI:Sprite:WORLD') || die "Could not connect (".$ +DBI->err.':'.$DBI->errstr.")!"; $DBI->do("CREATE TABLE WORLD (UID INT, X INT, Y INT, Z INT, IID INT)") +;



    "Weird things happen, get used to it"

    Flame ~ Lead Programmer: GMS
    http://gms.uoe.org