コード例 #1
0
ファイル: HeadlessProcessor.cs プロジェクト: DevZhav/error
 public static void OnPostprocessBuild(BuildTarget buildTarget, string path)
 {
     if (Headless.IsBuildingHeadless())
     {
         HeadlessBuilder.Postprocess(Directory.GetParent(path).ToString());
     }
 }
コード例 #2
0
ファイル: HTMLElement.cs プロジェクト: myshinobi/NERVEBrowser
        public async Task UpdateRectangleAsync(Headless chrome, bool pickNew = false)
        {
            try
            {
                string script = GetBoundingJavascript(pickNew);
                object data   = await chrome.GetJavaScriptResult(script);

                if (data.ToString() == "null")
                {
                    exists = false;
                }
                else
                {
                    IDictionary <String, Object> result = (IDictionary <String, Object>)data;
                    rectangle = ReadRectangle(result);
                    if (rectangle.Width * rectangle.Height > 0)
                    {
                        exists = true;
                    }
                    else
                    {
                        exists = false;
                    }
                }
            }
            catch (Exception e)
            {
                Console.WriteLine(e.Message);
                exists = false;
            }
        }
コード例 #3
0
ファイル: HTMLElement.cs プロジェクト: myshinobi/NERVEBrowser
        //public async Task FindJavascriptElement(Headless chrome)
        //{
        //    string javascript = GetElementJavascript();
        //    object data = await chrome.GetJavaScriptResult(javascript);
        //    if (data.ToString() == "null")
        //    {
        //        exists = false;
        //    }
        //    else
        //    {
        //        exists = true;
        //        javascriptVariable = data.ToString();
        //    }
        //}

        public async Task <string> GetSrcAsync(Headless chrome, bool pickNew = false)
        {
            try
            {
                string script = GetMyJavascript(GetMyVariableName() + ".src", pickNew);
                object data   = await chrome.GetJavaScriptResult(script);

                if (data.ToString() == "null")
                {
                    exists = false;
                }
                else
                {
                    string result = (string)data;
                    exists = true;
                    return(result);
                }
            }
            catch (Exception e)
            {
                Console.WriteLine(e.Message);
                exists = false;
            }

            return("");
        }
コード例 #4
0
        public void SendDesignLayer()
        {
            var token = "TestToken";

            GSA.App = new MockGSAApp(proxy: new GSAProxy());

            var testObjects    = new Dictionary <string, List <SpeckleObject> >();
            var sendersCreated = new List <TestSpeckleGSASender>();
            var tokensUsed     = new List <string>();

            Headless.streamSenderCreationFn = (url, t) =>
            {
                var sender = new TestSpeckleGSASender()
                {
                    ServerAddress = url, Token = t
                };
                sendersCreated.Add(sender);
                return(sender);
            };

            //Copy file so that it can be deleted later
            var origFilePath   = HelperFunctions.GetFullPath(sendGsaFileRelativePath);
            var copiedFilePath = HelperFunctions.GetFullPath(@".\SendAnalysisLayerTest.gwb");

            File.Copy(origFilePath, copiedFilePath, true);

            var exceptionThrown = false;

            try
            {
                var headless = new Headless();
                headless.RunCLI("sender",
                                "--server", restApi,
                                "--email", "*****@*****.**",
                                "--token", token,
                                "--file", copiedFilePath,
                                "--layer", "design"
                                );
            }
            catch
            {
                exceptionThrown = true;
            }
            finally
            {
                File.Delete(copiedFilePath);
            }
            Assert.IsFalse(exceptionThrown);

            //Check there 3 receivers were used with the restApi and token
            Assert.AreEqual(1, sendersCreated.Count());
            Assert.IsFalse(string.IsNullOrEmpty(sendersCreated[0].StreamId));
            Assert.AreEqual(restApi, sendersCreated[0].ServerAddress);
            Assert.AreEqual(testSenBucketStreamIds["model"], sendersCreated[0].StreamId);
            Assert.AreEqual(token, sendersCreated[0].Token);
            Assert.IsTrue(sendersCreated[0].SentObjects.Keys.Count() > 0);
            Assert.IsTrue(sendersCreated[0].SentObjects.Values.Count() > 0); //Number of times a streamSender.SendObjects has been called
        }
