Jump to content
McKay Development

Blue

Member
  • Posts

    26
  • Joined

  • Last visited

Posts posted by Blue

  1. some user inventories are really big, and the module would be doing lots of requests to steam, so if only a single one request fails, it would have to start all over again, to have a few extra attempts to that specific request if we receive a mailformed response or a common http error would be realy cool

  2. // A bit of optimization; objects are hash tables so it's more efficient to look up by key than to iterate an array
    	var quickDescriptionLookup = {};
    
    	function getDescription(descriptions, classID, instanceID) {
    		var key = classID + '_' + (instanceID || '0'); // instanceID can be undefined, in which case it's 0.
    
    		if (quickDescriptionLookup[key]) {
    			return quickDescriptionLookup[key];
    		}
    
    		for (var i = 0; i < descriptions.length; i++) {
    			quickDescriptionLookup[descriptions[i].classid + '_' + (descriptions[i].instanceid || '0')] = descriptions[i];
    		}
    
    		return quickDescriptionLookup[key];
    	}
    

    This part of your node-steamcommunity, i meant the "quickDescriptionLookup", if the target inventory has to many descriptions, it could overload ram right?

     

    like for instance some target inventory with 100k items or something..

  3. ok cool, what about the steamcommunity module, this proccess is the same about the getInventoryContents? i saw that you made a temp var to load the target inventory, but if the target inventory is to big it can pretty much overload the ram as well right? would be cool to have something alike to keep control of ram usage if it doesnt exist yet, also thanks for the quick responses =D

  4. I was doing some tests in one of my projects that use this module, and i noticed that de polling sometimes requests to much ram, after get further the module in github, the "problem", seems to be that to much information is cached in the LeastUsedCache(), this happens only when there is a that bot account has to many items i suppose..

     

    so having that in mind, i have a question that can possibly lower the ram usage, what if we use a mongoDB or something alike to store that data intead(as an option to implement of course), this would only be useful in some cases like mine, but it might improve a little the ram usage, and also would be possible to store more data for more time if needed..

     

    i could have did it myself and test it to see if is worth it, but i'd rather see you guys thoughts first, and also the possibility of this to be implemented in the module by the @Doctor himself, if the results seems to be good

  5. For Steam Mobile Auth:

    client.logOn({
    "accountName": username,
    "password": password,
    "twoFactorCode": steamGuardCode //Steam Guard Code Generated by steam-totp 
    });

    For Steam Guard email code:

    client.logOn({
    "accountName": username,
    "password": password,
    "authCode": code //Get somehow the code sended to your email, and put it here
    });

    You can see more detailed information HERE

  6.     community.httpRequestPost({
            "uri": "https://steamcommunity.com/profiles/" + client.steamID.getSteamID64() + "/ajaxsetshowcaseconfig",
            "form": {
                "appid": 730,
                "item_contextid": 2,
                "item_assetid": 11692952310,
                "customization_type": 4,
                "slot": 0,
                "sessionid": sessionID
            },
            "json": true
        }, (err, response, body) => {
            console.log("err:", err);
            console.log("body:", body);
        }, "steamcommunity");

     

    I'm trying to play a little with the profile showcases, the idea is to make a change in the item that are showed in a desired slot, but for some reason it doesn't work, all the data passed in the POST are definetely right, you guys have an idea on how to make it work?

  7. There is any limit in getUserInventoryContents() ?, i mean, steam rate limits or anything that may freeze my bot, or may cause errors?

     

    for instance, if the bot keep making requests one after another all the time, like, finished the first request, then make another, finish and then another, (just an example, my bot doesn't run like that)

     

     

  8. error 26 means that the item id's you are trying to user are invalid.

     

    You need to re-scan the inventory and properly map the request again.

    yes i know what error 26 is about, you dont get my point, if the sentOfferChanged  isnt fired, so the bot cant handle items to avoid errors 26. and to a bot with requests all the time, re-scan inventory just isnt a good idea.

  9. i'm getting a lot of errors 26, and i have maked the bot to handle gived and received items, and if any error comes up, completely reload inventory, but still there are errors 26 all the time, so this event will for sure be fired ??

     

    Constructor i'm using.↓↓

    new TradeOfferManager({ "steam": client, "language": "en", "community":community, "pollInterval": "10000", "cancelTime": "7200000" }); 
  10. I have already changed the promptSteamGuardCode to false, and maked a steamGuard handler

    this.getCode(shared, function(code) {
    		callback({
    			"accountName": login,
    			"password": pw,
    			"twoFactorCode": code,
    			"rememberPassword":true,
    			"promptSteamGuardCode": false
    		});
    	});
    
    client.on('steamGuard', function(domain, callback) { helper.getCode(config.sharedse, function(code){ callback(code); }); });

    But sometimes i still got the Steam app code request, and i have to restart the node..

×
×
  • Create New...