Page 1 of 1

hmm.. double registering..

Posted: Sun Oct 31, 2010 5:27 pm
by tomtefan
Is it possible for me to do that ?

Iam more or less just missing pvp area in my game.

Now i have an idea wich gives me more control over fights, so i can balance them easier.
And since iam not that high on php, this idea makes it easier for me to overview things.

When a player register, it ends up in DB under: Players
Can i make it a double entry in the DB from one registering. ?

I want to have the player stats under Playermonster also.

And aswell when someone buys a weapon / armor or what ever, it make a double entry under similar tags
Playermonsterweapon, Playermonsterarmor, etc.


I tried this.

This is the Main line. from reguser.php (its working).
$SQL = "INSERT into players(name, password, email, blablablabla...

I tried to make it a double by just putting this under the line above.. (didnt work) =P
$SQL = "INSERT into playermonster(name, password, email, blablablabla...

i also tried:
$SQL = "INSERT into players AND playermonster (blablablabla... didnt work either hehehe


Its probably something easy, but i dont see it :lol:

Re: hmm.. double registering..

Posted: Sun Oct 31, 2010 6:33 pm
by Torniquet
all depends on how your playermonsters table is layed out.

if it is a copy of your players table.. then you should be able to insert as normal.

if not, then modify the insert query to match that of the playermonster table.

Re: hmm.. double registering..

Posted: Sun Oct 31, 2010 7:45 pm
by tomtefan
hmm, maybe i missed something there.. have to take a look at that again.

ty for info :D


EDIT:

YEY, its working.