اسم العضو كلمة المرور حفظ البيانات؟ تسجيل عضوية



ايجى4يو || Egy4u



اعلانات ايجى4يو


المشاركات: 314 [+]
المخالفات: [+]
مجموع الاوسمة: [+]
Senior.Egy4U غير متواجد حالياً
Senior.Egy4U
( ( عضو جديد ) )
Battle Power , PK Tournamet
: 06-04-2017 فى تمام الساعة 07:46 PM| المشاركة رقم: 1| من قسم: تطوير سيرفرات كـــونـــكر تـــهيس


كويسته
Battle Power , PK Tournamet xD
علشان تعرف اكثر انا بتكلم عن ايه
شوف الكويسته من الموقع االلعبه

Html

http://co.99.com/guide/event/2015/BPPK/ 
الاضــافة

Npcs.cs

Html

#region BPower Event 
                    #region BP QOUEST   
                    
case 95481:  
                        {  
                            switch (
npcRequest.OptionID)  
                            {  
                                case 
0:  
                                    {  
                                        if (
DateTime.Now.Hour == 18 && DateTime.Now.Minute == 00 && DateTime.Now.Minute <= 28)  
                                        {  
                                            
dialog.Text("hi" client.Entity.Name "Bp has startede do u need jouin?");  
                                            
dialog.Option("yes i need"1);  
                                            
dialog.Option("no iam not strong"255);  
                                            
dialog.Send();  
                                            break;  
                                        }  
                                        else  
                                        {  
                                            
dialog.Text("The Battle Power Toumament has ended.See you next time.");  
                                            
dialog.Option("Claim reward for 2 wins."2);  
                                            
dialog.Option("Claim reward for 3 wins."3);  
                                            
dialog.Option("Claim reward for 4 wins."4);  
                                            
dialog.Option("See you"255);  
                                            
dialog.Send();  
                                            break;  
                                        }  


                                    }  
                                case 
1:  
                                    {  
                                        if (
client.Entity.BattlePower >= 250 && client.Entity.BattlePower <= 300)  
                                        {  
                                            
client.Entity.Teleport(123455050);  

                                        }  
                                        else  
                                        {  
                                            if (
client.Entity.BattlePower >= 301 && client.Entity.BattlePower <= 350)  
                                            {  
                                                
client.Entity.Teleport(123445050);  

                                            }  
                                            else  
                                            {  
                                                if (
client.Entity.BattlePower >= 350 && client.Entity.BattlePower <= 385)  
                                                {  
                                                    
client.Entity.Teleport(123335050);  

                                                }  
                                            }     
                                        }  
                                        break;  
                                    }  
                                case 
2:  
                                    {  
                                        if (
client.Inventory.Contains(30068402))  
                                        {  
                                            
dialog.Text("Nice" client.Entity.Name "you have got 1m forM AverageBPToken");  
                                            
client.Inventory.Remove(30068402);  
                                            
client.Entity.ConquerPoints += 1000000;  
                                        }  
                                        else  
                                        {  
                                            if (
client.Inventory.Contains(30068412))  
                                            {  
                                                
dialog.Text("Nice" client.Entity.Name "you have got 2m forM EliteBPToken");  
                                                
client.Inventory.Remove(30068412);  
                                                
client.Entity.ConquerPoints += 2000000;  
                                            }  
                                            else  
                                            {  
                                                if (
client.Inventory.Contains(30068422))  
                                                {  
                                                    
dialog.Text("Nice" client.Entity.Name "you have got 3m forM SuperBPToken");  
                                                    
client.Inventory.Remove(30068422);  
                                                    
client.Entity.ConquerPoints += 3000000;  
                                                }  
                                                else  
                                                {  
                                                    
dialog.Text("Sorry" client.Entity.Name "you didn't have Any Token");  
                                                    
dialog.Option("I will come later",255);  
                                                    
dialog.Send();  
                                                }  
                                            }  
                                        }  
                                        break;  
                                    }  
                                case 
3:  
                                    {  
                                        if (
client.Inventory.Contains(30068403))  
                                        {  
                                            
dialog.Text("Nice" client.Entity.Name "you have got 1.5m forM AverageBPToken");  
                                            
client.Inventory.Remove(30068403);  
                                            
client.Entity.ConquerPoints += 1500000;  
                                        }  
                                        else  
                                        {  
                                            if (
client.Inventory.Contains(30068413))  
                                            {  
                                                
dialog.Text("Nice" client.Entity.Name "you have got 3m forM EliteBPToken");  
                                                
client.Inventory.Remove(30068413);  
                                                
client.Entity.ConquerPoints += 3000000;  
                                            }  
                                            else  
                                            {  
                                                if (
client.Inventory.Contains(30068423))  
                                                {  
                                                    
dialog.Text("Nice" client.Entity.Name "you have got 6m forM SuperBPToken");  
                                                    
client.Inventory.Remove(30068423);  
                                                    
client.Entity.ConquerPoints += 6000000;  
                                                }  
                                            }  
                                        }  
                                        break;  
                                    }  
                                case 
4:  
                                    {  
                                        if (
client.Inventory.Contains(30068404))  
                                        {  
                                            
dialog.Text("Nice" client.Entity.Name "you have got 2m forM AverageBPToken");  
                                            
client.Inventory.Remove(30068404);  
                                            
client.Entity.ConquerPoints += 2000000;  
                                        }  
                                        else  
                                        {  
                                            if (
client.Inventory.Contains(30068414))  
                                            {  
                                                
dialog.Text("Nice" client.Entity.Name "you have got 4m forM EliteBPToken");  
                                                
client.Inventory.Remove(30068414);  
                                                
client.Entity.ConquerPoints += 4000000;  
                                            }  
                                            else  
                                            {  
                                                if (
client.Inventory.Contains(30068424))  
                                                {  
                                                    
dialog.Text("Nice" client.Entity.Name "you have got 8m forM SuperBPToken");  
                                                    
client.Inventory.Remove(30068424);  
                                                    
client.Entity.ConquerPoints += 8000000;  
                                                }  
                                            }  
                                        }  
                                        break;  
                                    }  
                            }  
                            break;  
                        }  

                    