コード例 #5
0
 void Awake()
 {
     if (headless == null)
     {
         headless = this;
         DontDestroyOnLoad(gameObject);
     }
     else if (headless != this)
     {
         Destroy(this.gameObject);
         return;
     }
 }
コード例 #6
0
        public void Receive()
        {
            GSA.App = new MockGSAApp();
            var testObjects      = new Dictionary <string, List <SpeckleObject> >();
            var receiversCreated = new List <TestSpeckleGSAReceiver>();
            var tokensUsed       = new List <string>();

            Headless.streamReceiverCreationFn = (url, t) =>
            {
                var receiver = new TestSpeckleGSAReceiver(url, "mm");
                receiver.UpdateGlobalTrigger += Receiver_UpdateGlobalTrigger;
                receiver.Token = t;
                receiversCreated.Add(receiver);
                return(receiver);
            };

            //Copy file so that it can be deleted later
            var filePath = HelperFunctions.GetFullPath(@".\ReceiveDesignLayerTest.gwb");

            var email             = "*****@*****.**";
            var token             = "TestToken";
            var restApi           = "http://australia.speckle.arup.com/api/"; //Note: the real thing needs api on the end, so added here as reminder
            var expectedStreamIds = new List <string>()
            {
                "stream-id-a", "stream-id-b", "stream-id-c"
            };

            //var proxy = new TestPRo
            var headless = new Headless();

            headless.RunCLI("receiver",
                            "--server", restApi,
                            "--email", email,
                            "--token", token,
                            "--file", filePath,
                            "--streamIDs", string.Join(",", expectedStreamIds),
                            "--layer", "design",
                            "--nodeAllowance", "0.2");

            //Check there 3 receivers were used with the restApi and token
            Assert.AreEqual(3, receiversCreated.Count());
            Assert.IsTrue(receiversCreated.Select(r => r.StreamId).OrderBy(i => i).SequenceEqual(expectedStreamIds.OrderBy(i => i)));
            Assert.IsTrue(receiversCreated.All(r => r.ServerAddress.Equals(restApi)));
            Assert.IsTrue(receiversCreated.All(r => r.Token.Equals(token)));
            Assert.AreEqual(3, NumCalled); //Number of times a streamRecevier.Trigger has been called
        }
コード例 #7
0
	// This function cleans a build up in a synchronized fashion
	// and is called regardless of whether the build was successful
	static void FinalizeBuildSync (bool restore)
	{

		if (restore) {
			try {
				RestoreBuild ();
			} catch (Exception e) {
				buildError = true;
				UnityEngine.Debug.LogError (e);
			}

			try {
				RevertBuild ();
			} catch (Exception e) {
				buildError = true;
				UnityEngine.Debug.LogError (e);
			}
		}

		if (buildError) {
			UnityEngine.Debug.LogError ("Build failed!\nHeadless Builder (v" + Headless.version + ")");
			Headless.SetBuildingHeadless (false, HeadlessProfiles.currentProfile);
			HeadlessCallbacks.InvokeCallbacks ("HeadlessBuildFailed");
            if (manualBuild || debugBuild)
            {
                SetProgress(null);
            }
        } else {
			UnityEngine.Debug.Log ("Build success!\nHeadless Builder (v" + Headless.version + ")");
            Headless.SetBuildingHeadless(false, HeadlessProfiles.currentProfile);
            if (manualBuild || debugBuild) {
                SetProgress(null);
            }
			int finishedBuilds = EditorPrefs.GetInt ("HEADLESSBUILDER_FINISHEDBUILDS", 0);
			if (finishedBuilds < int.MaxValue - 64) { 
				EditorPrefs.SetInt ("HEADLESSBUILDER_FINISHEDBUILDS", finishedBuilds + 1);
			}
		}

		if (queueBuild) {
			if (!buildError) {
				ManualBuildQueue (queueID + 1);
			}
		}

	}
