Latest Shop.dat

04/03/2011 12:26 iStefan#1
Anyone Know the Shop ID of shopping mail of the latest client?
04/03/2011 14:55 { Angelius }#2
2888,

its client sided
Path: ini/emoneyshop
04/03/2011 15:51 iStefan#3
Now That's weird.
How do I make it work? (Server side)?
04/03/2011 17:20 chickmagnet#4
this from hell mouth check if it'll help

Code:
namespace Hellmouth
{
    partial class Handler
    {
        public static void BuyFromNPC(byte[] Data, Client Client)
        {
            uint Item = BitConverter.ToUInt32(Data, 8),
             Amount = BitConverter.ToUInt32(Data, 20),
             ShopID = BitConverter.ToUInt32(Data, 4),
             gPrice = 0, cPrice= 0, MoneyType = 1;
            string ItemName = string.Empty;
            Amount = Math.Max(1, Amount);
            switch (ShopID)
            {
                case 432:
                case 433:
                case 2888:
                    MoneyType = 2;
                    break;
            }
            foreach (Hellmouth.Struct.ItemData _Item in Dictionary.ItemData.Values)
                if (_Item.ID == Item)
                {
                    ItemName = _Item.Name;
                    gPrice = _Item.GoldCost;
                    gPrice *= Amount;
                    cPrice = _Item.CpCost;
                    cPrice *= Amount;
                }
            byte Plus = 0;
            switch (Item)
            {
                case 730001:
                    Plus = 1;
                    break;
                case 730002:
                    Plus = 2;
                    break;
                case 730003:
                    Plus = 3;
                    break;
                case 730004:
                    Plus = 4;
                    break;
                case 730005:
                    Plus = 5;
                    break;
                case 730006:
                    Plus = 6;
                    break;
                case 730007:
                    Plus = 7;
                    break;
                case 730008:
                    Plus = 8;
                    break;
                case 730009:
                    Plus = 9;
                    break;

            }
            switch (MoneyType)
            {
                case 1:
                    if (Client.Inventory.Count + Amount <= 40)
                    {
                        if (Client.Money >= gPrice)
                        {
                            Client.Money -= gPrice;
                            Client.AddItems(Item,Plus, Convert.ToByte(Amount));
                            Client.Send(Packets.Chat("Bought " + Amount + " " + ItemName + "! Check your inventory!", "SYSTEM", Client.Name, Struct.ChatType.Top));
                        }
                        else
                            Client.Send(Packets.Chat("Not enough silvers to purchase " + Amount + " " + ItemName, "SYSTEM", Client.Name, Struct.ChatType.Top));
                    }
                    else
                        Client.Send(Packets.Chat("You don't have enough inventory space!", "SYSTEM", Client.Name, Struct.ChatType.Top));
                    break;
                case 2:
                    if (Client.Inventory.Count + Amount <= 40)
                    {
                        if (Client.CP >= cPrice)
                        {
                            Client.CP -= cPrice;
                            Client.AddItems(Item, Plus, Convert.ToByte(Amount));
                            Client.Send(Packets.Chat("Bought " + Amount + " " + ItemName + "! Check your inventory!", "SYSTEM", Client.Name, Struct.ChatType.Top));
                        }
                        else
                            Client.Send(Packets.Chat("Not enough cps to purchase " + Amount + " " + ItemName, "SYSTEM", Client.Name, Struct.ChatType.Top));
                    }
                    else
                        Client.Send(Packets.Chat("You don't have enough inventory space!", "SYSTEM", Client.Name, Struct.ChatType.Top));
                    break;
            }
        }
    }
}
04/05/2011 18:04 iStefan#5
Quote:
Originally Posted by chickmagnet View Post
this from hell mouth check if it'll help

