Zitat von Nydn;61879[FONT="Arial"][COLOR="Teal"][SIZE="2"]Thanks for that nice Thread,
i will try it ^^[/SIZE][/COLOR][/FONT]
[FONT="Fixedsys"][COLOR="DarkOrchid"]
Thanks, need any help and I'll be glad to assist![/COLOR][/FONT]
Zitat von Nydn;61879[FONT="Arial"][COLOR="Teal"][SIZE="2"]Thanks for that nice Thread,
i will try it ^^[/SIZE][/COLOR][/FONT]
[FONT="Fixedsys"][COLOR="DarkOrchid"]
Thanks, need any help and I'll be glad to assist![/COLOR][/FONT]
[FONT="Fixedsys"][COLOR="DarkOrchid"]Go to compose.cs and search for[/COLOR][/FONT]
[FONT="Fixedsys"][COLOR="DarkOrchid"]
Replace that entire void with this:[/COLOR][/FONT]
if (MainI.ID != 0 && MinorI.ID != 0 && MainI.Plus <= 11)
{
uint Progress = MainI.Progress;
Progress += Database.StonePts[MinorI.Plus];
GC.MyChar.RemoveItem(MinorI);
GC.MyChar.RemoveItem(MainI);
while (Progress >= Database.ComposePts[MainI.Plus] && MainI.Plus <= 11)
{
Progress -= Database.ComposePts[MainI.Plus];
MainI.Plus++;
}
if (MainI.Plus == 12)
Progress = 0;
MainI.Progress = (ushort)Progress;
GC.MyChar.AddItem(MainI);
GC.MyChar.RemoveItem(MinorI);
}
Alles anzeigen
[COLOR="DarkOrchid"][FONT="Fixedsys"]Then go to database.cs and search for[/FONT][/COLOR]
public static ushort[] ComposePts = new ushort[12] { 20, 20, 80, 240, 720, 2160, 6480, 19440, 58320, 2700, 5500, 9000 };
[COLOR="DarkOrchid"][FONT="Fixedsys"]
And replace that with[/FONT][/COLOR]
public static ushort[] ComposePts = new ushort[13] { 20, 20, 80, 240, 720, 2160, 6480, 19440, 58320, 2700, 5500, 9000, 29160 };
[COLOR="DarkOrchid"][FONT="Fixedsys"]There you go.
Fixed composition.[/FONT][/COLOR]
[FONT="Fixedsys"][COLOR="DarkOrchid"]I made this thread for people who have problems with the 5165 source that just recently became public.
First here's how's you set it up.
Download it from here.
And the client from here.
Open the folder, for me its Fixed Source.
Place the folder OldCODB in your C:/ drive.
Then you open OldCODB.
Then in OldCODB open up config.ini.
Edit config.ini to your settings.
Then go to your sources debug folder, for me its Fixed Source\rikardo updated\bin\Debug and double click NewestCOServer.exe.
And when the Cmd prompt opens up type in
For example:

