File tree Expand file tree Collapse file tree 4 files changed +21
-3
lines changed
UndertaleModLib/Scripting Expand file tree Collapse file tree 4 files changed +21
-3
lines changed Original file line number Diff line number Diff line change @@ -84,6 +84,13 @@ public void ScriptMessage(string message)
8484 if ( IsInteractive ) Pause ( ) ;
8585 }
8686
87+ /// <inheritdoc/>
88+ public void ScriptWarning ( string message )
89+ {
90+ Console . WriteLine ( $ "WARNING: { message } ") ;
91+ if ( IsInteractive ) Pause ( ) ;
92+ }
93+
8794 /// <inheritdoc/>
8895 public void SetUMTConsoleText ( string message )
8996 {
Original file line number Diff line number Diff line change @@ -113,11 +113,17 @@ void EnsureDataLoaded()
113113 bool MakeNewDataFile ( ) ;
114114
115115 /// <summary>
116- /// Used in Scripts in order to show a message to the user.
116+ /// Used in scripts in order to show a message to the user.
117117 /// </summary>
118118 /// <param name="message">The message to show.</param>
119119 void ScriptMessage ( string message ) ;
120120
121+ /// <summary>
122+ /// Used in scripts in order to show a warning message to the user.
123+ /// </summary>
124+ /// <param name="message">The warning message to show.</param>
125+ void ScriptWarning ( string message ) ;
126+
121127 //TODO: currently should get repurposed/renamed?
122128 /// <summary>
123129 /// Sets the message of the variable holding text from the console. Currently only used in GUI.
@@ -133,7 +139,7 @@ void EnsureDataLoaded()
133139 bool ScriptQuestion ( string message ) ;
134140
135141 /// <summary>
136- /// Used in Scripts in order to show an error to the user.
142+ /// Used in scripts in order to show an error to the user.
137143 /// </summary>
138144 /// <param name="error">The error message to show.</param>
139145 /// <param name="title">A short-descriptive title.</param>
Original file line number Diff line number Diff line change @@ -66,6 +66,11 @@ public void ScriptMessage(string message)
6666 Console . WriteLine ( message ) ;
6767 }
6868
69+ public void ScriptWarning ( string message )
70+ {
71+ Console . WriteLine ( $ "Warning: { message } ") ;
72+ }
73+
6974 public bool ScriptQuestion ( string message )
7075 {
7176 Console . WriteLine ( message ) ;
Original file line number Diff line number Diff line change @@ -1251,7 +1251,7 @@ UndertaleFont FontPickerResult()
12511251 comboBox . Anchor = AnchorStyles . Left | AnchorStyles . Top | AnchorStyles . Right ;
12521252 foreach ( UndertaleFont font in Data . Fonts )
12531253 {
1254- if ( font is null || font . Name ? . Content ? is null)
1254+ if ( font is null || font . Name ? . Content is null )
12551255 continue ;
12561256 comboBox . Items . Add ( font . Name . Content ) ;
12571257 }
You can’t perform that action at this time.
0 commit comments