|
You last visited: Today at 23:41
Advertisement
[Release]SaveHalos
Discussion on [Release]SaveHalos within the CO2 PServer Guides & Releases forum part of the CO2 Private Server category.
02/03/2010, 03:59
|
#46
|
elite*gold: 0
Join Date: Oct 2009
Posts: 8,783
Received Thanks: 5,304
|
Quote:
Originally Posted by glover
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:
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
|
#47
|
elite*gold: 0
Join Date: Mar 2006
Posts: 61
Received Thanks: 88
|
Quote:
Originally Posted by .Arco
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
|
#48
|
elite*gold: 0
Join Date: Feb 2010
Posts: 6
Received Thanks: 0
|
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
|
#49
|
elite*gold: 0
Join Date: Oct 2009
Posts: 8,783
Received Thanks: 5,304
|
considering its an npc.....
npcdialog.cs
|
|
|
03/01/2010, 02:49
|
#50
|
elite*gold: 0
Join Date: Feb 2007
Posts: 26
Received Thanks: 0
|
The NPC doesent work for me  Im getting an error concerning the link back??
|
|
|
03/01/2010, 02:50
|
#51
|
elite*gold: 0
Join Date: Oct 2009
Posts: 8,783
Received Thanks: 5,304
|
Quote:
Originally Posted by ztcjsa
The NPC doesent work for me  Im getting an error concerning the link back??
|
Change Linkback -> Control
|
|
|
03/01/2010, 02:52
|
#52
|
elite*gold: 0
Join Date: Feb 2010
Posts: 480
Received Thanks: 207
|
You need to update thread.
|
|
|
03/01/2010, 02:53
|
#53
|
elite*gold: 0
Join Date: Oct 2009
Posts: 8,783
Received Thanks: 5,304
|
Quote:
Originally Posted by Decker_
You need to update thread.
|
No I don't.
|
|
|
03/01/2010, 04:38
|
#54
|
elite*gold: 0
Join Date: Apr 2007
Posts: 142
Received Thanks: 15
|
Well, works perfectly for me. =] Just changed Linkback to Control and bam ^^
|
|
|
03/16/2010, 18:57
|
#55
|
elite*gold: 0
Join Date: Mar 2010
Posts: 51
Received Thanks: 17
|
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
|
#56
|
elite*gold: 0
Join Date: Oct 2009
Posts: 8,783
Received Thanks: 5,304
|
Quote:
Originally Posted by xI NiNJA DuCKey
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
|
#57
|
elite*gold: 0
Join Date: Mar 2010
Posts: 51
Received Thanks: 17
|
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
|
#58
|
elite*gold: 0
Join Date: May 2006
Posts: 1,190
Received Thanks: 516
|
Quote:
Originally Posted by -Java-
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
|
#59
|
elite*gold: 0
Join Date: May 2006
Posts: 1,190
Received Thanks: 516
|
Quote:
Originally Posted by -Java-
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
|
#60
|
elite*gold: 0
Join Date: May 2006
Posts: 1,190
Received Thanks: 516
|
Quote:
Originally Posted by -Java-
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.
|
|
|
All times are GMT +1. The time now is 23:42.
|
|