Played around with shaders and vfx graph, also started to work on networking

This commit is contained in:
Mikolaj 2022-05-17 16:00:45 +02:00
parent daaa135ecf
commit 5ad5751298
258 changed files with 89400 additions and 2338 deletions

32
Assets/CameraControler.cs Normal file
View file

@ -0,0 +1,32 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using Cinemachine;
namespace TTTSC.Player.Character.Controller
{
public class CameraControler : MonoBehaviour
{
private Transform _cameraTransfrom;
[SerializeField]
private Transform _cameraAnchor;
private GameObject _cinemachineCamera;
private CinemachineVirtualCamera _virtualCamera;
private CinemachineObjectRotator _objectRotator;
// Start is called before the first frame update
void Start()
{
_cameraTransfrom = GameObject.FindGameObjectWithTag("MainCamera").GetComponent<Transform>();
_cinemachineCamera = GameObject.FindGameObjectWithTag("CinemachineMainCamera");
_virtualCamera = _cinemachineCamera.GetComponent<CinemachineVirtualCamera>();
_objectRotator = _cinemachineCamera.GetComponent<CinemachineObjectRotator>();
_virtualCamera.Follow = _cameraAnchor;
_objectRotator.cameraTransform = _cameraTransfrom;
_objectRotator.horizontalRotationTargets.Add(transform);
}
}
}

View file

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 2c819d953c83aeb4296690c8564ca0d9
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,282 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &6062496430592583549
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 6062496430592583550}
m_Layer: 3
m_Name: PlayerCameraAnchor
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &6062496430592583550
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6062496430592583549}
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 0, y: 0.03, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 6062496430999171079}
m_RootOrder: 1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &6062496430727984388
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 6062496430727984391}
- component: {fileID: 6062496430727984390}
- component: {fileID: 6062496430727984389}
m_Layer: 0
m_Name: EventSystem
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &6062496430727984391
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6062496430727984388}
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 25, y: -2.583, z: 20.885}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 6062496430999171079}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!114 &6062496430727984390
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6062496430727984388}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 76c392e42b5098c458856cdf6ecaaaa1, type: 3}
m_Name:
m_EditorClassIdentifier:
m_FirstSelected: {fileID: 0}
m_sendNavigationEvents: 1
m_DragThreshold: 10
--- !u!114 &6062496430727984389
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6062496430727984388}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 01614664b831546d2ae94a42149d80ac, type: 3}
m_Name:
m_EditorClassIdentifier:
m_MoveRepeatDelay: 0.5
m_MoveRepeatRate: 0.1
m_XRTrackingOrigin: {fileID: 0}
m_ActionsAsset: {fileID: -944628639613478452, guid: ca9f5fa95ffab41fb9a615ab714db018,
type: 3}
m_PointAction: {fileID: -1654692200621890270, guid: ca9f5fa95ffab41fb9a615ab714db018,
type: 3}
m_MoveAction: {fileID: -8784545083839296357, guid: ca9f5fa95ffab41fb9a615ab714db018,
type: 3}
m_SubmitAction: {fileID: 392368643174621059, guid: ca9f5fa95ffab41fb9a615ab714db018,
type: 3}
m_CancelAction: {fileID: 7727032971491509709, guid: ca9f5fa95ffab41fb9a615ab714db018,
type: 3}
m_LeftClickAction: {fileID: 3001919216989983466, guid: ca9f5fa95ffab41fb9a615ab714db018,
type: 3}
m_MiddleClickAction: {fileID: -2185481485913320682, guid: ca9f5fa95ffab41fb9a615ab714db018,
type: 3}
m_RightClickAction: {fileID: -4090225696740746782, guid: ca9f5fa95ffab41fb9a615ab714db018,
type: 3}
m_ScrollWheelAction: {fileID: 6240969308177333660, guid: ca9f5fa95ffab41fb9a615ab714db018,
type: 3}
m_TrackedDevicePositionAction: {fileID: 6564999863303420839, guid: ca9f5fa95ffab41fb9a615ab714db018,
type: 3}
m_TrackedDeviceOrientationAction: {fileID: 7970375526676320489, guid: ca9f5fa95ffab41fb9a615ab714db018,
type: 3}
m_DeselectOnBackgroundClick: 1
m_PointerBehavior: 0
--- !u!1 &6062496430999171099
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 6062496430999171079}
- component: {fileID: 6062496430999171084}
- component: {fileID: 6062496430999171073}
- component: {fileID: 6062496430999171076}
- component: {fileID: 6062496430999171074}
- component: {fileID: 6062496430999171072}
- component: {fileID: 6062496430999171086}
- component: {fileID: 9200296088039977358}
- component: {fileID: 3186146282381019070}
m_Layer: 3
m_Name: Player_Ghost
m_TagString: Player
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &6062496430999171079
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6062496430999171099}
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -25, y: 2.583, z: -20.885}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
- {fileID: 6062496430727984391}
- {fileID: 6062496430592583550}
m_Father: {fileID: 0}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!114 &6062496430999171084
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6062496430999171099}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 495cd3a0a3a33904ab3473618f482aa4, type: 3}
m_Name:
m_EditorClassIdentifier:
characterRigidbody: {fileID: 6062496430999171072}
cameraTransform: {fileID: 0}
playerInfoData: {fileID: 0}
playerStateEnforcrer: {fileID: 6062496430999171074}
playerStateMachine: {fileID: 6062496430999171073}
playerInputReceiver: {fileID: 6062496430999171076}
gameManager: {fileID: 0}
roundSystem: {fileID: 0}
--- !u!114 &6062496430999171073
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6062496430999171099}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: abe7058362b44e043b66c7ddc42a22c2, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!114 &6062496430999171076
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6062496430999171099}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 777675542a674f346bb9629fd1eb84bc, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!114 &6062496430999171074
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6062496430999171099}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 293f9b619cc75c24f93ceaf1ed5d04de, type: 3}
m_Name:
m_EditorClassIdentifier:
_playerGhostReffrenceHub: {fileID: 6062496430999171084}
_playerInfoData: {fileID: 0}
_aliveBodyPrefab: {fileID: 6167160771052314074, guid: 0c51ca6cd6963b14eaa25c9a60dc3c30,
type: 3}
_spectatorBodyPrefab: {fileID: 1135382073684329176, guid: b615186e864b86245a99d5258f67ae27,
type: 3}
--- !u!54 &6062496430999171072
Rigidbody:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6062496430999171099}
serializedVersion: 2
m_Mass: 1
m_Drag: 0
m_AngularDrag: 0.05
m_UseGravity: 0
m_IsKinematic: 0
m_Interpolate: 0
m_Constraints: 112
m_CollisionDetection: 3
--- !u!114 &6062496430999171086
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6062496430999171099}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 8e19d2cb639d0254b858f57d281e6005, type: 3}
m_Name:
m_EditorClassIdentifier:
_playerInfoData: {fileID: 0}
--- !u!114 &9200296088039977358
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6062496430999171099}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 9b91ecbcc199f4492b9a91e820070131, type: 3}
m_Name:
m_EditorClassIdentifier:
sceneId: 0
serverOnly: 0
visible: 0
m_AssetId: 4b8299fb26d528c4a96049468544b48f
hasSpawned: 0
--- !u!114 &3186146282381019070
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6062496430999171099}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 2c819d953c83aeb4296690c8564ca0d9, type: 3}
m_Name:
m_EditorClassIdentifier:
_cameraAnchor: {fileID: 6062496430592583550}

