Android 手机作为 PC 中的游戏控制器

发布于 2024-12-10 22:00:16 字数 112 浏览 2 评论 0原文

这又是我的论文,如何将我的 Android 手机替换为 PC 中的游戏控制器(特别是方向盘)?我需要使用游戏控制器驱动程序吗?如果我需要这些驱动程序,我该如何使用?我决定将 C# 用于我的 PC 服务器。谢谢。

This is about my thesis again, How can I substitute my Android phone into a Game Controller (specifically a steering wheel) in a PC? Do I need to use game controller drivers? and how can I use these drivers if i need one?. I decided I will use C# for my PC server. Thank You.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

半世晨晓 2024-12-17 22:00:16

在 Android 端

您可以使用加速计坐标来实现此目的。它可以轻松充当方向盘。您只需相应地读取并绘制坐标即可。您可以在后台将数据发送到服务器,即您的 PC。然后该服务器将向游戏发送命令

在PC上

您可以使用此方法找到游戏窗口http://www.pinvoke.net/default.aspx/user32.FindWindowEx

然后你可以使用这个将键盘按键发送到游戏窗口
http://www.pinvoke.net/default.aspx/user32/SendMessage.html

On Android Side

You can use Accelerometer coordinates for this purpose. It can easily act as an steering wheel. You will just have to read and map the coordinates accordingly. Behind the scene you can send data to a server i.e. your PC. This server will then send commands to the game

On PC

You can find the game window using this method http://www.pinvoke.net/default.aspx/user32.FindWindowEx

Then you can send keyboard keys to game window using this
http://www.pinvoke.net/default.aspx/user32/SendMessage.html

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文