Search Unity

Badumna Network Suite - Unity version

Discussion in 'Multiplayer' started by peshwa_prince, Apr 15, 2010.

  1. CaptainKiyaku

    CaptainKiyaku

    Joined:
    Feb 8, 2009
    Posts:
    324
    With the NPC Demo. But setting the Broadcast Port to 0 solved this.

    But now they can't connect to the server at all. I think i'm not setting up the arbitration server correctly.
     
  2. tak3r

    tak3r

    Joined:
    Apr 29, 2010
    Posts:
    28
    1. To stop the seedpeer from command line on Linux, use command "kill [pid]",while to find your seedpeer pid you could use the command "ps aux|grep seedpeer"

    2. If you overwrite the NetworkConfig.xml file, you need to restart your seedpeer manually or restart it from control center.

    Hope these info are useful
    :D
     
  3. tak3r

    tak3r

    Joined:
    Apr 29, 2010
    Posts:
    28
    You should make sure that the ArbitrationServer address is correctly setup. The arbitration server address should be the public ip address of machine that running the arbitartion server. (you could find machine public ip address from www.whatismyip.com) And make sure you set the right port number as well.

    Note: Don't put a private ip address as arbitration server address in the client network configuration
     
  4. tak3r

    tak3r

    Joined:
    Apr 29, 2010
    Posts:
    28
    The current version of control panel does not support this feature yet. Currently, you have to start the UnityArbitrator manually.
     
  5. CaptainKiyaku

    CaptainKiyaku

    Joined:
    Feb 8, 2009
    Posts:
    324
    I did that (using my public address). Does it matter if you use a DNS name or not? Probably not i guess. But i tried both.

    I use this Windows Control Panel too. I was wondering why there is no "service" to start the Arbitration Server? So i just started everything else and opened the UnityArbitrator.exe with the corresponding files (dbConfig and deiConfig).

    But it's somehow not connecting to it. The dei authentification works though (i just printed out a debug message to see if it works or not).

    I am still wondering if Badumna is good for MMO-like concepts (like World of Warcraft) or if another Backend would be better (photon for example). It seems to be great for Shooter kind of network games though.
     
  6. tak3r

    tak3r

    Joined:
    Apr 29, 2010
    Posts:
    28
    Hi Kiyaku,

    1. Are you using the DeiSQLite or DeiMySql?
    (If you are using DeiSQLite, you have to add user into your database first, if you are using DeiMySql, make sure when you add a new user, it has a participation permission on "permissions" table)

    2. can the Arbitration connect successfully to the Dei Server??
    (If it can connect, then the problem is not on your DeiServer)

    3. Did your unity client application also login through Dei?? (If your Unity client application is not login from Dei Server, then this client will not be able to talk to dei server, since it has different certificate)

    Note:

    I'm pretty sure that when first time you create badumna database from badumna.sql, there are 3 default user.

    username: unity
    password: 123

    username: unity2
    password: 123

    username: admin
    password: admin_password

    username: arbitration
    password: server
     
  7. CaptainKiyaku

    CaptainKiyaku

    Joined:
    Feb 8, 2009
    Posts:
    324
    1. I am using the DeiMysql and added the badumna.sql

    2. Well it prints out following line:
    Code (csharp):
    1. Success load the dei configuration from deiConfig
    2. Successfuly load database configuration from DbConfig
    3. Connection String : Server=localhost;Database=badumna;User ID=root;Password=xxxxxx;Pooling=false;
    So if this is a sign for a connection, then yes it does. If not, how exactly can i check it out?

    3. I am using the NPC Demo (also tried the Arbitration Demo).
    I print a debug line if "DoDeiLogin" was successful and it works. So i bet it is connecting correctly (i tried to use a non existing username and it printed false).

    I used the admin user and tried to use a new one too.

    Does the Arbitration need a specific port to be open?
    I tried 21255, 21257, 21259, 27248, 21252.

    Do i have to change some settings in the controlpanel in order to have a arbitration server? I had to use Broadcast = 0 in the client config right? Do i have to disable it in the controlpanel as well?
     
  8. tak3r

    tak3r

    Joined:
    Apr 29, 2010
    Posts:
    28
    You mention that the broadcast port is set to 0 (means you disabled broadcast). Did you run the seedpeer ?

    If you didn't run the seedpeer then you can't connect to each other.

    If you run the seedpeer, make sure both arbitration server and NPC Demo point to the same seedpeer.

    If you don't want any broadcast at all, then you should set the broadcast port in the control panel to 0 as well.
     
  9. CaptainKiyaku

    CaptainKiyaku

    Joined:
    Feb 8, 2009
    Posts:
    324
    I don't want any broadcasting so i set it to 0. I only want them to connect to the Arbitration Server.

    I wonder what exactly i am doing wrong. It's hard to locate the problem as there isn't much feedback from the arbitrator or whatever :/
     
  10. Matroblend

    Matroblend

    Joined:
    Jan 30, 2009
    Posts:
    134
    Grrrr, Ok I have tried everything I can think of and for the life of me I can't get my home server to work.
    I have tried portforwarding, DMZ, DynDNS change this setting and that setting tried just the seedpeer and nothing.

    So now I am going to try the XP VPN today and see if that works. I am getting to the end of my rope on ideas to build a working environment.
     
  11. Creative

    Creative

    Joined:
    May 8, 2010
    Posts:
    184
    epic fail at providing a dot after 'com'!
     
  12. grfxman

    grfxman

    Joined:
    May 28, 2009
    Posts:
    309
    Which Module is failing? The Seed Peer? Auth Server? etc???

    And which OS did it fail on?
     
  13. Matroblend

    Matroblend

    Joined:
    Jan 30, 2009
    Posts:
    134
    I am running XP and it is the SeedPeer that the client is failing to connect.

    I can connect UPD just fine on the LAN but I have that set to zero and want to connect via IP.

    My setup is I have a Host PC running XP WAMP and the Badumna Control Center a Dev PC running XP and Unity and a Mac Book running a client on another IP.
     
  14. grfxman

    grfxman

    Joined:
    May 28, 2009
    Posts:
    309
    Well I got it all running but it was on Linux.

    From what I learned so far is :

    Badumna use these ports 21250 - 21260 UDP/TCP both ways.

    So you should make those available.

    I don't remember what we typed to start SeedPeer but there was a typo for the AuthServer. It should be something like:

    Code (csharp):
    1. mono UnityArbitrator.exe --db_config=DbConfig --dei_config=deiConfig
    To start DeiServer :

    Code (csharp):
    1. mono DeiMySql.exe port:21259 --db=badumna --host=localhost --user=root tcpconnection
    I think you can add the command flag " tcpconnection " or " port " on the command line for the SeedPeer as well. But you would have to check.

    It takes a little bit to get it all running, But it does all function. I have them running online right now.

    Hope the NFO helps :)
     
  15. Matroblend

    Matroblend

    Joined:
    Jan 30, 2009
    Posts:
    134
    Ok I have gone over and over everything opened all the ports the Badumna could use even to the point of DMZ tried both the the public and portforwarded IPs and I have been working on it from day one of Badumnas release.

    I think it my be time to try something else.
     
  16. grfxman

    grfxman

    Joined:
    May 28, 2009
    Posts:
    309
    Have you tried contacting them?
     
  17. Matroblend

    Matroblend

    Joined:
    Jan 30, 2009
    Posts:
    134
  18. grfxman

    grfxman

    Joined:
    May 28, 2009
    Posts:
    309
    I would email them. Go to contact section of their site.

    I had the opposite problem. The local windows install worked. But it took awhile to get it up on the Linux server. But that was due to the fact I hadn't used Linux in about 10 years. If your doing it on a laptop and your ever in Portland I can take a look at it. Since we seem to be neighbors.
     
  19. grfxman

    grfxman

    Joined:
    May 28, 2009
    Posts:
    309
    If you guys want to test out Badumna you can go to:

    http://www.fringeworlds.com/

    We have a release date of Halloween but Unity user are welcome to test it out until then.

    Updates are frequent ( Usually every 48 hours ). The actual game is being built by 2 people. With a few free-lancers for illustrations.

    Currently you have access to 3600 square miles to explore.
     
  20. Matroblend

    Matroblend

    Joined:
    Jan 30, 2009
    Posts:
    134
    Hey nice going, I did a little running around there a few days ago looking good.

    Still working out my issues.
     
  21. grfxman

    grfxman

    Joined:
    May 28, 2009
    Posts:
    309
    Yeah I'm cleaning it up as fast as possible. The term Successive Refinement has become a full time lifestyle during construction of this. :)
     
  22. Nicon

    Nicon

    Joined:
    May 25, 2010
    Posts:
    14
    Has anyone got the Arbitration Server working, if so then how would you get it to work step by step if possible.

    So far I have gotten all the examples to work except one where it requires a login. My IP is DMZd through my router so it is public. I do however wish to get this working as I plan to have players signup and login to the world I am working on.

    Any help here would be very much appreciated.
     
  23. peshwa_prince

    peshwa_prince

    Joined:
    Apr 14, 2010
    Posts:
    67
    Nicon, What is the problem that you experience when you try the login demo. If the clients are authenticated successfully but they don't see each other then the problem is with the SeedPeer. You need a Dei enabled seed peer. Something we didn't include in the distribution. However, I am going to put the package out shortly.
    Cheers,
     
  24. Matroblend

    Matroblend

    Joined:
    Jan 30, 2009
    Posts:
    134
    Does this mean that Arbitration Server is not able to function yet if so I will just work on testing the other demo parts.
     
  25. Nicon

    Nicon

    Joined:
    May 25, 2010
    Posts:
    14
    Thank you, I was wondering why it was not working correctly. As Badumna seems to offer alot of possibilities for MMOs. As well anyway to show any examples or tutorials on how to extend the server for gamelogic?
     
  26. peshwa_prince

    peshwa_prince

    Joined:
    Apr 14, 2010
    Posts:
    67
    Does this mean that Arbitration Server is not able to function yet if so I will just work on testing the other demo parts.

    Matroblend,
    Arbitration Server should work fine. It is not affected at all whether you use Dei or not.
     
  27. skidding

    skidding

    Joined:
    May 28, 2010
    Posts:
    3
    Hi (first post here),

    I started playing with Unity for about 2 days and it's awesome. Anywho, I wanted to try Badumna and I encounter a problem. I was looking through the Developer Documentation and at the beginning of chapter 4. (Unity package) I'm supposed to open the first Demo that comes with Badumna. However I directly receive an error from that project, stating:
    Code (csharp):
    1. error CS2011: Unable to open response file: Temp/UnityTempFile-090dffa660bf2034293dfe20aebc0286
    I can't even go through with the first step of the demo walkthrough, as the Unity prompts me with this notice: "Can't add script behaviour NetworkIntialization. You need to fix all compile errors in all scripts first!".
    Also, the error is: "Log in file: at line: 0" so I can't really tell what it is; besides the fact that I just started with Unity.

    Hope I'm not totally off-track. Thanks!
     
  28. Matroblend

    Matroblend

    Joined:
    Jan 30, 2009
    Posts:
    134
    Welcome Skidding,

    The Unity demos do require a little work on your part.
    1. You need to set up the SeedPeer NetworkConfig.xml file it needs to be in the SeePeer folder. Pay close attn. the this part in BOLDyour.portforward.ip.com is your IP address.

    <Module Name="Connectivity">
    <PortRange>21255,21255</PortRange>
    <Broadcast Enabled="true">27360</Broadcast>
    <Initializer type="SeedPeer">your.portforward.ip.com:21255</Initializer>
    <PortForwarding Enabled="true" />


    2.You can spend a lot of time on portforward and DMZ issues, be warned.

    3. Start the SeedPeer.

    4.In Unity load the Demo1 tutorial and edit the client NetworkConfig.xml just like the SeedPeer.

    <Module Name="Connectivity">
    <PortRange>21255,21255</PortRange>
    <Broadcast Enabled="true">27360</Broadcast>
    <Initializer type="SeedPeer">your.portforward.ip.com:21255</Initializer>
    <PortForwarding Enabled="true" />
    <Stun Enabled="true">

    5. Edit the NetworkInitalization.cs file in the demo1\assets\plugins\networkingscript folder.

    badumnaConfigOptions.DiscoverySource = "your.portforward.ip.com:21255";
     
  29. Metron

    Metron

    Joined:
    Aug 24, 2009
    Posts:
    1,137
    Hi,

    I can't find any statement about the pricing scheme that will be used for this middleware. I must admit that I strongly hesitate using it if I don't really know which costs I have to face later on...

    Could anyone (Peshwa_Prince ?) make a little statement about this?

    Thanks
     
  30. scalify

    scalify

    Joined:
    May 20, 2010
    Posts:
    18

    Hi Metron,

    Thanks for your interest in our Badumna Network Suite. Pricing for commercial implementations is a monthly subscription, based on the peak concurrent users using the MMO. We’ll be publishing full pricing details soon, but as a guide, we’re aiming to reduce the overall cost for networking (ie. networking engine license plus the ongoing server bandwidth costs) by about 50%. One of the key benefits of the Badumna peer-to-peer architecture is a major reduction in server/bandwidth costs.

    Please contact us (info at scalify.com) if you’d like specific pricing for your project.

    You may also want to check out this new demo game that was built by Unity Studios using Badumna:

    http://www.badumna.com/badumna/BadumnaTrollBasher/BadumnaTrollBasher.html

    Cheers
    The Scalify Team
     
  31. Dreamora

    Dreamora

    Joined:
    Apr 5, 2008
    Posts:
    26,601
    Are there real benchmarks on this matter especially the traffic players will have to cope with due to the "push the bandwidth cost to the player instead of the server"?

    As this is a pretty non standard way of handling the staff some hard numbers would make a lot of sense, especially as any experienced dev in the field will have the same initial reaction: sending unverified data in an MMO is no-no-no-no-go :)
     
  32. peshwa_prince

    peshwa_prince

    Joined:
    Apr 14, 2010
    Posts:
    67
    Dreamora,
    There is benchmark data available. You can look at this paper that shows results from some very early trials: http://www.nicta.com.au/__data/assets/pdf_file/0006/19905/Badumna-P2P09-paper.pdf
    More specifically, to answer your question, each player contributes roughly the bandwidth required for their own game (we cap it at 64Kbps). As its a collective scheme, if you had a million players, each player would still contribute 64Kbps and we would have 64 X million Kbps available for the game.
    TO answer your second question on verifiability - Badumna gives complete control of that to the developer. If a developer decides that certain functionality is critical then those packets go via the server. Its only the non-critical stuff that is sent directly. Moreover, we encourage client-level checks for all incoming data so you can verify all incoming data. Hope that helps!
    Have fun :)
     
  33. Dreamora

    Dreamora

    Joined:
    Apr 5, 2008
    Posts:
    26,601
    Thank you for the link. I might potentially have gone over it but skipped the benchmark part due to the low amount of users on the first benchmark.
    While that didn't answer the question about the bandwidth, the 64k cap information did. its a bit high there, I guess that could be configured?

    With verification though I meant more verifying server side if the action is allowed at all.
    Thanks for clarification on that matter too.


    On a 3rd point: I've not checked through the docs but I guess that you have somewhere a disclaimer to inform all newcomming devs that the concept of the distributed agents requires that they get a legal ok from their end users to use those users machine for the purpose?


    All in all it seems to be a much more interesting technology than the "what you get in touch first" information and documentation imply on the direct information where its focused on the peer to peer aspect and its benefits :)
    Will need to dive deeper into it in the near future, as I've a strong focus around network and MP related programming so being up to date on the options, especially when "not the same as everyday", is a must :)
     
  34. Metron

    Metron

    Joined:
    Aug 24, 2009
    Posts:
    1,137
    I must admit that I didn't intend to use your library to create a fully fledged MMO. Instead, I see possibilities to create FPS games with more than the current 32-64 players. Such a game would not have monthly subscribers and a different pricing scheme would be more interesting.

    That said, I'll wait for the official price announcement and see what happens.

    Thanks.
     
  35. Nicon

    Nicon

    Joined:
    May 25, 2010
    Posts:
    14
    Just out of curiosity what encryption is used for the passwords and SALT fields in the DB? This way I can start setting up a signup script in PHP for those I want to give access out to try the game I am working on.
     
  36. peshwa_prince

    peshwa_prince

    Joined:
    Apr 14, 2010
    Posts:
    67
    Nicon,
    We are in the process of releasing documentation related to Dei server-side API. This will allow you to use all the functionality that is built-in to Dei such as encryption, etc.
     
  37. Nicon

    Nicon

    Joined:
    May 25, 2010
    Posts:
    14
    Nice. I do however have a problem running the arbitration demo remotely from another PC. I do have my IP public and outside of my router to test things out.
     
  38. tak3r

    tak3r

    Joined:
    Apr 29, 2010
    Posts:
    28
    Hi, I got the same problem,in my case I tried to run the Unity Editor as administrator and make sure the Unity Demo directory is not read-only directory, that fix the problem. Cheers :)
     
  39. tak3r

    tak3r

    Joined:
    Apr 29, 2010
    Posts:
    28
    The API can be found at http://www.badumna.com/api/1.3/dei/
     
  40. Ensane

    Ensane

    Joined:
    Jul 13, 2010
    Posts:
    221
    when I try to run the demo in unity is comes up with an error:

    "error CS2011: Unable to open response file: Temp/UnityTempFile-6bfa2d2a8bda45c4fad707a59d33678a"

    on the Demo's... and the arbiration demo isnt even present...

    Also anyone actually tested this server solution with thousands of players in a MMO setting? How good is it?
     
  41. tak3r

    tak3r

    Joined:
    Apr 29, 2010
    Posts:
    28
    Hi Ensane, please check my previous post regarding this problem, if you running it on windows vista/ 7 you have to run the unity editor as an administrator and make sure the demo directory (i.e. asset, library directories) shouldn't have a read only permission, or you could copy the whole unity demo directory to somewhere else, outside the ProgramFiles directory, and it should work too. Let me know if you still have the same problem. Cheers.
     
  42. Ensane

    Ensane

    Joined:
    Jul 13, 2010
    Posts:
    221
    so how does it perform for mmos? and how do u deal with someone with a crappy connection wouldnt it cause lag wwith the peer to peer?
     
  43. peshwa_prince

    peshwa_prince

    Joined:
    Apr 14, 2010
    Posts:
    67
    Badumna is designed to support MMOs in particular so it performs better with more users in the system. As for your question about a user with a crappy connection - he/she will experience more delays with a client-server solution as the updates have to travel to the server and then back. Moreover, to ensure that such users don't get overloaded, Badumna provides an overload service that ensure that such users do not experience any issues.
    Hope that helps with your query.
     
  44. Ensane

    Ensane

    Joined:
    Jul 13, 2010
    Posts:
    221
    my final question What about hackers? with the peer to peer isnt alot of the information on the clients end?
     
  45. peshwa_prince

    peshwa_prince

    Joined:
    Apr 14, 2010
    Posts:
    67
    We usually don't store any information at the client-end except for local client-data. All the arbitration is done at the server-end and persistent game state is stored on servers. We use the p2p network for object updates, chat, and anything else that is classified as non-critical. Moreover, all the information is encrypted prior to dispatch. Hope this information helps.
     
  46. Ensane

    Ensane

    Joined:
    Jul 13, 2010
    Posts:
    221
    Thanks this helps alot... so i set up the Badumna network and i like it and considering using it for my indie mmo is there any way i can email or speak with you directly about some other concerns or issues?
     
  47. Lopuz3

    Lopuz3

    Joined:
    Feb 25, 2010
    Posts:
    17
    Hi-

    I have followed a chunk of the tutorials in order to learn about Badumna and networking in general. I am confused about how to set up a public IP address. Could someone please explain a good way to set that up?

    Thanks in advance,
    Lopuz3
     
  48. Ensane

    Ensane

    Joined:
    Jul 13, 2010
    Posts:
    221
    www.whatismyip.com it will show you what yourr public address is... and use that address in the xml files/networkinitialize scripts
     
  49. mytoaster

    mytoaster

    Joined:
    Aug 6, 2010
    Posts:
    5
    So I have a few questions:
    1) The function Login() in NetworkFacade is blocking and will lock up the interface for a few seconds, is there a way to run this on a separate thread and have it callback when it's done?

    2) Is it possible, or does it even matter if there are multiple SeedPeers?

    3) Does it make sense to have multiple arbitration and DEI servers if all of them access the same MySQL db?

    Thanks!
     
  50. peshwa_prince

    peshwa_prince

    Joined:
    Apr 14, 2010
    Posts:
    67
    Excellent questions mytoaster...Here are the answers:

    1. The Badumna Login() does take around 5-10secs and you don't want your game to be inactive for that duration. You can start the Login() in a background thread and continue doing whatever you want in the main thread so that the users don't experience an unresponsive screen. The only condition is that before you do the next Badumna step, you need to make sure that Login is complete. We have a very simple example of how to do it, I will post it here for reference in a couple of days.
    2. The current version (1.3) doesn't allow multiple Seed Peers but the next version that is coming out in October will allow multiple Seed Peers and show examples of how to do that.
    3. Yes, it makes perfect sense to have multiple arbitration servers that access the same database. As a matter of fact, ver 1.4 will have a ready to use example that shows how to setup 2 arbitration servers (perhaps handling 2 different zones) but accessing the same database (with proper locking mechanisms, etc). It also has the feature to read/write the db at a constant rate so you don't overload the db and make the game unresponsive. Hope you are able to wait till then. If you are very desperate to implement this functionality then let me know and I will see if I can send you some pre-release material.

    Cheers.