Giter Club home page Giter Club logo

lunar's Introduction

Lunar

Lunar is a neural network aim assist that uses real-time object detection accelerated with CUDA on Nvidia GPUs.

About

Lunar can be modified to work with a variety of FPS games; however, it is currently configured for Fortnite. Besides being general purpose, the main advantage of using Lunar is that it does not meddle with the memory of other processes.

The basis of Lunar's player detection is the YOLOv5 architecture written in PyTorch.

A demo video (outdated) can be found here.

thumbnail

Installation

  1. Install a version of Python 3.8 or later.

  2. Navigate to the root directory. Use the package manager pip to install the necessary dependencies.

pip install -r requirements.txt

Usage

python lunar.py

To update sensitivity settings:

python lunar.py setup

To collect image data for annotating and training:

python lunar.py collect_data

Issues

  • The method of mouse movement (SendInput) is slow. For this reason, the crosshair often lags behind a moving detection. This problem can be lessened by increasing the pixel_increment (e.g. to 4) so fewer calls to that function are made.
  • False positives can also happen under certain lighting conditions.

Contributing

Pull requests are welcome. If you have any suggestions, questions, or find any issues, please open an issue and provide some detail. If you find this project interesting or helpful, please star the repository.

License

This project is distributed under GNU General Public License v3.0 license.

lunar's People

Contributors

wingysam avatar zeyad-mansour avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

lunar's Issues

Could not find a version that satisfies the requirement ctypes

When I install the requisiments.txt, in the end I get this error:

ERROR: Could not find a version that satisfies the requirement ctypes
ERROR: No matching distribution found for ctypes

2021-04-28 03_53_08-Fortnite

Even so, I open the program perfectly, but when the game starts and a character appears in front of me, it closes and shows the following error

2021-04-28 03_54_48-Símbolo del sistema

btw: i Send you a private message on twitter, you may be interested

ModuleNotFoundError: No module named 'cv2'

I dont know why every time I try running the python script it says ModuleNotFoundError: No module named 'cv2'

Im using CMD to run the script (by stating the scripts directory and using the python keyword to get python to run in cmd) but it still doesnt work. any tips?

Failed to execute script lunar

how do I open the ''lunar'' without showing anything on the screen? I tried converting to .exe using pyinstaller and --noconsole so nothing appears on the screen, but when I open it I get the message ''Failed to execute lunar script''

Error

[!] Sensitivity configuration is not set
[INFO] In-game X and Y axis sensitivity should be the same
X-Axis and Y-Axis Sensitivity (from in-game settings): 22
Targeting Sensitivity (from in-game settings): 50
[INFO] Your in-game targeting sensitivity must be the same as your scoping sensitivity
[INFO] Sensitivity configuration complete
Traceback (most recent call last):
File "lunar.py", line 74, in
main()
File "lunar.py", line 21, in main
lunar = Aimbot(collect_data = "collect_data" in sys.argv, controller = "controller" in sys.argv)
TypeError: init() got an unexpected keyword argument 'controller'

Correct Settings

Hi,
i was just testing the aimbot with 14.3 x/y and 100 (100%) target sensivity settings. The result was not that great so far. Im just wondering if you could recomment settings that might work better.

Since im normally playing with controller, i would like to know how the bot could might be optimized to support that.

Kind Regards
Stefan

Aimbot

Mouse just moves to top left of screen

i can't install pytorch

