Пример #1
0
        private static void CommandArgsAutoCompletion(On.RoR2.Console.AutoComplete.orig_ctor orig, RoR2.Console.AutoComplete self, RoR2.Console console)
        {
            orig(self, console);

            var searchableStrings = self.GetFieldValue <List <string> >("searchableStrings");
            var tmp = new List <string>();

            tmp.AddRange(ArgsAutoCompletion.CommandsWithStaticArgs);
            tmp.AddRange(ArgsAutoCompletion.CommandsWithDynamicArgs());

            tmp.Sort();
            searchableStrings.AddRange(tmp);

            self.SetFieldValue("searchableStrings", searchableStrings);
        }
Пример #2
0
        private void Start()
        {
            var _ = StringFinder.Instance;

            ArgsAutoCompletion.GatherCommandsAndFillStaticArgs();
        }