Register for your free account! | Forgot your password?

Go Back   elitepvpers > MMORPGs > Shaiya > Shaiya Private Server > Shaiya PServer Development
You last visited: Today at 16:12

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

Advertisement



Insert Buffs (Not Nerver Ending)

Discussion on Insert Buffs (Not Nerver Ending) within the Shaiya PServer Development forum part of the Shaiya Private Server category.

Reply
 
Old   #1
 
[GameAdvisor]Finn's Avatar
 
elite*gold: 0
Join Date: Sep 2016
Posts: 171
Received Thanks: 106
Insert Buffs (Not Nerver Ending)

Hi epvp.
Anyone know how to add Buffs on New Character? (Not Never Ending)
example 30Days CRR only. then after 30days buffs need to use CRR again..

thanks for the answers..
[GameAdvisor]Finn is offline  
Old 07/10/2019, 09:44   #2
 
elite*gold: 0
Join Date: Oct 2012
Posts: 173
Received Thanks: 28
Try look at table PS_GameData.dbo.charapplyskills

There some fields you should clarify: charid, skillid, skilllevel, leftresettime

Add the insert sql in store procedure create new char.
nick4ever is offline  
Old 07/10/2019, 13:50   #3
 
elite*gold: 0
Join Date: May 2019
Posts: 2
Received Thanks: 0
Elessatr is offline  
Old 07/10/2019, 17:42   #4
 
[GameAdvisor]Finn's Avatar
 
elite*gold: 0
Join Date: Sep 2016
Posts: 171
Received Thanks: 106
Quote:
Originally Posted by Elessatr View Post
i already have this sir for never ending 30days buffs
but i need is not never ending..
example : i give free 7 or 30days CRR on new create char then after 7 or 30days . CRR is gone..
by the way thanks for give a time to answer my question
[GameAdvisor]Finn is offline  
Old 07/10/2019, 22:41   #5
 
elite*gold: 260
Join Date: Sep 2011
Posts: 487
Received Thanks: 359
For new char add it into usp_Create_Char_R procedure
SnickQ is offline  
Thanks
1 User
Old 07/12/2019, 04:21   #6
 
Mike__'s Avatar
 
elite*gold: 0
Join Date: Oct 2018
Posts: 67
Received Thanks: 28
i have not done this but if I am going to do this, i would agree with @, i will go check at SP usp_Create_Char_R.
we put our SP for newly created characters there.

I did this once but through BaseGearsDefs:
- i gave the item to newly created characters and item locked it to their inventory, this way they can use the item anytime they wished to use it. (because some players wish to use it in a later time not UPON creation)

Mike__ is offline  
Thanks
1 User
Old 07/12/2019, 14:40   #7
 
[GameAdvisor]Finn's Avatar
 
elite*gold: 0
Join Date: Sep 2016
Posts: 171
Received Thanks: 106
Quote:
Originally Posted by Mike__ View Post
i have not done this but if I am going to do this, i would agree with @, i will go check at SP usp_Create_Char_R.
we put our SP for newly created characters there.

I did this once but through BaseGearsDefs:
- i gave the item to newly created characters and item locked it to their inventory, this way they can use the item anytime they wished to use it. (because some players wish to use it in a later time not UPON creation)

yeah but that way player will make multiple character then trade to other character.. because i want to add custom buffs i made like nos buffs but i want to make it use already when character create so can't trade the free 30days or 7days Nos buffs
[GameAdvisor]Finn is offline  
Old 07/12/2019, 15:09   #8
 
elite*gold: 260
Join Date: Sep 2011
Posts: 487
Received Thanks: 359
Quote:
Originally Posted by [GameAdvisor]Finn View Post
yeah but that way player will make multiple character then trade to other character.. because i want to add custom buffs i made like nos buffs but i want to make it use already when character create so can't trade the free 30days or 7days Nos buffs
Then why you not use this to insert buff into CharApplySkills?
SnickQ is offline  
Old 07/12/2019, 15:32   #9
 