#endregion by Lego  
                    #region BP Prize 250/300 by Lego  
                    
case 95482:  
                        {  
                            switch (
npcRequest.OptionID)  
                            {  
                                case 
0:  
                                    {  
                                        
dialog.Text("Nice" client.Entity.Name " Would you like to claim your Prize?.");  
                                        
dialog.Option("Take prize"1);  
                                        
dialog.Option("No i don't"255);  
                                        
dialog.Send();  
                                        break;  
                                    }  
                                case 
1:  
                                    {  
                                        
int alive 0;  
                                        foreach (
Tough.Client.GameClient players in Tough.Kernel.GamePool.Values)  
                                            if (
players.Entity.MapID == 12345 && (!players.Entity.Dead))  
                                                
alive++;  
                                        if (
DateTime.Now.Hour == 18 && DateTime.Now.Minute >= 30 && DateTime.Now.Minute <= 50)  
                                        {  
                                            if (
alive == 1)  
                                            {  
                                                
client.Entity.Teleport(1002300278);  
                                                
client.Inventory.Add(300684001);  
                                                
Kernel.SendWorldMessage(new Message(string.Concat(new object[] { "Congratulations! "client.Entity.Name" claimed the prize AverageBPToken for winning the [BPower] for this Day." }), System.Drawing.Color.Black0x7db), Program.GamePool);  
                                                
client.Entity.AddTopStatus3((ulong)Update.Flags3.rygh_syzsDateTime.Now.AddDays(7));  
                                                
EntityTable.SaveEntity(client);  
                                            }  
                                            else  
                                            {  
                                                
dialog.Text("There are still " Daily.howmanyinmap " players in the map kill it first to claim prize!");  
                                                
dialog.Option("okay"0xff);  
                                                
dialog.Send();  
                                            }  
                                        }  
                                        else  
                                        {  
                                            
dialog.Text("Hey there " client.Entity.Name "You can only claim the prize when the time on or after xx:30");  
                                            
dialog.Option("okay"0xff);  
                                            
dialog.Send();  
                                        }  
                                        break;  
                                    }  
                            }  
                            break;  
                        }  
                    
#endregion  
                    #region BP Prize 300/350 by Lego  
                    
