[COEMUV2]Better Beginner packs

07/02/2009 00:48 unluckyunknown45654554#1
this contains beginner packs Level1- 110, its not finished, but is very easy to

finish

it will check your invent spaces, and will give you a prize accoring to your class, the items arnt free, although.It also checks you Level, and sends you a system message saying wether or not you are correct


Massive Credit and Thanks to ScottDavey for his AddItem Function!
Code:
public static void AddItem(int itemid, int bless, int dura, int enchant, int plus, int position, int soc1, int soc2, int color, ClientSocket CSocket)
{
Struct.ItemInfo Item = new Struct.ItemInfo();
if (dura == 255)
{
Item.Dura = Item.MaxDura;
}
else
{
Item.Dura = dura;
}
Item.Bless = bless;
Item.Enchant = enchant;
Item.ItemID = itemid;
Item.Plus = plus;
Item.Position = position;
Item.Soc1 = soc1;
Item.Soc2 = soc2;
Item.Color = color;
Item.UID = Nano.Rand.Next(1, 9999999);
bool created = Database.Database.NewItem(Item, CSocket);
while (!created)
{
Item.UID = Nano.Rand.Next(1, 9999999);
created = Database.Database.NewItem(Item, CSocket);
}

CSocket.Client.Inventory.Add(Item.UID, Item);
CSocket.Send(ConquerPacket.ItemInfo(Item.UID, Item.ItemID, Item.Plus, Item.Bless, Item.Enchant, Item.Soc1, Item.Soc2, Item.Dura, Item.MaxDura, Item.Position, Item.Color));
}

i am a complete noob at coding, this is definatly not going to be brilliant at all, just something i was working on, and forgot, and just could not be arsed to finish it :P
07/02/2009 01:13 arab4life#2
cool, good job - finish it up xD