-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathbot.js
More file actions
88 lines (74 loc) · 2.72 KB
/
bot.js
File metadata and controls
88 lines (74 loc) · 2.72 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
var Steam = require("steam");
var SteamUser = require ("steam-user");
var client = new SteamUser();
var friends = new Steam.SteamFriends(client.client);
var SteamCommunity = require('steamcommunity');
var community = new SteamCommunity();
var client;
var SteamID = require("steamid");
var SteamTrade = require("steam-trade");
var SteamTrade = new SteamTrade();
////////////////////// CHANGE ONLY YourAccountName, YourPassword and STEAMID IN WITHDRAW
client.logOn({
"accountName": "YourAccountName",
"password": "YourPassword"
});
client.on("loggedOn", function(details){
console.log("Logged On To Steam Server With The ID Of " + client.steamID.getSteam3RenderedID());
client.setPersona(SteamUser.Steam.EPersonaState.Online);
client.gamesPlayed(730);
});
console.log("------------------------------------------------------------------")
console.log("CHANGE ONLY YourAccountName, YourPassword and STEAMID IN WITHDRAW")
console.log("## SteamBot Made by GumikCZ ##")
console.log("Have a problem?? My youtube channel: https://www.youtube.com/channel/UCd2ujTlK79FsUfF1aEJnh3w")
console.log("My GitHub with Projects: https://github.com/DrGumik")
console.log("------------------------------------------------------------------")
client.on("webSession", function(steamID, cookies){
community.setCookies(cookies);
SteamTrade.sessionID = cookies[0].split("=")[1];
cookies.forEach(function(cookie) {
SteamTrade.setCookie(cookie);
});
client.on("error", function(error){
console.log("Error");
});
friends.on("friendMsg", function(user, msg, type){
if(type == Steam.EChatEntryType.ChatMsg){
if(msg == "Hello"){
friends.sendMessage(user,"Hello!Send me trade invite.");
}
}
})
/////////////////////////////////////////////////////// WITHDRAW SYSTEM
SteamTrade.on("chatMsg", function(msg) {
if (msg == "!itemcsgo" && "Your STEAMID") //// You can find steamID on steamrep.com
console.log("Giving Items from CSGO!");
SteamTrade.loadInventory(730,2, function(items){
SteamTrade.addItems(items);
})
})
})
/////////////////////////////////////////////////////////////////
SteamTrade.on("ready", function() {
SteamTrade.ready(function() {
SteamTrade.confirm();
})
})
client.on("tradeStarted", function(steamID){
SteamTrade.open(steamID);
})
client.on("tradeRequest", function(steamID, respond){
console.log("Somone Is Ready To Trade"+ client.steamID.getSteam3RenderedID());
respond(true);
})
SteamTrade.on('end', function(status, getItems) {
if (status == 'complete') {
getItems(function(items) {
console.log(items);
});
}
});
///////////////////////////////////////////////////////////////////////////////
////My GitHub: https://github.com/DrGumik
///////////////////////////////////////////////////////////////////////////////