Collecting torchvision
Using cached torchvision-0.9.1-cp38-cp38-win_amd64.whl (852 kB)
Requirement already satisfied: numpy in c:\users\caler\appdata\local\packages\pythonsoftwarefoundation.python.3.8_qbz5n2kfra8p0\localcache\local-packages\python38\site-packages (from torchvision) (1.20.3)
Requirement already satisfied: pillow>=4.1.1 in c:\users\caler\appdata\local\packages\pythonsoftwarefoundation.python.3.8_qbz5n2kfra8p0\localcache\local-packages\python38\site-packages (from torchvision) (8.2.0)
Collecting torch==1.8.1
Using cached torch-1.8.1-cp38-cp38-win_amd64.whl (190.5 MB)
Requirement already satisfied: typing-extensions in c:\users\caler\appdata\local\packages\pythonsoftwarefoundation.python.3.8_qbz5n2kfra8p0\localcache\local-packages\python38\site-packages (from torch==1.8.1->torchvision) (3.10.0.0)
Installing collected packages: torch, torchvision
ERROR: Could not install packages due to an OSError: [Errno 2] No such file or directory: 'C:\Users\caler\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\caffe2\python\serialized_test\data\operator_test\collect_and_distribute_fpn_rpn_proposals_op_test.test_collect_and_dist.zip'

the aim is jumping

so when i aim the crosshair is jumping from location to another location randomly, it should be aimed at the closest target

What should be inside the config file?

In line 79 of the aimbot.py the config json file opens but since I do not know what it should contain, there cannot be any data extracted from it. I would appreciate an explainable reply.

Freezing

So it detects csgo enemies but whenever I right click to use the aimbot the program freezes and sends my character spinning until it unfreezes

controller?

Traceback (most recent call last):
File "lunar.py", line 74, in
main()
File "lunar.py", line 21, in main
lunar = Aimbot(collect_data = "collect_data" in sys.argv, controller = "controller" in sys.argv)
TypeError: init() got an unexpected keyword argument 'controller'

but im not using controller neither do i have one plugged in

0 FPS

pls im new on this and i really love the prject but the lunar vision stays at 0 fps how can i fix this ? 0 fps makes that the aimbot dont work

update

I got it running, but when will the next update be?

Issue when trying to start

[INFO] PRESS 'F1'
[INFO] PRESS 'F2'
[INFO] Recording
Traceback (most recent call last):
File "C:\Users\XYZ\AppData\Local\Programs\Python\Python39\Scripts\lunar.py", line 44, in
main()
File "C:\Users\XYZ\AppData\Local\Programs\Python\Python39\Scripts\lunar.py", line 26, in main
lunar.start()
File "C:\Users\XYZ\AppData\Local\Programs\Python\Python39\Scripts\lib\aimbot.py", line 120, in start
cv2.rectangle(frame, x1y1, x2y2, [0, 0, 255], 2) #draw the bounding boxes
TypeError: function takes exactly 4 arguments (2 given)
PS C:\Users\XYZ\AppData\Local\Programs\Python\Python39\Scripts>

Low FPS

It's not a real issue but when I use this Aimbot then I have between 15 and 30 FPS, but I have an Nvidia RTX 2070 Super OC
Can you possibly tell me why it is like that?

But your Aimbot is working (Performence is low but the rest is working :) )
Filme   TV 08 07 2021 19_36_19

mouse pointer runs to the top left corner

Hi,

