Phone Game Needs No Server
Multiplayer games on mobile devices usually need remote servers–but not this one.
A new augmented reality game can run on two Android phones, over 3G or Wi-Fi, without an additional server. The unique networking method used for the game could be quite useful for those working on disaster relief or in the military, where significant infrastructure isn’t always available.
Multiplayer games on mobile devices like phones usually require remote servers for communication between devices and game hosting, says Roelof Kemp, a computer scientist at Vrije Universiteit, in Amsterdam, the Netherlands, who codeveloped the game. But the game allows phones to communicate without the cost and added complexity of maintaining this additional infrastructure, he says.
“We hope it’s going to open the door for new and interesting distributed computing applications,” says Kemp.
The game uses a computing middleware system, called Ibis, originally developed for high-performance, distributed computing tasks, such as image processing or astrophysics research, but which Kemp and colleagues have adapted to run on Android phones. “It allows each phone to run a lightweight communication server,” says Kemp. The devices can communicate directly with the game, which is hosted on both handsets, using a 3G connection or Wi-Fi.
Known as Photoshoot, the game offers a modern-day take on the old gun-slinging shootouts of the Wild West by fusing the real world with virtual play. It’s simple enough: two players walk three steps away from each other, turn and shoot. But instead of firing bullets, a player tries to shoot a photograph of his opponent, lining up the onscreen crosshairs in the camera’s viewfinder with the opponent’s face. Each player has up to six shots, and the first to “shoot” their opponent in the face wins.
The game was developed in response to the Android Developers Challenge 2, launched by Google to encourage the development of innovative applications for its Android phones. Consequently, the game was designed to use data fusion, bringing together many different aspects of the device’s hardware in order to combine the gameplay with real events in the world.
The accelerometers and digital compass built into Android phones allow the game– distributed on both phones–to act like the referee, making sure each player has taken three steps and doesn’t turn too soon. “And to evaluate if it was a hit or a miss, we use a face-detection algorithm,” says Kemp. This works even if the face is partly obscured by the other player holding their phone in front of it, he says.
Even the process of pairing the two devices is novel, says Nicholas Palmer, who developed the game with Kemp and colleagues Thilo Kielman and Henri Bal. The pairing process takes place before the game begins. First, one phone generates a bar code that encodes the phone’s IP address. This bar code is displayed on the phone’s screen. The other player then uses their phone to take a picture of the bar code–in essence, scanning in the IP address of the phone. “This pairs the two phones,” says Palmer.
While these sorts of innovations help to extend augmented reality into the mobile gaming arena, the real innovation here is the communication system.
“There are a lot of situations where you would want to start interactions quickly between phones and mobile devices,” says Morris Sloman, a professor of distributed computing at Imperial College London, in the UK. Such a system could be particularly useful for military operations. Currently, there is a trend toward using Internet-enabled phones in the military, but ideally phones could communicate with each other even in areas where there is no infrastructure. Such a system would also be useful in disaster relief efforts, when infrastructure has been destroyed.
But Sloman questions whether a commercial system will be reliable if a Wi-Fi connection is not available. “In Europe, many service providers will not allow incoming data connections on their 3G networks.” Although outgoing transmissions are allowed, incoming data usually has to go through the network’s secure servers, he says. Palmer and Kemp accept that there may be issues with different network providers.
Photoshoot will be presented at the Mobile Opportunistic Networking workshop in Pisa, Italy, next week, and should be available to the public in the next couple of months. But in the long run, the hope is that its underlying ad hoc network capabilities will find broader use, says Palmer.
There are other possible ways to allow mobile devices to pair and connect, such as the protocols Bonjour and Universal PnP, says Blair MacIntyre, director of the Augmented Environments Lab at the Georgia Institute of Technology in Atlanta. And similarly, the iPhone app Bump allows pairing and information exchange between multiple devices on an ad hoc basis, just by bumping them together, he says.
However, Bump still relies upon remote servers, says Kemp. And both Bonjour and UPnP only work within a single Wi-Fi access point.
Become an MIT Technology Review Insider for in-depth analysis and unparalleled perspective.Subscribe today