• Advertisement
Sign in to follow this  

Unity [web] ideas for multiplayer web-based game framework/platform

This topic is 3298 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi, I am currently working on a game but once I get some free time, maybe I like to start a small project which is to provide a community web-based game development platform. I am at the initial "conception" stage and tyring to see if it is worthwhile to pusue this and any feedbacks would be appreciated. The thing I want is a web site that provides a central location for users to sign up using SSO mechanism (such as Windows Live ID, Yahoo BBAuth, OpenID, etc) and - provide *game developers* basic API for getting user identity for his/her game - provide *game developers* ability to register their games (such that it will show up in the list of free games) - provide *game users (gamers)" with list of free games - the games can be sigle-player, but encourages multi-player by providing basic match making features imagine, today, to build a simplest multi-player web-based games, you have to manage user accounts/password etc. My service will take care of that part so you can focus on writing game logic. For example, you have a HTML based game (hosted somewhere of your choice). When certain things like a user winning, it makes HTTP forms submition to my service to write to the score board. There are security issues, which I am thining using time-spamped encrypted token passed around (via query string, forms field, etc.) so that game developers can validate it. (and maybe setting up a common secret key between game develper and my site, for symetric encryption, etc.) I have started mental exercise to see if its feasible, and I think it is. I just need to learn more about requirements. Thanks for reading up to this. Apprecaite any feedback, if any. -yoshi

Share this post


Link to post
Share on other sites
Advertisement
It is a cool idea in theory but there are two major issues that would keep me from wanting to use such a service:

Trust.
If your login capability is down, users can't make full use of my game.

There are enough OpenID libraries out now (and Windows Live ID is planning to provide an OpenID 'alias' service sometime in '09) that I might as well just implement OpenID directly rather than using your service.

After all, if I'm competent, one implementation of OpenID could be copied into each new web game of mine until the protocol changes.

I also need to be confident your system being compromised won't cause me any significant problems.

Traffic.
A new service wouldn't have a significant flow of traffic into my game. I'd be more interested in integrating a web-game with an existing portal's login (most of which don't use a SSO except internally) than yours. Especially for games that are essentially stand-alone. (e.g. A flash game I could upload to Kongregate or sell a sponsorship to them)

Neither of them is something time and money can't fix, but it would take more effort than a small project is worth in most people's eyes. In addition, some portals offer paid sponsorships for some of the better flash games.

On the plus side...
Your idea would be more flexible than existing portals (e.g. you could do virtually any web-based game rather than just flash and maybe silverlight) and could 'drag' traffic to the developers site instead of leaving it at the portal. If you were willing to put the time and effort to build up a decent level of traffic (and have no major downtime) you may be able to convince developers to use your service.

________________________________________________________________________________

Beyond that:
The API would need to be usable in Flash, Silverlight, and PHP (as a minimum).

A matchmaking service with lobbies to chat in as well actual matchmaking features.

A good looking portal with enough general 'game portal stuff' (e.g. rating games, reviewing games, voting for your favorite game) for users to be able to treat it like a normal game portal.

_________
Just my 2 cents.

Share this post


Link to post
Share on other sites
Kenneth,

Thanks for your great input.

Your point about handling OpenID by yourself is valid and that it self won't add much value to my service. I haven't done OpenID yet, but Windows Live ID and Yahoo BBAuth were so easy that it takes a day or two to set it up... by anybody. Clearly, I would need to add more than that.

As for trust and reliability, I would almost have to commit to data center and promis some sort of written mimimum guarantee, I suppose. That would be one hurdle to go over. Your feedback reinforces that point - and that might be too high for me to go over, at least in the initial stage. Anyhow, point taken.

Traffic. You are saying that develpers would tend to go to "established" portal rather than a new service that nobody knows about yet. This tendency is stronger for a single player simpler games. Point taken. My feeling after your input is that perhaps I should completely focus on "multi player games" that and forget about "single player games" - a quick googling tells me that there thousands of free game portals already established.

Kenneth, right now I am struggling to understand how "multi-player web-based games" are architected. I am a professional ASP.NET developer so I understand the basic web-based applications. Whether you use HTML, javascript, Flash, Sliverlight (and PHP, ASP.NET, etc. for server side), you have to solve the "stateless" nature of web application. In particular, one of the online users performs an action, which causes some state change on the server side, the only way to get that user's action reflected on other users views is by having a polling mechanism from user agents... correct? Sorry, if this is a dumb quesion - I just want to establish a solid fact here.

