|
You last visited: Today at 04:48
Advertisement
another sql query
Discussion on another sql query within the Dekaron Private Server forum part of the Dekaron category.
08/12/2010, 16:20
|
#1
|
elite*gold: 0
Join Date: Dec 2008
Posts: 15
Received Thanks: 0
|
another sql query
hello guyz ,
well i want a sql query or a way or anything u recommend me ,
to make :
every new character starts or created and started playing my server will have :
Quote:
15 days custume ( the new summer set i have all )
+5 18% Talismans
Magic Health Pack 300 EA
10 Coppers
Health Regenerator
10 Portal Scrolls
|
maybe send on mail ,
or can be on his inventory
if send on mail , have to write mail
Quote:
from [GM]Team
Subject : Begin Event
Body Text : Welcome To My Dekaron , We Give Free Items As Event . Enjoy
|
thank you
|
|
|
08/12/2010, 20:53
|
#2
|
elite*gold: 0
Join Date: Aug 2009
Posts: 127
Received Thanks: 21
|
by zombe
Quote:
Have you ever wanted to give an item(s) to every character as soon as it is created?
Well, I am here to show you how!
First we will open up the MSSQL's Enterprise Manager, and we will take a lot at the user_character table in the character database.
Have you ever noticed the [DEV] characters in there? Well, that is what we are looking for. They all have an user_no of 19999999999991, so you can find them by searching for that user_no in user_character table.
Ok, first lets take a look at their names.
[DEV]KNIGHT, [DEV]HUNTER, [DEV]MAGICIAN , etc. Obviously a char for each class.
Lets take a look at the stats of [DEV]KNIGHT. 6 str, 3 dex, 4 con, 2 spr. Nothing special. Except... Wait, aren't these the stats that all knights have when the chart is created by default? Yes, they are! So what if we would change all those stats to lets say 2000, save and then create a character?
WOW! My newly created character has 2k stats!
Ok, so that is the method how to customize the character, like starting level, starting health, starting shield, etc. You can make it different for each class, if you want.
Ok, but how about items, you ask?
I will do it so that the items would be equipped by default.
So lets go to user_suit, but leave user_character table open.
Lets say we are customizing a knight. Note the character no of [DEV]KNIGHT, that is DEKARON0000001.
Lets find that in the user_suit table. Ok, we found it. 1 entry.
line_no 4, wIndex 2421.
Hmm... Wait, that is a lvl 1 1h-sword! The very same one a newly created character gets, when he makes a new character!
So this is what we do.
We will make ourselves a new character. Then, mail the items you want the newly created character to have to the char you just created, or you can drop them by killing mobs/treasureboxes. Anyway, once you have the items you want, equip them. Make sure you equip ONLY what you want the newly created character to have, so check your mount/wings slot, your potion quickslots, everything.
Once you have it equipped, logout and go to your enterprise manager, user_character, find your character. Get it's character number, I will use A09090520000000003 as an example, because that is my number.
Then, go to user_suit, find the character_no DEKARON0000001 (for knight).
DELETE the 1 row that it has. Then find your character's no (A09090520000000003 as an example). Change the character_no on all lines to DEKARON0000001. Log back into your account again (Yes, all of your items you equipped will be gone), then create a new character.
Wow! He has all the items!
The same can be used for all classes, and it can be used the same way for inventory, skillls, almost everything. Also, you can edit the guild's MASTERCODE to change the default guild created.
|
by pieter
Quote:
No more SQL Manager jobs that keep looping and lag your server!
open sql profiler
go to character > stored procedures
find SP_CHAR_CREATE
rightclick it > Edit
scroll down and look for:
COMMIT TRANSACTION
SET @sp_rtn = 0
RETURN
thats the line that returns the client, "OK Your character has been made, u can login!"
example of a mailbox script to send an argate to new characters right after they have been made
COMMIT TRANSACTION
/* Custom content by Henkie2 / Pieter / KissMyBow
Sends new characters a argate in mailbox to welcome them */
declare @itemnum INT
SET @itemnum = 9901
EXEC character.dbo.SP_POST_SEND_OP @character_no,'[DEV] Henkie2',1,'Welcome Gift!!','Welcome to -servername- here a gift',@itemnum,'0',0
SET @sp_rtn = 0
RETURN
NOTE! u cannot SAVE stored procedures to save changes u made to a stored procedure using SQL-Profiler u have to EXECUTE it
press ALT+X to execute the SP and save your changes
|
|
|
|
08/12/2010, 23:31
|
#3
|
elite*gold: 0
Join Date: Dec 2008
Posts: 15
Received Thanks: 0
|
Quote:
Originally Posted by CROvic
by zombe
by pieter
|
sorry nothing helped me ,
nothing of that way i want ,
i dont want to make a character and have all this ***** then remove character and replace with DEKARON0000001 ,
i want a sql query to do that ,
maybe make it like a job , to start and send this items when new character created
|
|
|
08/13/2010, 00:14
|
#4
|
elite*gold: 0
Join Date: Jan 2008
Posts: 568
Received Thanks: 176
|
he gave u my script and that script does exactly what u want
it just takes a little more reading to understand it
the procedure SP_CHAR_CREATE gets run everytime someone creates a new character, so alterring that is the best way to do it!
|
|
|
08/13/2010, 01:30
|
#5
|
elite*gold: 0
Join Date: Dec 2008
Posts: 15
Received Thanks: 0
|
Quote:
Originally Posted by pieter
he gave u my script and that script does exactly what u want
it just takes a little more reading to understand it
the procedure SP_CHAR_CREATE gets run everytime someone creates a new character, so alterring that is the best way to do it!
|
were to put that code ?
i have alot things on this stored produse thing
Quote:
declare @itemnum INT
SET @itemnum = 9901
EXEC character.dbo.SP_POST_SEND_OP @character_no,'[DEV] Henkie2',1,'Welcome Gift!!','Welcome to -servername- here a gift',@itemnum,'0',0
SET @sp_rtn = 0
RETURN
|
|
|
|
08/13/2010, 03:00
|
#6
|
elite*gold: 0
Join Date: Aug 2009
Posts: 127
Received Thanks: 21
|
Quote:
open sql profiler
go to character > stored procedures
find SP_CHAR_CREATE
rightclick it > Edit
scroll down and look for:
COMMIT TRANSACTION
SET @sp_rtn = 0
RETURN
and change it to this
declare @itemnum INT
SET @itemnum = enter index of item
EXEC character.dbo.SP_POST_SEND_OP @character_no,' MyName',1,'Enter Mail name!!','Enter text here',@itemnum,'0',0
SET @sp_rtn = 0
RETURN
|
|
|
08/13/2010, 03:04
|
#7
|
elite*gold: 0
Join Date: Aug 2009
Posts: 127
Received Thanks: 21
|
#remove this post
sry for double posting...
|
|
|
08/13/2010, 13:48
|
#8
|
elite*gold: 0
Join Date: Dec 2008
Posts: 15
Received Thanks: 0
|
Quote:
Originally Posted by CROvic
open sql profiler
go to character > stored procedures
find SP_CHAR_CREATE
rightclick it > Edit
scroll down and look for:
COMMIT TRANSACTION
SET @sp_rtn = 0
RETURN
and change it to this
declare @itemnum INT
SET @itemnum = enter index of item
EXEC character.dbo.SP_POST_SEND_OP @character_no,' MyName',1,'Enter Mail name!!','Enter text here',@itemnum,'0',0
SET @sp_rtn = 0
RETURN
|
on this script send only 1 item ,
i changed the copper index to my 15 days custume
but i need 4 more items so ?
and i want to send for each char a custume , so i think this way not working ?
|
|
|
08/13/2010, 20:32
|
#9
|
elite*gold: 20
Join Date: Mar 2008
Posts: 964
Received Thanks: 232
|
You can use zombe's script to give many items as start as well. just get the character number of 6 DEV characters. go to user_bag and find the rows with those character numbers and add the lines to give them items. So whenever someone makes a new character those items will be in the inventory.
|
|
|
08/15/2010, 14:53
|
#10
|
elite*gold: 0
Join Date: Jan 2008
Posts: 568
Received Thanks: 176
|
sadly the timed items will instantly expire in that way
|
|
|
08/15/2010, 18:30
|
#11
|
elite*gold: 0
Join Date: Dec 2008
Posts: 15
Received Thanks: 0
|
Quote:
Originally Posted by pieter
sadly the timed items will instantly expire in that way
|
yes i tried , that way
they get removed when i crate the character
|
|
|
08/15/2010, 18:45
|
#12
|
elite*gold: 0
Join Date: Jan 2008
Posts: 568
Received Thanks: 176
|
thats why u can use my script.
just look at what it does, after that its easy to make it sent 2 or more items
1 hint, u can only add 1 item per mailbox message
|
|
|
08/16/2010, 01:39
|
#13
|
elite*gold: 0
Join Date: Dec 2008
Posts: 15
Received Thanks: 0
|
Quote:
Originally Posted by pieter
thats why u can use my script.
just look at what it does, after that its easy to make it sent 2 or more items
1 hint, u can only add 1 item per mailbox message
|
yes but i tried ,
i copied 2 scripts i mean like this
Quote:
COMMIT TRANSACTION
declare @itemnum INT
SET @itemnum = enter index of item
EXEC character.dbo.SP_POST_SEND_OP @character_no,' MyName',1,'Enter Mail name!!','Enter text here',@itemnum,'0',0
SET @sp_rtn = 0
RETURN
declare @itemnum INT
SET @itemnum = enter index of item
EXEC character.dbo.SP_POST_SEND_OP @character_no,' MyName',1,'Enter Mail name!!','Enter text here',@itemnum,'0',0
SET @sp_rtn = 0
RETURN
END
|
but not working xD
|
|
|
08/16/2010, 10:21
|
#14
|
elite*gold: 0
Join Date: Jan 2008
Posts: 568
Received Thanks: 176
|
what error does it give if u parse it in sql profiler?
|
|
|
08/16/2010, 23:07
|
#15
|
elite*gold: 0
Join Date: Dec 2008
Posts: 15
Received Thanks: 0
|
Quote:
Originally Posted by pieter
what error does it give if u parse it in sql profiler?
|
nothing ,
i just get 1 item only on mail box .
1 mail with 1 item , but i think it must send 2 items with 2 mails right ?
Quote:
i mean for example i run the first sql code to send mana potion ,
and secend to send hp potion , but it send mana potion only .
|
|
|
|
|
|
Similar Threads
|
[Suche]Query für "Alteklinge, Reichsklinge" &' Stichdolche NUR QUERY!
08/18/2010 - Metin2 Private Server - 1 Replies
Ich weiß ich werd nervig aber ich suche die Query's
für Alteklinge, Reichsklinge &' Strichdolche
Why?
Naya, weil ich in der DB i-wie nur Drachenmaulglocke hab
... not more -.-
Auf jeden Fall Icon's etc. etc. etc. hab ich ich brauche nur die Query's
|
query
05/05/2010 - Metin2 Private Server - 0 Replies
So es gab mal ein ttut wie man query fur navicat usen kan nur ich finde in nicht mehr hat jemand den link?
|
Query?
05/03/2010 - Metin2 Private Server - 24 Replies
Hi Liebe Community ;)
Ich wollte mal neue waffen einfügen ;)
Jemand sagte mir um sie in die DB einzufügen musst du in die Item_Proto gehen und ein query machen...
aber wie geht das? ich muss das da einfügen
INSERT INTO `item_proto` VALUES ('7220', 'Spada Raggio di Luna +0 ', 'Spada Raggio di Luna +0', '1', '0', '0', '2', '32', '1', '16', '', '30000', '100', '7221', '19', '0', '5', '1', '80', '0', '0', '7', '15', '17', '2', '0', '0', '0', '90', '110', '5', '67', '117', '-1', '-1',...
|
A Query
03/02/2010 - 12Sky2 - 6 Replies
Hi,
First off, i'm an addict for 12sky 2. I play both 12sky 2 PH and 12sky 2 aeria. All the hax i find here for aeria server
has been very helpful. Apparently, things are quite the opposite for 12sky2 ph server since we have Xtrap. So hacking is quite
impossible for PH. Lately there has been major issues in PH server like some people using cheats/hacks. Fact is, there are already
people banned in PH server for using hax.
Anyway, been trying to find a way to hack 12sky 2 ph server but...
|
Query Help? xD
01/24/2009 - EO PServer Hosting - 3 Replies
Hey lol Can anyone show me how to make this Query replace the old Legion Admin.. Check out this wordpad please and if you Know how to make these Translations replace the old ones Please email me at [email protected]
|
All times are GMT +2. The time now is 04:48.
|
|