mirror of
https://git.do.srb2.org/STJr/UltimateZoneBuilder.git
synced 2024-11-23 04:12:12 +00:00
Fixed, Script Editor: MD5 hash of text files stored in PK3 was calculated incorrectly, resulting in false warning messages when saving.
This commit is contained in:
parent
cfc92d9075
commit
d73ea867a4
3 changed files with 8 additions and 2 deletions
|
@ -584,6 +584,9 @@ namespace CodeImp.DoomBuilder.Data
|
|||
File.WriteAllBytes(location.location, savestream.ToArray());
|
||||
}
|
||||
|
||||
// Rewind the stream (because DirectoryReader/WADReader don't modify stream Position in SaveFile)
|
||||
stream.Position = 0;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
|
@ -10,10 +10,13 @@ namespace CodeImp.DoomBuilder
|
|||
|
||||
public static string Get(Stream stream)
|
||||
{
|
||||
// Rewind the stream
|
||||
stream.Position = 0;
|
||||
|
||||
// Check hash
|
||||
byte[] data = hasher.ComputeHash(stream);
|
||||
|
||||
// Rewind the stream
|
||||
// Rewind the stream again...
|
||||
stream.Position = 0;
|
||||
|
||||
// Create a new Stringbuilder to collect the bytes and create a string.
|
||||
|
|
|
@ -1263,7 +1263,7 @@ namespace CodeImp.DoomBuilder.BuilderModes
|
|||
General.Map.UndoRedo.CreateUndo("Paste properties to " + rest);
|
||||
BuilderPlug.Me.CopiedThingProps.Apply(sel, false);
|
||||
foreach(Thing t in sel) t.UpdateConfiguration();
|
||||
General.Interface.DisplayStatus(StatusType.Action, "Pasted properties to" + rest + ".");
|
||||
General.Interface.DisplayStatus(StatusType.Action, "Pasted properties to " + rest + ".");
|
||||
|
||||
// Update
|
||||
General.Map.IsChanged = true;
|
||||
|
|
Loading…
Reference in a new issue