duanduanxi9441 2012-04-20 17:19
浏览 53
已采纳

实时图形浏览器mmo游戏,语言选项?

i cam across some older topics about this but since there is a lot of new techniques for creating web content i have to ask again.

My background: I have good knowledge of xhtml/css/javascript/php/mysql. I have no trouble making a webshop from scratch including a comprehensive database and a cms to easily add/modify products. I am very comfortable using PHP and mysql to store data. A attempt at a tribal wars clone does not scare me at all. I also made a couple of games with c#/xna but i am still considering myself novice. I dabbled with flash and feel this could probably be used to get the result i want.

My project: A 2D mmo tactical shooter. Players should be able to move across a fairly large maps and get position updates of other users very quickly. The game will hold a lot of maps and most maps should be able to handle just a couple of players. Hub maps and maps of interest however should be able to handle at least 100 players without lag.

It would be awesome if combat could be resolved real time on the map but i already thought of other ways to resolve this like opening an instance map where players could enter to join combat. I'm also considering a more tactical turn based approach on combat but it depends on the pro's and con's of real time combat.

To sum it up: I am sure i can manage everything except for the graphical implementation. Mysql should not have much trouble querying the local player positions in a couple of milliseconds.

I cam across a game named Deeppolis that pretty much resembles graphically what i want. I'm still considering making this as a downloadable client but i am very interested what my options are if i'm going to do this browser based as browser based games tend to get more people attracted.

Thanks for reading this wall of text :D.

  • 写回答

1条回答

  • dougang6821 2012-04-20 17:46
    关注

    you would not want to "query mysql" to get player positions if this is real time. You will want to create a socket server that all clients connect to. the socket server would keep a subscriber list of all connected clients in memory. this way when one client sends a message to the socket server, the socket server can immediately push needed data to whichever clients need it. you would also want to keep a model of the game state in memory in your socket server to prevent cheating etc. you would only use a database for long term storage, everything else should be in memory. also keep in mind shared servers will likely not allow you access to sockets to create a socket server, so you will need a private server.

    client side: javascript & socket.io (socket client)

    server side: javascript & node.js (socket server)

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 素材场景中光线烘焙后灯光失效
  • ¥15 请教一下各位,为什么我这个没有实现模拟点击
  • ¥15 执行 virtuoso 命令后,界面没有,cadence 启动不起来
  • ¥50 comfyui下连接animatediff节点生成视频质量非常差的原因
  • ¥20 有关区间dp的问题求解
  • ¥15 多电路系统共用电源的串扰问题
  • ¥15 slam rangenet++配置
  • ¥15 有没有研究水声通信方面的帮我改俩matlab代码
  • ¥15 ubuntu子系统密码忘记
  • ¥15 保护模式-系统加载-段寄存器