static void Main(string[] args) { List <ITeammate> FrontEnd = new List <ITeammate>() { new Leah(), new Natasha(), new Seth() }; List <ITeammate> BackEnd = new List <ITeammate>(); Robert Robert = new Robert(); Aaron Aaron = new Aaron(); Will Will = new Will(); BackEnd.Add(Robert); BackEnd.Add(Will); BackEnd.Add(Aaron); foreach (ITeammate member in FrontEnd) { member.Work(); } foreach (ITeammate member in BackEnd) { member.Work(); } }
private void ProcessSharp(int m) { var cho = _image[_fChoose.ChoosedFile]; byte[,,] res = null; string type = ""; switch (m) { case 0: res = new Robert(cho).RobertData; type = "-罗伯特锐化最终图"; break; case 1: res = new Sobel(cho).SobelData; type = "-Sobel锐化最终图"; break; case 2: res = new Lap(cho).Lapla; type = "-拉普拉斯锐化最终图"; break; } AddNewPic(res, cho.FileName + type, false); }
// Use this for initialization void Start() { if (parentObj == null) { parentObj = transform.parent.gameObject; } if (robert == null) { Debug.LogError("no robert"); } if (parentObj == null) { Debug.LogError("no parent gameobsject"); } parentCenter = parentObj.transform.position + new Vector3(0, 5, 0); robertScript = robert.GetComponent <Robert> (); animator = GetComponent <Animator> (); if (robertScript == null) { Debug.LogError("no robert script found"); } if (animator == null) { Debug.LogError("no animator found"); } parentCol = parentObj.GetComponent <Collider> (); state = false; // Debug.Log (parentCenter.x); // Debug.Log (parentCenter.y); // Debug.Log (parentCenter.z); }
// Use this for initialization void Start() { robert = GetComponent <Robert> (); if (robert == null) { Debug.LogError("No Robert.cs script"); } }