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 /
This question was closed Jul 28, 2013 at 02:11 AM by Benproductions1 for the following reason:

The question is answered

avatar image
0
Question by Pangamini · Mar 09, 2012 at 05:44 PM · rpcbroadcast

Sending RPC to everyone except one specific player

I would like server to broadcast some message from one client between other clients, without the original client sender receiving again. I know i could just simply loop through all connected and skip the sender, but i also know that RakNet has this feature (sending to everyone except one) and that it would be probably more effective.

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 Benproductions1 · Jul 31, 2012 at 09:14 AM 0
Share

Please choose a correct answer and rate it up...

1 Reply

  • Sort: 
avatar image
0

Answer by Benproductions1 · Jun 30, 2012 at 01:29 PM

To be honest this is a stupid question, that could be answered by just taking a look at the Unity Docs, but nevertheless here is the answer :)

networkView.RPC("MyFunction", RPCMode.Others, myvariable);

The RPCMode allows you to regulate who receives the RPC. This includes only the server, everyone, and everyone except the sender. Some of these can also be buffered. More info here; http://docs.unity3d.com/Documentation/ScriptReference/RPCMode.html And here: http://docs.unity3d.com/Documentation/Components/net-RPCDetails.html

Hope this helps :D

Comment
Add comment · Show 3 · 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 Pangamini · Aug 08, 2012 at 01:06 PM 0
Share

Sorry, you didn't understand. I don't want to exclude the sender of this RPC, but other chosen peer (peer who sent an RPC to the server and now server broadcasts this message to other peers except for the peer that sent it to the server.) RakNet does have this option, but i can't see it in Unity

avatar image Benproductions1 · Aug 08, 2012 at 01:23 PM 0
Share

Thanks for clearing that up :) that is possible in unity, but you would have to write it yourself!

avatar image Pangamini · Aug 08, 2012 at 02:25 PM 0
Share

That's what i did, i just thought maybe there would be less overhead or something

Follow this Question

Answers Answers and Comments

5 People are following this question.

avatar image avatar image avatar image avatar image avatar image

Related Questions

Can NetworkView state synchronization send to just the server, rather than all peers? 0 Answers

Odd behaviour when sending rpc from client to server 1 Answer

Passing a variable from a client to server 1 Answer

Buffered Network.Destroy? 0 Answers

Making a GUI Label carrying a variable update when changed to all clients on network 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