2017-10-20 02:00:49 +00:00
|
|
|
Class ExtXMLOutput extends FileWriter implements(ExtStatWriter);
|
|
|
|
|
|
|
|
var transient string Intendent;
|
|
|
|
var transient array<string> StackedSect;
|
|
|
|
|
|
|
|
event PreBeginPlay();
|
|
|
|
|
2020-11-28 20:04:55 +00:00
|
|
|
final function DumpXML(ExtPerkManager M)
|
2017-10-20 02:00:49 +00:00
|
|
|
{
|
|
|
|
OpenFile(class'OnlineSubsystem'.Static.UniqueNetIdToString(M.PRIOwner.UniqueId),FWFT_Stats,".xml",false);
|
|
|
|
M.OutputXML(Self);
|
|
|
|
CloseFile();
|
|
|
|
ResetFile();
|
|
|
|
}
|
|
|
|
|
2020-11-28 20:04:55 +00:00
|
|
|
function WriteValue(string Key, string Value)
|
2017-10-20 02:00:49 +00:00
|
|
|
{
|
|
|
|
Logf(Intendent$"<"$Key$">"$Value$"</"$Key$">");
|
|
|
|
}
|
2020-11-28 21:54:57 +00:00
|
|
|
|
2020-11-28 20:04:55 +00:00
|
|
|
function StartIntendent(string Section, optional string Key, optional string Value)
|
2017-10-20 02:00:49 +00:00
|
|
|
{
|
2020-11-28 20:12:58 +00:00
|
|
|
if (Key!="")
|
2017-10-20 02:00:49 +00:00
|
|
|
Logf(Intendent$"-<"$Section$" "$Key$"=\""$Value$"\">");
|
|
|
|
else Logf(Intendent$"-<"$Section$">");
|
|
|
|
Intendent $= Chr(9);
|
|
|
|
StackedSect.AddItem(Section);
|
|
|
|
}
|
2020-11-28 21:54:57 +00:00
|
|
|
|
2017-10-20 02:00:49 +00:00
|
|
|
function EndIntendent()
|
|
|
|
{
|
|
|
|
Intendent = Left(Intendent,Len(Intendent)-1);
|
|
|
|
Logf(Intendent$"</"$StackedSect[StackedSect.Length-1]$">");
|
|
|
|
StackedSect.Remove(StackedSect.Length-1,1);
|
|
|
|
}
|
2020-11-28 21:54:57 +00:00
|
|
|
|
2017-10-20 02:00:49 +00:00
|
|
|
function ResetFile()
|
|
|
|
{
|
|
|
|
Intendent = "";
|
|
|
|
StackedSect.Length = 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
defaultproperties
|
|
|
|
{
|
|
|
|
bFlushEachWrite=false
|
|
|
|
}
|