9 Commits
Author SHA1 Message Date
futile 0d7dde929d 0.5.3 2025-04-24 13:24:35 +01:00
futile 3ab802fd56 make RED, YELLOW, and GREEN slightly brighter 2025-04-23 14:33:08 +01:00
futile 53030cc5f7 add debug menu feature to change blocked_status of GameNetworking 2025-04-23 14:32:29 +01:00
futile 383224c2fa update readme 2025-04-23 14:31:50 +01:00
futile 575a6a4f1d update readme 2025-04-22 20:03:09 +01:00
futile 17579de277 update readme 2025-04-22 19:57:09 +01:00
futile 00727b9913 add compilation instructions to the repo 2025-04-22 14:34:37 +01:00
futile 1f6fc22525 check for app elevation in Default of Flags 2025-04-21 12:38:20 +01:00
futile 27b09be76e update screenshot in readme 2025-04-20 12:06:57 +01:00
8 changed files with 39 additions and 12 deletions
Generated
+1 -1
View File
@@ -864,7 +864,7 @@ dependencies = [
[[package]]
name = "gta-tools"
version = "0.5.2"
version = "0.5.3"
dependencies = [
"catppuccin-egui",
"chrono",
+1 -1
View File
@@ -1,6 +1,6 @@
[package]
name = "gta-tools"
version = "0.5.2"
version = "0.5.3"
edition = "2024"
[dependencies]
+10 -1
View File
@@ -1,4 +1,13 @@
# GTA Tools
A toolset of convenient things for GTA V Online.
![](https://i.vgy.me/s6bf1g.png)
![](https://i.vgy.me/maLh8W.png)
## Installing
**Option 1** — <ins>Download</ins>
Download the latest release [here](https://codeberg.org/futile/gta-tools/releases/download/latest/gta-tools.exe) and place it somewhere convenient for you, such as Documents. You could then make a shortcut titled "GTA Tools", and pin it to taskbar or Start.
**Option 2** — <ins>Build from source</ins>
You will need the Rust toolchain, which can be obtained [here](https://rustup.rs). Follow the instructions of its installer. Once you have Rust installed, clone this repo and navigate to it. At this point, you should probably `git checkout x.x.x`, where `x.x.x` is the latest tag. You can then run `cargo build --release`. Once you do that, you can use the binary located at `.\target\release\gta-tools.exe` in the same way as **Option 1**.
+2 -1
View File
@@ -3,6 +3,7 @@ use std::{
path::Path,
time::{Duration, Instant},
};
use strum::{Display, EnumIter};
use sysinfo::System;
use windows::{
Win32::{
@@ -23,7 +24,7 @@ const FILTER_NAME_OUT: &str = "[GTA Tools] Block all outbound traffic for GTA V"
const INTERVAL: Duration = Duration::from_secs(3);
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
#[derive(Clone, Copy, Debug, Display, PartialEq, Eq, EnumIter)]
pub enum BlockedStatus {
Blocked,
Failed,
+12 -2
View File
@@ -17,13 +17,23 @@ enum Stage {
About,
}
#[derive(Debug, Default)]
#[derive(Debug)]
pub struct Flags {
pub elevated: bool,
pub debug: bool,
closing: bool,
}
impl Default for Flags {
fn default() -> Self {
Self {
elevated: win::is_elevated(),
debug: false,
closing: false,
}
}
}
#[derive(Debug, Default)]
pub struct App {
pub meta: Meta,
@@ -35,7 +45,7 @@ pub struct App {
pub anti_afk: features::anti_afk::AntiAfk,
empty_session: features::empty_session::EmptySession,
force_close: features::force_close::ForceClose,
game_networking: features::game_networking::GameNetworking,
pub game_networking: features::game_networking::GameNetworking,
pub launch: features::launch::Launch,
}
+3 -3
View File
@@ -1,9 +1,9 @@
use crate::features::game_networking::BlockedStatus;
use eframe::egui;
pub const RED: egui::Color32 = egui::Color32::from_rgb(255, 128, 128);
pub const YELLOW: egui::Color32 = egui::Color32::from_rgb(255, 255, 128);
pub const GREEN: egui::Color32 = egui::Color32::from_rgb(128, 255, 128);
pub const RED: egui::Color32 = egui::Color32::from_rgb(255, 96, 96);
pub const YELLOW: egui::Color32 = egui::Color32::from_rgb(255, 255, 96);
pub const GREEN: egui::Color32 = egui::Color32::from_rgb(96, 255, 96);
impl From<BlockedStatus> for egui::Color32 {
fn from(value: BlockedStatus) -> Self {
+9
View File
@@ -50,6 +50,15 @@ impl App {
};
ui.label(format!("focused: \"{current_title}\""));
});
ui.horizontal(|ui| {
ui.label("blocked_status");
egui::ComboBox::from_id_salt("blocked_status")
.selected_text(&self.game_networking.blocked_status.to_string())
.show_ui(ui, |ui| {
tools::build_menu(ui, &mut self.game_networking.blocked_status);
});
});
});
ui.collapsing("anti afk", |ui| {
ui.label(format!(
+1 -3
View File
@@ -34,11 +34,9 @@ fn app_creator(
app.settings = persistent_state.settings;
}
// check if we're elevated. if not, and the user wants an elevated launch - relaunch elevated
let elevated = util::win::is_elevated();
if app.settings.start_elevated && !elevated {
if !app.flags.elevated && app.settings.start_elevated {
util::win::elevate(util::win::ElevationExitMethod::Forced);
}
app.flags.elevated = elevated;
// refresh sysinfo because it initializes with nothing
app.sysinfo.refresh_all();
// enable image loading support in egui