Register for your free account! | Forgot your password?

Go Back   elitepvpers > MMORPGs > Dekaron > Dekaron Private Server
You last visited: Today at 08:49

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



help me for SQL pros

Discussion on help me for SQL pros within the Dekaron Private Server forum part of the Dekaron category.

Reply
 
Old   #1
 
[DEV]Pwner's Avatar
 
elite*gold: 0
Join Date: Sep 2010
Posts: 147
Received Thanks: 35
help me for SQL pros

hello ,
i want to start a new job on my pserver ,
here it goes , i have a remote reborn system , and u reborn ur char on
my ( own website )
everything works good , but my last problem is that
i want to give a skill book for a character who made 1st reborn ,

so the SQL code must be like that : ( i have reborn table on user_character )

Quote:
go to user_character search for reborn table
if reborn table is 1 send item index xxxxx in mailbox
for this character .
xxxxx= item index
i have 3 skill books i want them on the first 3 reborns ,
so 1 skill each 1 reborn

hope u understood what i mean .
[DEV]Pwner is offline  
Old 10/07/2010, 12:07   #2
 
҉ THT ҉'s Avatar
 
elite*gold: 0
Join Date: Jul 2009
Posts: 912
Received Thanks: 250
uh that is kinda hard,
is the user_bag clean?
if, yes it would be easier to detect who did a reborn

PHP Code:
UPDATE                                        character.dbo.user_bag
SET                                            windex
='SKILL BOOK ID'            
WHERE character_no IN(
SELECT DISTINCT character_no FROM character.dbo.user_character 
                                            WHERE reborn_table 
'1'

OR                                            WHERE reborn_table '2'
OR                                            WHERE reborn_table '3'
OR                                            WHERE reborn_table '4'

SET ROWCOUNT 1
Note: This is with out internet, maybe there are some errors (I am at work cant help to much )
AND this will keep giving the skill book if someone keep relogging.
Cuz I cant check the whole script you use
҉ THT ҉ is offline  
Old 10/08/2010, 00:21   #3
 
-8gX's Avatar
 
elite*gold: 0
Join Date: Jan 2009
Posts: 614
Received Thanks: 151
Code:
<?php
$character_no = Use PHP to get the character number from the input form

$get_reborn = mssql_query(SELECT reborn_no FROM character.dbo.user_character WHERE character_no = $character_no)

if ($get_reborn = '1') {
     $sql = mssql_query(UPDATE character.dbo.userbag SET windex='SKILLBOOKID' where character_no = $character_no)
}
else if ($get_reborn = '2') {
 $sql = mssql_query(UPDATE character.dbo.userbag SET windex='SKILLBOOKID' where character_no = $character_no)
}
else if ($get_reborn = '3') {
 $sql = mssql_query(UPDATE character.dbo.userbag SET windex='SKILLBOOKID' where character_no = $character_no)
}
or die(mssql_error());
?>
Or you could do a switch statement for whatever $reborn_no is. You would put this in your PHP script on your website right when your system is calculating the reborn. This way unlike THT's script relogging doesnt give you another skill book.
-8gX is offline  
Old 10/08/2010, 13:00   #4
 
pieter's Avatar
 
elite*gold: 0
Join Date: Jan 2008
Posts: 568
Received Thanks: 176
lol dont add items in inventory

use the mailbox function : SP_CHAR_SEND_MAIL (or something like that)

i wrote a tut on it on dkunderground but dku is no more, and i dont have any backups
if i happen to find it somewhere ill add it to my guide-thread (sig)
pieter is offline  
Old 10/08/2010, 16:20   #5
 
[DEV]Pwner's Avatar
 
elite*gold: 0
Join Date: Sep 2010
Posts: 147
Received Thanks: 35
Quote:
Originally Posted by pieter View Post
lol dont add items in inventory

use the mailbox function : SP_CHAR_SEND_MAIL (or something like that)

i wrote a tut on it on dkunderground but dku is no more, and i dont have any backups
if i happen to find it somewhere ill add it to my guide-thread (sig)
yes that would be good , to send on mailbox
for who got 1st reborn , 2nd reborn , 3rd reborn

i will try out -8gX's script and add to reborn system on my web .

THT ҉' sends alot books xD and i want it on mail box ,

maybe make 1 job with 3 steps and make database to save the characters who got the books
1st check reborn characters + check the database
and 2nd sends book index for reborn 1 who doesnt have this books
and 3rd one save the characters who sent to at step 2nd
and reply to 1st step , so it wont send more books .. hope that idea works
[DEV]Pwner is offline  
Old 10/08/2010, 23:00   #6
 
-8gX's Avatar
 
elite*gold: 0
Join Date: Jan 2009
Posts: 614
Received Thanks: 151
yeah mailbox would work... u just cant call stored procedures from php can u?
-8gX is offline  
Old 10/09/2010, 09:01   #7
 
pieter's Avatar
 
elite*gold: 0
Join Date: Jan 2008
Posts: 568
Received Thanks: 176
yes you can, on my server ppl can mailbox themself items from the website

mssql_query "USE CHARACTER; EXEC SP_Custom_Itemsend @charnum @itemnum"

i made a custom SP that logs all items being sent and check for itemid's that aren't in the 'allow list'
if a disalowed item gets sent it reports it to GM panel and ban+ipban's the account
pieter is offline  
Old 10/09/2010, 09:37   #8
 
Zombe's Avatar
 
elite*gold: 20
Join Date: Dec 2007
Posts: 1,450
Received Thanks: 833
Don't look for people who have reborned separately, instead give them the item when they reborn. Modify your reborn script/stored procedure/job/whatever you use
Zombe is offline  
Reply


Similar Threads Similar Threads
Nur Für Pros :)
01/05/2010 - Metin2 Private Server - 13 Replies
Hallo Com, Wollte bei meinem freund seinen root server eine dt ebene hinzufügen weis aber nicht wie das funkz wen es jmd weis pls ne pn :) Es Gibt Ein Fettes Thx :) Edit: Am Besten 2 Ebenen :)
Help mi pros!
06/27/2009 - Conquer Online 2 - 1 Replies
I need the hex id of some fire tao skills like FireOfHell and scent sword fast blade. Theres one format like Tornado=3EA, some thing like this. Wud be grateful if any one help me.
could the PROs help me with this!
03/02/2009 - Lineage 2 - 6 Replies
Am running OOGW version 10.9.3 this is what i put for my Set.ini: CountryList=L2blaze; DefaultCountry=0 DefaultServer=0 DefaultCharacter=0 DefaultAccount=ken DefaultPassWord=
pros in only
06/19/2008 - Silkroad Online - 9 Replies
lol cuz i m a noob to this game. yesterday i killed 2 botters and got some pk points and 3 pk lvls. then i realise its a big mistake. cuz i m a free to be killed to others and i lost exp.when i stayed in town my hp auto drop. so i decided to logoff. today when i login again i was happy no pk points for me but then i found out my pk lvl still 3 and red name. plz some1 help me how can i turn to white name and no pk lvls again? thanks, if i cant get white name back, i would just quit cuz i...
Hey, a bit of help with SV from the pros?
02/21/2007 - Conquer Online 2 - 2 Replies
I'm having a problem with what i believe is the most current version of SV I can start it up fine and it has been working fine for several days now but i just went on today 2/21 and it has stopped working correctly. It might just be something minnor but i can start it up everything work and goes running hitting and attacking like normal for about a minute, then my whole conquer window shuts down. The SV stays open but the conquer shuts down ive tryed logging on several...



All times are GMT +2. The time now is 08:49.


Powered by vBulletin®
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2024 elitepvpers All Rights Reserved.