clean project
This commit is contained in:
10
Assets/Oculus/Avatar/Samples/AvatarGallery.meta
Normal file
10
Assets/Oculus/Avatar/Samples/AvatarGallery.meta
Normal file
@@ -0,0 +1,10 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 35f0ba21582517e45900137034e130af
|
||||
folderAsset: yes
|
||||
timeCreated: 1532639215
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
1197
Assets/Oculus/Avatar/Samples/AvatarGallery/AvatarGallery.unity
Normal file
1197
Assets/Oculus/Avatar/Samples/AvatarGallery/AvatarGallery.unity
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,9 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 7090d8e061d50cf459005277eef3e505
|
||||
timeCreated: 1532639215
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
10
Assets/Oculus/Avatar/Samples/AvatarGallery/Scripts.meta
Normal file
10
Assets/Oculus/Avatar/Samples/AvatarGallery/Scripts.meta
Normal file
@@ -0,0 +1,10 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 401f2fc661aa6af4da8c35c4f60718f8
|
||||
folderAsset: yes
|
||||
timeCreated: 1532729557
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,78 @@
|
||||
using UnityEngine;
|
||||
using System.Collections;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using Oculus.Avatar;
|
||||
|
||||
public class OvrAvatarTestDriver : OvrAvatarDriver {
|
||||
|
||||
private Vector3 headPos = new Vector3(0f, 1.6f, 0f);
|
||||
private Quaternion headRot = Quaternion.identity;
|
||||
|
||||
ControllerPose GetMalibuControllerPose(OVRInput.Controller controller)
|
||||
{
|
||||
ovrAvatarButton buttons = 0;
|
||||
if (OVRInput.Get(OVRInput.Button.PrimaryIndexTrigger, controller)) buttons |= ovrAvatarButton.One;
|
||||
|
||||
return new ControllerPose
|
||||
{
|
||||
buttons = buttons,
|
||||
touches = OVRInput.Get(OVRInput.Touch.PrimaryTouchpad) ? ovrAvatarTouch.One : 0,
|
||||
joystickPosition = OVRInput.Get(OVRInput.Axis2D.PrimaryTouchpad, controller),
|
||||
indexTrigger = 0f,
|
||||
handTrigger = 0f,
|
||||
isActive = (OVRInput.GetActiveController() & controller) != 0,
|
||||
};
|
||||
}
|
||||
|
||||
float voiceAmplitude = 0.0f;
|
||||
ControllerPose GetControllerPose(OVRInput.Controller controller)
|
||||
{
|
||||
ovrAvatarButton buttons = 0;
|
||||
if (OVRInput.Get(OVRInput.Button.One, controller)) buttons |= ovrAvatarButton.One;
|
||||
if (OVRInput.Get(OVRInput.Button.Two, controller)) buttons |= ovrAvatarButton.Two;
|
||||
if (OVRInput.Get(OVRInput.Button.Start, controller)) buttons |= ovrAvatarButton.Three;
|
||||
if (OVRInput.Get(OVRInput.Button.PrimaryThumbstick, controller)) buttons |= ovrAvatarButton.Joystick;
|
||||
|
||||
ovrAvatarTouch touches = 0;
|
||||
if (OVRInput.Get(OVRInput.Touch.One, controller)) touches |= ovrAvatarTouch.One;
|
||||
if (OVRInput.Get(OVRInput.Touch.Two, controller)) touches |= ovrAvatarTouch.Two;
|
||||
if (OVRInput.Get(OVRInput.Touch.PrimaryThumbstick, controller)) touches |= ovrAvatarTouch.Joystick;
|
||||
if (OVRInput.Get(OVRInput.Touch.PrimaryThumbRest, controller)) touches |= ovrAvatarTouch.ThumbRest;
|
||||
if (OVRInput.Get(OVRInput.Touch.PrimaryIndexTrigger, controller)) touches |= ovrAvatarTouch.Index;
|
||||
if (!OVRInput.Get(OVRInput.NearTouch.PrimaryIndexTrigger, controller)) touches |= ovrAvatarTouch.Pointing;
|
||||
if (!OVRInput.Get(OVRInput.NearTouch.PrimaryThumbButtons, controller)) touches |= ovrAvatarTouch.ThumbUp;
|
||||
|
||||
return new ControllerPose
|
||||
{
|
||||
buttons = buttons,
|
||||
touches = touches,
|
||||
joystickPosition = OVRInput.Get(OVRInput.Axis2D.PrimaryThumbstick, controller),
|
||||
indexTrigger = OVRInput.Get(OVRInput.Axis1D.PrimaryIndexTrigger, controller),
|
||||
handTrigger = OVRInput.Get(OVRInput.Axis1D.PrimaryHandTrigger, controller),
|
||||
isActive = (OVRInput.GetActiveController() & controller) != 0,
|
||||
};
|
||||
}
|
||||
|
||||
private void CalculateCurrentPose()
|
||||
{
|
||||
CurrentPose = new PoseFrame
|
||||
{
|
||||
voiceAmplitude = voiceAmplitude,
|
||||
headPosition = headPos,
|
||||
headRotation = headRot,
|
||||
handLeftPosition = OVRInput.GetLocalControllerPosition(OVRInput.Controller.LTouch),
|
||||
handLeftRotation = OVRInput.GetLocalControllerRotation(OVRInput.Controller.LTouch),
|
||||
handRightPosition = OVRInput.GetLocalControllerPosition(OVRInput.Controller.RTouch),
|
||||
handRightRotation = OVRInput.GetLocalControllerRotation(OVRInput.Controller.RTouch),
|
||||
controllerLeftPose = GetControllerPose(OVRInput.Controller.LTouch),
|
||||
controllerRightPose = GetControllerPose(OVRInput.Controller.RTouch),
|
||||
};
|
||||
}
|
||||
|
||||
public override void UpdateTransforms(IntPtr sdkAvatar)
|
||||
{
|
||||
CalculateCurrentPose();
|
||||
UpdateTransformsFromPose(sdkAvatar);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 151f6ca5e4e605c4ca65b3199bfc3377
|
||||
timeCreated: 1532699599
|
||||
licenseType: Store
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
9
Assets/Oculus/Avatar/Samples/Controllers.meta
Normal file
9
Assets/Oculus/Avatar/Samples/Controllers.meta
Normal file
@@ -0,0 +1,9 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 2856d681f3672e641a2e57df9676108c
|
||||
folderAsset: yes
|
||||
timeCreated: 1468456735
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
1194
Assets/Oculus/Avatar/Samples/Controllers/Controllers.unity
Normal file
1194
Assets/Oculus/Avatar/Samples/Controllers/Controllers.unity
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 2a83dd010542d2744bf59af99b4bc47c
|
||||
timeCreated: 1468457372
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
7
Assets/Oculus/Avatar/Samples/CrossPlatform.meta
Normal file
7
Assets/Oculus/Avatar/Samples/CrossPlatform.meta
Normal file
@@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: ad3077b9e8d4c4b4ea6177561faccbd2
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
1138
Assets/Oculus/Avatar/Samples/CrossPlatform/CrossPlatform.unity
Normal file
1138
Assets/Oculus/Avatar/Samples/CrossPlatform/CrossPlatform.unity
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: a95993f3779c6f842830a1f7ad81a478
|
||||
timeCreated: 1539938343
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
20
Assets/Oculus/Avatar/Samples/CrossPlatform/Readme.txt
Normal file
20
Assets/Oculus/Avatar/Samples/CrossPlatform/Readme.txt
Normal file
@@ -0,0 +1,20 @@
|
||||
This CrossPlatform sample scene demonstrates how Oculus Avatars can now be used on non-Oculus devices.
|
||||
|
||||
For more detailed information on this sample and cross-platform Avatar functionality, including details on customization and redistribution requirements, see the topic on this sample at: https://developer.oculus.com/documentation/avatarsdk/latest/concepts/avatars-unity-crossplat-sample/
|
||||
|
||||
Setup instructions:
|
||||
1 - Install Steam and SteamVR
|
||||
2 - Create a new Unity Project
|
||||
3 - Import the Oculus Integration from the Unity Asset Store.
|
||||
4 - Open the CrossPlatform scene (in Assets/Oculus/Avatar/Samples/CrossPlatform)
|
||||
5 - Use the Oculus Dashboard (https://dashboard.oculus.com/) to create a placeholder Rift app and copy the App ID
|
||||
6 - Paste the App ID in Unity under Oculus Avatars > Edit Configuration > Oculus Rift App Id
|
||||
7 - Enable OpenVR:
|
||||
Open PlayerSettings in the Inspector tab (from menu bar, Edit > Project Settings > Player)
|
||||
Under Virtual Reality SDKs, add OpenVR if it's not there already
|
||||
Remove Oculus (or drag it below OpenVR) so that OpenVR is used when the scene is played.
|
||||
8 - Click Play
|
||||
|
||||
The scene should play using SteamVR rather than the Oculus platform, and you'll see 12 different Oculus Avatars in front of you.
|
||||
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 5ec1b7b12e3fb3e4b99590edb47d298f
|
||||
timeCreated: 1539938373
|
||||
licenseType: Store
|
||||
TextScriptImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
9
Assets/Oculus/Avatar/Samples/GripPoses.meta
Normal file
9
Assets/Oculus/Avatar/Samples/GripPoses.meta
Normal file
@@ -0,0 +1,9 @@
|
||||
fileFormatVersion: 2
|
||||
guid: b8c4b9475079cf040953bf344ff4e44f
|
||||
folderAsset: yes
|
||||
timeCreated: 1477955918
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
2756
Assets/Oculus/Avatar/Samples/GripPoses/GripPoses.unity
Normal file
2756
Assets/Oculus/Avatar/Samples/GripPoses/GripPoses.unity
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 697c6df5e1eddad40b634d311b0bb2e5
|
||||
timeCreated: 1477966491
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
9
Assets/Oculus/Avatar/Samples/GripPoses/Scripts.meta
Normal file
9
Assets/Oculus/Avatar/Samples/GripPoses/Scripts.meta
Normal file
@@ -0,0 +1,9 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 85678699140c6c3429a87f4d679b1a17
|
||||
folderAsset: yes
|
||||
timeCreated: 1477957292
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,31 @@
|
||||
using UnityEngine;
|
||||
using System.Collections;
|
||||
using System;
|
||||
|
||||
public class PoseEditHelper : MonoBehaviour {
|
||||
|
||||
public Transform poseRoot;
|
||||
|
||||
void OnDrawGizmos()
|
||||
{
|
||||
if (poseRoot != null)
|
||||
{
|
||||
DrawJoints(poseRoot);
|
||||
}
|
||||
}
|
||||
|
||||
private void DrawJoints(Transform joint)
|
||||
{
|
||||
Gizmos.DrawWireSphere(joint.position, 0.005f);
|
||||
for (int i = 0; i < joint.childCount; ++i)
|
||||
{
|
||||
Transform child = joint.GetChild(i);
|
||||
if (child.name.EndsWith("_grip") || child.name.EndsWith("hand_ignore"))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
Gizmos.DrawLine(joint.position, child.position);
|
||||
DrawJoints(child);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 6bc5b4ba964e02b4ea773b2aaca7dc67
|
||||
timeCreated: 1477957304
|
||||
licenseType: Store
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
9
Assets/Oculus/Avatar/Samples/LocalAvatar.meta
Normal file
9
Assets/Oculus/Avatar/Samples/LocalAvatar.meta
Normal file
@@ -0,0 +1,9 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 2883b756c033a864ca988b3f522f3339
|
||||
folderAsset: yes
|
||||
timeCreated: 1467313725
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
671
Assets/Oculus/Avatar/Samples/LocalAvatar/LocalAvatar.unity
Normal file
671
Assets/Oculus/Avatar/Samples/LocalAvatar/LocalAvatar.unity
Normal file
@@ -0,0 +1,671 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!29 &1
|
||||
OcclusionCullingSettings:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 2
|
||||
m_OcclusionBakeSettings:
|
||||
smallestOccluder: 5
|
||||
smallestHole: 0.25
|
||||
backfaceThreshold: 100
|
||||
m_SceneGUID: 00000000000000000000000000000000
|
||||
m_OcclusionCullingData: {fileID: 0}
|
||||
--- !u!104 &2
|
||||
RenderSettings:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 8
|
||||
m_Fog: 0
|
||||
m_FogColor: {r: 0.5, g: 0.5, b: 0.5, a: 1}
|
||||
m_FogMode: 3
|
||||
m_FogDensity: 0.01
|
||||
m_LinearFogStart: 0
|
||||
m_LinearFogEnd: 300
|
||||
m_AmbientSkyColor: {r: 0.212, g: 0.227, b: 0.259, a: 1}
|
||||
m_AmbientEquatorColor: {r: 0.114, g: 0.125, b: 0.133, a: 1}
|
||||
m_AmbientGroundColor: {r: 0.047, g: 0.043, b: 0.035, a: 1}
|
||||
m_AmbientIntensity: 1
|
||||
m_AmbientMode: 0
|
||||
m_SubtractiveShadowColor: {r: 0.42, g: 0.478, b: 0.627, a: 1}
|
||||
m_SkyboxMaterial: {fileID: 10304, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_HaloStrength: 0.5
|
||||
m_FlareStrength: 1
|
||||
m_FlareFadeSpeed: 3
|
||||
m_HaloTexture: {fileID: 0}
|
||||
m_SpotCookie: {fileID: 10001, guid: 0000000000000000e000000000000000, type: 0}
|
||||
m_DefaultReflectionMode: 0
|
||||
m_DefaultReflectionResolution: 128
|
||||
m_ReflectionBounces: 1
|
||||
m_ReflectionIntensity: 1
|
||||
m_CustomReflection: {fileID: 0}
|
||||
m_Sun: {fileID: 0}
|
||||
m_IndirectSpecularColor: {r: 0.1838691, g: 0.22901776, b: 0.30311173, a: 1}
|
||||
--- !u!157 &3
|
||||
LightmapSettings:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 11
|
||||
m_GIWorkflowMode: 0
|
||||
m_GISettings:
|
||||
serializedVersion: 2
|
||||
m_BounceScale: 1
|
||||
m_IndirectOutputScale: 1
|
||||
m_AlbedoBoost: 1
|
||||
m_TemporalCoherenceThreshold: 1
|
||||
m_EnvironmentLightingMode: 0
|
||||
m_EnableBakedLightmaps: 1
|
||||
m_EnableRealtimeLightmaps: 1
|
||||
m_LightmapEditorSettings:
|
||||
serializedVersion: 9
|
||||
m_Resolution: 2
|
||||
m_BakeResolution: 40
|
||||
m_TextureWidth: 1024
|
||||
m_TextureHeight: 1024
|
||||
m_AO: 0
|
||||
m_AOMaxDistance: 1
|
||||
m_CompAOExponent: 0
|
||||
m_CompAOExponentDirect: 0
|
||||
m_Padding: 2
|
||||
m_LightmapParameters: {fileID: 0}
|
||||
m_LightmapsBakeMode: 1
|
||||
m_TextureCompression: 1
|
||||
m_FinalGather: 0
|
||||
m_FinalGatherFiltering: 1
|
||||
m_FinalGatherRayCount: 1024
|
||||
m_ReflectionCompression: 2
|
||||
m_MixedBakeMode: 1
|
||||
m_BakeBackend: 0
|
||||
m_PVRSampling: 1
|
||||
m_PVRDirectSampleCount: 32
|
||||
m_PVRSampleCount: 500
|
||||
m_PVRBounces: 2
|
||||
m_PVRFilterTypeDirect: 0
|
||||
m_PVRFilterTypeIndirect: 0
|
||||
m_PVRFilterTypeAO: 0
|
||||
m_PVRFilteringMode: 0
|
||||
m_PVRCulling: 1
|
||||
m_PVRFilteringGaussRadiusDirect: 1
|
||||
m_PVRFilteringGaussRadiusIndirect: 5
|
||||
m_PVRFilteringGaussRadiusAO: 2
|
||||
m_PVRFilteringAtrousPositionSigmaDirect: 0.5
|
||||
m_PVRFilteringAtrousPositionSigmaIndirect: 2
|
||||
m_PVRFilteringAtrousPositionSigmaAO: 1
|
||||
m_ShowResolutionOverlay: 1
|
||||
m_LightingDataAsset: {fileID: 0}
|
||||
m_UseShadowmask: 1
|
||||
--- !u!196 &4
|
||||
NavMeshSettings:
|
||||
serializedVersion: 2
|
||||
m_ObjectHideFlags: 0
|
||||
m_BuildSettings:
|
||||
serializedVersion: 2
|
||||
agentTypeID: 0
|
||||
agentRadius: 0.5
|
||||
agentHeight: 2
|
||||
agentSlope: 45
|
||||
agentClimb: 0.4
|
||||
ledgeDropHeight: 0
|
||||
maxJumpAcrossDistance: 0
|
||||
minRegionArea: 2
|
||||
manualCellSize: 0
|
||||
cellSize: 0.16666667
|
||||
manualTileSize: 0
|
||||
tileSize: 256
|
||||
accuratePlacement: 0
|
||||
debug:
|
||||
m_Flags: 0
|
||||
m_NavMeshData: {fileID: 0}
|
||||
--- !u!1001 &30431259
|
||||
Prefab:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 2
|
||||
m_Modification:
|
||||
m_TransformParent: {fileID: 0}
|
||||
m_Modifications:
|
||||
- target: {fileID: 4372900245187776, guid: 93c8b27ca530be741a2ea419a122d453, type: 2}
|
||||
propertyPath: m_LocalPosition.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 4372900245187776, guid: 93c8b27ca530be741a2ea419a122d453, type: 2}
|
||||
propertyPath: m_LocalPosition.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 4372900245187776, guid: 93c8b27ca530be741a2ea419a122d453, type: 2}
|
||||
propertyPath: m_LocalPosition.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 4372900245187776, guid: 93c8b27ca530be741a2ea419a122d453, type: 2}
|
||||
propertyPath: m_LocalRotation.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 4372900245187776, guid: 93c8b27ca530be741a2ea419a122d453, type: 2}
|
||||
propertyPath: m_LocalRotation.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 4372900245187776, guid: 93c8b27ca530be741a2ea419a122d453, type: 2}
|
||||
propertyPath: m_LocalRotation.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 4372900245187776, guid: 93c8b27ca530be741a2ea419a122d453, type: 2}
|
||||
propertyPath: m_LocalRotation.w
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 4372900245187776, guid: 93c8b27ca530be741a2ea419a122d453, type: 2}
|
||||
propertyPath: m_RootOrder
|
||||
value: 4
|
||||
objectReference: {fileID: 0}
|
||||
m_RemovedComponents: []
|
||||
m_ParentPrefab: {fileID: 100100000, guid: 93c8b27ca530be741a2ea419a122d453, type: 2}
|
||||
m_IsPrefabParent: 0
|
||||
--- !u!1001 &479796876
|
||||
Prefab:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 2
|
||||
m_Modification:
|
||||
m_TransformParent: {fileID: 0}
|
||||
m_Modifications:
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalPosition.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalPosition.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalPosition.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalRotation.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalRotation.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalRotation.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalRotation.w
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_RootOrder
|
||||
value: 2
|
||||
objectReference: {fileID: 0}
|
||||
m_RemovedComponents: []
|
||||
m_ParentPrefab: {fileID: 100100000, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
m_IsPrefabParent: 0
|
||||
--- !u!1001 &728245522
|
||||
Prefab:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 2
|
||||
m_Modification:
|
||||
m_TransformParent: {fileID: 0}
|
||||
m_Modifications:
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalPosition.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalPosition.y
|
||||
value: 0.6
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalPosition.z
|
||||
value: 0.5
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalRotation.x
|
||||
value: -0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalRotation.y
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalRotation.z
|
||||
value: -0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalRotation.w
|
||||
value: -0.00000016292068
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_RootOrder
|
||||
value: 3
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 158226, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_Name
|
||||
value: Little_LocalAvatar
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 11437430, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: ShowThirdPerson
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalScale.x
|
||||
value: 0.25
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalScale.y
|
||||
value: 0.25
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalScale.z
|
||||
value: 0.25
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 11437430, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: ShowFirstPerson
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
m_RemovedComponents: []
|
||||
m_ParentPrefab: {fileID: 100100000, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
m_IsPrefabParent: 0
|
||||
--- !u!1 &855176794
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
serializedVersion: 5
|
||||
m_Component:
|
||||
- component: {fileID: 855176795}
|
||||
m_Layer: 0
|
||||
m_Name: Table
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &855176795
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 855176794}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0.5}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children:
|
||||
- {fileID: 1517158095}
|
||||
- {fileID: 1903359377}
|
||||
m_Father: {fileID: 999742310}
|
||||
m_RootOrder: 1
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!1 &957641525
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
serializedVersion: 5
|
||||
m_Component:
|
||||
- component: {fileID: 957641529}
|
||||
- component: {fileID: 957641528}
|
||||
- component: {fileID: 957641526}
|
||||
m_Layer: 0
|
||||
m_Name: Floor
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 4294967295
|
||||
m_IsActive: 1
|
||||
--- !u!23 &957641526
|
||||
MeshRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 957641525}
|
||||
m_Enabled: 1
|
||||
m_CastShadows: 1
|
||||
m_ReceiveShadows: 1
|
||||
m_DynamicOccludee: 1
|
||||
m_MotionVectors: 1
|
||||
m_LightProbeUsage: 1
|
||||
m_ReflectionProbeUsage: 1
|
||||
m_Materials:
|
||||
- {fileID: 10303, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_StaticBatchInfo:
|
||||
firstSubMesh: 0
|
||||
subMeshCount: 0
|
||||
m_StaticBatchRoot: {fileID: 0}
|
||||
m_ProbeAnchor: {fileID: 0}
|
||||
m_LightProbeVolumeOverride: {fileID: 0}
|
||||
m_ScaleInLightmap: 1
|
||||
m_PreserveUVs: 1
|
||||
m_IgnoreNormalsForChartDetection: 0
|
||||
m_ImportantGI: 0
|
||||
m_StitchLightmapSeams: 0
|
||||
m_SelectedEditorRenderState: 3
|
||||
m_MinimumChartSize: 4
|
||||
m_AutoUVMaxDistance: 0.5
|
||||
m_AutoUVMaxAngle: 89
|
||||
m_LightmapParameters: {fileID: 0}
|
||||
m_SortingLayerID: 0
|
||||
m_SortingLayer: 0
|
||||
m_SortingOrder: 0
|
||||
--- !u!33 &957641528
|
||||
MeshFilter:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 957641525}
|
||||
m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0}
|
||||
--- !u!4 &957641529
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 957641525}
|
||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: -0.025, z: 0}
|
||||
m_LocalScale: {x: 2, y: 0.05, z: 2}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 999742310}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!1 &999742309
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
serializedVersion: 5
|
||||
m_Component:
|
||||
- component: {fileID: 999742310}
|
||||
m_Layer: 0
|
||||
m_Name: SceneGeometry
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &999742310
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 999742309}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children:
|
||||
- {fileID: 957641529}
|
||||
- {fileID: 855176795}
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 5
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!1001 &1239677853
|
||||
Prefab:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 2
|
||||
m_Modification:
|
||||
m_TransformParent: {fileID: 0}
|
||||
m_Modifications:
|
||||
- target: {fileID: 400004, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: m_LocalPosition.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400004, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: m_LocalPosition.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400004, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: m_LocalPosition.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400004, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: m_LocalRotation.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400004, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: m_LocalRotation.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400004, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: m_LocalRotation.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400004, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: m_LocalRotation.w
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400004, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: m_RootOrder
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 11400010, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: usePerEyeCameras
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 20000012175207052, guid: 126d619cf4daa52469682f85c1378b4a,
|
||||
type: 2}
|
||||
propertyPath: m_Enabled
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 2037080, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: m_Enabled
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 20000010189485334, guid: 126d619cf4daa52469682f85c1378b4a,
|
||||
type: 2}
|
||||
propertyPath: m_Enabled
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 11400000, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: _trackingOriginType
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 11400000, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: resetTrackerOnLoad
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
m_RemovedComponents: []
|
||||
m_ParentPrefab: {fileID: 100100000, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
m_IsPrefabParent: 0
|
||||
--- !u!1 &1517158094
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
serializedVersion: 5
|
||||
m_Component:
|
||||
- component: {fileID: 1517158095}
|
||||
- component: {fileID: 1517158097}
|
||||
- component: {fileID: 1517158096}
|
||||
m_Layer: 0
|
||||
m_Name: Top
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &1517158095
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1517158094}
|
||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0.6, z: 0}
|
||||
m_LocalScale: {x: 0.5, y: 0.02, z: 0.5}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 855176795}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!23 &1517158096
|
||||
MeshRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1517158094}
|
||||
m_Enabled: 1
|
||||
m_CastShadows: 1
|
||||
m_ReceiveShadows: 1
|
||||
m_DynamicOccludee: 1
|
||||
m_MotionVectors: 1
|
||||
m_LightProbeUsage: 1
|
||||
m_ReflectionProbeUsage: 1
|
||||
m_Materials:
|
||||
- {fileID: 10303, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_StaticBatchInfo:
|
||||
firstSubMesh: 0
|
||||
subMeshCount: 0
|
||||
m_StaticBatchRoot: {fileID: 0}
|
||||
m_ProbeAnchor: {fileID: 0}
|
||||
m_LightProbeVolumeOverride: {fileID: 0}
|
||||
m_ScaleInLightmap: 1
|
||||
m_PreserveUVs: 1
|
||||
m_IgnoreNormalsForChartDetection: 0
|
||||
m_ImportantGI: 0
|
||||
m_StitchLightmapSeams: 0
|
||||
m_SelectedEditorRenderState: 3
|
||||
m_MinimumChartSize: 4
|
||||
m_AutoUVMaxDistance: 0.5
|
||||
m_AutoUVMaxAngle: 89
|
||||
m_LightmapParameters: {fileID: 0}
|
||||
m_SortingLayerID: 0
|
||||
m_SortingLayer: 0
|
||||
m_SortingOrder: 0
|
||||
--- !u!33 &1517158097
|
||||
MeshFilter:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1517158094}
|
||||
m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0}
|
||||
--- !u!1 &1658970730
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
serializedVersion: 5
|
||||
m_Component:
|
||||
- component: {fileID: 1658970732}
|
||||
- component: {fileID: 1658970731}
|
||||
m_Layer: 0
|
||||
m_Name: Directional Light
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!108 &1658970731
|
||||
Light:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1658970730}
|
||||
m_Enabled: 1
|
||||
serializedVersion: 8
|
||||
m_Type: 1
|
||||
m_Color: {r: 0.5955882, g: 0.5955882, b: 0.5955882, a: 1}
|
||||
m_Intensity: 1
|
||||
m_Range: 10
|
||||
m_SpotAngle: 30
|
||||
m_CookieSize: 10
|
||||
m_Shadows:
|
||||
m_Type: 2
|
||||
m_Resolution: -1
|
||||
m_CustomResolution: -1
|
||||
m_Strength: 1
|
||||
m_Bias: 0.05
|
||||
m_NormalBias: 0.4
|
||||
m_NearPlane: 0.2
|
||||
m_Cookie: {fileID: 0}
|
||||
m_DrawHalo: 0
|
||||
m_Flare: {fileID: 0}
|
||||
m_RenderMode: 0
|
||||
m_CullingMask:
|
||||
serializedVersion: 2
|
||||
m_Bits: 4294967295
|
||||
m_Lightmapping: 4
|
||||
m_AreaSize: {x: 1, y: 1}
|
||||
m_BounceIntensity: 1
|
||||
m_ColorTemperature: 6570
|
||||
m_UseColorTemperature: 0
|
||||
m_ShadowRadius: 0
|
||||
m_ShadowAngle: 0
|
||||
--- !u!4 &1658970732
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1658970730}
|
||||
m_LocalRotation: {x: 0.25000006, y: 0.25000006, z: -0.06698733, w: 0.9330127}
|
||||
m_LocalPosition: {x: 0, y: 3, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 30, y: 30, z: 0}
|
||||
--- !u!1 &1903359376
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
serializedVersion: 5
|
||||
m_Component:
|
||||
- component: {fileID: 1903359377}
|
||||
- component: {fileID: 1903359379}
|
||||
- component: {fileID: 1903359378}
|
||||
m_Layer: 0
|
||||
m_Name: Pillar
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &1903359377
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1903359376}
|
||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0.3, z: 0}
|
||||
m_LocalScale: {x: 0.05, y: 0.6, z: 0.05}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 855176795}
|
||||
m_RootOrder: 1
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!23 &1903359378
|
||||
MeshRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1903359376}
|
||||
m_Enabled: 1
|
||||
m_CastShadows: 1
|
||||
m_ReceiveShadows: 1
|
||||
m_DynamicOccludee: 1
|
||||
m_MotionVectors: 1
|
||||
m_LightProbeUsage: 1
|
||||
m_ReflectionProbeUsage: 1
|
||||
m_Materials:
|
||||
- {fileID: 10303, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_StaticBatchInfo:
|
||||
firstSubMesh: 0
|
||||
subMeshCount: 0
|
||||
m_StaticBatchRoot: {fileID: 0}
|
||||
m_ProbeAnchor: {fileID: 0}
|
||||
m_LightProbeVolumeOverride: {fileID: 0}
|
||||
m_ScaleInLightmap: 1
|
||||
m_PreserveUVs: 1
|
||||
m_IgnoreNormalsForChartDetection: 0
|
||||
m_ImportantGI: 0
|
||||
m_StitchLightmapSeams: 0
|
||||
m_SelectedEditorRenderState: 3
|
||||
m_MinimumChartSize: 4
|
||||
m_AutoUVMaxDistance: 0.5
|
||||
m_AutoUVMaxAngle: 89
|
||||
m_LightmapParameters: {fileID: 0}
|
||||
m_SortingLayerID: 0
|
||||
m_SortingLayer: 0
|
||||
m_SortingOrder: 0
|
||||
--- !u!33 &1903359379
|
||||
MeshFilter:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1903359376}
|
||||
m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0}
|
||||
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: c65ef87480e70eb43931036c9c66d08d
|
||||
timeCreated: 1466730185
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
9
Assets/Oculus/Avatar/Samples/LocalAvatar/Prefabs.meta
Normal file
9
Assets/Oculus/Avatar/Samples/LocalAvatar/Prefabs.meta
Normal file
@@ -0,0 +1,9 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 6ab4fae765a78ff4891d22240708e124
|
||||
folderAsset: yes
|
||||
timeCreated: 1543419231
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,97 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!1001 &100100000
|
||||
Prefab:
|
||||
m_ObjectHideFlags: 1
|
||||
serializedVersion: 2
|
||||
m_Modification:
|
||||
m_TransformParent: {fileID: 0}
|
||||
m_Modifications: []
|
||||
m_RemovedComponents: []
|
||||
m_ParentPrefab: {fileID: 0}
|
||||
m_RootGameObject: {fileID: 1862311091348296}
|
||||
m_IsPrefabParent: 1
|
||||
--- !u!1 &1862311091348296
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 100100000}
|
||||
serializedVersion: 5
|
||||
m_Component:
|
||||
- component: {fileID: 4698346712314376}
|
||||
- component: {fileID: 33311121837070838}
|
||||
- component: {fileID: 23625037719976976}
|
||||
- component: {fileID: 114267226149696678}
|
||||
m_Layer: 0
|
||||
m_Name: GazeTarget
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &4698346712314376
|
||||
Transform:
|
||||
m_ObjectHideFlags: 1
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 100100000}
|
||||
m_GameObject: {fileID: 1862311091348296}
|
||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 0.05, y: 0.05, z: 0.05}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!23 &23625037719976976
|
||||
MeshRenderer:
|
||||
m_ObjectHideFlags: 1
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 100100000}
|
||||
m_GameObject: {fileID: 1862311091348296}
|
||||
m_Enabled: 0
|
||||
m_CastShadows: 1
|
||||
m_ReceiveShadows: 1
|
||||
m_DynamicOccludee: 1
|
||||
m_MotionVectors: 1
|
||||
m_LightProbeUsage: 1
|
||||
m_ReflectionProbeUsage: 1
|
||||
m_Materials:
|
||||
- {fileID: 10303, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_StaticBatchInfo:
|
||||
firstSubMesh: 0
|
||||
subMeshCount: 0
|
||||
m_StaticBatchRoot: {fileID: 0}
|
||||
m_ProbeAnchor: {fileID: 0}
|
||||
m_LightProbeVolumeOverride: {fileID: 0}
|
||||
m_ScaleInLightmap: 1
|
||||
m_PreserveUVs: 1
|
||||
m_IgnoreNormalsForChartDetection: 0
|
||||
m_ImportantGI: 0
|
||||
m_StitchLightmapSeams: 0
|
||||
m_SelectedEditorRenderState: 3
|
||||
m_MinimumChartSize: 4
|
||||
m_AutoUVMaxDistance: 0.5
|
||||
m_AutoUVMaxAngle: 89
|
||||
m_LightmapParameters: {fileID: 0}
|
||||
m_SortingLayerID: 0
|
||||
m_SortingLayer: 0
|
||||
m_SortingOrder: 0
|
||||
--- !u!33 &33311121837070838
|
||||
MeshFilter:
|
||||
m_ObjectHideFlags: 1
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 100100000}
|
||||
m_GameObject: {fileID: 1862311091348296}
|
||||
m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0}
|
||||
--- !u!114 &114267226149696678
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 1
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 100100000}
|
||||
m_GameObject: {fileID: 1862311091348296}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 5bfcd054df64e334ba2f191666f3fe92, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
Type: 2
|
||||
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 38d5bb078fd83c9428125e487bef4a1a
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 0
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,58 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!1001 &100100000
|
||||
Prefab:
|
||||
m_ObjectHideFlags: 1
|
||||
serializedVersion: 2
|
||||
m_Modification:
|
||||
m_TransformParent: {fileID: 0}
|
||||
m_Modifications: []
|
||||
m_RemovedComponents: []
|
||||
m_ParentPrefab: {fileID: 0}
|
||||
m_RootGameObject: {fileID: 1886941009443022}
|
||||
m_IsPrefabParent: 1
|
||||
--- !u!1 &1886941009443022
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 100100000}
|
||||
serializedVersion: 5
|
||||
m_Component:
|
||||
- component: {fileID: 4372900245187776}
|
||||
- component: {fileID: 114195579247105032}
|
||||
m_Layer: 0
|
||||
m_Name: GazeTargetSpawner
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &4372900245187776
|
||||
Transform:
|
||||
m_ObjectHideFlags: 1
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 100100000}
|
||||
m_GameObject: {fileID: 1886941009443022}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!114 &114195579247105032
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 1
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 100100000}
|
||||
m_GameObject: {fileID: 1886941009443022}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 3864ef0c62744294899fddc93640130f, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
GazeTargetPrefab: {fileID: 1862311091348296, guid: 38d5bb078fd83c9428125e487bef4a1a,
|
||||
type: 2}
|
||||
NumberOfDummyTargets: 100
|
||||
RadiusMultiplier: 3
|
||||
isVisible: 0
|
||||
@@ -0,0 +1,9 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 93c8b27ca530be741a2ea419a122d453
|
||||
timeCreated: 1543419517
|
||||
licenseType: Store
|
||||
NativeFormatImporter:
|
||||
mainObjectFileID: 100100000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
8
Assets/Oculus/Avatar/Samples/LocalAvatar/Scripts.meta
Normal file
8
Assets/Oculus/Avatar/Samples/LocalAvatar/Scripts.meta
Normal file
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 1391b4a6e544aab4bb1d8cf41ef93d8e
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,48 @@
|
||||
using UnityEngine;
|
||||
|
||||
public class GazeTargetSpawner : MonoBehaviour
|
||||
{
|
||||
public GameObject GazeTargetPrefab;
|
||||
public int NumberOfDummyTargets = 100;
|
||||
public int RadiusMultiplier = 3;
|
||||
[SerializeField]
|
||||
private bool isVisible;
|
||||
public bool IsVisible
|
||||
{
|
||||
get
|
||||
{
|
||||
return isVisible;
|
||||
}
|
||||
set
|
||||
{
|
||||
isVisible = value;
|
||||
GazeTarget[] dummyGazeTargets = gameObject.GetComponentsInChildren<GazeTarget>();
|
||||
for (int i = 0; i < dummyGazeTargets.Length; ++i)
|
||||
{
|
||||
MeshRenderer dummyMesh = dummyGazeTargets[i].GetComponent<MeshRenderer>();
|
||||
if (dummyMesh != null)
|
||||
{
|
||||
dummyMesh.enabled = isVisible;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void Start ()
|
||||
{
|
||||
for (int i = 0; i < NumberOfDummyTargets; ++i)
|
||||
{
|
||||
GameObject target = Instantiate(GazeTargetPrefab, transform);
|
||||
target.name += "_" + i;
|
||||
target.transform.localPosition = Random.insideUnitSphere * RadiusMultiplier;
|
||||
target.transform.rotation = Quaternion.identity;
|
||||
target.GetComponent<MeshRenderer>().enabled = IsVisible;
|
||||
}
|
||||
}
|
||||
|
||||
void OnValidate()
|
||||
{
|
||||
// Run through OnValidate to pick up changes from inspector
|
||||
IsVisible = isVisible;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 3864ef0c62744294899fddc93640130f
|
||||
timeCreated: 1543418975
|
||||
licenseType: Store
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
9
Assets/Oculus/Avatar/Samples/RemoteLoopback.meta
Normal file
9
Assets/Oculus/Avatar/Samples/RemoteLoopback.meta
Normal file
@@ -0,0 +1,9 @@
|
||||
fileFormatVersion: 2
|
||||
guid: f26892c9951b6f54c82a5f1bf34e8d8a
|
||||
folderAsset: yes
|
||||
timeCreated: 1468000039
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
513
Assets/Oculus/Avatar/Samples/RemoteLoopback/RemoteLoopback.unity
Normal file
513
Assets/Oculus/Avatar/Samples/RemoteLoopback/RemoteLoopback.unity
Normal file
@@ -0,0 +1,513 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!29 &1
|
||||
OcclusionCullingSettings:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 2
|
||||
m_OcclusionBakeSettings:
|
||||
smallestOccluder: 5
|
||||
smallestHole: 0.25
|
||||
backfaceThreshold: 100
|
||||
m_SceneGUID: 00000000000000000000000000000000
|
||||
m_OcclusionCullingData: {fileID: 0}
|
||||
--- !u!104 &2
|
||||
RenderSettings:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 8
|
||||
m_Fog: 0
|
||||
m_FogColor: {r: 0.5, g: 0.5, b: 0.5, a: 1}
|
||||
m_FogMode: 3
|
||||
m_FogDensity: 0.01
|
||||
m_LinearFogStart: 0
|
||||
m_LinearFogEnd: 300
|
||||
m_AmbientSkyColor: {r: 0.212, g: 0.227, b: 0.259, a: 1}
|
||||
m_AmbientEquatorColor: {r: 0.114, g: 0.125, b: 0.133, a: 1}
|
||||
m_AmbientGroundColor: {r: 0.047, g: 0.043, b: 0.035, a: 1}
|
||||
m_AmbientIntensity: 1
|
||||
m_AmbientMode: 0
|
||||
m_SubtractiveShadowColor: {r: 0.42, g: 0.478, b: 0.627, a: 1}
|
||||
m_SkyboxMaterial: {fileID: 10304, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_HaloStrength: 0.5
|
||||
m_FlareStrength: 1
|
||||
m_FlareFadeSpeed: 3
|
||||
m_HaloTexture: {fileID: 0}
|
||||
m_SpotCookie: {fileID: 10001, guid: 0000000000000000e000000000000000, type: 0}
|
||||
m_DefaultReflectionMode: 0
|
||||
m_DefaultReflectionResolution: 128
|
||||
m_ReflectionBounces: 1
|
||||
m_ReflectionIntensity: 1
|
||||
m_CustomReflection: {fileID: 0}
|
||||
m_Sun: {fileID: 0}
|
||||
m_IndirectSpecularColor: {r: 0.18386917, g: 0.2290177, b: 0.30311212, a: 1}
|
||||
--- !u!157 &3
|
||||
LightmapSettings:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 11
|
||||
m_GIWorkflowMode: 0
|
||||
m_GISettings:
|
||||
serializedVersion: 2
|
||||
m_BounceScale: 1
|
||||
m_IndirectOutputScale: 1
|
||||
m_AlbedoBoost: 1
|
||||
m_TemporalCoherenceThreshold: 1
|
||||
m_EnvironmentLightingMode: 0
|
||||
m_EnableBakedLightmaps: 1
|
||||
m_EnableRealtimeLightmaps: 1
|
||||
m_LightmapEditorSettings:
|
||||
serializedVersion: 9
|
||||
m_Resolution: 2
|
||||
m_BakeResolution: 40
|
||||
m_TextureWidth: 1024
|
||||
m_TextureHeight: 1024
|
||||
m_AO: 0
|
||||
m_AOMaxDistance: 1
|
||||
m_CompAOExponent: 0
|
||||
m_CompAOExponentDirect: 0
|
||||
m_Padding: 2
|
||||
m_LightmapParameters: {fileID: 0}
|
||||
m_LightmapsBakeMode: 1
|
||||
m_TextureCompression: 1
|
||||
m_FinalGather: 0
|
||||
m_FinalGatherFiltering: 1
|
||||
m_FinalGatherRayCount: 1024
|
||||
m_ReflectionCompression: 2
|
||||
m_MixedBakeMode: 1
|
||||
m_BakeBackend: 0
|
||||
m_PVRSampling: 1
|
||||
m_PVRDirectSampleCount: 32
|
||||
m_PVRSampleCount: 500
|
||||
m_PVRBounces: 2
|
||||
m_PVRFilterTypeDirect: 0
|
||||
m_PVRFilterTypeIndirect: 0
|
||||
m_PVRFilterTypeAO: 0
|
||||
m_PVRFilteringMode: 0
|
||||
m_PVRCulling: 1
|
||||
m_PVRFilteringGaussRadiusDirect: 1
|
||||
m_PVRFilteringGaussRadiusIndirect: 5
|
||||
m_PVRFilteringGaussRadiusAO: 2
|
||||
m_PVRFilteringAtrousPositionSigmaDirect: 0.5
|
||||
m_PVRFilteringAtrousPositionSigmaIndirect: 2
|
||||
m_PVRFilteringAtrousPositionSigmaAO: 1
|
||||
m_ShowResolutionOverlay: 1
|
||||
m_LightingDataAsset: {fileID: 0}
|
||||
m_UseShadowmask: 1
|
||||
--- !u!196 &4
|
||||
NavMeshSettings:
|
||||
serializedVersion: 2
|
||||
m_ObjectHideFlags: 0
|
||||
m_BuildSettings:
|
||||
serializedVersion: 2
|
||||
agentTypeID: 0
|
||||
agentRadius: 0.5
|
||||
agentHeight: 2
|
||||
agentSlope: 45
|
||||
agentClimb: 0.4
|
||||
ledgeDropHeight: 0
|
||||
maxJumpAcrossDistance: 0
|
||||
minRegionArea: 2
|
||||
manualCellSize: 0
|
||||
cellSize: 0.16666667
|
||||
manualTileSize: 0
|
||||
tileSize: 256
|
||||
accuratePlacement: 0
|
||||
debug:
|
||||
m_Flags: 0
|
||||
m_NavMeshData: {fileID: 0}
|
||||
--- !u!1001 &672535801
|
||||
Prefab:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 2
|
||||
m_Modification:
|
||||
m_TransformParent: {fileID: 0}
|
||||
m_Modifications:
|
||||
- target: {fileID: 496618, guid: 90bf33f968e6bb44ea0208fc82c90a44, type: 2}
|
||||
propertyPath: m_LocalPosition.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 496618, guid: 90bf33f968e6bb44ea0208fc82c90a44, type: 2}
|
||||
propertyPath: m_LocalPosition.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 496618, guid: 90bf33f968e6bb44ea0208fc82c90a44, type: 2}
|
||||
propertyPath: m_LocalPosition.z
|
||||
value: 0.5
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 496618, guid: 90bf33f968e6bb44ea0208fc82c90a44, type: 2}
|
||||
propertyPath: m_LocalRotation.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 496618, guid: 90bf33f968e6bb44ea0208fc82c90a44, type: 2}
|
||||
propertyPath: m_LocalRotation.y
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 496618, guid: 90bf33f968e6bb44ea0208fc82c90a44, type: 2}
|
||||
propertyPath: m_LocalRotation.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 496618, guid: 90bf33f968e6bb44ea0208fc82c90a44, type: 2}
|
||||
propertyPath: m_LocalRotation.w
|
||||
value: -0.00000016292068
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 496618, guid: 90bf33f968e6bb44ea0208fc82c90a44, type: 2}
|
||||
propertyPath: m_RootOrder
|
||||
value: 4
|
||||
objectReference: {fileID: 0}
|
||||
m_RemovedComponents: []
|
||||
m_ParentPrefab: {fileID: 100100000, guid: 90bf33f968e6bb44ea0208fc82c90a44, type: 2}
|
||||
m_IsPrefabParent: 0
|
||||
--- !u!1 &957641525
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
serializedVersion: 5
|
||||
m_Component:
|
||||
- component: {fileID: 957641529}
|
||||
- component: {fileID: 957641528}
|
||||
- component: {fileID: 957641527}
|
||||
- component: {fileID: 957641526}
|
||||
m_Layer: 0
|
||||
m_Name: Floor
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 4294967295
|
||||
m_IsActive: 1
|
||||
--- !u!23 &957641526
|
||||
MeshRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 957641525}
|
||||
m_Enabled: 1
|
||||
m_CastShadows: 1
|
||||
m_ReceiveShadows: 1
|
||||
m_DynamicOccludee: 1
|
||||
m_MotionVectors: 1
|
||||
m_LightProbeUsage: 1
|
||||
m_ReflectionProbeUsage: 1
|
||||
m_Materials:
|
||||
- {fileID: 10303, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_StaticBatchInfo:
|
||||
firstSubMesh: 0
|
||||
subMeshCount: 0
|
||||
m_StaticBatchRoot: {fileID: 0}
|
||||
m_ProbeAnchor: {fileID: 0}
|
||||
m_LightProbeVolumeOverride: {fileID: 0}
|
||||
m_ScaleInLightmap: 1
|
||||
m_PreserveUVs: 1
|
||||
m_IgnoreNormalsForChartDetection: 0
|
||||
m_ImportantGI: 0
|
||||
m_StitchLightmapSeams: 0
|
||||
m_SelectedEditorRenderState: 3
|
||||
m_MinimumChartSize: 4
|
||||
m_AutoUVMaxDistance: 0.5
|
||||
m_AutoUVMaxAngle: 89
|
||||
m_LightmapParameters: {fileID: 0}
|
||||
m_SortingLayerID: 0
|
||||
m_SortingLayer: 0
|
||||
m_SortingOrder: 0
|
||||
--- !u!65 &957641527
|
||||
BoxCollider:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 957641525}
|
||||
m_Material: {fileID: 0}
|
||||
m_IsTrigger: 0
|
||||
m_Enabled: 1
|
||||
serializedVersion: 2
|
||||
m_Size: {x: 1, y: 1, z: 1}
|
||||
m_Center: {x: 0, y: 0, z: 0}
|
||||
--- !u!33 &957641528
|
||||
MeshFilter:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 957641525}
|
||||
m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0}
|
||||
--- !u!4 &957641529
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 957641525}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: -0.5, z: 0}
|
||||
m_LocalScale: {x: 10, y: 1, z: 10}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 1
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!1001 &1233912640
|
||||
Prefab:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 2
|
||||
m_Modification:
|
||||
m_TransformParent: {fileID: 0}
|
||||
m_Modifications:
|
||||
- target: {fileID: 4372900245187776, guid: 93c8b27ca530be741a2ea419a122d453, type: 2}
|
||||
propertyPath: m_LocalPosition.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 4372900245187776, guid: 93c8b27ca530be741a2ea419a122d453, type: 2}
|
||||
propertyPath: m_LocalPosition.y
|
||||
value: 1.6
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 4372900245187776, guid: 93c8b27ca530be741a2ea419a122d453, type: 2}
|
||||
propertyPath: m_LocalPosition.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 4372900245187776, guid: 93c8b27ca530be741a2ea419a122d453, type: 2}
|
||||
propertyPath: m_LocalRotation.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 4372900245187776, guid: 93c8b27ca530be741a2ea419a122d453, type: 2}
|
||||
propertyPath: m_LocalRotation.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 4372900245187776, guid: 93c8b27ca530be741a2ea419a122d453, type: 2}
|
||||
propertyPath: m_LocalRotation.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 4372900245187776, guid: 93c8b27ca530be741a2ea419a122d453, type: 2}
|
||||
propertyPath: m_LocalRotation.w
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 4372900245187776, guid: 93c8b27ca530be741a2ea419a122d453, type: 2}
|
||||
propertyPath: m_RootOrder
|
||||
value: 6
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 4372900245187776, guid: 93c8b27ca530be741a2ea419a122d453, type: 2}
|
||||
propertyPath: m_LocalEulerAnglesHint.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 114195579247105032, guid: 93c8b27ca530be741a2ea419a122d453,
|
||||
type: 2}
|
||||
propertyPath: NumberOfDummyTargets
|
||||
value: 10
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 114195579247105032, guid: 93c8b27ca530be741a2ea419a122d453,
|
||||
type: 2}
|
||||
propertyPath: RadiusMultiplier
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
m_RemovedComponents: []
|
||||
m_ParentPrefab: {fileID: 100100000, guid: 93c8b27ca530be741a2ea419a122d453, type: 2}
|
||||
m_IsPrefabParent: 0
|
||||
--- !u!1 &1350565873
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
serializedVersion: 5
|
||||
m_Component:
|
||||
- component: {fileID: 1350565874}
|
||||
- component: {fileID: 1350565875}
|
||||
m_Layer: 0
|
||||
m_Name: RemoteLoopbackManager
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &1350565874
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1350565873}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0.57821083, y: 1.1191388, z: 0.57511383}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 5
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!114 &1350565875
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1350565873}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 1675d6690178fd0459887aed66409f70, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
LocalAvatar: {fileID: 1997500170}
|
||||
LoopbackAvatar: {fileID: 1966604974}
|
||||
LatencySettings:
|
||||
FakeLatencyMax: 0.25
|
||||
FakeLatencyMin: 0.002
|
||||
LatencyWeight: 0.25
|
||||
MaxSamples: 4
|
||||
--- !u!1001 &1473758005
|
||||
Prefab:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 2
|
||||
m_Modification:
|
||||
m_TransformParent: {fileID: 0}
|
||||
m_Modifications:
|
||||
- target: {fileID: 400004, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: m_LocalPosition.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400004, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: m_LocalPosition.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400004, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: m_LocalPosition.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400004, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: m_LocalRotation.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400004, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: m_LocalRotation.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400004, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: m_LocalRotation.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400004, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: m_LocalRotation.w
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400004, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: m_RootOrder
|
||||
value: 2
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 11400000, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: resetTrackerOnLoad
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 11400000, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
propertyPath: _trackingOriginType
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
m_RemovedComponents: []
|
||||
m_ParentPrefab: {fileID: 100100000, guid: 126d619cf4daa52469682f85c1378b4a, type: 2}
|
||||
m_IsPrefabParent: 0
|
||||
--- !u!1 &1658970730
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
serializedVersion: 5
|
||||
m_Component:
|
||||
- component: {fileID: 1658970732}
|
||||
- component: {fileID: 1658970731}
|
||||
m_Layer: 0
|
||||
m_Name: Directional Light
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!108 &1658970731
|
||||
Light:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1658970730}
|
||||
m_Enabled: 1
|
||||
serializedVersion: 8
|
||||
m_Type: 1
|
||||
m_Color: {r: 0.5955882, g: 0.5955882, b: 0.5955882, a: 1}
|
||||
m_Intensity: 1
|
||||
m_Range: 10
|
||||
m_SpotAngle: 30
|
||||
m_CookieSize: 10
|
||||
m_Shadows:
|
||||
m_Type: 2
|
||||
m_Resolution: -1
|
||||
m_CustomResolution: -1
|
||||
m_Strength: 1
|
||||
m_Bias: 0.05
|
||||
m_NormalBias: 0.4
|
||||
m_NearPlane: 0.2
|
||||
m_Cookie: {fileID: 0}
|
||||
m_DrawHalo: 0
|
||||
m_Flare: {fileID: 0}
|
||||
m_RenderMode: 0
|
||||
m_CullingMask:
|
||||
serializedVersion: 2
|
||||
m_Bits: 4294967295
|
||||
m_Lightmapping: 4
|
||||
m_AreaSize: {x: 1, y: 1}
|
||||
m_BounceIntensity: 1
|
||||
m_ColorTemperature: 6570
|
||||
m_UseColorTemperature: 0
|
||||
m_ShadowRadius: 0
|
||||
m_ShadowAngle: 0
|
||||
--- !u!4 &1658970732
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1658970730}
|
||||
m_LocalRotation: {x: 0.25000006, y: -0.24999997, z: 0.066987306, w: 0.9330127}
|
||||
m_LocalPosition: {x: 0, y: 3, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 30, y: -30, z: 0}
|
||||
--- !u!1001 &1742914067
|
||||
Prefab:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 2
|
||||
m_Modification:
|
||||
m_TransformParent: {fileID: 0}
|
||||
m_Modifications:
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalPosition.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalPosition.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalPosition.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalRotation.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalRotation.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalRotation.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_LocalRotation.w
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 463470, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
propertyPath: m_RootOrder
|
||||
value: 3
|
||||
objectReference: {fileID: 0}
|
||||
m_RemovedComponents: []
|
||||
m_ParentPrefab: {fileID: 100100000, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
m_IsPrefabParent: 0
|
||||
--- !u!114 &1966604974 stripped
|
||||
MonoBehaviour:
|
||||
m_PrefabParentObject: {fileID: 11464902, guid: 90bf33f968e6bb44ea0208fc82c90a44,
|
||||
type: 2}
|
||||
m_PrefabInternal: {fileID: 672535801}
|
||||
m_Script: {fileID: 11500000, guid: 00f3402a2ea5bff4880c0313515240cd, type: 3}
|
||||
--- !u!114 &1997500170 stripped
|
||||
MonoBehaviour:
|
||||
m_PrefabParentObject: {fileID: 11437430, guid: 84c8b8609f9bb434eaf5248f17ff1293,
|
||||
type: 2}
|
||||
m_PrefabInternal: {fileID: 1742914067}
|
||||
m_Script: {fileID: 11500000, guid: 00f3402a2ea5bff4880c0313515240cd, type: 3}
|
||||
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: aa35ff5ba76fb384d839383c84209da9
|
||||
timeCreated: 1468000130
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
9
Assets/Oculus/Avatar/Samples/RemoteLoopback/Scripts.meta
Normal file
9
Assets/Oculus/Avatar/Samples/RemoteLoopback/Scripts.meta
Normal file
@@ -0,0 +1,9 @@
|
||||
fileFormatVersion: 2
|
||||
guid: edf34aa3892fd9f4eb0795663f7e3ffc
|
||||
folderAsset: yes
|
||||
timeCreated: 1468000607
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,155 @@
|
||||
using UnityEngine;
|
||||
using System.Collections;
|
||||
using System;
|
||||
using System.IO;
|
||||
using Oculus.Avatar;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public class RemoteLoopbackManager : MonoBehaviour
|
||||
{
|
||||
class PacketLatencyPair
|
||||
{
|
||||
public byte[] PacketData;
|
||||
public float FakeLatency;
|
||||
};
|
||||
|
||||
public OvrAvatar LocalAvatar;
|
||||
public OvrAvatar LoopbackAvatar;
|
||||
|
||||
[System.Serializable]
|
||||
public class SimulatedLatencySettings
|
||||
{
|
||||
[Range(0.0f, 0.5f)]
|
||||
public float FakeLatencyMax = 0.25f; //250 ms max latency
|
||||
|
||||
[Range(0.0f, 0.5f)]
|
||||
public float FakeLatencyMin = 0.002f; //2ms min latency
|
||||
|
||||
[Range(0.0f, 1.0f)]
|
||||
public float LatencyWeight = 0.25f; // How much the latest sample impacts the current latency
|
||||
|
||||
[Range(0,10)]
|
||||
public int MaxSamples = 4; //How many samples in our window
|
||||
|
||||
internal float AverageWindow = 0f;
|
||||
internal float LatencySum = 0f;
|
||||
internal LinkedList<float> LatencyValues = new LinkedList<float>();
|
||||
|
||||
public float NextValue()
|
||||
{
|
||||
AverageWindow = LatencySum / (float)LatencyValues.Count;
|
||||
float RandomLatency = UnityEngine.Random.Range(FakeLatencyMin, FakeLatencyMax);
|
||||
float FakeLatency = AverageWindow * (1f - LatencyWeight) + LatencyWeight * RandomLatency;
|
||||
|
||||
if (LatencyValues.Count >= MaxSamples)
|
||||
{
|
||||
LatencySum -= LatencyValues.First.Value;
|
||||
LatencyValues.RemoveFirst();
|
||||
}
|
||||
|
||||
LatencySum += FakeLatency;
|
||||
LatencyValues.AddLast(FakeLatency);
|
||||
|
||||
return FakeLatency;
|
||||
}
|
||||
};
|
||||
|
||||
public SimulatedLatencySettings LatencySettings = new SimulatedLatencySettings();
|
||||
|
||||
private int PacketSequence = 0;
|
||||
|
||||
LinkedList<PacketLatencyPair> packetQueue = new LinkedList<PacketLatencyPair>();
|
||||
|
||||
void Start()
|
||||
{
|
||||
LocalAvatar.RecordPackets = true;
|
||||
LocalAvatar.PacketRecorded += OnLocalAvatarPacketRecorded;
|
||||
float FirstValue = UnityEngine.Random.Range(LatencySettings.FakeLatencyMin, LatencySettings.FakeLatencyMax);
|
||||
LatencySettings.LatencyValues.AddFirst(FirstValue);
|
||||
LatencySettings.LatencySum += FirstValue;
|
||||
}
|
||||
|
||||
void OnLocalAvatarPacketRecorded(object sender, OvrAvatar.PacketEventArgs args)
|
||||
{
|
||||
using (MemoryStream outputStream = new MemoryStream())
|
||||
{
|
||||
BinaryWriter writer = new BinaryWriter(outputStream);
|
||||
|
||||
if (LocalAvatar.UseSDKPackets)
|
||||
{
|
||||
var size = CAPI.ovrAvatarPacket_GetSize(args.Packet.ovrNativePacket);
|
||||
byte[] data = new byte[size];
|
||||
CAPI.ovrAvatarPacket_Write(args.Packet.ovrNativePacket, size, data);
|
||||
|
||||
writer.Write(PacketSequence++);
|
||||
writer.Write(size);
|
||||
writer.Write(data);
|
||||
}
|
||||
else
|
||||
{
|
||||
writer.Write(PacketSequence++);
|
||||
args.Packet.Write(outputStream);
|
||||
}
|
||||
|
||||
SendPacketData(outputStream.ToArray());
|
||||
}
|
||||
}
|
||||
|
||||
void Update()
|
||||
{
|
||||
if (packetQueue.Count > 0)
|
||||
{
|
||||
List<PacketLatencyPair> deadList = new List<PacketLatencyPair>();
|
||||
foreach (var packet in packetQueue)
|
||||
{
|
||||
packet.FakeLatency -= Time.deltaTime;
|
||||
|
||||
if (packet.FakeLatency < 0f)
|
||||
{
|
||||
ReceivePacketData(packet.PacketData);
|
||||
deadList.Add(packet);
|
||||
}
|
||||
}
|
||||
|
||||
foreach (var packet in deadList)
|
||||
{
|
||||
packetQueue.Remove(packet);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void SendPacketData(byte[] data)
|
||||
{
|
||||
PacketLatencyPair PacketPair = new PacketLatencyPair();
|
||||
PacketPair.PacketData = data;
|
||||
PacketPair.FakeLatency = LatencySettings.NextValue();
|
||||
|
||||
packetQueue.AddLast(PacketPair);
|
||||
}
|
||||
|
||||
void ReceivePacketData(byte[] data)
|
||||
{
|
||||
using (MemoryStream inputStream = new MemoryStream(data))
|
||||
{
|
||||
BinaryReader reader = new BinaryReader(inputStream);
|
||||
int sequence = reader.ReadInt32();
|
||||
|
||||
OvrAvatarPacket avatarPacket;
|
||||
if (LoopbackAvatar.UseSDKPackets)
|
||||
{
|
||||
int size = reader.ReadInt32();
|
||||
byte[] sdkData = reader.ReadBytes(size);
|
||||
|
||||
IntPtr packet = CAPI.ovrAvatarPacket_Read((UInt32)data.Length, sdkData);
|
||||
avatarPacket = new OvrAvatarPacket { ovrNativePacket = packet };
|
||||
}
|
||||
else
|
||||
{
|
||||
avatarPacket = OvrAvatarPacket.Read(inputStream);
|
||||
}
|
||||
|
||||
LoopbackAvatar.GetComponent<OvrAvatarRemoteDriver>().QueuePacket(sequence, avatarPacket);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 1675d6690178fd0459887aed66409f70
|
||||
timeCreated: 1468000639
|
||||
licenseType: Store
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
9
Assets/Oculus/Avatar/Samples/SocialStarter.meta
Normal file
9
Assets/Oculus/Avatar/Samples/SocialStarter.meta
Normal file
@@ -0,0 +1,9 @@
|
||||
fileFormatVersion: 2
|
||||
guid: f853d92f5be267947bcbbc142982b463
|
||||
folderAsset: yes
|
||||
timeCreated: 1517509658
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
9
Assets/Oculus/Avatar/Samples/SocialStarter/Assets.meta
Normal file
9
Assets/Oculus/Avatar/Samples/SocialStarter/Assets.meta
Normal file
@@ -0,0 +1,9 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 95e9e8192781ad94bad26b153c265787
|
||||
folderAsset: yes
|
||||
timeCreated: 1517509663
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,783 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!29 &1
|
||||
OcclusionCullingSettings:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 2
|
||||
m_OcclusionBakeSettings:
|
||||
smallestOccluder: 5
|
||||
smallestHole: 0.25
|
||||
backfaceThreshold: 100
|
||||
m_SceneGUID: 00000000000000000000000000000000
|
||||
m_OcclusionCullingData: {fileID: 0}
|
||||
--- !u!104 &2
|
||||
RenderSettings:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 8
|
||||
m_Fog: 0
|
||||
m_FogColor: {r: 0.5, g: 0.5, b: 0.5, a: 1}
|
||||
m_FogMode: 3
|
||||
m_FogDensity: 0.01
|
||||
m_LinearFogStart: 0
|
||||
m_LinearFogEnd: 300
|
||||
m_AmbientSkyColor: {r: 0.212, g: 0.227, b: 0.259, a: 1}
|
||||
m_AmbientEquatorColor: {r: 0.114, g: 0.125, b: 0.133, a: 1}
|
||||
m_AmbientGroundColor: {r: 0.047, g: 0.043, b: 0.035, a: 1}
|
||||
m_AmbientIntensity: 1
|
||||
m_AmbientMode: 0
|
||||
m_SubtractiveShadowColor: {r: 0.42, g: 0.478, b: 0.627, a: 1}
|
||||
m_SkyboxMaterial: {fileID: 10304, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_HaloStrength: 0.5
|
||||
m_FlareStrength: 1
|
||||
m_FlareFadeSpeed: 3
|
||||
m_HaloTexture: {fileID: 0}
|
||||
m_SpotCookie: {fileID: 10001, guid: 0000000000000000e000000000000000, type: 0}
|
||||
m_DefaultReflectionMode: 0
|
||||
m_DefaultReflectionResolution: 128
|
||||
m_ReflectionBounces: 1
|
||||
m_ReflectionIntensity: 1
|
||||
m_CustomReflection: {fileID: 0}
|
||||
m_Sun: {fileID: 0}
|
||||
m_IndirectSpecularColor: {r: 0.44657898, g: 0.4964133, b: 0.5748178, a: 1}
|
||||
--- !u!157 &3
|
||||
LightmapSettings:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 11
|
||||
m_GIWorkflowMode: 0
|
||||
m_GISettings:
|
||||
serializedVersion: 2
|
||||
m_BounceScale: 1
|
||||
m_IndirectOutputScale: 1
|
||||
m_AlbedoBoost: 1
|
||||
m_TemporalCoherenceThreshold: 1
|
||||
m_EnvironmentLightingMode: 0
|
||||
m_EnableBakedLightmaps: 1
|
||||
m_EnableRealtimeLightmaps: 1
|
||||
m_LightmapEditorSettings:
|
||||
serializedVersion: 9
|
||||
m_Resolution: 2
|
||||
m_BakeResolution: 40
|
||||
m_TextureWidth: 1024
|
||||
m_TextureHeight: 1024
|
||||
m_AO: 0
|
||||
m_AOMaxDistance: 1
|
||||
m_CompAOExponent: 1
|
||||
m_CompAOExponentDirect: 0
|
||||
m_Padding: 2
|
||||
m_LightmapParameters: {fileID: 0}
|
||||
m_LightmapsBakeMode: 1
|
||||
m_TextureCompression: 1
|
||||
m_FinalGather: 0
|
||||
m_FinalGatherFiltering: 1
|
||||
m_FinalGatherRayCount: 256
|
||||
m_ReflectionCompression: 2
|
||||
m_MixedBakeMode: 1
|
||||
m_BakeBackend: 0
|
||||
m_PVRSampling: 1
|
||||
m_PVRDirectSampleCount: 32
|
||||
m_PVRSampleCount: 500
|
||||
m_PVRBounces: 2
|
||||
m_PVRFilterTypeDirect: 0
|
||||
m_PVRFilterTypeIndirect: 0
|
||||
m_PVRFilterTypeAO: 0
|
||||
m_PVRFilteringMode: 0
|
||||
m_PVRCulling: 1
|
||||
m_PVRFilteringGaussRadiusDirect: 1
|
||||
m_PVRFilteringGaussRadiusIndirect: 5
|
||||
m_PVRFilteringGaussRadiusAO: 2
|
||||
m_PVRFilteringAtrousPositionSigmaDirect: 0.5
|
||||
m_PVRFilteringAtrousPositionSigmaIndirect: 2
|
||||
m_PVRFilteringAtrousPositionSigmaAO: 1
|
||||
m_ShowResolutionOverlay: 1
|
||||
m_LightingDataAsset: {fileID: 0}
|
||||
m_UseShadowmask: 1
|
||||
--- !u!196 &4
|
||||
NavMeshSettings:
|
||||
serializedVersion: 2
|
||||
m_ObjectHideFlags: 0
|
||||
m_BuildSettings:
|
||||
serializedVersion: 2
|
||||
agentTypeID: 0
|
||||
agentRadius: 0.5
|
||||
agentHeight: 2
|
||||
agentSlope: 45
|
||||
agentClimb: 0.4
|
||||
ledgeDropHeight: 0
|
||||
maxJumpAcrossDistance: 0
|
||||
minRegionArea: 2
|
||||
manualCellSize: 0
|
||||
cellSize: 0.16666667
|
||||
manualTileSize: 0
|
||||
tileSize: 256
|
||||
accuratePlacement: 0
|
||||
debug:
|
||||
m_Flags: 0
|
||||
m_NavMeshData: {fileID: 0}
|
||||
--- !u!1 &8653650
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
serializedVersion: 5
|
||||
m_Component:
|
||||
- component: {fileID: 8653655}
|
||||
- component: {fileID: 8653654}
|
||||
- component: {fileID: 8653653}
|
||||
- component: {fileID: 8653652}
|
||||
- component: {fileID: 8653651}
|
||||
m_Layer: 0
|
||||
m_Name: Main Camera
|
||||
m_TagString: MainCamera
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!81 &8653651
|
||||
AudioListener:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 8653650}
|
||||
m_Enabled: 0
|
||||
--- !u!124 &8653652
|
||||
Behaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 8653650}
|
||||
m_Enabled: 1
|
||||
--- !u!92 &8653653
|
||||
Behaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 8653650}
|
||||
m_Enabled: 1
|
||||
--- !u!20 &8653654
|
||||
Camera:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 8653650}
|
||||
m_Enabled: 1
|
||||
serializedVersion: 2
|
||||
m_ClearFlags: 1
|
||||
m_BackGroundColor: {r: 0.19215687, g: 0.3019608, b: 0.4745098, a: 0}
|
||||
m_NormalizedViewPortRect:
|
||||
serializedVersion: 2
|
||||
x: 0
|
||||
y: 0
|
||||
width: 1
|
||||
height: 1
|
||||
near clip plane: 0.3
|
||||
far clip plane: 1000
|
||||
field of view: 60
|
||||
orthographic: 0
|
||||
orthographic size: 5
|
||||
m_Depth: -1
|
||||
m_CullingMask:
|
||||
serializedVersion: 2
|
||||
m_Bits: 4294967295
|
||||
m_RenderingPath: -1
|
||||
m_TargetTexture: {fileID: 0}
|
||||
m_TargetDisplay: 0
|
||||
m_TargetEye: 3
|
||||
m_HDR: 0
|
||||
m_AllowMSAA: 1
|
||||
m_AllowDynamicResolution: 0
|
||||
m_ForceIntoRT: 0
|
||||
m_OcclusionCulling: 1
|
||||
m_StereoConvergence: 10
|
||||
m_StereoSeparation: 0.022
|
||||
--- !u!4 &8653655
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 8653650}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 1, z: -10}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!1 &206856059
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
serializedVersion: 5
|
||||
m_Component:
|
||||
- component: {fileID: 206856064}
|
||||
- component: {fileID: 206856063}
|
||||
- component: {fileID: 206856062}
|
||||
- component: {fileID: 206856061}
|
||||
- component: {fileID: 206856060}
|
||||
m_Layer: 0
|
||||
m_Name: RoomCamera
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!81 &206856060
|
||||
AudioListener:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 206856059}
|
||||
m_Enabled: 0
|
||||
--- !u!92 &206856061
|
||||
Behaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 206856059}
|
||||
m_Enabled: 1
|
||||
--- !u!124 &206856062
|
||||
Behaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 206856059}
|
||||
m_Enabled: 1
|
||||
--- !u!20 &206856063
|
||||
Camera:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 206856059}
|
||||
m_Enabled: 1
|
||||
serializedVersion: 2
|
||||
m_ClearFlags: 1
|
||||
m_BackGroundColor: {r: 0.19215687, g: 0.3019608, b: 0.4745098, a: 0}
|
||||
m_NormalizedViewPortRect:
|
||||
serializedVersion: 2
|
||||
x: 0
|
||||
y: 0
|
||||
width: 1
|
||||
height: 1
|
||||
near clip plane: 0.3
|
||||
far clip plane: 1000
|
||||
field of view: 60
|
||||
orthographic: 0
|
||||
orthographic size: 5
|
||||
m_Depth: 0
|
||||
m_CullingMask:
|
||||
serializedVersion: 2
|
||||
m_Bits: 4294967295
|
||||
m_RenderingPath: -1
|
||||
m_TargetTexture: {fileID: 0}
|
||||
m_TargetDisplay: 0
|
||||
m_TargetEye: 3
|
||||
m_HDR: 0
|
||||
m_AllowMSAA: 1
|
||||
m_AllowDynamicResolution: 0
|
||||
m_ForceIntoRT: 0
|
||||
m_OcclusionCulling: 1
|
||||
m_StereoConvergence: 10
|
||||
m_StereoSeparation: 0.022
|
||||
--- !u!4 &206856064
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 206856059}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 3, z: -9.5}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 5
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!1 &780482174
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
serializedVersion: 5
|
||||
m_Component:
|
||||
- component: {fileID: 780482176}
|
||||
- component: {fileID: 780482175}
|
||||
m_Layer: 0
|
||||
m_Name: Directional Light
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!108 &780482175
|
||||
Light:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 780482174}
|
||||
m_Enabled: 1
|
||||
serializedVersion: 8
|
||||
m_Type: 1
|
||||
m_Color: {r: 1, g: 0.95686275, b: 0.8392157, a: 1}
|
||||
m_Intensity: 1
|
||||
m_Range: 10
|
||||
m_SpotAngle: 30
|
||||
m_CookieSize: 10
|
||||
m_Shadows:
|
||||
m_Type: 2
|
||||
m_Resolution: -1
|
||||
m_CustomResolution: -1
|
||||
m_Strength: 1
|
||||
m_Bias: 0.05
|
||||
m_NormalBias: 0.4
|
||||
m_NearPlane: 0.2
|
||||
m_Cookie: {fileID: 0}
|
||||
m_DrawHalo: 0
|
||||
m_Flare: {fileID: 0}
|
||||
m_RenderMode: 0
|
||||
m_CullingMask:
|
||||
serializedVersion: 2
|
||||
m_Bits: 4294967295
|
||||
m_Lightmapping: 4
|
||||
m_AreaSize: {x: 1, y: 1}
|
||||
m_BounceIntensity: 1
|
||||
m_ColorTemperature: 6570
|
||||
m_UseColorTemperature: 0
|
||||
m_ShadowRadius: 0
|
||||
m_ShadowAngle: 0
|
||||
--- !u!4 &780482176
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 780482174}
|
||||
m_LocalRotation: {x: 0.40821788, y: -0.23456968, z: 0.10938163, w: 0.8754261}
|
||||
m_LocalPosition: {x: 0, y: 3, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 1
|
||||
m_LocalEulerAnglesHint: {x: 50, y: -30, z: 0}
|
||||
--- !u!1 &840719025
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
serializedVersion: 5
|
||||
m_Component:
|
||||
- component: {fileID: 840719029}
|
||||
- component: {fileID: 840719028}
|
||||
- component: {fileID: 840719027}
|
||||
- component: {fileID: 840719026}
|
||||
m_Layer: 0
|
||||
m_Name: HelpPanel
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!23 &840719026
|
||||
MeshRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 840719025}
|
||||
m_Enabled: 1
|
||||
m_CastShadows: 1
|
||||
m_ReceiveShadows: 1
|
||||
m_DynamicOccludee: 1
|
||||
m_MotionVectors: 1
|
||||
m_LightProbeUsage: 1
|
||||
m_ReflectionProbeUsage: 1
|
||||
m_Materials:
|
||||
- {fileID: 2100000, guid: 4c18da23435024b43a2b78449cbb6ed0, type: 2}
|
||||
m_StaticBatchInfo:
|
||||
firstSubMesh: 0
|
||||
subMeshCount: 0
|
||||
m_StaticBatchRoot: {fileID: 0}
|
||||
m_ProbeAnchor: {fileID: 0}
|
||||
m_LightProbeVolumeOverride: {fileID: 0}
|
||||
m_ScaleInLightmap: 1
|
||||
m_PreserveUVs: 1
|
||||
m_IgnoreNormalsForChartDetection: 0
|
||||
m_ImportantGI: 0
|
||||
m_StitchLightmapSeams: 0
|
||||
m_SelectedEditorRenderState: 3
|
||||
m_MinimumChartSize: 4
|
||||
m_AutoUVMaxDistance: 0.5
|
||||
m_AutoUVMaxAngle: 89
|
||||
m_LightmapParameters: {fileID: 0}
|
||||
m_SortingLayerID: 0
|
||||
m_SortingLayer: 0
|
||||
m_SortingOrder: 0
|
||||
--- !u!64 &840719027
|
||||
MeshCollider:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 840719025}
|
||||
m_Material: {fileID: 0}
|
||||
m_IsTrigger: 0
|
||||
m_Enabled: 1
|
||||
serializedVersion: 3
|
||||
m_Convex: 0
|
||||
m_CookingOptions: 14
|
||||
m_SkinWidth: 0.01
|
||||
m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0}
|
||||
--- !u!33 &840719028
|
||||
MeshFilter:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 840719025}
|
||||
m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0}
|
||||
--- !u!4 &840719029
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 840719025}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0.52, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 6
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!1001 &1390249324
|
||||
Prefab:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 2
|
||||
m_Modification:
|
||||
m_TransformParent: {fileID: 0}
|
||||
m_Modifications:
|
||||
- target: {fileID: 400006, guid: ce816f2e6abb0504092c23ed9b970dfd, type: 2}
|
||||
propertyPath: m_LocalPosition.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400006, guid: ce816f2e6abb0504092c23ed9b970dfd, type: 2}
|
||||
propertyPath: m_LocalPosition.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400006, guid: ce816f2e6abb0504092c23ed9b970dfd, type: 2}
|
||||
propertyPath: m_LocalPosition.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400006, guid: ce816f2e6abb0504092c23ed9b970dfd, type: 2}
|
||||
propertyPath: m_LocalRotation.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400006, guid: ce816f2e6abb0504092c23ed9b970dfd, type: 2}
|
||||
propertyPath: m_LocalRotation.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400006, guid: ce816f2e6abb0504092c23ed9b970dfd, type: 2}
|
||||
propertyPath: m_LocalRotation.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400006, guid: ce816f2e6abb0504092c23ed9b970dfd, type: 2}
|
||||
propertyPath: m_LocalRotation.w
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 400006, guid: ce816f2e6abb0504092c23ed9b970dfd, type: 2}
|
||||
propertyPath: m_RootOrder
|
||||
value: 2
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 100014, guid: ce816f2e6abb0504092c23ed9b970dfd, type: 2}
|
||||
propertyPath: m_TagString
|
||||
value: MainCamera
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 100010, guid: ce816f2e6abb0504092c23ed9b970dfd, type: 2}
|
||||
propertyPath: m_TagString
|
||||
value: MainCamera
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 11400002, guid: ce816f2e6abb0504092c23ed9b970dfd, type: 2}
|
||||
propertyPath: _trackingOriginType
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 100008, guid: ce816f2e6abb0504092c23ed9b970dfd, type: 2}
|
||||
propertyPath: m_IsActive
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 11400010, guid: ce816f2e6abb0504092c23ed9b970dfd, type: 2}
|
||||
propertyPath: SnapRotation
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 11400010, guid: ce816f2e6abb0504092c23ed9b970dfd, type: 2}
|
||||
propertyPath: EnableRotation
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
m_RemovedComponents: []
|
||||
m_ParentPrefab: {fileID: 100100000, guid: ce816f2e6abb0504092c23ed9b970dfd, type: 2}
|
||||
m_IsPrefabParent: 0
|
||||
--- !u!1 &1390249325 stripped
|
||||
GameObject:
|
||||
m_PrefabParentObject: {fileID: 100014, guid: ce816f2e6abb0504092c23ed9b970dfd, type: 2}
|
||||
m_PrefabInternal: {fileID: 1390249324}
|
||||
--- !u!1 &1390249326 stripped
|
||||
GameObject:
|
||||
m_PrefabParentObject: {fileID: 100010, guid: ce816f2e6abb0504092c23ed9b970dfd, type: 2}
|
||||
m_PrefabInternal: {fileID: 1390249324}
|
||||
--- !u!20 &1390249327
|
||||
Camera:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1390249325}
|
||||
m_Enabled: 0
|
||||
serializedVersion: 2
|
||||
m_ClearFlags: 1
|
||||
m_BackGroundColor: {r: 0.19215687, g: 0.3019608, b: 0.4745098, a: 0}
|
||||
m_NormalizedViewPortRect:
|
||||
serializedVersion: 2
|
||||
x: 0
|
||||
y: 0
|
||||
width: 1
|
||||
height: 1
|
||||
near clip plane: 0.3
|
||||
far clip plane: 1000
|
||||
field of view: 60
|
||||
orthographic: 0
|
||||
orthographic size: 5
|
||||
m_Depth: 0
|
||||
m_CullingMask:
|
||||
serializedVersion: 2
|
||||
m_Bits: 4294967295
|
||||
m_RenderingPath: -1
|
||||
m_TargetTexture: {fileID: 0}
|
||||
m_TargetDisplay: 0
|
||||
m_TargetEye: 2
|
||||
m_HDR: 0
|
||||
m_AllowMSAA: 1
|
||||
m_AllowDynamicResolution: 0
|
||||
m_ForceIntoRT: 0
|
||||
m_OcclusionCulling: 1
|
||||
m_StereoConvergence: 10
|
||||
m_StereoSeparation: 0.022
|
||||
--- !u!20 &1390249328
|
||||
Camera:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1390249326}
|
||||
m_Enabled: 0
|
||||
serializedVersion: 2
|
||||
m_ClearFlags: 1
|
||||
m_BackGroundColor: {r: 0.19215687, g: 0.3019608, b: 0.4745098, a: 0}
|
||||
m_NormalizedViewPortRect:
|
||||
serializedVersion: 2
|
||||
x: 0
|
||||
y: 0
|
||||
width: 1
|
||||
height: 1
|
||||
near clip plane: 0.3
|
||||
far clip plane: 1000
|
||||
field of view: 60
|
||||
orthographic: 0
|
||||
orthographic size: 5
|
||||
m_Depth: 0
|
||||
m_CullingMask:
|
||||
serializedVersion: 2
|
||||
m_Bits: 4294967295
|
||||
m_RenderingPath: -1
|
||||
m_TargetTexture: {fileID: 0}
|
||||
m_TargetDisplay: 0
|
||||
m_TargetEye: 1
|
||||
m_HDR: 0
|
||||
m_AllowMSAA: 1
|
||||
m_AllowDynamicResolution: 0
|
||||
m_ForceIntoRT: 0
|
||||
m_OcclusionCulling: 1
|
||||
m_StereoConvergence: 10
|
||||
m_StereoSeparation: 0.022
|
||||
--- !u!1 &1390249329 stripped
|
||||
GameObject:
|
||||
m_PrefabParentObject: {fileID: 100008, guid: ce816f2e6abb0504092c23ed9b970dfd, type: 2}
|
||||
m_PrefabInternal: {fileID: 1390249324}
|
||||
--- !u!114 &1390249330
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1390249329}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 043fbfd0ae7027742bace7a3691feb13, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
localAvatarPrefab: {fileID: 11437430, guid: 84c8b8609f9bb434eaf5248f17ff1293, type: 2}
|
||||
remoteAvatarPrefab: {fileID: 11464902, guid: 90bf33f968e6bb44ea0208fc82c90a44, type: 2}
|
||||
helpPanel: {fileID: 840719025}
|
||||
riftMaterial: {fileID: 2100000, guid: 4c18da23435024b43a2b78449cbb6ed0, type: 2}
|
||||
gearMaterial: {fileID: 2100000, guid: 09c03a3c5049d234590b91bbc6e84462, type: 2}
|
||||
roomSphere: {fileID: 1902705651}
|
||||
roomFloor: {fileID: 2115777246}
|
||||
spyCamera: {fileID: 206856063}
|
||||
--- !u!1 &1902705651
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
serializedVersion: 5
|
||||
m_Component:
|
||||
- component: {fileID: 1902705655}
|
||||
- component: {fileID: 1902705654}
|
||||
- component: {fileID: 1902705653}
|
||||
- component: {fileID: 1902705652}
|
||||
m_Layer: 0
|
||||
m_Name: Sphere
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!23 &1902705652
|
||||
MeshRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1902705651}
|
||||
m_Enabled: 1
|
||||
m_CastShadows: 1
|
||||
m_ReceiveShadows: 1
|
||||
m_DynamicOccludee: 1
|
||||
m_MotionVectors: 1
|
||||
m_LightProbeUsage: 1
|
||||
m_ReflectionProbeUsage: 1
|
||||
m_Materials:
|
||||
- {fileID: 2100000, guid: 296de5be1228bf34380061dd6e6b0f49, type: 2}
|
||||
m_StaticBatchInfo:
|
||||
firstSubMesh: 0
|
||||
subMeshCount: 0
|
||||
m_StaticBatchRoot: {fileID: 0}
|
||||
m_ProbeAnchor: {fileID: 0}
|
||||
m_LightProbeVolumeOverride: {fileID: 0}
|
||||
m_ScaleInLightmap: 1
|
||||
m_PreserveUVs: 1
|
||||
m_IgnoreNormalsForChartDetection: 0
|
||||
m_ImportantGI: 0
|
||||
m_StitchLightmapSeams: 0
|
||||
m_SelectedEditorRenderState: 3
|
||||
m_MinimumChartSize: 4
|
||||
m_AutoUVMaxDistance: 0.5
|
||||
m_AutoUVMaxAngle: 89
|
||||
m_LightmapParameters: {fileID: 0}
|
||||
m_SortingLayerID: 0
|
||||
m_SortingLayer: 0
|
||||
m_SortingOrder: 0
|
||||
--- !u!135 &1902705653
|
||||
SphereCollider:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1902705651}
|
||||
m_Material: {fileID: 0}
|
||||
m_IsTrigger: 0
|
||||
m_Enabled: 1
|
||||
serializedVersion: 2
|
||||
m_Radius: 0.5
|
||||
m_Center: {x: 0, y: 0, z: 0}
|
||||
--- !u!33 &1902705654
|
||||
MeshFilter:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1902705651}
|
||||
m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0}
|
||||
--- !u!4 &1902705655
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1902705651}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 3, y: 6, z: 3}
|
||||
m_LocalScale: {x: 2, y: 2, z: 2}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 4
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!1 &2115777246
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
serializedVersion: 5
|
||||
m_Component:
|
||||
- component: {fileID: 2115777250}
|
||||
- component: {fileID: 2115777249}
|
||||
- component: {fileID: 2115777248}
|
||||
- component: {fileID: 2115777247}
|
||||
m_Layer: 0
|
||||
m_Name: Plane
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!23 &2115777247
|
||||
MeshRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 2115777246}
|
||||
m_Enabled: 1
|
||||
m_CastShadows: 1
|
||||
m_ReceiveShadows: 1
|
||||
m_DynamicOccludee: 1
|
||||
m_MotionVectors: 1
|
||||
m_LightProbeUsage: 1
|
||||
m_ReflectionProbeUsage: 1
|
||||
m_Materials:
|
||||
- {fileID: 2100000, guid: c466b89bb972b8a42bd266c102f8f2cb, type: 2}
|
||||
m_StaticBatchInfo:
|
||||
firstSubMesh: 0
|
||||
subMeshCount: 0
|
||||
m_StaticBatchRoot: {fileID: 0}
|
||||
m_ProbeAnchor: {fileID: 0}
|
||||
m_LightProbeVolumeOverride: {fileID: 0}
|
||||
m_ScaleInLightmap: 1
|
||||
m_PreserveUVs: 1
|
||||
m_IgnoreNormalsForChartDetection: 0
|
||||
m_ImportantGI: 0
|
||||
m_StitchLightmapSeams: 0
|
||||
m_SelectedEditorRenderState: 3
|
||||
m_MinimumChartSize: 4
|
||||
m_AutoUVMaxDistance: 0.5
|
||||
m_AutoUVMaxAngle: 89
|
||||
m_LightmapParameters: {fileID: 0}
|
||||
m_SortingLayerID: 0
|
||||
m_SortingLayer: 0
|
||||
m_SortingOrder: 0
|
||||
--- !u!64 &2115777248
|
||||
MeshCollider:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 2115777246}
|
||||
m_Material: {fileID: 0}
|
||||
m_IsTrigger: 0
|
||||
m_Enabled: 1
|
||||
serializedVersion: 3
|
||||
m_Convex: 0
|
||||
m_CookingOptions: 14
|
||||
m_SkinWidth: 0.01
|
||||
m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0}
|
||||
--- !u!33 &2115777249
|
||||
MeshFilter:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 2115777246}
|
||||
m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0}
|
||||
--- !u!4 &2115777250
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 2115777246}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 7, y: 1, z: 7}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 3
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 236a5f96528802e47a70d6e47ebd3c16
|
||||
timeCreated: 1496779803
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,9 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 777b874d432a52044991fe1a0210200c
|
||||
folderAsset: yes
|
||||
timeCreated: 1496779985
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,127 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!21 &2100000
|
||||
Material:
|
||||
serializedVersion: 6
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_Name: GearHelp
|
||||
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_ShaderKeywords:
|
||||
m_LightmapFlags: 5
|
||||
m_CustomRenderQueue: -1
|
||||
stringTagMap: {}
|
||||
m_SavedProperties:
|
||||
serializedVersion: 2
|
||||
m_TexEnvs:
|
||||
- first:
|
||||
name: _BumpMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _DetailAlbedoMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _DetailMask
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _DetailNormalMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _EmissionMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _MainTex
|
||||
second:
|
||||
m_Texture: {fileID: 2800000, guid: 0453138effcc80349b11371805f72f5b, type: 3}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _MetallicGlossMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _OcclusionMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _ParallaxMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
m_Floats:
|
||||
- first:
|
||||
name: _BumpScale
|
||||
second: 1
|
||||
- first:
|
||||
name: _Cutoff
|
||||
second: 0.5
|
||||
- first:
|
||||
name: _DetailNormalMapScale
|
||||
second: 1
|
||||
- first:
|
||||
name: _DstBlend
|
||||
second: 0
|
||||
- first:
|
||||
name: _GlossMapScale
|
||||
second: 1
|
||||
- first:
|
||||
name: _Glossiness
|
||||
second: 0.5
|
||||
- first:
|
||||
name: _GlossyReflections
|
||||
second: 1
|
||||
- first:
|
||||
name: _Metallic
|
||||
second: 0
|
||||
- first:
|
||||
name: _Mode
|
||||
second: 0
|
||||
- first:
|
||||
name: _OcclusionStrength
|
||||
second: 1
|
||||
- first:
|
||||
name: _Parallax
|
||||
second: 0.02
|
||||
- first:
|
||||
name: _SmoothnessTextureChannel
|
||||
second: 0
|
||||
- first:
|
||||
name: _SpecularHighlights
|
||||
second: 1
|
||||
- first:
|
||||
name: _SrcBlend
|
||||
second: 1
|
||||
- first:
|
||||
name: _UVSec
|
||||
second: 0
|
||||
- first:
|
||||
name: _ZWrite
|
||||
second: 1
|
||||
m_Colors:
|
||||
- first:
|
||||
name: _Color
|
||||
second: {r: 1, g: 1, b: 1, a: 1}
|
||||
- first:
|
||||
name: _EmissionColor
|
||||
second: {r: 0, g: 0, b: 0, a: 1}
|
||||
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 09c03a3c5049d234590b91bbc6e84462
|
||||
timeCreated: 1497549036
|
||||
licenseType: Store
|
||||
NativeFormatImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,127 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!21 &2100000
|
||||
Material:
|
||||
serializedVersion: 6
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_Name: Help
|
||||
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_ShaderKeywords:
|
||||
m_LightmapFlags: 5
|
||||
m_CustomRenderQueue: -1
|
||||
stringTagMap: {}
|
||||
m_SavedProperties:
|
||||
serializedVersion: 2
|
||||
m_TexEnvs:
|
||||
- first:
|
||||
name: _BumpMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _DetailAlbedoMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _DetailMask
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _DetailNormalMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _EmissionMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _MainTex
|
||||
second:
|
||||
m_Texture: {fileID: 2800000, guid: c8f5462cc092d0c40ad71773132863e0, type: 3}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _MetallicGlossMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _OcclusionMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _ParallaxMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
m_Floats:
|
||||
- first:
|
||||
name: _BumpScale
|
||||
second: 1
|
||||
- first:
|
||||
name: _Cutoff
|
||||
second: 0.5
|
||||
- first:
|
||||
name: _DetailNormalMapScale
|
||||
second: 1
|
||||
- first:
|
||||
name: _DstBlend
|
||||
second: 0
|
||||
- first:
|
||||
name: _GlossMapScale
|
||||
second: 1
|
||||
- first:
|
||||
name: _Glossiness
|
||||
second: 0.5
|
||||
- first:
|
||||
name: _GlossyReflections
|
||||
second: 1
|
||||
- first:
|
||||
name: _Metallic
|
||||
second: 0
|
||||
- first:
|
||||
name: _Mode
|
||||
second: 0
|
||||
- first:
|
||||
name: _OcclusionStrength
|
||||
second: 1
|
||||
- first:
|
||||
name: _Parallax
|
||||
second: 0.02
|
||||
- first:
|
||||
name: _SmoothnessTextureChannel
|
||||
second: 0
|
||||
- first:
|
||||
name: _SpecularHighlights
|
||||
second: 1
|
||||
- first:
|
||||
name: _SrcBlend
|
||||
second: 1
|
||||
- first:
|
||||
name: _UVSec
|
||||
second: 0
|
||||
- first:
|
||||
name: _ZWrite
|
||||
second: 1
|
||||
m_Colors:
|
||||
- first:
|
||||
name: _Color
|
||||
second: {r: 1, g: 1, b: 1, a: 1}
|
||||
- first:
|
||||
name: _EmissionColor
|
||||
second: {r: 0, g: 0, b: 0, a: 1}
|
||||
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 4c18da23435024b43a2b78449cbb6ed0
|
||||
timeCreated: 1496780065
|
||||
licenseType: Store
|
||||
NativeFormatImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,127 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!21 &2100000
|
||||
Material:
|
||||
serializedVersion: 6
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_Name: Offline_Mat
|
||||
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_ShaderKeywords: _EMISSION
|
||||
m_LightmapFlags: 1
|
||||
m_CustomRenderQueue: -1
|
||||
stringTagMap: {}
|
||||
m_SavedProperties:
|
||||
serializedVersion: 2
|
||||
m_TexEnvs:
|
||||
- first:
|
||||
name: _BumpMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _DetailAlbedoMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _DetailMask
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _DetailNormalMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _EmissionMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _MainTex
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _MetallicGlossMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _OcclusionMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _ParallaxMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
m_Floats:
|
||||
- first:
|
||||
name: _BumpScale
|
||||
second: 1
|
||||
- first:
|
||||
name: _Cutoff
|
||||
second: 0.5
|
||||
- first:
|
||||
name: _DetailNormalMapScale
|
||||
second: 1
|
||||
- first:
|
||||
name: _DstBlend
|
||||
second: 0
|
||||
- first:
|
||||
name: _GlossMapScale
|
||||
second: 1
|
||||
- first:
|
||||
name: _Glossiness
|
||||
second: 0.5
|
||||
- first:
|
||||
name: _GlossyReflections
|
||||
second: 1
|
||||
- first:
|
||||
name: _Metallic
|
||||
second: 0
|
||||
- first:
|
||||
name: _Mode
|
||||
second: 0
|
||||
- first:
|
||||
name: _OcclusionStrength
|
||||
second: 1
|
||||
- first:
|
||||
name: _Parallax
|
||||
second: 0.02
|
||||
- first:
|
||||
name: _SmoothnessTextureChannel
|
||||
second: 0
|
||||
- first:
|
||||
name: _SpecularHighlights
|
||||
second: 1
|
||||
- first:
|
||||
name: _SrcBlend
|
||||
second: 1
|
||||
- first:
|
||||
name: _UVSec
|
||||
second: 0
|
||||
- first:
|
||||
name: _ZWrite
|
||||
second: 1
|
||||
m_Colors:
|
||||
- first:
|
||||
name: _Color
|
||||
second: {r: 0, g: 0, b: 0, a: 1}
|
||||
- first:
|
||||
name: _EmissionColor
|
||||
second: {r: 0, g: 0, b: 0, a: 1}
|
||||
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 296de5be1228bf34380061dd6e6b0f49
|
||||
timeCreated: 1496780100
|
||||
licenseType: Store
|
||||
NativeFormatImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,127 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!21 &2100000
|
||||
Material:
|
||||
serializedVersion: 6
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_Name: Plane_Mat
|
||||
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_ShaderKeywords: _EMISSION
|
||||
m_LightmapFlags: 1
|
||||
m_CustomRenderQueue: -1
|
||||
stringTagMap: {}
|
||||
m_SavedProperties:
|
||||
serializedVersion: 2
|
||||
m_TexEnvs:
|
||||
- first:
|
||||
name: _BumpMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _DetailAlbedoMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _DetailMask
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _DetailNormalMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _EmissionMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _MainTex
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _MetallicGlossMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _OcclusionMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- first:
|
||||
name: _ParallaxMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
m_Floats:
|
||||
- first:
|
||||
name: _BumpScale
|
||||
second: 1
|
||||
- first:
|
||||
name: _Cutoff
|
||||
second: 0.5
|
||||
- first:
|
||||
name: _DetailNormalMapScale
|
||||
second: 1
|
||||
- first:
|
||||
name: _DstBlend
|
||||
second: 0
|
||||
- first:
|
||||
name: _GlossMapScale
|
||||
second: 1
|
||||
- first:
|
||||
name: _Glossiness
|
||||
second: 0.5
|
||||
- first:
|
||||
name: _GlossyReflections
|
||||
second: 1
|
||||
- first:
|
||||
name: _Metallic
|
||||
second: 0
|
||||
- first:
|
||||
name: _Mode
|
||||
second: 0
|
||||
- first:
|
||||
name: _OcclusionStrength
|
||||
second: 1
|
||||
- first:
|
||||
name: _Parallax
|
||||
second: 0.02
|
||||
- first:
|
||||
name: _SmoothnessTextureChannel
|
||||
second: 0
|
||||
- first:
|
||||
name: _SpecularHighlights
|
||||
second: 1
|
||||
- first:
|
||||
name: _SrcBlend
|
||||
second: 1
|
||||
- first:
|
||||
name: _UVSec
|
||||
second: 0
|
||||
- first:
|
||||
name: _ZWrite
|
||||
second: 1
|
||||
m_Colors:
|
||||
- first:
|
||||
name: _Color
|
||||
second: {r: 0, g: 0.25517225, b: 1, a: 1}
|
||||
- first:
|
||||
name: _EmissionColor
|
||||
second: {r: 0, g: 0, b: 0, a: 1}
|
||||
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: c466b89bb972b8a42bd266c102f8f2cb
|
||||
timeCreated: 1496780131
|
||||
licenseType: Store
|
||||
NativeFormatImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,9 @@
|
||||
fileFormatVersion: 2
|
||||
guid: f05e47c366870a44ab2b3b5a8a64e107
|
||||
folderAsset: yes
|
||||
timeCreated: 1496780004
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,232 @@
|
||||
using UnityEngine;
|
||||
using System;
|
||||
using Oculus.Platform;
|
||||
using Oculus.Platform.Models;
|
||||
|
||||
// Helper class to manage a Peer-to-Peer connection to the other user.
|
||||
// The connection is used to send and received the Transforms for the
|
||||
// Avatars. The Transforms are sent via unreliable UDP at a fixed
|
||||
// frequency.
|
||||
public class P2PManager
|
||||
{
|
||||
// packet header is a message type byte
|
||||
private enum MessageType : byte
|
||||
{
|
||||
Update = 1,
|
||||
};
|
||||
|
||||
public P2PManager()
|
||||
{
|
||||
Net.SetPeerConnectRequestCallback(PeerConnectRequestCallback);
|
||||
Net.SetConnectionStateChangedCallback(ConnectionStateChangedCallback);
|
||||
}
|
||||
|
||||
#region Connection Management
|
||||
|
||||
public void ConnectTo(ulong userID)
|
||||
{
|
||||
// ID comparison is used to decide who calls Connect and who calls Accept
|
||||
if (SocialPlatformManager.MyID < userID)
|
||||
{
|
||||
Net.Connect(userID);
|
||||
SocialPlatformManager.LogOutput("P2P connect to " + userID);
|
||||
}
|
||||
}
|
||||
|
||||
public void Disconnect(ulong userID)
|
||||
{
|
||||
if (userID != 0)
|
||||
{
|
||||
Net.Close(userID);
|
||||
|
||||
RemotePlayer remote = SocialPlatformManager.GetRemoteUser(userID);
|
||||
if (remote != null)
|
||||
{
|
||||
remote.p2pConnectionState = PeerConnectionState.Unknown;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void PeerConnectRequestCallback(Message<NetworkingPeer> msg)
|
||||
{
|
||||
SocialPlatformManager.LogOutput("P2P request from " + msg.Data.ID);
|
||||
|
||||
RemotePlayer remote = SocialPlatformManager.GetRemoteUser(msg.Data.ID);
|
||||
if (remote != null)
|
||||
{
|
||||
SocialPlatformManager.LogOutput("P2P request accepted from " + msg.Data.ID);
|
||||
Net.Accept(msg.Data.ID);
|
||||
}
|
||||
}
|
||||
|
||||
void ConnectionStateChangedCallback(Message<NetworkingPeer> msg)
|
||||
{
|
||||
SocialPlatformManager.LogOutput("P2P state to " + msg.Data.ID + " changed to " + msg.Data.State);
|
||||
|
||||
RemotePlayer remote = SocialPlatformManager.GetRemoteUser(msg.Data.ID);
|
||||
if (remote != null)
|
||||
{
|
||||
remote.p2pConnectionState = msg.Data.State;
|
||||
|
||||
if (msg.Data.State == PeerConnectionState.Timeout &&
|
||||
// ID comparison is used to decide who calls Connect and who calls Accept
|
||||
SocialPlatformManager.MyID < msg.Data.ID)
|
||||
{
|
||||
// keep trying until hangup!
|
||||
Net.Connect(msg.Data.ID);
|
||||
SocialPlatformManager.LogOutput("P2P re-connect to " + msg.Data.ID);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Message Sending
|
||||
|
||||
public void SendAvatarUpdate(ulong userID, Transform rootTransform, UInt32 sequence, byte[] avatarPacket)
|
||||
{
|
||||
const int UPDATE_DATA_LENGTH = 41;
|
||||
byte[] sendBuffer = new byte[avatarPacket.Length + UPDATE_DATA_LENGTH];
|
||||
|
||||
int offset = 0;
|
||||
PackByte((byte)MessageType.Update, sendBuffer, ref offset);
|
||||
|
||||
PackULong(SocialPlatformManager.MyID, sendBuffer, ref offset);
|
||||
|
||||
PackFloat(rootTransform.position.x, sendBuffer, ref offset);
|
||||
// Lock to floor height
|
||||
PackFloat(0f, sendBuffer, ref offset);
|
||||
PackFloat(rootTransform.position.z, sendBuffer, ref offset);
|
||||
PackFloat(rootTransform.rotation.x, sendBuffer, ref offset);
|
||||
PackFloat(rootTransform.rotation.y, sendBuffer, ref offset);
|
||||
PackFloat(rootTransform.rotation.z, sendBuffer, ref offset);
|
||||
PackFloat(rootTransform.rotation.w, sendBuffer, ref offset);
|
||||
|
||||
PackUInt32(sequence, sendBuffer, ref offset);
|
||||
|
||||
Debug.Assert(offset == UPDATE_DATA_LENGTH);
|
||||
|
||||
Buffer.BlockCopy(avatarPacket, 0, sendBuffer, offset, avatarPacket.Length);
|
||||
Net.SendPacket(userID, sendBuffer, SendPolicy.Unreliable);
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region Message Receiving
|
||||
|
||||
public void GetRemotePackets()
|
||||
{
|
||||
Packet packet;
|
||||
|
||||
while ((packet = Net.ReadPacket()) != null)
|
||||
{
|
||||
byte[] receiveBuffer = new byte[packet.Size];
|
||||
packet.ReadBytes(receiveBuffer);
|
||||
|
||||
int offset = 0;
|
||||
MessageType messageType = (MessageType)ReadByte(receiveBuffer, ref offset);
|
||||
|
||||
ulong remoteUserID = ReadULong(receiveBuffer, ref offset);
|
||||
RemotePlayer remote = SocialPlatformManager.GetRemoteUser(remoteUserID);
|
||||
if (remote == null)
|
||||
{
|
||||
SocialPlatformManager.LogOutput("Unknown remote player: " + remoteUserID);
|
||||
continue;
|
||||
}
|
||||
|
||||
if (messageType == MessageType.Update)
|
||||
{
|
||||
processAvatarPacket(remote, ref receiveBuffer, ref offset);
|
||||
}
|
||||
else
|
||||
{
|
||||
SocialPlatformManager.LogOutput("Invalid packet type: " + packet.Size);
|
||||
continue;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public void processAvatarPacket(RemotePlayer remote, ref byte[] packet, ref int offset)
|
||||
{
|
||||
if (remote == null)
|
||||
return;
|
||||
|
||||
remote.receivedRootPositionPrior = remote.receivedRootPosition;
|
||||
remote.receivedRootPosition.x = ReadFloat(packet, ref offset);
|
||||
remote.receivedRootPosition.y = ReadFloat(packet, ref offset);
|
||||
remote.receivedRootPosition.z = ReadFloat(packet, ref offset);
|
||||
|
||||
remote.receivedRootRotationPrior = remote.receivedRootRotation;
|
||||
remote.receivedRootRotation.x = ReadFloat(packet, ref offset);
|
||||
remote.receivedRootRotation.y = ReadFloat(packet, ref offset);
|
||||
remote.receivedRootRotation.z = ReadFloat(packet, ref offset);
|
||||
remote.receivedRootRotation.w = ReadFloat(packet, ref offset);
|
||||
|
||||
remote.RemoteAvatar.transform.position = remote.receivedRootPosition;
|
||||
remote.RemoteAvatar.transform.rotation = remote.receivedRootRotation;
|
||||
|
||||
// forward the remaining data to the avatar system
|
||||
int sequence = (int)ReadUInt32(packet, ref offset);
|
||||
|
||||
byte[] remainingAvatarBuffer = new byte[packet.Length - offset];
|
||||
Buffer.BlockCopy(packet, offset, remainingAvatarBuffer, 0, remainingAvatarBuffer.Length);
|
||||
|
||||
IntPtr avatarPacket = Oculus.Avatar.CAPI.ovrAvatarPacket_Read((UInt32)remainingAvatarBuffer.Length, remainingAvatarBuffer);
|
||||
|
||||
var ovravatarPacket = new OvrAvatarPacket { ovrNativePacket = avatarPacket };
|
||||
remote.RemoteAvatar.GetComponent<OvrAvatarRemoteDriver>().QueuePacket(sequence, ovravatarPacket);
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region Serialization
|
||||
|
||||
void PackByte(byte b, byte[] buf, ref int offset)
|
||||
{
|
||||
buf[offset] = b;
|
||||
offset += sizeof(byte);
|
||||
}
|
||||
byte ReadByte(byte[] buf, ref int offset)
|
||||
{
|
||||
byte val = buf[offset];
|
||||
offset += sizeof(byte);
|
||||
return val;
|
||||
}
|
||||
|
||||
void PackFloat(float f, byte[] buf, ref int offset)
|
||||
{
|
||||
Buffer.BlockCopy(BitConverter.GetBytes(f), 0, buf, offset, sizeof(float));
|
||||
offset += sizeof(float);
|
||||
}
|
||||
float ReadFloat(byte[] buf, ref int offset)
|
||||
{
|
||||
float val = BitConverter.ToSingle(buf, offset);
|
||||
offset += sizeof(float);
|
||||
return val;
|
||||
}
|
||||
|
||||
void PackULong(ulong u, byte[] buf, ref int offset)
|
||||
{
|
||||
Buffer.BlockCopy(BitConverter.GetBytes(u), 0, buf, offset, sizeof(ulong));
|
||||
offset += sizeof(ulong);
|
||||
}
|
||||
ulong ReadULong(byte[] buf, ref int offset)
|
||||
{
|
||||
ulong val = BitConverter.ToUInt64(buf, offset);
|
||||
offset += sizeof(ulong);
|
||||
return val;
|
||||
}
|
||||
|
||||
void PackUInt32(UInt32 u, byte[] buf, ref int offset)
|
||||
{
|
||||
Buffer.BlockCopy(BitConverter.GetBytes(u), 0, buf, offset, sizeof(UInt32));
|
||||
offset += sizeof(UInt32);
|
||||
}
|
||||
UInt32 ReadUInt32(byte[] buf, ref int offset)
|
||||
{
|
||||
UInt32 val = BitConverter.ToUInt32(buf, offset);
|
||||
offset += sizeof(UInt32);
|
||||
return val;
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
fileFormatVersion: 2
|
||||
guid: e5d77a60e86b5bd4a999ef6c83f9e651
|
||||
timeCreated: 1521151723
|
||||
licenseType: Store
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,101 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
using Oculus.Platform;
|
||||
using Oculus.Platform.Models;
|
||||
|
||||
public class PlayerController : SocialPlatformManager
|
||||
{
|
||||
|
||||
// Secondary camera to debug and view the whole scene from above
|
||||
public Camera spyCamera;
|
||||
|
||||
// The OVRCameraRig for the main player so we can disable it
|
||||
private GameObject cameraRig;
|
||||
|
||||
private bool showUI = true;
|
||||
|
||||
public override void Awake()
|
||||
{
|
||||
base.Awake();
|
||||
cameraRig = localPlayerHead.gameObject;
|
||||
}
|
||||
|
||||
// Use this for initialization
|
||||
public override void Start()
|
||||
{
|
||||
base.Start();
|
||||
spyCamera.enabled = false;
|
||||
}
|
||||
|
||||
// Update is called once per frame
|
||||
public override void Update()
|
||||
{
|
||||
base.Update();
|
||||
checkInput();
|
||||
}
|
||||
|
||||
// Check for input from the touch controllers
|
||||
void checkInput()
|
||||
{
|
||||
if (UnityEngine.Application.platform == RuntimePlatform.Android)
|
||||
{
|
||||
// GearVR Controller
|
||||
|
||||
// Bring up friend invite list
|
||||
if (OVRInput.GetDown(OVRInput.Button.Back))
|
||||
{
|
||||
Rooms.LaunchInvitableUserFlow(roomManager.roomID);
|
||||
}
|
||||
|
||||
// Toggle Camera
|
||||
if (OVRInput.GetDown(OVRInput.Button.PrimaryTouchpad))
|
||||
{
|
||||
ToggleCamera();
|
||||
}
|
||||
|
||||
// Toggle Help UI
|
||||
if (OVRInput.GetDown(OVRInput.Button.PrimaryIndexTrigger))
|
||||
{
|
||||
ToggleUI();
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// PC Touch
|
||||
|
||||
// Bring up friend invite list
|
||||
if (OVRInput.GetDown(OVRInput.Button.Three))
|
||||
{
|
||||
Rooms.LaunchInvitableUserFlow (roomManager.roomID);
|
||||
}
|
||||
|
||||
// Toggle Camera
|
||||
if (OVRInput.GetDown(OVRInput.Button.Four))
|
||||
{
|
||||
ToggleCamera();
|
||||
}
|
||||
|
||||
// Toggle Help UI
|
||||
if (OVRInput.GetDown(OVRInput.Button.PrimaryThumbstick))
|
||||
{
|
||||
ToggleUI();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void ToggleCamera()
|
||||
{
|
||||
spyCamera.enabled = !spyCamera.enabled;
|
||||
localAvatar.ShowThirdPerson = !localAvatar.ShowThirdPerson;
|
||||
cameraRig.SetActive(!cameraRig.activeSelf);
|
||||
}
|
||||
|
||||
void ToggleUI()
|
||||
{
|
||||
showUI = !showUI;
|
||||
helpPanel.SetActive(showUI);
|
||||
localAvatar.ShowLeftController(showUI);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 043fbfd0ae7027742bace7a3691feb13
|
||||
timeCreated: 1521151723
|
||||
licenseType: Store
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,32 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
using Oculus.Platform;
|
||||
|
||||
public class RemotePlayer
|
||||
{
|
||||
public ulong remoteUserID;
|
||||
public bool stillInRoom;
|
||||
|
||||
// the result of the last connection state update message
|
||||
public PeerConnectionState p2pConnectionState;
|
||||
// the last reported state of the VOIP connection
|
||||
public PeerConnectionState voipConnectionState;
|
||||
|
||||
public OvrAvatar RemoteAvatar;
|
||||
|
||||
// the last received root transform position updates, equivalent to local tracking space transform
|
||||
public Vector3 receivedRootPosition;
|
||||
|
||||
// the previous received positions to interpolate from
|
||||
public Vector3 receivedRootPositionPrior;
|
||||
|
||||
// the last received root transform rotation updates, equivalent to local tracking space transform
|
||||
public Quaternion receivedRootRotation;
|
||||
|
||||
// the previous received rotations to interpolate from
|
||||
public Quaternion receivedRootRotationPrior;
|
||||
|
||||
// the voip tracker for the player
|
||||
public VoipAudioSourceHiLevel voipSource;
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
fileFormatVersion: 2
|
||||
guid: e5bc955e8176ef1478360f25ef5ccc8a
|
||||
timeCreated: 1521151723
|
||||
licenseType: Store
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,225 @@
|
||||
using UnityEngine;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using Oculus.Platform;
|
||||
using Oculus.Platform.Models;
|
||||
|
||||
// Helper class to manage Room creation, membership and invites.
|
||||
// Rooms are a mechanism to help Oculus users create a shared experience.
|
||||
// Users can only be in one Room at a time. If the Owner of a room
|
||||
// leaves, then ownership is transferred to some other member.
|
||||
// Here we use rooms to create the notion of a 'call' to help us
|
||||
// invite a Friend and establish a VOIP and P2P connection.
|
||||
public class RoomManager
|
||||
{
|
||||
// the ID of the Room that I'm in
|
||||
public ulong roomID;
|
||||
|
||||
// the ID of the Room that I'm invited to
|
||||
private ulong invitedRoomID;
|
||||
|
||||
// Am I the server?
|
||||
private bool amIServer;
|
||||
|
||||
// Have we already gone through the startup?
|
||||
private bool startupDone;
|
||||
|
||||
public RoomManager()
|
||||
{
|
||||
amIServer = false;
|
||||
startupDone = false;
|
||||
Rooms.SetRoomInviteAcceptedNotificationCallback(AcceptingInviteCallback);
|
||||
Rooms.SetUpdateNotificationCallback(RoomUpdateCallback);
|
||||
}
|
||||
|
||||
#region Launched Application from Accepting Invite
|
||||
|
||||
// Callback to check whether the User accepted an invite
|
||||
void AcceptingInviteCallback(Message<string> msg)
|
||||
{
|
||||
if (msg.IsError)
|
||||
{
|
||||
SocialPlatformManager.TerminateWithError(msg);
|
||||
return;
|
||||
}
|
||||
|
||||
SocialPlatformManager.LogOutput("Launched Invite to join Room: " + msg.Data);
|
||||
|
||||
invitedRoomID = Convert.ToUInt64(msg.GetString());
|
||||
|
||||
if (startupDone)
|
||||
{
|
||||
CheckForInvite();
|
||||
}
|
||||
}
|
||||
|
||||
// Check to see if the App was launched by accepting the Notication from the main Oculus app.
|
||||
// If so, we can directly join that room. (If it's still available.)
|
||||
public bool CheckForInvite()
|
||||
{
|
||||
startupDone = true;
|
||||
|
||||
if (invitedRoomID != 0)
|
||||
{
|
||||
JoinExistingRoom(invitedRoomID);
|
||||
return true;
|
||||
}
|
||||
else
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Create a Room and Invite Friend(s) from the Oculus Universal Menu
|
||||
|
||||
public void CreateRoom()
|
||||
{
|
||||
Rooms.CreateAndJoinPrivate(RoomJoinPolicy.FriendsOfOwner, 4, true)
|
||||
.OnComplete(CreateAndJoinPrivateRoomCallback);
|
||||
}
|
||||
|
||||
void CreateAndJoinPrivateRoomCallback(Message<Oculus.Platform.Models.Room> msg)
|
||||
{
|
||||
if (msg.IsError)
|
||||
{
|
||||
SocialPlatformManager.TerminateWithError(msg);
|
||||
return;
|
||||
}
|
||||
|
||||
roomID = msg.Data.ID;
|
||||
|
||||
if (msg.Data.OwnerOptional != null && msg.Data.OwnerOptional.ID == SocialPlatformManager.MyID)
|
||||
{
|
||||
amIServer = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
amIServer = false;
|
||||
}
|
||||
|
||||
SocialPlatformManager.TransitionToState(SocialPlatformManager.State.WAITING_IN_A_ROOM);
|
||||
SocialPlatformManager.SetFloorColorForState(amIServer);
|
||||
}
|
||||
|
||||
void OnLaunchInviteWorkflowComplete(Message msg)
|
||||
{
|
||||
if (msg.IsError)
|
||||
{
|
||||
SocialPlatformManager.TerminateWithError(msg);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Accept Invite
|
||||
|
||||
public void JoinExistingRoom(ulong roomID)
|
||||
{
|
||||
SocialPlatformManager.TransitionToState(SocialPlatformManager.State.JOINING_A_ROOM);
|
||||
Rooms.Join(roomID, true).OnComplete(JoinRoomCallback);
|
||||
}
|
||||
|
||||
void JoinRoomCallback(Message<Oculus.Platform.Models.Room> msg)
|
||||
{
|
||||
if (msg.IsError)
|
||||
{
|
||||
// is reasonable if caller called more than 1 person, and I didn't answer first
|
||||
return;
|
||||
}
|
||||
|
||||
var ownerOculusId = msg.Data.OwnerOptional != null ? msg.Data.OwnerOptional.OculusID : "null";
|
||||
var userCount = msg.Data.UsersOptional != null ? msg.Data.UsersOptional.Count : 0;
|
||||
|
||||
SocialPlatformManager.LogOutput("Joined Room " + msg.Data.ID + " owner: " + ownerOculusId + " count: " + userCount);
|
||||
roomID = msg.Data.ID;
|
||||
ProcessRoomData(msg);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Room Updates
|
||||
|
||||
void RoomUpdateCallback(Message<Oculus.Platform.Models.Room> msg)
|
||||
{
|
||||
if (msg.IsError)
|
||||
{
|
||||
SocialPlatformManager.TerminateWithError(msg);
|
||||
return;
|
||||
}
|
||||
|
||||
var ownerOculusId = msg.Data.OwnerOptional != null ? msg.Data.OwnerOptional.OculusID : "null";
|
||||
var userCount = msg.Data.UsersOptional != null ? msg.Data.UsersOptional.Count : 0;
|
||||
|
||||
SocialPlatformManager.LogOutput("Room Update " + msg.Data.ID + " owner: " + ownerOculusId + " count: " + userCount);
|
||||
ProcessRoomData(msg);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Room Exit
|
||||
|
||||
public void LeaveCurrentRoom()
|
||||
{
|
||||
if (roomID != 0)
|
||||
{
|
||||
Rooms.Leave(roomID);
|
||||
roomID = 0;
|
||||
}
|
||||
SocialPlatformManager.TransitionToState(SocialPlatformManager.State.LEAVING_A_ROOM);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Process Room Data
|
||||
|
||||
void ProcessRoomData(Message<Oculus.Platform.Models.Room> msg)
|
||||
{
|
||||
if (msg.Data.OwnerOptional != null && msg.Data.OwnerOptional.ID == SocialPlatformManager.MyID)
|
||||
{
|
||||
amIServer = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
amIServer = false;
|
||||
}
|
||||
|
||||
// if the caller left while I was in the process of joining, just use that as our new room
|
||||
if (msg.Data.UsersOptional != null && msg.Data.UsersOptional.Count == 1)
|
||||
{
|
||||
SocialPlatformManager.TransitionToState(SocialPlatformManager.State.WAITING_IN_A_ROOM);
|
||||
}
|
||||
else
|
||||
{
|
||||
SocialPlatformManager.TransitionToState(SocialPlatformManager.State.CONNECTED_IN_A_ROOM);
|
||||
}
|
||||
|
||||
// Look for users that left
|
||||
SocialPlatformManager.MarkAllRemoteUsersAsNotInRoom();
|
||||
|
||||
if (msg.Data.UsersOptional != null)
|
||||
{
|
||||
foreach (User user in msg.Data.UsersOptional)
|
||||
{
|
||||
if (user.ID != SocialPlatformManager.MyID)
|
||||
{
|
||||
if (!SocialPlatformManager.IsUserInRoom(user.ID))
|
||||
{
|
||||
SocialPlatformManager.AddRemoteUser(user.ID);
|
||||
}
|
||||
else
|
||||
{
|
||||
SocialPlatformManager.MarkRemoteUserInRoom(user.ID);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
SocialPlatformManager.ForgetRemoteUsersNotInRoom();
|
||||
SocialPlatformManager.SetFloorColorForState(amIServer);
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 923f57b3cf1990047b2e448680c8d5b8
|
||||
timeCreated: 1521151723
|
||||
licenseType: Store
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,587 @@
|
||||
using UnityEngine;
|
||||
using AOT;
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Collections.Generic;
|
||||
using Oculus.Avatar;
|
||||
using Oculus.Platform;
|
||||
using Oculus.Platform.Models;
|
||||
|
||||
|
||||
// This class coordinates communication with the Oculus Platform
|
||||
// Service running in your device.
|
||||
public class SocialPlatformManager : MonoBehaviour
|
||||
{
|
||||
private static readonly Vector3 START_ROTATION_ONE = new Vector3(0, 180, 0);
|
||||
private static readonly Vector3 START_POSITION_ONE = new Vector3(0, 4, 5);
|
||||
|
||||
private static readonly Vector3 START_ROTATION_TWO = new Vector3(0, 0, 0);
|
||||
private static readonly Vector3 START_POSITION_TWO = new Vector3(0, 4, -5);
|
||||
|
||||
private static readonly Vector3 START_ROTATION_THREE = new Vector3(0, 270, 0);
|
||||
private static readonly Vector3 START_POSITION_THREE = new Vector3(5, 4, 0);
|
||||
|
||||
private static readonly Vector3 START_ROTATION_FOUR = new Vector3(0, 90, 0);
|
||||
private static readonly Vector3 START_POSITION_FOUR = new Vector3(-5, 4, 0);
|
||||
|
||||
private static readonly Color BLACK = new Color(0.0f, 0.0f, 0.0f);
|
||||
private static readonly Color WHITE = new Color(1.0f, 1.0f, 1.0f);
|
||||
private static readonly Color CYAN = new Color(0.0f, 1.0f, 1.0f);
|
||||
private static readonly Color BLUE = new Color(0.0f, 0.0f, 1.0f);
|
||||
private static readonly Color GREEN = new Color(0.0f, 1.0f, 0.0f);
|
||||
|
||||
private float voiceCurrent = 0.0f;
|
||||
|
||||
// Local player
|
||||
private UInt32 packetSequence = 0;
|
||||
|
||||
public OvrAvatar localAvatarPrefab;
|
||||
public OvrAvatar remoteAvatarPrefab;
|
||||
|
||||
public GameObject helpPanel;
|
||||
protected MeshRenderer helpMesh;
|
||||
public Material riftMaterial;
|
||||
public Material gearMaterial;
|
||||
|
||||
protected OvrAvatar localAvatar;
|
||||
protected GameObject localTrackingSpace;
|
||||
protected GameObject localPlayerHead;
|
||||
|
||||
// Remote players
|
||||
protected Dictionary<ulong, RemotePlayer> remoteUsers = new Dictionary<ulong, RemotePlayer>();
|
||||
|
||||
// GameObject that represents the center sphere as a visual status indicator of the room
|
||||
public GameObject roomSphere;
|
||||
protected MeshRenderer sphereMesh;
|
||||
public GameObject roomFloor;
|
||||
protected MeshRenderer floorMesh;
|
||||
|
||||
protected State currentState;
|
||||
|
||||
protected static SocialPlatformManager s_instance = null;
|
||||
protected RoomManager roomManager;
|
||||
protected P2PManager p2pManager;
|
||||
protected VoipManager voipManager;
|
||||
|
||||
// my Application-scoped Oculus ID
|
||||
protected ulong myID;
|
||||
|
||||
// my Oculus user name
|
||||
protected string myOculusID;
|
||||
|
||||
|
||||
// animating the mouth for voip
|
||||
public static readonly float VOIP_SCALE = 2f;
|
||||
|
||||
public virtual void Update()
|
||||
{
|
||||
// Look for updates from remote users
|
||||
p2pManager.GetRemotePackets();
|
||||
|
||||
// update avatar mouths to match voip volume
|
||||
foreach (KeyValuePair<ulong, RemotePlayer> kvp in remoteUsers)
|
||||
{
|
||||
if (kvp.Value.voipSource == null)
|
||||
{
|
||||
if (kvp.Value.RemoteAvatar.MouthAnchor != null)
|
||||
{
|
||||
kvp.Value.voipSource = kvp.Value.RemoteAvatar.MouthAnchor.AddComponent<VoipAudioSourceHiLevel>();
|
||||
kvp.Value.voipSource.senderID = kvp.Value.remoteUserID;
|
||||
}
|
||||
}
|
||||
|
||||
if (kvp.Value.voipSource != null)
|
||||
{
|
||||
float remoteVoiceCurrent = Mathf.Clamp(kvp.Value.voipSource.peakAmplitude * VOIP_SCALE, 0f, 1f);
|
||||
kvp.Value.RemoteAvatar.VoiceAmplitude = remoteVoiceCurrent;
|
||||
}
|
||||
}
|
||||
|
||||
if (localAvatar != null)
|
||||
{
|
||||
localAvatar.VoiceAmplitude = Mathf.Clamp(voiceCurrent * VOIP_SCALE, 0f, 1f);
|
||||
}
|
||||
|
||||
Oculus.Platform.Request.RunCallbacks();
|
||||
}
|
||||
|
||||
#region Initialization and Shutdown
|
||||
|
||||
public virtual void Awake()
|
||||
{
|
||||
LogOutputLine("Start Log.");
|
||||
|
||||
// Grab the MeshRenderers. We'll be using the material colour to visually show status
|
||||
helpMesh = helpPanel.GetComponent<MeshRenderer>();
|
||||
sphereMesh = roomSphere.GetComponent<MeshRenderer>();
|
||||
floorMesh = roomFloor.GetComponent<MeshRenderer>();
|
||||
|
||||
// Set up the local player
|
||||
localTrackingSpace = this.transform.Find("OVRCameraRig/TrackingSpace").gameObject;
|
||||
localPlayerHead = this.transform.Find("OVRCameraRig/TrackingSpace/CenterEyeAnchor").gameObject;
|
||||
|
||||
// make sure only one instance of this manager ever exists
|
||||
if (s_instance != null)
|
||||
{
|
||||
Destroy(gameObject);
|
||||
return;
|
||||
}
|
||||
|
||||
s_instance = this;
|
||||
DontDestroyOnLoad(gameObject);
|
||||
|
||||
TransitionToState(State.INITIALIZING);
|
||||
|
||||
Core.AsyncInitialize().OnComplete(InitCallback);
|
||||
|
||||
roomManager = new RoomManager();
|
||||
p2pManager = new P2PManager();
|
||||
voipManager = new VoipManager();
|
||||
}
|
||||
|
||||
void InitCallback(Message<PlatformInitialize> msg)
|
||||
{
|
||||
if (msg.IsError)
|
||||
{
|
||||
TerminateWithError(msg);
|
||||
return;
|
||||
}
|
||||
|
||||
LaunchDetails launchDetails = ApplicationLifecycle.GetLaunchDetails();
|
||||
SocialPlatformManager.LogOutput("App launched with LaunchType " + launchDetails.LaunchType);
|
||||
|
||||
// First thing we should do is perform an entitlement check to make sure
|
||||
// we successfully connected to the Oculus Platform Service.
|
||||
Entitlements.IsUserEntitledToApplication().OnComplete(IsEntitledCallback);
|
||||
}
|
||||
|
||||
public virtual void Start()
|
||||
{
|
||||
// noop here, but is being overridden in PlayerController
|
||||
}
|
||||
|
||||
void IsEntitledCallback(Message msg)
|
||||
{
|
||||
if (msg.IsError)
|
||||
{
|
||||
TerminateWithError(msg);
|
||||
return;
|
||||
}
|
||||
|
||||
// Next get the identity of the user that launched the Application.
|
||||
Users.GetLoggedInUser().OnComplete(GetLoggedInUserCallback);
|
||||
}
|
||||
|
||||
void GetLoggedInUserCallback(Message<User> msg)
|
||||
{
|
||||
if (msg.IsError)
|
||||
{
|
||||
TerminateWithError(msg);
|
||||
return;
|
||||
}
|
||||
|
||||
myID = msg.Data.ID;
|
||||
myOculusID = msg.Data.OculusID;
|
||||
|
||||
localAvatar = Instantiate(localAvatarPrefab);
|
||||
localAvatar.CanOwnMicrophone = false;
|
||||
localTrackingSpace = this.transform.Find("OVRCameraRig/TrackingSpace").gameObject;
|
||||
|
||||
localAvatar.transform.SetParent(localTrackingSpace.transform, false);
|
||||
localAvatar.transform.localPosition = new Vector3(0, 0, 0);
|
||||
localAvatar.transform.localRotation = Quaternion.identity;
|
||||
|
||||
if (UnityEngine.Application.platform == RuntimePlatform.Android)
|
||||
{
|
||||
helpPanel.transform.SetParent(localAvatar.transform.Find("body"), false);
|
||||
helpPanel.transform.localPosition = new Vector3(0, 1.0f, 1.0f);
|
||||
helpMesh.material = gearMaterial;
|
||||
}
|
||||
else
|
||||
{
|
||||
helpPanel.transform.SetParent(localAvatar.transform.Find("hand_left"), false);
|
||||
helpPanel.transform.localPosition = new Vector3(0, 0.2f, 0.2f);
|
||||
helpMesh.material = riftMaterial;
|
||||
}
|
||||
|
||||
localAvatar.oculusUserID = myID.ToString();
|
||||
localAvatar.RecordPackets = true;
|
||||
localAvatar.PacketRecorded += OnLocalAvatarPacketRecorded;
|
||||
localAvatar.EnableMouthVertexAnimation = true;
|
||||
|
||||
Quaternion rotation = Quaternion.identity;
|
||||
|
||||
switch (UnityEngine.Random.Range(0, 4))
|
||||
{
|
||||
case 0:
|
||||
rotation.eulerAngles = START_ROTATION_ONE;
|
||||
this.transform.localPosition = START_POSITION_ONE;
|
||||
this.transform.localRotation = rotation;
|
||||
break;
|
||||
|
||||
case 1:
|
||||
rotation.eulerAngles = START_ROTATION_TWO;
|
||||
this.transform.localPosition = START_POSITION_TWO;
|
||||
this.transform.localRotation = rotation;
|
||||
break;
|
||||
|
||||
case 2:
|
||||
rotation.eulerAngles = START_ROTATION_THREE;
|
||||
this.transform.localPosition = START_POSITION_THREE;
|
||||
this.transform.localRotation = rotation;
|
||||
break;
|
||||
|
||||
case 3:
|
||||
default:
|
||||
rotation.eulerAngles = START_ROTATION_FOUR;
|
||||
this.transform.localPosition = START_POSITION_FOUR;
|
||||
this.transform.localRotation = rotation;
|
||||
break;
|
||||
}
|
||||
|
||||
TransitionToState(State.CHECKING_LAUNCH_STATE);
|
||||
|
||||
// If the user launched the app by accepting the notification, then we want to
|
||||
// join that room. If not, try to find a friend's room to join
|
||||
if (!roomManager.CheckForInvite())
|
||||
{
|
||||
SocialPlatformManager.LogOutput("No invite on launch, looking for a friend to join.");
|
||||
Users.GetLoggedInUserFriendsAndRooms()
|
||||
.OnComplete(GetLoggedInUserFriendsAndRoomsCallback);
|
||||
}
|
||||
Voip.SetMicrophoneFilterCallback(MicFilter);
|
||||
}
|
||||
|
||||
void GetLoggedInUserFriendsAndRoomsCallback(Message<UserAndRoomList> msg)
|
||||
{
|
||||
if (msg.IsError)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
foreach (UserAndRoom el in msg.Data)
|
||||
{
|
||||
// see if any friends are in a joinable room
|
||||
if (el.User == null) continue;
|
||||
if (el.RoomOptional == null) continue;
|
||||
if (el.RoomOptional.IsMembershipLocked == true) continue;
|
||||
if (el.RoomOptional.Joinability != RoomJoinability.CanJoin) continue;
|
||||
if (el.RoomOptional.JoinPolicy == RoomJoinPolicy.None) continue;
|
||||
|
||||
SocialPlatformManager.LogOutput("Trying to join room " + el.RoomOptional.ID + ", friend " + el.User.OculusID);
|
||||
roomManager.JoinExistingRoom(el.RoomOptional.ID);
|
||||
return;
|
||||
}
|
||||
|
||||
SocialPlatformManager.LogOutput("No friend to join. Creating my own room.");
|
||||
// didn't find any open rooms, start a new room
|
||||
roomManager.CreateRoom();
|
||||
TransitionToState(State.CREATING_A_ROOM);
|
||||
}
|
||||
|
||||
public void OnLocalAvatarPacketRecorded(object sender, OvrAvatar.PacketEventArgs args)
|
||||
{
|
||||
var size = Oculus.Avatar.CAPI.ovrAvatarPacket_GetSize(args.Packet.ovrNativePacket);
|
||||
byte[] toSend = new byte[size];
|
||||
|
||||
Oculus.Avatar.CAPI.ovrAvatarPacket_Write(args.Packet.ovrNativePacket, size, toSend);
|
||||
|
||||
foreach (KeyValuePair<ulong, RemotePlayer> kvp in remoteUsers)
|
||||
{
|
||||
//LogOutputLine("Sending avatar Packet to " + kvp.Key);
|
||||
// Root is local tracking space transform
|
||||
p2pManager.SendAvatarUpdate(kvp.Key, localTrackingSpace.transform, packetSequence, toSend);
|
||||
}
|
||||
|
||||
packetSequence++;
|
||||
}
|
||||
|
||||
public void OnApplicationQuit()
|
||||
{
|
||||
roomManager.LeaveCurrentRoom();
|
||||
|
||||
foreach (KeyValuePair<ulong, RemotePlayer> kvp in remoteUsers)
|
||||
{
|
||||
p2pManager.Disconnect(kvp.Key);
|
||||
voipManager.Disconnect(kvp.Key);
|
||||
}
|
||||
LogOutputLine("End Log.");
|
||||
}
|
||||
|
||||
public void AddUser(ulong userID, ref RemotePlayer remoteUser)
|
||||
{
|
||||
remoteUsers.Add(userID, remoteUser);
|
||||
}
|
||||
|
||||
public void LogOutputLine(string line)
|
||||
{
|
||||
Debug.Log(Time.time + ": " + line);
|
||||
}
|
||||
|
||||
// For most errors we terminate the Application since this example doesn't make
|
||||
// sense if the user is disconnected.
|
||||
public static void TerminateWithError(Message msg)
|
||||
{
|
||||
s_instance.LogOutputLine("Error: " + msg.GetError().Message);
|
||||
UnityEngine.Application.Quit();
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Properties
|
||||
|
||||
public static State CurrentState
|
||||
{
|
||||
get
|
||||
{
|
||||
return s_instance.currentState;
|
||||
}
|
||||
}
|
||||
|
||||
public static ulong MyID
|
||||
{
|
||||
get
|
||||
{
|
||||
if (s_instance != null)
|
||||
{
|
||||
return s_instance.myID;
|
||||
}
|
||||
else
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public static string MyOculusID
|
||||
{
|
||||
get
|
||||
{
|
||||
if (s_instance != null && s_instance.myOculusID != null)
|
||||
{
|
||||
return s_instance.myOculusID;
|
||||
}
|
||||
else
|
||||
{
|
||||
return string.Empty;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region State Management
|
||||
|
||||
public enum State
|
||||
{
|
||||
// loading platform library, checking application entitlement,
|
||||
// getting the local user info
|
||||
INITIALIZING,
|
||||
|
||||
// Checking to see if we were launched from an invite
|
||||
CHECKING_LAUNCH_STATE,
|
||||
|
||||
// Creating a room to join
|
||||
CREATING_A_ROOM,
|
||||
|
||||
// in this state we've create a room, and hopefully
|
||||
// sent some invites, and we're waiting people to join
|
||||
WAITING_IN_A_ROOM,
|
||||
|
||||
// in this state we're attempting to join a room from an invite
|
||||
JOINING_A_ROOM,
|
||||
|
||||
// we're in a room with others
|
||||
CONNECTED_IN_A_ROOM,
|
||||
|
||||
// Leaving a room
|
||||
LEAVING_A_ROOM,
|
||||
|
||||
// shutdown any connections and leave the current room
|
||||
SHUTDOWN,
|
||||
};
|
||||
|
||||
public static void TransitionToState(State newState)
|
||||
{
|
||||
if (s_instance)
|
||||
{
|
||||
s_instance.LogOutputLine("State " + s_instance.currentState + " -> " + newState);
|
||||
}
|
||||
|
||||
if (s_instance && s_instance.currentState != newState)
|
||||
{
|
||||
s_instance.currentState = newState;
|
||||
|
||||
// state transition logic
|
||||
switch (newState)
|
||||
{
|
||||
case State.SHUTDOWN:
|
||||
s_instance.OnApplicationQuit();
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
SetSphereColorForState();
|
||||
}
|
||||
|
||||
private static void SetSphereColorForState()
|
||||
{
|
||||
switch (s_instance.currentState)
|
||||
{
|
||||
case State.INITIALIZING:
|
||||
case State.SHUTDOWN:
|
||||
s_instance.sphereMesh.material.color = BLACK;
|
||||
break;
|
||||
|
||||
case State.WAITING_IN_A_ROOM:
|
||||
s_instance.sphereMesh.material.color = WHITE;
|
||||
break;
|
||||
|
||||
case State.CONNECTED_IN_A_ROOM:
|
||||
s_instance.sphereMesh.material.color = CYAN;
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
public static void SetFloorColorForState(bool host)
|
||||
{
|
||||
if (host)
|
||||
{
|
||||
s_instance.floorMesh.material.color = BLUE;
|
||||
}
|
||||
else
|
||||
{
|
||||
s_instance.floorMesh.material.color = GREEN;
|
||||
}
|
||||
}
|
||||
|
||||
public static void MarkAllRemoteUsersAsNotInRoom()
|
||||
{
|
||||
foreach (KeyValuePair<ulong, RemotePlayer> kvp in s_instance.remoteUsers)
|
||||
{
|
||||
kvp.Value.stillInRoom = false;
|
||||
}
|
||||
}
|
||||
|
||||
public static void MarkRemoteUserInRoom(ulong userID)
|
||||
{
|
||||
RemotePlayer remoteUser = new RemotePlayer();
|
||||
|
||||
if (s_instance.remoteUsers.TryGetValue(userID, out remoteUser))
|
||||
{
|
||||
remoteUser.stillInRoom = true;
|
||||
}
|
||||
}
|
||||
|
||||
public static void ForgetRemoteUsersNotInRoom()
|
||||
{
|
||||
List<ulong> toPurge = new List<ulong>();
|
||||
|
||||
foreach (KeyValuePair<ulong, RemotePlayer> kvp in s_instance.remoteUsers)
|
||||
{
|
||||
if (kvp.Value.stillInRoom == false)
|
||||
{
|
||||
toPurge.Add(kvp.Key);
|
||||
}
|
||||
}
|
||||
|
||||
foreach (ulong key in toPurge)
|
||||
{
|
||||
RemoveRemoteUser(key);
|
||||
}
|
||||
}
|
||||
|
||||
public static void LogOutput(string line)
|
||||
{
|
||||
s_instance.LogOutputLine(Time.time + ": " + line);
|
||||
}
|
||||
|
||||
public static bool IsUserInRoom(ulong userID)
|
||||
{
|
||||
return s_instance.remoteUsers.ContainsKey(userID);
|
||||
}
|
||||
|
||||
public static void AddRemoteUser(ulong userID)
|
||||
{
|
||||
RemotePlayer remoteUser = new RemotePlayer();
|
||||
|
||||
remoteUser.RemoteAvatar = Instantiate(s_instance.remoteAvatarPrefab);
|
||||
remoteUser.RemoteAvatar.oculusUserID = userID.ToString();
|
||||
remoteUser.RemoteAvatar.ShowThirdPerson = true;
|
||||
remoteUser.RemoteAvatar.EnableMouthVertexAnimation = true;
|
||||
remoteUser.p2pConnectionState = PeerConnectionState.Unknown;
|
||||
remoteUser.voipConnectionState = PeerConnectionState.Unknown;
|
||||
remoteUser.stillInRoom = true;
|
||||
remoteUser.remoteUserID = userID;
|
||||
|
||||
s_instance.AddUser(userID, ref remoteUser);
|
||||
s_instance.p2pManager.ConnectTo(userID);
|
||||
s_instance.voipManager.ConnectTo(userID);
|
||||
|
||||
s_instance.LogOutputLine("Adding User " + userID);
|
||||
}
|
||||
|
||||
public static void RemoveRemoteUser(ulong userID)
|
||||
{
|
||||
RemotePlayer remoteUser = new RemotePlayer();
|
||||
|
||||
if (s_instance.remoteUsers.TryGetValue(userID, out remoteUser))
|
||||
{
|
||||
Destroy(remoteUser.RemoteAvatar.MouthAnchor.GetComponent<VoipAudioSourceHiLevel>(), 0);
|
||||
Destroy(remoteUser.RemoteAvatar.gameObject, 0);
|
||||
s_instance.remoteUsers.Remove(userID);
|
||||
|
||||
s_instance.LogOutputLine("Removing User " + userID);
|
||||
}
|
||||
}
|
||||
|
||||
public void UpdateVoiceData(short[] pcmData, int numChannels)
|
||||
{
|
||||
if (localAvatar != null)
|
||||
{
|
||||
localAvatar.UpdateVoiceData(pcmData, numChannels);
|
||||
}
|
||||
|
||||
float voiceMax = 0.0f;
|
||||
float[] floats = new float[pcmData.Length];
|
||||
for (int n = 0; n < pcmData.Length; n++)
|
||||
{
|
||||
float cur = floats[n] = (float)pcmData[n] / (float)short.MaxValue;
|
||||
if (cur > voiceMax)
|
||||
{
|
||||
voiceMax = cur;
|
||||
}
|
||||
}
|
||||
voiceCurrent = voiceMax;
|
||||
}
|
||||
|
||||
[MonoPInvokeCallback(typeof(Oculus.Platform.CAPI.FilterCallback))]
|
||||
public static void MicFilter(short[] pcmData, System.UIntPtr pcmDataLength, int frequency, int numChannels)
|
||||
{
|
||||
s_instance.UpdateVoiceData(pcmData, numChannels);
|
||||
}
|
||||
|
||||
|
||||
public static RemotePlayer GetRemoteUser(ulong userID)
|
||||
{
|
||||
RemotePlayer remoteUser = new RemotePlayer();
|
||||
|
||||
if (s_instance.remoteUsers.TryGetValue(userID, out remoteUser))
|
||||
{
|
||||
return remoteUser;
|
||||
}
|
||||
else
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: a14858202ffbfc041afe4e5c282240d9
|
||||
timeCreated: 1539938349
|
||||
licenseType: Store
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,72 @@
|
||||
using UnityEngine;
|
||||
using System.Collections;
|
||||
|
||||
using Oculus.Platform;
|
||||
using Oculus.Platform.Models;
|
||||
|
||||
// Helper class to manage the Voice-over-IP connection to the
|
||||
// remote users
|
||||
public class VoipManager
|
||||
{
|
||||
public VoipManager()
|
||||
{
|
||||
Voip.SetVoipConnectRequestCallback(VoipConnectRequestCallback);
|
||||
Voip.SetVoipStateChangeCallback(VoipStateChangedCallback);
|
||||
}
|
||||
|
||||
public void ConnectTo(ulong userID)
|
||||
{
|
||||
// ID comparison is used to decide who initiates and who gets the Callback
|
||||
if (SocialPlatformManager.MyID < userID)
|
||||
{
|
||||
Voip.Start(userID);
|
||||
SocialPlatformManager.LogOutput("Voip connect to " + userID);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public void Disconnect(ulong userID)
|
||||
{
|
||||
if (userID != 0)
|
||||
{
|
||||
Voip.Stop(userID);
|
||||
|
||||
RemotePlayer remote = SocialPlatformManager.GetRemoteUser(userID);
|
||||
if (remote != null)
|
||||
{
|
||||
remote.voipConnectionState = PeerConnectionState.Unknown;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void VoipConnectRequestCallback(Message<NetworkingPeer> msg)
|
||||
{
|
||||
SocialPlatformManager.LogOutput("Voip request from " + msg.Data.ID);
|
||||
|
||||
RemotePlayer remote = SocialPlatformManager.GetRemoteUser(msg.Data.ID);
|
||||
if (remote != null)
|
||||
{
|
||||
SocialPlatformManager.LogOutput("Voip request accepted from " + msg.Data.ID);
|
||||
Voip.Accept(msg.Data.ID);
|
||||
}
|
||||
}
|
||||
|
||||
void VoipStateChangedCallback(Message<NetworkingPeer> msg)
|
||||
{
|
||||
SocialPlatformManager.LogOutput("Voip state to " + msg.Data.ID + " changed to " + msg.Data.State);
|
||||
|
||||
RemotePlayer remote = SocialPlatformManager.GetRemoteUser(msg.Data.ID);
|
||||
if (remote != null)
|
||||
{
|
||||
remote.voipConnectionState = msg.Data.State;
|
||||
|
||||
// ID comparison is used to decide who initiates and who gets the Callback
|
||||
if (msg.Data.State == PeerConnectionState.Timeout && SocialPlatformManager.MyID < msg.Data.ID)
|
||||
{
|
||||
// keep trying until hangup!
|
||||
Voip.Start(msg.Data.ID);
|
||||
SocialPlatformManager.LogOutput("Voip re-connect to " + msg.Data.ID);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
fileFormatVersion: 2
|
||||
guid: d22b9da5532b0224f82207825f9f6a65
|
||||
timeCreated: 1521151723
|
||||
licenseType: Store
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,9 @@
|
||||
fileFormatVersion: 2
|
||||
guid: fc164fe2aad000b40a6f426b477793aa
|
||||
folderAsset: yes
|
||||
timeCreated: 1496779994
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 17 KiB |
@@ -0,0 +1,58 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 0453138effcc80349b11371805f72f5b
|
||||
timeCreated: 1497548991
|
||||
licenseType: Store
|
||||
TextureImporter:
|
||||
fileIDToRecycleName: {}
|
||||
serializedVersion: 2
|
||||
mipmaps:
|
||||
mipMapMode: 0
|
||||
enableMipMap: 1
|
||||
linearTexture: 0
|
||||
correctGamma: 0
|
||||
fadeOut: 0
|
||||
borderMipMap: 0
|
||||
mipMapFadeDistanceStart: 1
|
||||
mipMapFadeDistanceEnd: 3
|
||||
bumpmap:
|
||||
convertToNormalMap: 0
|
||||
externalNormalMap: 0
|
||||
heightScale: 0.25
|
||||
normalMapFilter: 0
|
||||
isReadable: 0
|
||||
grayScaleToAlpha: 0
|
||||
generateCubemap: 0
|
||||
cubemapConvolution: 0
|
||||
cubemapConvolutionSteps: 7
|
||||
cubemapConvolutionExponent: 1.5
|
||||
seamlessCubemap: 0
|
||||
textureFormat: -1
|
||||
maxTextureSize: 2048
|
||||
textureSettings:
|
||||
filterMode: -1
|
||||
aniso: -1
|
||||
mipBias: -1
|
||||
wrapMode: -1
|
||||
nPOTScale: 1
|
||||
lightmap: 0
|
||||
rGBM: 0
|
||||
compressionQuality: 50
|
||||
spriteMode: 0
|
||||
spriteExtrude: 1
|
||||
spriteMeshType: 1
|
||||
alignment: 0
|
||||
spritePivot: {x: 0.5, y: 0.5}
|
||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||
spritePixelsToUnits: 100
|
||||
alphaIsTransparency: 0
|
||||
spriteTessellationDetail: -1
|
||||
textureType: -1
|
||||
buildTargetSettings: []
|
||||
spriteSheet:
|
||||
serializedVersion: 2
|
||||
sprites: []
|
||||
outline: []
|
||||
spritePackingTag:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 20 KiB |
@@ -0,0 +1,58 @@
|
||||
fileFormatVersion: 2
|
||||
guid: c8f5462cc092d0c40ad71773132863e0
|
||||
timeCreated: 1496780052
|
||||
licenseType: Store
|
||||
TextureImporter:
|
||||
fileIDToRecycleName: {}
|
||||
serializedVersion: 2
|
||||
mipmaps:
|
||||
mipMapMode: 0
|
||||
enableMipMap: 1
|
||||
linearTexture: 0
|
||||
correctGamma: 0
|
||||
fadeOut: 0
|
||||
borderMipMap: 0
|
||||
mipMapFadeDistanceStart: 1
|
||||
mipMapFadeDistanceEnd: 3
|
||||
bumpmap:
|
||||
convertToNormalMap: 0
|
||||
externalNormalMap: 0
|
||||
heightScale: 0.25
|
||||
normalMapFilter: 0
|
||||
isReadable: 0
|
||||
grayScaleToAlpha: 0
|
||||
generateCubemap: 0
|
||||
cubemapConvolution: 0
|
||||
cubemapConvolutionSteps: 7
|
||||
cubemapConvolutionExponent: 1.5
|
||||
seamlessCubemap: 0
|
||||
textureFormat: -1
|
||||
maxTextureSize: 2048
|
||||
textureSettings:
|
||||
filterMode: -1
|
||||
aniso: -1
|
||||
mipBias: -1
|
||||
wrapMode: -1
|
||||
nPOTScale: 1
|
||||
lightmap: 0
|
||||
rGBM: 0
|
||||
compressionQuality: 50
|
||||
spriteMode: 0
|
||||
spriteExtrude: 1
|
||||
spriteMeshType: 1
|
||||
alignment: 0
|
||||
spritePivot: {x: 0.5, y: 0.5}
|
||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||
spritePixelsToUnits: 100
|
||||
alphaIsTransparency: 0
|
||||
spriteTessellationDetail: -1
|
||||
textureType: -1
|
||||
buildTargetSettings: []
|
||||
spriteSheet:
|
||||
serializedVersion: 2
|
||||
sprites: []
|
||||
outline: []
|
||||
spritePackingTag:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
41
Assets/Oculus/Avatar/Samples/SocialStarter/README.txt
Normal file
41
Assets/Oculus/Avatar/Samples/SocialStarter/README.txt
Normal file
@@ -0,0 +1,41 @@
|
||||
The SocialStarter sample shows how to leverage Oculus Avatar and Oculus Platform features to make a very basic networked social experience.
|
||||
|
||||
For full functionality, this sample requires the following:
|
||||
1. An App ID from the Oculus Dashboard (https://dashboard.oculus.com/).
|
||||
2. A build associated with the App ID must be uploaded to a release channel on the Dashboard.
|
||||
3. The email associated with your Oculus account must be added to the Users for the release channel of the build.
|
||||
|
||||
|
||||
Setup instructions:
|
||||
1. Create a new Unity project.
|
||||
2. Import the Oculus Integration from the Unity Asset Store. The Oculus Integration contains everything you need to use Oculus Avatar and Oculus Platforms.
|
||||
3. From the Oculus Dashboard, create an Oculus Rift app and copy the App ID. An App ID is required to use Avatar and Platform features. There must be a build associated with the App ID uploaded to a release channel on the Dashboard for full functionality. The email address associated with your Oculus account must be added to the Users list of the release channel.
|
||||
4. From the Unity Editor menu bar, select Oculus Avatars > Edit Configuration and place your App ID in the two fields for Oculus Rift App Id and Gear VR App Id.
|
||||
5. From the Unity Editor menu bar, select Oculus Platform > Edit Settings and place your App ID in the two fields for Oculus Rift App Id and Gear VR App Id.
|
||||
6. Make sure the prefabs are set correctly. Select the OVRPlayerController object in the scene:
|
||||
a) Local Avatar Prefab should be set to the LocalAvatar (OvrAvatar) prefab found at Assets > Oculus > Avatar > Content > Prefabs.
|
||||
b) Remote Avatar Prefab should be set to the RemoteAvatar (OvrAvatar) prefab found at Assets > Oculus > Avatar > Content > Prefabs.
|
||||
c) From Assets/Oculus/Avatar/Samples/SocialStarter/Assets/Materials, drag Help to the OVRPlayerController’s Rift Material property.
|
||||
d) From Assets/Oculus/Avatar/Samples/SocialStarter/Assets/Materials, drag GearHelp to the OVRPlayerController’s Gear Material property.
|
||||
|
||||
|
||||
How to use:
|
||||
1. When you first start up the sample you are placed in a virtual room. In the virtual room, the color of the floor and sphere are used as indicators.
|
||||
a) The floor color indicates whether you are the owner of the room. Blue means you are the owner of the room. Green means you are a member of the room that joined via an invitation from the owner.
|
||||
b) The sphere color indicates whether you are in an online room. White means you are in an online room. Black means that either online room creation or an invite attempt failed for some reason.
|
||||
2. Your left hand should be holding the instructions UI. If you do not see the instructions, please make sure you followed steps 6c and 6d above. The instructions are as follows:
|
||||
|
||||
Rift
|
||||
Click left stick: Toggle showing the instructions.
|
||||
Button Y: Toggle the sky camera. This allows you to view the scene from a static third-person camera.
|
||||
Button X: Room invites. This will bring up the invite UI, which will show a list of your friends that you can invite to the room. This may take a second or two to pop up. Note that this functionality only works if you have uploaded a build to the Dashboard for the App ID you used.
|
||||
Left stick: Move around.
|
||||
Right stick: Rotate direction.
|
||||
|
||||
Oculus Go and Gear VR
|
||||
Trigger: Toggle showing the instructions.
|
||||
Touchpad click: Toggle the sky camera.
|
||||
Back button: Room invites.
|
||||
Touchpad: Move around.
|
||||
|
||||
3. When a user joins your room, a VoIP connection and a P2P connection will be set up. The P2P connection is used to send Avatar and positional updates. Note that this functionality only works if you have uploaded a build to the Dashboard for the App ID you used.
|
||||
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: a7a78d98ba50c73429cf004f1635d521
|
||||
timeCreated: 1517510514
|
||||
licenseType: Store
|
||||
TextScriptImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
Reference in New Issue
Block a user