View file

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 4b8299fb26d528c4a96049468544b48f
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 229adc495d0d8174a88d12a34d63e9e5
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -27,21 +27,37 @@ Material:
m_LightmapFlags: 4
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: 2000
m_CustomRenderQueue: -1
stringTagMap:
RenderType: Opaque
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- MainTex:
m_Texture: {fileID: 2800000, guid: 423391cbbe5ecd94b94ef01cc234a46d, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- Mask_R_Emission:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BaseMap:
m_Texture: {fileID: 2800000, guid: 423391cbbe5ecd94b94ef01cc234a46d, type: 3}
m_Scale: {x: 1000, y: 1000}
m_Offset: {x: 0, y: 0}
- _Base_Map:
m_Texture: {fileID: 2800000, guid: 423391cbbe5ecd94b94ef01cc234a46d, type: 3}
m_Scale: {x: 1000, y: 1000}
m_Offset: {x: 0, y: 0}
- _BumpMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _Cube:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailAlbedoMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
@ -54,6 +70,14 @@ Material:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DiffuseTexture:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _EmissionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
@ -66,6 +90,10 @@ Material:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _Normal_Map:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _OcclusionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
@ -92,37 +120,80 @@ Material:
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- Brightness_Rim: 2
- MAIN_LIGHT_CALCULATE_SHADOWS: 0
- Rim_Power: 5
- Toon_Ramp_Offset: 0.5
- Toon_Ramp_Smoothness: 0
- _AlphaClip: 0
- _Ambient_Occlusion: 0
- _Blend: 0
- _BlendOp: 0
- _BumpScale: 1
- _CameraFadingEnabled: 0
- _CameraFarFadeDistance: 2
- _CameraNearFadeDistance: 1
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _ColorMask: 15
- _ColorMode: 0
- _Cull: 2
- _Cutoff: 0.5
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DistortionBlend: 0.5
- _DistortionEnabled: 0
- _DistortionStrength: 1
- _DistortionStrengthScaled: 0.1
- _DstBlend: 0
- _EnvironmentReflections: 1
- _FlipbookBlending: 0
- _FlipbookMode: 0
- _GlossMapScale: 1
- _Glossiness: 0.5
- _GlossyReflections: 1
- _MAIN_LIGHT_SHADOWS: 0
- _MAIN_LIGHT_SHADOWS_CASCADE: 0
- _Metallic: 0
- _Mode: 0
- _Normal_Strength: 0
- _OcclusionStrength: 1
- _Offset: 0
- _Parallax: 0.02
- _QueueControl: 0
- _QueueOffset: 0
- _ReceiveShadows: 1
- _SHADOWS_SOFT: 0
- _SHADOW_SOFT: 0
- _Shininess: 0.7
- _Smoothness: 0.5
- _SmoothnessTextureChannel: 0
- _SoftParticlesEnabled: 0
- _SoftParticlesFarFadeDistance: 1
- _SoftParticlesNearFadeDistance: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _Stencil: 0
- _StencilComp: 8
- _StencilOp: 0
- _StencilReadMask: 255
- _StencilWriteMask: 255
- _Strength: 0.2
- _Surface: 0
- _UVSec: 0
- _UseUIAlphaClip: 0
- _WorkflowMode: 1
- _ZWrite: 1
m_Colors:
- Toon_Ramp_Tint: {r: 0.34117648, g: 0.34117648, b: 0.34117648, a: 1}
- _BaseColor: {r: 1, g: 1, b: 1, a: 1}
- _BaseColorAddSubDiff: {r: 0, g: 0, b: 0, a: 0}
- _CameraFadeParams: {r: 0, g: 0, b: 0, a: 0}
- _Color: {r: 1, g: 1, b: 1, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _Offset: {r: 0, g: 0, b: 0, a: 0}
- _ReflectColor: {r: 1, g: 1, b: 1, a: 0.5}
- _SoftParticleFadeParams: {r: 0, g: 0, b: 0, a: 0}
- _SpecColor: {r: 0.2, g: 0.2, b: 0.2, a: 1}
- _Tiling: {r: 1000, g: 1000, b: 0, a: 0}
m_BuildTextureStacks: []

View file

@ -21,6 +21,14 @@ Material:
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- MainTex:
m_Texture: {fileID: 2800000, guid: 183cc34fb39cd6e48854ccb835b53869, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- Mask_R_Emission:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BaseMap:
m_Texture: {fileID: 2800000, guid: 183cc34fb39cd6e48854ccb835b53869, type: 3}
m_Scale: {x: 10, y: 10}
@ -79,6 +87,10 @@ Material:
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- Brightness_Rim: 2
- Rim_Power: 5
- Toon_Ramp_Offset: 0.5
- Toon_Ramp_Smoothness: 0
- _AlphaClip: 0
- _Blend: 0
- _BumpScale: 1
@ -97,6 +109,7 @@ Material:
- _Mode: 0
- _OcclusionStrength: 1
- _Parallax: 0.02
- _QueueControl: 0
- _QueueOffset: 0
- _ReceiveShadows: 1
- _Smoothness: 0
@ -108,10 +121,13 @@ Material:
- _WorkflowMode: 1
- _ZWrite: 1
m_Colors:
- Toon_Ramp_Tint: {r: 0.33962262, g: 0.33962262, b: 0.33962262, a: 1}
- _BaseColor: {r: 1, g: 1, b: 1, a: 1}
- _Color: {r: 1, g: 1, b: 1, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _Offset: {r: 0, g: 0, b: 0, a: 0}
- _SpecColor: {r: 0.2, g: 0.2, b: 0.2, a: 1}
- _Tiling: {r: 10, g: 10, b: 0, a: 0}
m_BuildTextureStacks: []
--- !u!114 &5412631003896171903
MonoBehaviour:

View file

@ -14,13 +14,21 @@ Material:
m_LightmapFlags: 4
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: 2000
m_CustomRenderQueue: -1
stringTagMap:
RenderType: Opaque
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- MainTex:
m_Texture: {fileID: 2800000, guid: 42106d5139c46084e9338f3079c83481, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- Mask_R_Emission:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BaseMap:
m_Texture: {fileID: 2800000, guid: 42106d5139c46084e9338f3079c83481, type: 3}
m_Scale: {x: 1, y: 1}
@ -79,6 +87,10 @@ Material:
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- Brightness_Rim: 2
- Rim_Power: 6.57
- Toon_Ramp_Offset: 0.5
- Toon_Ramp_Smoothness: 0
- _AlphaClip: 0
- _Blend: 0
- _BumpScale: 1
@ -97,6 +109,7 @@ Material:
- _Mode: 0
- _OcclusionStrength: 1
- _Parallax: 0.02
- _QueueControl: 0
- _QueueOffset: 0
- _ReceiveShadows: 1
- _Smoothness: 0
@ -108,10 +121,13 @@ Material:
- _WorkflowMode: 1
- _ZWrite: 1
m_Colors:
- Toon_Ramp_Tint: {r: 0.34117648, g: 0.34117648, b: 0.34117648, a: 1}
- _BaseColor: {r: 1, g: 1, b: 1, a: 1}
- _Color: {r: 1, g: 1, b: 1, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _Offset: {r: 0, g: 0, b: 0, a: 0}
- _SpecColor: {r: 0.2, g: 0.2, b: 0.2, a: 1}
- _Tiling: {r: 1, g: 1, b: 0, a: 0}
m_BuildTextureStacks: []
--- !u!114 &2749542163986675426
MonoBehaviour:

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 2c04999179e053447af714d7012fc887
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 09d69b2ae1b051242930de530700d161
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 11400000
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,10 @@
using System;
namespace Mirror
{
public interface ISegmentTransport
{
bool ServerSend(int connectionId, int channelId, ArraySegment<byte> data);
bool ClientSend(int channelId, ArraySegment<byte> data);
}
}

View file

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 622d156a237c7894cb013e501d4793fb
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 6bc259d9cf1aa444b824d3aa82a0ef28
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,56 @@
//
// Source: https://stackoverflow.com/questions/255341/getting-multiple-keys-of-specified-value-of-a-generic-dictionary#255630
//
using System;
using System.Collections.Generic;
namespace LightReflectiveMirror
{
class BiDictionary<TFirst, TSecond>
{
IDictionary<TFirst, TSecond> firstToSecond = new Dictionary<TFirst, TSecond>();
IDictionary<TSecond, TFirst> secondToFirst = new Dictionary<TSecond, TFirst>();
public void Add(TFirst first, TSecond second)
{
if (firstToSecond.ContainsKey(first) ||
secondToFirst.ContainsKey(second))
{
throw new ArgumentException("Duplicate first or second");
}
firstToSecond.Add(first, second);
secondToFirst.Add(second, first);
}
public bool TryGetByFirst(TFirst first, out TSecond second)
{
return firstToSecond.TryGetValue(first, out second);
}
public void Remove(TFirst first)
{
secondToFirst.Remove(firstToSecond[first]);
firstToSecond.Remove(first);
}
public ICollection<TFirst> GetAllKeys()
{
return secondToFirst.Values;
}
public bool TryGetBySecond(TSecond second, out TFirst first)
{
return secondToFirst.TryGetValue(second, out first);
}
public TSecond GetByFirst(TFirst first)
{
return firstToSecond[first];
}
public TFirst GetBySecond(TSecond second)
{
return secondToFirst[second];
}
}
}

View file

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 8914d2a366f983644878d8499a097f9d
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: c9c76ba5b4c19024dabfcd3d608ae0d7
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,311 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEditor;
using System.Net;
using System.Reflection;
using System.Linq;
using Mirror;
using Mirror.SimpleWeb;
using System;
using kcp2k;
namespace LightReflectiveMirror
{
#if UNITY_EDITOR
[CustomEditor(typeof(LightReflectiveMirrorTransport))]
public class LRMInspector : Editor
{
int serverPort = 7777;
string serverIP;
float invalidServerIP = 0;
bool usingLLB = false;
LRMDirectConnectModule directModule;
string[] tabs = new string[] { "LRM Settings", "NAT Punch", "Load Balancer", "Other" };
int currentTab = 0;
Type[] supportedTransports = new Type[3] { typeof(KcpTransport), typeof(SimpleWebTransport), typeof(TelepathyTransport) };
public override void OnInspectorGUI()
{
var lrm = (LightReflectiveMirrorTransport)target;
directModule = lrm.GetComponent<LRMDirectConnectModule>();
GUILayout.BeginHorizontal();
GUILayout.FlexibleSpace();
GUILayout.Label(Resources.Load<Texture>("LRM"), GUILayout.Height(50), GUILayout.Width(100));
GUILayout.FlexibleSpace();
GUILayout.EndHorizontal();
if (string.IsNullOrEmpty(lrm.loadBalancerAddress))
{
// First setup screen, ask if they are using LLB or just a single LRM node.
EditorGUILayout.HelpBox("Thank you for using LRM!\nTo get started, please select which setup you are using.", MessageType.None);
if (GUILayout.Button("Load Balancer Setup"))
{
usingLLB = true;
lrm.loadBalancerAddress = "127.0.0.1";
serverPort = 7070;
}
if (GUILayout.Button("Single LRM Node Setup"))
{
lrm.loadBalancerAddress = "127.0.0.1";
lrm.useLoadBalancer = false;
usingLLB = false;
serverIP = "172.105.109.117";
}
}
else if (usingLLB)
{
// They said they are using LLB, configure it!
EditorGUILayout.HelpBox("The Load Balancer is another server that is different than the LRM node. Please enter the IP address or domain name of your Load Balancer server, along with the port.", MessageType.None);
EditorGUILayout.HelpBox("Acceptable Examples: 127.0.0.1, mydomain.com", MessageType.Info);
if (Time.realtimeSinceStartup - invalidServerIP < 5)
EditorGUILayout.HelpBox("Invalid Server Address!", MessageType.Error);
serverIP = EditorGUILayout.TextField("Server Address", serverIP);
serverPort = Mathf.Clamp(EditorGUILayout.IntField("Server Port", serverPort), ushort.MinValue, ushort.MaxValue);
if (GUILayout.Button("Continue"))
{
if (IPAddress.TryParse(serverIP, out IPAddress serverAddr))
{
lrm.loadBalancerAddress = serverAddr.ToString();
lrm.loadBalancerPort = (ushort)serverPort;
lrm.serverIP = "127.0.0.1";
lrm.useLoadBalancer = true;
usingLLB = false;
serverIP = "";
}
else
{
try
{
if (Dns.GetHostEntry(serverIP).AddressList.Length > 0)
{
lrm.loadBalancerAddress = serverIP;
lrm.loadBalancerPort = (ushort)serverPort;
lrm.serverIP = "127.0.0.1";
usingLLB = false;
serverIP = "";
}
else
invalidServerIP = Time.realtimeSinceStartup;
}
catch
{
invalidServerIP = Time.realtimeSinceStartup;
}
}
}
}
else if (lrm.clientToServerTransport == null)
{
// next up, the actual transport. We are going to loop over all the transport types here and let them select one.
EditorGUILayout.HelpBox("We need to use the same transport used on the server. Please select the same transport used on your LRM Node(s)", MessageType.None);
foreach (var transport in supportedTransports)
{
if (GUILayout.Button(transport.Name))
{
var newTransportGO = new GameObject("LRM - Connector");
newTransportGO.transform.SetParent(lrm.transform);
var newTransport = newTransportGO.AddComponent(transport);
lrm.clientToServerTransport = (Transport)newTransport;
}
}
}
else if (string.IsNullOrEmpty(lrm.serverIP))
{
// Empty server IP, this is pretty important! Lets show the UI to require it.
EditorGUILayout.HelpBox("For a single LRM node setup, we need the IP address or domain name of your LRM server.", MessageType.None);
EditorGUILayout.HelpBox("Acceptable Examples: 172.105.109.117, mydomain.com", MessageType.Info);
if (Time.realtimeSinceStartup - invalidServerIP < 5)
EditorGUILayout.HelpBox("Invalid Server Address!", MessageType.Error);
serverIP = EditorGUILayout.TextField("Server Address", serverIP);
serverPort = Mathf.Clamp(EditorGUILayout.IntField("Server Port", serverPort), ushort.MinValue, ushort.MaxValue);
if (GUILayout.Button("Continue"))
{
if (IPAddress.TryParse(serverIP, out IPAddress serverAddr))
{
lrm.serverIP = serverAddr.ToString();
lrm.SetTransportPort((ushort)serverPort);
}
else
{
try
{
if (Dns.GetHostEntry(serverIP).AddressList.Length > 0)
{
lrm.serverIP = serverIP;
lrm.SetTransportPort((ushort)serverPort);
}
else
invalidServerIP = Time.realtimeSinceStartup;
}
catch
{
invalidServerIP = Time.realtimeSinceStartup;
}
}
}
}
else if (lrm.NATPunchtroughPort < 0)
{
// NAT Punchthrough configuration.
EditorGUILayout.HelpBox("Do you wish to use NAT Punchthrough? This can reduce load by up to 80% on your LRM nodes, but exposes players IP's to other players.", MessageType.None);
if (GUILayout.Button("Use NAT Punchthrough"))
{
lrm.NATPunchtroughPort = 1;
lrm.useNATPunch = true;
lrm.gameObject.AddComponent<LRMDirectConnectModule>();
}
if (GUILayout.Button("Do NOT use NAT Punchthrough"))
lrm.NATPunchtroughPort = 1;
}
else if (directModule != null && directModule.directConnectTransport == null)
{
// NAT Punchthrough setup.
EditorGUILayout.HelpBox("To use direct connecting, we need a transport to communicate with the other clients. Please select a transport to use.", MessageType.None);
foreach (var transport in supportedTransports)
{
if (lrm.useNATPunch && transport != typeof(KcpTransport))
continue;
if (GUILayout.Button(transport.Name))
{
var newTransportGO = new GameObject("LRM - Direct Connect");
newTransportGO.transform.SetParent(lrm.transform);
var newTransport = newTransportGO.AddComponent(transport);
directModule.directConnectTransport = (Transport)newTransport;
}
}
}
else
{
// They have completed the "setup guide" Show them the main UI
// Remove unused transports...
foreach (var transport in lrm.GetComponentsInChildren<Transport>())
{
if (!(transport is LightReflectiveMirrorTransport))
{
if (transport != lrm.clientToServerTransport && (directModule == null ? true : directModule.directConnectTransport != transport))
{
if (transport.gameObject == lrm.gameObject)
DestroyImmediate(transport);
else
DestroyImmediate(transport.gameObject);
}
}
}
currentTab = GUILayout.Toolbar(currentTab, tabs);
EditorGUILayout.Space();
EditorGUILayout.BeginVertical("Window");
switch (currentTab)
{
case 0:
using (var change = new EditorGUI.ChangeCheckScope())
{
// They are in the LRM Settings tab.
if (lrm.useLoadBalancer)
{
EditorGUILayout.HelpBox("While using a Load Balancer, you don't set the LRM node IP or port.", MessageType.Info);
GUI.enabled = false;
}
lrm.serverIP = EditorGUILayout.TextField("LRM Node IP", lrm.serverIP);
lrm.serverPort = (ushort)Mathf.Clamp(EditorGUILayout.IntField("LRM Node Port", lrm.serverPort), ushort.MinValue, ushort.MaxValue);
lrm.endpointServerPort = (ushort)Mathf.Clamp(EditorGUILayout.IntField("Endpoint Port", lrm.endpointServerPort), ushort.MinValue, ushort.MaxValue);
if (lrm.useLoadBalancer)
{
GUI.enabled = true;
}
lrm.authenticationKey = EditorGUILayout.TextField("LRM Auth Key", lrm.authenticationKey);
lrm.heartBeatInterval = EditorGUILayout.Slider("Heartbeat Time", lrm.heartBeatInterval, 0.1f, 5f);
lrm.connectOnAwake = EditorGUILayout.Toggle("Connect on Awake", lrm.connectOnAwake);
lrm.clientToServerTransport = (Transport)EditorGUILayout.ObjectField("LRM Transport", lrm.clientToServerTransport, typeof(Transport), true);
if (change.changed)
{
EditorUtility.SetDirty(lrm);
}
}
serializedObject.ApplyModifiedProperties();
break;
case 1:
// NAT punch tab.
if (directModule == null)
{
EditorGUILayout.HelpBox("NAT Punchthrough disabled, missing Direct Connect.", MessageType.Info);
if (GUILayout.Button("Add Direct Connect"))
lrm.gameObject.AddComponent<LRMDirectConnectModule>();
}
else
{
if (!(directModule.directConnectTransport is KcpTransport))
{
EditorGUILayout.HelpBox("NAT Punch only supports KCP currently.", MessageType.Info);
GUI.enabled = false;
lrm.useNATPunch = false;
}
lrm.useNATPunch = EditorGUILayout.Toggle("Use NAT Punch", lrm.useNATPunch);
GUI.enabled = true;
directModule.directConnectTransport = (Transport)EditorGUILayout.ObjectField("Direct Transport", directModule.directConnectTransport, typeof(Transport), true);
}
serializedObject.ApplyModifiedProperties();
break;
case 2:
// Load balancer tab
lrm.useLoadBalancer = EditorGUILayout.Toggle("Use Load Balancer", lrm.useLoadBalancer);
if (!lrm.useLoadBalancer)
GUI.enabled = false;
lrm.loadBalancerAddress = EditorGUILayout.TextField("Load Balancer Address", lrm.loadBalancerAddress);
lrm.loadBalancerPort = (ushort)Mathf.Clamp(EditorGUILayout.IntField("Load Balancer Port", lrm.loadBalancerPort), ushort.MinValue, ushort.MaxValue);
lrm.region = (LRMRegions)EditorGUILayout.EnumPopup("Node Region", lrm.region);
if (!lrm.useLoadBalancer)
GUI.enabled = true;
serializedObject.ApplyModifiedProperties();
break;
case 3:
// Other tab...
GUI.enabled = false;
EditorGUILayout.TextField("Server Status", lrm.serverStatus);
EditorGUILayout.TextField("Server ID", string.IsNullOrEmpty(lrm.serverId) ? "Not Hosting." : lrm.serverId);
GUI.enabled = true;
EditorGUILayout.Space();
lrm.serverName = EditorGUILayout.TextField("Server Name", lrm.serverName);
lrm.extraServerData = EditorGUILayout.TextField("Extra Server Data", lrm.extraServerData);
lrm.maxServerPlayers = EditorGUILayout.IntField("Max Server Players", lrm.maxServerPlayers);
lrm.isPublicServer = EditorGUILayout.Toggle("Is Public Server", lrm.isPublicServer);
EditorGUILayout.Space();
EditorGUILayout.Space();
EditorGUILayout.PropertyField(serializedObject.FindProperty("connectedToRelay"));
EditorGUILayout.PropertyField(serializedObject.FindProperty("disconnectedFromRelay"));
EditorGUILayout.PropertyField(serializedObject.FindProperty("serverListUpdated"));
serializedObject.ApplyModifiedProperties();
break;
}
EditorGUILayout.EndVertical();
}
}
}
#endif
}

View file

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: ebe9be4a049785a41ac7c27b7b2c82d1
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,230 @@
// --------------------------------------------------------------------------------------------------------------------
/// <copyright file="HelpAttribute.cs">
/// <See cref="https://github.com/johnearnshaw/unity-inspector-help"></See>
/// Copyright (c) 2017, John Earnshaw, reblGreen Software Limited
/// <See cref="https://github.com/johnearnshaw/"></See>
/// <See cref="https://bitbucket.com/juanshaf/"></See>
/// <See cref="https://reblgreen.com/"></See>
/// All rights reserved.
/// Redistribution and use in source and binary forms, with or without modification, are
/// permitted provided that the following conditions are met:
/// 1. Redistributions of source code must retain the above copyright notice, this list of
/// conditions and the following disclaimer.
/// 2. Redistributions in binary form must reproduce the above copyright notice, this list
/// of conditions and the following disclaimer in the documentation and/or other materials
/// provided with the distribution.
/// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
/// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
/// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.IN NO EVENT SHALL THE
/// COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
/// EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
/// SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
/// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
/// TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
/// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
/// </copyright>
// --------------------------------------------------------------------------------------------------------------------
using System;
using UnityEngine;
#if UNITY_EDITOR
using UnityEditor;
#endif
[AttributeUsage(AttributeTargets.Field, Inherited = true)]
public class HelpAttribute : PropertyAttribute
{
public readonly string text;
// MessageType exists in UnityEditor namespace and can throw an exception when used outside the editor.
// We spoof MessageType at the bottom of this script to ensure that errors are not thrown when
// MessageType is unavailable.
public readonly MessageType type;
/// <summary>
/// Adds a HelpBox to the Unity property inspector above this field.
/// </summary>
/// <param name="text">The help text to be displayed in the HelpBox.</param>
/// <param name="type">The icon to be displayed in the HelpBox.</param>
public HelpAttribute(string text, MessageType type = MessageType.Info)
{
this.text = text;
this.type = type;
}
}
#if UNITY_EDITOR
[CustomPropertyDrawer(typeof(HelpAttribute))]
public class HelpDrawer : PropertyDrawer
{
// Used for top and bottom padding between the text and the HelpBox border.
const int paddingHeight = 8;
// Used to add some margin between the the HelpBox and the property.
const int marginHeight = 2;
// Global field to store the original (base) property height.
float baseHeight = 0;
// Custom added height for drawing text area which has the MultilineAttribute.
float addedHeight = 0;
/// <summary>
/// A wrapper which returns the PropertyDrawer.attribute field as a HelpAttribute.
/// </summary>
HelpAttribute helpAttribute { get { return (HelpAttribute)attribute; } }
/// <summary>
/// A helper property to check for RangeAttribute.
/// </summary>
RangeAttribute rangeAttribute
{
get
{
var attributes = fieldInfo.GetCustomAttributes(typeof(RangeAttribute), true);
return attributes != null && attributes.Length > 0 ? (RangeAttribute)attributes[0] : null;
}
}
/// <summary>
/// A helper property to check for MultiLineAttribute.
/// </summary>
MultilineAttribute multilineAttribute
{
get
{
var attributes = fieldInfo.GetCustomAttributes(typeof(MultilineAttribute), true);
return attributes != null && attributes.Length > 0 ? (MultilineAttribute)attributes[0] : null;
}
}
public override float GetPropertyHeight(SerializedProperty prop, GUIContent label)
{
// We store the original property height for later use...
baseHeight = base.GetPropertyHeight(prop, label);
// This stops icon shrinking if text content doesn't fill out the container enough.
float minHeight = paddingHeight * 5;
// Calculate the height of the HelpBox using the GUIStyle on the current skin and the inspector
// window's currentViewWidth.
var content = new GUIContent(helpAttribute.text);
var style = GUI.skin.GetStyle("helpbox");
var height = style.CalcHeight(content, EditorGUIUtility.currentViewWidth);
// We add tiny padding here to make sure the text is not overflowing the HelpBox from the top
// and bottom.
height += marginHeight * 2;
// Since we draw a custom text area with the label above if our property contains the
// MultilineAttribute, we need to add some extra height to compensate. This is stored in a
// seperate global field so we can use it again later.
if (multilineAttribute != null && prop.propertyType == SerializedPropertyType.String)
{
addedHeight = 48f;
}
// If the calculated HelpBox is less than our minimum height we use this to calculate the returned
// height instead.
return height > minHeight ? height + baseHeight + addedHeight : minHeight + baseHeight + addedHeight;
}
public override void OnGUI(Rect position, SerializedProperty prop, GUIContent label)
{
// We get a local reference to the MultilineAttribute as we use it twice in this method and it
// saves calling the logic twice for minimal optimization, etc...
var multiline = multilineAttribute;
EditorGUI.BeginProperty(position, label, prop);
// Copy the position out so we can calculate the position of our HelpBox without affecting the
// original position.
var helpPos = position;
helpPos.height -= baseHeight + marginHeight;
if (multiline != null)
{
helpPos.height -= addedHeight;
}
// Renders the HelpBox in the Unity inspector UI.
EditorGUI.HelpBox(helpPos, helpAttribute.text, helpAttribute.type);
position.y += helpPos.height + marginHeight;
position.height = baseHeight;
// If we have a RangeAttribute on our field, we need to handle the PropertyDrawer differently to
// keep the same style as Unity's default.
var range = rangeAttribute;
if (range != null)
{
if (prop.propertyType == SerializedPropertyType.Float)
{
EditorGUI.Slider(position, prop, range.min, range.max, label);
}
else if (prop.propertyType == SerializedPropertyType.Integer)
{
EditorGUI.IntSlider(position, prop, (int)range.min, (int)range.max, label);
}
else
{
// Not numeric so draw standard property field as punishment for adding RangeAttribute to
// a property which can not have a range :P
EditorGUI.PropertyField(position, prop, label);
}
}
else if (multiline != null)
{
// Here's where we handle the PropertyDrawer differently if we have a MultiLineAttribute, to try
// and keep some kind of multiline text area. This is not identical to Unity's default but is
// better than nothing...
if (prop.propertyType == SerializedPropertyType.String)
{
var style = GUI.skin.label;
var size = style.CalcHeight(label, EditorGUIUtility.currentViewWidth);
EditorGUI.LabelField(position, label);
position.y += size;
position.height += addedHeight - size;
// Fixed text dissappearing thanks to: http://answers.unity3d.com/questions/244043/textarea-does-not-work-text-dissapears-solution-is.html
prop.stringValue = EditorGUI.TextArea(position, prop.stringValue);
}
else
{
// Again with a MultilineAttribute on a non-text field deserves for the standard property field
// to be drawn as punishment :P
EditorGUI.PropertyField(position, prop, label);
}
}
else
{
// If we get to here it means we're drawing the default property field below the HelpBox. More custom
// and built in PropertyDrawers could be implemented to enable HelpBox but it could easily make for
// hefty else/if block which would need refactoring!
EditorGUI.PropertyField(position, prop, label);
}
EditorGUI.EndProperty();
}
}
#else
// Replicate MessageType Enum if we are not in editor as this enum exists in UnityEditor namespace.
// This should stop errors being logged the same as Shawn Featherly's commit in the Github repo but I
// feel is cleaner than having the conditional directive in the middle of the HelpAttribute constructor.
public enum MessageType
{
None,
Info,
Warning,
Error,
}
#endif

View file

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 6a2112e9804bfdd4d8f1ad9bc5e4d168
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,18 @@
{
"name": "LRM",
"references": [
"GUID:30817c1a0e6d646d99c048fc403f5979",
"GUID:3b5390adca4e2bb4791cb930316d6f3e",
"GUID:725ee7191c021de4dbf9269590ded755",
"GUID:6806a62c384838046a3c66c44f06d75f"
],
"includePlatforms": [],
"excludePlatforms": [],
"allowUnsafeCode": true,
"overrideReferences": false,
"precompiledReferences": [],
"autoReferenced": true,
"defineConstraints": [],
"versionDefines": [],
"noEngineReferences": false
}

View file

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 3e90199726a18bc488368938e8df23bf
AssemblyDefinitionImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,174 @@
// This is an optional module for adding direct connect support
using Mirror;
using System;
using System.Collections.Generic;
using UnityEngine;
using LightReflectiveMirror;
[RequireComponent(typeof(LightReflectiveMirrorTransport))]
public class LRMDirectConnectModule : MonoBehaviour
{
[HideInInspector]
public Transport directConnectTransport;
public bool showDebugLogs;
private LightReflectiveMirrorTransport lightMirrorTransport;
void Awake()
{
lightMirrorTransport = GetComponent<LightReflectiveMirrorTransport>();
if (directConnectTransport == null)
{
Debug.Log("Direct Connect Transport is null!");
return;
}
if (directConnectTransport is LightReflectiveMirrorTransport)
{
Debug.Log("Direct Connect Transport Cannot be the relay, silly. :P");
return;
}
directConnectTransport.OnServerConnected = (OnServerConnected);
directConnectTransport.OnServerDataReceived = (OnServerDataReceived);
directConnectTransport.OnServerDisconnected = (OnServerDisconnected);
directConnectTransport.OnServerError = (OnServerError);
directConnectTransport.OnClientConnected = (OnClientConnected);
directConnectTransport.OnClientDataReceived = (OnClientDataReceived);
directConnectTransport.OnClientDisconnected = (OnClientDisconnected);
directConnectTransport.OnClientError = (OnClientError);
}
public void StartServer(int port)
{
if(port > 0)
SetTransportPort(port);
directConnectTransport.ServerStart();
if (showDebugLogs)
Debug.Log("Direct Connect Server Created!");
}
public void StopServer()
{
directConnectTransport.ServerStop();
}
public void JoinServer(string ip, int port)
{
if (SupportsNATPunch())
SetTransportPort(port);
directConnectTransport.ClientConnect(ip);
}
public void SetTransportPort(int port)
{
if (directConnectTransport is kcp2k.KcpTransport kcpTransport)
kcpTransport.Port = (ushort)port;
else
{
throw new Exception("DIRECT CONNECT MODULE ONLY SUPPORTS KCP AT THE MOMENT.");
}
}
public int GetTransportPort()
{
if (directConnectTransport is kcp2k.KcpTransport kcpTransport)
return kcpTransport.Port;
else
{
throw new Exception("DIRECT CONNECT MODULE ONLY SUPPORTS KCP AT THE MOMENT.");
}
}
public bool SupportsNATPunch()
{
return directConnectTransport is kcp2k.KcpTransport;
}
public bool KickClient(int clientID)
{
if (showDebugLogs)
Debug.Log("Kicked direct connect client.");
#if MIRROR_37_0_OR_NEWER
directConnectTransport.ServerDisconnect(clientID);
return true;
#else
return directConnectTransport.ServerDisconnect(clientID);
#endif
}
public void ClientDisconnect()
{
directConnectTransport.ClientDisconnect();
}
public void ServerSend(int clientID, ArraySegment<byte> data, int channel)
{
#if MIRROR_40_0_OR_NEWER
directConnectTransport.ServerSend(clientID, data, channel);
#else
directConnectTransport.ServerSend(clientID, channel, data);
#endif
}
public void ClientSend(ArraySegment<byte> data, int channel)
{
#if MIRROR_40_0_OR_NEWER
directConnectTransport.ClientSend(data, channel);
#else
directConnectTransport.ClientSend(channel, data);
#endif
}
#region Transport Callbacks
void OnServerConnected(int clientID)
{
if (showDebugLogs)
Debug.Log("Direct Connect Client Connected");
lightMirrorTransport.DirectAddClient(clientID);
}
void OnServerDataReceived(int clientID, ArraySegment<byte> data, int channel)
{
lightMirrorTransport.DirectReceiveData(data, channel, clientID);
}
void OnServerDisconnected(int clientID)
{
lightMirrorTransport.DirectRemoveClient(clientID);
}
void OnServerError(int client, Exception error)
{
if (showDebugLogs)
Debug.Log("Direct Server Error: " + error);
}
void OnClientConnected()
{
if (showDebugLogs)
Debug.Log("Direct Connect Client Joined");
lightMirrorTransport.DirectClientConnected();
}
void OnClientDisconnected()
{
lightMirrorTransport.DirectDisconnected();
}
void OnClientDataReceived(ArraySegment<byte> data, int channel)
{
lightMirrorTransport.DirectReceiveData(data, channel);
}
void OnClientError(Exception error)
{
if (showDebugLogs)
Debug.Log("Direct Client Error: " + error);
}
#endregion
}

View file

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 9c4cbff877abc42448dd829920c6c233
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,198 @@
using System;
using System.Collections;
using System.Collections.Generic;
using System.IO;
using System.IO.Compression;
using System.Text;
using UnityEngine;
namespace LightReflectiveMirror
{
public static class LRMTools
{
public static void WriteByte(this byte[] data, ref int position, byte value)
{
data[position] = value;
position += 1;
}
public static byte ReadByte(this byte[] data, ref int position)
{
byte value = data[position];
position += 1;
return value;
}
public static void WriteBool(this byte[] data, ref int position, bool value)
{
unsafe
{
fixed (byte* dataPtr = &data[position])
{
bool* valuePtr = (bool*)dataPtr;
*valuePtr = value;
position += 1;
}
}
}
public static bool ReadBool(this byte[] data, ref int position)
{
bool value = BitConverter.ToBoolean(data, position);
position += 1;
return value;
}
public static void WriteString(this byte[] data, ref int position, string value)
{
if (string.IsNullOrWhiteSpace(value))
{
data.WriteInt(ref position, 0);
}
else
{
data.WriteInt(ref position, value.Length);
for (int i = 0; i < value.Length; i++)
data.WriteChar(ref position, value[i]);
}
}
public static string ReadString(this byte[] data, ref int position)
{
string value = default;
int stringSize = data.ReadInt(ref position);
for (int i = 0; i < stringSize; i++)
value += data.ReadChar(ref position);
return value;
}
public static void WriteBytes(this byte[] data, ref int position, byte[] value)
{
data.WriteInt(ref position, value.Length);
for (int i = 0; i < value.Length; i++)
data.WriteByte(ref position, value[i]);
}
public static byte[] ReadBytes(this byte[] data, ref int position)
{
int byteSize = data.ReadInt(ref position);
byte[] value = new byte[byteSize];
for (int i = 0; i < byteSize; i++)
value[i] = data.ReadByte(ref position);
return value;
}
public static void WriteChar(this byte[] data, ref int position, char value)
{
unsafe
{
fixed (byte* dataPtr = &data[position])
{
char* valuePtr = (char*)dataPtr;
*valuePtr = value;
position += 2;
}
}
}
public static char ReadChar(this byte[] data, ref int position)
{
char value = BitConverter.ToChar(data, position);
position += 2;
return value;
}
public static void WriteInt(this byte[] data, ref int position, int value)
{
unsafe
{
fixed (byte* dataPtr = &data[position])
{
int* valuePtr = (int*)dataPtr;
*valuePtr = value;
position += 4;
}
}
}
public static int ReadInt(this byte[] data, ref int position)
{
int value = BitConverter.ToInt32(data, position);
position += 4;
return value;
}
}
internal static class CompressorExtensions
{
/// <summary>
/// Decompresses the string.
/// </summary>
/// <param name="compressedText">The compressed text.</param>
/// <returns></returns>
public static string Decompress(this string compressedText)
{
byte[] gZipBuffer = Convert.FromBase64String(compressedText);
using (var memoryStream = new MemoryStream())
{
int dataLength = BitConverter.ToInt32(gZipBuffer, 0);
memoryStream.Write(gZipBuffer, 4, gZipBuffer.Length - 4);
var buffer = new byte[dataLength];
memoryStream.Position = 0;
using (var gZipStream = new GZipStream(memoryStream, CompressionMode.Decompress))
{
gZipStream.Read(buffer, 0, buffer.Length);
}
return Encoding.UTF8.GetString(buffer);
}
}
}
internal static class JsonUtilityHelper
{
public static bool IsJsonArray(string json)
{
return json.StartsWith("[") && json.EndsWith("]");
}
public static T[] FromJson<T>(string json)
{
if (!IsJsonArray(json))
{
throw new System.FormatException("The input json string is not a Json Array");
}
json = "{\"Items\":" + json + "}";
JsonWrapper<T> wrapper = JsonUtility.FromJson<JsonWrapper<T>>(json);
return wrapper.Items;
}
public static string ToJson<T>(T[] array)
{
JsonWrapper<T> wrapper = new JsonWrapper<T>();
wrapper.Items = array;
return JsonUtility.ToJson(wrapper);
}
public static string ToJson<T>(T[] array, bool prettyPrint)
{
JsonWrapper<T> wrapper = new JsonWrapper<T>();
wrapper.Items = array;
return JsonUtility.ToJson(wrapper, prettyPrint);
}
[Serializable]
private class JsonWrapper<T>
{
public T[] Items;
}
}
}

View file

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 603a99af3f33b8c4482f9908752ea561
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 9e2be9cb6d4c6d64ab1812a9dca8bc57
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,74 @@
using Mirror;
using System;
namespace LightReflectiveMirror
{
public partial class LightReflectiveMirrorTransport : Transport
{
public void DirectAddClient(int clientID)
{
if (!_isServer)
return;
_connectedDirectClients.Add(clientID, _currentMemberId);
OnServerConnected?.Invoke(_currentMemberId);
_currentMemberId++;
}
public void DirectRemoveClient(int clientID)
{
if (!_isServer)
return;
OnServerDisconnected?.Invoke(_connectedDirectClients.GetByFirst(clientID));
_connectedDirectClients.Remove(clientID);
}
public void DirectReceiveData(ArraySegment<byte> data, int channel, int clientID = -1)
{
if (_isServer)
OnServerDataReceived?.Invoke(_connectedDirectClients.GetByFirst(clientID), data, channel);
if (_isClient)
OnClientDataReceived?.Invoke(data, channel);
}
public void DirectClientConnected()
{
_directConnected = true;
OnClientConnected?.Invoke();
}
public void DirectDisconnected()
{
if (_directConnected)
{
_isClient = false;
_directConnected = false;
OnClientDisconnected?.Invoke();
}
else
{
int pos = 0;
_directConnected = false;
_clientSendBuffer.WriteByte(ref pos, (byte)OpCodes.JoinServer);
_clientSendBuffer.WriteString(ref pos, _cachedHostID);
_clientSendBuffer.WriteBool(ref pos, false); // Direct failed, use relay
_isClient = true;
#if MIRROR_40_0_OR_NEWER
clientToServerTransport.ClientSend(new System.ArraySegment<byte>(_clientSendBuffer, 0, pos), 0);
#else
clientToServerTransport.ClientSend(0, new System.ArraySegment<byte>(_clientSendBuffer, 0, pos));
#endif
}
if (_clientProxy != null)
{
_clientProxy.Dispose();
_clientProxy = null;
}
}
}
}

View file

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 1e38dc8d43e06744484cf2962c017606
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,67 @@
using Mirror;
using System;
using System.Collections;
using System.Net;
using UnityEngine;
namespace LightReflectiveMirror
{
public partial class LightReflectiveMirrorTransport : Transport
{
IEnumerator NATPunch(IPEndPoint remoteAddress)
{
for (int i = 0; i < 10; i++)
{
_NATPuncher.Send(_punchData, 1, remoteAddress);
yield return new WaitForSeconds(0.25f);
}
}
void RecvData(IAsyncResult result)
{
IPEndPoint newClientEP = new IPEndPoint(IPAddress.Any, 0);
var data = _NATPuncher.EndReceive(result, ref newClientEP);
_NATPuncher.BeginReceive(new AsyncCallback(RecvData), _NATPuncher);
if (!newClientEP.Address.Equals(_relayPuncherIP.Address))
{
if (_isServer)
{
if (_serverProxies.TryGetByFirst(newClientEP, out SocketProxy foundProxy))
{
if (data.Length > 2)
foundProxy.RelayData(data, data.Length);
}
else
{
_serverProxies.Add(newClientEP, new SocketProxy(_NATIP.Port + 1, newClientEP));
_serverProxies.GetByFirst(newClientEP).dataReceived += ServerProcessProxyData;
}
}
if (_isClient)
{
if (_clientProxy == null)
{
_clientProxy = new SocketProxy(_NATIP.Port - 1);
_clientProxy.dataReceived += ClientProcessProxyData;
}
else
{
_clientProxy.ClientRelayData(data, data.Length);
}
}
}
}
void ServerProcessProxyData(IPEndPoint remoteEndpoint, byte[] data)
{
_NATPuncher.Send(data, data.Length, remoteEndpoint);
}
void ClientProcessProxyData(IPEndPoint _, byte[] data)
{
_NATPuncher.Send(data, data.Length, _directConnectEndpoint);
}
}
}

View file

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 3d493f36a877ab042875f198b110ebb3
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,325 @@
using Mirror;
using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using UnityEngine;
namespace LightReflectiveMirror
{
public partial class LightReflectiveMirrorTransport : Transport
{
public override bool ServerActive() => _isServer;
public override bool Available() => _connectedToRelay;
public override void ClientConnect(Uri uri) => ClientConnect(uri.Host);
public override int GetMaxPacketSize(int channelId = 0) => clientToServerTransport.GetMaxPacketSize(channelId);
public override bool ClientConnected() => _isClient;
public override void ServerLateUpdate()
{
if (_directConnectModule != null)
_directConnectModule.directConnectTransport.ServerLateUpdate();
}
public override string ServerGetClientAddress(int connectionId)
{
if (_connectedRelayClients.TryGetBySecond(connectionId, out int relayId))
return relayId.ToString();
if (_connectedDirectClients.TryGetBySecond(connectionId, out int directId))
return "DIRECT-" + directId;
// Shouldn't ever get here.
return "?";
}
public override void ClientEarlyUpdate()
{
clientToServerTransport.ClientEarlyUpdate();
if (_directConnectModule != null)
_directConnectModule.directConnectTransport.ClientEarlyUpdate();
}
public override void ClientLateUpdate()
{
clientToServerTransport.ClientLateUpdate();
if (_directConnectModule != null)
_directConnectModule.directConnectTransport.ClientLateUpdate();
}
public override void ServerEarlyUpdate()
{
if (_directConnectModule != null)
_directConnectModule.directConnectTransport.ServerEarlyUpdate();
}
public override void ClientConnect(string address)
{
if (!Available())
{
Debug.Log("Not connected to relay!");
OnClientDisconnected?.Invoke();
return;
}
if (_isClient || _isServer)
throw new Exception("Cannot connect while hosting/already connected!");
_cachedHostID = address;
var room = GetServerForID(address);
if (!useLoadBalancer)
{
int pos = 0;
_directConnected = false;
_clientSendBuffer.WriteByte(ref pos, (byte)OpCodes.JoinServer);
_clientSendBuffer.WriteString(ref pos, address);
_clientSendBuffer.WriteBool(ref pos, _directConnectModule != null);
if (_directConnectModule == null)
{
_clientSendBuffer.WriteString(ref pos, "0.0.0.0");
}
else
{
if (GetLocalIp() == null)
_clientSendBuffer.WriteString(ref pos, "0.0.0.0");
else
_clientSendBuffer.WriteString(ref pos, GetLocalIp());
}
_isClient = true;
#if MIRROR_40_0_OR_NEWER
clientToServerTransport.ClientSend(new System.ArraySegment<byte>(_clientSendBuffer, 0, pos), 0);
#else
clientToServerTransport.ClientSend(0, new System.ArraySegment<byte>(_clientSendBuffer, 0, pos));
#endif
}
else
{
StartCoroutine(JoinOtherRelayAndMatch(room, address));
}
}
public override void ClientDisconnect()
{
_isClient = false;
// make sure we are even connected to a relay
if (Available())
{
int pos = 0;
_clientSendBuffer.WriteByte(ref pos, (byte)OpCodes.LeaveRoom);
#if MIRROR_40_0_OR_NEWER
clientToServerTransport.ClientSend(new ArraySegment<byte>(_clientSendBuffer, 0, pos), 0);
#else
clientToServerTransport.ClientSend(0, new ArraySegment<byte>(_clientSendBuffer, 0, pos));
#endif
}
if (_directConnectModule != null)
_directConnectModule.ClientDisconnect();
}
#if MIRROR_40_0_OR_NEWER
public override void ClientSend(ArraySegment<byte> segment, int channelId)
#else
public override void ClientSend(int channelId, ArraySegment<byte> segment)
#endif
{
if (_directConnected)
{
_directConnectModule.ClientSend(segment, channelId);
}
else
{
int pos = 0;
_clientSendBuffer.WriteByte(ref pos, (byte)OpCodes.SendData);
_clientSendBuffer.WriteBytes(ref pos, segment.Array.Take(segment.Count).ToArray());
_clientSendBuffer.WriteInt(ref pos, 0);
#if MIRROR_40_0_OR_NEWER
clientToServerTransport.ClientSend(new ArraySegment<byte>(_clientSendBuffer, 0, pos), channelId);
#else
clientToServerTransport.ClientSend(channelId, new ArraySegment<byte>(_clientSendBuffer, 0, pos));
#endif
}
}
#if !MIRROR_37_0_OR_NEWER
public override bool ServerDisconnect(int connectionId)
{
if (_connectedRelayClients.TryGetBySecond(connectionId, out int relayId))
{
int pos = 0;
_clientSendBuffer.WriteByte(ref pos, (byte)OpCodes.KickPlayer);
_clientSendBuffer.WriteInt(ref pos, relayId);
clientToServerTransport.ClientSend(0, new ArraySegment<byte>(_clientSendBuffer, 0, pos));
return true;
}
if (_connectedDirectClients.TryGetBySecond(connectionId, out int directId))
return _directConnectModule.KickClient(directId);
return false;
}
#else
public override void ServerDisconnect(int connectionId)
{
if (_connectedRelayClients.TryGetBySecond(connectionId, out int relayId))
{
int pos = 0;
_clientSendBuffer.WriteByte(ref pos, (byte)OpCodes.KickPlayer);
_clientSendBuffer.WriteInt(ref pos, relayId);
clientToServerTransport.ClientSend(new ArraySegment<byte>(_clientSendBuffer, 0, pos), 0);
return;
}
if (_connectedDirectClients.TryGetBySecond(connectionId, out int directId))
_directConnectModule.KickClient(directId);
}
#endif
#if MIRROR_40_0_OR_NEWER
public override void ServerSend(int connectionId, ArraySegment<byte> segment, int channelId)
#else
public override void ServerSend(int connectionId, int channelId, ArraySegment<byte> segment)
#endif
{
if (_directConnectModule != null && _connectedDirectClients.TryGetBySecond(connectionId, out int directId))
{
_directConnectModule.ServerSend(directId, segment, channelId);
}
else
{
int pos = 0;
_clientSendBuffer.WriteByte(ref pos, (byte)OpCodes.SendData);
_clientSendBuffer.WriteBytes(ref pos, segment.Array.Take(segment.Count).ToArray());
_clientSendBuffer.WriteInt(ref pos, _connectedRelayClients.GetBySecond(connectionId));
#if MIRROR_40_0_OR_NEWER
clientToServerTransport.ClientSend(new ArraySegment<byte>(_clientSendBuffer, 0, pos), channelId);
#else
clientToServerTransport.ClientSend(channelId, new ArraySegment<byte>(_clientSendBuffer, 0, pos));
#endif
}
}
public override void ServerStart()
{
if (!Available())
{
Debug.Log("Not connected to relay! Server failed to start.");
return;
}
if (_isClient || _isServer)
{
Debug.Log("Cannot host while already hosting or connected!");
return;
}
_isServer = true;
_connectedRelayClients = new BiDictionary<int, int>();
_currentMemberId = 1;
_connectedDirectClients = new BiDictionary<int, int>();
var keys = new List<IPEndPoint>(_serverProxies.GetAllKeys());
for (int i = 0; i < keys.Count; i++)
{
_serverProxies.GetByFirst(keys[i]).Dispose();
_serverProxies.Remove(keys[i]);
}
int pos = 0;
_clientSendBuffer.WriteByte(ref pos, (byte)OpCodes.CreateRoom);
_clientSendBuffer.WriteInt(ref pos, maxServerPlayers);
_clientSendBuffer.WriteString(ref pos, serverName);
_clientSendBuffer.WriteBool(ref pos, isPublicServer);
_clientSendBuffer.WriteString(ref pos, extraServerData);
// If we have direct connect module, and our local IP isnt null, tell server. Only time local IP is null is on cellular networks, such as IOS and Android.
_clientSendBuffer.WriteBool(ref pos, _directConnectModule != null ? GetLocalIp() != null ? true : false : false);
if (_directConnectModule != null && GetLocalIp() != null)
{
_clientSendBuffer.WriteString(ref pos, GetLocalIp());
// Transport port will be NAT port + 1 for the proxy connections.
_directConnectModule.StartServer(useNATPunch ? _NATIP.Port + 1 : -1);
}
else
_clientSendBuffer.WriteString(ref pos, "0.0.0.0");
if (useNATPunch)
{
_clientSendBuffer.WriteBool(ref pos, true);
_clientSendBuffer.WriteInt(ref pos, 0);
}
else
{
_clientSendBuffer.WriteBool(ref pos, false);
_clientSendBuffer.WriteInt(ref pos, _directConnectModule == null ? 1 : _directConnectModule.SupportsNATPunch() ? _directConnectModule.GetTransportPort() : 1);
}
#if MIRROR_40_0_OR_NEWER
clientToServerTransport.ClientSend(new ArraySegment<byte>(_clientSendBuffer, 0, pos), 0);
#else
clientToServerTransport.ClientSend(0, new ArraySegment<byte>(_clientSendBuffer, 0, pos));
#endif
}
public override void ServerStop()
{
if (_isServer)
{
_isServer = false;
int pos = 0;
_clientSendBuffer.WriteByte(ref pos, (byte)OpCodes.LeaveRoom);
#if MIRROR_40_0_OR_NEWER
clientToServerTransport.ClientSend(new ArraySegment<byte>(_clientSendBuffer, 0, pos), 0);
#else
clientToServerTransport.ClientSend(0, new ArraySegment<byte>(_clientSendBuffer, 0, pos));
#endif
if (_directConnectModule != null)
_directConnectModule.StopServer();
var keys = new List<IPEndPoint>(_serverProxies.GetAllKeys());
for (int i = 0; i < keys.Count; i++)
{
_serverProxies.GetByFirst(keys[i]).Dispose();
_serverProxies.Remove(keys[i]);
}
}
}
public override Uri ServerUri()
{
UriBuilder builder = new UriBuilder
{
Scheme = "LRM",
Host = serverId.ToString()
};
return builder.Uri;
}
public override void Shutdown()
{
_isAuthenticated = false;
_isClient = false;
_isServer = false;
_connectedToRelay = false;
clientToServerTransport.Shutdown();
}
}
}

View file

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 16602a520793b6044894096e873bc28d
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,227 @@
using Mirror;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using UnityEngine;
using UnityEngine.Networking;
namespace LightReflectiveMirror
{
public partial class LightReflectiveMirrorTransport : Transport
{
public void RequestServerList(LRMRegions searchRegion = LRMRegions.Any)
{
if (_isAuthenticated && _connectedToRelay)
StartCoroutine(GetServerList(searchRegion));
else
Debug.Log("You must be connected to Relay to request server list!");
}
IEnumerator RelayConnect()
{
string url = $"http://{loadBalancerAddress}:{loadBalancerPort}/api/join/";
serverStatus = "Waiting for LLB...";
using (UnityWebRequest webRequest = UnityWebRequest.Get(url))
{
// Request and wait for the desired page.
webRequest.SetRequestHeader("x-Region", ((int)region).ToString());
webRequest.SetRequestHeader("Access-Control-Allow-Credentials", "true");
webRequest.SetRequestHeader("Access-Control-Allow-Headers", "Accept, X-Access-Token, X-Application-Name, X-Request-Sent-Time");
webRequest.SetRequestHeader("Access-Control-Allow-Methods", "GET, POST, OPTIONS");
webRequest.SetRequestHeader("Access-Control-Allow-Origin", "*");
yield return webRequest.SendWebRequest();
var result = webRequest.downloadHandler.text;
#if UNITY_2020_1_OR_NEWER
switch (webRequest.result)
{
case UnityWebRequest.Result.ConnectionError:
case UnityWebRequest.Result.DataProcessingError:
case UnityWebRequest.Result.ProtocolError:
Debug.LogWarning("LRM | Network Error while getting a relay to join from Load Balancer.");
break;
case UnityWebRequest.Result.Success:
var parsedAddress = JsonUtility.FromJson<RelayAddress>(result);
Connect(parsedAddress.address, parsedAddress.port);
endpointServerPort = parsedAddress.endpointPort;
break;
}
#else
if (webRequest.isNetworkError || webRequest.isHttpError)
{
Debug.LogWarning("LRM | Network Error while getting a relay to join from Load Balancer.");
}
else
{
// join here
var parsedAddress = JsonUtility.FromJson<RelayAddress>(result);
Connect(parsedAddress.address, parsedAddress.port);
endpointServerPort = parsedAddress.endpointPort;
}
#endif
}
}
IEnumerator JoinOtherRelayAndMatch(Room? roomValue, string ID)
{
var room = new Room();
// using load balancer, we NEED the server's relay address
if (roomValue.HasValue)
room = roomValue.Value;
else
{
_serverListUpdated = false;
RequestServerList();
yield return new WaitUntil(() => _serverListUpdated);
var foundRoom = GetServerForID(ID);
if (foundRoom.HasValue)
{
room = foundRoom.Value;
}
else
{
Debug.LogWarning("LRM | Client tried to join a server that does not exist!");
OnClientDisconnected?.Invoke();
yield break;
}
}
// Wait for disconnection
DisconnectFromRelay();
while (IsAuthenticated())
yield return null;
endpointServerPort = room.relayInfo.endpointPort;
Connect(room.relayInfo.address, room.relayInfo.port);
while (!IsAuthenticated())
yield return null;
int pos = 0;
_directConnected = false;
_clientSendBuffer.WriteByte(ref pos, (byte)OpCodes.JoinServer);
_clientSendBuffer.WriteString(ref pos, room.serverId);
_clientSendBuffer.WriteBool(ref pos, _directConnectModule != null);
string local = GetLocalIp();
_clientSendBuffer.WriteString(ref pos, local ?? "0.0.0.0");
_isClient = true;
#if MIRROR_40_0_OR_NEWER
clientToServerTransport.ClientSend(new System.ArraySegment<byte>(_clientSendBuffer, 0, pos), 0);
#else
clientToServerTransport.ClientSend(0, new System.ArraySegment<byte>(_clientSendBuffer, 0, pos));
#endif
}
IEnumerator GetServerList(LRMRegions region)
{
if (!useLoadBalancer)
{
string uri = $"http://{serverIP}:{endpointServerPort}/api/compressed/servers";
using (UnityWebRequest webRequest = UnityWebRequest.Get(uri))
{
webRequest.SetRequestHeader("Access-Control-Allow-Credentials", "true");
webRequest.SetRequestHeader("Access-Control-Allow-Headers", "Accept, X-Access-Token, X-Application-Name, X-Request-Sent-Time");
webRequest.SetRequestHeader("Access-Control-Allow-Methods", "GET, POST, OPTIONS");
webRequest.SetRequestHeader("Access-Control-Allow-Origin", "*");
// Request and wait for the desired page.
yield return webRequest.SendWebRequest();
var result = webRequest.downloadHandler.text;
#if UNITY_2020_1_OR_NEWER
switch (webRequest.result)
{
case UnityWebRequest.Result.ConnectionError:
case UnityWebRequest.Result.DataProcessingError:
case UnityWebRequest.Result.ProtocolError:
Debug.LogWarning("LRM | Network Error while retreiving the server list!");
break;
case UnityWebRequest.Result.Success:
relayServerList?.Clear();
relayServerList = JsonUtilityHelper.FromJson<Room>(result.Decompress()).ToList();
serverListUpdated?.Invoke();
break;
}
#else
if (webRequest.isNetworkError || webRequest.isHttpError)
{
Debug.LogWarning("LRM | Network Error while retreiving the server list!");
}
else
{
relayServerList?.Clear();
relayServerList = JsonUtilityHelper.FromJson<Room>(result.Decompress()).ToList();
serverListUpdated?.Invoke();
}
#endif
}
}
else // get master list from load balancer
{
yield return StartCoroutine(RetrieveMasterServerListFromLoadBalancer(region));
}
}
/// <summary>
/// Gets master list from the LB.
/// This can be optimized but for now it is it's
/// own separate method, so i can understand wtf is going on :D
/// </summary>
/// <returns></returns>
IEnumerator RetrieveMasterServerListFromLoadBalancer(LRMRegions region)
{
string uri = $"http://{loadBalancerAddress}:{loadBalancerPort}/api/masterlist/";
using (UnityWebRequest webRequest = UnityWebRequest.Get(uri))
{
webRequest.SetRequestHeader("x-Region", ((int)region).ToString());
// Request and wait for the desired page.
yield return webRequest.SendWebRequest();
var result = webRequest.downloadHandler.text;
#if UNITY_2020_1_OR_NEWER
switch (webRequest.result)
{
case UnityWebRequest.Result.ConnectionError:
case UnityWebRequest.Result.DataProcessingError:
case UnityWebRequest.Result.ProtocolError:
Debug.LogWarning("LRM | Network Error while retreiving the server list!");
break;
case UnityWebRequest.Result.Success:
relayServerList?.Clear();
relayServerList = JsonUtilityHelper.FromJson<Room>(result).ToList();
serverListUpdated?.Invoke();
_serverListUpdated = true;
break;
}
#else
if (webRequest.isNetworkError || webRequest.isHttpError)
{
Debug.LogWarning("LRM | Network Error while retreiving the server list!");
}
else
{
relayServerList?.Clear();
relayServerList = JsonUtilityHelper.FromJson<Room>(result).ToList();
serverListUpdated?.Invoke();
_serverListUpdated = true;
}
#endif
}
}
}
}

View file

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 4ce47885d25567b4a8c0d6f3727de7f3
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,74 @@
using Mirror;
using System.Collections.Generic;
using System.Net;
using System.Net.Sockets;
using UnityEngine.Events;
namespace LightReflectiveMirror
{
public partial class LightReflectiveMirrorTransport : Transport
{
// Connection/auth variables
public Transport clientToServerTransport;
public string serverIP = null;
public ushort serverPort = 7777;
public ushort endpointServerPort = 8080;
public float heartBeatInterval = 3;
public bool connectOnAwake = true;
public string authenticationKey = "Secret Auth Key";
public UnityEvent disconnectedFromRelay;
public UnityEvent connectedToRelay;
// NAT Puncher variables
public bool useNATPunch = false;
public int NATPunchtroughPort = -1;
private const int NAT_PUNCH_ATTEMPTS = 3;
// LLB variables (LRM Load Balancer)
public bool useLoadBalancer = false;
public ushort loadBalancerPort = 7070;
public string loadBalancerAddress = null;
// Server hosting variables
public string serverName = "My awesome server!";
public string extraServerData = "Map 1";
public int maxServerPlayers = 10;
public bool isPublicServer = true;
private const string LOCALHOST = "127.0.0.1";
// Server list variables
public UnityEvent serverListUpdated;
public List<Room> relayServerList { private set; get; } = new List<Room>();
// Current Server Information
public string serverStatus = "Not Started.";
public string serverId = string.Empty;
private LRMDirectConnectModule _directConnectModule;
public LRMRegions region = LRMRegions.NorthAmerica;
private byte[] _clientSendBuffer;
private bool _connectedToRelay = false;
private bool _isClient = false;
private bool _isServer = false;
private bool _directConnected = false;
private bool _isAuthenticated = false;
private int _currentMemberId;
private bool _callbacksInitialized = false;
private string _cachedHostID;
private UdpClient _NATPuncher;
private IPEndPoint _NATIP;
private IPEndPoint _relayPuncherIP;
private byte[] _punchData = new byte[1] { 1 };
private IPEndPoint _directConnectEndpoint;
private SocketProxy _clientProxy;
private BiDictionary<IPEndPoint, SocketProxy> _serverProxies = new BiDictionary<IPEndPoint, SocketProxy>();
private BiDictionary<int, int> _connectedRelayClients = new BiDictionary<int, int>();
private BiDictionary<int, int> _connectedDirectClients = new BiDictionary<int, int>();
private bool _serverListUpdated = false;
}
public enum LRMRegions { Any, NorthAmerica, SouthAmerica, Europe, Asia, Africa, Oceania }
}

View file

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: f823917eee8f54742b6b03e520f05730
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,488 @@
using kcp2k;
using Mirror;
using Mirror.SimpleWeb;
using System;
using System.Collections.Generic;
using System.Net;
using System.Net.Sockets;
using UnityEngine;
namespace LightReflectiveMirror
{
[DefaultExecutionOrder(1001)]
public partial class LightReflectiveMirrorTransport : Transport
{
public bool IsAuthenticated() => _isAuthenticated;
private void Awake()
{
if (Application.platform == RuntimePlatform.WebGLPlayer)
useNATPunch = false;
else
_directConnectModule = GetComponent<LRMDirectConnectModule>();
if (clientToServerTransport is LightReflectiveMirrorTransport)
throw new Exception("Haha real funny... Use a different transport.");
if (_directConnectModule != null)
{
if (useNATPunch && !_directConnectModule.SupportsNATPunch())
{
Debug.LogWarning("LRM | NATPunch is turned on but the transport used does not support it. It will be disabled.");
useNATPunch = false;
}
}
SetupCallbacks();
if (connectOnAwake)
ConnectToRelay();
InvokeRepeating(nameof(SendHeartbeat), heartBeatInterval, heartBeatInterval);
}
private void SetupCallbacks()
{
if (_callbacksInitialized)
return;
_callbacksInitialized = true;
clientToServerTransport.OnClientConnected = OnConnectedToRelay;
clientToServerTransport.OnClientDataReceived = DataReceived;
clientToServerTransport.OnClientDisconnected = Disconnected;
clientToServerTransport.OnClientError = (e) => Debug.LogException(e);
}
private void Disconnected()
{
_connectedToRelay = false;
_isAuthenticated = false;
disconnectedFromRelay?.Invoke();
serverStatus = "Disconnected from relay.";
}
private void OnConnectedToRelay()
{
_connectedToRelay = true;
connectedToRelay?.Invoke();
}
public void ConnectToRelay()
{
if (!useLoadBalancer)
{
if (!_connectedToRelay)
{
Connect(serverIP, serverPort);
}
else
{
Debug.LogWarning("LRM | Already connected to relay!");
}
}
else
{
if (!_connectedToRelay)
{
StartCoroutine(RelayConnect());
}
else
{
Debug.LogWarning("LRM | Already connected to relay!");
}
}
}
/// <summary>
/// Connects to the desired relay
/// </summary>
/// <param name="serverIP"></param>
private void Connect(string serverIP, ushort port = 7777)
{
// need to implement custom port
if (clientToServerTransport is LightReflectiveMirrorTransport)
throw new Exception("LRM | Client to Server Transport cannot be LRM.");
SetTransportPort(port);
this.serverIP = serverIP;
serverStatus = "Connecting to relay...";
_clientSendBuffer = new byte[clientToServerTransport.GetMaxPacketSize()];
clientToServerTransport.ClientConnect(serverIP);
}
public void DisconnectFromRelay()
{
if (IsAuthenticated())
{
clientToServerTransport.ClientDisconnect();
}
}
private void SendHeartbeat()
{
if (_connectedToRelay)
{
// Send a blank message with just the opcode 200, which is heartbeat
int pos = 0;
_clientSendBuffer.WriteByte(ref pos, 200);
#if MIRROR_40_0_OR_NEWER
clientToServerTransport.ClientSend(new ArraySegment<byte>(_clientSendBuffer, 0, pos), 0);
#else
clientToServerTransport.ClientSend(0, new ArraySegment<byte>(_clientSendBuffer, 0, pos));
#endif
// If NAT Puncher is initialized, send heartbeat on that as well.
try
{
if (_NATPuncher != null)
_NATPuncher.Send(new byte[] { 0 }, 1, _relayPuncherIP);
}
catch (Exception e)
{
print(e);
}
// Check if any server-side proxies havent been used in 10 seconds, and timeout if so.
var keys = new List<IPEndPoint>(_serverProxies.GetAllKeys());
for (int i = 0; i < keys.Count; i++)
{
if (DateTime.Now.Subtract(_serverProxies.GetByFirst(keys[i]).lastInteractionTime).TotalSeconds > 10)
{
_serverProxies.GetByFirst(keys[i]).Dispose();
_serverProxies.Remove(keys[i]);
}
}
}
}
private void DataReceived(ArraySegment<byte> segmentData, int channel)
{
try
{
var data = segmentData.Array;
int pos = segmentData.Offset;
// Read the opcode of the incoming data, this allows us to know what its used for.
OpCodes opcode = (OpCodes)data.ReadByte(ref pos);
switch (opcode)
{
case OpCodes.Authenticated:
// Server authenticated us! That means we are fully ready to host and join servers.
serverStatus = "Authenticated! Good to go!";
_isAuthenticated = true;
RequestServerList();
break;
case OpCodes.AuthenticationRequest:
// Server requested that we send an authentication request, lets send our auth key.
serverStatus = "Sent authentication to relay...";
SendAuthKey();
break;
case OpCodes.GetData:
// Someone sent us a packet from their mirror over the relay
var recvData = data.ReadBytes(ref pos);
// If we are the server and the client is registered, invoke the callback
if (_isServer)
{
if (_connectedRelayClients.TryGetByFirst(data.ReadInt(ref pos), out int clientID))
OnServerDataReceived?.Invoke(clientID, new ArraySegment<byte>(recvData), channel);
}
// If we are the client, invoke the callback
if (_isClient)
OnClientDataReceived?.Invoke(new ArraySegment<byte>(recvData), channel);
break;
case OpCodes.ServerLeft:
// Called when we were kicked, or server was closed.
if (_isClient)
{
_isClient = false;
OnClientDisconnected?.Invoke();
}
break;
case OpCodes.PlayerDisconnected:
// Called when another player left the room.
if (_isServer)
{
// Get their client ID and invoke the mirror callback
int user = data.ReadInt(ref pos);
if (_connectedRelayClients.TryGetByFirst(user, out int clientID))
{
OnServerDisconnected?.Invoke(clientID);
_connectedRelayClients.Remove(user);
}
}
break;
case OpCodes.RoomCreated:
// We successfully created the room, the server also gave us the serverId of the room!
serverId = data.ReadString(ref pos);
break;
case OpCodes.ServerJoined:
// Called when a player joins the room or when we joined a room.
int clientId = data.ReadInt(ref pos);
if (_isClient)
{
// We successfully joined a room, let mirror know.
OnClientConnected?.Invoke();
}
if (_isServer)
{
// A client joined our room, let mirror know and setup their ID in the dictionary.
_connectedRelayClients.Add(clientId, _currentMemberId);
OnServerConnected?.Invoke(_currentMemberId);
_currentMemberId++;
}
break;
case OpCodes.DirectConnectIP:
// Either a client is trying to join us via NAT Punch, or we are trying to join a host over NAT punch/Direct connect.
var ip = data.ReadString(ref pos);
int port = data.ReadInt(ref pos);
bool attemptNatPunch = data.ReadBool(ref pos);
_directConnectEndpoint = new IPEndPoint(IPAddress.Parse(ip), port);
// Both client and server will send data to each other to open the hole.
if (useNATPunch && attemptNatPunch)
{
StartCoroutine(NATPunch(_directConnectEndpoint));
}
if (!_isServer)
{
// We arent the server, so lets tell the direct connect module to attempt a connection and initializing our middle man socket.
if (_clientProxy == null && useNATPunch && attemptNatPunch)
{
_clientProxy = new SocketProxy(_NATIP.Port - 1);
_clientProxy.dataReceived += ClientProcessProxyData;
}
if (useNATPunch && attemptNatPunch)
{
if (ip == LOCALHOST)
_directConnectModule.JoinServer(LOCALHOST, port + 1);
else
_directConnectModule.JoinServer(LOCALHOST, _NATIP.Port - 1);
}
else
_directConnectModule.JoinServer(ip, port);
}
break;
case OpCodes.RequestNATConnection:
// Called when the LRM node would like us to establish a NAT puncher connection. Its safe to ignore if NAT punch is disabled.
if (useNATPunch && GetLocalIp() != null && _directConnectModule != null)
{
byte[] initalData = new byte[150];
int sendPos = 0;
initalData.WriteBool(ref sendPos, true);
initalData.WriteString(ref sendPos, data.ReadString(ref pos));
NATPunchtroughPort = data.ReadInt(ref pos);
if (_NATPuncher == null)
{
_NATPuncher = new UdpClient { ExclusiveAddressUse = false };
while (true)
{
try
{
_NATIP = new IPEndPoint(IPAddress.Parse(GetLocalIp()), UnityEngine.Random.Range(16000, 17000));
_NATPuncher.Client.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.ReuseAddress, true);
_NATPuncher.Client.Bind(_NATIP);
break;
}
catch { } // Binding port is in use, keep trying :P
}
}
if (!IPAddress.TryParse(serverIP, out IPAddress serverAddr))
serverAddr = Dns.GetHostEntry(serverIP).AddressList[0];
_relayPuncherIP = new IPEndPoint(serverAddr, NATPunchtroughPort);
for (int attempts = 0; attempts < NAT_PUNCH_ATTEMPTS; attempts++)
_NATPuncher.Send(initalData, sendPos, _relayPuncherIP);
_NATPuncher.BeginReceive(new AsyncCallback(RecvData), _NATPuncher);
}
break;
}
}
catch (Exception e) { print(e); }
}
public void SetTransportPort(ushort port)
{
if (clientToServerTransport is KcpTransport kcp)
kcp.Port = port;
if (clientToServerTransport is TelepathyTransport telepathy)
telepathy.port = port;
if (clientToServerTransport is SimpleWebTransport swt)
swt.port = port;
}
public void UpdateRoomName(string newServerName = "My Awesome Server!")
{
if (_isServer)
{
int pos = 0;
_clientSendBuffer.WriteByte(ref pos, (byte)OpCodes.UpdateRoomData);
_clientSendBuffer.WriteBool(ref pos, true);
_clientSendBuffer.WriteString(ref pos, newServerName);
_clientSendBuffer.WriteBool(ref pos, false);
_clientSendBuffer.WriteBool(ref pos, false);
_clientSendBuffer.WriteBool(ref pos, false);
#if MIRROR_40_0_OR_NEWER
clientToServerTransport.ClientSend(new ArraySegment<byte>(_clientSendBuffer, 0, pos), 0);
#else
clientToServerTransport.ClientSend(0, new ArraySegment<byte>(_clientSendBuffer, 0, pos));
#endif
}
}
public void UpdateRoomData(string newServerData = "Extra Data!")
{
if (_isServer)
{
int pos = 0;
_clientSendBuffer.WriteByte(ref pos, (byte)OpCodes.UpdateRoomData);
_clientSendBuffer.WriteBool(ref pos, false);
_clientSendBuffer.WriteBool(ref pos, true);
_clientSendBuffer.WriteString(ref pos, newServerData);
_clientSendBuffer.WriteBool(ref pos, false);
_clientSendBuffer.WriteBool(ref pos, false);
#if MIRROR_40_0_OR_NEWER
clientToServerTransport.ClientSend(new ArraySegment<byte>(_clientSendBuffer, 0, pos), 0);
#else
clientToServerTransport.ClientSend(0, new ArraySegment<byte>(_clientSendBuffer, 0, pos));
#endif
}
}
public void UpdateRoomVisibility(bool isPublic = true)
{
if (_isServer)
{
int pos = 0;
_clientSendBuffer.WriteByte(ref pos, (byte)OpCodes.UpdateRoomData);
_clientSendBuffer.WriteBool(ref pos, false);
_clientSendBuffer.WriteBool(ref pos, false);
_clientSendBuffer.WriteBool(ref pos, true);
_clientSendBuffer.WriteBool(ref pos, isPublic);
_clientSendBuffer.WriteBool(ref pos, false);
#if MIRROR_40_0_OR_NEWER
clientToServerTransport.ClientSend(new ArraySegment<byte>(_clientSendBuffer, 0, pos), 0);
#else
clientToServerTransport.ClientSend(0, new ArraySegment<byte>(_clientSendBuffer, 0, pos));
#endif
}
}
public void UpdateRoomPlayerCount(int maxPlayers = 16)
{
if (_isServer)
{
int pos = 0;
_clientSendBuffer.WriteByte(ref pos, (byte)OpCodes.UpdateRoomData);
_clientSendBuffer.WriteBool(ref pos, false);
_clientSendBuffer.WriteBool(ref pos, false);
_clientSendBuffer.WriteBool(ref pos, false);
_clientSendBuffer.WriteBool(ref pos, true);
_clientSendBuffer.WriteInt(ref pos, maxPlayers);
#if MIRROR_40_0_OR_NEWER
clientToServerTransport.ClientSend(new ArraySegment<byte>(_clientSendBuffer, 0, pos), 0);
#else
clientToServerTransport.ClientSend(0, new ArraySegment<byte>(_clientSendBuffer, 0, pos));
#endif
}
}
private Room? GetServerForID(string serverID)
{
for (int i = 0; i < relayServerList.Count; i++)
{
if (relayServerList[i].serverId == serverID)
return relayServerList[i];
}
return null;
}
private void SendAuthKey()
{
int pos = 0;
_clientSendBuffer.WriteByte(ref pos, (byte)OpCodes.AuthenticationResponse);
_clientSendBuffer.WriteString(ref pos, authenticationKey);
#if MIRROR_40_0_OR_NEWER
clientToServerTransport.ClientSend(new ArraySegment<byte>(_clientSendBuffer, 0, pos), 0);
#else
clientToServerTransport.ClientSend(0, new ArraySegment<byte>(_clientSendBuffer, 0, pos));
#endif
}
public enum OpCodes
{
Default = 0, RequestID = 1, JoinServer = 2, SendData = 3, GetID = 4, ServerJoined = 5, GetData = 6, CreateRoom = 7, ServerLeft = 8, PlayerDisconnected = 9, RoomCreated = 10,
LeaveRoom = 11, KickPlayer = 12, AuthenticationRequest = 13, AuthenticationResponse = 14, Authenticated = 17, UpdateRoomData = 18, ServerConnectionData = 19, RequestNATConnection = 20,
DirectConnectIP = 21
}
private static string GetLocalIp()
{
var host = Dns.GetHostEntry(Dns.GetHostName());
foreach (var ip in host.AddressList)
{
if (ip.AddressFamily == AddressFamily.InterNetwork)
{
return ip.ToString();
}
}
return null;
}
}
[Serializable]
public struct Room
{
public string serverName;
public int maxPlayers;
public string serverId;
public string serverData;
public int hostId;
public List<int> clients;
public int currentPlayers;
public RelayAddress relayInfo;
}
[Serializable]
public struct RelayAddress
{
public ushort port;
public ushort endpointPort;
public string address;
public LRMRegions serverRegion;
}
}

View file

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 7064b1b1d0671194baf55fa8d5f564d6
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {fileID: 2800000, guid: f4000c50bdad7994f8425330b81e5d87, type: 3}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 48c208983412ff24abf68dda3691fa07
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.9 KiB

View file

@ -0,0 +1,92 @@
fileFormatVersion: 2
guid: f4000c50bdad7994f8425330b81e5d87
TextureImporter:
internalIDToNameTable: []
externalObjects: {}
serializedVersion: 11
mipmaps:
mipMapMode: 0
enableMipMap: 1
sRGBTexture: 1
linearTexture: 0
fadeOut: 0
borderMipMap: 0
mipMapsPreserveCoverage: 0
alphaTestReferenceValue: 0.5
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: 0.25
normalMapFilter: 0
isReadable: 0
streamingMipmaps: 0
streamingMipmapsPriority: 0
grayScaleToAlpha: 0
generateCubemap: 6
cubemapConvolution: 0
seamlessCubemap: 0
textureFormat: 1
maxTextureSize: 2048
textureSettings:
serializedVersion: 2
filterMode: -1
aniso: -1
mipBias: -100
wrapU: -1
wrapV: -1
wrapW: -1
nPOTScale: 1
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: 0.5, y: 0.5}
spritePixelsToUnits: 100
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spriteGenerateFallbackPhysicsShape: 1
alphaUsage: 1
alphaIsTransparency: 0
spriteTessellationDetail: -1
textureType: 0
textureShape: 1
singleChannelComponent: 0
maxTextureSizeSet: 0
compressionQualitySet: 0
textureFormatSet: 0
applyGammaDecoding: 0
platformSettings:
- serializedVersion: 3
buildTarget: DefaultTexturePlatform
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
spriteSheet:
serializedVersion: 2
sprites: []
outline: []
physicsShape: []
bones: []
spriteID:
internalID: 0
vertices: []
indices:
edges: []
weights: []
secondaryTextures: []
spritePackingTag:
pSDRemoveMatte: 0
pSDShowRemoveMatteOption: 0
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,68 @@
using System;
using System.Collections;
using System.Collections.Generic;
using System.Net;
using System.Net.Sockets;
using UnityEngine;
namespace LightReflectiveMirror
{
// This class handles the proxying from punched socket to transport.
public class SocketProxy
{
public DateTime lastInteractionTime;
public Action<IPEndPoint, byte[]> dataReceived;
UdpClient _udpClient;
IPEndPoint _recvEndpoint = new IPEndPoint(IPAddress.Any, 0);
IPEndPoint _remoteEndpoint;
bool _clientInitialRecv = false;
public SocketProxy(int port, IPEndPoint remoteEndpoint)
{
_udpClient = new UdpClient();
_udpClient.Connect(new IPEndPoint(IPAddress.Loopback, port));
_udpClient.BeginReceive(new AsyncCallback(RecvData), _udpClient);
lastInteractionTime = DateTime.Now;
// Clone it so when main socket recvies new data, it wont switcheroo on us.
_remoteEndpoint = new IPEndPoint(remoteEndpoint.Address, remoteEndpoint.Port);
}
public SocketProxy(int port)
{
_udpClient = new UdpClient(port);
_udpClient.BeginReceive(new AsyncCallback(RecvData), _udpClient);
lastInteractionTime = DateTime.Now;
}
public void RelayData(byte[] data, int length)
{
_udpClient.Send(data, length);
lastInteractionTime = DateTime.Now;
}
public void ClientRelayData(byte[] data, int length)
{
if (_clientInitialRecv)
{
_udpClient.Send(data, length, _recvEndpoint);
lastInteractionTime = DateTime.Now;
}
}
public void Dispose()
{
_udpClient.Dispose();
}
void RecvData(IAsyncResult result)
{
byte[] data = _udpClient.EndReceive(result, ref _recvEndpoint);
_udpClient.BeginReceive(new AsyncCallback(RecvData), _udpClient);
_clientInitialRecv = true;
lastInteractionTime = DateTime.Now;
dataReceived?.Invoke(_remoteEndpoint, data);
}
}
}

View file

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: f482ce0c4da51924ba033e827aca8f28
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,9 @@
{
"name": "com.derek-r-s.lrm",
"version": "0.10.120",
"displayName": "Light-Reflective-Mirror",
"description": "Light Reflective Mirror is a transport for Mirror Networking which relays network traffic through your own servers.",
"unity": "2019.4",
"dependencies": {},
"keywords": []
}

View file

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 09ee2ee51265449fea67160707630572
PackageManifestImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: db0d1e5a0697e3c40b7f932deae9a5dc
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

8
Assets/Resources.meta Normal file
View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: a63e6d0da7952cf4587224c5f398b98a
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 6edd9d23359aa864f8cce72aff170b64
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 8e4d276109dbee44cbb565864ad1677c
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: eb433dc36548834438e4a8eb2188efc6
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,33 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 8
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: OutdoorHDRI028_16K-HDR
m_Shader: {fileID: 103, guid: 0000000000000000f000000000000000, type: 0}
m_ValidKeywords: []
m_InvalidKeywords: []
m_LightmapFlags: 4
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: -1
stringTagMap: {}
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- _Tex:
m_Texture: {fileID: 8900000, guid: 20f859d6e9d585949817feade868e80c, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- _Exposure: 1
- _Rotation: 0
m_Colors:
- _Tint: {r: 0.5, g: 0.5, b: 0.5, a: 0.5}
m_BuildTextureStacks: []

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: c8b22a7286067d34590384523cc4438d
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 9835b85fccf374545918f9658c14d1fb
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 8900000
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,39 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!84 &8400000
RenderTexture:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: cubemapCapture
m_ImageContentsHash:
serializedVersion: 2
Hash: 00000000000000000000000000000000
m_ForcedFallbackFormat: 4
m_DownscaleFallback: 0
m_IsAlphaChannelOptional: 0
serializedVersion: 5
m_Width: 4096
m_Height: 4096
m_AntiAliasing: 8
m_MipCount: -1
m_DepthStencilFormat: 94
m_ColorFormat: 8
m_MipMap: 0
m_GenerateMips: 1
m_SRGB: 0
m_UseDynamicScale: 0
m_BindMS: 0
m_EnableCompatibleFormat: 1
m_TextureSettings:
serializedVersion: 2
m_FilterMode: 1
m_Aniso: 0
m_MipBias: 0
m_WrapU: 1
m_WrapV: 1
m_WrapW: 1
m_Dimension: 4
m_VolumeDepth: 1
m_ShadowSamplingMode: 2

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: bb52074d8615e184e8e8d49385f06927
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 8400000
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,39 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!84 &8400000
RenderTexture:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: cubemapImage
m_ImageContentsHash:
serializedVersion: 2
Hash: 00000000000000000000000000000000
m_ForcedFallbackFormat: 4
m_DownscaleFallback: 0
m_IsAlphaChannelOptional: 0
serializedVersion: 5
m_Width: 4096
m_Height: 2048
m_AntiAliasing: 8
m_MipCount: -1
m_DepthStencilFormat: 94
m_ColorFormat: 8
m_MipMap: 0
m_GenerateMips: 1
m_SRGB: 0
m_UseDynamicScale: 0
m_BindMS: 0
m_EnableCompatibleFormat: 1
m_TextureSettings:
serializedVersion: 2
m_FilterMode: 1
m_Aniso: 0
m_MipBias: 0
m_WrapU: 1
m_WrapV: 1
m_WrapW: 1
m_Dimension: 2
m_VolumeDepth: 1
m_ShadowSamplingMode: 2

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 8173ba2767e6aa94fa08cef4b1e6ae7a
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 8400000
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 88a4492cd2642d546a9c6b3bd277ca8e
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

Binary file not shown.

After

Width:  |  Height:  |  Size: 98 KiB

View file

@ -0,0 +1,122 @@
fileFormatVersion: 2
guid: 2bb60b1e8a958b94faa061e44e4f79b3
TextureImporter:
internalIDToNameTable: []
externalObjects: {}
serializedVersion: 11
mipmaps:
mipMapMode: 0
enableMipMap: 0
sRGBTexture: 1
linearTexture: 0
fadeOut: 0
borderMipMap: 0
mipMapsPreserveCoverage: 0
alphaTestReferenceValue: 0.5
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: 0.25
normalMapFilter: 0
isReadable: 0
streamingMipmaps: 0
streamingMipmapsPriority: 0
vTOnly: 0
ignoreMasterTextureLimit: 0
grayScaleToAlpha: 0
generateCubemap: 6
cubemapConvolution: 0
seamlessCubemap: 0
textureFormat: 1
maxTextureSize: 2048
textureSettings:
serializedVersion: 2
filterMode: 1
aniso: 1
mipBias: 0
wrapU: 1
wrapV: 1
wrapW: 0
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 1
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: 0.5, y: 0.5}
spritePixelsToUnits: 100
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spriteGenerateFallbackPhysicsShape: 1
alphaUsage: 1
alphaIsTransparency: 1
spriteTessellationDetail: -1
textureType: 8
textureShape: 1
singleChannelComponent: 0
flipbookRows: 1
flipbookColumns: 1
maxTextureSizeSet: 0
compressionQualitySet: 0
textureFormatSet: 0
ignorePngGamma: 0
applyGammaDecoding: 0
platformSettings:
- serializedVersion: 3
buildTarget: DefaultTexturePlatform
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
- serializedVersion: 3
buildTarget: Standalone
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
- serializedVersion: 3
buildTarget: Server
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
spriteSheet:
serializedVersion: 2
sprites: []
outline: []
physicsShape: []
bones: []
spriteID: 5e97eb03825dee720800000000000000
internalID: 0
vertices: []
indices:
edges: []
weights: []
secondaryTextures: []
nameFileIdTable: {}
spritePackingTag:
pSDRemoveMatte: 0
pSDShowRemoveMatteOption: 0
userData:
assetBundleName:
assetBundleVariant:

Binary file not shown.

After

Width:  |  Height:  |  Size: 236 KiB

View file

@ -0,0 +1,122 @@
fileFormatVersion: 2
guid: 7baed0c50d18e4f4881ed7881955cfce
TextureImporter:
internalIDToNameTable: []
externalObjects: {}
serializedVersion: 11
mipmaps:
mipMapMode: 0
enableMipMap: 0
sRGBTexture: 1
linearTexture: 0
fadeOut: 0
borderMipMap: 0
mipMapsPreserveCoverage: 0
alphaTestReferenceValue: 0.5
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: 0.25
normalMapFilter: 0
isReadable: 0
streamingMipmaps: 0
streamingMipmapsPriority: 0
vTOnly: 0
ignoreMasterTextureLimit: 0
grayScaleToAlpha: 0
generateCubemap: 6
cubemapConvolution: 0
seamlessCubemap: 0
textureFormat: 1
maxTextureSize: 2048
textureSettings:
serializedVersion: 2
filterMode: 1
aniso: 1
mipBias: 0
wrapU: 1
wrapV: 1
wrapW: 0
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 1
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: 0.5, y: 0.5}
spritePixelsToUnits: 100
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spriteGenerateFallbackPhysicsShape: 1
alphaUsage: 1
alphaIsTransparency: 1
spriteTessellationDetail: -1
textureType: 8
textureShape: 1
singleChannelComponent: 0
flipbookRows: 1
flipbookColumns: 1
maxTextureSizeSet: 0
compressionQualitySet: 0
textureFormatSet: 0
ignorePngGamma: 0
applyGammaDecoding: 0
platformSettings:
- serializedVersion: 3
buildTarget: DefaultTexturePlatform
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
- serializedVersion: 3
buildTarget: Standalone
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
- serializedVersion: 3
buildTarget: Server
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
spriteSheet:
serializedVersion: 2
sprites: []
outline: []
physicsShape: []
bones: []
spriteID: 5e97eb03825dee720800000000000000
internalID: 0
vertices: []
indices:
edges: []
weights: []
secondaryTextures: []
nameFileIdTable: {}
spritePackingTag:
pSDRemoveMatte: 0
pSDShowRemoveMatteOption: 0
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: db89945b187dcc14f94e2f2cd75abed6
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,187 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 8
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: CustomLightTest
m_Shader: {fileID: 4800000, guid: 933532a4fcc9baf4fa0491de14d08ed7, type: 3}
m_ValidKeywords: []
m_InvalidKeywords: []
m_LightmapFlags: 4
m_EnableInstancingVariants: 1
m_DoubleSidedGI: 0
m_CustomRenderQueue: -1
stringTagMap:
RenderType: Opaque
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- MainTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- Mask_R_Emission:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BaseMap:
m_Texture: {fileID: 2800000, guid: aa6fb989189ddee4b8127e71c11ae661, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _Base_Map:
m_Texture: {fileID: 2800000, guid: 5f5aeaac0e738ed49a32e8898557ed0e, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BumpMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailAlbedoMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailMask:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailNormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DiffuseTexture:
m_Texture: {fileID: 2800000, guid: aa6fb989189ddee4b8127e71c11ae661, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _EmissionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _HeightMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MainTex:
m_Texture: {fileID: 2800000, guid: aa6fb989189ddee4b8127e71c11ae661, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MetalicMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MetallicGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _NormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _Normal_Map:
m_Texture: {fileID: 2800000, guid: 65f468cc591eb0044b729109c1e7b3a9, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _OcclusionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _ParallaxMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _SpecGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_Lightmaps:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_LightmapsInd:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_ShadowMasks:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- Brightness_Rim: 2
- MAIN_LIGHT_CALCULATE_SHADOWS: 0
- Rim_Power: 5
- Toon_Ramp_Offset: 0.5
- Toon_Ramp_Smoothness: 0
- _ADDITIONAL_LIGHTS: 1
- _ADDITIONAL_LIGHT_SHADOWS: 1
- _Albedo: 0.3
- _AlphaClip: 0
- _Ambient_Occlusion: 0
- _Blend: 0
- _BumpScale: 1
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _Cull: 2
- _Cutoff: 0.5
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DstBlend: 0
- _EdgeDistanceAttenuation: 0.1
- _EdgeRim: 0.21
- _EdgeRimOffset: 1.08
- _EdgeShadowAttenuation: 1.86
- _EdgeSpecular: 0.1
- _EdgeSpecularOffset: 0
- _Emission: 0
- _EnvironmentReflections: 1
- _GlossMapScale: 0
- _Glossiness: 0
- _GlossyReflections: 0
- _MAIN_LIGHT_SHADOWS: 1
- _MAIN_LIGHT_SHADOWS_CASCADE: 1
- _Metallic: 0
- _Normal_Strength: 1.08
- _OcclusionStrength: 1
- _Offset: 0
- _Parallax: 0.005
- _QueueControl: 0
- _QueueOffset: 0
- _ReceiveShadows: 1
- _RimThreshold: 1
- _SHADOWS_SOFT: 1
- _SHADOW_SOFT: 1
- _Smoothness: 0.552
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _Surface: 0
- _WorkflowMode: 1
- _ZWrite: 1
m_Colors:
- Toon_Ramp_Tint: {r: 0.34117648, g: 0.34117648, b: 0.34117648, a: 1}
- _BaseColor: {r: 1, g: 1, b: 1, a: 1}
- _BaseMapColor: {r: 1, g: 1, b: 1, a: 0}
- _Color: {r: 1, g: 1, b: 1, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _EmissionMapColor: {r: 0, g: 0, b: 0, a: 0}
- _Offset: {r: 0, g: 0, b: 0, a: 0}
- _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1}
- _Tiling: {r: 1, g: 1, b: 0, a: 0}
m_BuildTextureStacks: []
--- !u!114 &6894510991190069626
MonoBehaviour:
m_ObjectHideFlags: 11
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3}
m_Name:
m_EditorClassIdentifier:
version: 5

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: b81129970f92618419a1a41aa6a2e827
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,205 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 8
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: CustomToonLightTest
m_Shader: {fileID: -6465566751694194690, guid: b2f2e076036fbd64ab9dc2fd8d6c7e4e,
type: 3}
m_ValidKeywords: []
m_InvalidKeywords: []
m_LightmapFlags: 4
m_EnableInstancingVariants: 1
m_DoubleSidedGI: 0
m_CustomRenderQueue: -1
stringTagMap: {}
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- MainTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- Mask_R_Emission:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BaseMap:
m_Texture: {fileID: 2800000, guid: aa6fb989189ddee4b8127e71c11ae661, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _Base_Map:
m_Texture: {fileID: 0}
m_Scale: {x: 10, y: 10}
m_Offset: {x: 0, y: 0}
- _BumpMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailAlbedoMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailMask:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailNormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DiffuseTexture:
m_Texture: {fileID: 2800000, guid: aa6fb989189ddee4b8127e71c11ae661, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _EmissionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _HeightMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MainTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MetalicMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MetallicGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _Nomal:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _NormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _Normal_Map:
m_Texture: {fileID: 0}
m_Scale: {x: 10, y: 10}
m_Offset: {x: 0, y: 0}
- _OcclusionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _ParallaxMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _SpecGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _Texture2DAsset_94ed32cf0e49498183b70fd9bdf3eb13_Out_0:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_Lightmaps:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_LightmapsInd:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_ShadowMasks:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- Brightness_Rim: 2
- MAIN_LIGHT_CALCULATE_SHADOWS: 0
- Rim_Power: 5
- Toon_Ramp_Offset: 0.5
- Toon_Ramp_Smoothness: 0
- _ADDITIONAL_LIGHTS: 1
- _ADDITIONAL_LIGHT_SHADOWS: 1
- _Albedo: 0.3
- _AlphaClip: 0
- _Ambient_Occlusion: 0
- _Blend: 0
- _BumpScale: 1
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _Cull: 2
- _Cutoff: 0.5
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DstBlend: 0
- _EdgeDistanceAttenuation: 0.63
- _EdgeRim: 0.02
- _EdgeRimOffset: 0
- _EdgeSecular: 1
- _EdgeShadowAttenuation: 0.15
- _EdgeSpecular: 0.1
- _EdgeSpecularOffset: 0
- _Edge_Distance_Attenuation: 4.26
- _Edge_Rim: 0.3
- _Edge_Rim_Offset: 0.02
- _Edge_Shadow_Attenuation: 0.65
- _Edge_Specular: 0.26
- _Edge_Specular_Offset: 0.9
- _Emission: 0
- _EnvironmentReflections: 1
- _GlossMapScale: 0
- _Glossiness: 0
- _GlossyReflections: 0
- _MAIN_LIGHT_SHADOWS: 1
- _MAIN_LIGHT_SHADOWS_CASCADE: 1
- _Metallic: 0
- _Normal_Strenght: 0
- _Normal_Strength: 0.86
- _OcclusionStrength: 1
- _Parallax: 0.005
- _QueueControl: 0
- _QueueOffset: 0
- _ReceiveShadows: 1
- _RimThreshold: 0.09
- _SHADOWS_SOFT: 1
- _SHADOW_SOFT: 1
- _Shininess: 0.1
- _Smoothness: 0.2
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _Surface: 0
- _WorkflowMode: 1
- _ZWrite: 1
- _albedo: 0.1
- _normal: 0.28
m_Colors:
- Toon_Ramp_Tint: {r: 0.34117648, g: 0.34117648, b: 0.34117648, a: 1}
- _BaseColor: {r: 1, g: 1, b: 1, a: 1}
- _BaseMapColor: {r: 1, g: 1, b: 1, a: 0}
- _Color: {r: 1, g: 1, b: 1, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _EmissionMapColor: {r: 0, g: 0, b: 0, a: 0}
- _Offset: {r: 0, g: 0, b: 0, a: 0}
- _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1}
- _Tiling: {r: 1, g: 1, b: 0, a: 0}
m_BuildTextureStacks: []
--- !u!114 &6894510991190069626
MonoBehaviour:
m_ObjectHideFlags: 11
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3}
m_Name:
m_EditorClassIdentifier:
version: 5

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: f51e30a057be9f24084572a6f13cc0cf
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: b6ef874559bd6654a9806bf0891e9210
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,161 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 8
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: defaultMat
m_Shader: {fileID: 4800000, guid: 933532a4fcc9baf4fa0491de14d08ed7, type: 3}
m_ValidKeywords:
- _NORMALMAP
- _SMOOTHNESS_TEXTURE_ALBEDO_CHANNEL_A
m_InvalidKeywords: []
m_LightmapFlags: 4
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: -1
stringTagMap:
RenderType: Opaque
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- _BaseMap:
m_Texture: {fileID: 2800000, guid: e2e092fcfa4d917469ac212f3077a9a0, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _Base_Map:
m_Texture: {fileID: 2800000, guid: e2e092fcfa4d917469ac212f3077a9a0, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BumpMap:
m_Texture: {fileID: 2800000, guid: 17677dafc7bd6a4499ecfb2b6dd74c4f, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailAlbedoMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailMask:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailNormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _EmissionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MainTex:
m_Texture: {fileID: 2800000, guid: e2e092fcfa4d917469ac212f3077a9a0, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MetallicGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _Nomal:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _Normal_Map:
m_Texture: {fileID: 2800000, guid: 17677dafc7bd6a4499ecfb2b6dd74c4f, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _OcclusionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _ParallaxMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _SpecGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _Texture2DAsset_94ed32cf0e49498183b70fd9bdf3eb13_Out_0:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_Lightmaps:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_LightmapsInd:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_ShadowMasks:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- _AlphaClip: 0
- _Ambient_Occlusion: 1
- _Blend: 0
- _BumpScale: 1
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _Cull: 2
- _Cutoff: 0.5
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DstBlend: 0
- _Edge_Distance_Attenuation: 4.26
- _Edge_Rim: 0.3
- _Edge_Rim_Offset: 0.02
- _Edge_Shadow_Attenuation: 0.65
- _Edge_Specular: 0.26
- _Edge_Specular_Offset: 0.9
- _EnvironmentReflections: 1
- _GlossMapScale: 1
- _Glossiness: 0
- _GlossyReflections: 1
- _Metallic: 0
- _Mode: 0
- _Normal_Strenght: 0
- _Normal_Strength: 0
- _OcclusionStrength: 1
- _Offset: 0
- _Parallax: 0.02
- _QueueControl: 0
- _QueueOffset: 0
- _ReceiveShadows: 1
- _RimThreshold: 0.09
- _Shininess: 0.1
- _Smoothness: 0
- _SmoothnessTextureChannel: 1
- _SpecularHighlights: 1
- _SrcBlend: 1
- _Surface: 0
- _UVSec: 0
- _WorkflowMode: 1
- _ZWrite: 1
m_Colors:
- _BaseColor: {r: 0.9063317, g: 0.9063317, b: 0.9063317, a: 1}
- _Color: {r: 0.9063317, g: 0.9063317, b: 0.9063317, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _Offset: {r: 0, g: 0, b: 0, a: 0}
- _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1}
- _Tiling: {r: 1, g: 1, b: 0, a: 0}
m_BuildTextureStacks: []
--- !u!114 &5147692904599633074
MonoBehaviour:
m_ObjectHideFlags: 11
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3}
m_Name:
m_EditorClassIdentifier:
version: 5

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 53b44c714c1a3374fb5060362127be8a
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,126 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 8
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: Standard
m_Shader: {fileID: 4800000, guid: 933532a4fcc9baf4fa0491de14d08ed7, type: 3}
m_ValidKeywords: []
m_InvalidKeywords: []
m_LightmapFlags: 4
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: -1
stringTagMap:
RenderType: Opaque
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- _BaseMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BumpMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailAlbedoMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailMask:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailNormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _EmissionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MainTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MetallicGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _OcclusionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _ParallaxMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _SpecGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_Lightmaps:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_LightmapsInd:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_ShadowMasks:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- _AlphaClip: 0
- _Blend: 0
- _BumpScale: 1
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _Cull: 2
- _Cutoff: 0.5
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DstBlend: 0
- _EnvironmentReflections: 1
- _GlossMapScale: 0
- _Glossiness: 0
- _GlossyReflections: 0
- _Metallic: 0
- _OcclusionStrength: 1
- _Parallax: 0.005
- _QueueOffset: 0
- _ReceiveShadows: 1
- _Smoothness: 0.5
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _Surface: 0
- _WorkflowMode: 1
- _ZWrite: 1
m_Colors:
- _BaseColor: {r: 1, g: 1, b: 1, a: 1}
- _Color: {r: 1, g: 1, b: 1, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1}
m_BuildTextureStacks: []
--- !u!114 &3689810309619950535
MonoBehaviour:
m_ObjectHideFlags: 11
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3}
m_Name:
m_EditorClassIdentifier:
version: 5

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: d5d4173cc2030e449842e506ea2fd884
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 61e4578db5c07c548a4da83ff57dd9fe
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,129 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 8
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: Stripe1
m_Shader: {fileID: 4800000, guid: 933532a4fcc9baf4fa0491de14d08ed7, type: 3}
m_ValidKeywords:
- _RECEIVE_SHADOWS_OFF
m_InvalidKeywords: []
m_LightmapFlags: 4
m_EnableInstancingVariants: 1
m_DoubleSidedGI: 1
m_CustomRenderQueue: -1
stringTagMap:
RenderType: Opaque
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- _BaseMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BumpMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailAlbedoMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailMask:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailNormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _EmissionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MainTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MetallicGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _OcclusionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _ParallaxMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _SpecGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_Lightmaps:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_LightmapsInd:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_ShadowMasks:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- _AlphaClip: 0
- _Blend: 0
- _BumpScale: 1
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _Cull: 0
- _Cutoff: 0.5
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DstBlend: 0
- _EnvironmentReflections: 1
- _GlossMapScale: 1
- _Glossiness: 0
- _GlossyReflections: 1
- _Metallic: 0
- _Mode: 0
- _OcclusionStrength: 1
- _Parallax: 0.02
- _QueueOffset: 0
- _ReceiveShadows: 0
- _Smoothness: 0
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _Surface: 0
- _UVSec: 0
- _WorkflowMode: 1
- _ZWrite: 1
m_Colors:
- _BaseColor: {r: 1, g: 1, b: 1, a: 1}
- _Color: {r: 1, g: 1, b: 1, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1}
m_BuildTextureStacks: []
--- !u!114 &959678501309879400
MonoBehaviour:
m_ObjectHideFlags: 11
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3}
m_Name:
m_EditorClassIdentifier:
version: 5

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 43c041bef9c8c3c4a80b6d145eea3d51
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,129 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!114 &-1206082138550218931
MonoBehaviour:
m_ObjectHideFlags: 11
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3}
m_Name:
m_EditorClassIdentifier:
version: 5
--- !u!21 &2100000
Material:
serializedVersion: 8
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: Stripe2
m_Shader: {fileID: 4800000, guid: 933532a4fcc9baf4fa0491de14d08ed7, type: 3}
m_ValidKeywords:
- _RECEIVE_SHADOWS_OFF
m_InvalidKeywords: []
m_LightmapFlags: 4
m_EnableInstancingVariants: 1
m_DoubleSidedGI: 1
m_CustomRenderQueue: -1
stringTagMap:
RenderType: Opaque
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- _BaseMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BumpMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailAlbedoMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailMask:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailNormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _EmissionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MainTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MetallicGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _OcclusionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _ParallaxMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _SpecGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_Lightmaps:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_LightmapsInd:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_ShadowMasks:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- _AlphaClip: 0
- _Blend: 0
- _BumpScale: 1
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _Cull: 0
- _Cutoff: 0.5
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DstBlend: 0
- _EnvironmentReflections: 1
- _GlossMapScale: 1
- _Glossiness: 0
- _GlossyReflections: 1
- _Metallic: 0
- _Mode: 0
- _OcclusionStrength: 1
- _Parallax: 0.02
- _QueueOffset: 0
- _ReceiveShadows: 0
- _Smoothness: 0
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _Surface: 0
- _UVSec: 0
- _WorkflowMode: 1
- _ZWrite: 1
m_Colors:
- _BaseColor: {r: 0, g: 0, b: 0, a: 1}
- _Color: {r: 0, g: 0, b: 0, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1}
m_BuildTextureStacks: []

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: aca31300caf809248b075b71f975b98a
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 130a57841069f874bbfc4f8c157e1a98
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,128 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!114 &-4793630757284805227
MonoBehaviour:
m_ObjectHideFlags: 11
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3}
m_Name:
m_EditorClassIdentifier:
version: 5
--- !u!21 &2100000
Material:
serializedVersion: 8
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: BluWire
m_Shader: {fileID: 4800000, guid: 933532a4fcc9baf4fa0491de14d08ed7, type: 3}
m_ValidKeywords: []
m_InvalidKeywords: []
m_LightmapFlags: 4
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: -1
stringTagMap:
RenderType: Opaque
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- _BaseMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BumpMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailAlbedoMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailMask:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailNormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _EmissionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MainTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MetallicGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _OcclusionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _ParallaxMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _SpecGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_Lightmaps:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_LightmapsInd:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_ShadowMasks:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- _AlphaClip: 0
- _Blend: 0
- _BumpScale: 1
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _Cull: 2
- _Cutoff: 0.5
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DstBlend: 0
- _EnvironmentReflections: 1
- _GlossMapScale: 1
- _Glossiness: 0
- _GlossyReflections: 1
- _Metallic: 0
- _Mode: 0
- _OcclusionStrength: 1
- _Parallax: 0.02
- _QueueOffset: 0
- _ReceiveShadows: 1
- _Smoothness: 0.5
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _Surface: 0
- _UVSec: 0
- _WorkflowMode: 1
- _ZWrite: 1
m_Colors:
- _BaseColor: {r: 0.08102346, g: 0.019957686, b: 0.9063317, a: 1}
- _Color: {r: 0.08102345, g: 0.019957686, b: 0.9063317, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1}
m_BuildTextureStacks: []

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: d8d78ac7870203f488d0adf88bd749fe
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,137 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 8
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: EnergyOrb
m_Shader: {fileID: -6465566751694194690, guid: a10c57b94f694c841b45ecca713f634a,
type: 3}
m_ValidKeywords: []
m_InvalidKeywords: []
m_LightmapFlags: 2
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: -1
stringTagMap: {}
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- _BaseMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BumpMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailAlbedoMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailMask:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailNormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _EmissionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _EnergyTexture:
m_Texture: {fileID: 2800000, guid: fb1e7061661837348996e515d4808353, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MainTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MetallicGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _OcclusionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _ParallaxMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _SpecGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_Lightmaps:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_LightmapsInd:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_ShadowMasks:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- _AlphaClip: 0
- _Blend: 0
- _BumpScale: 1
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _Cull: 2
- _Cutoff: 0.5
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DstBlend: 0
- _EnergyScrollSpeed: 0.1
- _EnvironmentReflections: 1
- _GlossMapScale: 1
- _Glossiness: 0
- _GlossyReflections: 1
- _Metallic: 0
- _Mode: 0
- _OcclusionStrength: 1
- _OrbInstability: 0.1
- _OrbSpeed: 0.22
- _Parallax: 0.02
- _QueueControl: 0
- _QueueOffset: 0
- _ReceiveShadows: 1
- _Smoothness: 0.5
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _Surface: 0
- _UVSec: 0
- _WorkflowMode: 1
- _ZWrite: 1
m_Colors:
- _BaseColor: {r: 0.4658, g: 0, b: 0.9063317, a: 1}
- _Color: {r: 0.46579993, g: 0, b: 0.9063317, a: 1}
- _EmissionColor: {r: 0.3061061, g: 0, b: 1, a: 1}
- _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1}
- _TextureColor: {r: 28.830072, g: 0, b: 110.13088, a: 1}
m_BuildTextureStacks: []
--- !u!114 &1323044874121813210
MonoBehaviour:
m_ObjectHideFlags: 11
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3}
m_Name:
m_EditorClassIdentifier:
version: 5

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 357c52e5b571d0647ab7777d08db877d
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,132 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 8
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: Glass
m_Shader: {fileID: 4800000, guid: 933532a4fcc9baf4fa0491de14d08ed7, type: 3}
m_ValidKeywords:
- _ALPHAPREMULTIPLY_ON
- _SURFACE_TYPE_TRANSPARENT
m_InvalidKeywords: []
m_LightmapFlags: 6
m_EnableInstancingVariants: 1
m_DoubleSidedGI: 1
m_CustomRenderQueue: 3000
stringTagMap:
RenderType: Transparent
disabledShaderPasses:
- DepthOnly
- SHADOWCASTER
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- _BaseMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BumpMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailAlbedoMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailMask:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailNormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _EmissionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MainTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MetallicGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _OcclusionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _ParallaxMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _SpecGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_Lightmaps:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_LightmapsInd:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_ShadowMasks:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- _AlphaClip: 0
- _Blend: 1
- _BumpScale: 1
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _Cull: 0
- _Cutoff: 0.5
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DstBlend: 10
- _EnvironmentReflections: 1
- _GlossMapScale: 1
- _Glossiness: 0
- _GlossyReflections: 1
- _Metallic: 0
- _Mode: 0
- _OcclusionStrength: 1
- _Parallax: 0.02
- _QueueOffset: 0
- _ReceiveShadows: 1
- _Smoothness: 0.302
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _Surface: 1
- _UVSec: 0
- _WorkflowMode: 1
- _ZWrite: 0
m_Colors:
- _BaseColor: {r: 0, g: 0, b: 0, a: 0}
- _Color: {r: 0, g: 0, b: 0, a: 0}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1}
m_BuildTextureStacks: []
--- !u!114 &7457877242772275457
MonoBehaviour:
m_ObjectHideFlags: 11
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3}
m_Name:
m_EditorClassIdentifier:
version: 5

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 4bffe88de2a0be245af25f2ffa7c7185
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,144 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 8
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: Polimer
m_Shader: {fileID: 4800000, guid: 933532a4fcc9baf4fa0491de14d08ed7, type: 3}
m_ValidKeywords: []
m_InvalidKeywords: []
m_LightmapFlags: 4
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: -1
stringTagMap:
RenderType: Opaque
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- MainTex:
m_Texture: {fileID: 2800000, guid: ca160b59bcf57884fa6dd7833316d9ce, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- Mask_R_Emission:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BaseMap:
m_Texture: {fileID: 2800000, guid: ca160b59bcf57884fa6dd7833316d9ce, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BumpMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailAlbedoMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailMask:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailNormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _EmissionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MainTex:
m_Texture: {fileID: 2800000, guid: ca160b59bcf57884fa6dd7833316d9ce, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MetallicGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _OcclusionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _ParallaxMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _SpecGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_Lightmaps:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_LightmapsInd:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_ShadowMasks:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- Brightness_Rim: 2
- Rim_Power: 5
- Toon_Ramp_Offset: 0.5
- Toon_Ramp_Smoothness: 0
- _AlphaClip: 0
- _Blend: 0
- _BumpScale: 1
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _Cull: 2
- _Cutoff: 0.5
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DstBlend: 0
- _EnvironmentReflections: 1
- _GlossMapScale: 1
- _Glossiness: 0
- _GlossyReflections: 1
- _Metallic: 0
- _Mode: 0
- _OcclusionStrength: 1
- _Parallax: 0.02
- _QueueControl: 0
- _QueueOffset: 0
- _ReceiveShadows: 1
- _Smoothness: 0.5
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _Surface: 0
- _UVSec: 0
- _WorkflowMode: 1
- _ZWrite: 1
m_Colors:
- Toon_Ramp_Tint: {r: 0.49056596, g: 0.49056596, b: 0.49056596, a: 1}
- _BaseColor: {r: 1, g: 1, b: 1, a: 1}
- _Color: {r: 1, g: 1, b: 1, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _Offset: {r: 0, g: 0, b: 0, a: 0}
- _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1}
- _Tiling: {r: 0, g: 0, b: 0, a: 0}
m_BuildTextureStacks: []
--- !u!114 &7591789968530208446
MonoBehaviour:
m_ObjectHideFlags: 11
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3}
m_Name:
m_EditorClassIdentifier:
version: 5

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: d1a16092d01e36a498e9a3762c1c51e9
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,128 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 8
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: RedWire
m_Shader: {fileID: 4800000, guid: 933532a4fcc9baf4fa0491de14d08ed7, type: 3}
m_ValidKeywords: []
m_InvalidKeywords: []
m_LightmapFlags: 4
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: -1
stringTagMap:
RenderType: Opaque
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- _BaseMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BumpMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailAlbedoMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailMask:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailNormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _EmissionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MainTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MetallicGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _OcclusionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _ParallaxMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _SpecGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_Lightmaps:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_LightmapsInd:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_ShadowMasks:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- _AlphaClip: 0
- _Blend: 0
- _BumpScale: 1
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _Cull: 2
- _Cutoff: 0.5
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DstBlend: 0
- _EnvironmentReflections: 1
- _GlossMapScale: 1
- _Glossiness: 0
- _GlossyReflections: 1
- _Metallic: 0
- _Mode: 0
- _OcclusionStrength: 1
- _Parallax: 0.02
- _QueueOffset: 0
- _ReceiveShadows: 1
- _Smoothness: 0.5
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _Surface: 0
- _UVSec: 0
- _WorkflowMode: 1
- _ZWrite: 1
m_Colors:
- _BaseColor: {r: 0.9063317, g: 0, b: 0.01138732, a: 1}
- _Color: {r: 0.9063317, g: 0, b: 0.01138732, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1}
m_BuildTextureStacks: []
--- !u!114 &3971061248606489664
MonoBehaviour:
m_ObjectHideFlags: 11
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3}
m_Name:
m_EditorClassIdentifier:
version: 5

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 8b0177c670063bc4bb684af9ad2c6609
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: a403810a6e639cb48b312b6df3f4d6ac
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,143 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!114 &-2922466015008598244
MonoBehaviour:
m_ObjectHideFlags: 11
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3}
m_Name:
m_EditorClassIdentifier:
version: 5
--- !u!21 &2100000
Material:
serializedVersion: 8
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: BlackHole
m_Shader: {fileID: -6465566751694194690, guid: e7ccc3f2dceea4d4d87a3a7bd0ee7c1d,
type: 3}
m_ValidKeywords: []
m_InvalidKeywords: []
m_LightmapFlags: 0
m_EnableInstancingVariants: 1
m_DoubleSidedGI: 0
m_CustomRenderQueue: -1
stringTagMap: {}
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- _BaseMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BumpMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailAlbedoMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailMask:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailNormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _EmissionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MainTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MetallicGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _OcclusionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _ParallaxMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _SpecGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_Lightmaps:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_LightmapsInd:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_ShadowMasks:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- _AlphaClip: 0
- _Blend: 0
- _BumpScale: 1
- _CenterBulge: -0.19
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _Cull: 2
- _Cutoff: 0.5
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DstBlend: 0
- _EnvironmentReflections: 1
- _GlossMapScale: 1
- _Glossiness: 0
- _GlossyReflections: 1
- _HoleDistortion: 0.69
- _HoleInstability: 0.06
- _HoleNoise: 1
- _HoleNoiseSpeed: 0.57
- _HoleRotationSpeed: 0
- _HoleSize: 0.1
- _HoleSpeed: 0.03
- _HoleTwirl: 17
- _HoleTwirlSpeed: 0.1
- _MeshSize: 0
- _Metallic: 0
- _Mode: 0
- _OcclusionStrength: 1
- _OutlineSize: 0.92
- _OutsideSmoothing: 0
- _Parallax: 0.02
- _QueueControl: 0
- _QueueOffset: 0
- _ReceiveShadows: 1
- _Smoothing: 0.1
- _Smoothness: 0.5
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _Surface: 0
- _UVSec: 0
- _WorkflowMode: 1
- _ZWrite: 1
m_Colors:
- _BaseColor: {r: 0, g: 0, b: 0, a: 1}
- _Color: {r: 0, g: 0, b: 0, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1}
m_BuildTextureStacks: []

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 475a2cd34df502d45a2de08f8b00c821
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,128 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!114 &-7737023274898479621
MonoBehaviour:
m_ObjectHideFlags: 11
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3}
m_Name:
m_EditorClassIdentifier:
version: 5
--- !u!21 &2100000
Material:
serializedVersion: 8
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: Body
m_Shader: {fileID: 4800000, guid: 933532a4fcc9baf4fa0491de14d08ed7, type: 3}
m_ValidKeywords: []
m_InvalidKeywords: []
m_LightmapFlags: 4
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: -1
stringTagMap:
RenderType: Opaque
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- _BaseMap:
m_Texture: {fileID: 0}
m_Scale: {x: 0.1, y: 0.1}
m_Offset: {x: 0, y: 0}
- _BumpMap:
m_Texture: {fileID: 0}
m_Scale: {x: 0.1, y: 0.1}
m_Offset: {x: 0, y: 0}
- _DetailAlbedoMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailMask:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailNormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _EmissionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MainTex:
m_Texture: {fileID: 0}
m_Scale: {x: 0.1, y: 0.1}
m_Offset: {x: 0, y: 0}
- _MetallicGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _OcclusionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _ParallaxMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _SpecGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_Lightmaps:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_LightmapsInd:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_ShadowMasks:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- _AlphaClip: 0
- _Blend: 0
- _BumpScale: 1
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _Cull: 2
- _Cutoff: 0.5
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DstBlend: 0
- _EnvironmentReflections: 1
- _GlossMapScale: 1
- _Glossiness: 0
- _GlossyReflections: 1
- _Metallic: 0
- _Mode: 0
- _OcclusionStrength: 1
- _Parallax: 0.02
- _QueueOffset: 0
- _ReceiveShadows: 1
- _Smoothness: 0.5
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _Surface: 0
- _UVSec: 0
- _WorkflowMode: 1
- _ZWrite: 1
m_Colors:
- _BaseColor: {r: 0.14150941, g: 0.14150941, b: 0.14150941, a: 1}
- _Color: {r: 0.14150938, g: 0.14150938, b: 0.14150938, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1}
m_BuildTextureStacks: []

View file

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: a7386b2ff75cb9147b3db7c0c89521c6
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:

View file

@ -0,0 +1,129 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 8
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: Green
m_Shader: {fileID: 4800000, guid: 933532a4fcc9baf4fa0491de14d08ed7, type: 3}
m_ValidKeywords:
- _EMISSION
m_InvalidKeywords: []
m_LightmapFlags: 1
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: -1
stringTagMap:
RenderType: Opaque
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- _BaseMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BumpMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailAlbedoMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailMask:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailNormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _EmissionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MainTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MetallicGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _OcclusionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _ParallaxMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _SpecGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_Lightmaps:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_LightmapsInd:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_ShadowMasks:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- _AlphaClip: 0
- _Blend: 0
- _BumpScale: 1
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _Cull: 2
- _Cutoff: 0.5
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DstBlend: 0
- _EnvironmentReflections: 1
- _GlossMapScale: 1
- _Glossiness: 0
- _GlossyReflections: 1
- _Metallic: 0
- _Mode: 0
- _OcclusionStrength: 1
- _Parallax: 0.02
- _QueueOffset: 0
- _ReceiveShadows: 1
- _Smoothness: 0.5
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _Surface: 0
- _UVSec: 0
- _WorkflowMode: 1
- _ZWrite: 1
m_Colors:
- _BaseColor: {r: 0, g: 0.90588236, b: 0.047061183, a: 1}
- _Color: {r: 0, g: 0.90588236, b: 0.04706116, a: 1}
- _EmissionColor: {r: 0, g: 0.79910284, b: 0.0036767125, a: 1}
- _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1}
m_BuildTextureStacks: []
--- !u!114 &3586347142592645587
MonoBehaviour:
m_ObjectHideFlags: 11
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3}
m_Name:
m_EditorClassIdentifier:
version: 5

Some files were not shown because too many files have changed in this diff Show more