Code:
namespace Hellmouth
{
    partial class Handler
    {
        public static void BuyFromNPC(byte[] Data, Client Client)
        {
            uint Item = BitConverter.ToUInt32(Data, 8),
             Amount = BitConverter.ToUInt32(Data, 20),
             ShopID = BitConverter.ToUInt32(Data, 4),
             gPrice = 0, cPrice= 0, MoneyType = 1;
            string ItemName = string.Empty;
            Amount = Math.Max(1, Amount);
            switch (ShopID)
            {
                case 432:
                case 433:
                case 2888:
                    MoneyType = 2;
                    break;
            }
            foreach (Hellmouth.Struct.ItemData _Item in Dictionary.ItemData.Values)
                if (_Item.ID == Item)
                {
                    ItemName = _Item.Name;
                    gPrice = _Item.GoldCost;
                    gPrice *= Amount;
                    cPrice = _Item.CpCost;
                    cPrice *= Amount;
                }
            byte Plus = 0;
            switch (Item)
            {
                case 730001:
                    Plus = 1;
                    break;
                case 730002:
                    Plus = 2;
                    break;
                case 730003:
                    Plus = 3;
                    break;
                case 730004:
                    Plus = 4;
                    break;
                case 730005:
                    Plus = 5;
                    break;
                case 730006:
                    Plus = 6;
                    break;
                case 730007:
                    Plus = 7;
                    break;
                case 730008:
                    Plus = 8;
                    break;
                case 730009:
                    Plus = 9;
                    break;

            }
            switch (MoneyType)
            {
                case 1:
                    if (Client.Inventory.Count + Amount <= 40)
                    {
                        if (Client.Money >= gPrice)
                        {
                            Client.Money -= gPrice;
                            Client.AddItems(Item,Plus, Convert.ToByte(Amount));
                            Client.Send(Packets.Chat("Bought " + Amount + " " + ItemName + "! Check your inventory!", "SYSTEM", Client.Name, Struct.ChatType.Top));
                        }
                        else
                            Client.Send(Packets.Chat("Not enough silvers to purchase " + Amount + " " + ItemName, "SYSTEM", Client.Name, Struct.ChatType.Top));
                    }
                    else
                        Client.Send(Packets.Chat("You don't have enough inventory space!", "SYSTEM", Client.Name, Struct.ChatType.Top));
                    break;
                case 2:
                    if (Client.Inventory.Count + Amount <= 40)
                    {
                        if (Client.CP >= cPrice)
                        {
                            Client.CP -= cPrice;
                            Client.AddItems(Item, Plus, Convert.ToByte(Amount));
                            Client.Send(Packets.Chat("Bought " + Amount + " " + ItemName + "! Check your inventory!", "SYSTEM", Client.Name, Struct.ChatType.Top));
                        }
                        else
                            Client.Send(Packets.Chat("Not enough cps to purchase " + Amount + " " + ItemName, "SYSTEM", Client.Name, Struct.ChatType.Top));
                    }
                    else
                        Client.Send(Packets.Chat("You don't have enough inventory space!", "SYSTEM", Client.Name, Struct.ChatType.Top));
                    break;
            }
        }
    }
}
That Didn't help. Anyway Thanks for trying.
04/05/2011 20:02 .Kinshi#6
Are you trying to make it work with the Npc client side? Or the actual buying sever side?
04/05/2011 20:31 iStefan#7
Quote:
Originally Posted by .Kinshi View Post
Are you trying to make it work with the Npc client side? Or the actual buying sever side?
I'm Actually buying ingame.
04/06/2011 07:01 { Angelius }#8
Quote:
Originally Posted by iStefan View Post
I'm Actually buying ingame.
if you Bothered to Read what i replayed earlier it wold be much more easier thought .

ITS CLIENT SIDED , the ID for the shopping mall 2888 and you'll find it in the client folder Coblabla/ini/emoneyshop.ini open it and search for shopID 2888,

Ps.You cant change/add any items to the shopping mall with out modifying that file ,

Good luck.
04/06/2011 13:24 iStefan#9
Quote:
Originally Posted by { Angelius } View Post
if you Bothered to Read what i replayed earlier it wold be much more easier thought .

ITS CLIENT SIDED , the ID for the shopping mall 2888 and you'll find it in the client folder Coblabla/ini/emoneyshop.ini open it and search for shopID 2888,

Ps.You cant change/add any items to the shopping mall with out modifying that file ,

Good luck.

Dude. Changing items is not the problem, I Can't Buy from it. I Tried adding new shop in my Shop.dat (Server sided) with an ID 2888, and it didn't work.
Please contact me on msn [Only registered and activated users can see links. Click Here To Register...]
04/06/2011 14:01 { Angelius }#10
Quote:
Originally Posted by iStefan View Post
Dude. Changing items is not the problem, I Can't Buy from it. I Tried adding new shop in my Shop.dat (Server sided) with an ID 2888, and it didn't work.
Please contact me on msn [Only registered and activated users can see links. Click Here To Register...]
to add a new shop take the same path and find the emonyshpt.ini file and add the shop inside that file .

the shopping mall is no longer in the shop.dat
04/06/2011 16:45 iStefan#11
Quote:
Originally Posted by { Angelius } View Post
to add a new shop take the same path and find the emonyshpt.ini file and add the shop inside that file .

the shopping mall is no longer in the shop.dat
WHICH PART OF "I CAN'T ADD THE SHOPPING MAIL ON SERVER SIDE" YOU CAN'T UNDERSTAND?
04/06/2011 17:50 F i n c h i#12
Where to find Shopping Mall items in source (Hellmouth) side?
04/07/2011 01:49 .Kinshi#13
To buy an item from a shop, the client sends a Item Usage packet (1009) with type 1.

Once you get to handling the packet, give me a PM and I'll help you further.