If that is the typical web-based multi-player game architecture, then my API has to be designed around that architecture.

Your other inputs: basic match making + some sort of user-to-user communication palform (chat), and attractive UI, seem essential to me to. Thanks for affirmation.


by the way, the game I am developing right now is a client-server app using TCP based on Socket (it used to use DirectPlay but I pulled it out as MS dropped it from the DirectX package). I was thinking I would add support for TCP with binary formatted protocol for future, but do you think there might be more people interested in?

Sorry for a huge message (should chuck it up, I suppose)

thanks.


Share this post


Link to post
Share on other sites
Quote:
Original post by ywatanabe
....

Traffic. You are saying that develpers would tend to go to "established" portal rather than a new service that nobody knows about yet. This tendency is stronger for a single player simpler games. Point taken. My feeling after your input is that perhaps I should completely focus on "multi player games" that and forget about "single player games" - a quick googling tells me that there thousands of free game portals already established.

Quite a few of those portals offer multiplayer games as well, just fyi.
(e.g. http://www.gamedozer.com/battalion/, http://www.flash-game.net/free-games/multiplayer-games.php)

Pretty much every segment of the web game market is serviced by some kind of portal. From the PBBGs to the single player Flash and Silverlight games.
(e.g. http://www.pbbg-portal.com/, http://apexwebgaming.com/)

So, avoiding a section of the market that isn't already serviced by an established portal won't really be possible imo. But no one to my knowledge offers SSO which would allow developers to leech some traffic to their websites instead of letting portals take it all. Just internal login and/or listing for reviews, directory, etc.

Quote:

Kenneth, right now I am struggling to understand how "multi-player web-based games" are architected. I am a professional ASP.NET developer so I understand the basic web-based applications. Whether you use HTML, javascript, Flash, Sliverlight (and PHP, ASP.NET, etc. for server side), you have to solve the "stateless" nature of web application. In particular, one of the online users performs an action, which causes some state change on the server side, the only way to get that user's action reflected on other users views is by having a polling mechanism from user agents... correct? Sorry, if this is a dumb quesion - I just want to establish a solid fact here.

I'm pretty sure no one is using a polling mechanism since there are better alternatives. However, I mostly write PBBGs (in php) for fun so I can't be certain no one is using such a method to get around paying for a 'professional-grade' flash socket server.

Flash
Flash has various socket server offerings.
(e.g. http://www.smartfoxserver.com/, http://code.google.com/p/gfs-server/)

For games that use such an offering, it would just be like a regular client/server game as far as architecture goes. The client would be the flash file displayed on the server which in turn communicates with the server-side code.

(e.g. http://www.tacticsarena.com/)

PBBGs
For PBBGs, you don't really need polling since your really behaving like a normal website (AJAX or otherwise). (e.g. You have your login session, You post the 'build units' form, the database updates with your orders, You navigate to the 'build buildings' page.)

(e.g. http://www.blacknova.net/ source: http://sourceforge.net/projects/blacknova)

As a hobbyist, I'm probably not in a position to say definitively that 'this is typical' but it probably is correct.

Quote:

...

by the way, the game I am developing right now is a client-server app using TCP based on Socket (it used to use DirectPlay but I pulled it out as MS dropped it from the DirectX package). I was thinking I would add support for TCP with binary formatted protocol for future, but do you think there might be more people interested in?

I honestly don't know one way or the other since the games I create never anything more than the basics (e.g. http, whatever protocol an AJAX library I may use uses) for communication.

Quote:

Sorry for a huge message (should chuck it up, I suppose)

NP.

Quote:

thanks.

Your welcome.

Share this post


Link to post
Share on other sites
Kenneth,

Thanks again for detailed reply to my queries.

I never knew the term PBBG, but now I do. You pointed me to several useful links and basic concepts/technologies. I will be busy reading these articles for a while.

I am also going to play some of the PBBG out there to get a feel for requirments, and I probably should write one.

I am still not quite sure how a user who is looking at a page (static) gets the updated world when another modified it... without some sort of polling. Maybe I just don't understand the types of games written in PBBGs. Say, if I were to write a chess game, unless I refresh the browser (to make a HTTP request), I am staring at the stale world data.

Anyway, I have lots of readings/researches. Hopefully, it will come clear gradually.

Thanks,
-y

Share this post


Link to post
Share on other sites
Quote:
Original post by ywatanabe
Kenneth,

Thanks again for detailed reply to my queries.

Your welcome.

Quote:

...

I am also going to play some of the PBBG out there to get a feel for requirments, and I probably should write one.


One of the links I gave you was the source to an open source PBBG. Just in case you missed it:
http://sourceforge.net/projects/blacknova

Quote:

I am still not quite sure how a user who is looking at a page (static) gets the updated world when another modified it... without some sort of polling. Maybe I just don't understand the types of games written in PBBGs. Say, if I were to write a chess game, unless I refresh the browser (to make a HTTP request), I am staring at the stale world data.

Most PBBGs do require you to refresh the browser to get updated data. ;)

They aren't usually games like chess where you'd care about rapid updates of information. They are normally games with hour long 'ticks' which update all the game information periodically. So the user tends to do the following:
log in
use some forms to issue orders (e.g. build, send messages, join an alliance, send armies to steal land)
log out
Repeat in 8-24 hours.


Those that don't, use AJAX or Reverse AJAX.

AJAX could result in polling for information. I don't know why I didn't make that clear in the other post. I'm stupid like that sometimes.

But, Reverse AJAX would not (except at a very low level e.g. OS level). And Reverse AJAX makes more sense for a web-game where information needs regular updating.

Quote:

Anyway, I have lots of readings/researches. Hopefully, it will come clear gradually.

Thanks,
-y


Best of luck finding what your looking for!

Share this post


Link to post
Share on other sites
HI everyone,

I'm very interested in what you are discussing about, I think your idea to build a framework for webgame online is really GREAT!!

I've created a multiplayer web-game on my own and it run quite well but there're so many problems to be dealt with to fully develop this.

You're welcome to take a look and please give me some advice.

Here is the link: http://yugiohnetwork.com

Share this post


Link to post
Share on other sites
Hi thethanghn,

I just looked at your site quickly and looks like you have build a ton of features there. All by yourself? Cool! I don't plya Yugio (what a shame, I am Japanese and grew up there and it was on Shonen Jump magazine... I was just leaving Japan when Yugio started so never got into..)

Anyway...

Yeah, I've been continueing my research on this. I learned what Reverse AJAX is and especially Comet (slow loading) technique that web-game devs can use to build more real-time game.

But my main focus is to build a tool that help build games... not game itself. Here is what I see so far

A web-based games can be broken down to these components:

a. User account management service
b. User scoreboard service
c. Match making service (for multiplayer)
d. Data storage service "P" part of PBBGs
e. Business logic service (the actual game rules and logics)
f. Presentation layer (views, shapes, pages, animations, sounds etc.)

What game developer want to spend most of time is in 'e' and 'f', I think.
'a' is boring but hard and users may have more registance (the feeling you have when you have to provide your name, password, etc to just use a service)

'b' and 'c' might be specific to games, but I think it can be abstracted. Like your Duel system, its 1-on-1, right? For some games, its 2x2 (say, veritual tennis). Some are "free-for-all" up upper limit. And multiplayer team based ones. I think we can support most of these.

'd' is also boring. I just want to "save" data and move on.

So, what if a framework takes care of all of these...?

[Framework]
a. User account management service
b. User scoreboard service
c. Match making service (for multiplayer)
d. Data storage service "P" part of PBBGs

[Your Game]
And you can implement the following at your web site anyway you want.
e. Business logic service (the actual game rules and logics)
f. Presentation layer (views, shapes, pages, animations, sounds etc.)

Obviuosly, there has to be a communication between [Framework] and [Your Game]. If we restrict the communication between these two to HTTP, then many poeple will be able to write games. (I wouid also like to have TCP protocol but that's for later)

That's what I got in my head so far.


Share this post


Link to post
Share on other sites
A framework that takes care of all of that would be good. :)

Although, I think d. may not be possible. To build an efficient database requires too much 'game specific' information...but if you could do it, it would rock.

Share this post


Link to post
Share on other sites
Kenneth,

Yeah, I just did a quick design write up to discover what it would take to build a simple 2-player tic-tac-toe game (sort of mental exercise to handle signing up, match making, game setup, game start, game update, game ending, recording result, etc. using a simple web-based game with ajax/comet).

It is becoming clear to me that abstracting "storage" layer (and above) is just not going to be feasible. Maybe I can serve certain type of games, but creating a virtual database using physical database (while keeping performance reasonable, as you pointed out) is not trivial.

I am gradually shifting from concepts to design/implementation, and hitting lots of issues.

Scoreboard service, which already have lots of variations, is probably where I can realistically stop. I still think SSO, user account management, matchmaking are doabine.

thanks for keeping an eye on this thread!

-y

Share this post


Link to post
Share on other sites
Well, good luck getting everything together. :)

I'm debating about reviving my PBBG website over the summer and starting on a new game...maybe I'll use your framework as one of the various options to login with.

Right now, I'm thinking of trying to integrate it into multiple login solutions (e.g. Facebook, OpenID) while still being able to use a single ID for the forum/rest of the website.

We'll see how it goes...I usually can't get more than a small player base together (or lose interest in making the 'new' game I have an idea for due a lack of collaboration). I'm not good about picking things I can do entirely without a certain amount of decent art, which I can't provide.

Share this post


Link to post
Share on other sites
I think to make a common data storage as you described in "d." is quite hard because it is up to type of game.
We'd better build a mechanism to register a object/entity, control its state during life time of game session so that we're able to build an interface independant to database.
And if we decide the transportation method is Ajax/comet, the data being transported must be game state, which has an common format: JSON, XML... the business logic could break into 2 parts:
- server:
receive object state data --> do game logic --> send object state back to client
- client:
receive object state data --> display, apply logic or do some graphic effect --> periodically send object state to server
We may build interface for each of these.

Another issue: load balancing, caching, update shared data...

Share this post


Link to post
Share on other sites
Hi folks,
I've been thinking about this stuff over the weekend...

Kenneth,

I tried to get to your game but couldn't... is it up and running somewhere that I can get to? Just curious what you have got!

thethanghn,

Yeah, it will be hard. I did an exercise to see if I can abstract storage requirements. I felt is doable but the problem is that I am not aware of ALL game types and have no means to validate abstracted storage model would be usable for most cases. Sort of doing game dev in SaaS (software as a service) way, if you will. Not easy.

So, I step back and started thinking more about (1) single sign-on, (2) match making, and (3) scoreboard. This is not trivial either, especially single sign-on, which is the critical and could be too complex (and this goes against easy dev platform for many game devs at various skill levels). My goal was to create a platform that is "easy" and SSO involves some stuff that's hard to master (or at least time consuming - certificate, public-private-key encyription, sigining, etc...)

I will continue to work on ideas and once it gets more comcrete, I will publish it via google doc or something...

Share this post


Link to post
Share on other sites
Quote:
Original post by ywatanabe
...
Kenneth,

I tried to get to your game but couldn't... is it up and running somewhere that I can get to? Just curious what you have got!


It isn't up on the internet anywhere atm.

I shut it down awhile ago because of a game I 'inherited' and its playerbase and I had issues that just kind of spiraled until things collapsed. And the other game...was not as popular as I had hoped and I could never get replacement for the programmer art.

But the main opponent who thought I never should have 'inherited' it in the first place shut his version down after about the same time I was running it.

So I was planning to revive it, maybe build a small silly game in the same vein as Click the PBBG, while I work on a 'better' game than my last attempt. ;)

If you feel it will be helpful...I'll try to set some of it up again but I had everything integrated into some forum software that no longer exists on the internet and which I didn't keep a copy, so I'd probably have to re-work the login system and a few other things to get it working again.

If you can wait six months or so, I should have something 'online' in late June/early July.

Quote:

...

I will continue to work on ideas and once it gets more comcrete, I will publish it via google doc or something...


Cool.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
  • Advertisement
  • Popular Tags

  • Advertisement
  • Popular Now

  • Similar Content

    • By 3dmodelerguy
      So I am building a turn based rogue-like (think CDDA). The game is going to have a very large map (up to 1000's x 1000's) however to alleviate most of that I obviously can't render everything so there will just be render a certain radius around the player and just load in and out data as the player moves.
      The next major system I am prototyping is making interactive tiles destructible and pretty much everything will be destructible besides basic landscape (cars, doors, windows, structures, etc. will be destructible)
      While I am only rendering a certain amount of tiles around the player, I want to keep the amount of colliders active at one time to be as small as possible for performance and currently the tilemap tool I use automatically merges colliders together.
      So instead of creating a separate colliders for each of these tiles and having the destructible behavior tied to that object (which my tilemap tool would allow me to do) I was thinking that I would store an array of all the X and Y locations for the interactive tilemap layer and let the tilemap manage the colliders. 
      Then when I hit a collider on the interactive tilemap layer, instead of of getting the behavior for how to deal with the destruction for that tile from that game object, I would pull it from the array I mentioned earlier based on the tile I attempt to interact with which I already have.
      Does this sound like a good approach? Any other recommendations would be welcomed.
    • By NDraskovic
      Hey guys,
      I have a really weird problem. I'm trying to get some data from a REST service. I'm using the following code:
       
      private void GetTheScores() { UnityWebRequest GetCommand = UnityWebRequest.Get(url); UnityWebRequestAsyncOperation operation = GetCommand.SendWebRequest(); if (!operation.webRequest.isNetworkError) { ResultsContainer rez = JsonUtility.FromJson<ResultsContainer>(operation.webRequest.downloadHandler.text); Debug.Log("Text: " + operation.webRequest.downloadHandler.text); } } The problem is that when I'm in Unity's editor, the request doesn't return anything (operation.webRequest.downloadHandler.text is empty, the Debug.Log command just prints "Text: "), but when I enter the debug mode and insert a breakpoint on that line, then it returns the text properly. Does anyone have an idea why is this happening?
      The real problem I'm trying to solve is that when I receive the text, I can't get the data from the JSON. The markup is really simple:
      [{"id":1,"name":"Player1"},{"id":2,"name":"Player2"}] and I have an object that should accept that data:
      [System.Serializable] public class ResultScript { public int id; public string name; } There is also a class that should accept the array of these objects (which the JSON is returning):
      [System.Serializable] public class ResultsContainer { public ResultScript[] results; } But when I run the code (in the debug mode, to get any result) I get an error: ArgumentException: JSON must represent an object type. I've googled it but none of the proposed solutions work for me.
      Also (regardless if I'm in the debug mode or not) when I try to do some string operations like removing or adding characters to the GET result, the functions return an empty string as a result
      Can you help me with any of these problems?
      Thank you
    • By nihitori
      The Emotional Music Vol. I pack focuses on beautiful and esoteric orchestral music, capable of creating truly emotive and intimate moods. It features detailed chamber strings, cello and piano as the main instruments, resulting in a subtle and elegant sound never before heard in video game royalty-free music assets.

      The pack includes 5 original tracks, as well as a total of 47 loops based on these tracks (long loops for simple use and short loops for custom / complex music layering).

      Unity Asset Store link: https://www.assetstore.unity3d.com/en/#!/content/107032
      Unreal Engine Marketplace link: https://www.unrealengine.com/marketplace/emotional-music-vol-i

      A 15 seconds preview of each main track is available on Soundcloud:
       
    • By RoKabium Games
      Another one of our new UI for #screenshotsaturday. This is the inventory screen for showing what animal fossils you have collected so far. #gamedev #indiedev #sama
    • By eldwin11929
      We're looking for programmers for our project.
      Our project is being made in Unity
      Requirements:
      -Skills in Unity
      -C#
      -Javascript
      -Node.js
      We're looking for programmers who can perform a variety of functions on our project.
      Project is a top-down hack-and-slash pvp dungeon-crawler like game. Game is entirely multiplayer based, using randomized dungeons, and a unique combat system with emphasis on gameplay.
      We have a GDD to work off of, and a Lead Programmer you would work under.
      Assignments may include:
      -Creating new scripts of varying degrees specific to the project (mostly server-side, but sometimes client-side)
      -Assembling already created monsters/characters with existing or non-existing code.
      -Creating VFX
      -Assembling already created environment models
      If interested, please contact: eldwin11929@yahoo.com
      This project is unpaid, but with royalties.
       
      ---
      Additional Project Info:
      Summary:
      Bassetune Reapers is a Player-verus-Player, competitive dungeon crawler. This basically takes on aspects of dungeon crawling, but with a more aggressive setting. Players will have the option to play as the "dungeon-crawlers" (called the 'Knights', or "Knight Class", in-game) or as the "dungeon" itself (literally called the 'Bosses', or "Boss Class", in-game). What this means is that players can choose to play as the people invading the dungeon, or as the dungeon-holders themselves.
      Key Features:
      -Intense, fast-paced combat
      -Multiple skills, weapons, and ways to play the game
      -Tons of different Bosses, Minibosses, creatures and traps to utilize throughout the dungeon
      -Multiple unique environments
      -Interesting, detailed lore behind both the game and world
      -Intricate RPG system
      -Ladder and ranking system
      -Lots of customization for both classes s of customization for both classes
  • Advertisement