Commit 44a0eaf0 authored by lllyasviel's avatar lllyasviel Committed by GitHub

Merge pull request #8 from 976047167/master

升级至unity5.62f。
parents ff8d0bc2 faeade54
Library/
Temp/
.vs/
*.sln
*.csproj
Shader "Custom/WaterBlur" {
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Custom/WaterBlur" {
Properties {
_blurSizeXY("BlurSizeXY", Range(0,10)) = 2
}
......@@ -29,7 +31,7 @@ struct v2f {
v2f vert(data i){
v2f o;
o.position = mul(UNITY_MATRIX_MVP, i.vertex);
o.position = UnityObjectToClipPos(i.vertex);
o.screenPos = o.position;
return o;
}
......
......@@ -370,7 +370,7 @@ public class MegaMeshPage : MonoBehaviour
BuildTangents(mesh);
if ( optimize )
mesh.Optimize();
;
mesh.RecalculateBounds();
}
......@@ -633,7 +633,7 @@ public class MegaMeshPage : MonoBehaviour
BuildTangents(mesh);
if ( optimize )
mesh.Optimize();
;
mesh.RecalculateBounds();
}
......
Shader "Custom/ArrowShader"
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Custom/ArrowShader"
{
Properties
{
......@@ -61,7 +63,7 @@
v2f vert_arrow (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.texcoord = TRANSFORM_TEX(v.texcoord,_MainTex);
return o;
}
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Learning Unity Shader/Lecture 15/RapidBlurEffect"
{
//-----------------------------------【属性 || Properties】------------------------------------------
......@@ -126,7 +128,7 @@ Shader "Learning Unity Shader/Lecture 15/RapidBlurEffect"
//【6.2】填充输出结构
//将三维空间中的坐标投影到二维窗口
o.pos = mul(UNITY_MATRIX_MVP, v.vertex);
o.pos = UnityObjectToClipPos(v.vertex);
//对图像的降采样:取像素上下左右周围的点,分别存于四级纹理坐标中
o.uv20 = v.texcoord + _MainTex_TexelSize.xy* half2(0.5h, 0.5h);;
o.uv21 = v.texcoord + _MainTex_TexelSize.xy * half2(-0.5h, -0.5h);
......@@ -172,7 +174,7 @@ Shader "Learning Unity Shader/Lecture 15/RapidBlurEffect"
//【9.2】填充输出结构
//将三维空间中的坐标投影到二维窗口
o.pos = mul(UNITY_MATRIX_MVP, v.vertex);
o.pos = UnityObjectToClipPos(v.vertex);
//纹理坐标
o.uv = half4(v.texcoord.xy, 1, 1);
//计算X方向的偏移量
......@@ -190,7 +192,7 @@ Shader "Learning Unity Shader/Lecture 15/RapidBlurEffect"
//【10.2】填充输出结构
//将三维空间中的坐标投影到二维窗口
o.pos = mul(UNITY_MATRIX_MVP, v.vertex);
o.pos = UnityObjectToClipPos(v.vertex);
//纹理坐标
o.uv = half4(v.texcoord.xy, 1, 1);
//计算Y方向的偏移量
......
......@@ -16,7 +16,7 @@ public class MonoCardInDeckManager : MonoBehaviour {
if (pic != null)
{
loadedPicCode = cardData.Id;
gameObject.transform.FindChild("face").GetComponent<Renderer>().material.mainTexture = pic;
gameObject.transform.Find("face").GetComponent<Renderer>().material.mainTexture = pic;
}
}
if (Program.I().deckManager.currentBanlist != loaded_banlist)
......
......@@ -11,7 +11,7 @@ public class forceColor : MonoBehaviour {
DestroyImmediate(item);
}
Color c;
UnityEngine.Color.TryParseHexString(Config.Getui("allUI.color"), out c);
ColorUtility.TryParseHtmlString(Config.Getui("allUI.color"), out c);
var sprites = GetComponentsInChildren<UISprite>();
foreach (var item in sprites)
{
......@@ -27,7 +27,7 @@ public class forceColor : MonoBehaviour {
}
}
}
UnityEngine.Color.TryParseHexString(Config.Getui("List.color"), out c);
ColorUtility.TryParseHtmlString(Config.Getui("List.color"), out c);
var lists = GetComponentsInChildren<UIPopupList>();
foreach (var item in lists)
{
......@@ -41,7 +41,7 @@ public class forceColor : MonoBehaviour {
{
}
}
UnityEngine.Color.TryParseHexString(Config.Getui("lable.color"), out c);
ColorUtility.TryParseHtmlString(Config.Getui("lable.color"), out c);
var ls = GetComponentsInChildren<UILabel>();
foreach (var item in ls)
{
......@@ -49,7 +49,7 @@ public class forceColor : MonoBehaviour {
item.gradientTop = c;
item.gradientBottom = Color.gray;
}
UnityEngine.Color.TryParseHexString(Config.Getui("lable.color.fadecolor"), out c);
ColorUtility.TryParseHtmlString(Config.Getui("lable.color.fadecolor"), out c);
ls = GetComponentsInChildren<UILabel>();
foreach (var item in ls)
{
......
......@@ -62,7 +62,7 @@ public class barPngLoader : MonoBehaviour {
api_name.height = int.Parse(mats[1]);
break;
case "playerNameLable.color":
Color.TryParseHexString(mats[1],out c);
ColorUtility.TryParseHtmlString(mats[1],out c);
api_name.color = c;
api_name.gradientTop = api_name.color;
break;
......@@ -107,7 +107,7 @@ public class barPngLoader : MonoBehaviour {
api_healthHint.height = int.Parse(mats[1]);
break;
case "healthLable.color":
Color.TryParseHexString(mats[1], out c);
ColorUtility.TryParseHtmlString(mats[1], out c);
api_healthHint.color = c;
api_healthHint.gradientTop = api_name.color;
break;
......@@ -152,7 +152,7 @@ public class barPngLoader : MonoBehaviour {
api_timeHint.height = int.Parse(mats[1]);
break;
case "timeLable.color":
Color.TryParseHexString(mats[1], out c);
ColorUtility.TryParseHtmlString(mats[1], out c);
api_timeHint.color = c;
api_timeHint.gradientTop = api_name.color;
break;
......
......@@ -81,7 +81,7 @@ public class gameInfo : MonoBehaviour
child.gameObject.layer = gameObject.layer;
}
Color c;
UnityEngine.Color.TryParseHexString(Config.Getui("gameChainCheckArea.color"), out c);
ColorUtility.TryParseHtmlString(Config.Getui("gameChainCheckArea.color"), out c);
UIHelper.getByName<UISprite>(UIHelper.getByName<UIToggle>(gameObject, "ignore_").gameObject, "Background").color = c;
UIHelper.getByName<UISprite>(UIHelper.getByName<UIToggle>(gameObject, "watch_").gameObject, "Background").color = c;
UIHelper.getByName<UISprite>(UIHelper.getByName<UIToggle>(gameObject, "use_").gameObject, "Background").color = c;
......
fileFormatVersion: 2
guid: 868c8ef03b5990d4db7b7e891c456cee
folderAsset: yes
timeCreated: 1495457253
licenseType: Pro
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: abb23a9422c4bcc4a9613864e7832e63
folderAsset: yes
timeCreated: 1475343881
licenseType: Pro
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:
......@@ -68,7 +68,7 @@ public class iconSetForButton : MonoBehaviour
break;
}
Color c;
UnityEngine.Color.TryParseHexString(Config.Getui("gameButtonSign.color"), out c);
ColorUtility.TryParseHtmlString(Config.Getui("gameButtonSign.color"), out c);
UITextureInButton.color = c;
}
public void setText(string hint)
......
......@@ -366,7 +366,7 @@ public class RopeEditor : EditorWindow
ropeObj.jointPhysicsSettings.interpolation = (RigidbodyInterpolation)EditorGUILayout.EnumPopup("Interpolation Mode", ropeObj.jointPhysicsSettings.interpolation);
GUILayout.Space(10);
GUILayout.Label("Physics Iteration [Affects ALL Scene Objects]");
Physics.solverIterationCount = (int)EditorGUILayout.Slider(Physics.solverIterationCount, 5, 100);
Physics.defaultSolverIterations = (int)EditorGUILayout.Slider(Physics.defaultSolverIterations, 5, 100);
GUILayout.Space(10);
GUILayout.Label("Collision Mode Used in Unity 3.0 ONLY");
ropeObj.jointPhysicsSettings.collisionMode = (Rope2.CollisionDetectMode)EditorGUILayout.EnumPopup("Collision Mode", ropeObj.jointPhysicsSettings.collisionMode);
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Transparent/Refractive"
{
Properties
......@@ -64,7 +66,7 @@ Shader "Transparent/Refractive"
void vert (inout appdata_full v, out Input o)
{
UNITY_INITIALIZE_OUTPUT(Input, o);
o.position = mul(UNITY_MATRIX_MVP, v.vertex);
o.position = UnityObjectToClipPos(v.vertex);
#if UNITY_UV_STARTS_AT_TOP
float scale = -1.0;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Unlit/Masked Colored"
{
Properties
......@@ -54,7 +56,7 @@ Shader "Unlit/Masked Colored"
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = TRANSFORM_TEX(v.texcoord, _MainTex);
return o;
......
......@@ -32,7 +32,7 @@ public static class NGUIEditorExtensions
{
rt = new RenderTexture(width, height, 1);
rt.hideFlags = HideFlags.HideAndDontSave;
rt.generateMips = false;
rt.autoGenerateMips = false;
rt.format = RenderTextureFormat.ARGB32;
rt.filterMode = FilterMode.Trilinear;
rt.anisoLevel = 4;
......
fileFormatVersion: 2
guid: 9c1c3e0c6e0365141b6ce67cbe0fddca
timeCreated: 1480605656
licenseType: Pro
PluginImporter:
serializedVersion: 1
iconMap: {}
executionOrder: {}
isPreloaded: 0
platformData:
Any:
enabled: 1
settings: {}
Editor:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: c3340bc7d1fca784fb0aef6f34b3575d
timeCreated: 1480605661
licenseType: Pro
PluginImporter:
serializedVersion: 1
iconMap: {}
executionOrder: {}
isPreloaded: 0
platformData:
Any:
enabled: 1
settings: {}
Editor:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 26753383e6341c24da58820bb591b5d7
timeCreated: 1481637485
licenseType: Pro
PluginImporter:
serializedVersion: 1
iconMap: {}
executionOrder: {}
isPreloaded: 0
platformData:
Any:
enabled: 1
settings: {}
Editor:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 4f8fba4113a7984449305cef004c61e9
timeCreated: 1481637487
licenseType: Pro
PluginImporter:
serializedVersion: 1
iconMap: {}
executionOrder: {}
isPreloaded: 0
platformData:
Any:
enabled: 1
settings: {}
Editor:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: b59e4f5f725a4484d84015652d7df76a
folderAsset: yes
timeCreated: 1470042630
licenseType: Pro
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Highlighted/Blur"
{
Properties
......@@ -38,7 +40,7 @@ Shader "Hidden/Highlighted/Blur"
{
// Shader code optimized for the Unity shader compiler
v2f o;
o.pos = mul(UNITY_MATRIX_MVP, v.vertex);
o.pos = UnityObjectToClipPos(v.vertex);
half2 offs = _MainTex_TexelSize.xy * _OffsetScale;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Highlighted/Composite"
{
Properties
......@@ -38,7 +40,7 @@ Shader "Hidden/Highlighted/Composite"
v2f vert (appdata_img v)
{
v2f o;
o.pos = mul(UNITY_MATRIX_MVP, v.vertex);
o.pos = UnityObjectToClipPos(v.vertex);
o.uv[0] = v.texcoord.xy;
o.uv[1] = v.texcoord.xy;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
#ifndef HIGHLIGHTING_CG_INCLUDED
#define HIGHLIGHTING_CG_INCLUDED
......@@ -13,7 +15,7 @@ struct appdata_vert
float4 vert(appdata_vert v) : POSITION
{
return mul(UNITY_MATRIX_MVP, v.vertex);
return UnityObjectToClipPos(v.vertex);
}
fixed4 frag() : COLOR
......@@ -41,7 +43,7 @@ struct v2f
v2f vert_alpha(appdata_vert_tex v)
{
v2f o;
o.pos = mul(UNITY_MATRIX_MVP, v.vertex);
o.pos = UnityObjectToClipPos(v.vertex);
o.texcoord = TRANSFORM_TEX(v.texcoord, _MainTex);
return o;
}
......
......@@ -121,10 +121,10 @@ public class gameCard : OCGobject
public gameCard()
{
gameObject =Program.I().create(Program.I().mod_ocgcore_card);
gameObject_face = gameObject.transform.FindChild("card").FindChild("face").gameObject;
gameObject_back = gameObject.transform.FindChild("card").FindChild("back").gameObject;
gameObject_event_main = gameObject.transform.FindChild("card").FindChild("event").gameObject;
cardHint = gameObject.transform.FindChild("text").GetComponent<TMPro.TextMeshPro>();
gameObject_face = gameObject.transform.Find("card").Find("face").gameObject;
gameObject_back = gameObject.transform.Find("card").Find("back").gameObject;
gameObject_event_main = gameObject.transform.Find("card").Find("event").gameObject;
cardHint = gameObject.transform.Find("text").GetComponent<TMPro.TextMeshPro>();
SpSummonFlash = insFlash("0099ff");
ActiveFlash = insFlash("00ff66");
SelectFlash = insFlash("ff8000");
......@@ -962,7 +962,7 @@ public class gameCard : OCGobject
try
{
gameObject_event_main.GetComponent<MeshCollider>().enabled = true;
gameObject.transform.FindChild("card").GetComponent<animation_floating_slow>().enabled = true;
gameObject.transform.Find("card").GetComponent<animation_floating_slow>().enabled = true;
}
catch (System.Exception e)
{
......@@ -984,7 +984,7 @@ public class gameCard : OCGobject
try
{
gameObject_event_main.GetComponent<MeshCollider>().enabled = false;
gameObject.transform.FindChild("card").GetComponent<animation_floating_slow>().enabled = false;
gameObject.transform.Find("card").GetComponent<animation_floating_slow>().enabled = false;
destroy(gameObject_event_card_bed);
}
catch (System.Exception e)
......@@ -998,7 +998,7 @@ public class gameCard : OCGobject
refreshFunctions.Remove(this.card_verticle_drawing_handler);
refreshFunctions.Remove(this.monster_cloude_handler);
refreshFunctions.Remove(this.card_floating_text_handler);
gameObject.transform.FindChild("card").transform.localPosition = Vector3.zero;
gameObject.transform.Find("card").transform.localPosition = Vector3.zero;
set_text("");
//caculateAbility();
}
......@@ -1007,7 +1007,7 @@ public class gameCard : OCGobject
try
{
gameObject_event_main.GetComponent<MeshCollider>().enabled = true;
gameObject.transform.FindChild("card").GetComponent<animation_floating_slow>().enabled = true;
gameObject.transform.Find("card").GetComponent<animation_floating_slow>().enabled = true;
}
catch (System.Exception e)
{
......@@ -2062,9 +2062,9 @@ public class gameCard : OCGobject
flash.transform.SetParent(gameObject_face.transform, false);
flash.transform.localPosition = Vector3.zero;
Color tcl = Color.yellow;
Color.TryParseHexString(color, out tcl);
ColorUtility.TryParseHtmlString(color, out tcl);
flash.flashingStartColor = tcl;
Color.TryParseHexString("000000", out tcl);
ColorUtility.TryParseHtmlString("000000", out tcl);
flash.flashingEndColor = tcl;
return flash;
}
......@@ -2078,9 +2078,9 @@ public class gameCard : OCGobject
MouseFlash.transform.SetParent(gameObject_face.transform, false);
MouseFlash.transform.localPosition = Vector3.zero;
Color tcl = Color.yellow;
Color.TryParseHexString("ff8000", out tcl);
ColorUtility.TryParseHtmlString("ff8000", out tcl);
MouseFlash.flashingStartColor = tcl;
Color.TryParseHexString("ffffff", out tcl);
ColorUtility.TryParseHtmlString("ffffff", out tcl);
MouseFlash.flashingEndColor = tcl;
}
MouseFlash.gameObject.SetActive(true);
......
......@@ -297,8 +297,8 @@ public class GameField : OCGobject
if (p_hole_me == null)
{
p_hole_me = create(Program.I().mod_ocgcore_ss_p_idle_effect, new Vector3(0, 0, 0));
p_hole_mel = p_hole_me.transform.FindChild("l");
p_hole_mer = p_hole_me.transform.FindChild("r");
p_hole_mel = p_hole_me.transform.Find("l");
p_hole_mer = p_hole_me.transform.Find("r");
prereal = 0;
}
}
......@@ -317,8 +317,8 @@ public class GameField : OCGobject
if (p_hole_op == null)
{
p_hole_op = create(Program.I().mod_ocgcore_ss_p_idle_effect, new Vector3(0, 0, 0));
p_hole_opl = p_hole_op.transform.FindChild("l");
p_hole_opr = p_hole_op.transform.FindChild("r");
p_hole_opl = p_hole_op.transform.Find("l");
p_hole_opr = p_hole_op.transform.Find("r");
prereal = 0;
}
}
......
......@@ -4645,8 +4645,8 @@ public class Ocgcore : ServantWithCardDescription
if (psum)
{
float real = (Program.fieldSize - 1) * 0.9f + 1f;
Program.I().mod_ocgcore_ss_p_sum_effect.transform.FindChild("l").localPosition = new Vector3(-15.2f * real, 0, 0);
Program.I().mod_ocgcore_ss_p_sum_effect.transform.FindChild("r").localPosition = new Vector3(14.65f * real, 0, 0);
Program.I().mod_ocgcore_ss_p_sum_effect.transform.Find("l").localPosition = new Vector3(-15.2f * real, 0, 0);
Program.I().mod_ocgcore_ss_p_sum_effect.transform.Find("r").localPosition = new Vector3(14.65f * real, 0, 0);
MonoBehaviour.Destroy((GameObject)MonoBehaviour.Instantiate(Program.I().mod_ocgcore_ss_p_sum_effect, pvector, Quaternion.identity), 5f);
}
}
......@@ -4719,8 +4719,8 @@ public class Ocgcore : ServantWithCardDescription
if (psum)
{
float real = (Program.fieldSize - 1) * 0.9f + 1f;
Program.I().mod_ocgcore_ss_p_sum_effect.transform.FindChild("l").localPosition = new Vector3(-15.2f * real, 0, 0);
Program.I().mod_ocgcore_ss_p_sum_effect.transform.FindChild("r").localPosition = new Vector3(14.65f * real, 0, 0);
Program.I().mod_ocgcore_ss_p_sum_effect.transform.Find("l").localPosition = new Vector3(-15.2f * real, 0, 0);
Program.I().mod_ocgcore_ss_p_sum_effect.transform.Find("r").localPosition = new Vector3(14.65f * real, 0, 0);
MonoBehaviour.Destroy((GameObject)MonoBehaviour.Instantiate(Program.I().mod_ocgcore_ss_p_sum_effect, pvector, Quaternion.identity), 5f);
}
......
......@@ -451,22 +451,22 @@ public class Program : MonoBehaviour
if (ui_back_ground_2d == null)
{
ui_back_ground_2d = create(mod_ui_2d);
camera_back_ground_2d = ui_back_ground_2d.transform.FindChild("Camera").GetComponent<Camera>();
camera_back_ground_2d = ui_back_ground_2d.transform.Find("Camera").GetComponent<Camera>();
}
camera_back_ground_2d.depth = -2;
ui_back_ground_2d.layer = 8;
ui_back_ground_2d.transform.FindChild("Camera").gameObject.layer = 8;
ui_back_ground_2d.transform.Find("Camera").gameObject.layer = 8;
camera_back_ground_2d.cullingMask = (int)Mathf.Pow(2, 8);
camera_back_ground_2d.clearFlags = CameraClearFlags.Depth;
if (ui_container_3d == null)
{
ui_container_3d = create(mod_ui_3d);
camera_container_3d = ui_container_3d.transform.FindChild("Camera").GetComponent<Camera>();
camera_container_3d = ui_container_3d.transform.Find("Camera").GetComponent<Camera>();
}
camera_container_3d.depth = -1;
ui_container_3d.layer = 9;
ui_container_3d.transform.FindChild("Camera").gameObject.layer = 9;
ui_container_3d.transform.Find("Camera").gameObject.layer = 9;
camera_container_3d.cullingMask = (int)Mathf.Pow(2, 9);
camera_container_3d.fieldOfView = 75;
camera_container_3d.rect = camera_game_main.rect;
......@@ -481,11 +481,11 @@ public class Program : MonoBehaviour
if (ui_main_2d == null)
{
ui_main_2d = create(mod_ui_2d);
camera_main_2d = ui_main_2d.transform.FindChild("Camera").GetComponent<Camera>();
camera_main_2d = ui_main_2d.transform.Find("Camera").GetComponent<Camera>();
}
camera_main_2d.depth = 3;
ui_main_2d.layer = 11;
ui_main_2d.transform.FindChild("Camera").gameObject.layer = 11;
ui_main_2d.transform.Find("Camera").gameObject.layer = 11;
camera_main_2d.cullingMask = (int)Mathf.Pow(2, 11);
camera_main_2d.clearFlags = CameraClearFlags.Depth;
......@@ -493,11 +493,11 @@ public class Program : MonoBehaviour
if (ui_windows_2d == null)
{
ui_windows_2d = create(mod_ui_2d);
camera_windows_2d = ui_windows_2d.transform.FindChild("Camera").GetComponent<Camera>();
camera_windows_2d = ui_windows_2d.transform.Find("Camera").GetComponent<Camera>();
}
camera_windows_2d.depth = 2;
ui_windows_2d.layer = 19;
ui_windows_2d.transform.FindChild("Camera").gameObject.layer = 19;
ui_windows_2d.transform.Find("Camera").gameObject.layer = 19;
camera_windows_2d.cullingMask = (int)Mathf.Pow(2, 19);
camera_windows_2d.clearFlags = CameraClearFlags.Depth;
......@@ -505,11 +505,11 @@ public class Program : MonoBehaviour
if (ui_main_3d == null)
{
ui_main_3d = create(mod_ui_3d);
camera_main_3d = ui_main_3d.transform.FindChild("Camera").GetComponent<Camera>();
camera_main_3d = ui_main_3d.transform.Find("Camera").GetComponent<Camera>();
}
camera_main_3d.depth = 1;
ui_main_3d.layer = 10;
ui_main_3d.transform.FindChild("Camera").gameObject.layer = 10;
ui_main_3d.transform.Find("Camera").gameObject.layer = 10;
camera_main_3d.cullingMask = (int)Mathf.Pow(2, 10);
camera_main_3d.fieldOfView = 75;
camera_main_3d.rect = new Rect(0, 0, 1, 1);
......
......@@ -909,7 +909,7 @@ public class GameTextureManager
N.Apply();
try
{
UnityEngine.Color.TryParseHexString(File.ReadAllText("texture\\duel\\chainColor.txt"), out chainColor);
ColorUtility.TryParseHtmlString(File.ReadAllText("texture\\duel\\chainColor.txt"), out chainColor);
}
catch (Exception)
{
......
......@@ -11,7 +11,7 @@ public class WindowServantSP : Servant
{
if (gameObject != null)
{
var glass = gameObject.transform.FindChild("glass");
var glass = gameObject.transform.Find("glass");
UIPanel pan = gameObject.GetComponentInChildren<UIPanel>();
if (pan != null)
{
......@@ -35,7 +35,7 @@ public class WindowServantSP : Servant
{
return;
}
var glass = gameObject.transform.FindChild("glass");
var glass = gameObject.transform.Find("glass");
var panelKIller = gameObject.GetComponent<panelKIller>();
if (panelKIller == null)
{
......@@ -74,7 +74,7 @@ public class WindowServantSP : Servant
panelKIller = gameObject.AddComponent<panelKIller>();
}
panelKIller.set(true);
var glass = gameObject.transform.FindChild("glass");
var glass = gameObject.transform.Find("glass");
if (glass != null)
{
glass.gameObject.SetActive(true);
......
......@@ -1627,8 +1627,8 @@ public class DeckManager : ServantWithCardDescription
if (r == null)
{
r = Program.I().create(Program.I().new_mod_cardInDeckManager).AddComponent<MonoCardInDeckManager>();
r.gameObject.transform.FindChild("back").gameObject.GetComponent<Renderer>().material.mainTexture = GameTextureManager.myBack;
r.gameObject.transform.FindChild("face").gameObject.GetComponent<Renderer>().material.mainTexture = GameTextureManager.myBack;
r.gameObject.transform.Find("back").gameObject.GetComponent<Renderer>().material.mainTexture = GameTextureManager.myBack;
r.gameObject.transform.Find("face").gameObject.GetComponent<Renderer>().material.mainTexture = GameTextureManager.myBack;
}
r.gameObject.transform.position = new Vector3(0, 5, 0);
r.gameObject.transform.eulerAngles = new Vector3(90, 0, 0);
......
......@@ -8,7 +8,7 @@ public class overlay_light : MonoBehaviour {
{
try
{
l = gameObject.transform.FindChild("light").gameObject;
l = gameObject.transform.Find("light").gameObject;
v = new Vector3(get_rand(), get_rand(), get_rand());
Vector3 chuizhi = (new Vector3(1, 1, -(v.x + v.y) / v.z)) / Vector3.Distance(Vector3.zero, new Vector3(1, 1, -(v.x + v.y) / v.z));
l.transform.localPosition = chuizhi * 5;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
// Community contribution: http://www.tasharen.com/forum/index.php?topic=9268.0
Shader "Hidden/Unlit/Premultiplied Colored (TextureClip)"
{
......@@ -55,7 +57,7 @@ Shader "Hidden/Unlit/Premultiplied Colored (TextureClip)"
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
o.clipUV = (v.vertex.xy * _ClipRange0.zw + _ClipRange0.xy) * 0.5 + float2(0.5, 0.5);
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Unlit/Premultiplied Colored 1"
{
Properties
......@@ -54,7 +56,7 @@ Shader "Hidden/Unlit/Premultiplied Colored 1"
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
o.worldPos = v.vertex.xy * _ClipRange0.zw + _ClipRange0.xy;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Unlit/Premultiplied Colored 2"
{
Properties
......@@ -64,7 +66,7 @@ Shader "Hidden/Unlit/Premultiplied Colored 2"
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
o.worldPos.xy = v.vertex.xy * _ClipRange0.zw + _ClipRange0.xy;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Unlit/Premultiplied Colored 3"
{
Properties
......@@ -67,7 +69,7 @@ Shader "Hidden/Unlit/Premultiplied Colored 3"
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
o.worldPos.xy = v.vertex.xy * _ClipRange0.zw + _ClipRange0.xy;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Unlit/Premultiplied Colored"
{
Properties
......@@ -52,7 +54,7 @@ Shader "Unlit/Premultiplied Colored"
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.texcoord = v.texcoord;
o.color = v.color;
return o;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Unlit/Text (TextureClip)"
{
Properties
......@@ -53,7 +55,7 @@ Shader "Hidden/Unlit/Text (TextureClip)"
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
o.clipUV = (v.vertex.xy * _ClipRange0.zw + _ClipRange0.xy) * 0.5 + float2(0.5, 0.5);
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Unlit/Text 1"
{
Properties
......@@ -54,7 +56,7 @@ Shader "Hidden/Unlit/Text 1"
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
o.worldPos = v.vertex.xy * _ClipRange0.zw + _ClipRange0.xy;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Unlit/Text 2"
{
Properties
......@@ -64,7 +66,7 @@ Shader "Hidden/Unlit/Text 2"
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
o.worldPos.xy = v.vertex.xy * _ClipRange0.zw + _ClipRange0.xy;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Unlit/Text 3"
{
Properties
......@@ -67,7 +69,7 @@ Shader "Hidden/Unlit/Text 3"
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
o.worldPos.xy = v.vertex.xy * _ClipRange0.zw + _ClipRange0.xy;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Unlit/Text"
{
Properties
......@@ -50,7 +52,7 @@ Shader "Unlit/Text"
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.texcoord = v.texcoord;
o.color = v.color;
return o;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Unlit/Transparent Colored (Packed) (TextureClip)"
{
Properties
......@@ -54,7 +56,7 @@ Shader "Unlit/Transparent Colored (Packed) (TextureClip)"
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
o.worldPos = TRANSFORM_TEX(v.vertex.xy, _MainTex);
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
// Community contribution: http://www.tasharen.com/forum/index.php?topic=9268.0
Shader "Hidden/Unlit/Transparent Colored (TextureClip)"
{
......@@ -54,7 +56,7 @@ Shader "Hidden/Unlit/Transparent Colored (TextureClip)"
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
o.clipUV = (v.vertex.xy * _ClipRange0.zw + _ClipRange0.xy) * 0.5 + float2(0.5, 0.5);
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Unlit/Transparent Colored 1"
{
Properties
......@@ -55,7 +57,7 @@ Shader "Hidden/Unlit/Transparent Colored 1"
v2f vert (appdata_t v)
{
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
o.worldPos = v.vertex.xy * _ClipRange0.zw + _ClipRange0.xy;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Unlit/Transparent Colored 2"
{
Properties
......@@ -65,7 +67,7 @@ Shader "Hidden/Unlit/Transparent Colored 2"
v2f vert (appdata_t v)
{
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
o.worldPos.xy = v.vertex.xy * _ClipRange0.zw + _ClipRange0.xy;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Unlit/Transparent Colored 3"
{
Properties
......@@ -68,7 +70,7 @@ Shader "Hidden/Unlit/Transparent Colored 3"
v2f vert (appdata_t v)
{
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
o.worldPos.xy = v.vertex.xy * _ClipRange0.zw + _ClipRange0.xy;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Unlit/Transparent Colored"
{
Properties
......@@ -51,7 +53,7 @@ Shader "Unlit/Transparent Colored"
v2f vert (appdata_t v)
{
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.texcoord = v.texcoord;
o.color = v.color;
return o;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Unlit/Transparent Masked 1"
{
Properties
......@@ -59,7 +61,7 @@ Shader "Hidden/Unlit/Transparent Masked 1"
v2f vert (appdata_t v)
{
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
o.texcoord1 = v.texcoord1;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Unlit/Transparent Masked 2"
{
Properties
......@@ -69,7 +71,7 @@ Shader "Hidden/Unlit/Transparent Masked 2"
v2f vert (appdata_t v)
{
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
o.texcoord1 = v.texcoord1;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Unlit/Transparent Masked 3"
{
Properties
......@@ -72,7 +74,7 @@ Shader "Hidden/Unlit/Transparent Masked 3"
v2f vert (appdata_t v)
{
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
o.texcoord1 = v.texcoord1;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Unlit/Transparent Masked"
{
Properties
......@@ -55,7 +57,7 @@ Shader "Unlit/Transparent Masked"
v2f vert (appdata_t v)
{
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.texcoord = v.texcoord;
o.texcoord1 = v.texcoord1;
o.color = v.color;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Unlit/Transparent Packed 1"
{
Properties
......@@ -55,7 +57,7 @@ Shader "Hidden/Unlit/Transparent Packed 1"
v2f vert (appdata_t v)
{
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
o.worldPos = v.vertex.xy * _ClipRange0.zw + _ClipRange0.xy;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Unlit/Transparent Packed 2"
{
Properties
......@@ -65,7 +67,7 @@ Shader "Hidden/Unlit/Transparent Packed 2"
v2f vert (appdata_t v)
{
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
o.worldPos.xy = v.vertex.xy * _ClipRange0.zw + _ClipRange0.xy;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Unlit/Transparent Packed 3"
{
Properties
......@@ -68,7 +70,7 @@ Shader "Hidden/Unlit/Transparent Packed 3"
v2f vert (appdata_t v)
{
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
o.worldPos.xy = v.vertex.xy * _ClipRange0.zw + _ClipRange0.xy;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Unlit/Transparent Packed"
{
Properties
......@@ -53,7 +55,7 @@ Shader "Unlit/Transparent Packed"
v2f vert (appdata_t v)
{
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = v.texcoord;
return o;
......
......@@ -10,7 +10,7 @@ namespace TMPro.Examples
private GameObject m_floatingText;
private TextMeshPro m_textMeshPro;
private TextMesh m_textMesh;
private NavMeshAgent m_navAgent;
private UnityEngine.AI.NavMeshAgent m_navAgent;
private Transform m_transform;
private Transform m_floatingText_Transform;
......@@ -24,7 +24,7 @@ namespace TMPro.Examples
void Awake()
{
m_transform = transform;
m_navAgent = GetComponent<NavMeshAgent>();
m_navAgent = GetComponent<UnityEngine.AI.NavMeshAgent>();
m_floatingText = new GameObject(m_transform.name + " floating text");
m_floatingText_Transform = m_floatingText.transform;
......
fileFormatVersion: 2
guid: 91fec1b28f9a91b42abd9257cd4d129b
folderAsset: yes
timeCreated: 1458307470
licenseType: Pro
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "TMPro/Mobile/Bitmap" {
Properties {
......@@ -45,7 +47,7 @@ SubShader {
v2f vert (appdata_t v)
{
v2f o;
o.vertex = UnityPixelSnap(mul(UNITY_MATRIX_MVP, v.vertex));
o.vertex = UnityPixelSnap(UnityObjectToClipPos(v.vertex));
//o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.color = v.color;
if(o.color.a > .5) o.color.a -= .5;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
// Copyright (C) 2014 Stephan Schaem - All Rights Reserved
// This code can only be used under the standard Unity Asset Store End User License Agreement
// A Copy of the EULA APPENDIX 1 is available at http://unity3d.com/company/legal/as_terms
......@@ -69,7 +71,7 @@ SubShader {
float4 vert = i.vertex;
vert.x += _VertexOffsetX;
vert.y += _VertexOffsetY;
float4 vPosition = UnityPixelSnap(mul(UNITY_MATRIX_MVP, vert));
float4 vPosition = UnityPixelSnap(UnityObjectToClipPos(vert));
fixed4 faceColor = i.color;
if(faceColor.a > .5) faceColor.a -= .5;
......
// Upgrade NOTE: replaced '_Object2World' with 'unity_ObjectToWorld'
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
// Copyright (C) 2014 Stephan Schaem - All Rights Reserved
// This code can only be used under the standard Unity Asset Store End User License Agreementoutline
// A Copy of the EULA APPENDIX 1 is available at http://unity3d.com/company/legal/as_terms
......@@ -135,7 +138,7 @@ SubShader {
vert.x += _VertexOffsetX;
vert.y += _VertexOffsetY;
float4 vPosition = mul(UNITY_MATRIX_MVP, vert);
float4 vPosition = UnityObjectToClipPos(vert);
float2 pixelSize = vPosition.w;
pixelSize /= float2(_ScaleX, _ScaleY) * abs(mul((float2x2)UNITY_MATRIX_P, _ScreenParams.xy));
......@@ -183,7 +186,7 @@ SubShader {
float4(input.texcoord0, UnpackUV(input.texcoord1.x)),
float4(alphaClip, scale, bias, weight),
float4(vert.xy-_MaskCoord.xy, .5/pixelSize.xy),
mul((float3x3)_EnvMatrix, _WorldSpaceCameraPos.xyz - mul(_Object2World, vert).xyz),
mul((float3x3)_EnvMatrix, _WorldSpaceCameraPos.xyz - mul(unity_ObjectToWorld, vert).xyz),
#if (UNDERLAY_ON || UNDERLAY_INNER)
float4(input.texcoord0 + bOffset, bScale, bBias),
underlayColor,
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
// Copyright (C) 2014 Stephan Schaem - All Rights Reserved
// This code can only be used under the standard Unity Asset Store End User License Agreement
// A Copy of the EULA APPENDIX 1 is available at http://unity3d.com/company/legal/as_terms
......@@ -122,7 +124,7 @@ SubShader {
float4 vert = input.vertex;
vert.x += _VertexOffsetX;
vert.y += _VertexOffsetY;
float4 vPosition = mul(UNITY_MATRIX_MVP, vert);
float4 vPosition = UnityObjectToClipPos(vert);
// Derivative Implementation
float2 dx = ddx(input.texcoord0);
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
// Copyright (C) 2014 Stephan Schaem - All Rights Reserved
// This code can only be used under the standard Unity Asset Store End User License Agreement
// A Copy of the EULA APPENDIX 1 is available at http://unity3d.com/company/legal/as_terms
......@@ -102,7 +104,7 @@ SubShader {
float4 vert = input.vertex;
vert.x += _VertexOffsetX;
vert.y += _VertexOffsetY;
float4 vPosition = mul(UNITY_MATRIX_MVP, vert);
float4 vPosition = UnityObjectToClipPos(vert);
float2 pixelSize = vPosition.w;
pixelSize /= float2(_ScaleX, _ScaleY) * abs(mul((float2x2)UNITY_MATRIX_P, _ScreenParams.xy));
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
// Copyright (C) 2014 Stephan Schaem - All Rights Reserved
// This code can only be used under the standard Unity Asset Store End User License Agreement
// A Copy of the EULA APPENDIX 1 is available at http://unity3d.com/company/legal/as_terms
......@@ -122,7 +124,7 @@ SubShader {
float4 vert = input.vertex;
vert.x += _VertexOffsetX;
vert.y += _VertexOffsetY;
float4 vPosition = mul(UNITY_MATRIX_MVP, vert);
float4 vPosition = UnityObjectToClipPos(vert);
float2 pixelSize = vPosition.w;
pixelSize /= float2(_ScaleX, _ScaleY) * abs(mul((float2x2)UNITY_MATRIX_P, _ScreenParams.xy));
......
// Upgrade NOTE: replaced '_Object2World' with 'unity_ObjectToWorld'
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
// Copyright (C) 2014 Stephan Schaem - All Rights Reserved
// This code can only be used under the standard Unity Asset Store End User License Agreementoutline
// A Copy of the EULA APPENDIX 1 is available at http://unity3d.com/company/legal/as_terms
......@@ -157,7 +160,7 @@ SubShader {
float4 vert = input.vertex;
vert.x += _VertexOffsetX;
vert.y += _VertexOffsetY;
float4 vPosition = mul(UNITY_MATRIX_MVP, vert);
float4 vPosition = UnityObjectToClipPos(vert);
float2 pixelSize = vPosition.w;
pixelSize /= float2(_ScaleX, _ScaleY) * abs(mul((float2x2)UNITY_MATRIX_P, _ScreenParams.xy));
......@@ -205,7 +208,7 @@ SubShader {
float4(input.texcoord0, UnpackUV(input.texcoord1.x)),
float4(alphaClip, scale, bias, weight),
float4(vert.xy-_MaskCoord.xy, .5/pixelSize.xy),
mul((float3x3)_EnvMatrix, _WorldSpaceCameraPos.xyz - mul(_Object2World, vert).xyz),
mul((float3x3)_EnvMatrix, _WorldSpaceCameraPos.xyz - mul(unity_ObjectToWorld, vert).xyz),
#if (UNDERLAY_ON || UNDERLAY_INNER)
float4(input.texcoord0 + bOffset, bScale, bBias),
underlayColor,
......
// Upgrade NOTE: replaced '_Object2World' with 'unity_ObjectToWorld'
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
// Copyright (C) 2014 Stephan Schaem - All Rights Reserved
// This code can only be used under the standard Unity Asset Store End User License Agreement
// A Copy of the EULA APPENDIX 1 is available at http://unity3d.com/company/legal/as_terms
......@@ -19,7 +22,7 @@ void VertShader(inout appdata_full v, out Input data)
data.param.y = 1;//v.texcoord1.y;// * _GradientScale * 1.5;
#else
float4 vert = v.vertex;
float4 vPosition = mul(UNITY_MATRIX_MVP, vert);
float4 vPosition = UnityObjectToClipPos(vert);
float2 pixelSize = vPosition.w; // * unity_Scale.w;
//pixelSize /= float2(_ScaleX * _ScreenParams.x * UNITY_MATRIX_P[0][0], _ScaleY * _ScreenParams.y * UNITY_MATRIX_P[1][1]);
pixelSize /= float2(_ScaleX, _ScaleY) * mul((float2x2)UNITY_MATRIX_P, _ScreenParams.xy);
......@@ -92,7 +95,7 @@ void PixShader(Input input, inout SurfaceOutput o)
n = normalize(n - bump);
// Cubemap reflection
fixed4 reflcol = texCUBE(_Cube, reflect(input.viewDirEnv, mul((float3x3)_Object2World,n)));
fixed4 reflcol = texCUBE(_Cube, reflect(input.viewDirEnv, mul((float3x3)unity_ObjectToWorld,n)));
float3 emission = reflcol.rgb * lerp(_ReflectFaceColor.rgb, _ReflectOutlineColor.rgb, saturate(sd + outline * 0.5)) * faceColor.a;
#else
float3 n = float3(0,0,-1);
......
......@@ -71,16 +71,11 @@ namespace TMPro
}
protected override void OnFillVBO(List<UIVertex> vbo)
{
base.OnFillVBO(vbo);
//Debug.Log("OnFillVBO called.");
//vbo = m_manager.uiVertex.ToList();
protected override void OnPopulateMesh(VertexHelper vh)
{
base.OnPopulateMesh(vh);
}
}
}
......
......@@ -1118,6 +1118,10 @@ namespace TMPro
isInputParsingRequired = true;
}
public void RecalculateMasking()
{
throw new NotImplementedException();
}
}
}
......
fileFormatVersion: 2
guid: 863f62626963a6445b92586f336ae65d
folderAsset: yes
timeCreated: 1458307470
licenseType: Pro
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: bbaaaa822d3ceb2478f1431c4afd6867
folderAsset: yes
timeCreated: 1470080051
licenseType: Pro
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Effects/Distortion/CullBack+1" {
Properties {
_Color ("Main Color", Color) = (1,1,1,1)
......@@ -37,7 +39,7 @@ struct Input {
void vert (inout appdata_full v, out Input o) {
UNITY_INITIALIZE_OUTPUT(Input,o);
float4 oPos = mul(UNITY_MATRIX_MVP, v.vertex);
float4 oPos = UnityObjectToClipPos(v.vertex);
#if UNITY_UV_STARTS_AT_TOP
float scale = -1.0;
#else
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Effects/Distortion/CullBack+2" {
Properties {
_Color ("Main Color", Color) = (1,1,1,1)
......@@ -36,7 +38,7 @@ struct Input {
void vert (inout appdata_full v, out Input o) {
UNITY_INITIALIZE_OUTPUT(Input,o);
float4 oPos = mul(UNITY_MATRIX_MVP, v.vertex);
float4 oPos = UnityObjectToClipPos(v.vertex);
#if UNITY_UV_STARTS_AT_TOP
float scale = -1.0;
#else
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Effects/Distortion/CullOff+1" {
Properties {
_Color ("Main Color", Color) = (1,1,1,1)
......@@ -39,7 +41,7 @@ struct Input {
void vert (inout appdata_full v, out Input o) {
UNITY_INITIALIZE_OUTPUT(Input,o);
float4 oPos = mul(UNITY_MATRIX_MVP, v.vertex);
float4 oPos = UnityObjectToClipPos(v.vertex);
#if UNITY_UV_STARTS_AT_TOP
float scale = -1.0;
#else
......
Shader "Effects/Distortion/CutOutCullOff+1" {
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Effects/Distortion/CutOutCullOff+1" {
Properties {
_Color ("Main Color", Color) = (1,1,1,1)
_MainTex ("Base (RGB) Gloss (A)", 2D) = "black" {}
......@@ -40,7 +42,7 @@ struct Input {
void vert (inout appdata_full v, out Input o) {
UNITY_INITIALIZE_OUTPUT(Input,o);
float4 oPos = mul(UNITY_MATRIX_MVP, v.vertex);
float4 oPos = UnityObjectToClipPos(v.vertex);
#if UNITY_UV_STARTS_AT_TOP
float scale = -1.0;
#else
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Effects/Distortion/CutOutCullOff" {
Properties {
_Color ("Main Color", Color) = (1,1,1,1)
......@@ -40,7 +42,7 @@ struct Input {
void vert (inout appdata_full v, out Input o) {
UNITY_INITIALIZE_OUTPUT(Input,o);
float4 oPos = mul(UNITY_MATRIX_MVP, v.vertex);
float4 oPos = UnityObjectToClipPos(v.vertex);
#if UNITY_UV_STARTS_AT_TOP
float scale = -1.0;
#else
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Effects/Distortion/Free/CullBack" {
Properties {
_Color ("Main Color", Color) = (1,1,1,1)
......@@ -43,7 +45,7 @@ Category {
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = TRANSFORM_TEX(v.texcoord,_MainTex);
return o;
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Effects/Distortion/Free/CullOff" {
Properties {
_Color ("Main Color", Color) = (1,1,1,1)
......@@ -43,7 +45,7 @@ Category {
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = TRANSFORM_TEX(v.texcoord,_MainTex);
return o;
......
Shader "Effects/Distortion/Free/CutOutCullOff" {
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Effects/Distortion/Free/CutOutCullOff" {
Properties {
_Color ("Main Color", Color) = (1,1,1,1)
_MainTex ("Base (RGB) Gloss (A)", 2D) = "black" {}
......@@ -47,7 +49,7 @@ Category {
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = TRANSFORM_TEX(v.texcoord,_MainTex);
o.texcoord1 = TRANSFORM_TEX(v.texcoord1,_CutoutTex);
......
Shader "Effects/GlowAdditive" {
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Effects/GlowAdditive" {
Properties {
_TintColor ("Tint Color", Color) = (0.5,0.5,0.5,0.5)
_MainTex ("Particle Texture", 2D) = "white" {}
......@@ -50,7 +52,7 @@ Category {
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
#ifdef SOFTPARTICLES_ON
o.projPos = ComputeScreenPos (o.vertex);
COMPUTE_EYEDEPTH(o.projPos.z);
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Effects/GlowAdditiveSimple" {
Properties {
_TintColor ("Tint Color", Color) = (0.5,0.5,0.5,0.5)
......@@ -54,7 +56,7 @@ Category {
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
//o.color = v.color;
o.texcoord = TRANSFORM_TEX(v.texcoord,_MainTex);
return o;
......
Shader "Effects/GlowAdditiveTwoColor" {
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Effects/GlowAdditiveTwoColor" {
Properties {
_TintColor ("Tint Color", Color) = (0.5,0.5,0.5,0.5)
_CoreColor ("Core Color", Color) = (0.5,0.5,0.5,0.5)
......@@ -56,7 +58,7 @@ Category {
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
#ifdef SOFTPARTICLES_ON
o.projPos = ComputeScreenPos (o.vertex);
COMPUTE_EYEDEPTH(o.projPos.z);
......
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Effects/Particles" {
Properties {
_TintColor ("Tint Color", Color) = (0.5,0.5,0.5,0.5)
......@@ -39,7 +41,7 @@ Category {
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = TRANSFORM_TEX(v.texcoord,_MainTex);
......
Shader "Effects/Rim" {
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Effects/Rim" {
Properties {
_Color ("Rim Color", Color) = (0.5,0.5,0.5,0.5)
_FPOW("FPOW Fresnel", Float) = 5.0
......@@ -46,7 +48,7 @@ Category {
v2f vert (appdata_t v)
{
v2f o;
o.vertex = mul(UNITY_MATRIX_MVP, v.vertex);
o.vertex = UnityObjectToClipPos(v.vertex);
o.color = v.color;
o.texcoord = TRANSFORM_TEX(v.texcoord,_MainTex);
......
Shader "Effects/Water" {
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Effects/Water" {
Properties {
_Color ("Main Color", Color) = (1,1,1,1)
_SpecColor ("Specular Color", Color) = (0.5,0.5,0.5,1)
......@@ -56,7 +58,7 @@ struct Input {
void vert (inout appdata_full v, out Input o) {
UNITY_INITIALIZE_OUTPUT(Input,o);
float4 oPos = mul(UNITY_MATRIX_MVP, v.vertex);
float4 oPos = UnityObjectToClipPos(v.vertex);
#if UNITY_UV_STARTS_AT_TOP
float scale = -1.0;
#else
......
......@@ -14,8 +14,8 @@ public class thunder_locator : MonoBehaviour {
}
// Use this for initialization
void Start () {
leftobj_left = gameObject.transform.FindChild("left").gameObject;
rightobj_right = gameObject.transform.FindChild("right").gameObject;
leftobj_left = gameObject.transform.Find("left").gameObject;
rightobj_right = gameObject.transform.Find("right").gameObject;
}
// Update is called once per frame
......
m_EditorVersion: 5.1.3f1
m_StandardAssetsVersion: 0
m_EditorVersion: 5.6.2f1
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment