[Question]Pre-leveled Characters

08/22/2011 08:48 [Dev]Cataclysm#1
I had searched a bit and had not found anything on this, but I was curious on how I would be able to have all new characters created set at level 60? I know I can just fix and set all required exp per level to 0 but I would rather just be able to set them up before hand. Can anyone point me in the direction I should be looking to find & fix this?
08/22/2011 09:01 viper4513#2
Not to sure, but i heard ShaiyaX did this to their server, and maybe another server aswell (before them)

Try edit the Exp.Defs table or maybe one of the CreateChar stored procedures (dbo.usp_Create_Char_R)

i'm guessing near line 65, make Skill point 300, and add a stat point at 549 or whatever it goes to usually.
maybe even try change the @level to 60, instead of 0.... try things out (preferably in a test server) and see if you can work it out yourself :)
08/22/2011 09:02 [GM]Recover#3
ask [ADMIN]Snuggle he did it he might give you a Hint ;)
08/22/2011 09:09 [Dev]Cataclysm#4
Yeah I have messed around with a few things but haven't quite struck gold on it. I like using Brain.exe so I just thought I would ask in which general direction should I go lol. But will check the procedures & a few others to see if that works.
08/22/2011 09:12 JohnHeatz#5
To point you out in some direction, you just need to set the default to 60 instead of 1 on the level column on the chars table, obviously this has to be done on the creation of a character ;)
08/22/2011 09:27 [Dev]Cataclysm#6
Quote:
Originally Posted by JohnHeatz View Post
To point you out in some direction, you just need to set the default to 60 instead of 1 on the level column on the chars table
Well the way I read and understood that was basically setting their level via DB AFTER the toon is made. Then again maybe you are referring to opening it via "Design". If so I have done that while it is labeled "smallint" and I changed the "Default Value or Binding" from ((0)) to ((60)) but it didn't work.

Now I am also inside the stored procedure as Viper said but not sure what exactly to edit but I had an idea of maybe trying:

(This is part of the query that I am looking at)


/* 여기까지 인자값 주어져야 함 */

/* SP 내부 참조용 변수 */

@CharID int = 0,
@NameCnt tinyint = 0

AS

SET NOCOUNT ON

DECLARE @Ret int

SET @CharName = LTRIM(RTRIM(@CharName))
SET @SkillPoint = 5
SET @Ret = 0






Now what I thought about editing or changing on this would be this particular section:



AS

SET NOCOUNT ON

DECLARE @Ret int

SET @CharName = LTRIM(RTRIM(@CharName))
SET @Level = 60
SET @StatPoint = 531
SET @SkillPoint = 300
SET @Ret = 0


Now I am not sure if this would work and or if it did, if I would need to change it somewhere else. Just looked like common sense to me in that aspect of looking at it.
08/22/2011 09:36 viper4513#7
should be able to just execute that Stored Procedure, restart server, make new toon and it will either work, or not.. :P

But reading what JohnHeatz said, it looks like you only change that 0 to 60, then define some things in the char_create procedures to get it working :P hope you work it out xD

Edit:
Maybe another thing you could try out, is setting the "exp" the same as you did with the "level" value...
so they start with the top exp, if the int value will reach that.. :P
08/22/2011 09:38 .Scy#8
Quote:
Originally Posted by [Dev]Cataclysm View Post
Well the way I read and understood that was basically setting their level via DB AFTER the toon is made. Then again maybe you are referring to opening it via "Design". If so I have done that while it is labeled "smallint" and I changed the "Default Value or Binding" from ((0)) to ((60)) but it didn't work.

Now I am also inside the stored procedure as Viper said but not sure what exactly to edit but I had an idea of maybe trying:

(This is part of the query that I am looking at)


/* 여기까지 인자값 주어져야 함 */

/* SP 내부 참조용 변수 */

@CharID int = 0,
@NameCnt tinyint = 0

AS

SET NOCOUNT ON

DECLARE @Ret int

SET @CharName = LTRIM(RTRIM(@CharName))
SET @SkillPoint = 5
SET @Ret = 0






Now what I thought about editing or changing on this would be this particular section:



AS

SET NOCOUNT ON

DECLARE @Ret int

SET @CharName = LTRIM(RTRIM(@CharName))
SET @Level = 60
SET @StatPoint = 531
SET @SkillPoint = 300
SET @Ret = 0


Now I am not sure if this would work and or if it did, if I would need to change it somewhere else. Just looked like common sense to me in that aspect of looking at it.
if the red SET isnt allready in there u cant do it like this. the game expects a lvl 1 char with 5 stats u cant just do new functions but u may try it(im nota dev. at shaiya didnt even play it :p)
08/22/2011 09:41 [Dev]Cataclysm#9
Well what do ya know, it did work lol. So the part I modified actually did take effect when making a new character. Gotta love the Brain.exe :P

Thanks to all of you guys for the tip in direction
08/22/2011 09:48 viper4513#10
xD glad you got it working, now you can work on setting the buttons (em, nm, hm, um) to give different starting levels or even gameplay types :P
08/22/2011 09:51 [Dev]Cataclysm#11
Lol would be nice, though if I had to start somewhere I would believe it would be in the same stored procedure but just modifying it. But 1 step at a time right? :P
08/22/2011 09:54 .Scy#12
i wouldnt have expected that LOL simple shit made serverfiles i think(no offence)
08/22/2011 09:58 JohnHeatz#13
Every thing you have to work on a database is pure logic, obviously it involves some knowledge on what you are doing, that is the basic of programming "per se" the thing while you are doing something like this is that some things are so easy to do and involve so much logic that people take them aside thinking "No, this won't work, it is too easy" and at the end they end up trying after failing with other ways and getting to know that the easiest thing is the one that worked.

Glad that you got this to work Cataclysm ;)
08/22/2011 10:01 [Dev]Cataclysm#14
Yeah you are right about this John. A lot of the time I tend to overlook or over think things because it just seems "too" easy. But that is what trial and error is for. I can't tell you how many times I had failed in making a proper patch then finally realised the reason something wouldn't take effect was because I was forgetting sub folders inside the data folder lol. But always a good feeling to figure shit out once in a while eh?
08/22/2011 13:03 viper4513#15
mhmms, thats the way i work with my SQL shiz, i'm a total newbie at it, with no past experience.. i go at it with a hammer and break everything in everyway i can until i get something to work :P

Thats how i learn xD

and for the button things, i wudnt think it would be a stored procedure but simply just edit the "look" of the button itself, probably look in the "interface" folder in your game files (extracted)