Register for your free account! | Forgot your password?

You last visited: Today at 10:56

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

Advertisement



[HELP]Guildwar Prize

Discussion on [HELP]Guildwar Prize within the CO2 Private Server forum part of the Conquer Online 2 category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Nov 2011
Posts: 84
Received Thanks: 1
[HELP]Guildwar Prize

Hey guys , I have another problem of mine.
Can anyone help me again ?
The NPC on game won't work. I already put the correct NPC ID. |
I wonder if there`s any problem in the code given below.

Code:
                            #region ClaimGuildPrize
                            case 4482114:
                                {
                                    switch (npcRequest.OptionID)
                                    {
                                        case 0:
                                            {
                                                dialog.Text("Hello there. Do you want to Claim GuildWar Prize you can only Claim it 1 Time if you won GW.");
                                                dialog.Option("Leme Claim.", 1);
                                                dialog.Option("Claim TopDeputyLeader.", 3);
                                                dialog.Option("Just Passing By!", 255);
                                                dialog.Send();
                                                break;
                                            }
                                        case 1:
                                            {
                                                if (client.Guild != null)
                                                {
                                                    if (client.Guild.PoleKeeper && client.Guild != null && client.AsMember.Rank == Conquer_Online_Server.Game.Enums.GuildMemberRank.GuildLeader)
                                                    {
                                                        dialog.Text("Are you sure you want to Claim your Prize?");
                                                        dialog.Option("Yes.", 2);
                                                        dialog.Option("Ah, nevermind.", 255);
                                                        dialog.Send();
                                                    }
                                                    else
                                                    {
                                                        dialog.Text("Sorry only GuildLeader of the Winner Guild can Claim The Prize After GuildWar End.");
                                                        dialog.Option("Ahh.", 255);
                                                        dialog.Send();
                                                    }
                                                }
                                                else
                                                {
                                                    dialog.Text("Sorry You are not Member in any guild yet");
                                                    dialog.Option("Ahh.", 255);
                                                    dialog.Send();
                                                }
                                                break;
                                            }
                                        case 2:
                                            {
                                                if (DateTime.Now.Hour >= Game.SezaREvents.GWEEndHour && DateTime.Now.Hour < (Game.SezaREvents.GWEEndHour + 1) && DateTime.Now.DayOfWeek == DayOfWeek.Sunday && client.Guild.PoleKeeper && client.Guild != null && client.AsMember.Rank == Conquer_Online_Server.Game.Enums.GuildMemberRank.GuildLeader && ClassPk.TopGlClaim == 0)
                                                {
                                                    client.Entity.ConquerPoints += Conquer_Online_Server.Database.rates.GuildWar;
                                                    ClassPk.AddGl();
                                                    client.Inventory.Add(723467, 0, 1);
                                                    Game.Flags.AddGuildLeader(client);
                                                    client.Entity.AddFlag(Update.Flags.TopGuildLeader);
                                                    Conquer_Online_Server.ServerBase.Kernel.SendWorldMessage(new Message("Congratulations! " + client.Entity.Name + " Leader of " + client.Guild.PoleKeeper + " The winner guild has Claimed Guild War Prize " + Conquer_Online_Server.Database.rates.GuildWar + " cps and LordToken!", System.Drawing.Color.White, Message.TopLeft), Conquer_Online_Server.ServerBase.Kernel.GamePool.Values);
                                                }
                                                else
                                                {
                                                    dialog.Text("Sorry you dont have Any Prize to claim only GL of the winner guild can claim Prize After GW");
                                                    dialog.Option("Ahh.", 255);
                                                    dialog.Send();
                                                }
                                                break;
                                            }
                                        case 3:
                                            {
                                                if (client.Guild != null)
                                                {
                                                    if (client.Guild.PoleKeeper && client.Guild != null && client.AsMember.Rank == Conquer_Online_Server.Game.Enums.GuildMemberRank.DeputyLeader)
                                                    {
                                                        dialog.Text("Are you sure you want to Claim your Prize?");
                                                        dialog.Option("Yes.", 4);
                                                        dialog.Option("Ah, nevermind.", 255);
                                                        dialog.Send();
                                                    }
                                                    else
                                                    {
                                                        dialog.Text("Sorry only DeputyLeader of the Winner Guild can Claim The Prize After GuildWar End.");
                                                        dialog.Option("Ahh.", 255);
                                                        dialog.Send();
                                                    }

                                                }
                                                else
                                                {
                                                    dialog.Text("Sorry You are not Member in any guild yet");
                                                    dialog.Option("Ahh.", 255);
                                                    dialog.Send();
                                                }
                                                break;
                                            }
                                        case 4:
                                            {
                                                if (!client.Entity.ContainsFlag(Update.Flags.TopDeputyLeader))
                                                {
                                                    if (DateTime.Now.Hour >= Game.SezaREvents.GWEEndHour && DateTime.Now.Hour < (Game.SezaREvents.GWEEndHour + 1) && DateTime.Now.DayOfWeek == DayOfWeek.Sunday && client.Guild.PoleKeeper && client.Guild != null && client.AsMember.Rank == Conquer_Online_Server.Game.Enums.GuildMemberRank.DeputyLeader && ClassPk.TopDlClaim < 5)
                                                    {
                                                        ClassPk.AddDl();
                                                        client.Entity.AddFlag(Update.Flags.TopDeputyLeader);
                                                        Conquer_Online_Server.ServerBase.Kernel.SendWorldMessage(new Message("Congratulations! " + client.Entity.Name + " From " + client.Guild.PoleKeeper + " Has Claimed TopDeputyLeader Halo!", System.Drawing.Color.White, Message.TopLeft), Conquer_Online_Server.ServerBase.Kernel.GamePool.Values);
                                                        if (ClassPk.TopDlClaim == 1)
                                                        {
                                                            Game.Flags.AddGuildDeaputy(client);
                                                        }
                                                        if (ClassPk.TopDlClaim == 2)
                                                        {
                                                            Game.Flags.AddGuildDeaputy2(client);
                                                        }
                                                        if (ClassPk.TopDlClaim == 3)
                                                        {
                                                            Game.Flags.AddGuildDeaputy3(client);
                                                        }
                                                        if (ClassPk.TopDlClaim == 4)
                                                        {
                                                            Game.Flags.AddGuildDeaputy4(client);
                                                        }
                                                        if (ClassPk.TopDlClaim == 5)
                                                        {
                                                            Game.Flags.AddGuildDeaputy5(client);
                                                        }
                                                    }
                                                    else
                                                    {
                                                        dialog.Text("Sorry you dont have Any Prize to claim only Dl of the Winner Guild Can claim the halo After GW end.");
                                                        dialog.Option("Ahh.", 255);
                                                        dialog.Send();
                                                    }
                                                    break;
                                                }
                                                else
                                                {
                                                    dialog.Text("Sorry you already have top DeaputyLeader come next time ;).");
                                                    dialog.Option("Ahh.", 255);
                                                    dialog.Send();
                                                }
                                                break;
                                            }
                                    }
                                    break;
                                }
                            #endregion
akosicamar2 is offline  
Old 02/05/2014, 03:02   #2
 
elite*gold: 0
Join Date: Feb 2006
Posts: 726
Received Thanks: 271
Well for starters you are going to have to stop making a thread for every single problem you encounter.
Im sorry but our job is not to fix every little bug you come across.

Secondly, just saying "it doesnt work" doesn't really help us help you.
Do you get any error messages?
Does the server say anything?
Does the NPC say anything at all?

Have you compared this code to another NPCs code to make sure you aren't missing a function call?
Are you positive the NPC ID is exactly the same? (Its awfully long too).

Lastly, judging from the code, you can only claim the reward on a sunday one hour after GW has ended.
Also, your null checks should be the first thing you check for, not something in the middle. Otherwise if it is null, it will throw an exception before you even check for it.
Aceking is offline  
Thanks
1 User
Old 02/05/2014, 10:01   #3
 
elite*gold: 0
Join Date: Nov 2011
Posts: 84
Received Thanks: 1
Quote:
Originally Posted by Aceking View Post
Well for starters you are going to have to stop making a thread for every single problem you encounter.
Im sorry but our job is not to fix every little bug you come across.

Secondly, just saying "it doesnt work" doesn't really help us help you.
Do you get any error messages?
Does the server say anything?
Does the NPC say anything at all?

Have you compared this code to another NPCs code to make sure you aren't missing a function call?
Are you positive the NPC ID is exactly the same? (Its awfully long too).

Lastly, judging from the code, you can only claim the reward on a sunday one hour after GW has ended.
Also, your null checks should be the first thing you check for, not something in the middle. Otherwise if it is null, it will throw an exception before you even check for it.
No error Message even the NPC can't even talk I don't know why Please help me for the sake of my server. I will be really thankful to you if you help me.

bump !

bump !
akosicamar2 is offline  
Reply


Similar Threads Similar Threads
guildwar prize npc
04/13/2013 - CO2 Private Server - 2 Replies
i just want to fix this npc it doesn't give any body any halos or cps please reply me fast
now get your prize
11/11/2012 - Conquer Online 2 - 2 Replies
Sweet Home Cp Giveaway Requirements Rewards Players who have registered for less than a year. 215 CPs(Bound) Players who have registered for 1 year and above. 430 CPs(Bound) Players who have registered for 2 years and above. 645 CPs(Bound) Players who have registered for 3 years and above. 860 CPs(Bound) Players who have registered for 4 years and above. 1075 CPs(Bound) Players who have registered for 5 years and above. 1290 CPs(Bound) Players who have registered for 6 years...
Play can copy the name of the Guildwar At least two For name Took the award for Prize
08/17/2011 - CO2 Private Server - 0 Replies
plese help its for Source 5375 see The Guild name Is nova see pictuer Two names at the same time 1:http://imageshack.us/photo/my-images/850/160627 22.jpg/ plese help my serve is ShutDown please all my server is Shutdown
Prize
09/27/2010 - Archlord - 2 Replies
Hey i recently went to the store to get my Ukash vouches so i can buy Wcoin but when ever i put my code in and the amount i want i click continue and it says payment failed and its been doing this for a while how to fix? If you can help il give you a scroll.



All times are GMT +1. The time now is 10:57.


Powered by vBulletin®
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2026 elitepvpers All Rights Reserved.