I`m trying to use it playing warzone. It targets my enemies but when I press the right mouse buttom the pointer runs to the top left corner of the screen. What am I doing wrong?

FPS issue in the software

Currently when im using lunar with fortnite im having fps issue in the software. it goes for 40 fps to 1-5 fps when im using the aimbot. It also freezes sometimes and makes the aim not working properly.

image

If you could help me i would apreciate !

tutorial

can you make tutorial im new idk all this and dont know how to do this <3

pip install

Im having issues installing the stuff in requirments, It gives me this error
Looking in links: https://download.pytorch.org/whl/torch_stable.html
ERROR: Could not find a version that satisfies the requirement torch==1.8.1+cu111 (from versions: 0.1.2, 0.1.2.post1, 0.1.2.post2)
ERROR: No matching distribution found for torch==1.8.1+cu111

I get an error

I have already installed the necessary dependencies using pip
I have python 3.8 and cuda 11.1 installed.

Traceback (most recent call last):
File "lunar.py", line 74, in
main()
File "lunar.py", line 21, in main
lunar = Aimbot(collect_data = "collect_data" in sys.argv, controller = "controller" in sys.argv)
TypeError: init() got an unexpected keyword argument 'controller'
image

I also tried with the latest version of python

update: I downloaded an old version of Lunar and it worked correctly.

Error when running on linux

Is there a way to run this on linux? I get an error when installing requirements.txt and when running python lunar.py.
Screenshot from 2021-08-15 15-50-52
Screenshot from 2021-08-15 15-56-55

Driver for Python

I have a ''driver'' and some things to improve the script, add me to discord pls : isv#5460

controller

so I ried with a controller it did not work, is there like anything I can do to make it work. I have ReWASD and other 3rd party software. what do you recommend.

AMD GPUs

Do you think this would work at all without CUDA? I know you mention that performance will suffer without it, but is it worth trying without using an NVIDIA card?

Error when running on linux

When I try to run python3 lunar.py I get an error -

Traceback (most recent call last):
File "lunar.py", line 6, in
from pynput import keyboard
ModuleNotFoundError: No module named 'pynput'

No detecting player

I installed all the things and followed the tutorial but the program doesn't detect the players

RuntimeError!

image

hello,
What is problem?
how to fix it?
My GPU: GTX Rog 1650

No config file..?

[INFO] Loading the neural network model
Downloading: "https://github.com/ultralytics/yolov5/archive/master.zip" to C:\Users\User/.cache\torch\hub\master.zip
YOLOv5  2021-7-12 torch 1.8.1+cu111 CUDA:0 (NVIDIA GeForce GTX 1660 SUPER, 6144.0MB)

Downloading https://github.com/ultralytics/yolov5/releases/download/v5.0/yolov5s.pt to C:\Users\User\.cache\torch\hub\ultralytics_yolov5_master\yolov5s.pt...
100%|█████████████████████████████████████████████████████████████████████████████| 14.1M/14.1M [00:01<00:00, 11.8MB/s]

Fusing layers...
Model Summary: 224 layers, 7266973 parameters, 0 gradients
Adding AutoShape...
[!] CUDA ACCELERATION IS UNAVAILABLE
Traceback (most recent call last):
  File "C:\Games\Lunar-main\lunar.py", line 74, in <module>
    main()
  File "C:\Games\Lunar-main\lunar.py", line 26, in main
    lunar = Aimbot()
  File "C:\Games\Lunar-main\lib\aimbot.py", line 85, in __init__
    with open("config/config.json") as f:
FileNotFoundError: [Errno 2] No such file or directory: 'config/config.json'

Not sure why this is happening.

Error

Hello,i have error,can you help me plz.......
rhbgvfcde

Aimbot Training

The aimbot works great, love your script. I have been training my own models for games. One of the issues I have is I get an increase in false positive detections with my models. Any good tips on what types of screenshots to use? I use a mix of clean and messy images. Thinking the messy images may be causing the conflicts. I use around 1500 images, is that too many or too few for the yolov5s model? Any tips would be greatly appreciated. cheers!

unable to draw the bounding boxes?

   cv2.rectangle(frame, x1y1, x2y2, [0, 0, 255], 2) #draw the bounding boxes
cv2.error: OpenCV(4.5.2) :-1: error: (-5:Bad argument) in function 'rectangle'
> Overload resolution failed:
>  - Can't parse 'pt1'. Sequence item with index 0 has a wrong type
>  - Can't parse 'pt1'. Sequence item with index 0 has a wrong type
>  - Can't parse 'rec'. Expected sequence length 4, got 2
>  - Can't parse 'rec'. Expected sequence length 4, got 2

Players are not detected

In the program it says that cuda is active but then in lunar vision it does not detect the players.
I do not get the picture that marking the player

Low FPS

I have only between 15 and 30 FPS but I have an Nvidia RTX 2070 Super OC.
Can you tell me why?
Filme   TV 08 07 2021 19_42_55

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.