Skip to content

Commit

Permalink
quick edits
Browse files Browse the repository at this point in the history
  • Loading branch information
default user name committed Oct 11, 2022
1 parent 7781486 commit ea60fb2
Showing 1 changed file with 13 additions and 10 deletions.
23 changes: 13 additions & 10 deletions Documentation/3.5_Multiplayer_Objects_Overview_and_Tutorial.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,13 @@ This documentation accompanies the [Multiplayer Simple Scene](./2.1_Sample_Scene
| ----------------------------- | ----------------------------------------- | ----------------------------------------------------------------------------------- |
| Object through creation menus | Look, Move, Modify, Spawn multiple copies | Renderer, Collider, PhotonView (ownership: Takeover) |
| Static scene object | Just Look at them | None, (If you want basic networking, you can attach PhotonView and script RPCs) |
| Synchronized scene object | Look, Move, Modify | |
| Synchronized scene object | Look, Move, Modify | Renderer (somewhere in the object)
PlayerCreatedObject (set: DontMoveToScene)
PhotonView (ownership: Takeover)
PhotonTransformView (sync: all)
Collider (optional; if you want to manually specify boundaries)
|

* **Static scene objects:** These are built with the scene and are not modifiable by users. Use this if you want all users to just look at the same objects. They are visible to all users, but cannot be moved/modified; and if a user does move them (ex: while running in the Unity editor) the object’s properties are not synchronized between users. The ManualCube_Static is an example of such an object.
* **How to create it before running:** It was created by right-clicking on the scene and creating a 3D Cube object.
</br></br>
* **Synchronized scene objects**: These objects are built with the scene, and are modifiable by users. Use this if you want all users to look and manipulate objects. They are visible to all users and, when modified, their properties are synchronized between all users. The ManualCube_PlayerMoveable is such an example (*if you cannot find it in the scene while Unity is running, search for it by name because it will have been moved under the networked objects root).
* **How to create it before running:** It was created by making a simple 3D Cube, then adding to it the following scripts:
* _PhotonView_: used by Photon to synchronize the object across users; note that ownership must be of type Takeover.
* _PhotonTransformView_: used by Photon to send/receive the object’s transform; note that all the object properties are synchronized.
* _PlayerCreatedObject_: used by our system to let users move/edit the object. This script also creates a bunch of other scripts on the object to make it respond nicely through MRTK interactions.
</br></br>
* **Objects created through creation menus:** These objects are created at runtime through the object creation menus. Use this if you need users to spawn multiple objects and modify/move them around. They are just like synchronized scene objects but they are created through the menus.
* **How to spawn one while running:** To create one, run the project and select a Cube from the in-world creation menu; it will be spawned for all users, and located under the networked objects root object.
* <picture><img src="./Images/object_menuu.png" width= "400" height="240"></picture>
Expand All @@ -29,3 +25,10 @@ This documentation accompanies the [Multiplayer Simple Scene](./2.1_Sample_Scene
* Make sure it has a Collider (that’s how users will grab it) and also a PhotonView (that’s how Photon will spawn it; and set its ownership to type Takeover). No other scripts are needed, the system will add other scripts when the object gets spawned.
* Put the prefab inside the Resources/CreationPrefabs folder. (This folder will be scanned when users see the menu).
* * Note, whenever you add a new object, you’ll need to rebuild the project for all users, otherwise the users will not have the object.


* **Static scene objects:** These are built with the scene and are not modifiable by users. Use this if you want all users to just look at the same objects. They are visible to all users, but cannot be moved/modified; and if a user does move them (ex: while running in the Unity editor) the object’s properties are not synchronized between users. The ManualCube_Static is an example of such an object.
* **How to create it before running:** It was created by right-clicking on the scene and creating a 3D Cube object.
</br></br>

* **Synchronized scene objects**: These objects are built with the scene, and are modifiable by users. Use this method if you want all users to look and manipulate objects. They are visible to all users and, when modified, their properties are synchronized between all users. You can find all the

0 comments on commit ea60fb2

Please sign in to comment.