doulian4467 2014-04-15 04:04
浏览 18
已采纳

同步PHP服务器和android倒计时器

I'm creating an android game timer. The countdown timer in PHP server should be equal to the timer in android app. Timer should always run. If the game finished, It should create a new timer for the next game. Should I use Server time or I have to set fixed time for game?

  • 写回答

1条回答 默认 最新

  • donglu3184 2014-04-15 04:08
    关注

    I would use a database to store the time the game started, then you can call up the current time from the server/database as well as the start time of the game and use a function in your android app to countdown/calculate the difference.

    More detail might be key for better answers.

    Cheers!

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

报告相同问题?

悬赏问题

  • ¥15 我这模型写的不对吗?为什么lingo解出来的下面影子价格这一溜少一个变量
  • ¥50 树莓派安卓APK系统签名
  • ¥15 maple软件,用solve求反函数出现rootof,怎么办?
  • ¥65 汇编语言除法溢出问题
  • ¥15 Visual Studio问题
  • ¥20 求一个html代码,有偿
  • ¥100 关于使用MATLAB中copularnd函数的问题
  • ¥20 在虚拟机的pycharm上
  • ¥15 jupyterthemes 设置完毕后没有效果
  • ¥15 matlab图像高斯低通滤波