Formatting FIxes (#58)
This commit is contained in:
parent
57fb9fb525
commit
096d39609e
1318 changed files with 11633 additions and 22129 deletions
|
|
@ -154,14 +154,12 @@ namespace Server.Engines.Help
|
|||
{
|
||||
string path = Path.Combine(Core.BaseDirectory, "Data/pageresponse.cfg");
|
||||
|
||||
using (StreamWriter op = new StreamWriter(path))
|
||||
using StreamWriter op = new StreamWriter(path);
|
||||
for (int i = 0; i < List.Count; ++i)
|
||||
{
|
||||
for (int i = 0; i < List.Count; ++i)
|
||||
{
|
||||
PredefinedResponse resp = List[i];
|
||||
PredefinedResponse resp = List[i];
|
||||
|
||||
op.WriteLine("{0}\t{1}", resp.Title, resp.Message);
|
||||
}
|
||||
op.WriteLine("{0}\t{1}", resp.Title, resp.Message);
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
|
|
@ -181,20 +179,18 @@ namespace Server.Engines.Help
|
|||
|
||||
try
|
||||
{
|
||||
using (StreamReader ip = new StreamReader(path))
|
||||
using StreamReader ip = new StreamReader(path);
|
||||
string line;
|
||||
|
||||
while ((line = ip.ReadLine()?.Trim()) != null)
|
||||
{
|
||||
string line;
|
||||
if (line.Length == 0 || line.StartsWith("#"))
|
||||
continue;
|
||||
|
||||
while ((line = ip.ReadLine()?.Trim()) != null)
|
||||
{
|
||||
if (line.Length == 0 || line.StartsWith("#"))
|
||||
continue;
|
||||
string[] split = line.Split('\t');
|
||||
|
||||
string[] split = line.Split('\t');
|
||||
|
||||
if (split.Length == 2)
|
||||
list.Add(new PredefinedResponse(split[0], split[1]));
|
||||
}
|
||||
if (split.Length == 2)
|
||||
list.Add(new PredefinedResponse(split[0], split[1]));
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
|
|
@ -305,15 +301,9 @@ namespace Server.Engines.Help
|
|||
}
|
||||
}
|
||||
|
||||
public string Center(string text)
|
||||
{
|
||||
return $"<CENTER>{text}</CENTER>";
|
||||
}
|
||||
public string Center(string text) => $"<CENTER>{text}</CENTER>";
|
||||
|
||||
public string Color(string text, int color)
|
||||
{
|
||||
return $"<BASEFONT COLOR=#{color:X6}>{text}</BASEFONT>";
|
||||
}
|
||||
public string Color(string text, int color) => $"<BASEFONT COLOR=#{color:X6}>{text}</BASEFONT>";
|
||||
|
||||
public void AddTextInput(int x, int y, int w, int h, int id, string def)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue