Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 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 reiconrooc · Aug 19, 2018 at 03:22 PM · networkingscenenetworkspawn

network card game

I am new with unity and with the networking concept. I am making a card game and I am in trouble with the table. The table is where played card are placed and shown to all players. Should I spawn the table from the server using a prefab or should I place the table in the scene in the hierarchy? And in the second case, how the player can interact with the table (they are different objects spawned in different times)?,I am new with unity and the networking concept. I am making a card game and I am in trouble with the table. The table is the place where cards played are shown to all player. My firts question is if the table has to be spawned by the server or if it should be part of the scene in the Hierarchy. If it should be part of the scene, ho the player can interact with the table? (They are different project spawned in different times)

Comment
Add comment · Show 1
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
avatar image toddisarockstar · Aug 20, 2018 at 06:39 AM 0
Share

in your case the server could be simple. just enough to store some number arrangement pry in a byte array to represent everything that is currently going on on the table that can be read and overwritten by the users. I would recommend just a single file. the users game copies should do all the real work and the server should be simple.

2 Replies

· Add your reply
  • Sort: 
avatar image
1

Answer by Austin-Gregory · Aug 20, 2018 at 06:51 AM

The table object itself should be created on the clients as I'm assuming it doesn't do anything but act as the surface for the cards.

It sounds like you're stuck on the actual networking bit, however. The cards that are placed ON the table would need to be synced to all clients so this is what the server should handle. Client decides to play a card, sends that action to the server, server handles creating the card and syncing it to the clients. The way you handle that will depend on what type of networking you're doing.

This type of turn-based networking is definitely a good starting point for learning networking, but networking is the worst starting point for learning game development. I would highly recommend a different approach that will allow you to work up to networking. Perhaps give a local co-op version a shot and see how you do with that before jumping into the deep end.

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
avatar image
0

Answer by reiconrooc · Aug 20, 2018 at 08:45 PM

Does "The table object itself should be created on the clients" means that the table should be part of the player prefab? Reading the documentation, I found a phrase talking about the fact that function between client and server can be called only on spawned objects. Did I unterstand right? My idea is to have an object (called AI) only server side. This object manage the operations of the game. Probably I am confused about the functions placement, so can you tell me a generic idea of what object i should use and where/when spawn or create them?

Comment
Add comment · Show 1 · 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
avatar image reiconrooc · Aug 20, 2018 at 08:50 PM 0
Share

Or maybe I list my objects and how I am using them, so you can have a preview of my components

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

171 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Why is NetworKserver.Spawn() creating a Spawn button in NetworkIdentity? 3 Answers

UNET save server (world) progress 1 Answer

i'm trying to spawn enemies and it goes well but when i'm trying to scale them it doesn't sync i used [ClientRpc] and it didn't work 1 Answer

how to make game start when both the players are connected? 1 Answer

How to load the second online scene in UNET? 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