Android: Turn based network capable game engine - android

This may be ambitious, but in stackoverflow i trust...
I am wondering about the capabilities and possible road blocks would be for creating a turn based network capable game engine for the android platform, and would be played in a similiar fashion to games such as "Words with Friends" ect.
This engine would be tailored to a card game and would only require data packets sent between peers every time a player takes his/her turn. Game resources such as images and sounds may have to be downloaded from a central server and stored on the android device's temporary storage in order to reduce the amount of storage that the app would have to permanently have on the device.
Before I invest a lot of time into this project I figured I would ask some initial questions.
What limitations/roadblocks does a seed/turn based network game provide to a developer?
Is integrating an ingame microtransaction based shop using a service such as PayPal a possibility?
Will packets between peers need to be encrypted to prevent cheating?
How is it possible to validate clients from a central server to prevent piracy?
What is the best method for balancing lightweight storage/cpu requirements, while still having crystal clear graphics?
Is it a good idea to learn java seperately from using the android SDK, or just jump right in?
Thanks!

Networking adds complexity; see if you can make single player first
Yes, but frowned upon; Google prefers, and may some day insist, that you use their in-app feature.
Yes, if you substitute "discourage" for "prevent"
Login authentication for the networking to work is one way.
If the UI has 3D graphics, use OpenGL, otherwise, use Canvas or even HTML5
Jump

Related

Implementing online connectivity and multiplayer/PVP for a newbie

Background
I'm a noob programmer looking to create a simple turn based mobile game as a side project. I've pretty much got the game logic down and am left with implementing the online multiplayer/PVP portion.
More specifically, i'm looking to implementing a system when the player clicks play and will be matched with an opponent in a 1 v 1 format, without any lobbies etc etc.
I'm currently trying to develop my game in android studio(i'm new) but am also open to unity if it makes the development easier.(I have no experience in Unity).
What i want to know
From what i understand,i need to create and host my own server for the multiplayer to run(i.e matching of player to opponent). Do i also need the server to run the game itself or am i able to connect the player to the opponent and simply record the result of the game to my server/database?
Also, how would i go about creating and running/hosting the server? I heard nodeJS is a good choice for writing the server.
Can anyone point me to a good resource/tutorial for creating and running my own server, and if possible free(or cheap) hosting for my server?
Also, is unity a better choice than android studio for my game?
End Goal
I just wanna publish my game onto the app store,IOS store,etc etc.
If you don't have any experience with creating multiplayer games, I'd recommend looking into one of the several ready-made solutions available on the market (Unity Multiplayer is one such service). You could essentially make your entire online game without ever needing to code a server.
Coding game servers is more work than you think. You'd first need to make a working game server, then you'd need to consider hosting, data storage, scaling, ping, etc. The downside is that you'll get less customizability and less security (you'll need to handle much of the game client-side, which means you're susceptible to hacking by modification of the client, known in the android world as "mods"). However, if you're just starting out, a game server of your own will probably do more harm than good.
You should always choose a multiplatform engine for mobile games. You do not want to code your entire game twice. So yes, Unity is a good choice, and it's the de-facto standard for mobile these days. If you're going to be making games, learning Unity is a worthwhile investment.
Last, and this one comes from my personal experience only with no real statistical data to support it, people who implement game servers with node often end up discovering that their server just can't handle the load, which leads to a need for stacking a whole lot of technologies up on one another to scale the server(s) out or squeeze more performance in some way. It'll often prove to be bad choice in the long run. Or then again, maybe the people I know just aren't good with node.

Android two-player game, online play

I have a simple two-player android game (like Chess), and I want to add some functionality for users to play against each other online. I would prefer to make this as simple as possible (so no complex website where users meet each other and maintain a rating, etc.; instead, just the ability to somehow "look-up" your buddy and have a quick game against him or her).
First of all, is there any way to do this peer-to-peer? From my research, it looks like no, or at least there is no "easy" peer-to-peer method. Admittedly, I haven't looked much into p2p for Android in a while...
The other way then, would be to set up a server, but I have no idea how to do this. Does anyone have some links, info, etc. about how to set up a simple server for enabling online gaming like this?
Thanks!
The problem with p2p is going to be discovery i.e how do players discover each other or their address for communication. The other problem with p2p is that players phones are often going to be behind NATs and if both are behind a NAT then they will need a intermediary between them for communication. These are two common reasons why a server is required even for the simplest of multiplayer games.
Is your game an asynchronous turn based game like words with friends?
There are options of using cloud service for such a game as well so that you just do Android development and access a webservice for storing game data and sending push notifications to update the other player of his/her turn. You can take a look at this https://github.com/shephertz/App42-Tic-Tac-Toe sample on how to do it.

system for bidirectional realtime communication between tablets and server

We are going to build a multiplayer game.
The idea is that every player has a tablet and is connected to a server.
The server should control the game logic, while the clients (the tablets) will only serve as a frontend to the game.
We need to make a decision about the frameworks/programming language we are going to use.
A crossplatform frontend would be cool, but is not mandatory. It has to run on Android devices at least.
The communication between the server and the client must be bidirectional and realtime.
We don't care about a small amount of delay.
Currently we consider an HTML5 client in combination with a javascript server (running upon nodejs) to be the best option.
The communication would be managed by the javascript library socket.io.
The HTML5 frontend can be run either in-browser or as an app (built with PhoneGap).
However we did not decide yet since we want to be sure to make the right choice.
There might be frameworks that can do a better job.
Does anyone know a better solution?
Play 2 is great for this well, but node/socket are great choices too. I would use backbone.js for the front end as it gives you a lot of flexibility and it's easy to keep the views in sync. (there is an example of such an app on my github if you're interested)

Game server infrastructure for two players turn based board phone game

I tried to do my homework in this topic, but unfortunately with no luck, at least the picture not as clear I can start digging deeper or registering for a service etc.
What I am trying to implement: Simple 2 player board game, with CPU or internet opponent. The game is a phone game for all the 3 platforms iPhone, Android, WP7. (please do not harm WP7:-)
One option is go to some cloud (Azure, Amazon) and implement some game server. Sounds reinventing the wheel, but maybe there is an open source implementation. (only ASP.NET because my skills)
My current understanding my other and preferable option is using a service like Openfeint or ScoreLoop (bought (and eaten?) by RIM :-().
Unfortunately it is not clear for me (after reading the two FAQs) if besides of high score lists and maintaining statistics is any of game server is capable to conducting a board game between two authenticated player?
Could anyone point me where to start? (or suggest me a WP7 sample or marketplace game which uses a public game server for two player board game internet gameplay?)
Thx for answers
I also wanted to develop a multiplayer game and examined Openfeint, Scoreloop and Skiller. I ended up using Skiller as my multiplayer engine, since it was the only one that supports multiplayer and it works great.
Hope i helped.
Look at Azure for social games toolkit https://github.com/WindowsAzure-Toolkits/wa-toolkit-games
There as some areas of concern outside of the logic of just the game.
User Identity and Authorizing. (Game Center)
Game Data Persistence and Storage. (Cloud Database like AWS DynamoDB)
Game Match Queuing. (AWS SQS) Don't attempt this with a database using pessimistic concurrency.
Notifications of Match Players are ready for sleeping clients. (AWS SNS to APNS/Google to Endpoint(this mobile device))
Polling or Notification for Next Move. (AWS SQS or SNS) I wouldn't poll a Database for this.
Those services are just example recommendations. I don't work for Amazon, they are the easiest and most affordable to get up and running but there maybe better services out there. I found them with your same requirements in mind. I don't want to commit to 100 bux plus a month if my idea is a boon-dongle.
You could do all that listed above to start out for under $15 a month using cloud services. The best thing is if your idea takes off you simply bump up the thresholds on those with a flick of a switch from an admin portal. Some automatically scale.

How to find out the cost of our Android App or project before developing?

Actually I have a Client-Server based application developed on vb.net/C#.net now i want to port or publish that client-server Application on Android. I knew the tools for making it useful for my Android device. And I have also make out some important point to find out the cost of that project, but i'm newbie so i can't understand how to give assign or fix a amount for particular task in android. My Points are:
Develop a jazzy look user Interface for displaying a data.
Check and use the Device's network connection state.
Use the web service for accessing the method/functionality of
client-server application.
Also check and use the state of web service whether it is available
or not and use the functionality or fetch the data on the basis of
state.
Also the main thing is to maintain the server for storing the data
and fetching the data via web service.
Any help is appreciated for finding and assigning the cost/price/amount to the Android application.
This usually depends on the size of your target market. If you have a large target market, you can let the app go at a low price, because volume and economies of scale will kick in bringing your costs down while your revenues go up.
If you have a smaller target market, you're going to have to bump up the price of the application in order to recover costs of delivering to such a small market and move into the positive for profit loss.
For the most part, you can ignore the cost of developing your app. Development is mainly a one-time fixed cost that disappears over time. There will be some maintenance of the application itself that will cost money over time, but it isn't enough to worry about. Your server maintenance will be the brunt of your costs, but provided you're able to outsource most of the storage and bandwidth onto Amazon's extremely cheap pay as you go servers, you're running costs will be relatively low as well.
The greatest majority of your budget will be spent on marketing (depending on the type of app you are developing). Should you get a shoe in with the press, or market through ads on mobile, Facebook and the like. This is where most of your money will be going. Make sure to offset the cost of conversion with the revenue generated by conversion.
If you gave me more details, I could get more specific and help you out some more, but with what I have to go on, I have to stay broad. I wish you the best of luck with your venture.

Categories

Resources