public Vector2 pointStart; // 物品列表顶点 // Use this for initialization void Start() { Player = GameObject.Find("NewHero"); dc = Player.GetComponent <DeathControl>(); rpu = Player.GetComponent <ResPutUp>(); screenX = Screen.width; screenY = Screen.height; scaleX = screenX / 1280; scaleY = screenY / 720; guiRectStyle = new GUIStyle(); //guiRectStyle.border = new RectOffset(0, 0, 0, 0); guiRectStyle.alignment = TextAnchor.MiddleCenter; //textstyle1 guiTextRectStyle1 = new GUIStyle(); guiTextRectStyle1.fontSize = (int)(32 * scaleX); guiTextRectStyle1.fontStyle = FontStyle.Bold; guiTextRectStyle1.normal.textColor = Color.white; //textstyle2 guiTextRectStyle2 = new GUIStyle(); guiTextRectStyle2.fontSize = (int)(36 * scaleX); guiTextRectStyle2.fontStyle = FontStyle.Bold; guiTextRectStyle2.normal.textColor = Color.white; guiTextRectStyle2.alignment = TextAnchor.MiddleRight; ResPart = GameObject.Find("NewHero").GetComponent <ResPutUp>(); pointStart = new Vector2(1100 * scaleX, 20 * scaleY); }
void Start() { dc = GetComponent <DeathControl>(); //originalColor = came.GetComponent<Camera>().backgroundColor; PrevAlertTime = 0f; dl = GameObject.Find("Eyelight").GetComponent <DynamicLight>(); dl.OnExitFieldOfView += onExitFieldOfView; dl.InsideFieldOfViewEvent += onEnterFieldOfView; // yield return new WaitForEndOfFrame(); }
// Use this for initialization void Start() { //if (Player.GetComponent<DeathControl>().ifdead == true) // { dc = Player.GetComponent <DeathControl>(); mbm = Player.GetComponent <MonitoredByMonster>(); if (SystemInfo.supportsImageEffects == false) { enabled = false; return; } if (curShader != null && curShader.isSupported == false) { enabled = false; } // } }
// Use this for initialization void Start() { anim = GetComponent <Animator>(); pc = GetComponent <PlayerControl>(); dc = GetComponent <DeathControl>(); }