Jump to content

WHITELIONX

Member
  • Content Count

    4
  • Joined

  • Last visited

  • Medals

Community Reputation

10 Good

About WHITELIONX

  • Rank
    Rookie

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. You're actually better off with getting the actual source, you can edit it to your liking then.
  2. Well it's easy enough to add things if you want to include saying "squad" first, such as "squad map" selects squad then opens the map BUT if like me you want to say something like "squad map, go to" because the "go to" part which I added does not work like that so it's a case of saying "squad map" "squad" "squad move to". Basically it means saying "squad" more times than you should need to. Otherwise opening the map I have added just you need to say "squad map". I just added the next bit of code to the CommandPool.cs after the command for nextwaypoint // Move to (10) Command moveTo = new Command("MOVETO", new string[] { "move to", "move", "move there" }, new [] { DirectInputEmulator.KeyPress(DirectInputKeys.Space) }, subjectRef); commandObjects.Add("MOVETO", moveTo); commandSet.Add(moveTo.Item); // Map (11) Command map = new Command("MAP", new string[] { "map" }, new[] { DirectInputEmulator.KeyPress(DirectInputKeys.M) }, subjectRef); commandObjects.Add("MAP", map); commandSet.Add(map.Item); Saying "Squad move to" does what it says.
  3. Am I really the only other person, apart from the original team, that is still looking at this to add extra things?
  4. I am using the latest source and am wondering how on earth to add a map button, I have tried a few things in the Subject.cs because that's where I assume the main area would be? I can add it to the command section thus saying "squad map" and the program selects the squad then opens the map but I just want it to open the map without the "squad" at the start lol. using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Speech.Recognition; using System.Speech.Recognition.SrgsGrammar; using System.Diagnostics; namespace Articulate { class Subject : CommandChunk { public Subject() { GenerateRuleList(); GenerateKeyLookup(); } private void GenerateRuleList() { RuleList = new List<SrgsRule>(); // SQUAD SELECTION SrgsItem one = GetNewNode(new string[] {"one"}, "ONE"); SrgsItem two = GetNewNode(new string[] { "two" }, "TWO"); SrgsItem three = GetNewNode(new string[] { "three" }, "THREE"); SrgsItem four = GetNewNode(new string[] { "four" }, "FOUR"); SrgsItem five = GetNewNode(new string[] { "five" }, "FIVE"); SrgsItem six = GetNewNode(new string[] { "six" }, "SIX"); SrgsItem seven = GetNewNode(new string[] { "seven" }, "SEVEN"); SrgsItem eight = GetNewNode(new string[] { "eight" }, "EIGHT"); SrgsItem nine = GetNewNode(new string[] { "nine" }, "NINE"); SrgsItem ten = GetNewNode(new string[] { "ten" }, "TEN"); SrgsOneOf squadNumbersChoice = new SrgsOneOf(one, two, three, four, five, six, seven, eight, nine, ten); SrgsItem squadNumbersConcatChoice = new SrgsItem(squadNumbersChoice, new SrgsItem(0, 1, "and")); squadNumbersConcatChoice.SetRepeat(1, 10); SrgsRule squadNumbers = new SrgsRule("squadNumbers"); squadNumbers.Add(squadNumbersConcatChoice); RuleList.Add(squadNumbers); SrgsRule squadMembers = new SrgsRule("squadSelections"); squadMembers.Add(new SrgsRuleRef(squadNumbers)); squadMembers.Add(new SrgsSemanticInterpretationTag("out=rules.squadNumbers;")); RuleList.Add(squadMembers); // TEAM SrgsItem red = GetNewNode(new string[] { "red" }, "RED"); SrgsItem yellow = GetNewNode(new string[] { "yellow" }, "YELLOW"); SrgsItem white = GetNewNode(new string[] { "white" }, "WHITE"); SrgsItem blue = GetNewNode(new string[] { "blue" }, "BLUE"); SrgsItem green = GetNewNode(new string[] { "green" }, "GREEN"); SrgsOneOf teamColorsChoice = new SrgsOneOf(blue, green, white, yellow, red); SrgsRule teamColors = new SrgsRule("teamColors"); teamColors.Add(teamColorsChoice); RuleList.Add(teamColors); SrgsRule teams = new SrgsRule("teams"); teams.Add(new SrgsItem("team")); teams.Add(new SrgsRuleRef(teamColors)); teams.Add(new SrgsSemanticInterpretationTag("out=rules.teamColors;")); RuleList.Add(teams); // ALL SrgsItem allItems = GetNewNode(new string[] { "all", "everyone", "team", "squad" }, "ALL"); SrgsRule all = new SrgsRule("all"); all.Add(allItems); RuleList.Add(all); // MAP SrgsItem maps = GetNewNode(new string[] { "map", "mab", "map", "mab" }, "MAP"); SrgsRule map = new SrgsRule("map"); map.Add(maps); RuleList.Add(map); // ALL TOGETHER NOW SrgsOneOf subjectChoice = new SrgsOneOf(); subjectChoice.Add(new SrgsItem(new SrgsRuleRef(teams))); subjectChoice.Add(new SrgsItem(new SrgsRuleRef(squadMembers))); subjectChoice.Add(new SrgsItem(new SrgsRuleRef(all))); subjectChoice.Add(new SrgsItem(new SrgsRuleRef(map))); SrgsRule subject = new SrgsRule("subject"); subject.Add(subjectChoice); RootRule = subject; RuleList.Add(subject); } private void GenerateKeyLookup() { KeyLookup = new Dictionary<string, List<OutputBase>>(); var one = DirectInputEmulator.KeyPress(DirectInputKeys.F1); var two = DirectInputEmulator.KeyPress(DirectInputKeys.F2); var three = DirectInputEmulator.KeyPress(DirectInputKeys.F3); var four = DirectInputEmulator.KeyPress(DirectInputKeys.F4); var five = DirectInputEmulator.KeyPress(DirectInputKeys.F5); var six = DirectInputEmulator.KeyPress(DirectInputKeys.F6); var seven = DirectInputEmulator.KeyPress(DirectInputKeys.F7); var eight = DirectInputEmulator.KeyPress(DirectInputKeys.F8); var nine = DirectInputEmulator.KeyPress(DirectInputKeys.F9); var ten = DirectInputEmulator.KeyPress(DirectInputKeys.F10); var red = DirectInputEmulator.KeyPress(DirectInputKeys.Shift, DirectInputKeys.F1); var green = DirectInputEmulator.KeyPress(DirectInputKeys.Shift, DirectInputKeys.F2); var blue = DirectInputEmulator.KeyPress(DirectInputKeys.Shift, DirectInputKeys.F3); var yellow = DirectInputEmulator.KeyPress(DirectInputKeys.Shift, DirectInputKeys.F4); var white = DirectInputEmulator.KeyPress(DirectInputKeys.Shift, DirectInputKeys.F5); var everyone = new List<OutputBase>(); everyone.Add(DirectInputEmulator.KeyPress(DirectInputKeys.Tilde)); var maps = new List<OutputBase>(); maps.Add(DirectInputEmulator.KeyPress(DirectInputKeys.M)); // SQUAD SELECTION KeyLookup.Add("ONE", new List<OutputBase>() { one }); KeyLookup.Add("TWO", new List<OutputBase>() { two }); KeyLookup.Add("THREE", new List<OutputBase>() { three }); KeyLookup.Add("FOUR", new List<OutputBase>() { four }); KeyLookup.Add("FIVE", new List<OutputBase>() { five }); KeyLookup.Add("SIX", new List<OutputBase>() { six }); KeyLookup.Add("SEVEN", new List<OutputBase>() { seven }); KeyLookup.Add("EIGHT", new List<OutputBase>() { eight }); KeyLookup.Add("NINE", new List<OutputBase>() { nine }); KeyLookup.Add("TEN", new List<OutputBase>() { ten }); // TEAM SELECTION KeyLookup.Add("RED", new List<OutputBase>() { red }); KeyLookup.Add("BLUE", new List<OutputBase>() { blue }); KeyLookup.Add("YELLOW", new List<OutputBase>() { yellow }); KeyLookup.Add("WHITE", new List<OutputBase>() { white }); KeyLookup.Add("GREEN", new List<OutputBase>() { green }); // ALL KeyLookup.Add("ALL", everyone); KeyLookup.Add("MAP", maps); } } }
×