Refactored conditions

Refactored conditions

--- AngleSharp/Parser/Css/CssParser.cs
+++ AngleSharp/Parser/Css/CssParser.cs
@@ -18,7 +18,7 @@
     /// The CSS parser.
     /// See http://dev.w3.org/csswg/css-syntax/#parsing for more details.
     /// </summary>
-    [DebuggerStepThrough]
+    //[DebuggerStepThrough]
     public sealed class CssParser
     {
         #region Fields
@@ -167,8 +167,8 @@
             var rule = new CssMediaRule(list);

             if (token.Type != CssTokenType.CurlyBracketOpen)
-                return null;
-
+                return parser.SkipDeclarations<CssMediaRule>(token);
+
             parser.FillRules(rule);
             return rule;
         }
@@ -181,13 +181,14 @@
         /// <returns>The created page rule.</returns>
         internal static CssPageRule CreatePageRule(CssParser parser)
         {
+            var token = parser._tokenizer.Get();
             var rule = new CssPageRule();
-            var token = parser._tokenizer.Get();
             rule.Selector = parser.InSelector(ref token);

-            if (token.Type == CssTokenType.CurlyBracketOpen)
-                parser.FillDeclarations(rule.Style);
-
+            if (token.Type != CssTokenType.CurlyBracketOpen)
+                return parser.SkipDeclarations<CssPageRule>(token);
+
+            parser.FillDeclarations(rule.Style);
             return rule;
         }

@@ -199,12 +200,13 @@
         /// <returns>The created font-face rule.</returns>
         internal static CssFontFaceRule CreateFontFaceRule(CssParser parser)
         {
+            var token = parser._tokenizer.Get();
             var rule = new CssFontFaceRule();
-            var token = parser._tokenizer.Get();
-
-            if (token.Type == CssTokenType.CurlyBracketOpen)
-                parser.FillDeclarations(rule.Style);
-
+
+            if (token.Type != CssTokenType.CurlyBracketOpen)
+                return parser.SkipDeclarations<CssFontFaceRule>(token);
+
+            parser.FillDeclarations(rule.Style);
             return rule;
         }

@@ -216,19 +218,14 @@
         /// <returns>The created supports rule.</returns>
         internal static CssSupportsRule CreateSupportsRule(CssParser parser)
         {
+            var token = parser._tokenizer.Get();
             var rule = new CssSupportsRule();
-            var token = parser._tokenizer.Get();
             rule.Condition = parser.InCondition(ref token);

-            if (rule.Condition == null)
-            {
-                while (token.IsNot(CssTokenType.Eof, CssTokenType.CurlyBracketOpen))
-                    token = parser._tokenizer.Get();
-            }
-
-            if (token.Type == CssTokenType.CurlyBracketOpen)
-                parser.FillRules(rule);
-
+            if (token.Type != CssTokenType.CurlyBracketOpen)
+                return parser.SkipDeclarations<CssSupportsRule>(token);
+
+            parser.FillRules(rule);
             return rule;
         }

@@ -243,9 +240,10 @@
             var token = parser._tokenizer.Get();
             var rule = parser.InDocumentFunctions(ref token);

-            if (token.Type == CssTokenType.CurlyBracketOpen)
-                parser.FillRules(rule);
-
+            if (token.Type != CssTokenType.CurlyBracketOpen)
+                return parser.SkipDeclarations<CssDocumentRule>(token);
+
+            parser.FillRules(rule);
             return rule;
         }

@@ -258,11 +256,13 @@
         internal static CssKeyframesRule CreateKeyframesRule(CssParser parser)
         {
             var token = parser._tokenizer.Get();
-            var rule = parser.InKeyframesName(ref token);
-
-            if (token.Type == CssTokenType.CurlyBracketOpen)
-                parser.FillKeyframeRules(rule);
-
+            var rule = new CssKeyframesRule();
+            rule.Name = parser.InRuleName(ref token);
+
+            if (token.Type != CssTokenType.CurlyBracketOpen)
+                return parser.SkipDeclarations<CssKeyframesRule>(token);
+
+            parser.FillKeyframeRules(rule);
             return rule;
         }

