Skip to content

Commit

Permalink
3.0.0
Browse files Browse the repository at this point in the history
package: forgot to bump the version lels

feat: analytics page
fix: use new api endpoint for user info
build: revamp

server: start converting to websockets
analytics: automatically clear table on update
build: fixes
package.json: cleanup and fixes

*: stuff, also i updated docs

userscript: change user api url

*: make errors more verbose
userscript: add error when token is invalid

user/ws: update websocket url

version: bump to 2.2.0

analytics: return '...' if data is null

userscript/ws: fix reconnecting
userscript/crash: add WIPED message
userscript/bet: emulate balance and resync every 10 games to reduce api
requests
backend/rain: formatted embeds to show all attributes in phone
notifications

userscript/crash: ACTUALLY add the wiped message now
*: updated dependencies

*: fix capitalization for linux

backend/config: format everything to be consistent
backend/browser: add a way to modify browser launch options

*: also use "bonusWallet" for showing balance
config: update and reformat it, again.
docs: update config

backend/rain: use string for pinging to prevent overflow

userscript/crash: forceClose when wiped
userscript/rain: fix formatting when rain concludes

backend/index: update support URL
backend/rain: fix epoch unix timestamp
*: add dependabot updates

V3

v3: start development
bf/rain: implement

crash: implement
wallet: make use of wallet namespace for changes
user: migrate to axios
analytics: add quarterly reports in logs
analytics/page: temporarily non-functional
updater: temporarily removed

docs/config: reformat and update config

