Skip to content

Commit

Permalink
Merge pull request #575 from vchelaru/568-high-code-generation---slas…
Browse files Browse the repository at this point in the history
…hes-in-file-path-causing-issues-in-visual-studio

The @ character now prefixes string assignments so that slashes '\' i…
  • Loading branch information
vchelaru authored Feb 2, 2025
2 parents 9376334 + fd7f3d2 commit 9665adc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions CodeOutputPlugin/Manager/CodeGenerator.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2432,6 +2432,8 @@ private static void GenerateAssignGumReferences(ElementSave element, VisualApi v

#endregion

#region States

public static string GetCodeForState(ElementSave container, StateSave stateSave, CodeOutputProjectSettings codeOutputProjectSettings)
{
var stringBuilder = new StringBuilder();
Expand All @@ -2456,8 +2458,6 @@ private static VariableSave[] GetVariablesToAssignOnState(StateSave stateSave)
return variablesToConsider;
}

#region States

private static void FillWithStateEnums(CodeGenerationContext context)
{

Expand Down Expand Up @@ -3114,7 +3114,7 @@ private static string VariableValueToGumCode(object value, string rootName, bool
}
else
{
return "\"" + asString.Replace("\n", "\\n") + "\"";
return $"@\"{asString}\"";
}
}
else if (value is bool)
Expand Down

0 comments on commit 9665adc

Please sign in to comment.