Register for your free account! | Forgot your password?

You last visited: Today at 20:44

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

Advertisement



PVP Reward

Discussion on PVP Reward within the Shaiya PServer Development forum part of the Shaiya Private Server category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Jun 2018
Posts: 3
Received Thanks: 0
PVP Reward

Can any one Help on How To make a PVP Reward??
dejillas1234 is offline  
Old 06/25/2018, 13:50   #2
 
elite*gold: 0
Join Date: Mar 2018
Posts: 251
Received Thanks: 104
Hey you can edit this script
USE [PS_GameData]
GO
/****** Object: StoredProcedure [dbo].[usp_Save_Char_Kills_Rewards] Script Date: 09/20/2012 21:42:42 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO


ALTER Proc [dbo].[usp_Save_Char_Kills_Rewards]
@ID tinyint, @ varchar(12),
@K1 int

AS

SET NOCOUNT ON

@DP INT

if(@k1> 999 AND @k1< 1000000)
SET @DP =(
CASE
WHEN @k1 = 1000 THEN 25
WHEN @k1 = 2000 THEN 50
ELSE @DP
END)

BEGIN
UPDATE PS_UserData.dbo.Users_Master SET Point = Point + @DP WHERE UserID = @
END

IF(@@ERROR = 0)
BEGIN
RETURN 1
END
ELSE
BEGIN
RETURN -1
END

SET NOCOUNT OFF

Code:
SET @ = ' 100'
SELECT @ID=U.UserUID, @=U.UserID
FROM PS_GameData.dbo.Chars AS C INNER JOIN PS_UserData.dbo.Users_Master AS U
ON C.UserUID = U.UserUID AND C.UserID = U.UserID
WHERE C.CharName = @ AND C.Del=0;
ELSE
BEGIN
SET @Point=(SELECT Point FROM PS_UserData.dbo.Users_Master WHERE UserUID @ID)
UPDATE PS_UserData.dbo.Users_Master
SET Point=(Point @)
WHERE UserUID @ID
SET @=(SELECT Point FROM PS_UserData.dbo.Users_Master WHERE UserUID @ID)SET @ = ' 100'
SELECT @ID=U.UserUID, @=U.UserID
FROM PS_GameData.dbo.Chars AS C INNER JOIN PS_UserData.dbo.Users_Master AS U
ON C.UserUID = U.UserUID AND C.UserID = U.UserID
WHERE C.CharName = @ AND C.Del=0;
ELSE
BEGIN
SET @Point=(SELECT Point FROM PS_UserData.dbo.Users_Master WHERE UserUID @ID)
UPDATE PS_UserData.dbo.Users_Master
SET Point=(Point @)
WHERE UserUID @ID
SET @=(SELECT Point FROM PS_UserData.dbo.Users_Master WHERE UserUID @ID)

Credit's To JuuF

You need to add more "if" statements if you want to do it per rank though, this is what you have here:

Code:
@DP INT

if(@k1> 999 AND @k1< 1000000)
SET @DP =(
CASE
WHEN @k1 = 1000 THEN 25
WHEN @k1 = 2000 THEN 50
ELSE @DP
END)

Quote:
Originally Posted by [DEV]Wan View Post
Hey you can edit this script
USE [PS_GameData]
GO
/****** Object: StoredProcedure [dbo].[usp_Save_Char_Kills_Rewards] Script Date: 09/20/2012 21:42:42 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO


ALTER Proc [dbo].[usp_Save_Char_Kills_Rewards]
@ID tinyint, @ varchar(12),
@K1 int

AS

SET NOCOUNT ON

@DP INT

if(@k1> 999 AND @k1< 1000000)
SET @DP =(
CASE
WHEN @k1 = 1000 THEN 25
WHEN @k1 = 2000 THEN 50
ELSE @DP
END)

BEGIN
UPDATE PS_UserData.dbo.Users_Master SET Point = Point + @DP WHERE UserID = @
END

IF(@@ERROR = 0)
BEGIN
RETURN 1
END
ELSE
BEGIN
RETURN -1
END

SET NOCOUNT OFF

Code:
SET @ = ' 100'
SELECT @ID=U.UserUID, @=U.UserID
FROM PS_GameData.dbo.Chars AS C INNER JOIN PS_UserData.dbo.Users_Master AS U
ON C.UserUID = U.UserUID AND C.UserID = U.UserID
WHERE C.CharName = @ AND C.Del=0;
ELSE
BEGIN
SET @Point=(SELECT Point FROM PS_UserData.dbo.Users_Master WHERE UserUID @ID)
UPDATE PS_UserData.dbo.Users_Master
SET Point=(Point @)
WHERE UserUID @ID
SET @=(SELECT Point FROM PS_UserData.dbo.Users_Master WHERE UserUID @ID)SET @ = ' 100'
SELECT @ID=U.UserUID, @=U.UserID
FROM PS_GameData.dbo.Chars AS C INNER JOIN PS_UserData.dbo.Users_Master AS U
ON C.UserUID = U.UserUID AND C.UserID = U.UserID
WHERE C.CharName = @ AND C.Del=0;
ELSE
BEGIN
SET @Point=(SELECT Point FROM PS_UserData.dbo.Users_Master WHERE UserUID @ID)
UPDATE PS_UserData.dbo.Users_Master
SET Point=(Point @)
WHERE UserUID @ID
SET @=(SELECT Point FROM PS_UserData.dbo.Users_Master WHERE UserUID @ID)

Credit's To JuuF

You need to add more "if" statements if you want to do it per rank though, this is what you have here:

Code:
@DP INT

if(@k1> 999 AND @k1< 1000000)
SET @DP =(
CASE
WHEN @k1 = 1000 THEN 25
WHEN @k1 = 2000 THEN 50
ELSE @DP
END)








If @k1 = 1000
Set @DP = 25
Else if @k1 = 2000
Set @DP = 50T his is a simply arrangement for this, looks better, easier to understand -maybe- and you won't have to worry about the CASE syntax too much; as I see it sort of awkward there.
[DEV]Wan is offline  
Reply

Tags
pvp reward, shaiya


Similar Threads Similar Threads
[Selling] Pre-registration reward for Summoners War: Rift of Worlds 1$ Pre-registration reward
12/15/2015 - Summoners War Trading - 0 Replies
“Summoners War: The Rift of Worlds” is now available! http://i.imgur.com/uZ71itv.png <Download Summoners War> http://m.withhive.com/b?i=9447&g=9446 <Get Pre-registration Reward> Autobuy: https://payivy.com/v/9a4ce
Double pvp daily honor reward
03/11/2008 - WoW Exploits, Hacks, Tools & Macros - 5 Replies
Here we go; I personally use this exploit to gain my daily 800 honor point, so all you have to do is to take your Daily Pvp Quest,complete it and then rejoin the same BG of the daily quest. At this point when you join for the second time the bg you start it with the 400 point of the quest plus 400 point for an unfixed bug. For example: the daily pvp quest is to win alterac valley however, i will do the quest and then join arathi .......-after 5 minutes-.... Nice one, av won at the first...



All times are GMT +1. The time now is 20:45.


Powered by vBulletin®
Copyright ©2000 - 2025, 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 ©2025 elitepvpers All Rights Reserved.