|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
قسم الاسئلة و الاستفسارات لعمل السيرفرات الخاصة [ قسم خاص لأسئلة واستفسارات عمل السيرفرات الخاصة ] [ يرجى الالتزام بقوانين قسم الأسئلة والاستفسارات ] |
|
06-01-2017, 12:44 AM
|
#1
|
|
• الانـتـسـاب » Oct 2012
|
• رقـم العـضـويـة » 106331
|
• المشـــاركـات » 957
|
• الـدولـة » GIZZA
|
• الـهـوايـة » Babel.SRO only
|
• اسـم الـسـيـرفـر » Lepus
|
• الـجـنـس » Male
|
• نقـاط التقييم » 13
|
|
|
system silk hour
اولا السلام عليكم انا عندى جيم دجرى 11 كاب 110 انا عامل نظام السلد بيجي كل ساعة بس كنت عايز اخلى السلك يجي للناس ال110 بس مش اقل من اللفل دة ياريت لو حد يعرف يفدنى وشكرا
|
|
|
إعلانات google |
|
06-01-2017, 04:16 AM
|
#2
|
|
• الانـتـسـاب » Sep 2012
|
• رقـم العـضـويـة » 105765
|
• المشـــاركـات » 3,016
|
• الـدولـة » تحت البحر
|
• الـهـوايـة » hack Site
|
• اسـم الـسـيـرفـر » No Server
|
• الـجـنـس » Male
|
• نقـاط التقييم » 25
|
|
|
رد: system silk hour
غير ده مكان الي عندك في addlogcher
كود PHP:
IF (@CharID IN (select charid from SRO_VT_SHARD.dbo._User with (nolock) where UserJID in (select JID from SRO_VT_ACCOUNT.dbo.TB_User with (nolock) where sec_content = 3)) and exists (Select * from SRO_VT_SHARD.dbo._Char where CurLevel = '120' and CharID = @charid) and not exists (SELECT CharID FROM _OnlineOffline WHERE CharID = @CharID) ) BEGIN
INSERT INTO _OnlineOffline (CharID, Charname, [Status], [Date], [Minutes], [tMinutes], eSilk, mOnline, [Silk/Hour], [stillOnline@]) VALUES ( @CharID, (SELECT CharName16 FROM SRO_VT_SHARD.dbo._Char WHERE CharID = @CharID), 'OnHold', GETDATE(), 0,0,0, NULL,(SELECT DefaultSilk FROM [_Silk/Hour-Config] WHERE [Desc] like 'Rates'), NULL ); END
IF (@EventID = 4 OR @EventID = 6) BEGIN
IF (@EventID = 6 AND ((SELECT [Status] FROM _OnlineOffline WHERE CharID = @CharID) like 'OnHold')) BEGIN UPDATE _OnlineOffline SET [Status] = 'Offline' WHERE CharID = @CharID END IF (@EventID = 6 AND ((SELECT [Status] FROM _OnlineOffline WHERE CharID = @CharID) like 'Online')) BEGIN UPDATE _OnlineOffline SET [Status] = 'Offline', [Minutes] = [Minutes] + (DATEDIFF(MINUTE,[stillOnline@],GETDATE())), [tMinutes] = [tMinutes] + (DATEDIFF(MINUTE,[stillOnline@],GETDATE())), [mOnline] = NULL, [stillOnline@] = NULL WHERE CharID = @CharID END IF (@EventID = 4) BEGIN UPDATE _OnlineOffline SET [Status] = 'Online', [Date] = GETDATE(), [stillOnline@] = GETDATE() WHERE CharID = @CharID END END
UPDATE _OnlineOffline SET [mOnline] = CAST((DATEDIFF(MINUTE,[Date],GETDATE()))as varchar(max)) + ' minute(s) Online', [Minutes] = [Minutes] + (DATEDIFF(MINUTE,[stillOnline@],GETDATE())), [tMinutes] = [tMinutes] + (DATEDIFF(MINUTE,[stillOnline@],GETDATE())), [stillOnline@] = GETDATE() WHERE [Status] like 'Online'
/*Silk/Hour basic calc*/ IF ((SELECT [tMinutes] from _OnlineOffline WHERE CharID = @CharID) >= (SELECT [Step1Silk] FROM [_Silk/Hour-Config] WHERE [Desc] like 'Requirements')) BEGIN Declare @sph int; exec @sph = [_GetSilkperHour] @CharID UPDATE _OnlineOffline SET [Silk/Hour] = @sph WHERE CharID = @CharID END /*!Silk/Hour basic calc*/
IF (((SELECT NextDate FROM [_RandomPlayer&Date] WHERE [Desc] like 'Next') IS NULL)) BEGIN DECLARE @FirstDate datetime, @Today datetime = GETDATE(), @FirstCharID int;
exec @FirstCharID = SRO_VT_SHARD.dbo._RandomPlayerID exec SRO_VT_SHARD.dbo._GetRandomTime @Today, @FirstDate OUTPUT UPDATE [_RandomPlayer&Date] SET NextDate = @FirstDate, RefreshedDate = GETDATE(), CharID = @FirstCharID, Charname = (SELECT CharName16 FROM SRO_VT_SHARD.dbo._Char WHERE CharID = @FirstCharID) WHERE [Desc] like 'Next'; END IF ((SELECT NextDate FROM [_RandomPlayer&Date] WHERE [Desc] like 'Next') <= GETDATE()) BEGIN UPDATE _OnlineOffline SET [Silk/Hour] = (SELECT RewardSilk FROM [_Silk/Hour-Config] WHERE [Desc] like 'Rates') WHERE CharID = (SELECT CharID FROM [_RandomPlayer&Date] WHERE [Desc] like 'Next'); Declare @CurSilkperHour int, @OldCharID int = (SELECT CharID FROM [_RandomPlayer&Date] WHERE [Desc] like 'Current'); IF (@OldCharID IS NOT NULL) BEGIN exec @CurSilkperHour = _GetSilkperHour @OldCharID UPDATE _OnlineOffline SET [Silk/Hour] = @CurSilkperHour WHERE CharID = @OldCharID; END UPDATE [_RandomPlayer&Date] SET NextDate = NULL, RefreshedDate = GETDATE(), CharID = (SELECT CharID FROM [_RandomPlayer&Date] WHERE [Desc] like 'Next'), Charname = (SELECT Charname FROM [_RandomPlayer&Date] WHERE [Desc] like 'Next') WHERE [Desc] like 'Current' /*new Random Time of Today+1*/ DECLARE @NextDate datetime, @Tomorrow datetime = GETDATE()+1, @NewCharID int; exec @NewCharID = SRO_VT_SHARD.dbo._RandomPlayerID exec SRO_VT_SHARD.dbo._GetRandomTime @Tomorrow, @NextDate OUTPUT UPDATE [_RandomPlayer&Date] SET NextDate = @NextDate, RefreshedDate = GETDATE(), CharID = @NewCharID, Charname = (SELECT CharName16 FROM SRO_VT_SHARD.dbo._Char WHERE CharID = @NewCharID) WHERE [Desc] like 'Next' /*!new Random...*/ END /*Calculation of the silk amount*/ Declare @tMinutes bigint = (SELECT [Minutes] from _OnlineOffline WHERE CharID = @CharID), @Silk int; IF (@tMinutes >= 60) BEGIN SET @Silk = CAST(((SELECT [Minutes] FROM _OnlineOffline WHERE CharID = @CharID) / 60) as int) UPDATE _OnlineOffline SET [Minutes] = [Minutes] % 60 WHERE CharID = @CharID IF exists (SELECT [WEEKDAYS] FROM [_Silk/Hour-Config] WHERE [WEEKDAYS] like DATENAME(WEEKDAY, GETDATE())) BEGIN UPDATE _OnlineOffline SET [eSilk] = [eSilk] + (@Silk*[Silk/Hour]) WHERE CharID = @CharID exec SRO_VT_ACCOUNT.dbo._extraSilk @CharID, @Silk END END
متنساش تغير lvl
|
|
|
يتصفح الموضوع حالياً : 1 (0 عضو و 1 زائر)
|
|
ضوابط المشاركة
|
لا تستطيع إضافة مواضيع جديدة
لا تستطيع الرد على المواضيع
لا تستطيع إرفاق ملفات
لا تستطيع تعديل مشاركاتك
كود HTML معطلة
|
|
|
الساعة الآن 11:32 PM.
|