Then login with that account and you're good to go.
If you have any problems with the 5165 source post them here. I will try my hardest to help with these problems and if anyone knows any solutions to problems post them here as well.
EDIT:There is a certain way to do that /item command in case you don't know.
It's like this:
The item name needs to be spelled entirely correct.
Meaning capital letters and all.
The quality needs to be right after but lowercased.
Hope this helps.[/COLOR][/FONT]
Problems:Expball:Unlimited Times a day.
#region ExpBall
case 723700://This is for the expball 10 Times a day. This code makes it so you can use it as many times as you want. Replace your old expball code with this one.
{
if (Level < 137)
{
IncreaseExp(ExpBallExp, false);
RemoveItem(I);
}
else
{
MyClient.LocalMessage(2000, "You are already the highest level.");
}
break;
}
#endregion
Alles anzeigen
Pots:Now cannot be used when MP/HP is already full.
#region MP Pots//Replace your entire potion code with mine.
case 1001000:
{
if (CurMP <= MaxMP)
{
CurMP += 70;
RemoveItem(I);
}
else
{
MyClient.LocalMessage(2005, "You MP is currently full.");
}
break;
}
case 1001010:
{
if (CurMP <= MaxMP)
{
CurMP += 200;
RemoveItem(I);
}
else
{
MyClient.LocalMessage(2005, "You MP is currently full.");
}
break;
}
case 1001020:
{
if (CurMP <= MaxMP)
{
CurMP += 450;
RemoveItem(I);
}
else
{
MyClient.LocalMessage(2005, "You MP is currently full.");
}
break;
}
case 1001030:
{
if (CurMP <= MaxMP)
{
CurMP += 1000;
RemoveItem(I);
}
else
{
MyClient.LocalMessage(2005, "You MP is currently full.");
}
break;
}
case 1001040:
{
if (CurMP <= MaxMP)
{
CurMP += 2000;
RemoveItem(I);
}
else
{
MyClient.LocalMessage(2005, "You MP is currently full.");
}
}
break;
case 1002030:
{
if (CurMP <= MaxMP)
{
CurMP += 3000;
RemoveItem(I);
}
else
{
MyClient.LocalMessage(2005, "You MP is currently full.");
}
break;
}
case 1002040:
{
if (CurMP <= MaxMP)
{
CurMP += 4500;
RemoveItem(I);
}
else
{
MyClient.LocalMessage(2005, "You MP is currently full.");
}
break;
}
#endregion
#region HP Pots
case 1000000:
{
if (CurHP <= MaxHP)
{
CurHP += 70;
RemoveItem(I);
}
else
{
MyClient.LocalMessage(2005, "You HP is currently full.");
}
break;
}
case 1000010:
{
if (CurHP <= MaxHP)
{
CurHP += 150;
RemoveItem(I);
}
else
{
MyClient.LocalMessage(2005, "You HP is currently full.");
}
break;
}
case 1000020:
{
if (CurHP <= MaxHP)
{
CurHP += 250;
RemoveItem(I);
}
else
{
MyClient.LocalMessage(2005, "You HP is currently full.");
}
break;
}
case 1000030:
{
if (CurHP <= MaxHP)
{
CurHP += 500;
RemoveItem(I);
}
else
{
MyClient.LocalMessage(2005, "You HP is currently full.");
}
break;
}
case 1002000:
{
if (CurHP <= MaxHP)
{
CurHP += 800;
RemoveItem(I);
}
else
{
MyClient.LocalMessage(2005, "You HP is currently full.");
}
break;
}
case 1002010:
{
if (CurHP <= MaxHP)
{
CurHP += 1200;
RemoveItem(I);
}
else
{
MyClient.LocalMessage(2005, "You HP is currently full.");
}
break;
}
case 1002020:
{
if (CurHP <= MaxHP)
{
CurHP += 2000;
RemoveItem(I);
}
else
{
MyClient.LocalMessage(2005, "You HP is currently full.");
}
break;
}
case 1002050:
{
if (CurHP <= MaxHP)
{
CurHP +=3000;
RemoveItem(I);
}
else
{
MyClient.LocalMessage(2005, "You HP is currently full.");
}
break;
}
#endregion
Alles anzeigen
Ladyluck:With this code you can do the lottery unlimited times.
case 923:
{
if (Control == 0)
{
GC.AddSend(Packets.NPCSay(("Welcome to the Lottery Center! There are meny LuckyBoxes which have innumerable treasure such as super gems,two-socket gears, up to 500,000,000 silvers etc. in them. If you are level 70 or above, you are allowed to enter the Lottery Center as much as you want.")));
GC.AddSend(Packets.NPCSay(("And I charge you only 27 CPs for each admission.Come on, Try your luck right now!")));
GC.AddSend(Packets.NPCLink("Wow, good deal!", 1));
GC.AddSend(Packets.NPCLink("May I know the rules first?", 2));
GC.AddSend(Packets.NPCLink("No Thanks!", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
else if (Control == 1)
{
if (GC.MyChar.Lottery)
{
GC.MyChar.Teleport(700, 40, 50);
return;
}
if (GC.MyChar.Level >= 70)
{
if (GC.MyChar.Inventory.Count < 40)
{
if (GC.MyChar.CPs >= 27)
{
GC.MyChar.Teleport(700, 40, 50);
GC.MyChar.CPs -= 27;
GC.MyChar.Lottery = true;
}
else
{
GC.AddSend(Packets.NPCSay("I'm sorry you do not have the required CPs."));
GC.AddSend(Packets.NPCLink("Okay, I will be back when I have 27 CPs.", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
}
else
{
GC.AddSend(Packets.NPCSay("Please make some room in your item box first."));
GC.AddSend(Packets.NPCLink("Okay...", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
}
else
{
GC.AddSend(Packets.NPCSay("I'm sorry you do not have the required Level 70."));
GC.AddSend(Packets.NPCLink("Okay...", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
}
if (Control == 2)
{
GC.AddSend(Packets.NPCSay("You will be teleported to Lottery Center where there are many LuckyBoxes after you pay me 27 CPs. You may choose one box to try your luck at your will."));
GC.AddSend(Packets.NPCSay("Remeber you have only one chance to open a LuckyBox every time. If you want to open another box, you have to leave the room to re-enrol in Market."));
GC.AddSend(Packets.NPCLink("Okay...", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
break;
}
Alles anzeigen
Nearly Perfect Expball Calculations.
public uint ExpBallExp
{
get
{
if (Level < 30)
return (uint)(15000 + Level * 430);
else if (Level < 50)
return (uint)(40000 + Level * 430);
else if (Level < 80)
return (uint)(30000 + Level * 500);
else if (Level < 80)
return (uint)(30000 + Level * 600);
else if (Level < 100)
return (uint)(30000 + Level * 700);
else if (Level < 110)
return (uint)(30000 + Level * 900);
else if (Level < 120)
return (uint)(30000 + Level * 1100);
else if (Level < 125)
return (uint)(30000 + Level * 1500);
else if (Level < 130)
return (uint)(30000 + Level * 1000);
else
return (uint)(30000 + Level * 1000);
}
}
Alles anzeigen
[FONT="Fixedsys"][COLOR="DarkOrchid"]Here is my Proficiency God. It doesn't work like the real one in Conquer.
It's no matter what level the weapon's proficiency is at, you pay 20 Exp Balls to make it level 20.
Well here it is.[/COLOR][/FONT]
#region Proficiency God
case 7374:
{
if (Control == 0)
{
GC.AddSend(Packets.NPCSay("I can use the power of 20 experience balls to upgrade your proficiency straight to level 20"));
GC.AddSend(Packets.NPCLink("One Handed Weapons.", 1));
GC.AddSend(Packets.NPCLink("Two Handed Weapons.", 2));
GC.AddSend(Packets.NPCLink("Boxing", 3));
GC.AddSend(Packets.NPCLink("Nah. I'll just leave.", 255));
GC.AddSend(Packets.NPCSetFace(30));
GC.AddSend(Packets.NPCFinish());
}
if (Control == 1)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
GC.AddSend(Packets.NPCSay("Pick the one handed weapon proficiency you would like to upgrade."));
GC.AddSend(Packets.NPCLink("Sword", 4));
GC.AddSend(Packets.NPCLink("Blade", 5));
GC.AddSend(Packets.NPCLink("Club", 6));
GC.AddSend(Packets.NPCLink("Axe", 7));
GC.AddSend(Packets.NPCLink("Hammer", 8));
GC.AddSend(Packets.NPCLink("BackSword", 9));
GC.AddSend(Packets.NPCLink("Dagger", 10));
GC.AddSend(Packets.NPCLink("Next", 11));
GC.AddSend(Packets.NPCSetFace(30));
GC.AddSend(Packets.NPCFinish());
}
else
{
GC.AddSend(Packets.NPCSay("You don't have 20 Experience balls!"));
GC.AddSend(Packets.NPCLink("Sorry", 255));
GC.AddSend(Packets.NPCSetFace(30));
GC.AddSend(Packets.NPCFinish());
}
}
if (Control == 11)
{
GC.AddSend(Packets.NPCSay("Pick the one handed weapon proficiency you would like to upgrade."));
GC.AddSend(Packets.NPCLink("Hook", 12));
GC.AddSend(Packets.NPCLink("Scepter", 13));
GC.AddSend(Packets.NPCLink("Mace", 14));
GC.AddSend(Packets.NPCLink("Katana", 15));
GC.AddSend(Packets.NPCLink("Back", 1));
GC.AddSend(Packets.NPCSetFace(30));
GC.AddSend(Packets.NPCFinish());
}
if (Control == 2)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
GC.AddSend(Packets.NPCSay("Pick the Two handed weapon proficiency you would like to upgrade."));
GC.AddSend(Packets.NPCLink("Bow", 17));
GC.AddSend(Packets.NPCLink("Wand", 18));
GC.AddSend(Packets.NPCLink("Glaive", 19));
GC.AddSend(Packets.NPCLink("Poleaxe", 20));
GC.AddSend(Packets.NPCLink("Longhammer", 21));
GC.AddSend(Packets.NPCLink("Spear", 22));
GC.AddSend(Packets.NPCLink("Halberd", 23)); ;
GC.AddSend(Packets.NPCSetFace(30));
GC.AddSend(Packets.NPCFinish());
}
else
{
GC.AddSend(Packets.NPCSay("You don't have 20 Experience balls!"));
GC.AddSend(Packets.NPCLink("Sorry", 255));
GC.AddSend(Packets.NPCSetFace(30));
GC.AddSend(Packets.NPCFinish());
}
}
#region Sword
if (Control == 4)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
for (byte i = 0; i < 20; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(723700));
}
{
GC.MyChar.RWProf(new Game.Prof() { ID = 420, Lvl = 20, Exp = 0 });
}
}
#endregion
#region Blade
if (Control == 5)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
for (byte i = 0; i < 20; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(723700));
}
{
GC.MyChar.RWProf(new Game.Prof() { ID = 410, Lvl = 20, Exp = 0 });
}
}
#endregion
#region Club
if (Control == 6)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
for (byte i = 0; i < 20; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(723700));
}
{
GC.MyChar.RWProf(new Game.Prof() { ID = 480, Lvl = 20, Exp = 0 });
}
}
#endregion
#region Axe
if (Control == 7)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
for (byte i = 0; i < 20; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(723700));
}
{
GC.MyChar.RWProf(new Game.Prof() { ID = 450, Lvl = 20, Exp = 0 });
}
}
#endregion
#region Hammer
if (Control == 8)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
for (byte i = 0; i < 20; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(723700));
}
{
GC.MyChar.RWProf(new Game.Prof() { ID = 460, Lvl = 20, Exp = 0 });
}
}
#endregion
#region Backsword
if (Control == 9)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
for (byte i = 0; i < 20; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(723700));
}
{
GC.MyChar.RWProf(new Game.Prof() { ID = 421, Lvl = 20, Exp = 0 });
}
}
#endregion
#region Dagger
if (Control == 10)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
for (byte i = 0; i < 20; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(723700));
}
{
GC.MyChar.RWProf(new Game.Prof() { ID = 490, Lvl = 20, Exp = 0 });
}
}
#endregion
#region Hook
if (Control == 12)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
for (byte i = 0; i < 20; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(723700));
}
{
GC.MyChar.RWProf(new Game.Prof() { ID = 430, Lvl = 20, Exp = 0 });
}
}
#endregion
#region Scepter
if (Control == 13)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
for (byte i = 0; i < 20; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(723700));
}
{
GC.MyChar.RWProf(new Game.Prof() { ID = 481, Lvl = 20, Exp = 0 });
}
}
#endregion
#region Mace
if (Control == 14)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
for (byte i = 0; i < 20; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(723700));
}
{
GC.MyChar.RWProf(new Game.Prof() { ID = 441, Lvl = 20, Exp = 0 });
}
}
#endregion
#region Katana
if (Control == 15)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
for (byte i = 0; i < 20; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(723700));
}
{
GC.MyChar.RWProf(new Game.Prof() { ID = 601, Lvl = 20, Exp = 0 });
}
}
#endregion
#region Bow
if (Control == 17)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
for (byte i = 0; i < 20; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(723700));
}
{
GC.MyChar.RWProf(new Game.Prof() { ID = 500, Lvl = 20, Exp = 0 });
}
}
#endregion
#region Wand
if (Control == 18)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
for (byte i = 0; i < 20; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(723700));
}
{
GC.MyChar.RWProf(new Game.Prof() { ID = 561, Lvl = 20, Exp = 0 });
}
}
#endregion
#region Glaive
if (Control == 19)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
for (byte i = 0; i < 20; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(723700));
}
{
GC.MyChar.RWProf(new Game.Prof() { ID = 510, Lvl = 20, Exp = 0 });
}
}
#endregion
#region Poleaxe
if (Control == 20)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
for (byte i = 0; i < 20; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(723700));
}
{
GC.MyChar.RWProf(new Game.Prof() { ID = 530, Lvl = 20, Exp = 0 });
}
}
#endregion
#region Longhammer
if (Control == 21)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
for (byte i = 0; i < 20; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(723700));
}
{
GC.MyChar.RWProf(new Game.Prof() { ID = 540, Lvl = 20, Exp = 0 });
}
}
#endregion
#region Spear
if (Control == 22)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
for (byte i = 0; i < 20; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(723700));
}
{
GC.MyChar.RWProf(new Game.Prof() { ID = 560, Lvl = 20, Exp = 0 });
}
}
#endregion
#region Halberd
if (Control == 23)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
for (byte i = 0; i < 20; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(723700));
}
{
GC.MyChar.RWProf(new Game.Prof() { ID = 580, Lvl = 20, Exp = 0 });
}
}
#endregion
#region Boxing
if (Control == 3)
{
if (GC.MyChar.InventoryContains(723700, 20))
{
for (byte i = 0; i < 20; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(723700));
}
{
GC.MyChar.RWProf(new Game.Prof() { ID = 000, Lvl = 20, Exp = 0 });
}
}
#endregion
break;
}
#endregion
Alles anzeigen
[FONT="Fixedsys"][COLOR="DarkOrchid"]Press Thanks if this helps.[/COLOR][/FONT]
[FONT="Fixedsys"][COLOR="DarkOrchid"]I went and tested these calculations for expballs for the 5165 source.
I'll release them here.
Keep in mind that these are not perfect.
They are almost perfect.
Enjoy.[/COLOR][/FONT]
public uint ExpBallExp
{
get
{
if (Level < 30)
return (uint)(15000 + Level * 430);
else if (Level < 50)
return (uint)(40000 + Level * 430);
else if (Level < 80)
return (uint)(30000 + Level * 500);
else if (Level < 80)
return (uint)(30000 + Level * 600);
else if (Level < 100)
return (uint)(30000 + Level * 700);
else if (Level < 110)
return (uint)(30000 + Level * 900);
else if (Level < 120)
return (uint)(30000 + Level * 1100);
else if (Level < 125)
return (uint)(30000 + Level * 1500);
else if (Level < 130)
return (uint)(30000 + Level * 1000);
else
return (uint)(30000 + Level * 1000);
}
}
Alles anzeigen
[FONT="Fixedsys"][COLOR="DarkOrchid"]I hear a lot of people saying how quiz show does not work.
Well I decided to go through the source and find out what the problem is.
It's really simple so here it is.
You're going to go to Database.cs and search for[/COLOR][/FONT]
[FONT="Fixedsys"][COLOR="DarkOrchid"]Under that you should see this[/COLOR][/FONT]
{
{
string[] AllLines = System.IO.File.ReadAllLines("C:\\OldCODB\\QuizShow.txt");
int questionscount = AllLines.Length;
for (int x = 0; x < questionscount; x++)
{
string[] Info = AllLines[x].Split('#');
string Question = Info[0];
Features.QuizShow.Answer[] Answers = new NewestCOServer.Features.QuizShow.Answer[4];
Answers[0] = new NewestCOServer.Features.QuizShow.Answer(Info[1].Split(':')[0], ushort.Parse(Info[1].Split(':')[1]));
Answers[1] = new NewestCOServer.Features.QuizShow.Answer(Info[2].Split(':')[0], ushort.Parse(Info[2].Split(':')[1]));
Answers[2] = new NewestCOServer.Features.QuizShow.Answer(Info[3].Split(':')[0], ushort.Parse(Info[3].Split(':')[1]));
Answers[3] = new NewestCOServer.Features.QuizShow.Answer(Info[4].Split(':')[0], ushort.Parse(Info[4].Split(':')[1]));
Features.QuizShow.Question Q = new NewestCOServer.Features.QuizShow.Question(Question, Answers);
Features.QuizShow.AllQuestions.Add((ushort)x, Q);
}
}
}
Alles anzeigen
[FONT="Fixedsys"][COLOR="DarkOrchid"]Replace it with this.[/COLOR][/FONT]
{
if (File.Exists(@"C:\OldCODB\QuizShow.txt"))
{
string[] AllLines = System.IO.File.ReadAllLines(@"C:\OldCODB\QuizShow.txt");
int questionscount = AllLines.Length;
for (int x = 0; x < questionscount; x++)
{
string[] Info = AllLines[x].Split('#');
string Question = Info[0];
Features.QuizShow.Answer[] Answers = new NewestCOServer.Features.QuizShow.Answer[4];
Answers[0] = new NewestCOServer.Features.QuizShow.Answer(Info[1].Split(':')[0], ushort.Parse(Info[1].Split(':')[1]));
Answers[1] = new NewestCOServer.Features.QuizShow.Answer(Info[2].Split(':')[0], ushort.Parse(Info[2].Split(':')[1]));
Answers[2] = new NewestCOServer.Features.QuizShow.Answer(Info[3].Split(':')[0], ushort.Parse(Info[3].Split(':')[1]));
Answers[3] = new NewestCOServer.Features.QuizShow.Answer(Info[4].Split(':')[0], ushort.Parse(Info[4].Split(':')[1]));
Features.QuizShow.Question Q = new NewestCOServer.Features.QuizShow.Question(Question, Answers);
Features.QuizShow.AllQuestions.Add((ushort)x, Q);
}
}
}
Alles anzeigen
[FONT="Fixedsys"][COLOR="DarkOrchid"]Hope this helps.[/COLOR][/FONT]
[FONT="Fixedsys"][COLOR="DarkOrchid"]
This is for 5165!
Go to Mob.cs and search for this.[/COLOR][/FONT]
[FONT="Fixedsys"][COLOR="DarkOrchid"]Under that void put this.[/COLOR][/FONT]
if (MyMath.ChanceSuccess(DropRates.CPs))
{
if (Char != null)
{
Char.CPs += CPS AMOUNT YOU WANT;
}
}
[FONT="Fixedsys"][COLOR="DarkOrchid"]Then go to DropRates.cs and search for:[/COLOR][/FONT]
[FONT="Fixedsys"][COLOR="DarkOrchid"]Under that put: [/COLOR][/FONT]
[FONT="Fixedsys"][COLOR="DarkOrchid"]Then in that same .cs search for: [/COLOR][/FONT]
[FONT="Fixedsys"][COLOR="DarkOrchid"]Under that put [/COLOR][/FONT]
[FONT="Fixedsys"][COLOR="DarkOrchid"]Then go to OldCODB and at the very bottom put CPs=DropRate of your choice.
Then thats it.
Press thanks if it helped.[/COLOR][/FONT]
[FONT="Fixedsys"][COLOR="DarkOrchid"]I know most of you know how to "fix" this already but I figure I'll post a "fix" for it.
First go to Charcater.cs and search for this.[/COLOR][/FONT]
if(!MyClient.GM)
foreach (Character C in World.H_Chars.Values)
{
if (C.Alive && C != this)
{
if (MyMath.PointDistance(Loc.X, Loc.Y, C.Loc.X, C.Loc.Y) <= Dist)
if (C.PKAble(PKMode, this) && !SU.PlayerTargets.Contains(C) && !World.NoPKMaps.Contains(Loc.Map))
SU.PlayerTargets.Add(C, SU.GetDamage(C));
}
}
[FONT="Fixedsys"][COLOR="DarkOrchid"]Delete that entire code.
Next go to Attack.cs.
Search for [/COLOR][/FONT]
[FONT="Fixedsys"][COLOR="DarkOrchid"]Delete that.
Now gm's should be able to pk.
Hope this helps.[/COLOR][/FONT]
[FONT="Fixedsys"][COLOR="DarkOrchid"]Okay well in the 5165 source, GM's and PM's cannot trade.
Well yeah the fix for it is small but since alot of people were asking me about it I am going to release my trading code.
Replace your entire Trade.cs with this code.
[/color][/font]
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using NewestCOServer.Game;
namespace NewestCOServer.PacketHandling
{
public class Trade
{
static void CancelTrade(Main.GameClient C)
{
if (C.MyChar.Trading)
{
Character Who = (Character)World.H_Chars[C.MyChar.TradingWith];
if (Who != null)
{
Who.MyClient.AddSend(Packets.TradePacket(C.MyChar.TradingWith, 5));
Who.Trading = false;
Who.TradingWith = 0;
Who.TradeSide.Clear();
Who.TradingCPs = 0;
Who.TradingSilvers = 0;
Who.ClickedOK = false;
Who.Silvers = Who.Silvers;//update the silvers
Who.CPs = Who.CPs;//update the cps
Who.MyClient.AddSend(Packets.ChatMessage(Who.MyClient.MessageID, "SYSTEM", Who.Name, "Trading failed!", 2005, 0));
}
C.AddSend(Packets.TradePacket(C.MyChar.TradingWith, 5));
C.MyChar.Trading = false;
C.MyChar.TradingWith = 0;
C.MyChar.TradeSide = new System.Collections.ArrayList(20);
C.MyChar.TradingCPs = 0;
C.MyChar.TradingSilvers = 0;
C.MyChar.ClickedOK = false;
C.MyChar.CPs = C.MyChar.CPs;//update the cps
C.MyChar.Silvers = C.MyChar.Silvers;//update the silvers
C.AddSend(Packets.ChatMessage(C.MessageID, "SYSTEM", C.MyChar.Name, "Trading failed!", 2005, 0));
}
}
public static void Handle(Main.GameClient C, byte[] Data)
{
uint UID = BitConverter.ToUInt32(Data, 4);
byte Type = Data[8];
switch (Type)
{
case 1:
{
Character Who = (Character)World.H_Chars[UID];
if (Who != null && !Who.Trading)
{
if (!C.MyChar.Trading)
{
if (Who.EntityID != C.MyChar.TradingWith)
{
C.MyChar.TradingWith = UID;
if (Who.EntityID == C.MyChar.TradingWith && Who.TradingWith == C.MyChar.EntityID)
{
Who.MyClient.AddSend(Packets.TradePacket(C.MyChar.EntityID, 3));
C.AddSend(Packets.TradePacket(Who.EntityID, 3));
C.MyChar.Trading = true;
Who.Trading = true;
break;
}
else
{
C.AddSend(Packets.ChatMessage(C.MessageID, "SYSTEM", C.MyChar.Name, "[Trade]Request for trading has been sent out.", 2005, 0));
Who.MyClient.AddSend(Packets.TradePacket(C.MyChar.EntityID, 1));
}
}
if (Who.EntityID == C.MyChar.TradingWith && Who.TradingWith == C.MyChar.EntityID)
{
Who.MyClient.AddSend(Packets.TradePacket(C.MyChar.EntityID, 3));
C.AddSend(Packets.TradePacket(Who.EntityID, 3));
C.MyChar.Trading = true;
Who.Trading = true;
}
}
else
C.AddSend(Packets.ChatMessage(C.MessageID, "SYSTEM", C.MyChar.Name, "[Trade]Close the current trade before you take another one.", 2005, 0));
}
else
C.AddSend(Packets.ChatMessage(C.MessageID, "SYSTEM", C.MyChar.Name, "[Trade]The target is trading with someone else.", 2005, 0));
break;
}
case 2:
{
CancelTrade(C);
break;
}
case 6:
{
Character Who = (Character)World.H_Chars[C.MyChar.TradingWith];
if (Who != null)
{
if (C.MyChar.TradeSide.Count < 20)
{
if (Who.Inventory.Count + C.MyChar.TradeSide.Count < 40)
{
Game.Item I = C.MyChar.FindInvItem(UID);
if (!I.FreeItem)
{
Who.MyClient.AddSend(Packets.TradeItem(I));
C.MyChar.TradeSide.Add(I.UID);
}
else
{
C.AddSend(Packets.TradePacket(UID, 11));
C.AddSend(Packets.ChatMessage(C.MessageID, "SYSTEM", C.MyChar.Name, "[Trade]Cannot trade items made with gm commands.", 2005, 0));
}
}
else
{
C.AddSend(Packets.TradePacket(UID, 11));
C.AddSend(Packets.ChatMessage(C.MessageID, "SYSTEM", C.MyChar.Name, "[Trade]Your trade partner can't hold any more items.", 2005, 0));
Who.MyClient.AddSend(Packets.ChatMessage(C.MessageID, "SYSTEM", C.MyChar.Name, "[Trade]The one your trading with cant add anymore items on the table because you have no room in your inventory.", 2005, 0));
}
}
}
break;
}
case 7:
{
C.MyChar.TradingSilvers = UID;
Character Who = (Character)World.H_Chars[C.MyChar.TradingWith];
Who.MyClient.AddSend(Packets.TradePacket(UID, 8));
break;
}
case 13:
{
C.MyChar.TradingCPs = UID;
Character Who = (Character)World.H_Chars[C.MyChar.TradingWith];
Who.MyClient.AddSend(Packets.TradePacket(UID, 12));
break;
}
case 10:
{
Character Who = (Character)World.H_Chars[C.MyChar.TradingWith];
if (Who != null && Who.ClickedOK)
{
if (C.MyChar.Silvers >= C.MyChar.TradingSilvers && C.MyChar.CPs >= C.MyChar.TradingCPs && Who.Silvers >= Who.TradingSilvers && Who.CPs >= Who.TradingCPs)
{
Who.MyClient.AddSend(Packets.TradePacket(C.MyChar.TradingWith, 5));
C.AddSend(Packets.TradePacket(C.MyChar.EntityID, 5));
Who.Silvers += C.MyChar.TradingSilvers;
Who.Silvers -= Who.TradingSilvers;
C.MyChar.Silvers += Who.TradingSilvers;
C.MyChar.Silvers -= C.MyChar.TradingSilvers;
Who.CPs += C.MyChar.TradingCPs;
Who.CPs -= Who.TradingCPs;
C.MyChar.CPs += Who.TradingCPs;
C.MyChar.CPs -= C.MyChar.TradingCPs;
foreach (uint Id in C.MyChar.TradeSide)
{
Game.Item I = C.MyChar.FindInvItem(Id);
Who.AddItem(I);
C.MyChar.RemoveItem(I);
}
foreach (uint Id in Who.TradeSide)
{
Game.Item I = Who.FindInvItem(Id);
C.MyChar.AddItem(I);
Who.RemoveItem(I);
}
Who.Trading = false;
Who.TradingWith = 0;
Who.TradeSide = new System.Collections.ArrayList(20);
Who.TradingCPs = 0;
Who.TradingSilvers = 0;
Who.ClickedOK = false;
Who.MyClient.AddSend(Packets.ChatMessage(Who.MyClient.MessageID, "SYSTEM", Who.Name, "Trading succeeded!", 2005, 0));
C.MyChar.Trading = false;
C.MyChar.TradingWith = 0;
C.MyChar.TradeSide = new System.Collections.ArrayList(20);
C.MyChar.TradingCPs = 0;
C.MyChar.TradingSilvers = 0;
C.MyChar.ClickedOK = false;
C.AddSend(Packets.ChatMessage(C.MessageID, "SYSTEM", C.MyChar.Name, "Trading succeeded!", 2005, 0));
}
else
CancelTrade(C);
}
else
{
C.MyChar.ClickedOK = true;
Who.MyClient.AddSend(Packets.TradePacket(0, 10));
}
break;
}
}
}
}
}
Alles anzeigen
[FONT="Fixedsys"][COLOR="DarkOrchid"]
Press thanks if it helped.[/COLOR][/FONT]