@@ -274,14 +274,9 @@
         /// <returns>The generated namespace rule.</returns>
         internal static CssNamespaceRule CreateNamespaceRule(CssParser parser)
         {
+            var token = parser._tokenizer.Get();
             var rule = new CssNamespaceRule();
-            var token = parser._tokenizer.Get();
-
-            if (token.Type == CssTokenType.Ident)
-            {
-                rule.Prefix = token.Data;
-                token = parser._tokenizer.Get();
-            }
+            rule.Prefix = parser.InRuleName(ref token);

             if (token.Type == CssTokenType.Url)
                 rule.NamespaceUri = token.Data;
@@ -298,11 +293,11 @@
         /// <returns>The generated rule.</returns>
         internal static CssCharsetRule CreateCharsetRule(CssParser parser)
         {
+            var token = parser._tokenizer.Get();
             var rule = new CssCharsetRule();
-            var token = parser._tokenizer.Get();

             if (token.Type == CssTokenType.String)
-                rule.CharacterSet = ((CssStringToken)token).Data;
+                rule.CharacterSet = token.Data;

             parser._tokenizer.JumpToNextSemicolon();
             return rule;
@@ -316,18 +311,18 @@
         /// <returns>The created rule.</returns>
         internal static CssImportRule CreateImportRule(CssParser parser)
         {
-            var import = new CssImportRule();
-            var token = parser._tokenizer.Get();
+            var token = parser._tokenizer.Get();
+            var rule = new CssImportRule();

             if (token.Is(CssTokenType.String, CssTokenType.Url))
             {
-                import.Href = token.Data;
+                rule.Href = token.Data;
                 token = parser._tokenizer.Get();
-                import.Media = parser.InMediaList(ref token);
+                rule.Media = parser.InMediaList(ref token);
             }

             parser._tokenizer.JumpToNextSemicolon();
-            return import;
+            return rule;
         }

         #endregion
@@ -345,15 +340,7 @@
             {
                 case CssTokenType.AtKeyword:
                 {
-                    var rule = this.CreateAtRule(token.Data);
-
-                    if (rule == null)
-                    {
-                        RaiseErrorOccurred(CssParseError.UnknownAtRule, token);
-                        _tokenizer.SkipUnknownRule();
-                    }
-
-                    return rule;
+                    return this.CreateAtRule(token.Data);
                 }
                 case CssTokenType.CurlyBracketOpen:
                 {
@@ -513,22 +500,6 @@
         #endregion

         #region Keyframes
-
-        /// <summary>
-        /// Before the name of an @keyframes rule has been detected.
-        /// </summary>
-        CssKeyframesRule InKeyframesName(ref CssToken token)
-        {
-            var rule = new CssKeyframesRule();
-
-            if (token.Type == CssTokenType.Ident)
-            {
-                rule.Name = token.Data;
-                token = _tokenizer.Get();
-            }
-
-            return rule;
-        }

         /// <summary>
         /// Before the curly bracket of an @keyframes rule has been seen.
@@ -723,6 +694,22 @@
         #region Value

         /// <summary>
+        /// Before the name of a rule has been detected.
+        /// </summary>
+        String InRuleName(ref CssToken token)
+        {
+            var name = String.Empty;
+
+            if (token.Type == CssTokenType.Ident)
+            {
+                name = token.Data;
+                token = _tokenizer.Get();
+            }
+
+            return name;
+        }
+
+        /// <summary>
         /// Called before any token in the value regime had been seen.
         /// </summary>
         CssValue InValue(ref CssToken token)
@@ -758,8 +745,6 @@

             if (condition != null)
             {
-                token = _tokenizer.Get();
-
                 if (token.Data.Equals(Keywords.And, StringComparison.OrdinalIgnoreCase))
                 {
                     token = _tokenizer.Get();
@@ -779,10 +764,12 @@

         CssSupportsRule.ICondition ExtractCondition(ref CssToken token)
         {
+            var condition = default(CssSupportsRule.ICondition);
+
             if (token.Type == CssTokenType.RoundBracketOpen)
             {
                 token = _tokenizer.Get();
-                var condition = InCondition(ref token);
+                condition = InCondition(ref token);

                 if (condition != null)
                     condition = new CssSupportsRule.GroupCondition(condition);
@@ -790,18 +777,18 @@
                     condition = DeclCondition(ref token);

                 if (token.Type == CssTokenType.RoundBracketClose)
-                    return condition;
+                    token = _tokenizer.Get();
             }
             else if (token.Data.Equals(Keywords.Not, StringComparison.OrdinalIgnoreCase))
             {
                 token = _tokenizer.Get();
-                var condition = ExtractCondition(ref token);
+                condition = ExtractCondition(ref token);

                 if (condition != null)
-                    return new CssSupportsRule.NotCondition(condition);
-            }
-
-            return null;
+                    condition = new CssSupportsRule.NotCondition(condition);
+            }
+
+            return condition;
         }

         CssSupportsRule.ICondition DeclCondition(ref CssToken token)
@@ -818,12 +805,10 @@
             if (token.Type == CssTokenType.Colon)
             {
                 var result = InValue(ref token);
+                property.IsImportant = _value.IsImportant;

                 if (result != null)
-                {
-                    property.IsImportant = _value.IsImportant;
                     return new CssSupportsRule.DeclarationCondition(property, result);
-                }
             }

             return null;
@@ -842,7 +827,6 @@
                     break;

                 list.Add(condition);
-                token = _tokenizer.Get();

                 if (!token.Data.Equals(connector, StringComparison.OrdinalIgnoreCase))
                     break;
@@ -856,6 +840,13 @@
         #endregion

         #region Helpers
+
+        T SkipDeclarations<T>(CssToken token)
+        {
+            RaiseErrorOccurred(CssParseError.UnknownAtRule, token);
+            _tokenizer.SkipUnknownRule();
+            return default(T);
+        }

         /// <summary>
         /// The kernel that is pulling the tokens into the parser.


Removed even more operations

Removed even more operations

--- Assets/MixedRealityToolkit/Utilities/AssetScriptReferenceRetargeter.cs
+++ Assets/MixedRealityToolkit/Utilities/AssetScriptReferenceRetargeter.cs
@@ -82,7 +82,7 @@
         }

         private const string YamlPrefix = "%YAML 1.1";
-
+
         private static readonly Dictionary<string, string> sourceToOutputFolders = new Dictionary<string, string>
         {
             {"Library/PlayerDataCache/WindowsStoreApps", "UAP" },
@@ -101,6 +101,7 @@
         {
             try
             {
+                Debug.Log("Starting to Retarget Assets.");
                 RunRetargetToDLL();
                 Debug.Log("Complete.");
             }
@@ -113,10 +114,10 @@

         private static void RunRetargetToDLL()
         {
-            string[] allFilesUnderAssets = Directory.GetFiles(Application.dataPath, "*", SearchOption.AllDirectories);
-
-            Dictionary<string, ClassInformation> scriptFilesReferences = ProcessScripts(allFilesUnderAssets);
-            Debug.Log($"Found {scriptFilesReferences.Count} script file references.");
+            //string[] allFilesUnderAssets = Directory.GetFiles(Application.dataPath, "*", SearchOption.AllDirectories);
+
+            //Dictionary<string, ClassInformation> scriptFilesReferences = ProcessScripts(allFilesUnderAssets);
+            //Debug.Log($"Found {scriptFilesReferences.Count} script file references.");

             //Dictionary<string, ClassInformation> compiledClassReferences = ProcessCompiledDLLs("PackagedAssemblies", Application.dataPath.Replace("Assets", "NuGet/Plugins/Editor"));
             //Debug.Log($"Found {compiledClassReferences.Count} compiled class references.");
@@ -377,8 +378,8 @@
             List<DirectoryInfo> outputDirectories = new List<DirectoryInfo>();
             string playerDataCachePath = Application.dataPath.Replace("Assets", "Library/PlayerDataCache");
             DirectoryInfo playerDataCahce = new DirectoryInfo(playerDataCachePath);
-
-            foreach(KeyValuePair<string, string> sourceToOutputPair in sourceToOutputFolders)
+
+            foreach (KeyValuePair<string, string> sourceToOutputPair in sourceToOutputFolders)
             {
                 DirectoryInfo directory = new DirectoryInfo(Application.dataPath.Replace("Assets", sourceToOutputPair.Key));
                 if (!directory.Exists)
@@ -492,7 +493,7 @@
                             File.WriteAllLines(metaFilePath, metaFileContent);
                         }
                     }
-                }
+                }
             }
         }

@@ -520,10 +521,10 @@
         }

         private static void RecursiveFolderCleanup(DirectoryInfo folder)
-        {
+        {
             foreach (DirectoryInfo subFolder in folder.GetDirectories())
             {
-                RecursiveFolderCleanup(subFolder);
+                RecursiveFolderCleanup(subFolder);
             }

             string fileCheck;


removed unused node types

removed unused node types

--- Assets/MixedRealityToolkit/_Core/Devices/OpenVR/OpenVRDeviceManager.cs
+++ Assets/MixedRealityToolkit/_Core/Devices/OpenVR/OpenVRDeviceManager.cs
@@ -67,13 +67,6 @@
         }

         #region Unity InteractionManager Events
-
-        private void InputTracking_nodeAdded(XRNodeState obj)
-        {
-        }
-        private void InputTracking_nodeRemoved(XRNodeState obj)
-        {
-        }

         private void InputTracking_trackingAcquired(XRNodeState obj)
         {


- Fixing issue with chat messages containing quotes not properly being send up

--- Glimesh/Glimesh.Base/Models/Clients/Chat/ChatSendMessagePacketModel.cs
+++ Glimesh/Glimesh.Base/Models/Clients/Chat/ChatSendMessagePacketModel.cs
@@ -17,6 +17,8 @@
         public ChatSendMessagePacketModel(string channelID, string message)
             : base()
         {
+            message = message.Replace("\"", "\\\"");
+
             this.Topic = AbsintheControlTopicName;
             this.Event = DocEventName;
             this.Payload["query"] = string.Format(MessageMutationPayload, channelID, message);


extracted method

extracted method

--- HQC-Part-II/homework-refactoring/MatrixPath.RefactoredOriginal/Path.cs
+++ HQC-Part-II/homework-refactoring/MatrixPath.RefactoredOriginal/Path.cs
@@ -85,13 +85,28 @@
             var nextCellValue = 1;
             var rowCoordinate = 0;
             var colCoordinate = 0;
+
+            FillTheMatrixUntilADeadEnd(theMatrix, ref rowCoordinate, ref colCoordinate, ref nextCellValue);
+            FindAnEmptyCellToJumpTo(theMatrix, out rowCoordinate, out colCoordinate);
+            while (rowCoordinate != 0 && colCoordinate != 0)
+            {
+                nextCellValue++;
+                FillTheMatrixUntilADeadEnd(theMatrix, ref rowCoordinate, ref colCoordinate, ref nextCellValue);
+                FindAnEmptyCellToJumpTo(theMatrix, out rowCoordinate, out colCoordinate);
+            }
+
+            PrintTheMatrix(theMatrix);
+        }
+
+        private static void FillTheMatrixUntilADeadEnd(int[,] theMatrix, ref int rowCoordinate, ref int colCoordinate, ref int nextCellValue)
+        {
             var deltaX = 1;
             var deltaY = 1;
+            var matrixSize = theMatrix.GetLength(0);

             while (true)
             {
                 theMatrix[rowCoordinate, colCoordinate] = nextCellValue;
-
                 if (!CheckIfNextMatrixCellIsEmpty(theMatrix, rowCoordinate, colCoordinate))
                 {
                     break;
@@ -113,42 +128,6 @@
                 colCoordinate += deltaY;
                 nextCellValue++;
             }
-
-            FindAnEmptyCellToJumpTo(theMatrix, out rowCoordinate, out colCoordinate);
-
-            if (rowCoordinate != 0 && colCoordinate != 0)
-            {
-                nextCellValue++;
-                deltaX = 1;
-                deltaY = 1;
-
-                while (true)
-                {
-                    theMatrix[rowCoordinate, colCoordinate] = nextCellValue;
-                    if (!CheckIfNextMatrixCellIsEmpty(theMatrix, rowCoordinate, colCoordinate))
-                    {
-                        break;
-                    }
-
-                    var nextRowCoordinateCandidate = rowCoordinate + deltaX;
-                    var nextColCoordinateCandidate = colCoordinate + deltaY;
-                    var isOutOfBounds = CheckIfCoordinateCandidateIsOutOfBounds(matrixSize, nextRowCoordinateCandidate, nextColCoordinateCandidate);
-                    while (isOutOfBounds || theMatrix[rowCoordinate + deltaX, colCoordinate + deltaY] != 0)
-                    {
-                        ChangeDirection(ref deltaX, ref deltaY);
-
-                        nextRowCoordinateCandidate = rowCoordinate + deltaX;
-                        nextColCoordinateCandidate = colCoordinate + deltaY;
-                        isOutOfBounds = CheckIfCoordinateCandidateIsOutOfBounds(matrixSize, nextRowCoordinateCandidate, nextColCoordinateCandidate);
-                    }
-
-                    rowCoordinate += deltaX;
-                    colCoordinate += deltaY;
-                    nextCellValue++;
-                }
-            }
-
-            PrintTheMatrix(theMatrix);
         }

         private static void PrintTheMatrix(int[,] matrix)


front-end grouplevel

front-end grouplevel


fix Button contructors
table.ColumnSpacing
table.RowSpacing
thanks to Marius Andreiana <mandreiana@rdslink.ro>
for noticing and providing a similar patch

svn path=/trunk/gtk-sharp/; revision=20324

--- sample/DbClient/client.cs
+++ sample/DbClient/client.cs
@@ -130,7 +130,7 @@

 		tableau = new Gtk.Table ((uint) dataList.Count + 1, 3, false);
 		DrawTitles (tableau);
-		tableau.ColSpacings = 10;
+		tableau.ColumnSpacing = 10;
 		uint i = 1;
 		foreach (Record r in dataList) {
 			tableau.Attach (new Label (r.ID.ToString ()), 0, 1, i, i + 1);
@@ -181,13 +181,13 @@
 		dialog.VBox.PackStart (frame, true, true, 0);

 		Button button = null;
-		button = Button.NewFromStock (Stock.Add);
+		button = new Button (Stock.Add);
 		button.Clicked += new EventHandler (Insert_Action);
 		button.CanDefault = true;
 		dialog.ActionArea.PackStart (button, true, true, 0);
 		button.GrabDefault ();

-		button = Button.NewFromStock (Stock.Cancel);
+		button = new Button (Stock.Cancel);
 		button.Clicked += new EventHandler (Dialog_Cancel);
 		dialog.ActionArea.PackStart (button, true, true, 0);
 		dialog.Modal = true;
@@ -211,13 +211,13 @@
 		dialog.VBox.PackStart (frame, true, true, 0);

 		Button button = null;
-		button = Button.NewFromStock (Stock.Remove);
+		button = new Button (Stock.Remove);
 		button.Clicked += new EventHandler (Remove_Action);
 		button.CanDefault = true;
 		dialog.ActionArea.PackStart (button, true, true, 0);
 		button.GrabDefault ();

-		button = Button.NewFromStock (Stock.Cancel);
+		button = new Button (Stock.Cancel);
 		button.Clicked += new EventHandler (Dialog_Cancel);
 		dialog.ActionArea.PackStart (button, true, true, 0);

@@ -233,8 +233,8 @@

 		Table table = new Table (3, 3, false);
 		hbox.PackStart (table);
-		table.ColSpacings = 4;
-		table.RowSpacings = 4;
+		table.ColumnSpacing = 4;
+		table.RowSpacing = 4;
 		Label label = null;

 		label = Label.NewWithMnemonic ("_ID");
@@ -275,13 +275,13 @@
 		dialog.VBox.PackStart (frame, true, true, 0);

 		Button button = null;
-		button = Button.NewFromStock (Stock.Apply);
+		button = new Button (Stock.Apply);
 		button.Clicked += new EventHandler (Update_Action);
 		button.CanDefault = true;
 		dialog.ActionArea.PackStart (button, true, true, 0);
 		button.GrabDefault ();

-		button = Button.NewFromStock (Stock.Cancel);
+		button = new Button (Stock.Cancel);
 		button.Clicked += new EventHandler (Dialog_Cancel);
 		dialog.ActionArea.PackStart (button, true, true, 0);


some ordering in Startup.Configur

some ordering in Startup.Configur

--- samples/WebApi/Startup.cs
+++ samples/WebApi/Startup.cs
@@ -67,7 +67,8 @@
       // Identity
       var authority = this.Configuration["IdentityServer:Authority"];
       services
-        .AddIdentityServer(o => {
+        .AddIdentityServer(o =>
+        {
           o.IssuerUri = authority;
           o.Authentication.CookieAuthenticationScheme = "dummy";
         })
@@ -173,10 +174,10 @@
         });
       }

+      app.UseFileServer();
+
       app.UseIdentityServer();
       // app.UseAuthentication();
-
-      app.UseFileServer();

       app.SubscribeMessageHandlers();


RA-1456 changed wording of tests search result mapper tests.

--- src/Esfa.Vacancy.UnitTests/SearchApprenticeship/Api/Mappings/GivenASearchResponseMapper/WhenMappingApprenticeshipSummary.cs
+++ src/Esfa.Vacancy.UnitTests/SearchApprenticeship/Api/Mappings/GivenASearchResponseMapper/WhenMappingApprenticeshipSummary.cs
@@ -21,9 +21,9 @@
             _mapper = config.CreateMapper();
         }

-        [TestCase(1, null, ApiTypes.TrainingType.Standard, TestName = "Then load Standard type")]
-        [TestCase(null, "10", ApiTypes.TrainingType.Framework, TestName = "Then load Framework type")]
-        public void WhenMappingTraingingDetails(int? standardId, string frameworkCode, ApiTypes.TrainingType expectedTrainingType)
+        [TestCase(1, null, ApiTypes.TrainingType.Standard, TestName = "And has Standard ID then TrainingType set to Standard")]
+        [TestCase(null, "10", ApiTypes.TrainingType.Framework, TestName = "And has Framework Code then TrainingType set to Framework")]
+        public void AndMappingTrainingType(int? standardId, string frameworkCode, ApiTypes.TrainingType expectedTrainingType)
         {
             var expectedTrainingCode = standardId.HasValue ? standardId.ToString() : frameworkCode;
             var domainType = new ApprenticeshipSummary()
@@ -39,7 +39,7 @@
         }

         [Test]
-        public void WhenMappingGeoCoordinates()
+        public void ThenGeoCoordinatesMapCorrectly()
         {
             var domainType = new ApprenticeshipSummary
             {
@@ -54,7 +54,7 @@
         }

         [Test]
-        public void WhenMappingShortDescription()
+        public void ThenShortDescriptionMapsCorrectly()
         {
             var description = "desc";
             var domainType = new ApprenticeshipSummary
@@ -68,7 +68,7 @@
         }

         [Test]
-        public void WhenMappingTrainingProviderName()
+        public void ThenTrainingProviderNameMapsCorrectly()
         {
             var providerName = "desc";
             var domainType = new ApprenticeshipSummary
@@ -83,7 +83,7 @@

         [TestCase("National", true, TestName = "And Location Type is National Then map set IsNationWide to true")]
         [TestCase("NonNational", false, TestName = "And Location Type is NonNational Then map set IsNationWide to false")]
-        public void WhenMappingIsNationWide(string value, bool expectedResult)
+        public void AndMappingIsNationWide(string value, bool expectedResult)
         {
             var domainType = new ApprenticeshipSummary
             {


Add function return to entrance scene, adjust initialize sequence

--- Assets/Meow/Components/MainGame.cs
+++ Assets/Meow/Components/MainGame.cs
@@ -23,6 +23,7 @@
         public string LuaScriptRootFolderName;
         public string SceneRootFolderPath;
         public string MainSceneName = "01Main.unity";
+        public string EntranceScenePath;

         public bool IsAutoDownload;

@@ -59,7 +60,10 @@
             if (IsAutoDownload)
             {
                 yield return Download();
-                yield return Initialize();
+                StartGameButton.onClick.AddListener(() =>
+                {
+                    StartInitializeCoroutine(null);
+                });
             }
         }

@@ -73,6 +77,8 @@
             _updateOperation = _updater.UpdateFromRemoteAsset();
             _totalCount = _updateOperation.RemainBundleCount;
             yield return _updateOperation;
+
+            StartGameButton.gameObject.SetActive(true);
         }

         private IEnumerator Initialize()
@@ -83,11 +89,8 @@

             _luaHelper.Initialize(_loader, _updater);

-            StartGameButton.gameObject.SetActive(true);
-            StartGameButton.onClick.AddListener(() =>
-            {
-                LoadLevelAsync(Path.Combine(SceneRootFolderPath, MainSceneName));
-            });
+            LoadLevelAsync(Path.Combine(SceneRootFolderPath, MainSceneName));
+
         }

         private void Update()
@@ -114,6 +117,18 @@
             StartCoroutine(op);
             return op;
         }
+
+        public void ReturnToEntrance()
+        {
+            SceneManager.LoadScene(EntranceScenePath);
+
+            foreach (var mainGame in _mainGames.Values)
+            {
+                mainGame._loader.UnLoadAssetBundles();
+                Destroy(mainGame.gameObject);
+            }
+            _mainGames.Clear();
+        }

         public static MainGame GetInstance(string projectName)
         {
@@ -137,9 +152,16 @@
         {
             StartCoroutine(Download());
         }
-
-        public void StartInitializeCoroutine()
+
+        public void StartInitializeCoroutine(string sourceProjectName)
         {
+            if (!string.IsNullOrEmpty(sourceProjectName))
+            {
+                var mainGame = _mainGames[sourceProjectName];
+                mainGame._loader.UnLoadAssetBundles();
+                _mainGames.Remove(sourceProjectName);
+                Destroy(mainGame.gameObject);
+            }
             StartCoroutine(Initialize());
         }


Simpler

Simpler

--- Gigas/Femto.cs
+++ Gigas/Femto.cs
@@ -112,20 +112,17 @@
             // Write out the Arrayxs
             writer.WriteLine("    public static class EntitySet");
             writer.WriteLine("    {");
-            foreach (var entityClass in entityClasses)
+
+            // Write the Add functions
+            for (int i = 0; i < entityClasses.Count; i++)
             {
+                var entityClass = entityClasses[i];
                 var entityName = $"{entityClass}s";
                 var entityId = $"{entityClass}Ids";
+                var entityIndex = $"{entityClass}Index";

                 writer.WriteLine($"        public static Arrayx<int> {entityId} = new Arrayx<int>();");
                 writer.WriteLine($"        public static Arrayx<{entityClass}> {entityName} = new Arrayx<{entityClass}>();");
-            }
-
-            // Write the Add functions
-            foreach (var entityClass in entityClasses)
-            {
-                var entityName = $"{entityClass}s";
-                var entityId = $"{entityClass}Ids";

                 writer.WriteLine();
                 writer.WriteLine($"        public static void Add{entityClass}({entityClass} component)");
@@ -148,7 +145,6 @@
                 writer.WriteLine();
                 writer.WriteLine($"            {entityId}.Elements[{entityId}.Length++] = component.gameObject.GetInstanceID();");
                 writer.WriteLine($"            {entityName}.Elements[{entityName}.Length++] = component;");
-                // writer.WriteLine($"            component.enabled = true; ");
                 writer.WriteLine();
                 writer.WriteLine($"            // Resize check");
                 writer.WriteLine();
@@ -160,21 +156,18 @@
                 writer.WriteLine($"                {entityName}.Size *= 2;");
                 writer.WriteLine($"                Array.Resize(ref {entityName}.Elements, {entityName}.Size);");
                 writer.WriteLine($"            }}");
-                writer.WriteLine($"        }}");
-            }
-
-            // Write the Remove functions for GameObjects
-            foreach (var entityClass in entityClasses)
-            {
-                var entityName = $"{entityClass}s";
-                var entityId = $"{entityClass}Ids";
-
-                writer.WriteLine();
-                writer.WriteLine($"        public static void Remove{entityClass}(GameObject gameObject)");
-                writer.WriteLine($"        {{");
-                writer.WriteLine($"            // Finding the index");
-                writer.WriteLine();
-                writer.WriteLine($"            var id = gameObject.GetInstanceID();");
+                writer.WriteLine();
+                writer.WriteLine($"            // Enable");
+                writer.WriteLine();
+                writer.WriteLine($"            component.enabled = true; ");
+                writer.WriteLine($"        }}");
+
+                writer.WriteLine();
+                writer.WriteLine($"        public static void Remove{entityClass}({entityClass} component)");
+                writer.WriteLine($"        {{");
+                writer.WriteLine($"            // Find the index");
+                writer.WriteLine();
+                writer.WriteLine($"            var id = component.gameObject.GetInstanceID();");
                 writer.WriteLine($"            var indexToRemove = -1;");
                 writer.WriteLine($"            for (int i = 0; i < {entityId}.Length; i++)");
                 writer.WriteLine($"            {{");
@@ -199,229 +192,10 @@
                 writer.WriteLine($"                {entityName}.Length - indexToRemove - 1);");
                 writer.WriteLine($"            {entityName}.Length--;");
                 writer.WriteLine();
-                writer.WriteLine($"            // Component destruction");
-                writer.WriteLine();
-                writer.WriteLine($"            if (gameObject != null)");
-                writer.WriteLine($"                GameObject.Destroy(gameObject.GetComponent<{entityClass}>());");
-                writer.WriteLine($"        }}");
-            }
-
-            // Write the Remove functions
-            foreach (var entityClass in entityClasses)
-            {
-                var entityName = $"{entityClass}s";
-                var entityId = $"{entityClass}Ids";
-
-                writer.WriteLine();
-                writer.WriteLine($"        public static void Remove{entityClass}({entityClass} component)");
-                writer.WriteLine($"        {{");
-                writer.WriteLine($"            // Finding the index");
-                writer.WriteLine();
-                writer.WriteLine($"            var id = component.gameObject.GetInstanceID();");
-                writer.WriteLine($"            var indexToRemove = -1;");
-                writer.WriteLine($"            for (int i = 0; i < {entityId}.Length; i++)");
-                writer.WriteLine($"            {{");
-                writer.WriteLine($"                if ({entityId}.Elements[i] == id)");
-                writer.WriteLine($"                {{");
-                writer.WriteLine($"                    indexToRemove = i;");
-                writer.WriteLine($"                    break;");
-                writer.WriteLine($"                }}");
-                writer.WriteLine($"            }}");
-                writer.WriteLine();
-                writer.WriteLine($"            // Overwrite");
-                writer.WriteLine();
-                writer.WriteLine($"            Array.Copy(");
-                writer.WriteLine($"                {entityId}.Elements, indexToRemove + 1,");
-                writer.WriteLine($"                {entityId}.Elements, indexToRemove,");
-                writer.WriteLine($"                {entityId}.Length - indexToRemove - 1);");
-                writer.WriteLine($"            {entityId}.Length--;");
-                writer.WriteLine();
-                writer.WriteLine($"            Array.Copy(");
-                writer.WriteLine($"                {entityName}.Elements, indexToRemove + 1,");
-                writer.WriteLine($"                {entityName}.Elements, indexToRemove,");
-                writer.WriteLine($"                {entityName}.Length - indexToRemove - 1);");
-                writer.WriteLine($"            {entityName}.Length--;");
-                writer.WriteLine();
-                writer.WriteLine($"            // Component destruction");
-                writer.WriteLine();
-                writer.WriteLine($"            if (component != null)");
-                writer.WriteLine($"                GameObject.Destroy(component);");
-                writer.WriteLine($"        }}");
-            }
-
-            // Write the Disable functions for GameObjects
-            // foreach (var entityClass in entityClasses)
-            // {
-            //     var entityName = CamelCase(entityClass);
-            //     var entityId = $"{CamelCase(entityClass)}Id";
-
-            //     writer.WriteLine();
-            //     writer.WriteLine($"        public static void Disable{entityClass}(GameObject gameObject)");
-            //     writer.WriteLine($"        {{");
-            //     writer.WriteLine($"            // Finding the index");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            var id = gameObject.GetInstanceID();");
-            //     writer.WriteLine($"            var indexToRemove = -1;");
-            //     writer.WriteLine($"            for (int i = 0; i < {entityId}.Length; i++)");
-            //     writer.WriteLine($"            {{");
-            //     writer.WriteLine($"                if ({entityId}.Elements[i] == id)");
-            //     writer.WriteLine($"                {{");
-            //     writer.WriteLine($"                    indexToRemove = i;");
-            //     writer.WriteLine($"                    break;");
-            //     writer.WriteLine($"                }}");
-            //     writer.WriteLine($"            }}");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            // Overwrite");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            Array.Copy(");
-            //     writer.WriteLine($"                {entityId}.Elements, indexToRemove + 1,");
-            //     writer.WriteLine($"                {entityId}.Elements, indexToRemove,");
-            //     writer.WriteLine($"                {entityId}.Length - indexToRemove - 1);");
-            //     writer.WriteLine($"            {entityId}.Length--;");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            Array.Copy(");
-            //     writer.WriteLine($"                {entityName}.Elements, indexToRemove + 1,");
-            //     writer.WriteLine($"                {entityName}.Elements, indexToRemove,");
-            //     writer.WriteLine($"                {entityName}.Length - indexToRemove - 1);");
-            //     writer.WriteLine($"            {entityName}.Length--;");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            // Disable");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            gameObject.GetComponent<{entityClass}>().enabled = false;");
-            //     writer.WriteLine($"        }}");
-            // }
-
-            // Write the Disable functions
-            // foreach (var entityClass in entityClasses)
-            // {
-            //     var entityName = CamelCase(entityClass);
-            //     var entityId = $"{CamelCase(entityClass)}Id";
-
-            //     writer.WriteLine();
-            //     writer.WriteLine($"        public static void Disable{entityClass}({entityClass} component)");
-            //     writer.WriteLine($"        {{");
-            //     writer.WriteLine($"            // Finding the index");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            var id = component.gameObject.GetInstanceID();");
-            //     writer.WriteLine($"            var indexToRemove = -1;");
-            //     writer.WriteLine($"            for (int i = 0; i < {entityId}.Length; i++)");
-            //     writer.WriteLine($"            {{");
-            //     writer.WriteLine($"                if ({entityId}.Elements[i] == id)");
-            //     writer.WriteLine($"                {{");
-            //     writer.WriteLine($"                    indexToRemove = i;");
-            //     writer.WriteLine($"                    break;");
-            //     writer.WriteLine($"                }}");
-            //     writer.WriteLine($"            }}");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            // Overwrite");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            Array.Copy(");
-            //     writer.WriteLine($"                {entityId}.Elements, indexToRemove + 1,");
-            //     writer.WriteLine($"                {entityId}.Elements, indexToRemove,");
-            //     writer.WriteLine($"                {entityId}.Length - indexToRemove - 1);");
-            //     writer.WriteLine($"            {entityId}.Length--;");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            Array.Copy(");
-            //     writer.WriteLine($"                {entityName}.Elements, indexToRemove + 1,");
-            //     writer.WriteLine($"                {entityName}.Elements, indexToRemove,");
-            //     writer.WriteLine($"                {entityName}.Length - indexToRemove - 1);");
-            //     writer.WriteLine($"            {entityName}.Length--;");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            // Disable");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            component.enabled = false;");
-            //     writer.WriteLine($"        }}");
-            // }
-
-            // Write the Enable functions for GameObjects
-            // foreach (var entityClass in entityClasses)
-            // {
-            //     var entityName = CamelCase(entityClass);
-            //     var entityId = $"{CamelCase(entityClass)}Id";
-
-            //     writer.WriteLine();
-            //     writer.WriteLine($"        public static void Enable{entityClass}(GameObject gameObject)");
-            //     writer.WriteLine($"        {{");
-            //     writer.WriteLine($"            // Finding the index");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            var id = gameObject.GetInstanceID();");
-            //     writer.WriteLine($"            var indexToRemove = -1;");
-            //     writer.WriteLine($"            for (int i = 0; i < {entityId}.Length; i++)");
-            //     writer.WriteLine($"            {{");
-            //     writer.WriteLine($"                if ({entityId}.Elements[i] == id)");
-            //     writer.WriteLine($"                {{");
-            //     writer.WriteLine($"                    indexToRemove = i;");
-            //     writer.WriteLine($"                    break;");
-            //     writer.WriteLine($"                }}");
-            //     writer.WriteLine($"            }}");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            // Overwrite");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            Array.Copy(");
-            //     writer.WriteLine($"                {entityId}.Elements, indexToRemove + 1,");
-            //     writer.WriteLine($"                {entityId}.Elements, indexToRemove,");
-            //     writer.WriteLine($"                {entityId}.Length - indexToRemove - 1);");
-            //     writer.WriteLine($"            {entityId}.Length--;");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            Array.Copy(");
-            //     writer.WriteLine($"                {entityName}.Elements, indexToRemove + 1,");
-            //     writer.WriteLine($"                {entityName}.Elements, indexToRemove,");
-            //     writer.WriteLine($"                {entityName}.Length - indexToRemove - 1);");
-            //     writer.WriteLine($"            {entityName}.Length--;");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            // Enable");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            gameObject.GetComponent<{entityClass}>().enabled = true;");
-            //     writer.WriteLine($"        }}");
-            // }
-
-            // Write the Enable functions
-            // foreach (var entityClass in entityClasses)
-            // {
-            //     var entityName = CamelCase(entityClass);
-            //     var entityId = $"{CamelCase(entityClass)}Id";
-
-            //     writer.WriteLine();
-            //     writer.WriteLine($"        public static void Enable{entityClass}({entityClass} component)");
-            //     writer.WriteLine($"        {{");
-            //     writer.WriteLine($"            // Finding the index");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            var id = component.gameObject.GetInstanceID();");
-            //     writer.WriteLine($"            var indexToRemove = -1;");
-            //     writer.WriteLine($"            for (int i = 0; i < {entityId}.Length; i++)");
-            //     writer.WriteLine($"            {{");
-            //     writer.WriteLine($"                if ({entityId}.Elements[i] == id)");
-            //     writer.WriteLine($"                {{");
-            //     writer.WriteLine($"                    indexToRemove = i;");
-            //     writer.WriteLine($"                    break;");
-            //     writer.WriteLine($"                }}");
-            //     writer.WriteLine($"            }}");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            // Overwrite");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            Array.Copy(");
-            //     writer.WriteLine($"                {entityId}.Elements, indexToRemove + 1,");
-            //     writer.WriteLine($"                {entityId}.Elements, indexToRemove,");
-            //     writer.WriteLine($"                {entityId}.Length - indexToRemove - 1);");
-            //     writer.WriteLine($"            {entityId}.Length--;");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            Array.Copy(");
-            //     writer.WriteLine($"                {entityName}.Elements, indexToRemove + 1,");
-            //     writer.WriteLine($"                {entityName}.Elements, indexToRemove,");
-            //     writer.WriteLine($"                {entityName}.Length - indexToRemove - 1);");
-            //     writer.WriteLine($"            {entityName}.Length--;");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            // Enable");
-            //     writer.WriteLine();
-            //     writer.WriteLine($"            component.enabled = true;");
-            //     writer.WriteLine($"        }}");
-            // }
-
-            // Write the Get functions for multiple components
-            foreach (var entityClass in entityClasses)
-            {
-                var entityName = $"{entityClass}s";
-                var entityId = $"{entityClass}Ids";
+                writer.WriteLine($"            // Disable");
+                writer.WriteLine();
+                writer.WriteLine($"            component.enabled = false;");
+                writer.WriteLine($"        }}");

                 writer.WriteLine();
                 writer.WriteLine($"        public static Arrayx<{entityClass}> Get{entityClass}(params Arrayx<int>[] ids)");
@@ -435,14 +209,6 @@
                 writer.WriteLine();
                 writer.WriteLine($"            return Gigas.Get<{entityClass}>(idsWith{entityClass}, EntitySet.{entityName});");
                 writer.WriteLine($"        }}");
-            }
-
-            // Write the Get functions for single components
-            foreach (var entityClass in entityClasses)
-            {
-                var entityName = $"{entityClass}s";
-                var entityId = $"{entityClass}Ids";
-                var entityIndex = $"{entityClass}Index";

                 writer.WriteLine();
                 writer.WriteLine($"        private static Dictionary<int, int> {entityIndex} = new Dictionary<int, int>();");
@@ -470,6 +236,9 @@
                 writer.WriteLine();
                 writer.WriteLine($"            return {entityName}.Elements[index];");
                 writer.WriteLine($"        }}");
+
+                if (i < entityClasses.Count - 1)
+                    writer.WriteLine();
             }

             // End of class
@@ -497,4 +266,8 @@
     }
 }

-#endif+#endif
+
+// Truth
+
+// 1 The GameObject GetInstanceID() is the Entity id.


Do comparison with layers in registry case insensitive

* Prevents the warning about layers being mis-registered popping up a
  false positive

--- renderdocui/Code/Helpers.cs
+++ renderdocui/Code/Helpers.cs
@@ -243,7 +243,7 @@

             foreach (var n in names)
             {
-                if(Path.GetFullPath(n) == myJSON)
+                if(String.Compare(Path.GetFullPath(n), myJSON, StringComparison.CurrentCultureIgnoreCase) == 0)
                 {
                     thisRegistered = true;
                 }


Fix minor bug.

Fix minor bug.

--- IPA/Program.cs
+++ IPA/Program.cs
@@ -94,7 +94,8 @@
             Console.Error.Write("ERROR: " + message);
             if (!Environment.CommandLine.Contains("--nowait"))
             {
-                Console.In.ReadToEnd();
+                Console.WriteLine("\n\n[Press any key to quit]");
+                Console.ReadKey();
             }
             Environment.Exit(1);
         }


Reuse sunken track setup code for tunneled track

--- Initializer.cs
+++ Initializer.cs
@@ -158,36 +158,11 @@

         private static void SetupTunnelPrefab(NetInfo tunnelPrefab, NetInfo originalPrefab)
         {
-            var stationAI = tunnelPrefab.GetComponent<TrainTrackAI>();
-            stationAI.m_tunnelInfo = tunnelPrefab;
-
-            tunnelPrefab.m_clipTerrain = false;
-
-            tunnelPrefab.m_createGravel = false;
-            tunnelPrefab.m_createPavement = false;
-            tunnelPrefab.m_createRuining = false;
-
-            tunnelPrefab.m_flattenTerrain = false;
-            tunnelPrefab.m_followTerrain = false;
-
-            tunnelPrefab.m_intersectClass = null;
-
-            tunnelPrefab.m_maxHeight = -1;
-            tunnelPrefab.m_minHeight = -3;
-
-            tunnelPrefab.m_requireSurfaceMaps = false;
-            tunnelPrefab.m_snapBuildingNodes = false;
-
-            tunnelPrefab.m_placementStyle = ItemClass.Placement.Procedural;
-            tunnelPrefab.m_useFixedHeight = true;
-            tunnelPrefab.m_lowerTerrain = false;
-            tunnelPrefab.m_availableIn = ItemClass.Availability.GameAndAsset;
-
+            SetupSunkenPrefab(tunnelPrefab, originalPrefab);
             foreach (var lane in tunnelPrefab.m_lanes)
             {
                 lane.m_laneProps = null;
             }
-
             var metroStation =
                 Resources.FindObjectsOfTypeAll<NetInfo>().FirstOrDefault(netInfo => netInfo.name == "Metro Station Track");
             if (metroStation != null)


PSF Update Alert should be Critical

PSF Update Alert should be Critical

Increased alert status.

--- poshsecframework/Interface/frmMain.cs
+++ poshsecframework/Interface/frmMain.cs
@@ -1747,7 +1747,7 @@
                 DateTime.TryParse(Properties.Settings.Default.LastModuleCheck, out modlast);
                 if (psflast > modlast)
                 {
-                    AddAlert("PoshSec Framework has been updated! Please update your version. Last update: " + psflastmodified, PShell.psmethods.PSAlert.AlertType.Warning, "Github API");
+                    AddAlert("PoshSec Framework has been updated! Please update your version. Last update: " + psflastmodified, PShell.psmethods.PSAlert.AlertType.Critical, "Github API");
                 }
                 if (ghc.Errors.Count > 0)
                 {


edited the repeated symbol code

edited the repeated symbol code


Four4Sample - add Four 4's console app

Four4Sample - add Four 4's console app

--- projects/Four4Sample/Four4/Program.cs
+++ projects/Four4Sample/Four4/Program.cs
@@ -5,12 +5,80 @@
 namespace Four4
 {
     using System;
+    using System.Collections.Generic;

     internal sealed class Program
     {
+        private readonly ExpressionSearch search;
+        private readonly SortedDictionary<int, string> results;
+
+        public Program()
+        {
+            this.search = InitSearch();
+            this.results = new SortedDictionary<int, string>();
+        }
+
+        public void Run()
+        {
+            this.search.Run(this.OnFound);
+
+            Console.WriteLine("Found {0} results.", this.results.Count);
+
+            foreach (KeyValuePair<int, string> result in this.results)
+            {
+                Console.WriteLine("{0} = {1}", result.Key, result.Value);
+            }
+        }
+
         private static void Main(string[] args)
         {
-            Console.WriteLine("Hello World!");
+            new Program().Run();
+        }
+
+        private static ExpressionSearch InitSearch()
+        {
+            ExpressionSearch search = new ExpressionSearch();
+            search.AddBinary("+");
+            search.AddBinary("-");
+            search.AddBinary("*");
+            search.AddBinary("/");
+            search.AddUnary("!");
+            search.AddUnary("R");
+            search.AddOperand("4");
+            search.AddOperand("44");
+            search.AddOperand("444");
+            search.AddOperand("4444");
+            search.AddOperand(Number.PointFour);
+            search.AddOperand(Number.PointFourRepeating);
+            return search;
+        }
+
+        private bool OnFound(Expression expr)
+        {
+            if (expr.NumeralCount != 4)
+            {
+                return true;
+            }
+
+            Number num = expr.Result;
+            if (!num.IsWhole)
+            {
+                return true;
+            }
+
+            int n = (int)num;
+            if (n > 100)
+            {
+                return true;
+            }
+
+            if (this.results.ContainsKey(n))
+            {
+                return true;
+            }
+
+            this.results.Add(n, expr.ToString());
+            return this.results.Count < 100;
         }
     }
 }


Fixed tests

Fixed tests


Fixed issue in try map in directed model mapper ignoring checks on first vehicle.


Fix NRE in ParticleTests that was introduced in previous commit.

--- tests/tests/classes/tests/ParticleTest/ParticleTest.cs
+++ tests/tests/classes/tests/ParticleTest/ParticleTest.cs
@@ -987,6 +987,9 @@

 		public DemoParticleFromFile(string file) : base()
         {
+			if (particleConfigManager == null)
+				particleConfigManager = new Dictionary<string, CCParticleSystemConfig> ();
+
             m_title = file;

         }


(#201) Update serializer settings

(#201) Update serializer settings


incremental commit for bugfix

incremental commit for bugfix

--- Assets/Scripts/AnimationManager.cs
+++ Assets/Scripts/AnimationManager.cs
@@ -297,7 +297,7 @@
 		animator.ResetTrigger("Landed");
 		animator.ResetTrigger("Throw");
 		animator.ResetTrigger("Point");
-		animator.SetTrigger(randomAction());
+		animator.SetTrigger(randomAnimation(actionList));
 		GetComponent<AudioSource>().clip = null;
 		clearCards();
 	}
@@ -345,10 +345,10 @@
 			bodyParts[i].transform.GetChild(0).gameObject.SetActive(false);
 		}
 	}
-	string randomAction ()
-	{
-		int val = Random.Range(0, actionList.Length);
-		return actionList[val];
+	string randomAnimation (string[] s)
+	{
+		int val = Random.Range(0, s.Length);
+		return s[val];
 	}
 	/// <summary>
 	/// Changes the body part.


removed dublicated code

removed dublicated code

--- Assets/Scripts/Cards/DoubleCard.cs
+++ Assets/Scripts/Cards/DoubleCard.cs
@@ -69,8 +69,6 @@
                         F.GetComponent<GameManager>().GetPointCardNumber(team);
                         F.GetComponent<GameManager>().GenerateFieldCard(CardID.Pointcard, indexX, indexY);
                         cardprocessdone = true;
-                        F.GetComponent<GameManager>().CollectRemoveCard(OwnGO, CardAction.CardDeleted);
-
                         AS.Complete += delegate {
                             MR.enabled = false;
                             F.GetComponent<GameManager>().animationDone = true;


Callbacks

Callbacks

--- Assets/Scripts/GameStageManager.cs
+++ Assets/Scripts/GameStageManager.cs
@@ -49,21 +49,25 @@
             }));
         }

-        public void LoadStaging()
+        public void LoadStaging(Action callback=null)
         {
             UnloadScenes();

             StartCoroutine(LoadSceneRoutine(_stagingSceneName, () => {
                 AirConsoleController.Instance.SetView(AirConsoleController.ViewStaging);
+
+                callback?.Invoke();
             }));
         }

-        public void LoadArena()
+        public void LoadArena(Action callback=null)
         {
             UnloadScenes();

             StartCoroutine(LoadSceneRoutine(_arenaSceneName, () => {
                 AirConsoleController.Instance.SetView(AirConsoleController.ViewArena);
+
+                callback?.Invoke();
             }));
         }


something changed there do know what

something changed there do know what

--- Assets/Scripts/Menu/OptionsMenu.cs
+++ Assets/Scripts/Menu/OptionsMenu.cs
@@ -83,10 +83,8 @@
             Resolution r = resolutionSelector.getCurrentResolution();
             Screen.SetResolution(r.width, r.height, FullScreen.isOn);
         }
