Database Q
Displaying 1-10 of 10 total.
1
omegama99
|
Does anyone know a good site where i can learn to make a Database and then how to make the scripts that can get the data from that database.
Posted on 2001-07-16 16:17:17
|
TheGerf
|
http://www.vergearchive.freeurl.com/Mike
This place has lots of scripts, you'll just have to take a look through them all.
TheGerf, not just any gerf.
Posted on 2001-07-16 16:39:14
|
TheDeveloper
|
Do you mean for verge? Or for something like the web?
-The Developer Insert witty signature here
Posted on 2001-07-17 00:18:58
|
Kut
|
I'm sure that if you nicely ask google.com;
it would shoots you lots of answers. ;)
make database + tutorial
Failure is not an option,
Windows is built with it!
Posted on 2001-07-17 12:32:37
|
omegama99
|
ive looked up most of them, but i dont really understand how you get each line using fgettoken.
Also, i created a pointer in *.pcx format. When i go to put it on the screen with Tcopysprite, all the colors become black. Any idea why or what to do?
Posted on 2001-07-17 13:34:28
|
TheGerf
|
If you use FSeekLine() you can pick a line to read/write from.
Is your pcx in the right palette? And do you use colours 0 or 256 at all? I think 256 does some gay stuff, and 0 should be transparent. I dunno, I'm tired...
TheGerf, not just any gerf.
Posted on 2001-07-17 17:10:12
|
TheDeveloper
|
ive looked up most of them, but i dont really understand how you get each line using fgettoken.
Ok first set the line you want to start reading from with fseekline (in most versions it ignores the very first line). Then you can use a loop that reads each token (and those are seperated by spacec btw) and does stuff to it. Fgettoken will automaticly linewrap for you if you want. Or if you prefer, you can set a limited number of tokens per line and then fseekline to the next one when you hit the end of the line. something like this;
string token;
void ReadAFile(string filenamehere) {
int file;
file=fopen(filenamehere);
fseekline(1,file);
while(some_condition_here) {
gettoken(token,file);
do_stuff_with_the_token_here();
}
be_sure_to_free_the_file_when_you_are_done();
}
A couple of notes, v2 chokes on strings if you declare them locally so make them all global (it's faster anyway I hear), and make sure you free your file (or a have a way to bail out that does such as alt-x) or you'll get some nasty memory leaks going on. And if you need a real world example of this I'll be happy to post one for you.
-The Developer Insert witty signature here
Posted on 2001-07-17 20:58:56
|
omegama99
|
well im not too sure about the stupid pallet thing. But just wondering, is there a limit to the number of global strings and ints you can declare. Also is there a limit on arrays.
Ive been getting unknown token errors from the compiler. Usually when i get this its cause i put stuff in a bad order, or forgot to put a semicolon;
This time, it seems that even when i get rid of the lines, it still gives me the errors. any ideas?
The darkness awaits, do not try and escape your destiny.
Posted on 2001-07-18 00:10:19
|
TheGerf
|
There is a limit, it's rather large so you shouldn't run in to it. What line gives you the Unknown token?
TheGerf, not just any gerf.
Posted on 2001-07-18 20:45:07
|
omegama99
|
I feel like a complete idiot (dont comment on that).
What happened is in my system.vc i included all my functions in other *.vc files like this.
#include "keys.vc"
#include "save.vc"
#include "itemdat.vc"
#include "weapons.vc"
etc.
what happened is the last line of my itemdat.vc i forgot a semi-colon. Everything after that fuc*ed up.(please excuse my language). Since it was the last line of itemdat.vc that didnt have the semicolon, it said that the int w_name[MAXWEAPON]; was an unknown token. This had me looking in the wrong place. But i fixed it now. It kinda ticks me off to see that i ended up wasting over 7 hours on a semi-colon.
The darkness awaits, do not try and escape your destiny.
Posted on 2001-07-18 23:00:45
|