[GameAdvisor]Finn's Avatar
 
elite*gold: 0
Join Date: Sep 2016
Posts: 171
Received Thanks: 106
Quote:
Originally Posted by SnickQ View Post
Then why you not use this to insert buff into CharApplySkills?
SET @D = IDENT_CURRENT('Chars')
INSERT INTO dbo.CharApplySkills (CharID,SkillID,SkillLevel,LeftResetTime) VALUES @D,286,3,2592000)
END

RETURN @D

SET NOCOUNT OFF

like this sir?
[GameAdvisor]Finn is offline  
Old 07/12/2019, 15:33   #10
 
Mike__'s Avatar
 
elite*gold: 0
Join Date: Oct 2018
Posts: 67
Received Thanks: 28
Quote:
Originally Posted by [GameAdvisor]Finn View Post
yeah but that way player will make multiple character then trade to other character.. because i want to add custom buffs i made like nos buffs but i want to make it use already when character create so can't trade the free 30days or 7days Nos buffs
Not if the item is locked in the character's inventory.
Mike__ is offline  
Thanks
1 User
Old 07/13/2019, 19:52   #11
 
elite*gold: 0
Join Date: Apr 2016
Posts: 256
Received Thanks: 143
Programmability > usp_Create_Char_R
The specific SQL code adds a 7-Day Continuous Resurrection Rune to new characters.

All you have to do is change the SkillID, SkillLevel and LeftResetTime to your skill.
Make sure that LeftResetTime is in seconds.

Code:
INSERT INTO PS_GameData.dbo.CharApplySkills
(CharID, SkillID, SkillLevel, LeftResetTime)
VALUES
(@CharID, 286, 1, 604800)
[ADMIN]Phreak is offline  
Thanks
1 User
Old 07/14/2019, 05:46   #12
 
[GameAdvisor]Finn's Avatar
 
elite*gold: 0
Join Date: Sep 2016
Posts: 171
Received Thanks: 106
Quote:
Originally Posted by [ADMIN]Phreak View Post
Programmability > usp_Create_Char_R
The specific SQL code adds a 7-Day Continuous Resurrection Rune to new characters.

All you have to do is change the SkillID, SkillLevel and LeftResetTime to your skill.
Make sure that LeftResetTime is in seconds.

Code:
INSERT INTO PS_GameData.dbo.CharApplySkills
(CharID, SkillID, SkillLevel, LeftResetTime)
VALUES
(@CharID, 286, 1, 604800)
i already did without restarting the server but not show/work the buffs ..
[GameAdvisor]Finn is offline  
Old 07/14/2019, 11:24   #13

 
{Skrillex}'s Avatar
 
elite*gold: 0
Join Date: Mar 2013
Posts: 849
Received Thanks: 407
Quote:
Originally Posted by [GameAdvisor]Finn View Post
i already did without restarting the server but not show/work the buffs ..
Do you add the line from @ under
"SET @D = IDENT_CURRENT('Chars')" this line?

Btw Check your Logs. Maybe there is a error message.

Regards
{Skrillex} is offline  
Thanks
1 User
Old 07/14/2019, 12:31   #14
 
[GameAdvisor]Finn's Avatar
 
elite*gold: 0
Join Date: Sep 2016
Posts: 171
Received Thanks: 106
Quote:
Originally Posted by {Skrillex} View Post
Do you add the line from @ under
"SET @D = IDENT_CURRENT('Chars')" this line?

Btw Check your Logs. Maybe there is a error message.

Regards
i did like this

Quote:
SET @CharID = IDENT_CURRENT('Chars')
INSERT INTO CharItems
SELECT @CharID AS CharID,ItemID,dbo.ItemUID() AS ItemUID,Type,TypeID,Bag,Slot,Quality,Gem1,Gem2,Gem 3,Gem4,Gem5,Gem6,Craftname,1 AS COUNT,GETDATE() AS Maketime,'S' AS Maketype,0 AS Del
FROM PS_GameDefs.dbo.BaseGearsDefs WHERE Family = @Family AND Job = @Job AND Level = @Level
END