-        QualitySettings.vSyncCount = data.Vsync ? 1 : 0;

-
-
+        QualitySettings.vSyncCount = data.Vsync ? 1 : 0;

         if (data == null)
         {


Boost now works without direction being held

--- Assets/Scripts/PlayerController.cs
+++ Assets/Scripts/PlayerController.cs
@@ -60,14 +60,25 @@
 			float yAxis = moveJoystick.position.y;//Input.GetAxis ("Vertical");

 			if (inWater){
-				float jetSpeed = speed;
+				// Move in direction
+				float moveX = xAxis * speed * Time.deltaTime;
+				float moveY = yAxis * speed * Time.deltaTime;
+
+				rigidbody2D.AddForce (new Vector3 (moveX, moveY, 0.0f));
+
+				// Boost
+//				float jetSpeed = speed;
 				if (boostButton.isPressed && gameController.GetBoost() > 0){
-					jetSpeed = speed * jetMultiplier;
+//					jetSpeed = speed * jetMultiplier;
 					isBoosting = true;
 					gameController.RemoveFromBoost(1);
 					timeSinceBoost = 0;

 					boostParticles.Play();
+
+					// Add boost vector
+					Vector3 boostVector = transform.up * (jetMultiplier * speed) * Time.deltaTime;
+					rigidbody2D.AddForce(boostVector);
 				}
 				else {
 					isBoosting = false;
@@ -81,11 +92,7 @@
 						timeSinceBoost += 1;
 					}
 				}
-				float moveX = xAxis * jetSpeed * Time.deltaTime;
-				float moveY = yAxis * jetSpeed * Time.deltaTime;
-
-				rigidbody2D.AddForce (new Vector3 (moveX, moveY, 0.0f));
-
+//
 				SetGravityForAll(0.01f);
 			}


