[Release]SaveHalos

02/03/2010 03:59 Arcо#46
Quote:
Originally Posted by glover View Post
Hi everyone.
A simple source code without using a new file for TopGuilds, it's already added into this source ^^
at database.cs in function LoadCharacter()
You can add it Under this:
Code:
                    C.Loaded = true;
Code:
                    if (C.MyGuild == Features.GuildWars.LastWinner && (C.GuildRank == NewestCOServer.Features.GuildRank.GuildLeader))
                        C.StatEff.Add(StatusEffectEn.TopGuildLeader);
                    if (C.MyGuild == Features.GuildWars.LastWinner && (C.GuildRank == NewestCOServer.Features.GuildRank.DeputyManager))
                            C.StatEff.Add(StatusEffectEn.TopDeputyLeader);
For other effects you need only add next feature ranking.
If you got error on: StatusEffectEn try to add reference.
But for this wouldn't you also need to do something for each save character and create character void?
02/03/2010 15:04 glover#47
Quote:
Originally Posted by .Arco View Post
But for this wouldn't you also need to do something for each save character and create character void?
No you do not need. this stats is loaded when character has login and automatically got this stats once for all deputy Leaders and Guild Leader. source 5165 automatically saving GuildWars structure.
If other guild will win second GW old GL, DL's Still got this effect.
I must write new source code in function endgw for delete this effect on old winner characters or this will be disapear when old winner got relog:-)
02/05/2010 04:19 maximumbrutal#48
where to put this code?
at the chat.cs? please reply real quick
Code:
 #region GWArenaNPC
                            case 380:
                                {
                                    if (Linkback == 0)
                                    {
                                        GC.AddSend(Packets.NPCSay("Do you want enter the guild arena?"));
                                        GC.AddSend(Packets.NPCLink("Yes.", 1));
                                        GC.AddSend(Packets.NPCLink("I am the winning Guild Leader!", 2));
                                        GC.AddSend(Packets.NPCLink("But I'm a Deputy Leader and I want the Deputy Leader Halo.", 3));
                                        GC.AddSend(Packets.NPCLink("Just passing by.", 255));
                                        GC.AddSend(Packets.NPCSetFace(N.Avatar));
                                        GC.AddSend(Packets.NPCFinish());
                                    }
                                    else if (Linkback == 1)
                                    {
                                        GC.MyChar.Teleport(1038, 350, 350);
                                    }
                                    else if (Linkback == 2)
                                    {
                                        if (GC.MyChar.MyGuild == Features.GuildWars.LastWinner && (GC.MyChar.GuildRank == NewestCOServer.Features.GuildRank.GuildLeader))
                                        {

                                            GC.MyChar.CPs += 4500;
                                            World.SendMsgToAll("SYSTEM", GC.MyChar.Name + " has claimed 4500 CPs and the TopGuildLeader Halo for winning GuildWar!", 2011, 0);

                                            GC.MyChar.StatEff.Add(StatusEffectEn.TopGuildLeader); 
                                            try
                                            {
                                                StreamWriter sw = new StreamWriter("C:\\OldCODB/Tops/TopLeader.txt");
                                                sw.WriteLine("" + GC.MyChar.EntityID + "#17179869184");
                                                sw.Close();
                                            }
                                            catch (Exception e)
                                            {
                                                Console.WriteLine(e.Message);
                                            }
                                        }
                                        else
                                        {
                                            GC.AddSend(Packets.NPCSay("You already claimed your 4500 cps! Get out of here!"));
                                            GC.AddSend(Packets.NPCLink("Sorry", 255));
                                            GC.AddSend(Packets.NPCSetFace(N.Avatar));
                                            GC.AddSend(Packets.NPCFinish());
                                        }
                                    }
                                    else
                                    {
                                        GC.AddSend(Packets.NPCSay("You are not in the Top Guild!"));
                                        GC.AddSend(Packets.NPCLink("Oh sorry", 255));
                                        GC.AddSend(Packets.NPCSetFace(30));
                                        GC.AddSend(Packets.NPCFinish());
                                    }

                                    if (Linkback == 3)
                                    {
                                        if (GC.MyChar.MyGuild == Features.GuildWars.LastWinner && (GC.MyChar.GuildRank == NewestCOServer.Features.GuildRank.DeputyManager))
                                        {
                                            World.SendMsgToAll("SYSTEM", GC.MyChar.Name + " has claimed the TopDeputyLeader Halo!", 2011, 0);
                                            GC.MyChar.StatEff.Add(StatusEffectEn.TopDeputyLeader);
                                            try
                                            {
                                                // Now it should work 100%
                                                StreamWriter sw = new StreamWriter("C:\\OldCODB/Tops/TopDeputy.txt");
                                                sw.WriteLine("" + GC.MyChar.EntityID + "#34359738368");
                                                sw.Close();
                                            }
                                            catch (Exception e)
                                            {
                                                Console.WriteLine(e.Message);
                                            }
                                        }
                                        else
                                        {
                                            GC.AddSend(Packets.NPCSay("You are not in the Top Guild!"));
                                            GC.AddSend(Packets.NPCLink("Oh sorry", 255));
                                            GC.AddSend(Packets.NPCSetFace(30));
                                            GC.AddSend(Packets.NPCFinish());
                                        }
                                    }
                                    break;
                                }
                                    
                                
                            #endregion
