Ok last problem. I coded my first full npc :D etheral ehehehehe and it works i cant believe it. I made sure the id and uid was correct in the notepad file, map, coords (x) and (y). And i got blacksmith lee on to. But i have one problem.
case 550:
{
if (Control == 0)
{
GC.AddSend(Packets.NPCSay("It's a chaotic world... rich steal from poor... bla bla bla. I am the great item socketer."));
GC.AddSend(Packets.NPCSay("It will cost you 18 DragonBalls to create the first socket."));
GC.AddSend(Packets.NPCSay("The second one will cost you 7 Tough Drills."));
GC.AddSend(Packets.NPCLink("I want to create a first socket.", 1));
GC.AddSend(Packets.NPCLink("I want to create a second socket.", 2));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
if (Control == 1 || Control == 2)
{
if (Control == 1)
GC.AddSend(Packets.NPCSay("Prepare 18 DragonBalls for the socket and choose the equipment you want the socket to be created in."));
else
GC.AddSend(Packets.NPCSay("Prepare 7 Tough Drills the socket and choose the equipment you want the socket to be created in."));
GC.AddSend(Packets.NPCLink("Headgear", (byte)(Control * 18)));
GC.AddSend(Packets.NPCLink("Necklace/Bag", (byte)(Control * 18)));
GC.AddSend(Packets.NPCLink("Armor", (byte)(Control * 18)));
GC.AddSend(Packets.NPCLink("Shield", (byte)(Control * 18)));
GC.AddSend(Packets.NPCLink("Ring", (byte)(Control * 18)));
GC.AddSend(Packets.NPCLink("Boots", (byte)(Control * 18)));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
else if (Control > 100 && Control <= 18 || Control == 18 || Control == 18 || Control == 18)
{
byte Pos = (byte)(Control - 18);
Game.Item Eq = GC.MyChar.Equips.Get(Pos);
if (Eq.Soc1 == NewestCOServer.Game.Item.Gem.NoSocket)
{
if (GC.MyChar.Silvers >= 250000 && GC.MyChar.InventoryContains(1088000, 12))
{
GC.MyChar.EquipStats(Pos, false);
for (byte i = 0; i < 18; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(1200005));
GC.MyChar.Silvers -= 250000;
Eq.Soc1 = NewestCOServer.Game.Item.Gem.EmptySocket;
GC.MyChar.Equips.Replace(Pos, Eq, GC.MyChar);
GC.MyChar.EquipStats(Pos, true);
GC.AddSend(Packets.NPCSay("Congratulations! You now have the first socket in your equipment."));
GC.AddSend(Packets.NPCLink("I see.", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
else
{
GC.AddSend(Packets.NPCSay("You don't have the materials."));
GC.AddSend(Packets.NPCLink("I see.", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
}
else
{
GC.AddSend(Packets.NPCSay("The item already has the first socket."));
GC.AddSend(Packets.NPCLink("Oh, right.", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
}
else if (Control > 200 && Control <= 203 || Control == 205 || Control == 206 || Control == 208)
{
byte Pos = (byte)(Control - 200);
Game.Item Eq = GC.MyChar.Equips.Get(Pos);
if (Eq.Soc1 != NewestCOServer.Game.Item.Gem.NoSocket)
{
if (Eq.Soc2 == NewestCOServer.Game.Item.Gem.NoSocket)
{
if (GC.MyChar.Silvers >= 1000000 && GC.MyChar.InventoryContains(1200005, 5))
{
GC.MyChar.EquipStats(Pos, false);
for (byte i = 0; i < 18; i++)
GC.MyChar.RemoveItem(GC.MyChar.NextItem(1200005));
GC.MyChar.Silvers -= 250000;
Eq.Soc1 = NewestCOServer.Game.Item.Gem.EmptySocket;
GC.MyChar.Equips.Replace(Pos, Eq, GC.MyChar);
GC.MyChar.EquipStats(Pos, true);
GC.AddSend(Packets.NPCSay("Congratulations! You now have the second socket in your equipment."));
GC.AddSend(Packets.NPCLink("I see.", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
else
{
GC.AddSend(Packets.NPCSay("You don't have the materials."));
GC.AddSend(Packets.NPCLink("I see.", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
}
else
{
GC.AddSend(Packets.NPCSay("The item already has the second socket."));
GC.AddSend(Packets.NPCLink("Oh, right.", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
}
else
{
GC.AddSend(Packets.NPCSay("You first need the first socket done. Then i can make the second one."));
GC.AddSend(Packets.NPCLink("I see.", 255));
GC.AddSend(Packets.NPCSetFace(N.Avatar));
GC.AddSend(Packets.NPCFinish());
}
}
break;
}
#endregion
Immune added this is and now i made it spawn but when i have 18 dragon balls. or even 18 tough drills he dont make the first socket.
i changed all the numbers to 18 as u can see cus i just got totally confused here. If someone could just tell me what to do on this one i would be greatful. And i think i changed item number aswell to dragon ball i dunno how this is corrected. It should only take someone 30 seconds >.>