Cleaned up comments

Cleaned up comments

--- Assets/Scripts/PlayerController.cs
+++ Assets/Scripts/PlayerController.cs
@@ -5,20 +5,21 @@
 public class PlayerController : MonoBehaviour {

     // Define Private Variables
+
+    // Level Settings
     private Rigidbody rb;
     private int count;
     private string levelNumber;
     private bool isPaused = false;

     // Define Public Variables
+
+    // Level GUI/Settings
     public float speed;
     public Text countText;
-    //public Text winText;
-    //public GameObject menuButton;
     public Text levelText;
     public GameObject levelInfo;
-    //public GameObject nextLevelButton;
-    // New Variables
+    // Level Pause/End
     public GameObject levelCompleted;
     public GameObject levelPaused;

@@ -27,9 +28,6 @@
         rb = GetComponent<Rigidbody>();
         count = 0;
         LevelCompleted();
-        //winText.text = "";
-        //menuButton.SetActive(false);
-        //nextLevelButton.SetActive(false);
         levelCompleted.SetActive(false);
         levelPaused.SetActive(false);
         LevelInfo();
@@ -88,9 +86,6 @@
         {
             if (count == 4)
             {
-                //winText.text = "You Win!";
-                //menuButton.SetActive(true);
-                //nextLevelButton.SetActive(true);
                 levelCompleted.SetActive(true);

                 // Save string when level is completed
@@ -106,9 +101,6 @@
         {
             if (count == 4)
             {
-                //winText.text = "You Win!";
-                //menuButton.SetActive(true);
-                //nextLevelButton.SetActive(true);
                 levelCompleted.SetActive(true);

                 // Save string when level is completed
@@ -124,9 +116,6 @@
         {
             if (count == 8)
             {
-                //winText.text = "You Win!";
-                //menuButton.SetActive(true);
-                //nextLevelButton.SetActive(true);
                 levelCompleted.SetActive(true);

                 // Save string when level is completed


added ref position on collide check

added ref position on collide check

--- Assets/Scripts/QQLevelGenerator.cs
+++ Assets/Scripts/QQLevelGenerator.cs
@@ -10,9 +10,6 @@
 	private int mapWidth, mapHeight;
 	private List<QQTile> tileInstances;
     private int deleteCounter = 0;
-
-    private Vector2 lastHit;
-    private TileType lastHitType;

 	public int MapHeight
 	{
@@ -35,20 +32,20 @@
 		//StartCoroutine(ColumnGeneratorRoutine(mapWidth));
 	}

-	public TileType CollideAtPosition(Vector3 pos, bool inBlock = false)
+	public TileType CollideAtPosition(Vector3 pos, ref Vector2 previousPositionInGrid, TileType preiousTileType, bool inBlock = false)
 	{
-
+
         if (pos.x < 0 || pos.y < 0)
             return TileType.Empty;

         Vector2 positionInGrid = new Vector2((int)pos.x % mapWidth, (int)pos.y % mapHeight);

-        if (positionInGrid == lastHit)
-            return lastHitType;
-        lastHit = positionInGrid;
+        if (positionInGrid == previousPositionInGrid)
+            return preiousTileType;
+        previousPositionInGrid = positionInGrid;
+        RVDrawer.QDrawCross(pos, Color.white, 1f, Vector3.forward);

         TileType type = tilesArray[(int)positionInGrid.x, (int)positionInGrid.y];
-        lastHitType = type;

         Debug.Log("Is in Block: "+inBlock);


Refactored some overlay stuff.

Refactored some overlay stuff.

--- Assets/Scripts/States/StateGame.cs
+++ Assets/Scripts/States/StateGame.cs
@@ -5,10 +5,13 @@
 public class StateGame : ExaState {
 	public StateGame(): base(GAME) {
 		//Initialize
-		m_Score 		= 0;
-		m_Error			= 0;
-		m_Health		= HEALTH_MAX;
-		m_EnemyTimer	= 2.0f;
+		m_Score 				= 0;
+		m_Error					= 0;
+		m_Health				= HEALTH_MAX;
+		m_ScoreCounterTimers	= new List<float>();
+		m_HealthCounterTimers	= new List<float>();
+		m_HealthChanges			= new List<float>();
+		m_EnemyTimer			= 2.0f;

 		//Create background
 		FSprite Background = new FSprite("rect") {
@@ -38,24 +41,33 @@
 		m_ScoreCounter 		= new FLabel("font", "");
 		m_ErrorCounter 		= new FLabel("font", "");
 		m_HealthCounter 	= new FLabel("font", "");
-		m_CounterOverlay 	= new FSprite("rect") {
+		m_ScoreOverlay 		= new FSprite("rect") {
 			x = 0,
 			y = 0,
 			width = m_ScoreCounter.textRect.width,
 			height = m_ScoreCounter.textRect.height,
-			color = new Color(255.0f, 255.0f, 255.0f, 0.35f)
+			color = new Color(1.0f, 1.0f, 1.0f, 0.35f),
+			isVisible = false
 		};
-		m_CounterOverlay.isVisible = false;
+		m_HealthOverlay 	= new FSprite("rect") {
+			x = 0,
+			y = 0,
+			width = m_HealthCounter.textRect.width,
+			height = m_HealthCounter.textRect.height,
+			color = new Color(1.0f, 1.0f, 1.0f, 0.35f),
+			isVisible = false
+		};

 		//Prepare
 		m_Error--;
 		AddChild(m_ScoreCounter);
+		AddChild(m_ScoreOverlay);
 		AddChild(m_ErrorCounter);
 		AddChild(m_HealthCounter);
-		AddChild(m_CounterOverlay);
+		AddChild(m_HealthOverlay);
 		incrementError();
 		increaseScore(0);
-		changeHealth(0);
+		changeHealth();
 	}

 	public override void onUpdate(FTouch[] touches) {
@@ -83,9 +95,25 @@
 		processCoinCounter(touches);
 	}

-	public void increaseScore(int amount) {
+	protected void addScoreChange(float duration) {
+		//Add
+		m_ScoreCounterTimers.Add(duration);
+		m_ScoreOverlay.isVisible = true;
+	}
+
+	protected void addHealthChange(float change, float duration) {
+		//Add
+		m_HealthChanges.Add(change);
+		m_HealthCounterTimers.Add(duration);
+
+		//Show
+		m_HealthOverlay.isVisible = true;
+	}
+
+	protected void increaseScore(int amount) {
 		//Add
 		m_Score += amount;
+		if (m_ScoreCounterTimers.Count > 0) m_ScoreCounterTimers.RemoveAt(0);

 		//Refresh
 		m_ScoreCounter.text = "Score: " + m_Score;
@@ -93,23 +121,34 @@
 		m_ScoreCounter.y 	= Futile.screen.height - 12 - (m_ScoreCounter.textRect.height * 0.5f);

 		//Refresh overlay
-		m_CounterOverlay.x 		= m_ScoreCounter.x;
-		m_CounterOverlay.y 		= m_ScoreCounter.y;
-		m_CounterOverlay.width	= m_ScoreCounter.textRect.width;
-		m_CounterOverlay.height	= m_ScoreCounter.textRect.height;
-	}
-
-	public void changeHealth(float change) {
-		//Change
-		m_Health += change;
+		m_ScoreOverlay.x 		= m_ScoreCounter.x;
+		m_ScoreOverlay.y 		= m_ScoreCounter.y;
+		m_ScoreOverlay.width	= m_ScoreCounter.textRect.width;
+		m_ScoreOverlay.height	= m_ScoreCounter.textRect.height;
+	}
+
+	protected void changeHealth() {
+		//If there's change
+		if (m_HealthCounterTimers.Count > 0) m_HealthCounterTimers.RemoveAt(0);
+		if (m_HealthChanges.Count > 0) {
+			//Change health
+			m_Health += m_HealthChanges[0];
+			m_HealthChanges.RemoveAt(0);
+		}

 		//Refresh
 		m_HealthCounter.text 	= "Health: " + (int)m_Health;
 		m_HealthCounter.x 		= 12 + (m_HealthCounter.textRect.width * 0.5f);
 		m_HealthCounter.y 		= Futile.screen.height - 12 - (m_HealthCounter.textRect.height * 0.5f);
-	}
-
-	public void incrementError() {
+
+		//Refresh overlay
+		m_HealthOverlay.x 		= m_HealthCounter.x;
+		m_HealthOverlay.y 		= m_HealthCounter.y;
+		m_HealthOverlay.width	= m_HealthCounter.textRect.width;
+		m_HealthOverlay.height	= m_HealthCounter.textRect.height;
+	}
+
+	protected void incrementError() {
 		//Increase
 		m_Error++;

@@ -189,36 +228,38 @@
 	}*/

 	protected void processCoinCounter(FTouch[] touches) {
-		//If there's counter
-		if (m_CoinCounterTime > 0) {
+		//While not all timer
+		int Index = 0;
+		while (Index < m_ScoreCounterTimers.Count) {
 			//Manage time
-			m_CoinCounterTime -= Time.deltaTime;
-			if (m_CoinCounterTime <= 0 && !m_CounterOverlay.isVisible) incrementError();
-		}
-		m_CounterOverlay.isVisible = m_CoinCounterTime > 0;
-
-		//For each touch
-		bool Touched = false;
-		for (int i = 0; i < touches.Length && !Touched; i++) {
-			//If done
-			if (touches[i].phase == TouchPhase.Ended) {
-				//Check position
-				float TouchX 		= touches[i].position.x;
-				float TouchY 		= touches[i].position.y;
-				float HalfWidth		= m_ScoreCounter.textRect.width * 0.5f;
-				float HalfHeight 	= m_ScoreCounter.textRect.height * 0.5f;
-				if (TouchX >= m_ScoreCounter.x - HalfWidth && TouchX <= m_ScoreCounter.x + HalfWidth && TouchY >= m_ScoreCounter.y - HalfHeight && TouchY <= m_ScoreCounter.y + HalfHeight) Touched = true;
-			}
-		}
-
-		//If touched
-		if (Touched) {
-			//Decrease health if not time
-			if (m_CoinCounterTime <= 0) incrementError();
-
-			//Pressed
-			increaseScore(500);
-			m_CoinCounterTime = 0;
+			m_ScoreCounterTimers[Index] -= Time.deltaTime;
+			if (m_ScoreCounterTimers[Index] > 0) Index++;
+			else {
+				//Remove
+				if (!m_ScoreOverlay.isVisible) incrementError();
+				m_ScoreCounterTimers.RemoveAt(Index);
+			}
+		}
+
+		//Check score overlay
+		m_ScoreOverlay.isVisible = m_ScoreCounterTimers.Count > 0;
+		if (m_ScoreOverlay.isVisible) {
+			//For each touch
+			bool Touched = false;
+			for (int i = 0; i < touches.Length && !Touched; i++) {
+				//If done
+				if (touches[i].phase == TouchPhase.Ended) {
+					//Check position
+					float TouchX 		= touches[i].position.x;
+					float TouchY 		= touches[i].position.y;
+					float HalfWidth		= m_ScoreCounter.textRect.width * 0.5f;
+					float HalfHeight 	= m_ScoreCounter.textRect.height * 0.5f;
+					if (TouchX >= m_ScoreCounter.x - HalfWidth && TouchX <= m_ScoreCounter.x + HalfWidth && TouchY >= m_ScoreCounter.y - HalfHeight && TouchY <= m_ScoreCounter.y + HalfHeight) Touched = true;
+				}
+			}
+
+			//If touched
+			if (Touched) increaseScore(500);
 		}
 	}

@@ -262,11 +303,13 @@
 	protected const float HEALTH_MAX = 100;

 	//Data
-	protected int 	m_Score;
-	protected int	m_Error;
-	protected float m_Health;
-	protected float m_CoinCounterTime;
-	protected float m_EnemyTimer;
+	protected int 			m_Score;
+	protected int			m_Error;
+	protected float 		m_Health;
+	protected float 		m_EnemyTimer;
+	protected List<float> 	m_HealthChanges;
+	protected List<float> 	m_ScoreCounterTimers;
+	protected List<float> 	m_HealthCounterTimers;

 	//Components
 	protected Exa			m_Exa;
@@ -276,5 +319,6 @@
 	protected FLabel 	m_ScoreCounter;
 	protected FLabel 	m_ErrorCounter;
 	protected FLabel 	m_HealthCounter;
-	protected FSprite	m_CounterOverlay;
+	protected FSprite	m_HealthOverlay;
+	protected FSprite	m_ScoreOverlay;
 }


添加精确排除列表，以便排除同名但不同参数的某个重载函数

添加精确排除列表，以便排除同名但不同参数的某个重载函数

--- Assets/ToLua/Editor/ToLuaExport.cs
+++ Assets/ToLua/Editor/ToLuaExport.cs
@@ -135,7 +135,6 @@
         "Light.areaSize",
         "Security.GetChainOfTrustValue",
         "Texture2D.alphaIsTransparency",
-        "WWW.movie",
         "WebCamTexture.MarkNonReadable",
         "WebCamTexture.isReadable",
         "Graphic.OnRebuildRequested",
@@ -156,15 +155,20 @@
         "Light.lightmappingMode"
     };

+	public static List<MemberInfo> memberInfoFilter = new List<MemberInfo>
+	{
+		typeof(WWW).GetProperty("movie"),
+	};
+
     public static bool IsMemberFilter(MemberInfo mi)
-    {
-        return memberFilter.Contains(type.Name + "." + mi.Name);
+    {
+		return memberInfoFilter.Contains(mi) || memberFilter.Contains(type.Name + "." + mi.Name);
     }

     public static bool IsMemberFilter(Type t)
     {
         string name = LuaMisc.GetTypeName(t);
-        return memberFilter.Find((p) => { return name.Contains(p); }) != null;
+        return memberInfoFilter.Contains(t) || memberFilter.Find((p) => { return name.Contains(p); }) != null;
     }

     static ToLuaExport()


Minor style quibble

Minor style quibble

--- Assets/Voxelgon/ShipEditor/Wall.cs
+++ Assets/Voxelgon/ShipEditor/Wall.cs
@@ -89,8 +89,7 @@

 		//Methods

-		public bool ValidVertex(Vector3 vertex)
-        {
+		public bool ValidVertex(Vector3 vertex) {
             if (ContainsVertex(vertex)) {
                 return false;
             }


Now selector compensates for disappearing lanes.

--- Assets/scripts/PlayerController.cs
+++ Assets/scripts/PlayerController.cs
@@ -81,6 +81,22 @@
 			KeyPress[(int)btn] = Input.GetKey(inputkeys[(int)btn]);
 		}

+		if (MySpawners [selectedSpawner] == null) {
+			int temp = selectedSpawner;
+			for (int i = 0; temp - i >= 0 || temp + i <= MySpawners.Count - 1; i++) {
+				if (temp + i <= MySpawners.Count -1 && MySpawners [temp + i] != null) {
+					selectedSpawner = temp + i;
+					MySpawners[selectedSpawner].GetComponent<Renderer> ().material.color = (playernr == 1? Color.blue :Color.red);
+					break;
+				}
+				if (temp - i >= 0 && MySpawners [temp - i] != null) {
+					selectedSpawner = temp - i;
+					MySpawners[selectedSpawner].GetComponent<Renderer> ().material.color = (playernr == 1? Color.blue :Color.red);
+					break;
+				}
+			}
+		}
+
 		if(KeyPress[(int)Buttons.Spawn1] && !DeltaPress[(int)Buttons.Spawn1]){
 			spawn (unitPrefab01);
 		}
@@ -92,14 +108,23 @@
 		}

 		if (KeyPress[(int)Buttons.Up] && !DeltaPress[(int)Buttons.Up]) {
-			if (selectedSpawner < MySpawners.Count-1 ) {
-				selectedSpawner++;
+			int tempSelecter = selectedSpawner;
+			do {
+				tempSelecter++;
+			} while (tempSelecter < MySpawners.Count - 1 && MySpawners [tempSelecter] == null);
+			if (tempSelecter <= MySpawners.Count -1 ) {
+				selectedSpawner = tempSelecter;
 				updateSpawnerColor();
 			}
 		}
 		else if(KeyPress[(int)Buttons.Down] && !DeltaPress[(int)Buttons.Down]){
-			if (selectedSpawner > 0 ) {
-				selectedSpawner--;
+			int tempSelecter = selectedSpawner;
+			do {
+				tempSelecter--;
+			} while ( tempSelecter > 0 && MySpawners [tempSelecter] == null);
+
+			if (tempSelecter >= 0 ) {
+				selectedSpawner = tempSelecter;
 				updateSpawnerColor();
 			}
 		}


Logger outputs downloaded html.

Logger outputs downloaded html.

--- AwfulNET.Core/Common/Extensions.cs
+++ AwfulNET.Core/Common/Extensions.cs
@@ -264,6 +264,10 @@
                 var bytes = await content.ReadAsByteArrayAsync();
                 html = western.GetString(bytes, 0, bytes.Length);
                 Logger.Default.AddEntry(LogLevel.INFO, "[GetHtml] Html character length: " + html.Length);
+                Logger.Default.AddEntry(LogLevel.INFO, "[GetHtml] Html start:");
+                Logger.Default.AddEntry(LogLevel.INFO, "[GetHtml] -----------");
+                Logger.Default.AddEntry(LogLevel.INFO, html);
+                Logger.Default.AddEntry(LogLevel.INFO, "[GetHtml] -----------");
                 Logger.Default.AddEntry(LogLevel.INFO, "[GetHtml] Completed.");
             }
             catch (Exception ex)


add full memory configuration

add full memory configuration

--- BitSharp.Client/MainWindow.xaml.cs
+++ BitSharp.Client/MainWindow.xaml.cs
@@ -1,4 +1,5 @@
 //#define TEST_TOOL
+//#define MEMORY
 //#define MONGODB

 using BitSharp.Common.ExtensionMethods;
@@ -47,7 +48,7 @@
             {
                 //TODO
                 //MainnetRules.BypassValidation = true;
-                MainnetRules.BypassExecuteScript = true;
+                MainnetRules.IgnoreScriptErrors = true;
                 ScriptEngine.BypassVerifySignature = true;

                 Debug.WriteLine(DateTime.Now);
@@ -56,6 +57,9 @@
                 //if (Directory.Exists(Path.Combine(Config.LocalStoragePath, "data-test")))
                 //    Directory.Delete(Path.Combine(Config.LocalStoragePath, "data-test"), recursive: true);
                 //var storageContext = new EsentStorageContext(Path.Combine(Config.LocalStoragePath, "data-test"));
+                var storageContext = new MemoryStorageContext();
+                var knownAddressStorage = storageContext.KnownAddressStorage;
+#elif MEMORY
                 var storageContext = new MemoryStorageContext();
                 var knownAddressStorage = storageContext.KnownAddressStorage;
 #elif MONGODB


Fix missed `GameName` rename

Fix missed `GameName` rename

--- osu.Framework.Tests/Exceptions/TestLoadExceptions.cs
+++ osu.Framework.Tests/Exceptions/TestLoadExceptions.cs
@@ -199,7 +199,11 @@

             try
             {
-                using (var host = new TestRunHeadlessGameHost($"{GetType().Name}-{Guid.NewGuid()}", realtime: false))
+                using (var host = new TestRunHeadlessGameHost(new HostConfig
+                {
+                    Name = $"{GetType().Name}-{Guid.NewGuid()}",
+                    Realtime = false,
+                }))
                 {
                     using (var game = new TestGame())
                     {


Fix catastrophic failure

Fix catastrophic failure

--- osu.Framework/Graphics/Containers/ScrollContainer.cs
+++ osu.Framework/Graphics/Containers/ScrollContainer.cs
@@ -216,7 +216,8 @@

         private void updateScrollbar()
         {
-            Scrollbar.ResizeTo(MathHelper.Clamp(availableContent > 0 ? displayableContent / availableContent : 0, Scrollbar.DimSize / DrawHeight, 1), 200, Easing.OutQuint);
+            if (DrawHeight > 0)
+                Scrollbar.ResizeTo(MathHelper.Clamp(availableContent > 0 ? displayableContent / availableContent : 0, Scrollbar.DimSize / DrawHeight, 1), 200, Easing.OutQuint);
             Scrollbar.FadeTo(ScrollbarVisible && availableContent - 1 > displayableContent ? 1 : 0, 200);
             updatePadding();
         }


Type to DrawableOsuHitObject

Type to DrawableOsuHitObject

--- osu.Game.Rulesets.Osu.Tests/TestSceneFollowPoints.cs
+++ osu.Game.Rulesets.Osu.Tests/TestSceneFollowPoints.cs
@@ -10,7 +10,6 @@
 using osu.Framework.Graphics.Containers;
 using osu.Game.Beatmaps;
 using osu.Game.Beatmaps.ControlPoints;
-using osu.Game.Rulesets.Objects.Drawables;
 using osu.Game.Rulesets.Objects.Types;
 using osu.Game.Rulesets.Osu.Objects;
 using osu.Game.Rulesets.Osu.Objects.Drawables;
@@ -22,7 +21,7 @@
 {
     public class TestSceneFollowPoints : OsuTestScene
     {
-        private Container<DrawableHitObject> hitObjectContainer;
+        private Container<DrawableOsuHitObject> hitObjectContainer;
         private FollowPointRenderer followPointRenderer;

         [SetUp]
@@ -30,7 +29,7 @@
         {
             Children = new Drawable[]
             {
-                hitObjectContainer = new Container<DrawableHitObject> { RelativeSizeAxes = Axes.Both },
+                hitObjectContainer = new Container<DrawableOsuHitObject> { RelativeSizeAxes = Axes.Both },
                 followPointRenderer = new FollowPointRenderer { RelativeSizeAxes = Axes.Both }
             };
         });
@@ -44,7 +43,7 @@
         [Test]
         public void TestRemoveSingleHitObject()
         {
-            DrawableHitObject obj = null;
+            DrawableOsuHitObject obj = null;

             addObjects(() => new[] { new HitCircle { Position = new Vector2(100, 100) } }, o => obj = o);
             removeObject(() => obj);
@@ -66,7 +65,7 @@
         [Test]
         public void TestRemoveEndObject()
         {
-            var objects = new List<DrawableHitObject>();
+            var objects = new List<DrawableOsuHitObject>();

             AddStep("reset", () => objects.Clear());

@@ -85,7 +84,7 @@
         [Test]
         public void TestRemoveStartObject()
         {
-            var objects = new List<DrawableHitObject>();
+            var objects = new List<DrawableOsuHitObject>();

             AddStep("reset", () => objects.Clear());

@@ -104,7 +103,7 @@
         [Test]
         public void TestRemoveMiddleObject()
         {
-            var objects = new List<DrawableHitObject>();
+            var objects = new List<DrawableOsuHitObject>();

             AddStep("reset", () => objects.Clear());

@@ -123,7 +122,7 @@
         [Test]
         public void TestMoveHitObject()
         {
-            var objects = new List<DrawableHitObject>();
+            var objects = new List<DrawableOsuHitObject>();

             AddStep("reset", () => objects.Clear());

@@ -136,10 +135,10 @@
                 new HitCircle { Position = new Vector2(500, 500) },
             }, o => objects.Add(o));

-            AddStep("move hitobject", () => ((OsuHitObject)objects[2].HitObject).Position = new Vector2(300, 100));
-        }
-
-        private void addObjects(Func<HitCircle[]> ctorFunc, Action<DrawableHitObject> storeFunc = null)
+            AddStep("move hitobject", () => objects[2].HitObject.Position = new Vector2(300, 100));
+        }
+
+        private void addObjects(Func<HitCircle[]> ctorFunc, Action<DrawableOsuHitObject> storeFunc = null)
         {
             AddStep("add hitobjects", () =>
             {
@@ -159,7 +158,7 @@
             });
         }

-        private void removeObject(Func<DrawableHitObject> getFunc)
+        private void removeObject(Func<DrawableOsuHitObject> getFunc)
         {
             AddStep("remove hitobject", () =>
             {
@@ -173,11 +172,11 @@
         private class FollowPointRenderer : CompositeDrawable
         {
             /// <summary>
-            /// Adds the <see cref="FollowPoint"/>s around a <see cref="DrawableHitObject"/>.
+            /// Adds the <see cref="FollowPoint"/>s around a <see cref="DrawableOsuHitObject"/>.
             /// This includes <see cref="FollowPoint"/>s leading into <paramref name="hitObject"/>, and <see cref="FollowPoint"/>s exiting <paramref name="hitObject"/>.
             /// </summary>
-            /// <param name="hitObject">The <see cref="DrawableHitObject"/> to add <see cref="FollowPoint"/>s for.</param>
-            public void AddFollowPoints(DrawableHitObject hitObject)
+            /// <param name="hitObject">The <see cref="DrawableOsuHitObject"/> to add <see cref="FollowPoint"/>s for.</param>
+            public void AddFollowPoints(DrawableOsuHitObject hitObject)
             {
                 var startGroup = new FollowPointGroup(hitObject);
                 AddInternal(startGroup);
@@ -205,11 +204,11 @@
             }

             /// <summary>
-            /// Removes the <see cref="FollowPoint"/>s around a <see cref="DrawableHitObject"/>.
+            /// Removes the <see cref="FollowPoint"/>s around a <see cref="DrawableOsuHitObject"/>.
             /// This includes <see cref="FollowPoint"/>s leading into <paramref name="hitObject"/>, and <see cref="FollowPoint"/>s exiting <paramref name="hitObject"/>.
             /// </summary>
-            /// <param name="hitObject">The <see cref="DrawableHitObject"/> to remove <see cref="FollowPoint"/>s for.</param>
-            public void RemoveFollowPoints(DrawableHitObject hitObject)
+            /// <param name="hitObject">The <see cref="DrawableOsuHitObject"/> to remove <see cref="FollowPoint"/>s for.</param>
+            public void RemoveFollowPoints(DrawableOsuHitObject hitObject)
             {
                 var groups = findGroups(hitObject);

@@ -224,12 +223,12 @@
             }

             /// <summary>
-            /// Finds the <see cref="FollowPointGroup"/>s with <paramref name="hitObject"/> as the start and end <see cref="DrawableHitObject"/>s.
-            /// </summary>
-            /// <param name="hitObject">The <see cref="DrawableHitObject"/> to find the relevant <see cref="FollowPointGroup"/> of.</param>
+            /// Finds the <see cref="FollowPointGroup"/>s with <paramref name="hitObject"/> as the start and end <see cref="DrawableOsuHitObject"/>s.
+            /// </summary>
+            /// <param name="hitObject">The <see cref="DrawableOsuHitObject"/> to find the relevant <see cref="FollowPointGroup"/> of.</param>
             /// <returns>A tuple containing the end group (the <see cref="FollowPointGroup"/> where <paramref name="hitObject"/> is the end of),
             /// and the start group (the <see cref="FollowPointGroup"/> where <paramref name="hitObject"/> is the start of).</returns>
-            private (FollowPointGroup start, FollowPointGroup end) findGroups(DrawableHitObject hitObject)
+            private (FollowPointGroup start, FollowPointGroup end) findGroups(DrawableOsuHitObject hitObject)
             {
                 //           endGroup         startGroup
                 //     h1 -> -> -> -> -> h2 -> -> -> -> -> h3
@@ -273,24 +272,24 @@
             private const double preempt = 800;

             /// <summary>
-            /// The <see cref="DrawableHitObject"/> which <see cref="FollowPoint"/>s will exit from.
+            /// The <see cref="DrawableOsuHitObject"/> which <see cref="FollowPoint"/>s will exit from.
             /// </summary>
             [NotNull]
-            public readonly DrawableHitObject Start;
-
-            public FollowPointGroup(DrawableHitObject start)
+            public readonly DrawableOsuHitObject Start;
+
+            public FollowPointGroup(DrawableOsuHitObject start)
             {
                 Start = start;
                 RelativeSizeAxes = Axes.Both;
             }

-            private DrawableHitObject end;
-
-            /// <summary>
-            /// The <see cref="DrawableHitObject"/> which <see cref="FollowPoint"/>s will enter.
+            private DrawableOsuHitObject end;
+
+            /// <summary>
+            /// The <see cref="DrawableOsuHitObject"/> which <see cref="FollowPoint"/>s will enter.
             /// </summary>
             [CanBeNull]
-            public DrawableHitObject End
+            public DrawableOsuHitObject End
             {
                 get => end;
                 set
@@ -307,8 +306,8 @@
                 if (End == null)
                     return;

-                OsuHitObject osuStart = (OsuHitObject)Start.HitObject;
-                OsuHitObject osuEnd = (OsuHitObject)End.HitObject;
+                OsuHitObject osuStart = Start.HitObject;
+                OsuHitObject osuEnd = End.HitObject;

                 if (osuEnd.NewCombo)
                     return;


Correct the sizes of TestCaseLogoFacadeContainer

--- osu.Game.Tests/Visual/TestCaseLogoFacadeContainer.cs
+++ osu.Game.Tests/Visual/TestCaseLogoFacadeContainer.cs
@@ -122,7 +122,7 @@
                     {
                         Alpha = 0.35f,
                         RelativeSizeAxes = Axes.None,
-                        Size = new Vector2(107),
+                        Size = new Vector2(72),
                         Child = visualBox = new Box
                         {
                             Colour = Color4.Tomato,
@@ -133,7 +133,7 @@
                     {
                         Alpha = 0.35f,
                         RelativeSizeAxes = Axes.None,
-                        Size = new Vector2(107),
+                        Size = new Vector2(72),
                         Child = transferContainerBox = new Box
                         {
                             Colour = Color4.White,
@@ -172,7 +172,7 @@
                 this.logo = logo;
                 logo.FadeIn(350);
                 logo.ScaleTo(new Vector2(0.15f), 350, Easing.In);
-                logoFacadeContainer.SetLogo(logo, 0.3f, 1000, Easing.InOutQuint);
+                logoFacadeContainer.SetLogo(logo, 1.0f, 1000, Easing.InOutQuint);
                 logoFacadeContainer.Tracking = true;
                 moveLogoFacade();
             }


Fix beatmap overlay leaderboards and links not working

Completely aware that this isn't how it should be done, but would like
to get this out in a hotfix release today. Maybe changes opinions on
https://github.com/ppy/osu/pull/16890 structure?

--- osu.Game/Online/API/Requests/Responses/APIBeatmap.cs
+++ osu.Game/Online/API/Requests/Responses/APIBeatmap.cs
@@ -112,7 +112,27 @@
             public int OnlineID { get; set; } = -1;

             public string Name => $@"{nameof(APIRuleset)} (ID: {OnlineID})";
-            public string ShortName => nameof(APIRuleset);
+
+            public string ShortName
+            {
+                get
+                {
+                    // TODO: this should really not exist.
+                    switch (OnlineID)
+                    {
+                        case 0: return "osu";
+
+                        case 1: return "taiko";
+
+                        case 2: return "catch";
+
+                        case 3: return "fruits";
+
+                        default: throw new ArgumentOutOfRangeException();
+                    }
+                }
+            }
+
             public string InstantiationInfo => string.Empty;

             public Ruleset CreateInstance() => throw new NotImplementedException();


Fix not setting Origin + Anchors properly when reversing.

--- osu.Game/Rulesets/Timing/SpeedAdjustmentContainer.cs
+++ osu.Game/Rulesets/Timing/SpeedAdjustmentContainer.cs
@@ -85,11 +85,13 @@
             {
                 RelativeChildSize = new Vector2((ScrollingAxes & Axes.X) > 0 ? (float)-VisibleTimeRange : 1, (ScrollingAxes & Axes.Y) > 0 ? (float)-VisibleTimeRange : 1);
                 RelativeChildOffset = new Vector2((ScrollingAxes & Axes.X) > 0 ? (float)VisibleTimeRange : 0, (ScrollingAxes & Axes.Y) > 0 ? (float)VisibleTimeRange : 0);
+                Origin = Anchor = Anchor.BottomLeft;
             }
             else
             {
                 RelativeChildSize = new Vector2((ScrollingAxes & Axes.X) > 0 ? (float)VisibleTimeRange : 1, (ScrollingAxes & Axes.Y) > 0 ? (float)VisibleTimeRange : 1);
                 RelativeChildOffset = Vector2.Zero;
+                Anchor = Anchor = Anchor.TopLeft;
             }
         }


Also store total size to reset usage usage data.


AML-3843 Update 'Ways to add your PAYE scheme' to CDN

--- src/SFA.DAS.EmployerAccounts.Web/Views/EmployerAccountPaye/WaysToAdd.cshtml
+++ src/SFA.DAS.EmployerAccounts.Web/Views/EmployerAccountPaye/WaysToAdd.cshtml
@@ -5,71 +5,74 @@
 @{ViewBag.HideNav = true; }
 @{
     ViewBag.GaData.Vpv = "/accounts/schemes/ways-to-add";
-    var hiddenClass = ViewBag.InError != null && ViewBag.InError ? "" : "hidden";
-    var errorClass = ViewBag.InError != null && ViewBag.InError ? "error" : "";
+    var hiddenClass = ViewBag.InError != null && ViewBag.InError ? "" : "govuk-visually-hidden";
+    var errorClass = ViewBag.InError != null && ViewBag.InError ? "govuk-form-group--error" : "";
     var aornAction = ViewBag.AornLock > 0 ? "$('#AornWarning').removeClass('hidden')" : "";
 }
-

-

-

-            Ways to add your PAYE scheme
-

-
If you know the annual payroll for your organisation is under £3 million, you can use either:

-

-

+@{Layout = "~/Views/Shared/_Layout_CDN.cshtml"; }
+
+

+

+
Ways to add your PAYE scheme

+
If you know the annual payroll for your organisation is under £3 million, you can use either:

+

Government Gateway login for your PAYE scheme

accounts office reference number and employer PAYE scheme reference

-
If you know the annual payroll for your organisation is over £3 million, you can use:

-

-

+
+
If you know the annual payroll for your organisation is over £3 million, you can use:

+

Government Gateway login for your PAYE scheme

-
If you've not sure how much your annual payroll is, choose Government Gateway.

+
If you’re not sure how much your annual payroll is, choose
Government Gateway.

+
         <form method="POST" action="@Url.Action(ControllerConstants.WaysToAddPayeSchemeActionName)">
             @Html.AntiForgeryToken()
-

-                <fieldset>
-                    <legend class="form-label-bold">
-
-                            You must select an option to continue.
+

+
+                <fieldset class="govuk-fieldset" aria-describedby="how-contacted-conditional-hint">
+
+                        You must select an option to continue.
+
+                    @** TODO
+
+                            Due to incorrect attempts, this has been disabled for @ViewBag.AornLock minute@(ViewBag.AornLock > 1 ? "s" : "")

-                    </legend>
-
-                        <input type="radio" name="choice" id="want-to-use-gov-gateway" value="1" />
-                        I want to use Government Gateway
-
-
-                        <input type="radio" name="choice" id="want-to-use-aorn" value="2" onclick="@aornAction" />
-                        I want to use my accounts office reference number and employer PAYE scheme reference
-
+                    **@
+

+

+                            <input class="govuk-radios__input" type="radio" name="choice" id="ways-to-add-your-paye" value="1" />
+
+                                I want to use Government Gateway
+
+

+
+

+                            <input class="govuk-radios__input" type="radio" name="choice" id="want-to-use-aorn" value="2" onclick="@aornAction" />
+
+                                I want to use my accounts office reference number and employer PAYE scheme reference
+
+

+
+

                 </fieldset>
-

-
-                        Due to incorrect attempts, this has been disabled for @ViewBag.AornLock minute@(ViewBag.AornLock > 1 ? "s" : "")
-
-

-

-

-
-                            Warning
-
-
-                            Before you continue, you must make sure you have authority to add PAYE schemes to the account for this organisation.
-
-

-

+

-

-                <button class="button" type="submit" id="submit-how-to-add-payescheme">Continue</button>
+
+

+                !
+
+                    Warning
+                    Before you continue, you must make sure you have authority to add PAYE schemes to the account for this organisation
+

+
+

+                <button class="govuk-button" type="submit" id="submit-how-to-add-payescheme">Continue</button>
+

+
+
+
         </form>

-@section pageSpecificJS {
-
-}


Update PetEnPlugin.cs

Update PetEnPlugin.cs

文面変更。

--- PetEnPlugin.cs
+++ PetEnPlugin.cs
@@ -4,7 +4,7 @@
 using System.Text;
 using System.Windows.Forms;
 // Advanced Combat Tracker - mini parse window用Plugin
-// NameEn:キャラクター名のペットも含めて英語で出力
+// NameEn: 日本語クライアント利用時に、キャラクター名(ペット含む)を英語で出力
 [assembly: AssemblyTitle("Mini Parse Pets' Name in English")]
 [assembly: AssemblyVersion("1.0.0.0")]


Include namespace in type displays.

Include namespace in type displays.

--- PrettyPrint.cs
+++ PrettyPrint.cs
@@ -121,7 +121,7 @@
         EscapeChar(output, (char)result);
       } else if(result is Type || result.GetType().Name == "MonoType") {
         if(_depth > 0 || !expandTypes)
-          output.Append("typeof(" + ((Type)result).Name + ")");
+          output.Append("typeof(" + ((Type)result).Namespace + "." + ((Type)result).Name + ")");
         else
           output.Append(InteractiveBase.Describe(result));
       } else {


Update File Adding comments, changing input params.

--- Box.V2/Managers/BoxFilesManager.cs
+++ Box.V2/Managers/BoxFilesManager.cs
@@ -185,21 +185,20 @@
         /// overwrites the file if it knows about the latest version. The filename on Box will remain the same as the previous version.
         /// A proper timeout should be provided for large uploads
         /// </summary>
-        /// <param name="fileName"></param>
-        /// <param name="fileId"
-        /// <param name="stream"></param>
-        /// <param name="etag"></param>
-        /// <param name="fields"></param>
-        /// <param name="timeout"></param>
-        /// <param name="contentMD5"></param>
-        /// <param name="setStreamPositionToZero"></param>
-        /// <param name="uploadUri"></param>
-        /// <returns></returns>
-        public async Task<BoxFile> UploadNewVersionAsync(string fileName, string fileId, Stream stream,
-                                                         string etag = null, List<string> fields = null,
-                                                         TimeSpan? timeout = null, byte[] contentMD5 = null,
-                                                         bool setStreamPositionToZero = true,
-                                                         Uri uploadUri = null)
+        /// <param name="fileName">Name of the file</param>
+        /// <param name="fileId">Id of the updated file</param>
+        /// <param name="stream">Stream of uploading file</param>
+        /// <param name="etag">Etag field of the file object</param>
+        /// <param name="fields">Fields which shall be returned in result</param>
+        /// <param name="timeout">Optional timeout for response</param>
+        /// <param name="contentMD5">The SHA1 hash of the file</param>
+        /// <param name="setStreamPositionToZero">Set position for input stream to 0</param>
+        /// <returns>A full file object is returned</returns>
+        public async Task<BoxFile> UploadNewVersionAsync(string fileName, string fileId, Stream stream,
+                                                         string etag = null, List<string> fields = null,
+                                                         TimeSpan? timeout = null, byte[] contentMD5 = null,
+                                                         bool setStreamPositionToZero = true
+                                                         )
         {
             stream.ThrowIfNull("stream");
             fileName.ThrowIfNullOrWhiteSpace("fileName");
@@ -207,7 +206,7 @@
             if (setStreamPositionToZero)
                 stream.Position = 0;

-            uploadUri = uploadUri == null ? new Uri(string.Format(Constants.FilesNewVersionEndpointString, fileId)) : uploadUri;
+            Uri uploadUri = new Uri(string.Format(Constants.FilesNewVersionEndpointString, fileId));

             BoxMultiPartRequest request = new BoxMultiPartRequest(uploadUri) { Timeout = timeout }
                 .Header("If-Match", etag)


Rename test.

Rename test.

--- Braintree.Tests/TransactionTest.cs
+++ Braintree.Tests/TransactionTest.cs
@@ -2530,7 +2530,7 @@
         }

         [Test]
-        public void Clone_WithAllAttributes()
+        public void Clone()
         {
             TransactionRequest request = new TransactionRequest
             {


Reworked the AppDomain to have the workaround for the safe-handle issue, and only apply it when running Mono

--- Ceen.Httpd.Cli/AppDomainHandler.cs
+++ Ceen.Httpd.Cli/AppDomainHandler.cs
@@ -5,6 +5,7 @@
 using System.Net.Sockets;
 using System.Linq;
 using System.Net;
+using System.Reflection;

 namespace Ceen.Httpd.Cli
 {
@@ -86,6 +87,8 @@
 			}
 		}

+
+
 		/// <summary>
 		/// Wrapper helper to invoke methods across the AppDomain boundary
 		/// </summary>
@@ -225,6 +228,11 @@
 			public bool UseSSL { get; private set; }

 			/// <summary>
+			/// The method used to handle requests
+			/// </summary>
+			private Action<TcpClient, EndPoint, string> m_handler;
+
+			/// <summary>
 			/// Initializes a new instance of the <see cref="T:Ceen.Httpd.Cli.AppDomainHandler.RunnerInstance"/> class.
 			/// </summary>
 			/// <param name="wrapper">The wrapper used to process requests.</param>
@@ -234,6 +242,54 @@
 			/// <param name="config">The server configuration.</param>
 			public RunnerInstance(IRemotingWrapper wrapper, string address, int port, bool usessl, ServerConfig config)
 			{
+				FieldInfo safe_handle_field = null;
+
+				var monoRuntime = Type.GetType("Mono.Runtime");
+				var monoVersion = new Version(0, 0);
+				if (monoRuntime != null)
+				{
+					var displayName = monoRuntime.GetMethod("GetDisplayName", BindingFlags.NonPublic | BindingFlags.Static);
+					if (displayName != null)
+					{
+						var displayString = (displayName.Invoke(null, null) as string) ?? string.Empty;
+						var versionstring = displayString.Split(' ').FirstOrDefault();
+						Version.TryParse(versionstring, out monoVersion);
+					}
+				}
+
+				// This bug is fixed in mono, but we need to wait to get the version number
+				if (monoRuntime != null && monoVersion <= new Version(4, 6, 2))
+				{
+					safe_handle_field = typeof(Socket).GetField("safe_handle", BindingFlags.NonPublic | BindingFlags.Instance);
+					if (safe_handle_field == null)
+						safe_handle_field = typeof(Socket).GetField("m_Handle", BindingFlags.NonPublic | BindingFlags.Instance);
+				}
+
+				var pid = System.Diagnostics.Process.GetCurrentProcess().Id;
+
+				if (safe_handle_field == null)
+				{
+					m_handler = (socket, addr, id) =>
+					{
+						Wrapper.HandleRequest(socket.Client.DuplicateAndClose(pid), addr, id);
+					};
+				}
+				else
+				{
+					m_handler = (socket, addr, id) =>
+					{
+						// Bugfix workaround for: https://bugzilla.xamarin.com/show_bug.cgi?id=47425
+						var prev_sh = safe_handle_field.GetValue(socket.Client);
+
+						var s = socket.Client.DuplicateAndClose(pid);
+
+						if (prev_sh != null)
+							GC.SuppressFinalize(prev_sh);
+
+						Wrapper.HandleRequest(s, addr, id);
+					};
+				}
+
 				RestartAsync(wrapper, address, port, usessl, config);
 			}

@@ -268,29 +324,12 @@
 				Address = address;
 				ShouldStop = false;

-				var pid = System.Diagnostics.Process.GetCurrentProcess().Id;
-
-				var safe_handle_field = typeof(Socket).GetField("safe_handle", System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Instance);
-				if (safe_handle_field == null)
-					safe_handle_field = typeof(Socket).GetField("m_Handle", System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Instance);
-
 				RunnerTask = HttpServer.ListenToSocketAsync(
 					new IPEndPoint(ConfigParser.ParseIPAddress(address), port),
 					usessl,
 					m_token.Token,
 					config,
-					(socket, addr, id) =>
-					{
-						// Bugfix workaround for: https://bugzilla.xamarin.com/show_bug.cgi?id=47425
-						var prev_sh = safe_handle_field == null ? null : safe_handle_field.GetValue(socket.Client);
-
-						var s = socket.Client.DuplicateAndClose(pid);
-
-						if (prev_sh != null)
-							GC.SuppressFinalize(prev_sh);
-
-						Wrapper.HandleRequest(s, addr, id);
-					}
+					m_handler
 				);
 			}
 		}
@@ -410,7 +449,6 @@
 			// Ensure it parses
 			ConfigParser.ParseIPAddress(address);

-
 			var prev = m_handlers.Where(x => x.UseSSL == usessl).FirstOrDefault();
 			if (enabled)
 			{


OnAddressChanged now loads "newValue", allows for more consistent overriding.

--- CefSharp.Wpf/ChromiumWebBrowser.cs
+++ CefSharp.Wpf/ChromiumWebBrowser.cs
@@ -165,7 +165,7 @@
                 Dispatcher
             );

-            managedCefBrowserAdapter.LoadUrl(Address);
+            managedCefBrowserAdapter.LoadUrl(newValue);
         }

         #endregion Address dependency property


matrix is a struct so it cant be null

matrix is a struct so it cant be null

--- CefSharp.Wpf/ChromiumWebBrowser.cs
+++ CefSharp.Wpf/ChromiumWebBrowser.cs
@@ -558,13 +558,10 @@

         private void CheckIsNonStandardDpi()
         {
-            if (matrix != null) // make sure it's connected
-            {
-                dpiTransform = new ScaleTransform(
-                    1 / matrix.M11,
-                    1 / matrix.M22
-                );
-            }
+            dpiTransform = new ScaleTransform(
+                   1 / matrix.M11,
+                   1 / matrix.M22
+               );
         }

         private void AddSourceHookIfNotAlreadyPresent()


If overrides are specified, construct a shader from them and apply that.

--- ChamberLib.OpenTK/ShaderProgram.cs
+++ ChamberLib.OpenTK/ShaderProgram.cs
@@ -82,7 +82,22 @@
                 MakeReady();
             }

-            ApplyBase();
+            if ((vertexShaderOverride != null && vertexShaderOverride != VertexShader) ||
+                (fragmentShaderOverride != null && fragmentShaderOverride != FragmentShader))
+            {
+                vertexShaderOverride = vertexShaderOverride ?? VertexShader;
+                fragmentShaderOverride = fragmentShaderOverride ?? FragmentShader;
+
+                var effectiveProgram = MakeShaderProgram(
+                    (ShaderStage)vertexShaderOverride,
+                    (ShaderStage)fragmentShaderOverride);
+
+                effectiveProgram.ApplyBase();
+            }
+            else
+            {
+                ApplyBase();
+            }
         }

         protected void ApplyBase()