I’m writing a simple text adventure game. I have a master database that I populate by running an SQL script with the ‘ij’ tool. This is fine for creating the master database for my application. My intent, when the user creates a new game, is to create a duplicate database in a unique directory for that game, and then populate the DB to match the master schema. So each game will have its own database based on the master db. I’m not sure the best way to do this. Is this a valid approach? I tried creating a windows script that java could reference to run my SQL script to populate a new database, but the windows script can’t execute any commands after the “ij” tool starts. Alternatively, I could just create the entire DB schema using SQL statements within a java object, but that seems really obtuse. Any ideas? How do they handle this in other games?
*** To avoid confusion: I know how to “create” a new database with Java, just not how to populate it without using SQL statements.
Thanks,
8ballj