diff --git a/Sulakore/Habbo/Web/HGameData.cs b/Sulakore/Habbo/Web/HGameData.cs index 34050d9..22907cb 100644 --- a/Sulakore/Habbo/Web/HGameData.cs +++ b/Sulakore/Habbo/Web/HGameData.cs @@ -11,7 +11,7 @@ public class HGameData { private readonly Dictionary _variables; - private const string FLASH_VAR_PATTERN = "('|\")(?.*?)\\1(?>\\s+)?:(?>\\s+)?('|\")(?.*?)\\3"; + private const string FLASH_VAR_PATTERN = "(\"|')+?(?.*?)(\"|')+?(:| :| : |: |,|, )+?(\"|')+?(?.*?)(\"|')+(\\)|,|\\s|$)+"; private string _source; public string Source @@ -55,7 +55,14 @@ public bool ContainsVariable(string variable) private void ExtractVariables() { _variables.Clear(); - MatchCollection matches = Regex.Matches(Source, FLASH_VAR_PATTERN, RegexOptions.Multiline | RegexOptions.Compiled); + + MatchCollection matches = Regex.Matches(Source, FLASH_VAR_PATTERN, + RegexOptions.Multiline +#if !DEBUG + | RegexOptions.Compiled +#endif + ); + foreach (Match match in matches) { string variable = match.Groups["var"].Value;