-2
  • Channel Api 允许从服务器拉更新到客户端。但无法将数据发送回 socket 。我们需要向服务器发出 Ajax 请求,这意味着它比直接通过套接字发送非常慢。

  • Appengine 适用于 web,基于 socket 的游戏,我们无法控制 appengine 实例的关闭和重启。游戏对象需要保存到数据存储和内存缓存(非常慢)。后端可能是一个可以接受的解决方案,但我认为它不能作为在线网页游戏的专用服务器。

我仍在寻找appengine上socket webgame的解决方案

4

2 回答 2

1

你刚刚回答了你自己的问题。App Engine 不是动作游戏等超低延迟操作的好平台。寻找另一个平台。如果延迟不是什么大问题(即回合制游戏),App Engine 应该可以工作。

套接字 API 可能也不适合您,因为它适用于出站套接字。

于 2012-11-06T15:26:40.317 回答
0

If your game will have a small number of users then a dedicated "normal" server would be fine, of course.

If, however, you want your game to potentially scale to a far higher number of users then you have to design it accordingly and that means (probably) separating out logic (backend) and interaction with users (frontend). As you say, you don't want a server containing the only copy of the game to just shutdown. Backends won't do that.

You can sign up to the Sockets Beta which may be what you need instead of the channel API.

于 2012-11-06T10:31:41.957 回答