Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by Steffen D E · May 14, 2015 at 04:24 PM · c#multiplayernetworkserverclient

Multiplayer server-client setup

Greetings everyone!

I'm working on a multiplayer game, and have run into a snag, regarding the multiplayer part.

The game is a non-physics 2D game (with some 3D elements) of one to many (hundred) players.

For the networking, I want to use an authoritative server structure, where the clients submit their actions, and the server modify the gameworld and broadcast the changes, both to ensure that everyone is in sync with the same gameworld, and to minimize cheating.

I want the user to be able to start a game, and have friends join that game, using LAN or a matchmaking server, and I want the user to be able to start a dedicated server, and have friends join that game instead.

As I want the singleplayer part to be a local instance of multiplayer with only one player (much like how Space Engineers do it), I'm guessing my best option is to build the client and server parts separately, using Unity for the client part, and .Net for the server part, and then starting the server as a new process, when starting a singleplayer game or hosting a multiplayer one (not dedicated). This way, if the user want to host a dedicated server, he doesn't need to have the client running.

I looked into building the whole thing on unity, but as far as I can tell, unity doesn't support sending [RPC] requests to itself, as both the client and server.

I think I read somewhere that uLink support this, however I don't want to pay for a license, before I KNOW that is exactly what I need, and a 30day trial is to little time.

so, I guess my question is, what would be the best way of attacking this? Am I on the right track with the way I plan to implement this, or is there a much better method, that I haven't thought of? And if this IS the best way, is there a way to use the unity networking to connect to a .net server?

Thanks for your time and answers!

P.s. the gameworld is meant to be a persisting world, so I've chosen to implement it in an embedded SQLite database, which the server part need to modify.

P.P.s. I use the free unity license.

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by Samal · May 15, 2015 at 06:43 PM

So u wanna send an email to a person that is sitting next to you instead of speaking to him/he directly? Instead of making an RPC call just call the function like u normaly do. What u need is to know if the client and server are the same machine by checking the IP.

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

4 People are following this question.

avatar image avatar image avatar image avatar image

Related Questions

Networking RPC calls never sent to other clients 1 Answer

Do i need to have 2 seperate apps communicating for server/client relationship? 2 Answers

Server and Network no communication 1 Answer

Player falls through plane/floor (Multiplayer) 1 Answer

How to hide a started/full server 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges