在应用程序中实现聊天?

发布于 2024-07-13 18:41:00 字数 200 浏览 4 评论 0原文

我正在制作一个游戏,并且在服务器端使用 Python。

使用 Python 自己实现聊天是相当简单的 - 这不是我的问题。
我的问题是
我只是想知道是否有任何预制的聊天服务器或某种我可以在游戏中实现的服务,而不是滚动自己的聊天服务器?
也许就像我可以在游戏服务器进程旁边运行一个不同的进程?

I'm making a game and I am using Python for the server side.

It would be fairly trivial to implement chat myself using Python - that's not my question.
My question is
I was just wondering if there were any pre-made chat servers or some kind of service that I would be able to implement inside of my game instead of rolling my own chat server?
Maybe like a different process I could run next to my game server process?

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

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

发布评论

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

评论(3

狂之美人 2024-07-20 18:41:00

我建议使用 XMPP/Jabber。 有很多不同语言的客户端和服务器库。 它是免费/开源的。

http://en.wikipedia.org/wiki/XMPP

I recommend using XMPP/Jabber. There are a lot of libraries for clients and servers in different languages. It's free/open source.

http://en.wikipedia.org/wiki/XMPP

青芜 2024-07-20 18:41:00

老实说,我认为您最好自己推出并将其与您的程序紧密集成。 我知道重新发明轮子是没有意义的,但在你的情况下这样做有几个优点:集成、学习、安全性和简单性。

Honestly, I think it'd be best for you to roll your own and get it tightly integrated with your program. I know there's no sense in reinventing the wheel, but there are several advantages to doing so in your case: integration, learning, security, and simplicity.

不羁少年 2024-07-20 18:41:00

也许你可以使用 IRC 作为聊天服务,我知道 python 的 irclib ,它更像是一个客户端,但理论上,您可以使用它从游戏服务器代理另一个 IRC 服务器。

这有点老套,我只是想提一下。

Maybe you could use IRC as a chat service, I know of irclib for python, its more of a client but in theory, you could use it to proxy another IRC server from the game server.

It's a little hackish, I just thought I'd mention it.

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