Начинающий
- Статус
- Оффлайн
- Регистрация
- 5 Янв 2023
- Сообщения
- 65
- Реакции
- 2
Здрасте, у менгя были экстернал макросы писал пол года назад, забросил раст, вернулся, уже не работают. Писал на питоне, теперь на ахк и на с# писал все тоже не работает, как можно сделать без инжекта анти отдачу?
Это еще очень сырая версия, которая сохранилась в файлообменнике, вот она
ДА ФУЛЛ ГПТ КОД, НО МНЕ БЫЛО УДОБНО
Это еще очень сырая версия, которая сохранилась в файлообменнике, вот она
ДА ФУЛЛ ГПТ КОД, НО МНЕ БЫЛО УДОБНО
macros.py:
import win32api
import win32con
import time
import threading
from pynput import mouse, keyboard
import random
from PyQt5.QtWidgets import (QApplication, QMainWindow, QWidget, QVBoxLayout,
QHBoxLayout, QComboBox, QLabel, QPushButton, QFrame,
QMessageBox, QCheckBox)
from PyQt5.QtCore import Qt, QTimer, QPoint
from PyQt5.QtGui import QFont, QPalette, QColor, QIcon
import sys
import requests
import wmi
import hashlib
import os
import ctypes
from ctypes import wintypes
# Настройки оружия
WEAPONS = {
'AK-47': {
'standing': {'vertical': 4.92, 'horizontal': -3.7},
'crouching': {'vertical': 2.90, 'horizontal': -1.5}
},
'Python': {
'standing': {'vertical': 7.8, 'horizontal': 0.65},
'crouching': {'vertical': 4.5, 'horizontal': 0.45}
},
'LR-300': {
'standing': {'vertical': 4.25, 'horizontal': 0.65},
'crouching': {'vertical': 2.77, 'horizontal': 0.75}
},
'MP5': {
'standing': {'vertical': 3, 'horizontal': 0},
'crouching': {'vertical': 1.92, 'horizontal': 0}
},
'Thompson': {
'standing': {'vertical': 2, 'horizontal': 0},
'crouching': {'vertical': 1.12, 'horizontal': 0}
},
'Berda': {
'standing': {'vertical': 3.1, 'horizontal': 0},
'crouching': {'vertical': 2.15, 'horizontal': 0}
},
'SMG': {
'standing': {'vertical': 1.98, 'horizontal': 0},
'crouching': {'vertical': 1.22, 'horizontal': 0}
},
'Peshka': {
'standing': {'vertical': 2.15, 'horizontal': 0.45},
'crouching': {'vertical': 1.12, 'horizontal': 0.34}
},
'M39': {
'standing': {'vertical': 3.15, 'horizontal': -2.04},
'crouching': {'vertical': 1.95, 'horizontal': -1.10}
},
'M249': {
'standing': {'vertical': 4.05, 'horizontal': -2.60},
'crouching': {'vertical': 2.28, 'horizontal': -1.60}
},
'Beretta': {
'standing': {'vertical': 6.2, 'horizontal': 0},
'crouching': {'vertical': 3.75, 'horizontal': 0}
},
'Revolver': {
'standing': {'vertical': 3.4, 'horizontal': 0},
'crouching': {'vertical': 2.35, 'horizontal': 0}
},
'SKS': {
'standing': {'vertical': 4.5, 'horizontal': 0},
'crouching': {'vertical': 2.65, 'horizontal': 0}
},
'Pulik': {
'standing': {'vertical': 3.97, 'horizontal': 2},
'crouching': {'vertical': 2.68, 'horizontal': 1.27}
},
'Big revik': {
'standing': {'vertical': 7.15, 'horizontal': -0.7},
'crouching': {'vertical': 4.95, 'horizontal': -0.1}
},
'Prototype': {
'standing': {'vertical': 2.95, 'horizontal': 0},
'crouching': {'vertical': 1.95, 'horizontal': 0}
},
'Dwushka': {
'standing': {'vertical': 15.75, 'horizontal': -4},
'crouching': {'vertical': 11.81, 'horizontal': -3}
},
'Pomp': {
'standing': {'vertical': 3.5, 'horizontal': 0},
'crouching': {'vertical': 2.63, 'horizontal': 0}
},
'Spas': {
'standing': {'vertical': 9, 'horizontal': -2},
'crouching': {'vertical': 6.75, 'horizontal': -1.5}
},
'M4': {
'standing': {'vertical': 4.35, 'horizontal': -1.2},
'crouching': {'vertical': 3.26, 'horizontal': -0.9}
}
}
class StatusOverlay(QWidget):
def __init__(self, app):
super().__init__()
self.app = app
self.setWindowFlags(Qt.FramelessWindowHint | Qt.WindowStaysOnTopHint | Qt.Tool)
self.setAttribute(Qt.WA_TranslucentBackground)
self.resize(120, 39)
self.move(30, 30)
layout = QVBoxLayout()
layout.setContentsMargins(0, 0, 0, 0)
self.status_label = QLabel("FLUS DISABLE")
self.status_label.setStyleSheet("""
QLabel {
color: #ff3333;
font-size: 7px;
font-weight: bold;
font-family: 'Segoe UI';
background-color: rgba(10, 10, 10, 180);
padding: 4px;
border: 1px solid #ff3333;
border-radius: 4px;
}
""")
layout.addWidget(self.status_label)
self.setLayout(layout)
def update_status(self, enabled):
if enabled:
self.status_label.setText("FLUS ACTIVE")
self.status_label.setStyleSheet("""
QLabel {
color: #00ff00;
font-size: 12px;
font-weight: bold;
font-family: 'Segoe UI';
background-color: rgba(20, 20, 20, 200);
padding: 15px;
border: 1px solid #00ff00;
border-radius: 4px;
}
""")
else:
self.status_label.setText("FLUS DISABLE")
self.status_label.setStyleSheet("""
QLabel {
color: #ff3333;
font-size: 12px;
font-weight: bold;
font-family: 'Segoe UI';
background-color: rgba(20, 20, 20, 200);
padding: 15px;
border: 1px solid #ff3333;
border-radius: 4px;
}
""")
class NoRecoilMenu(QMainWindow):
def __init__(self, norecoil, app):
super().__init__()
self.app = app
self.norecoil = norecoil
self.dark_theme = True
self.setWindowTitle("FLUS Macros")
self.setFixedSize(500, 223)
self.setWindowFlags(Qt.FramelessWindowHint)
self.setAttribute(Qt.WA_TranslucentBackground)
self.frame = QFrame(self)
self.frame.setGeometry(10, 10, 481, 201)
self.create_ui_elements()
self.theme_button = QPushButton("🌙 Light Theme", self.frame)
self.theme_button.setGeometry(10, 160, 461, 30)
self.theme_button.clicked.connect(self.toggle_theme)
self.apply_theme()
def create_ui_elements(self):
self.closeButton = QPushButton("✖", self.frame)
self.closeButton.setGeometry(440, 0, 41, 31)
self.closeButton.clicked.connect(self.close_application)
self.minimizeButton = QPushButton("➖", self.frame)
self.minimizeButton.setGeometry(390, 0, 41, 31)
self.minimizeButton.clicked.connect(self.showMinimized)
self.title_label = QLabel("Never v3.1-Recode [Author:Swaga]", self.frame)
self.title_label.setGeometry(20, 0, 361, 30)
self.auto_sprint_checkbox = QCheckBox("AutoSprint", self.frame)
self.auto_sprint_checkbox.setGeometry(10, 40, 461, 30)
self.auto_sprint_checkbox.stateChanged.connect(self.norecoil.toggle_auto_sprint)
self.weapon_combo = QComboBox(self.frame)
self.weapon_combo.setGeometry(10, 80, 461, 30)
self.weapon_combo.addItems(WEAPONS.keys())
self.weapon_combo.currentTextChanged.connect(self.change_weapon)
self.change_key_button = QPushButton("Change activation key (F6)", self.frame)
self.change_key_button.setGeometry(10, 120, 461, 30)
self.change_key_button.clicked.connect(self.start_key_capture)
self.waiting_for_key = False
self.status_overlay = StatusOverlay(self.app)
self.status_overlay.show()
self.status_timer = QTimer()
self.status_timer.timeout.connect(self.update_status)
self.status_timer.start(100)
def apply_theme(self):
if self.dark_theme:
frame_style = """
QFrame {
background-color: rgb(25, 25, 25);
border-radius: 15px;
}
"""
title_style = """
QLabel {
color: white;
font-weight: bold;
font-size: 16px;
}
"""
checkbox_style = """
QCheckBox {
color: white;
background-color: rgb(28, 28, 28);
border-radius: 5px;
padding: 5px;
padding-left: 10px;
border: 2px solid rgb(0, 128, 255);
font-size: 14px;
}
QCheckBox::indicator {
width: 20px;
height: 20px;
margin-right: 5px;
}
QCheckBox::indicator:unchecked {
background-color: rgb(28, 28, 28);
border: 2px solid rgb(0, 128, 255);
border-radius: 4px;
}
QCheckBox::indicator:checked {
background-color: rgb(0, 128, 255);
border: 2px solid rgb(0, 128, 255);
border-radius: 4px;
}
"""
combobox_style = """
QComboBox {
background-color: rgb(28, 28, 28);
border-radius: 5px;
padding-left: 10px;
color: white;
border: 2px solid rgb(0, 128, 255);
}
"""
button_style = """
QPushButton {
background-color: rgb(28, 28, 28);
border-radius: 5px;
color: white;
border: 2px solid rgb(0, 128, 255);
}
QPushButton:hover {
background-color: rgb(35, 35, 35);
}
"""
self.theme_button.setText("🌙 Light Theme")
else:
frame_style = """
QFrame {
background-color: rgb(230, 240, 255);
border-radius: 15px;
}
"""
title_style = """
QLabel {
color: rgb(0, 80, 170);
font-weight: bold;
font-size: 16px;
}
"""
checkbox_style = """
QCheckBox {
color: rgb(0, 80, 170);
background-color: rgb(240, 245, 255);
border-radius: 5px;
padding: 5px;
padding-left: 10px;
border: 2px solid rgb(0, 128, 255);
font-size: 14px;
}
QCheckBox::indicator {
width: 20px;
height: 20px;
margin-right: 5px;
}
QCheckBox::indicator:unchecked {
background-color: rgb(240, 245, 255);
border: 2px solid rgb(0, 128, 255);
border-radius: 4px;
}
QCheckBox::indicator:checked {
background-color: rgb(0, 128, 255);
border: 2px solid rgb(0, 128, 255);
border-radius: 4px;
}
"""
combobox_style = """
QComboBox {
background-color: rgb(240, 245, 255);
border-radius: 5px;
padding-left: 10px;
color: rgb(0, 80, 170);
border: 2px solid rgb(0, 128, 255);
}
"""
button_style = """
QPushButton {
background-color: rgb(240, 245, 255);
border-radius: 5px;
color: rgb(0, 80, 170);
border: 2px solid rgb(0, 128, 255);
}
QPushButton:hover {
background-color: rgb(220, 230, 255);
}
"""
self.theme_button.setText("☀️ Dark Theme")
self.frame.setStyleSheet(frame_style)
self.title_label.setStyleSheet(title_style)
self.auto_sprint_checkbox.setStyleSheet(checkbox_style)
self.weapon_combo.setStyleSheet(combobox_style)
self.change_key_button.setStyleSheet(button_style)
self.theme_button.setStyleSheet(button_style)
self.closeButton.setStyleSheet(button_style)
self.minimizeButton.setStyleSheet(button_style)
def apply_button_theme(self, button):
if self.dark_theme:
button.setStyleSheet("""
QPushButton {
background-color: rgb(28, 28, 28);
border-radius: 5px;
color: white;
border: 2px solid rgb(0, 128, 255);
}
QPushButton:hover {
background-color: rgb(35, 35, 35);
}
""")
else:
button.setStyleSheet("""
QPushButton {
background-color: rgb(255, 255, 255);
border-radius: 5px;
color: black;
border: 2px solid rgb(0, 128, 255);
}
QPushButton:hover {
background-color: rgb(245, 245, 245);
}
""")
def toggle_theme(self):
self.dark_theme = not self.dark_theme
self.apply_theme()
def change_weapon(self, weapon_name):
self.norecoil.current_weapon = weapon_name
print(f"Оружие изменено на {weapon_name}")
def update_status(self):
self.status_overlay.update_status(self.norecoil.enabled)
def mousePressEvent(self, event):
self.oldPos = event.globalPos()
def mouseMoveEvent(self, event):
delta = QPoint(event.globalPos() - self.oldPos)
self.move(self.x() + delta.x(), self.y() + delta.y())
self.oldPos = event.globalPos()
def close_application(self):
self.status_overlay.close()
self.app.quit()
def closeEvent(self, event):
self.status_timer.stop()
self.status_overlay.close()
event.accept()
def start_key_capture(self):
self.change_key_button.setText("Press any key...")
self.waiting_for_key = True
self.key_capture_thread = threading.Thread(target=self.capture_key, daemon=True)
self.key_capture_thread.start()
def capture_key(self):
def on_press(key):
if self.waiting_for_key:
self.norecoil.set_toggle_key(key)
self.waiting_for_key = False
try:
if hasattr(key, 'char'):
key_name = key.char.upper()
else:
key_name = str(key).split('.')[-1].upper()
self.change_key_button.setText(f"Change activation key ({key_name})")
except AttributeError:
key_name = str(key).split('.')[-1].upper()
self.change_key_button.setText(f"Change activation key ({key_name})")
return False
with keyboard.Listener(on_press=on_press) as listener:
listener.join()
class MOUSEINPUT(ctypes.Structure):
_fields_ = [
("dx", wintypes.LONG),
("dy", wintypes.LONG),
("mouseData", wintypes.DWORD),
("dwFlags", wintypes.DWORD),
("time", wintypes.DWORD),
("dwExtraInfo", ctypes.POINTER(wintypes.ULONG))
]
class KEYBDINPUT(ctypes.Structure):
_fields_ = [
("wVk", wintypes.WORD),
("wScan", wintypes.WORD),
("dwFlags", wintypes.DWORD),
("time", wintypes.DWORD),
("dwExtraInfo", ctypes.POINTER(wintypes.ULONG))
]
class HARDWAREINPUT(ctypes.Structure):
_fields_ = [
("uMsg", wintypes.DWORD),
("wParamL", wintypes.WORD),
("wParamH", wintypes.WORD)
]
class INPUT_union(ctypes.Union):
_fields_ = [
("mi", MOUSEINPUT),
("ki", KEYBDINPUT),
("hi", HARDWAREINPUT)
]
class INPUT(ctypes.Structure):
_fields_ = [
("type", wintypes.DWORD),
("union", INPUT_union)
]
class NoRecoil:
RU_TO_EN = {
'й': 'q', 'ц': 'w', 'у': 'e', 'к': 'r', 'е': 't', 'н': 'y', 'г': 'u', 'ш': 'i',
'щ': 'o', 'з': 'p', 'ф': 'a', 'ы': 's', 'в': 'd', 'а': 'f', 'п': 'g', 'р': 'h',
'о': 'j', 'л': 'k', 'д': 'l', 'я': 'z', 'ч': 'x', 'с': 'c', 'м': 'v', 'и': 'b',
'т': 'n', 'ь': 'm'
}
def __init__(self):
self.enabled = False
self.shooting = False
self.current_weapon = 'AK-47'
self.last_shot_time = 0
self.auto_sprint = False
self.sprint_thread = None
self.toggle_key = 'f6'
self.is_crouching = False
self.running = True
self.last_toggle_time = 0 # Добавляем защиту от двойного срабатывания
self.crouch_listener = keyboard.Listener(on_press=self.on_key_press, on_release=self.on_key_release)
self.crouch_listener.start()
def toggle(self):
current_time = time.time()
if current_time - self.last_toggle_time < 0.3: # Защита от двойного срабатывания
return
self.last_toggle_time = current_time
self.enabled = not self.enabled
state = "Включен" if self.enabled else "Выключен"
print(f"NoRecoil {state}")
def set_toggle_key(self, key):
try:
if hasattr(key, 'char'):
self.toggle_key = key.char.lower()
else:
self.toggle_key = str(key).split('.')[-1].lower()
except AttributeError:
self.toggle_key = str(key).split('.')[-1].lower()
print(f"Key changed to: {self.toggle_key}")
def sprint_loop(self):
while self.running:
if self.auto_sprint:
win32api.keybd_event(0x10, 0, 0, 0)
else:
win32api.keybd_event(0x10, 0, win32con.KEYEVENTF_KEYUP, 0)
time.sleep(0.1)
def toggle_auto_sprint(self, state):
self.auto_sprint = bool(state)
if not self.sprint_thread:
self.sprint_thread = threading.Thread(target=self.sprint_loop, daemon=True)
self.sprint_thread.start()
def on_click(self, x, y, button, pressed):
if button == mouse.Button.left:
self.shooting = pressed
if pressed:
self.last_shot_time = time.time()
def on_key_press(self, key):
try:
if hasattr(key, 'char') and key.char.lower() == 'c':
self.is_crouching = True
current_key = key.char.lower() if hasattr(key, 'char') else str(key).split('.')[-1].lower()
if current_key in self.RU_TO_EN:
current_key = self.RU_TO_EN[current_key]
if current_key == self.toggle_key:
self.toggle()
except AttributeError:
pass
def on_key_release(self, key):
try:
if hasattr(key, 'char') and key.char.lower() == 'c':
self.is_crouching = False
except AttributeError:
pass
@staticmethod
def move_mouse(dx, dy):
extra = win32con.MOUSEEVENTF_MOVE
win32api.mouse_event(extra, dx, dy, 0, 0)
def stop(self):
self.running = False
if self.sprint_thread and self.sprint_thread.is_alive():
self.sprint_thread.join()
def recoil_control(self):
while True:
try:
if self.enabled and self.shooting:
weapon = WEAPONS[self.current_weapon]
stance = 'crouching' if self.is_crouching else 'standing'
recoil_values = weapon[stance]
vertical_recoil = recoil_values['vertical'] + random.uniform(-0.15, 0.15)
horizontal_recoil = recoil_values['horizontal'] + random.uniform(-0.1, 0.1)
self.move_mouse(int(horizontal_recoil), int(vertical_recoil))
time.sleep(0.016)
else:
time.sleep(0.001)
except Exception as e:
print(f"Ошибка: {e}")
time.sleep(0.001)
def main():
app = QApplication(sys.argv)
app.setStyle("Fusion")
script = NoRecoil()
recoil_thread = threading.Thread(target=script.recoil_control, daemon=True)
recoil_thread.start()
mouse_listener = mouse.Listener(on_click=script.on_click)
keyboard_listener = keyboard.Listener(
on_press=script.on_key_press,
on_release=script.on_key_release
)
mouse_listener.start()
keyboard_listener.start()
menu = NoRecoilMenu(script, app)
menu.show()
exit_code = app.exec_()
# Корректное завершение
script.stop()
mouse_listener.stop()
keyboard_listener.stop()
sys.exit(exit_code)
if __name__ == "__main__":
main()