Git Product home page Git Product logo

fengjixuchui / aiassistc Goto Github PK

View Code? Open in Web Editor NEW

This project forked from dengqizhou30/aiassistc

0.0 0.0 0.0 210.76 MB

AIAssistC是一个AI游戏助手,使用OpenCv、DNN、ssd_mobilenet/efficientdet、hidriver、MFC等技术,截取游戏屏幕进行对象识别,使用虚拟鼠标键盘驱动实现自动瞄准/自动开枪等功能,提升玩家的游戏体验。

License: Apache License 2.0

C++ 98.52% C 0.21% C# 0.05% PowerShell 0.15% Python 1.08% PureBasic 0.01%

aiassistc's Introduction

通告:本项目不再更新,新项目地址 https://github.com/dengqizhou30/AIAssistOpenCV
新项目做了重构简化,已发布可运行程序,有兴趣的兄弟可以下载试用 https://github.com/dengqizhou30/AIAssistOpenCV/releases

AIAssistC 是c++版本的AIAssist,原来c#的版本,由于使用的OpenCvSharp4不支持显卡CUDA加速,而游戏中检测速度是关键,所以再做有一个c++版本。
目前已实现了图像检测、自动追踪、自动开火等主体功能。GPU加速已经开发成功,这块坑很多,有时间整理下相关内容。
GPU加速的建议是不要尝试需要自己编译GPU功能的框架,非常浪费时间。直接选择提供预编译好支持GPU的运行库,如TensorFlow C API,可以节约大量时间。
原来的c#版本不再更新,感兴趣的可以参考 https://github.com/dengqizhou30/AIAssist

版本变更:
V1.2:
1、系统不再依赖鼠标键盘驱动程序,移除相关子项目,简化整个工程解决方案。
2、鼠标键盘驱动程序相关子项目,迁移到独立的工程中 https://github.com/dengqizhou30/HIDDriver

一、项目说明:
AIAssistC是一个AI游戏助手,使用OpenCv、DNN、tensorflow c api、cppflow、ssd_mobilenet/efficientdet、hidriver、MFC等技术,截取游戏屏幕,使用AI模型进行对象识别,并实现自动瞄准/自动开枪等鼠标操作,提升玩家的游戏体验。

二、工程说明:
AIAssist:mfc前端UI子工程;
AIAssistLib:AI助手静态库子工程;
Data:存放模型文件及工具文件的子工程;
HIDDriver:windows鼠标键盘驱动子工程,已移除;
HIDDriverLib:鼠标键盘驱动调用库子工程,已移除;
HIDDriverLibTest:鼠标键盘驱动调用库验证测试子工程,已移除;
OpencvTest:openc功能验证测试子工程;

三、主要的运行库:
1、intel贡献的大神级图像处理框架OpenCv:
https://opencv.org/

OpenCV DNN 模块目前支持多种AI对象检测模型推理运行:
https://github.com/opencv/opencv/tree/master/samples/dnn
https://github.com/opencv/opencv/wiki/TensorFlow-Object-Detection-API
https://github.com/openvinotoolkit/open_model_zoo

2、TensorFlow C API运行库,cppflow是TensorFlow C API的C++封装库:
选择使用TensorFlow C API运行库的原因,是因为它提供编译好的支持GPU的运行库,而其他框架都需要自己编译。
https://tensorflow.google.cn/install/lang_c
https://github.com/serizba/cppflow
https://serizba.github.io/cppflow/quickstart.html

3、谷歌tensoflow的对象检测模型efficientdet-lite0、ssd_mobilenet_v3:
实测gpu加速效果,efficientdet-lite模型比ssd_mobilenet好很多
https://hub.tensorflow.google.cn/tensorflow/efficientnet/lite0/classification/2
https://github.com/tensorflow/models

四、使用注意:
1、使用小技巧:目前基于AI图像检测,只做到了人员识别,无法区分敌我。为避免游戏中自动追踪并射击队友的尴尬,有一个使用技巧。 目前在工具中加入了控制逻辑,只有切换到主副武器时才会运行自动追踪和自动射击,切换到其他武器时不会自动追踪。 所以在捡枪或者跟队友跑时,切换到手枪或其他数字键,停止自动追踪。对敌时再切换到主副武器(数字键1或2),自动追踪才生效。 习惯这种操作方式后,这个工具使用体验相对好一些。

2、使用windows api实现了鼠标键盘操作模拟,HIDDriver驱动程序不再是必须项。在绝地求生、逆战、穿越火线三个游戏上测试,windows api可以正常工作。

3、HIDDriver驱动已移除工程,这个驱动目前还没有微软颁发的正式证书,只能在win 10测试模式下执行。如果要尝试,参考项目说明:
https://github.com/dengqizhou30/HIDDriver

五、游戏截图:
穿越火线游戏截图:
blockchain
blockchain

aiassistc's People

Contributors

dengqizhou30 avatar eternaltitan avatar fengjixuchui avatar

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.