case 95483:  
                        {  
                            switch (
npcRequest.OptionID)  
                            {  
                                case 
0:  
                                    {  
                                        
dialog.Text("Nice" client.Entity.Name " Would you like to claim your Prize?.");  
                                        
dialog.Option("Take prize"1);  
                                        
dialog.Option("No i don't"255);  
                                        
dialog.Send();  
                                        break;  
                                    }  
                                case 
1:  
                                    {  
                                        
int alive 0;  
                                        foreach (
Tough.Client.GameClient players in Tough.Kernel.GamePool.Values)  
                                            if (
players.Entity.MapID == 12344 && (!players.Entity.Dead))  
                                                
alive++;  
                                        if (
DateTime.Now.Hour == 18 && DateTime.Now.Minute >= 30 && DateTime.Now.Minute <= 50)  
                                        {  
                                            if (
alive == 1)  
                                            {  
                                                
client.Entity.Teleport(1002300278);  
                                                
client.Inventory.Add(300684101);  
                                                
Kernel.SendWorldMessage(new Message(string.Concat(new object[] { "Congratulations! "client.Entity.Name" claimed the prize EliteBPToken for winning the [BPower] for this Day." }), System.Drawing.Color.Black0x7db), Program.GamePool);  
                                                
client.Entity.AddTopStatus3((ulong)Update.Flags3.rygh_syzsDateTime.Now.AddDays(7));  
                                                
EntityTable.SaveEntity(client);  
                                            }  
                                            else  
                                            {  
                                                
dialog.Text("There are still " Daily.howmanyinmap " players in the map kill it first to claim prize!");  
                                                
dialog.Option("okay"0xff);  
                                                
dialog.Send();  
                                            }  
                                        }  
                                        else  
                                        {  
                                            
dialog.Text("Hey there " client.Entity.Name "You can only claim the prize when the time on or after xx:30");  
                                            
dialog.Option("okay"0xff);  
                                            
dialog.Send();  
                                        }  
                                        break;  
                                    }  
                            }  
                            break;  
                        }  
                    
#endregion  
                    #region BP Prize 350/385 by Lego  
                    
case 95484:  
                        {  
                            switch (
npcRequest.OptionID)  
                            {  
                                case 
0:  
                                    {  
                                        
dialog.Text("Nice" client.Entity.Name " Would you like to claim your Prize?.");  
                                        
dialog.Option("Take prize"1);  
                                        
dialog.Option("No i don't"255);  
                                        
dialog.Send();  
                                        break;  
                                    }  
                                case 
1:  
                                    {  
                                        
int alive 0;  
                                        foreach (
Tough.Client.GameClient players in Tough.Kernel.GamePool.Values)  
                                            if (
players.Entity.MapID == 12333 && (!players.Entity.Dead))  
                                                
alive++;  
                                        if (
DateTime.Now.Hour == 18 && DateTime.Now.Minute >= 30 && DateTime.Now.Minute <= 50)  
                                        {  
                                            if (
alive == 1)  
                                            {  
                                                
client.Entity.Teleport(1002300278);  
                                                
client.Inventory.Add(300684201);  
                                                
Kernel.SendWorldMessage(new Message(string.Concat(new object[] { "Congratulations! "client.Entity.Name" claimed the prize SuperBPToken for winning the [BPower] for this Day." }), System.Drawing.Color.Black0x7db), Program.GamePool);  
                                                
client.Entity.AddTopStatus3((ulong)Update.Flags3.rygh_hglxDateTime.Now.AddDays(7));  
                                                
EntityTable.SaveEntity(client);  
                                            }  
                                            else  
                                            {  
                                                
dialog.Text("There are still " Daily.howmanyinmap " players in the map kill it first to claim prize!");  
                                                
dialog.Option("okay"0xff);  
                                                
dialog.Send();  
                                            }  
                                        }  
                                        else  
                                        {  
                                            
dialog.Text("Hey there " client.Entity.Name "You can only claim the prize when the time on or after xx:30");  
                                            
dialog.Option("okay"0xff);  
                                            
dialog.Send();  
                                        }  
                                        break;  
                                    }  
                            }  
                            break;  
                        }  
                    
#endregion  
                    #endregion BPower Quest by Lego 
World.cs

Html

#region BPower quest  
            
