احصائياتى

الردود
0

المشاهدات
22
 
Hazem
.:: المدير العام::.

    متواجد  الان

المشاركات
2,308

+التقييم
0.84

تاريخ التسجيل
Apr 2019

الاقامة
Egypt

نظام التشغيل
windows 7

رقم العضوية
1
2021-08-16, 03:10 PM
المشاركة 1
2021-08-16, 03:10 PM
المشاركة 1
افتراضي NPC Proficiency


ان بي سي Proficiency لنجوم الاسلحه


كود:
#region Proficiency 
                            
case 9401:            
                                { 
                                    switch (
npcRequest.OptionID) 
                                    { 
                                        case 
0: 
                                            { 
                                                
dialog.Text("Hello my friend. If you believe that, leveling your proficiency is too hard and takes too much time, I can help you. In exchange of a fixed amount of exp balls, I will agree to level up your proficiency."); 
                                                
dialog.Text("Now, tell me what proficiency you want to level up."); 
                                                
dialog.Option("One handed.", 1); 
                                                
dialog.Option("Two handed.", 3); 
                                                
dialog.Option("Other.", 5); 
                                                
dialog.Option("I'll just leave", 255); 
                                                
dialog.Send(); 
                                                break; 
                                            } 
                                        case 
1: 
                                            { 
                                                
dialog.Text("Which one handed proficiency?"); 
                                                
dialog.Option("Blade.", 41); 
                                                
dialog.Option("Sword.", 42); 
                                                
dialog.Option("Hook.", 43); 
                                                
dialog.Option("Whip.", 44); 
                                                
dialog.Option("Axe.", 45); 
                                                
dialog.Option("Next page.", 2); 
                                                
dialog.Option("Nothing, sorry.", 255); 
                                                
dialog.Send(); 
                                                break; 
                                            } 
                                        case 
2: 
                                            { 
                                                
dialog.Text("Which one handed proficiency?"); 
                                                
dialog.Option("PrayerBead.", 61); 
                                                
dialog.Option("Hammer.", 46); 
                                                
dialog.Option("Club.", 48); 
                                                
dialog.Option("Scepter.", 184); 
                                                
dialog.Option("Katana.", 60); 
                                                
dialog.Option("Next Page.", 6); 
                                                
dialog.Option("Back.", 1); 
                                                
dialog.Option("Nothing, sorry.", 255); 
                                                
dialog.Send(); 
                                                break; 
                                            } 
                                        case 
6: 
                                            { 
                                                
dialog.Text("Which one handed proficiency?"); 
                                                
dialog.Option("Axe.", 45); 
                                                
dialog.Option("Rapier.", 62); 
                                                
dialog.Option("Pistol.", 63); 
                                                
dialog.Option("Back.", 2); 
                                                
dialog.Send(); 
                                                break; 
                                            } 
                                        case 
3: 
                                            { 
                                                
dialog.Text("Which two handed proficiency?"); 
                                                
dialog.Option("Backsword.", 124); 
                                                
dialog.Option("Glaive.", 51); 
                                                
dialog.Option("Poleaxe.", 53); 
                                                
dialog.Option("LongHammer.", 54); 
                                                
dialog.Option("Spear.", 56); 
                                                
dialog.Option("Next page.", 4); 
                                                
dialog.Option("Nothing, sorry.", 255); 
                                                
dialog.Send(); 
                                                break; 
                                            } 
                                        case 
4: 
                                            { 
                                                
dialog.Text("Which one handed proficiency?"); 
                                                
dialog.Option("Pickaxe.", 142); 
                                                
dialog.Option("Halberd.", 58); 
                                                
dialog.Option("Wand.", 165); 
                                                
dialog.Option("Bow.", 50); 
                                                
dialog.Option("Back.", 3); 
                                                
dialog.Option("Nothing, sorry.", 255); 
                                                
dialog.Send(); 
                                                break; 
                                            } 
                                        case 
5: 
                                            { 
                                                
dialog.Text("Which one handed proficiency?"); 
                                                
dialog.Option("Boxing.", 254); 
                                                
dialog.Option("Shield.", 90); 
                                                
dialog.Option("Nothing, sorry.", 255); 
                                                
dialog.Send(); 
                                                break; 
                                            } 
                                        case 
100: 
                                            { 
                                                if (
client.Proficiencies.ContainsKey(client.UplevelProficiency)) 
                                                { 
                                                    var 
prof = client.Proficiencies[client.UplevelProficiency]; 
                                                    if (
prof.Level >= 12) 
                                                    { 
                                                        
dialog.Text("This proficiency cannot be leveled up anymore."); 
                                                        
dialog.Option("Oh.", 255); 
                                                        
dialog.Send(); 
                                                        break; 
                                                    } 
                                                    
client.UplevelProficiency = 0; 
                                                    if (
client.Inventory.Contains(723700, prof.Level)) 
                                                    { 
                                                        
client.Inventory.Remove(723700, prof.Level); 
                                                        
prof.Level++; 
                                                        
prof.Experience = 0; 
                                                        
prof.Send(client); 
                                                        break; 
                                                    } 
                                                    
dialog.Text("You don't have the requiered exp balls, I'm sorry I cannot help you."); 
                                                    
dialog.Option("It's alright.", 255); 
                                                    
dialog.Send(); 
                                                    break; 
                                                } 
                                                else 
                                                { 
                                                    
dialog.Text("You don't know this proficiency."); 
                                                    
dialog.Option("Ahh, sorry.", 255); 
                                                    
dialog.Send(); 
                                                    break; 
                                                } 
                                            } 
                                        default: 
                                            { 
                                                if (
npcRequest.OptionID == 255) 
                                                    return; 
                                                
ushort proficiency = 0; 
                                                if (
npcRequest.OptionID == 62) 
                                                { 
                                                    
proficiency = 611; 
                                                } 
                                                else if (
npcRequest.OptionID == 63) 
                                                { 
                                                    
proficiency = 612; 
                                                } 
                                                else if (
npcRequest.OptionID < 100) 
                                                    
proficiency = (ushort)(npcRequest.OptionID * 10); 
                                                else 
                                                { 
                                                    if (
npcRequest.OptionID != 254) 
                                                    { 
                                                        
string off = npcRequest.OptionID.ToString(); 
                                                        
string reverse = off[2].ToString() + off[1].ToString() + off[0].ToString(); 
                                                        
proficiency = ushort.Parse(reverse); 
                                                    } 
                                                } 
                                                if (
proficiency == 600) proficiency++; 
                                                if (
client.Proficiencies.ContainsKey(proficiency)) 
                                                { 
                                                    var 
prof = client.Proficiencies[proficiency]; 
                                                    if (
prof.Level >= 12) 
                                                    { 
                                                        
dialog.Text("This proficiency cannot be leveled up anymore."); 
                                                        
dialog.Option("Oh.", 255); 
                                                        
dialog.Send(); 
                                                        break; 
                                                    } 
                                                    
client.UplevelProficiency = proficiency; 
                                                    
dialog.Text("I need " + prof.Level + " exp balls to be able to level up this proficiency."); 
                                                    
dialog.Option("Let's do it then.", 100); 
                                                    
dialog.Option("No, sorry.", 255); 
                                                    
dialog.Send(); 
                                                    break; 
                                                } 
                                                else 
                                                { 
                                                    
dialog.Text("You don't know this proficiency."); 
                                                    
dialog.Option("Ahh, sorry.", 255); 
                                                    
dialog.Send(); 
                                                    break; 
                                                } 
                                            } 
                                    } 
                                    break; 
                                } 
                            
#endregion 




العلامات المرجعية



الذين يشاهدون محتوى الموضوع الآن : 1 ( الأعضاء 0 والزوار 1)
 

الانتقال السريع



الساعة الآن 08:09 PM