2
\$\begingroup\$

I'm creating a billiard game where one white ball will be controlled by two online players.

I have set my object photonview to ownership takeover.

  1. When a player shoots the ball in one client, it is synced on other client.

  2. Now when I update the ball on the other client, the other client is not updated.

Why is the ownership fixed?

Only one client is sending the updates to the other client, and not vice versa.

What should I do here?

\$\endgroup\$
1
  • \$\begingroup\$ The link to the image you had put in the question has rotten. Perhaps you want to reupload it to stack's imgur account. \$\endgroup\$ Commented Aug 7, 2018 at 13:07

1 Answer 1

1
\$\begingroup\$

I can't say why the ownership is fixed.

But that being the case I'd suggest making two cue balls, one owned by each client.

Only make one visible at a time based on whose turn it is. Then after their turn, update the other ball with the exact resulting properties of the first. Swap their visibility, rinse, repeat.

Also, make sure to turn off all the physics of the invisible ball.

\$\endgroup\$

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.