if (DateTime.Now.Hour == 18 && DateTime.Now.Minute == 00 && Now64.Second == 00)  
            {  
                
client.MessageBox("hi"+client.Entity .Name+"The BPower Quest started do u need jouin?",  
                    (
p) => { p.Entity.Teleport(1002292148); }, null);  
                  
            }  
            
#endregion  
            #region BPower cheak  
            #region BPower quest  
            
if (client.Entity.MapID == 12345)  
            {  
                if (
client.Entity.BattlePower 300 && client.Entity.BattlePower <= 350)  
                {
//by Lego  
                    
client.Entity.Teleport(123445050);  
                }  
                else  
                {  
                    if (
client.Entity.BattlePower 350 && client.Entity.BattlePower <= 385)  
                    {
//by Lego  
                        
client.Entity.Teleport(123335050);  
                    }  
                }  
            }  
            
#endregion  
            #region BPower quest  
            
if (client.Entity.MapID == 12344)  
            {  
                    if (
client.Entity.BattlePower 350 && client.Entity.BattlePower <= 385)  
                    {
//by Lego  
                        
client.Entity.Teleport(123335050);  
                }  
            }  
            
#endregion  
            #endregion 
Update.cs

Html

rygh_hglx 1UL << 174,  
                
rygh_syzs 1UL << 175 
Entity.cs

ابـحث علي

Html

public void RemoveTopStatus 
اقفلو من السالب و بدلو بالفويد ده

Html

public void RemoveTopStatus(UInt64 Title)  
        {  
            
ulong baseFlag TopStatusToInt(Title);  
            
MySqlCommand cmd = new MySqlCommand(MySqlCommandType.DELETE);  
            
cmd.Delete("status""entityid"UID).And("status"baseFlag).Execute();  
            if (
baseFlag == 31 || baseFlag == 32 || baseFlag == 33 || baseFlag == 34)  
                
RemoveFlag3((Title));  
            else if (
baseFlag == || baseFlag == 22 || baseFlag == 23 || baseFlag == 24  
                
|| baseFlag == 25 || baseFlag == 26 || baseFlag == 27 || baseFlag == 28  
                
|| baseFlag == 29 || baseFlag == 30)  
                
RemoveFlag2((Title));  
            else if (
Title == (ulong)1UL << 166 || Title == (ulong)1UL << 167 || Title == (ulong)1UL << 174 || Title == (ulong)1UL << 175)  
                
RemoveFlag3((ulong)Title);  
            else  
                
RemoveFlag(Title);  
        } 
وابحث علي

Html

public void LoadTopStatus() 
اقفلو من السالب و بدلو

Html

public void LoadTopStatus()  
        {  
            
using (MySqlCommand Command = new MySqlCommand(MySqlCommandType.SELECT))  
            {  
                
Command.Select("status").Where("entityid"UID).Execute();  
                
using (MySqlReader Reader = new MySqlReader(Command))  
                {  
                    while (
Reader.Read())  
                    {  
                        
UInt64 Title Reader.ReadUInt64("status");  
                        
DateTime Time Kernel.FromDateTimeInt(Reader.ReadUInt64("time"));  
                        if (
DateTime.Now Time)  
                            
RemoveTopStatus(Title);  
                        else  
                        {  
                            
//if (!ContainsFlag(IntToTopStatus(Title)))  

                            
if (Title == (ulong)1UL << 167 || Title == (ulong)1UL << 166 || Title == (ulong)1UL << 174 || Title == (ulong)1UL << 175)  
                            {  
                                
AddTopStatus3((ulong)TitleTimefalse);  
                            }  
                            else  
                            {  
                                
AddTopStatus(TitleTimefalse);  
                            }  
                        }  
                    }  
                }  
            }  
        } 
Navicat

Html

INSERT INTO `npcsVALUES ('95481''BPower''0002''9730''1002''0292''0146''0000');  
INSERT INTO `npcsVALUES ('95482''BPower Prize''0002''19470''12345''0120''0070''0000');  
INSERT INTO `npcsVALUES ('95483''BPower Prize''0002''19470''12344''0120''0000''0000');  
INSERT INTO `npcsVALUES ('95484''BPower Prize''0002''19470''12333''0120''0070''0000'); 

Html