backend/*: better debugging logs for disconnect and reconnect
analytics: add average latency

backend/rain: change logger title for api calls
backend/rain: change loggger title for webhook calls
backend/chat: log to analytics even if it doesnt meet minimum

wallet: reformat log when reconnecting
analytics: reformat log for reports

crash: fix not joining

crash: whoops...

analytics: revamp
config/*: change quarterly_reports to reports
*: bug fixes and other stuff

analytics/rain: fix rain table colors flipped

*: move all files into src instead of using different directories

chore: lint

analytics/page: say when rain is disabled

wallet: resync wallet when re/connecting

wallet: whoops

latency/*: max 2 decimals

latency: show if we are disconnected from the ws
latency: use crash namespace for ping instead of manager

analytics: use defaults

crash: multiply using config cashout instead of 2x

chore: lint

bet: multiply to 2 again (im bad at math)

bf: add roulette support

analytics: integrate roulette
analytics: add ping indicator colors

docs: update docs for roulette

docs: fix formatting

build: fix build errors

*: rebrand to bloxflip-autogambler

*: add more files to rebranding
chore: lint

packages: upgrade ig
  • Loading branch information
carince authored Mar 18, 2024
1 parent 3a3ccaf commit 71a816c
Show file tree
Hide file tree
Showing 48 changed files with 2,432 additions and 5,425 deletions.
6 changes: 6 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
version: 2
updates:
- package-ecosystem: "npm"
directory: "/"
schedule:
interval: "weekly"
54 changes: 27 additions & 27 deletions .swcrc
Original file line number Diff line number Diff line change
@@ -1,30 +1,30 @@
{
"$schema": "https://json.schemastore.org/swcrc",
"jsc": {
"parser": {
"syntax": "ecmascript",
"jsx": false,
"dynamicImport": true,
"privateMethod": true,
"functionBind": false,
"exportDefaultFrom": true,
"exportNamespaceFrom": true,
"decorators": false,
"decoratorsBeforeExport": false,
"topLevelAwait": false,
"importMeta": false
"$schema": "https://json.schemastore.org/swcrc",
"jsc": {
"parser": {
"syntax": "ecmascript",
"jsx": false,
"dynamicImport": true,
"privateMethod": true,
"functionBind": false,
"exportDefaultFrom": true,
"exportNamespaceFrom": true,
"decorators": false,
"decoratorsBeforeExport": false,
"topLevelAwait": false,
"importMeta": false
},
"target": "es2022",
"loose": true,
"externalHelpers": false
},
"target": "es2022",
"loose": true,
"externalHelpers": false
},
"module": {
"lazy": true,
"strict": true,
"noInterop": false,
"strictMode": true,
"type": "commonjs"
},
"minify": true,
"sourceMaps": "inline"
"module": {
"lazy": true,
"strict": true,
"noInterop": false,
"strictMode": true,
"type": "commonjs"
},
"minify": true,
"sourceMaps": "inline"
}
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<h1 align="center">bloxflip-autocrash</h1>
<p align="center">Bloxflip crash automation using the martingale strategy.<br>Earn robux passively while you sit back!</p>
<h1 align="center">bloxflip-autogambler</h1>
<p align="center">Bloxflip gambling automation using the martingale strategy.<br>Earn robux passively while you sit back!</p>

<p align="center"><img alt="GitHub Repo stars" src="https://img.shields.io/github/stars/carince/bloxflip-autocrash?color=yellow&style=flat-square"> <img alt="GitHub forks" src="https://img.shields.io/github/forks/carince/bloxflip-autocrash?style=flat-square"> <img alt="GitHub issues" src="https://img.shields.io/github/issues/carince/bloxflip-autocrash?style=flat-square"> <img alt="License" src="https://img.shields.io/badge/License-GPLv3-blue.svg?style=flat-square"></p>
<p align="center"><img alt="GitHub Repo stars" src="https://img.shields.io/github/stars/carince/bloxflip-autogambler?color=yellow&style=flat-square"> <img alt="GitHub forks" src="https://img.shields.io/github/forks/carince/bloxflip-autogambler?style=flat-square"> <img alt="GitHub issues" src="https://img.shields.io/github/issues/carince/bloxflip-autogambler?style=flat-square"> <img alt="License" src="https://img.shields.io/badge/License-GPLv3-blue.svg?style=flat-square"></p>

> **Warning**
> This automation software is against Bloxflip's [Terms of Service](https://bloxflip.com/terms "Terms of Service"), please use this at your own risk and I am not responsible for any terminated accounts.
## 💥 Features
- 🤖 Automated martingale bot
- 🤖 Automated martingale bot (crash and roulette)
- ☔ Rain Notifier
- 📊 Analytics
- 🏓 Discord Webhook integration
Expand Down
70 changes: 70 additions & 0 deletions build-pages.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
import { copyFile, readdir, mkdir, unlink, lstat, rmdir } from "fs/promises";
import { existsSync as exists } from "fs";

import { rollup } from "rollup";
import ts from "@rollup/plugin-typescript";
import swc from "@rollup/plugin-swc";
import esbuild from "rollup-plugin-esbuild";
import cjs from "@rollup/plugin-commonjs"

const plugins = [
cjs(),
ts(),
swc(),
esbuild({
minify: false,
treeShaking: false,
format: "esm"
})
];

// Clear and make paths
async function delDirRecursively(path) {
if (!exists(path)) return;

for (const file of await readdir(path)) {
const filePath = `${path}/${file}`;
if ((await lstat(filePath)).isDirectory()) {
await delDirRecursively(filePath);
} else {
console.log(`Deleting file: ${filePath}`);
await unlink(filePath);
}
}

console.log(`Deleting folder: ${path}`);
await rmdir(path);
}
await delDirRecursively("./dist/pages");
await mkdir("./dist/pages");
await mkdir("./dist/pages/public");

// Copy static files for analytics page.
await copyFile("./src/pages/index.html", "./dist/pages/index.html");
if (exists("./src/pages/public")) {
for (const file of await readdir("./src/pages/public")) {
copyFile(`./src/pages/public/${file}`, `./dist/pages/public/${file}`);
}
}

// Analytics Page
console.log("Building Analytics...");
try {
const analytics = await rollup({
input: "./src/pages/index.ts",
onwarn: () => { return; },
plugins
});

await analytics.write({
file: "./dist/pages/public/index.js",
format: "cjs",
compact: true
});
await analytics.close();

console.log("Successfully built Analytics!");
} catch (err) {
console.error(`Failed to build Analytics:\n ${err}`);
process.exit(1);
}
39 changes: 9 additions & 30 deletions build.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import { rollup } from "rollup";
import ts from "@rollup/plugin-typescript";
import swc from "@rollup/plugin-swc";
import esbuild from "rollup-plugin-esbuild";
import cjs from "@rollup/plugin-commonjs"

const plugins = [
ts(),
Expand Down Expand Up @@ -35,26 +36,24 @@ async function delDirRecursively(path) {
await rmdir(path);
}
await delDirRecursively("./dist");

await mkdir("./dist");
await mkdir("./dist/pages");
await mkdir("./dist/pages/public");

// Copy static files for analytics page.
await copyFile("./src/analytics/index.html", "./dist/pages/index.html");
await copyFile("./node_modules/socket.io/client-dist/socket.io.js", "./dist/pages/public/socket.io.js");
await copyFile("./src/pages/index.html", "./dist/pages/index.html");

if (exists("./src/analytics/public")) {
for (const file of await readdir("./src/analytics/public")) {
copyFile(`./src/analytics/public/${file}`, `./dist/pages/public/${file}`);
if (exists("./src/pages/public")) {
for (const file of await readdir("./src/pages/public")) {
copyFile(`./src/pages/public/${file}`, `./dist/pages/public/${file}`);
}
}

// Backend
console.log("Building Backend...");
try {
const backend = await rollup({
input: "./src/backend/index.ts",
input: "./src/index.ts",
onwarn: () => { return; },
plugins
});
Expand All @@ -72,32 +71,12 @@ try {
process.exit(1);
}

// UserScript
console.log("Building UserScript...");
try {
const userScript = await rollup({
input: "./src/userscript/index.ts",
onwarn: () => { return; },
plugins
});

await userScript.write({
file: "./dist/userscript.js",
format: "cjs",
compact: true
});
await userScript.close();

console.log("Successfully built UserScript!");
} catch (err) {
console.error(`Failed to build UserScript:\n ${err}`);
}

// Analytics Page
console.log("Building Analytics...");
try {
plugins.unshift(cjs())
const analytics = await rollup({
input: "./src/analytics/index.ts",
input: "./src/pages/index.ts",
onwarn: () => { return; },
plugins
});
Expand All @@ -116,6 +95,6 @@ try {
}

if (process.argv.includes("--run")) {
console.log("Running bloxflip-autocrash...");
console.log("Running bloxflip-autogambler...");
execSync("node .", { stdio: "inherit" });
}
16 changes: 7 additions & 9 deletions config.example.json5
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
{
"auth": "",
"bet": {
"tries": 12,
"startingBet": 0,
"autoCashout": 2
"game": "crash",
"tries": 14,
"starting_bet": 0,
"crash_autocashout": 2,
"roulette_color": "red"
},
"rain": {
"enabled": true,
Expand All @@ -13,17 +15,13 @@
"webhook": {
"enabled": false,
"link": "",
"ping_id": 0
"ping_id": "@everyone // <@USERID>"
}
}
},
"updater": {
"enabled": false,
"autoUpdate": false
},
// For debugging purposes only, dont touch if you dont know what you are doing
"debugging": {
"headless": true,
"reports": true,
"verbose": true
}
}
2 changes: 1 addition & 1 deletion docs/1_INSTALLING.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
# Installation
- Open your terminal and clone the repository
```bash
git clone https://github.com/carince/bloxflip-autocrash.git
git clone https://github.com/carince/bloxflip-autogambler.git
```

- Open your Browser of choice, Go to [Bloxflip](http://bloxflip.com "Bloxflip") and then run the following code inside of the Dev Tools console. (it should copy onto your clipboard):
Expand Down
14 changes: 6 additions & 8 deletions docs/2_CONFIG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,13 @@

auth: Your Bloxflip token


bet: {
game: "roulette" or "crash" (Game you want to bet on)
tries: How many times your balance will be divided to 2
startingBet: Custom starting bet tries will be ignored if this is set
autoCashout: At what multiplier you want to cashout
starting_bet: Custom starting bet tries will be ignored if this is set
crash_autocashout: At what multiplier you want to cashout, only works in crash
roulette_color: "purple", "red", or "yellow" (Color to bet on, only works in roulette)
}

rain: {
Expand All @@ -21,13 +24,8 @@
}
}

updater: {
enabled: Toggle update notifier
autoUpdate: Toggle auto updating
}

// For debugging purposes only dont touch if you dont know what you are doing
debugging: {
headless: Toggle chrome headless mode.
quarterly_reports: Toggle reports.
verbose: Toggle info logs.
}
Loading

0 comments on commit 71a816c

Please sign in to comment.