コード例 #8
0
    public void OnProcessShader(
        Shader shader, ShaderSnippetData snippet, IList <ShaderCompilerData> shaderCompilerData)
    {
        // In development, don't strip debug variants
        if (!Headless.IsBuildingHeadless() || !HeadlessBuilder.ShouldStripShaders())
        {
            return;
        }

        int shaderCount = shaderCompilerData.Count;

        for (int i = 0; i < shaderCompilerData.Count; ++i)
        {
            shaderCompilerData.RemoveAt(i);
            --i;
        }

        HeadlessBuilder.shaderCount += shaderCount;
    }
コード例 #9
0
ファイル: HTMLElement.cs プロジェクト: myshinobi/NERVEBrowser
        public async Task <T> GetMyVariableData <T>(string VarOrFunctionName, Headless chrome, bool pickNew = false)
        {
            try
            {
                string script = GetMyJavascript(GetMyVariableName() + "." + VarOrFunctionName, pickNew);
                object data   = await chrome.GetJavaScriptResult(script);

                if (data.ToString() == "null")
                {
                    exists = false;
                }
                else
                {
                    T result;
                    try
                    {
                        result = (T)data;
                    }
                    catch (Exception)
                    {
                        result = Newtonsoft.Json.JsonConvert.DeserializeObject <T>((string)data);
                        throw;
                    }

                    exists = true;
                    return(result);
                }
            }
            catch (Exception e)
            {
                Console.WriteLine(e.Message);
                exists = false;
            }

            return(default(T));
        }
コード例 #10
0
        public void SendAnalysisLayer()
        {
            var token = "TestToken";

            GSA.App = new MockGSAApp(proxy: new GSAProxy());

            var testObjects    = new Dictionary <string, List <SpeckleObject> >();
            var sendersCreated = new List <TestSpeckleGSASender>();
            var tokensUsed     = new List <string>();

            Headless.streamSenderCreationFn = (url, t) =>
            {
                var sender = new TestSpeckleGSASender()
                {
                    ServerAddress = url, Token = t
                };
                sendersCreated.Add(sender);
                return(sender);
            };

            var expectedTestCases = new[] { "A1", "C2" };
            var results           = new[] { "Nodal Displacements", "1D Element Displacement" };

            //Copy file so that it can be deleted later
            var origFilePath   = HelperFunctions.GetFullPath(sendGsaFileRelativePath);
            var copiedFilePath = HelperFunctions.GetFullPath(@".\SendAnalysisLayerTest.gwb");

            File.Copy(origFilePath, copiedFilePath, true);

            var exceptionThrown = false;

            try
            {
                var headless = new Headless();
                headless.RunCLI("sender",
                                "--server", restApi,
                                "--email", "*****@*****.**",
                                "--token", token,
                                "--file", copiedFilePath,
                                "--layer", "analysis",
                                "--separateStreams",
                                "--result", string.Join(",", results.Select(r => "\"" + r + "\"")),
                                "--resultCases", string.Join(",", expectedTestCases));
            }
            catch
            {
                exceptionThrown = true;
            }
            finally
            {
                File.Delete(copiedFilePath);
            }
            Assert.IsFalse(exceptionThrown);

            //Check there 3 receivers were used with the restApi and token
            Assert.AreEqual(2, sendersCreated.Count());
            Assert.IsTrue(sendersCreated.All(r => !string.IsNullOrEmpty(r.StreamId)));
            Assert.IsTrue(sendersCreated.All(r => r.ServerAddress.Equals(restApi)));
            Assert.IsTrue(sendersCreated.Select(r => r.StreamId).OrderBy(i => i).SequenceEqual(testSenBucketStreamIds.Values.OrderBy(i => i)));
            Assert.IsTrue(sendersCreated.All(r => r.Token.Equals(token)));
            Assert.IsTrue(sendersCreated.All(s => s.SentObjects.Keys.Count() > 0 && s.SentObjects.Values.Count() > 0)); //Number of times a streamSender.SendObjects has been called

            Assert.IsTrue(GSA.App.LocalSettings.ResultCases.SequenceEqual(expectedTestCases));
            Assert.IsTrue(GSA.App.LocalSettings.StreamSendConfig == SpeckleGSAInterfaces.StreamContentConfig.ModelWithTabularResults);
            Assert.IsTrue(GSA.App.LocalSettings.ResultTypes.Contains(SpeckleGSAInterfaces.ResultType.NodalDisplacements));
            Assert.IsTrue(GSA.App.LocalSettings.ResultTypes.Contains(SpeckleGSAInterfaces.ResultType.Element1dDisplacement));
        }
