[DGD] File access question

Kurt Nordstrom kurt at blar.net
Fri Jul 13 23:27:40 CEST 2007


I've got a situation that I'm trying to figure out the best way to
approach.  I was wondering if maybe any of you could give your thoughts on
how you might tackle it.

I'm wanting to code a simulated card game, with maybe 1000 unique cards
(they'll have various words on them), but only 200 of which will be used
in a given game.  So, essentially it will need to read a file of 1000
entries, pick out 200 by random (which it will store in memory), and then
close the file.

Is the loading of the entries something that I'd have to do with scheduled
call outs to avoid a tick overflow?  And is there any clever way to pick
200 random lines out of a variable length file?

Any input is appreciated.  Let me know if I'm not clear on what it is that
I want to do.

Thanks,

-Kurt



More information about the DGD mailing list