INSERT INTO PS_GameData.dbo.CharApplySkills
(CharID, SkillID, SkillLevel, LeftResetTime)
VALUES
(@CharID, 286, 1, 604800)

SELECT SkillID,MAX(SkillLevel) AS SkillLevel,MAX(Country) AS Country,MAX(Grow) AS Grow,MAX(Attackfighter) AS Attackfighter,MAX(Defensefighter) AS Defensefighter,MAX(Patrolrogue) AS Patrolrogue,MAX(Shootrogue) AS Shootrogue,MAX(Attackmage) AS Attackmage,MAX(Defensemage) AS Defensemage INTO #Skills
FROM PS_GameDefs.dbo.Skills
WHERE ReqLevel <= @Level AND
SkillLevel < 100 AND
TypeShow > 0 AND
(((@Job != 0 OR (Attackfighter = 1)) AND ((@Family != 0 OR (Country IN (6,2,0))) AND (@Family != 3 OR (Country IN (6,5,3)))))
AND ((@Job != 1 OR (Defensefighter = 1)) AND ((@Family != 0 OR (Country IN (6,2,0))) AND (@Family != 3 OR (Country IN (6,5,3)))))
AND ((@Job != 2 OR (Patrolrogue = 1)) AND ((@Family != 1 OR (Country IN (6,2,1))) AND (@Family != 2 OR (Country IN (6,5,4)))))
AND ((@Job != 3 OR (Shootrogue = 1)) AND ((@Family != 1 OR (Country IN (6,2,1))) AND (@Family != 3 OR (Country IN (6,5,3)))))
AND ((@Job != 4 OR (Attackmage = 1)) AND ((@Family != 1 OR (Country IN (6,2,1))) AND (@Family != 2 OR (Country IN (6,5,4)))))
AND ((@Job != 5 OR (Defensemage = 1)) AND ((@Family != 0 OR (Country IN (6,2,0))) AND (@Family != 2 OR (Country IN (6,5,4))))))
GROUP BY SkillID

DECLARE @Count INT = (SELECT COUNT(SkillLevel) FROM #Skills)

WHILE @Count > 0
BEGIN
INSERT INTO CharSkills
SELECT TOP (1) @CharID,SkillID,SkillLevel,@Count,0,GETDATE(),0
FROM #Skills

DELETE TOP (1) FROM #Skills

SET @Count -= 1
END

DROP TABLE #Skills

RETURN @CharID

SET NOCOUNT OFF
[GameAdvisor]Finn is offline  
Old 07/14/2019, 13:12   #15
 
elite*gold: 0
Join Date: Apr 2016
Posts: 256
Received Thanks: 143
Quote:
Originally Posted by [GameAdvisor]Finn View Post
i already did without restarting the server but not show/work the buffs ..
The specific change doesn't require a restart.
Did you make sure that skill exists on such ID?
Also, did you make a new character or checked on existing one?
[ADMIN]Phreak is offline  
Reply


Similar Threads Similar Threads
[Root Vorstellung]Memoria-you ´il nerver walk alone!
04/25/2011 - Metin2 PServer Advertising - 544 Replies
Hallo liebe E*PvP Community. Hiermit stelle ich euch den neuen Server Memoria vor. Features von Memoria: •2010er Files •2010er Client •Permanente Lv. Anzeige •Max. Lv. 150 •Drachenraum
"Nerver"
03/07/2010 - Off Topic - 1 Replies
Hallo, Es gibt so einen "Nerver" (.exe) wenn man das öffnet dann spielt das CD Laufwerk verrückt. D.h. es geht immer auf und wieder zu und erst nach einem neustart hört dies auf.Wo kriegt man den??? Ich habe schon so etwas ähnliches als batch programmiert aber so kriegt man das Laufwerk net mehr Zu^^ Freue mich vor allem über einen Link ;) MFG 28daniel28



All times are GMT +2. The time now is 16:12.


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.