Can jxta be used to develop online card game (p2p style)?
Can jxta be used to develop online card game (p2p style)?
https://www.java.net//node/677134
I am new to jxta.
The game need 4 players, so 4 peers in a group can play it.
There will be no additional server.
Can jxta support it?
When the group has 3 peers, and the 4th peer join, the game should start on all 4 peers.
Can all 3 peers learn the 4th peer's joining at the same time?
My worry is synchronization
————————————————————————————————————————————————
Technically speaking, JXTA can allow 4 peers to play together. No issue with that.
Regarding synchronization, the solution I would suggest is to centralize registration within one peer (for example, that peer creates a 4 player tables) and have other peers request to join that table. The central peer would grant such a request (or not) and notify the three other peers when the table is full to start playing.
Cheers,
J.
——————————————————————————————————————————————
If a peer act as central server, it'll be easy to program
but it'll be far less robust
what if the central server fail?
————————————————————————————————————————————————
Hi,
No. No peer as to act as a central server. Any peer can offer to create a table and any other peer can as to join. The peers who create a table just notify other peers in the group.
Cheers,
J.
Can jxta be used to develop online card game (p2p style)?的更多相关文章
- JXTA 2: 具有高性能、海量伸缩性的 P2P 网络
这是来自developerWorks的一篇文章,地址是 https://www.ibm.com/developerworks/cn/java/j-jxta2/ ———————————————————— ...
- Atitit JAVA p2p设计与总结 JXTA 2
Atitit JAVA p2p设计与总结 JXTA 2 JXTA 2 是开放源代码 P2P 网络的第二个主要版本,它利用流行的.基于 Java 的参考实现作为构建基础.在设计方面进行了重要的修改,以 ...
- jxta 2.8x启动了
http://chaupal.github.io/ ———————————————————————————————————————————————————————————————————— 至少两个月 ...
- 左侧带三角的Card css支持hover阴影
<div class="inputReportIndex"> <div class="inner"> <div class=&qu ...
- cPage分页,asp.net自定义分页,url传值分页,支持datalist、gridview、Repeater等
asp.net分页是最最常用的功能,实现方式也很多,使用不同的控件有不同的分页方式. 下面分享一个我们团队内部使用了多年的一个分页控件cPage,是自己设计编写,没有冗余,简单.快速. cPage,现 ...
- JavaScript验证
<script type="text/javascript"> /*密码*/ function password() { var pas ...
- css3 --- 翻页动画 --- javascript --- 3d --- Action
用css3和javascript做一个翻页动画<Action> 如有疑问请参照我的上一篇随笔:http://www.cnblogs.com/kodoyang/p/Html_Css3_Car ...
- ecshop开发日志之手机端虚拟商品自动发货
在ecshop官方模版收,web端的虚拟商品购买后不能像pc端那般直接在付款后出现虚拟商品的卡号,密码,截止日期一下为让手机购买也可以在付款后自动显示发货并能显示卡号密码截止日期首 先找到pc端的fl ...
- Linux 内核模块编译 Makefile
驱动编译分为静态编译和动态编译:静态编译即为将驱动直接编译进内核,动态编译即为将驱动编译成模块. 而动态编译又分为两种: a -- 内部编译 在内核源码目录内编译 b -- 外部编译 在内核源码的目录 ...
随机推荐
- UPC 2224 / “浪潮杯”山东省第四届ACM大学生程序设计竞赛 1008 Boring Counting 主席树
Problem H:Boring Counting Time Limit : 6000/3000ms (Java/Other) Memory Limit : 65535/32768K (Java/ ...
- 创建高安全性PHP网站的几个实用要点
大家都知道PHP已经是当前最流行的Web应用编程语言了.但是也与其他脚本语言一样,PHP也有几个很危险的安全漏洞.所以在这篇教学文章中,我们将大致看看几个实用的技巧来让你避免一些常见的PHP安全问题. ...
- heatmap.2
heatmap.2 {gplots} R Documentation Enhanced Heat Map Description A heat map is a false color image ( ...
- freemarker判断记录集是不是为空
#if($personals)这样写 直接把记录标识符放在if里面就可以了
- Asp.Net连接Mysql报错Out of sync with server
Asp.Net连接Mysql报错Out of sync with server 原因:程序引用的MySql.Data.dll版本高于服务器版本 解决:下载一个低版本的MySql.Data.dll,项目 ...
- Android异常之 unable to write jarlist cache file
异常: android开发调试时候不能运行,出现 unable to write jarlist cache file 错误. 解决方法: 1.找到appcompt文件夹如下的位置.
- c++实现输入法窗口自定义的代码
#pragma once #include <Windows.h> #include <imm.h> #include <string> #pragma comme ...
- Nginx & AWStats 安装、配置、使用
—— 参考IBM文章:THIS , 不一样的指导顺序 —— 1. awstats分析nginx - access.log,网上资料大部分都是下载,然后配置.官网下载地址: http://awstats ...
- Java [Leetcode 326]Power of Three
题目描述: Given an integer, write a function to determine if it is a power of three. Follow up:Could you ...
- hdu 2204 Eddy's爱好
// 一个整数N,1<=N<=1000000000000000000(10^18).// 输出在在1到N之间形式如M^K的数的总数// 容斥原理// 枚举k=集合{2,3,5,7,11,1 ...