public string GetSyntaxArgByBinary(string placeholder, BinaryString argBinary) { if (LanguageDefinition.PlaceHolders.EERegisters.Contains(placeholder)) { return(LanguageDefinition.EERegisters .Find(r => r.Binary == argBinary.Value)?.TextDisplay); } else if (LanguageDefinition.PlaceHolders.COP0Registers.Equals(placeholder)) { return(LanguageDefinition.COP0Registers .Find(r => r.Binary == argBinary.Value)?.TextDisplay); } else if (LanguageDefinition.PlaceHolders.COP1Registers.Contains(placeholder)) { return(LanguageDefinition.COP1Registers .Find(r => r.Binary == argBinary.Value)?.TextDisplay); } else if (LanguageDefinition.PlaceHolders.JType.Equals(placeholder)) { return("$" + Convert.ToString(argBinary.ToInt() * 4, 16).PadLeft(8, '0')); } else if (LanguageDefinition.PlaceHolders.IType.Contains(placeholder)) { return("$" + argBinary.ToHexString().Value); } else if (LanguageDefinition.PlaceHolders.SA.Equals(placeholder)) { return(argBinary.ToInt().ToString()); } else if (LanguageDefinition.PlaceHolders.Code.Equals(placeholder)) { return(argBinary.ToHexString().Value.PadLeft(5, '0')); } else { return(null); } }