コード例 #11
0
    // This function overarches the entire build process
    private static void Build ()
	{

		buildError = false;


		if (batchBuild) {

			// Process the relevant command line arguments

			string[] args = System.Environment.GetCommandLineArgs ();
			string batchPath = null;
			string batchProfile = null;
			for (int i = 0; i < args.Length - 1; i++) {
				if (args [i] == "-headlessPath") {
					batchPath = args [i + 1];
				}
				if (args [i] == "-headlessProfile") {
					batchProfile = args [i + 1];
				}
			}

			if (batchPath != null && Directory.Exists (batchPath)) {
				buildPath = batchPath;
			} else {
				UnityEngine.Debug.LogError ("Use the -headlessPath command line parameter to set a valid destination path for the headless build\nHeadless Builder (v" + Headless.version + ")");
				return;
			}

			if (batchProfile != null) {
				bool found = false;
				HeadlessProfiles.FindProfiles ();

				foreach (KeyValuePair<string,string> profile in HeadlessProfiles.GetProfileList()) {
					if (profile.Value.Equals (batchProfile)) {
						found = true;
						HeadlessProfiles.SetProfile (profile.Key);
					}
				}
				if (!found) {
					UnityEngine.Debug.LogError ("The profile specified by the -headlessProfile command line parameter was not found\nHeadless Builder (v" + Headless.version + ")");
					return;
				}
			}
		}

		if (manualBuild || debugBuild) {
            if (!EditorWindow.GetWindow<HeadlessEditor>().IsDocked())
            {
                EditorWindow.GetWindow<HeadlessEditor>().Close();
            }
		}


        // Load the settings (from file, not from memory)
        PrepareVariables();

        Headless.SetBuildingHeadless (true, headlessSettings.profileName);


		bool asyncExecute = manualBuild || debugBuild;

		if (asyncExecute) {
			HeadlessRoutine.start (InnerBuildAsync ());
		} else {
			InnerBuildSync ();
		}
	}
コード例 #12
0
ファイル: HTMLElement.cs プロジェクト: myshinobi/NERVEBrowser
 public async Task <string> GetInnerTextAsync(Headless chrome, bool pickNew = false)
 {
     return(await GetMyVariableData <string>("innerText", chrome, pickNew));
 }
コード例 #13
0
 // This function returns whether menu items should be enabled.
 private static bool isMenuEnabled()
 {
     return(!Headless.IsBuildingHeadless() && !BuildPipeline.isBuildingPlayer && !HeadlessEditor.dirtySettings && !HeadlessEditor.savingSettings);
 }