INSERT INTO `mapsVALUES ('12345''1017''0007''0000');  
INSERT INTO `mapsVALUES ('12344''1017''0007''0000');  
INSERT INTO `mapsVALUES ('12333''1017''0007''0000'); 
bin/debug/database/Iteams

Html

3006840@@AverageBPToken@@0@@0@@0@@0@@0@@0@@0@@0@@9@@0@@0@@0@@0@@0@@0@@0@@0@@0@@0@@1@@1@@0@@0@@0@@0@@0@@0@@0@@0@@0@@1@@800@@0@@0@@1@@0@@0@@0@@0@@0@@0@@0@@0@@0@@0@@1@@0@@0@@0@@0@@0@@BPTournament@@A~certificate~of~championship~in~the~250-300~BP~division.~Collect~2/3/4~tokens~to~claim~a~prize~from~the~BP~Tournament~Manager.@@0@@0@@0@@0@@0@@500@@0@@0@@0@@0@@0@@  
3006841@@EliteBPToken@@0@@0@@0@@0@@0@@0@@0@@0@@9@@0@@0@@0@@0@@0@@0@@0@@0@@0@@0@@1@@1@@0@@0@@0@@0@@0@@0@@0@@0@@0@@1@@800@@0@@0@@1@@0@@0@@0@@0@@0@@0@@0@@0@@0@@0@@1@@0@@0@@0@@0@@0@@BPTournament@@A~certificate~of~championship~in~the~301-350~BP~division.~Collect~2/3/4~tokens~to~claim~a~prize~from~the~BP~Tournament~Manager.@@0@@0@@0@@0@@0@@500@@0@@0@@0@@0@@0@@  
3006842@@SuperBPToken@@0@@0@@0@@0@@0@@0@@0@@0@@9@@0@@0@@0@@0@@0@@0@@0@@0@@0@@0@@1@@1@@0@@0@@0@@0@@0@@0@@0@@0@@0@@1@@800@@0@@0@@1@@0@@0@@0@@0@@0@@0@@0@@0@@0@@0@@1@@0@@0@@0@@0@@0@@BPTournament@@A~certificate~of~championship~in~the~350+~BP~division.~Collect~2/3/4~tokens~to~claim~a~prize~from~the~BP~Tournament~Manager.@@0@@0@@0@@0@@0@@500@@0@@0@@0@@0@@0@@ 
بعديها هتخوش علي كلينت
ini/iteamtype
فك تشفيره وضيف دول

Html

3006840@@AverageBPToken@@0@@0@@0@@0@@0@@0@@0@@0@@9@@0@@0@@0@@0@@0@@0@@0@@0@@0@@0@@1@@1@@0@@0@@0@@0@@0@@0@@0@@0@@0@@1@@800@@0@@0@@1@@0@@0@@0@@0@@0@@0@@0@@0@@0@@0@@1@@0@@0@@0@@0@@0@@BPTournament@@A~certificate~of~championship~in~the~250-300~BP~division.~Collect~2/3/4~tokens~to~claim~a~prize~from~the~BP~Tournament~Manager.@@0@@0@@0@@0@@0@@500@@0@@0@@0@@0@@0@@  
3006841@@EliteBPToken@@0@@0@@0@@0@@0@@0@@0@@0@@9@@0@@0@@0@@0@@0@@0@@0@@0@@0@@0@@1@@1@@0@@0@@0@@0@@0@@0@@0@@0@@0@@1@@800@@0@@0@@1@@0@@0@@0@@0@@0@@0@@0@@0@@0@@0@@1@@0@@0@@0@@0@@0@@BPTournament@@A~certificate~of~championship~in~the~301-350~BP~division.~Collect~2/3/4~tokens~to~claim~a~prize~from~the~BP~Tournament~Manager.@@0@@0@@0@@0@@0@@500@@0@@0@@0@@0@@0@@  
3006842@@SuperBPToken@@0@@0@@0@@0@@0@@0@@0@@0@@9@@0@@0@@0@@0@@0@@0@@0@@0@@0@@0@@1@@1@@0@@0@@ 
ani/ItemMinIcon

Html

[Item3006840]  
FrameAmount=1  
Frame0
=data/ItemMinIcon/741820.dds  

[Item3006841]  
FrameAmount=1  
Frame0
=data/ItemMinIcon/741819.dds  

[Item3006842]  
FrameAmount=1  
Frame0
=data/ItemMinIcon/741818.dds