caute takze mam klasickeho uplne primitivneho steam bota, ale potrebujem to spustit cez html dokument ako to mam spravit prosimvas?
skusal som uz <script src="index.js"></script>
robil som to aj ze som dal do hlavicky <script type="text/javascript" src="Public/Scripts/filename.js"></script>
a potom zavolal funkciu <button onclick="funkciaButton()">Blablaa</button>
ale bezuspesne..
kod:
Kód:
const SteamUser = require('steam-user');
const SteamTotp = require('steam-totp');
const config = require('./config.json');
const Pubgapi = require('pubg-api');
const apiInstance = new Pubgapi('<apiKey>');
const client = new SteamUser;
const logOnOptions = {
accountName: config.accountName,
password: config.password,
twoFactorCode: SteamTotp.generateAuthCode(config.shared_secret)
}
client.logOn(logOnOptions);
client.on('loggedOn', () => {
newFunction_1(client, SteamUser);
client.gamesPlayed(578080);
});