コード例 #14
0
        public override void Load()
        {
            AbnormalEffect effect = 0;

            AbnormalItem item = new PithyProfessional(effect);

            AddItem("UnusualPithyProfessional", item);
            AddEquipTexture(item, EquipType.Head, "UnusualPithyProfessional_Head", "Highlander/Items/Armor/PithyProfessional_Head");

            item = new LegendaryLid(effect);
            AddItem("UnusualLegendaryLid", item);
            AddEquipTexture(item, EquipType.Head, "UnusualLegendaryLid_Head", "Highlander/Items/Armor/LegendaryLid_Head");

            item = new BrassBucket(effect);
            AddItem("UnusualBrassBucket", item);
            AddEquipTexture(item, EquipType.Head, "UnusualBrassBucket_Head", "Highlander/Items/Armor/BrassBucket_Head");

            item = new TeamCaptain(effect);
            AddItem("UnusualTeamCaptain", item);
            AddEquipTexture(item, EquipType.Head, "UnusualTeamCaptain_Head", "Highlander/Items/Armor/TeamCaptain_Head");

            item = new StainlessPot(effect);
            AddItem("UnusualStainlessPot", item);
            AddEquipTexture(item, EquipType.Head, "UnusualStainlessPot_Head", "Highlander/Items/Armor/StainlessPot_Head");

            item = new Hotrod(effect);
            AddItem("UnusualHotrod", item);
            AddEquipTexture(item, EquipType.Head, "UnusualHotrod_Head", "Highlander/Items/Armor/Hotrod_Head");

            item = new StoutShako(effect);
            AddItem("UnusualStoutShako", item);
            AddEquipTexture(item, EquipType.Head, "UnusualStoutShako_Head", "Highlander/Items/Armor/StoutShako_Head");

            item = new SamurEye(effect);
            AddItem("UnusualSamurEye", item);
            AddEquipTexture(item, EquipType.Head, "UnusualSamurEye_Head", "Highlander/Items/Armor/SamurEye_Head");

            item = new OlSnaggletooth(effect);
            AddItem("UnusualOlSnaggletooth", item);
            AddEquipTexture(item, EquipType.Head, "UnusualOlSnaggletooth_Head", "Highlander/Items/Armor/OlSnaggletooth_Head");

            item = new PyromancerMask(effect);
            AddItem("UnusualPyromancerMask", item);
            AddEquipTexture(item, EquipType.Head, "UnusualPyromancerMask_Head", "Highlander/Items/Armor/PyromancerMask_Head");

            item = new HongKongCone(effect);
            AddItem("UnusualHongKongCone", item);
            AddEquipTexture(item, EquipType.Head, "UnusualHongKongCone_Head", "Highlander/Items/Armor/HongKongCone_Head");

            item = new KillerExclusive(effect);
            AddItem("UnusualKillerExclusive", item);
            AddEquipTexture(item, EquipType.Head, "UnusualKillerExclusive_Head", "Highlander/Items/Armor/KillerExclusive_Head");

            item = new TartanTyrolean(effect);
            AddItem("UnusualTartanTyrolean", item);
            AddEquipTexture(item, EquipType.Head, "UnusualTartanTyrolean_Head", "Highlander/Items/Armor/TartanTyrolean_Head");

            item = new ColdfrontCommander(effect);
            AddItem("UnusualColdfrontCommander", item);
            AddEquipTexture(item, EquipType.Head, "UnusualColdfrontCommander_Head", "Highlander/Items/Armor/ColdfrontCommander_Head");

            item = new SinnerShade(effect);
            AddItem("UnusualSinnerShade", item);
            AddEquipTexture(item, EquipType.Head, "UnusualSinnerShade_Head", "Highlander/Items/Armor/SinnerShade_Head");

            item = new MightyMitre(effect);
            AddItem("UnusualMightyMitre", item);
            AddEquipTexture(item, EquipType.Head, "UnusualMightyMitre_Head", "Highlander/Items/Armor/MightyMitre_Head");

            item = new CondorCap(effect);
            AddItem("UnusualCondorCap", item);
            AddEquipTexture(item, EquipType.Head, "UnusualCondorCap_Head", "Highlander/Items/Armor/CondorCap_Head");

            item = new SurgeonShako(effect);
            AddItem("UnusualSurgeonShako", item);
            AddEquipTexture(item, EquipType.Head, "UnusualSurgeonShako_Head", "Highlander/Items/Armor/SurgeonShako_Head");

            item = new ToySoldier(effect);
            AddItem("UnusualToySoldier", item);
            AddEquipTexture(item, EquipType.Head, "UnusualToySoldier_Head", "Highlander/Items/Armor/ToySoldier_Head");

            item = new PatriotPeak(effect);
            AddItem("UnusualPatriotPeak", item);
            AddEquipTexture(item, EquipType.Head, "UnusualPatriotPeak_Head", "Highlander/Items/Armor/PatriotPeak_Head");

            item = new Globetrotter(effect);
            AddItem("UnusualGlobetrotter", item);
            AddEquipTexture(item, EquipType.Head, "UnusualGlobetrotter_Head", "Highlander/Items/Armor/Globetrotter_Head");

            item = new Anger(effect);
            AddItem("UnusualAnger", item);
            AddEquipTexture(item, EquipType.Head, "UnusualAnger_Head", "Highlander/Items/Armor/Anger_Head");

            // Series 2

            item = new DeadCone(effect);
            AddItem("UnusualDeadCone", item);
            AddEquipTexture(item, EquipType.Head, "UnusualDeadCone_Head", "Highlander/Items/Armor/Series2/DeadCone_Head");

            item = new FruitShoot(effect);
            AddItem("UnusualFruitShoot", item);
            AddEquipTexture(item, EquipType.Head, "UnusualFruitShoot_Head", "Highlander/Items/Armor/Series2/FruitShoot_Head");

            item = new FuriousFukaamigasa(effect);
            AddItem("UnusualFuriousFukaamigasa", item);
            AddEquipTexture(item, EquipType.Head, "UnusualFuriousFukaamigasa_Head", "Highlander/Items/Armor/Series2/FuriousFukaamigasa_Head");

            item = new HeroHachimaki(effect);
            AddItem("UnusualHeroHachimaki", item);
            AddEquipTexture(item, EquipType.Head, "UnusualHeroHachimaki_Head", "Highlander/Items/Armor/Series2/HeroHachimaki_Head");

            item = new HotDogger(effect);
            AddItem("UnusualHotDogger", item);
            AddEquipTexture(item, EquipType.Head, "UnusualHotDogger_Head", "Highlander/Items/Armor/Series2/HotDogger_Head");

            item = new JanissaryKetche(effect);
            AddItem("UnusualJanissaryKetche", item);
            AddEquipTexture(item, EquipType.Head, "UnusualJanissaryKetche_Head", "Highlander/Items/Armor/Series2/JanissaryKetche_Head");

            item = new Law(effect);
            AddItem("UnusualLaw", item);
            AddEquipTexture(item, EquipType.Head, "UnusualLaw_Head", "Highlander/Items/Armor/Series2/Law_Head");

            item = new MediMask(effect);
            AddItem("UnusualMediMask", item);
            AddEquipTexture(item, EquipType.Head, "UnusualMediMask_Head", "Highlander/Items/Armor/Series2/MediMask_Head");

            item = new SurgeonStahlhelm(effect);
            AddItem("UnusualSurgeonStahlhelm", item);
            AddEquipTexture(item, EquipType.Head, "UnusualSurgeonStahlhelm_Head", "Highlander/Items/Armor/Series2/SurgeonStahlhelm_Head");

            item = new ToughStuffMuffs(effect);
            AddItem("UnusualToughStuffMuffs", item);
            AddEquipTexture(item, EquipType.Head, "UnusualToughStuffMuffs_Head", "Highlander/Items/Armor/Series2/ToughStuffMuffs_Head");

            // Halloween Hats

            item = new CroneDome(effect);
            AddItem("UnusualCroneDome", item);
            AddEquipTexture(item, EquipType.Head, "UnusualCroneDome_Head", "Highlander/Items/Armor/Halloween/CroneDome_Head");

            item = new Executioner(effect);
            AddItem("UnusualExecutioner", item);
            AddEquipTexture(item, EquipType.Head, "UnusualExecutioner_Head", "Highlander/Items/Armor/Halloween/Executioner_Head");

            item = new Hellmet(effect);
            AddItem("UnusualHellmet", item);
            AddEquipTexture(item, EquipType.Head, "UnusualHellmet_Head", "Highlander/Items/Armor/Halloween/Hellmet_Head");

            item = new InfernalImpaler(effect);
            AddItem("UnusualInfernalImpaler", item);
            AddEquipTexture(item, EquipType.Head, "UnusualInfernalImpaler_Head", "Highlander/Items/Armor/Halloween/InfernalImpaler_Head");

            item = new MacabreMask(effect);
            AddItem("UnusualMacabreMask", item);
            AddEquipTexture(item, EquipType.Head, "UnusualMacabreMask_Head", "Highlander/Items/Armor/Halloween/MacabreMask_Head");

            item = new OneWayTicket(effect);
            AddItem("UnusualOneWayTicket", item);
            AddEquipTexture(item, EquipType.Head, "UnusualOneWayTicket_Head", "Highlander/Items/Armor/Halloween/OneWayTicket_Head");

            item = new SearedSorcerer(effect);
            AddItem("UnusualSearedSorcerer", item);
            AddEquipTexture(item, EquipType.Head, "UnusualSearedSorcerer_Head", "Highlander/Items/Armor/Halloween/SearedSorcerer_Head");

            item = new SirPumpkinton(effect);
            AddItem("UnusualSirPumpkinton", item);
            AddEquipTexture(item, EquipType.Head, "UnusualSirPumpkinton_Head", "Highlander/Items/Armor/Halloween/SirPumpkinton_Head");

            // OG Hats

            item = new PaperBag(effect);
            AddItem("UnusualPaperBag", item);
            AddEquipTexture(item, EquipType.Head, "UnusualPaperBag_Head", "Highlander/Items/Armor/PaperBag_Head");

            item = new OpenMind(effect);
            AddItem("UnusualOpenMind", item);
            AddEquipTexture(item, EquipType.Head, "UnusualOpenMind_Head", "Highlander/Items/Armor/OpenMind_Head");

            item = new Headless(effect);
            AddItem("UnusualHeadless", item);
            AddEquipTexture(item, EquipType.Head, "UnusualHeadless_Head", "Highlander/Items/Armor/Headless_Head");

            item = new GuerrillaRebel(effect);
            AddItem("UnusualGuerrillaRebel", item);
            AddEquipTexture(item, EquipType.Head, "UnusualGuerrillaRebel_Head", "Highlander/Items/Armor/GuerrillaRebel_Head");

            item = new SkiMask(effect);
            AddItem("UnusualSkiMask", item);
            AddEquipTexture(item, EquipType.Head, "UnusualSkiMask_Head", "Highlander/Items/Armor/SkiMask_Head");

            item = new ImpregnableHelm(effect);
            AddItem("UnusualImpregnableHelm", item);
            AddEquipTexture(item, EquipType.Head, "UnusualImpregnableHelm_Head", "Highlander/Items/Armor/ImpregnableHelm_Head");

            item = new NinjaHeadband(effect);
            AddItem("UnusualNinjaHeadband", item);
            AddEquipTexture(item, EquipType.Head, "UnusualNinjaHeadband_Head", "Highlander/Items/Armor/NinjaHeadband_Head");

            item = new AutonomousOrb(effect);
            AddItem("UnusualAutonomousOrb", item);
            AddEquipTexture(item, EquipType.Head, "UnusualAutonomousOrb_Head", "Highlander/Items/Armor/AutonomousOrb_Head");

            item = new MedicalMask(effect);
            AddItem("UnusualMedicalMask", item);
            AddEquipTexture(item, EquipType.Head, "UnusualMedicalMask_Head", "Highlander/Items/Armor/MedicalMask_Head");

            item = new BloodWarriorMask(effect);
            AddItem("UnusualBloodWarriorMask", item);
            AddEquipTexture(item, EquipType.Head, "UnusualBloodWarriorMask_Head", "Highlander/Items/Armor/BloodWarriorMask_Head");

            /**for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      PithyProfessional item = new PithyProfessional(effect);
             *      AddItem(effect + "PithyProfessional", item);
             *      AddEquipTexture(item, EquipType.Head, "PithyProfessional" + effect + "_Head", "Highlander/Items/Armor/PithyProfessional_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      LegendaryLid item = new LegendaryLid(effect);
             *      AddItem(effect + "LegendaryLid", item);
             *      AddEquipTexture(item, EquipType.Head, "LegendaryLid" + effect + "_Head", "Highlander/Items/Armor/LegendaryLid_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      BrassBucket item = new BrassBucket(effect);
             *      AddItem(effect + "BrassBucket", item);
             *      AddEquipTexture(item, EquipType.Head, "BrassBucket" + effect + "_Head", "Highlander/Items/Armor/BrassBucket_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      TeamCaptain item = new TeamCaptain(effect);
             *      AddItem(effect + "TeamCaptain", item);
             *      AddEquipTexture(item, EquipType.Head, "TeamCaptain" + effect + "_Head", "Highlander/Items/Armor/TeamCaptain_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      StainlessPot item = new StainlessPot(effect);
             *      AddItem(effect + "StainlessPot", item);
             *      AddEquipTexture(item, EquipType.Head, "StainlessPot" + effect + "_Head", "Highlander/Items/Armor/StainlessPot_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      Hotrod item = new Hotrod(effect);
             *      AddItem(effect + "Hotrod", item);
             *      AddEquipTexture(item, EquipType.Head, "Hotrod" + effect + "_Head", "Highlander/Items/Armor/Hotrod_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      StoutShako item = new StoutShako(effect);
             *      AddItem(effect + "StoutShako", item);
             *      AddEquipTexture(item, EquipType.Head, "StoutShako" + effect + "_Head", "Highlander/Items/Armor/StoutShako_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      SamurEye item = new SamurEye(effect);
             *      AddItem(effect + "SamurEye", item);
             *      AddEquipTexture(item, EquipType.Head, "SamurEye" + effect + "_Head", "Highlander/Items/Armor/SamurEye_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      OlSnaggletooth item = new OlSnaggletooth(effect);
             *      AddItem(effect + "OlSnaggletooth", item);
             *      AddEquipTexture(item, EquipType.Head, "OlSnaggletooth" + effect + "_Head", "Highlander/Items/Armor/OlSnaggletooth_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      PyromancerMask item = new PyromancerMask(effect);
             *      AddItem(effect + "PyromancerMask", item);
             *      AddEquipTexture(item, EquipType.Head, "PyromancerMask" + effect + "_Head", "Highlander/Items/Armor/PyromancerMask_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      HongKongCone item = new HongKongCone(effect);
             *      AddItem(effect + "HongKongCone", item);
             *      AddEquipTexture(item, EquipType.Head, "HongKongCone" + effect + "_Head", "Highlander/Items/Armor/HongKongCone_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      KillerExclusive item = new KillerExclusive(effect);
             *      AddItem(effect + "KillerExclusive", item);
             *      AddEquipTexture(item, EquipType.Head, "KillerExclusive" + effect + "_Head", "Highlander/Items/Armor/KillerExclusive_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      BombBeanie item = new BombBeanie(effect);
             *      AddItem(effect + "BombBeanie", item);
             *      AddEquipTexture(item, EquipType.Head, "BombBeanie" + effect + "_Head", "Highlander/Items/Armor/BombBeanie_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      TartanTyrolean item = new TartanTyrolean(effect);
             *      AddItem(effect + "TartanTyrolean", item);
             *      AddEquipTexture(item, EquipType.Head, "TartanTyrolean" + effect + "_Head", "Highlander/Items/Armor/TartanTyrolean_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      ColdfrontCommander item = new ColdfrontCommander(effect);
             *      AddItem(effect + "ColdfrontCommander", item);
             *      AddEquipTexture(item, EquipType.Head, "ColdfrontCommander" + effect + "_Head", "Highlander/Items/Armor/ColdfrontCommander_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      SinnerShade item = new SinnerShade(effect);
             *      AddItem(effect + "SinnerShade", item);
             *      AddEquipTexture(item, EquipType.Head, "SinnerShade" + effect + "_Head", "Highlander/Items/Armor/SinnerShade_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      MightyMitre item = new MightyMitre(effect);
             *      AddItem(effect + "MightyMitre", item);
             *      AddEquipTexture(item, EquipType.Head, "MightyMitre" + effect + "_Head", "Highlander/Items/Armor/MightyMitre_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      CondorCap item = new CondorCap(effect);
             *      AddItem(effect + "CondorCap", item);
             *      AddEquipTexture(item, EquipType.Head, "CondorCap" + effect + "_Head", "Highlander/Items/Armor/CondorCap_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      SurgeonShako item = new SurgeonShako(effect);
             *      AddItem(effect + "SurgeonShako", item);
             *      AddEquipTexture(item, EquipType.Head, "SurgeonShako" + effect + "_Head", "Highlander/Items/Armor/SurgeonShako_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      ToySoldier item = new ToySoldier(effect);
             *      AddItem(effect + "ToySoldier", item);
             *      AddEquipTexture(item, EquipType.Head, "ToySoldier" + effect + "_Head", "Highlander/Items/Armor/ToySoldier_Head");
             * }
             * for (int i = 1; i < (int)AbnormalEffect.Max; i++)
             * {
             *      AbnormalEffect effect = (AbnormalEffect)i;
             *      PatriotPeak item = new PatriotPeak(effect);
             *      AddItem(effect + "PatriotPeak", item);
             *      AddEquipTexture(item, EquipType.Head, "PatriotPeak" + effect + "_Head", "Highlander/Items/Armor/PatriotPeak_Head");
             * }**/
        }