Compare commits

..

2 Commits

Author SHA1 Message Date
Adrian 0da6cc4242 Get length of zero terminated string 2016-02-15 04:25:40 +01:00
Adrian 387a90edff Add gitignore 2016-02-14 19:12:37 +01:00
2 changed files with 8 additions and 1 deletions

3
.gitignore vendored 100644
View File

@ -0,0 +1,3 @@
[Dd]ebug
[Rr]elease
*.userprefs

View File

@ -26,7 +26,6 @@ namespace AdrianKousz.Util
else Write((Int32)0);
}
// TODO: What gets actually written here?
public void WriteZStringRaw(string value) { WriteStringRaw(value + "\0"); }
public void WriteZStringInt16(string value) { WriteStringInt16(value + "\0"); }
public void WriteZStringInt32(string value) { WriteStringInt32(value + "\0"); }
@ -64,5 +63,10 @@ namespace AdrianKousz.Util
{
return encoding.GetByteCount(value);
}
public int GetZByteCount(string value)
{
return encoding.GetByteCount(value + "\0");
}
}
}