02/05/2010 07:28 Arcо#49
considering its an npc.....
npcdialog.cs
03/01/2010 02:49 ztcjsa#50
The NPC doesent work for me :( Im getting an error concerning the link back??
03/01/2010 02:50 Arcо#51
Quote:
Originally Posted by ztcjsa View Post
The NPC doesent work for me :( Im getting an error concerning the link back??
Change Linkback -> Control
03/01/2010 02:52 Decker_#52
You need to update thread.
03/01/2010 02:53 Arcо#53
Quote:
Originally Posted by Decker_ View Post
You need to update thread.
No I don't.
03/01/2010 04:38 Secrets-man#54
Well, works perfectly for me. =] Just changed Linkback to Control and bam ^^
03/16/2010 18:57 xI NiNJA DuCKey#55
Rite i've added this to ma test source...
So under every save halo 'Give' should i put
Code:
try
{
StreamWriter sw = new StreamWriter("C:\\OldCODB/Tops/TopLeader.txt");
sw.WriteLine("" + GC.MyChar.EntityID + "#17179869184");
sw.Close();
}
catch (Exception e)
{
Console.WriteLine(e.Message);
}
}
03/16/2010 19:04 Arcо#56
Quote:
Originally Posted by xI NiNJA DuCKey View Post
Rite i've added this to ma test source...
So under every save halo 'Give' should i put
Code:
try
{
StreamWriter sw = new StreamWriter("C:\\OldCODB/Tops/TopLeader.txt");
sw.WriteLine("" + GC.MyChar.EntityID + "#17179869184");
sw.Close();
}
catch (Exception e)
{
Console.WriteLine(e.Message);
}
}
And change the number to the enum of that skill.
03/17/2010 08:36 xI NiNJA DuCKey#57
Thanks.

Kinda off topic but i almost got a screenshot of 1337 Thanks on ur profile but it was 1338 :(
07/13/2010 02:23 .Beatz#58
Quote:
Originally Posted by -Java- View Post
i done evrtying right but no save when relog...here npc i use
Copy and paste his GWArenaNPC then change "Linkback" to "Control" and it will work fine.
07/13/2010 02:54 .Beatz#59
Quote:
Originally Posted by -Java- View Post
i dusnt wann copy i want use own npc
The amount of help you want of people is rediculous. Here is a hint if you want to make your own NPC for it. Copy and past .Arco's NPC then change the parts that you want to change. Dont mess with the parts you know nothing about.
07/13/2010 02:58 .Beatz#60
Quote:
Originally Posted by -Java- View Post
okay i fixed but i need numbers for it

sw.WriteLine("" + GC.MyChar.EntityID + "#17179869184");

someone plz ty
Every single number you need .Arco has released! It is on the very first post if you read you will see it.