예제 #1
0
        private Schema.Item GetItemFromPrivateBp(TradeEvent tradeEvent, ulong itemID)
        {
            if (OtherPrivateInventory == null)
            {
                // get the foreign inventory
                var f = session.GetForiegnInventory(OtherSID, tradeEvent.contextid, tradeEvent.appid);
                OtherPrivateInventory = new ForeignInventory(f);
            }

            ushort defindex = OtherPrivateInventory.GetDefIndex(itemID);

            Schema.Item schemaItem = CurrentSchema.GetItem(defindex);
            return(schemaItem);
        }
예제 #2
0
파일: Trade.cs 프로젝트: snideran/SteamBot
        private Schema.Item GetItemFromPrivateBp(TradeUserAssets asset)
        {
            if (OtherPrivateInventory == null)
            {
                dynamic foreignInventory = session.GetForeignInventory(OtherSID, asset.contextid, asset.appid);
                if (foreignInventory == null || foreignInventory.success == null || !foreignInventory.success.Value)
                {
                    return(null);
                }

                OtherPrivateInventory = new ForeignInventory(foreignInventory);
            }

            int defindex = OtherPrivateInventory.GetDefIndex(asset.assetid);

            Schema.Item schemaItem = CurrentSchema.GetItem(defindex);
            return(schemaItem);
        }
예제 #3
0
파일: Trade.cs 프로젝트: newhupo/SteamBot-1
        private Schema.Item GetItemFromPrivateBp(TradeEvent tradeEvent, ulong itemID)
        {
            if (OtherPrivateInventory == null)
            {
                // get the foreign inventory
                var f = session.GetForiegnInventory(OtherSID, tradeEvent.contextid,tradeEvent.contextid);
                OtherPrivateInventory = new ForeignInventory(f);
            }

            ushort defindex = OtherPrivateInventory.GetDefIndex(itemID);

            Schema.Item schemaItem = CurrentSchema.GetItem(defindex);
            return schemaItem;
        }