├── .gitattributes ├── Be.Windows.Forms.HexBox ├── AssemblyInfo.cs ├── Be.Windows.Forms.HexBox.csproj ├── Be.Windows.Forms.HexBox.xml ├── BuiltInContextMenu.cs ├── ByteCharConverters.cs ├── ByteCollection.cs ├── BytePositionInfo.cs ├── DataBlock.cs ├── DataMap.cs ├── DynamicByteProvider.cs ├── DynamicFileByteProvider.cs ├── FileByteProvider.cs ├── FileDataBlock.cs ├── FindOptions.cs ├── HexBox.bmp ├── HexBox.cs ├── HexBox.resx ├── HexBox.snk ├── HexCasing.cs ├── IByteProvider.cs ├── MemoryDataBlock.cs ├── NativeMethods.cs ├── Properties │ ├── Resources.Designer.cs │ └── Resources.resx ├── Util.cs ├── bin │ └── Debug │ │ ├── Be.Windows.Forms.HexBox.dll │ │ └── Be.Windows.Forms.HexBox.xml └── obj │ └── Debug │ ├── Be.Windows.Forms.HexBox.csproj.FileListAbsolute.txt │ ├── Be.Windows.Forms.HexBox.csproj.GenerateResource.Cache │ ├── Be.Windows.Forms.HexBox.csprojResolveAssemblyReference.cache │ ├── Be.Windows.Forms.HexBox.dll │ ├── Be.Windows.Forms.HexBox.resources │ ├── Be.Windows.Forms.Properties.Resources.resources │ ├── DesignTimeResolveAssemblyReferences.cache │ ├── DesignTimeResolveAssemblyReferencesInput.cache │ └── TempPE │ └── Properties.Resources.Designer.cs.dll ├── DAILibWV ├── DAILibWV.csproj ├── DBAccess.cs ├── Debug.cs ├── Frostbite │ ├── BJSON.cs │ ├── BinaryBundle.cs │ ├── Bundle.cs │ ├── CASFile.cs │ ├── CATFile.cs │ ├── EBXStream.cs │ ├── Mesh.cs │ ├── SBFile.cs │ ├── TOCFile.cs │ ├── Talktable.cs │ └── TextureMetaResource.cs ├── GlobalStuff.cs ├── HalfUtil.cs ├── Helpers.cs ├── Mod.cs ├── OldSupport │ └── DAIMODFile.cs ├── Properties │ └── AssemblyInfo.cs ├── SHA1Access.cs ├── bin │ └── Debug │ │ ├── DAILibWV.dll │ │ ├── ICSharpCode.SharpZipLib.dll │ │ ├── System.Data.SQLite.dll │ │ └── System.Data.SQLite.xml ├── obj │ └── Debug │ │ ├── DAILibWV.csproj.FileListAbsolute.txt │ │ ├── DAILibWV.csprojResolveAssemblyReference.cache │ │ ├── DAILibWV.dll │ │ ├── DesignTimeResolveAssemblyReferencesInput.cache │ │ ├── TemporaryGeneratedFile_036C0B5B-1481-4323-8D20-8F5ADCB23D92.cs │ │ ├── TemporaryGeneratedFile_5937a670-0e60-4077-877b-f7221da3dda1.cs │ │ └── TemporaryGeneratedFile_E7A71F73-0F8D-4B9B-B56E-8E70B10BC5D3.cs └── ref │ ├── ICSharpCode.SharpZipLib.dll │ ├── System.Data.SQLite.dll │ └── System.Data.SQLite.xml ├── DAIToolsWV.sln ├── DAIToolsWV.v11.suo ├── DAIToolsWV ├── App.config ├── Browser │ ├── BundleBrowser.Designer.cs │ ├── BundleBrowser.cs │ ├── BundleBrowser.resx │ ├── EBXBrowser.Designer.cs │ ├── EBXBrowser.cs │ ├── EBXBrowser.resx │ ├── FileBrowser.Designer.cs │ ├── FileBrowser.cs │ ├── FileBrowser.resx │ ├── MeshBrowser.Designer.cs │ ├── MeshBrowser.cs │ ├── MeshBrowser.resx │ ├── RESBrowser.Designer.cs │ ├── RESBrowser.cs │ ├── RESBrowser.resx │ ├── TextureBrowser.Designer.cs │ ├── TextureBrowser.cs │ └── TextureBrowser.resx ├── ContentTools │ ├── EBXTool.Designer.cs │ ├── EBXTool.cs │ ├── EBXTool.resx │ ├── MeshTool.Designer.cs │ ├── MeshTool.cs │ ├── MeshTool.resx │ ├── SHA1Lookup.Designer.cs │ ├── SHA1Lookup.cs │ ├── SHA1Lookup.resx │ ├── TalktableTool.Designer.cs │ ├── TalktableTool.cs │ ├── TalktableTool.resx │ ├── TextureTool.Designer.cs │ ├── TextureTool.cs │ └── TextureTool.resx ├── DAIToolsWV.csproj ├── DAIToolsWV.csproj.user ├── DebugOutputWindow.Designer.cs ├── DebugOutputWindow.cs ├── DebugOutputWindow.resx ├── FileTools │ ├── BundleBuilder.Designer.cs │ ├── BundleBuilder.cs │ ├── BundleBuilder.resx │ ├── CASContainerCreator.Designer.cs │ ├── CASContainerCreator.cs │ ├── CASContainerCreator.resx │ ├── DAIMODSupportTool.Designer.cs │ ├── DAIMODSupportTool.cs │ ├── DAIMODSupportTool.resx │ ├── HexTool.Designer.cs │ ├── HexTool.cs │ ├── HexTool.resx │ ├── INITFSTool.Designer.cs │ ├── INITFSTool.cs │ ├── INITFSTool.resx │ ├── MFTTool.Designer.cs │ ├── MFTTool.cs │ ├── MFTTool.resx │ ├── SBTool.Designer.cs │ ├── SBTool.cs │ ├── SBTool.resx │ ├── SBTool_InputForm.Designer.cs │ ├── SBTool_InputForm.cs │ ├── SBTool_InputForm.resx │ ├── TOCTool.Designer.cs │ ├── TOCTool.cs │ ├── TOCTool.resx │ ├── TOCTool_InputForm.Designer.cs │ ├── TOCTool_InputForm.cs │ └── TOCTool_InputForm.resx ├── FixedByteProvider.cs ├── GeneralTools │ ├── CATrepair.Designer.cs │ ├── CATrepair.cs │ ├── CATrepair.resx │ ├── FolderCompare.Designer.cs │ ├── FolderCompare.cs │ ├── FolderCompare.resx │ ├── HexToString.Designer.cs │ ├── HexToString.cs │ └── HexToString.resx ├── MainForm.Designer.cs ├── MainForm.cs ├── MainForm.resx ├── ModTools │ ├── ModEditor.Designer.cs │ ├── ModEditor.cs │ ├── ModEditor.resx │ ├── ModRunner.Designer.cs │ ├── ModRunner.cs │ └── ModRunner.resx ├── PSKFile.cs ├── Program.cs ├── Properties │ ├── AssemblyInfo.cs │ ├── Resources.Designer.cs │ ├── Resources.resx │ ├── Settings.Designer.cs │ └── Settings.settings ├── Render │ ├── MeshRenderObject.cs │ ├── RenderObject.cs │ └── Renderer.cs ├── bin │ └── Debug │ │ ├── Be.Windows.Forms.HexBox.dll │ │ ├── Be.Windows.Forms.HexBox.xml │ │ ├── DAILibWV.dll │ │ ├── DAIToolsWV.exe │ │ ├── DAIToolsWV.exe.config │ │ ├── DAIToolsWV.vshost.exe │ │ ├── DAIToolsWV.vshost.exe.config │ │ ├── DAIToolsWV.vshost.exe.manifest │ │ ├── DevIL.NET.dll │ │ ├── DevIL.dll │ │ ├── ICSharpCode.SharpZipLib.dll │ │ ├── Microsoft.DirectX.Direct3D.dll │ │ ├── Microsoft.DirectX.Direct3DX.dll │ │ ├── Microsoft.DirectX.dll │ │ ├── System.Data.SQLite.dll │ │ ├── System.Data.SQLite.xml │ │ ├── _cleanup.bat │ │ └── ext │ │ ├── img │ │ └── Default.bmp │ │ ├── keys │ │ └── mft_key.bin │ │ └── luacdec │ │ ├── compare.rb │ │ ├── dec.bat │ │ ├── lua.exe │ │ ├── luac.exe │ │ ├── luadec.exe │ │ ├── luadecguess.rb │ │ ├── temp.lua │ │ └── temp.luac ├── obj │ ├── Debug │ │ ├── DAIToolsWV.Browser.BundleBrowser.resources │ │ ├── DAIToolsWV.Browser.EBXBrowser.resources │ │ ├── DAIToolsWV.Browser.FileBrowser.resources │ │ ├── DAIToolsWV.Browser.MeshBrowser.resources │ │ ├── DAIToolsWV.Browser.RESBrowser.resources │ │ ├── DAIToolsWV.Browser.TextureBrowser.resources │ │ ├── DAIToolsWV.ContentTools.EBXTool.resources │ │ ├── DAIToolsWV.ContentTools.MeshTool.resources │ │ ├── DAIToolsWV.ContentTools.SHA1Lookup.resources │ │ ├── DAIToolsWV.ContentTools.TalktableTool.resources │ │ ├── DAIToolsWV.ContentTools.TextureTool.resources │ │ ├── DAIToolsWV.DebugOutputWindow.resources │ │ ├── DAIToolsWV.FileTools.BundleBuilder.resources │ │ ├── DAIToolsWV.FileTools.CASContainerCreator.resources │ │ ├── DAIToolsWV.FileTools.DAIMODSupportTool.resources │ │ ├── DAIToolsWV.FileTools.HexTool.resources │ │ ├── DAIToolsWV.FileTools.INITFSTool.resources │ │ ├── DAIToolsWV.FileTools.MFTTool.resources │ │ ├── DAIToolsWV.FileTools.SBTool.resources │ │ ├── DAIToolsWV.FileTools.SBTool_InputForm.resources │ │ ├── DAIToolsWV.FileTools.TOCTool.resources │ │ ├── DAIToolsWV.FileTools.TOCTool_InputForm.resources │ │ ├── DAIToolsWV.GeneralTools.CATrepair.resources │ │ ├── DAIToolsWV.GeneralTools.FolderCompare.resources │ │ ├── DAIToolsWV.GeneralTools.HexToString.resources │ │ ├── DAIToolsWV.MainForm.resources │ │ ├── DAIToolsWV.ModTools.ModEditor.resources │ │ ├── DAIToolsWV.ModTools.ModRunner.resources │ │ ├── DAIToolsWV.Properties.Resources.resources │ │ ├── DAIToolsWV.csproj.FileListAbsolute.txt │ │ ├── DAIToolsWV.csproj.GenerateResource.Cache │ │ ├── DAIToolsWV.csprojResolveAssemblyReference.cache │ │ ├── DAIToolsWV.exe │ │ ├── DesignTimeResolveAssemblyReferences.cache │ │ ├── DesignTimeResolveAssemblyReferencesInput.cache │ │ ├── TemporaryGeneratedFile_036C0B5B-1481-4323-8D20-8F5ADCB23D92.cs │ │ ├── TemporaryGeneratedFile_5937a670-0e60-4077-877b-f7221da3dda1.cs │ │ └── TemporaryGeneratedFile_E7A71F73-0F8D-4B9B-B56E-8E70B10BC5D3.cs │ └── x86 │ │ └── Debug │ │ ├── DAIToolsWV.MainForm.resources │ │ ├── DAIToolsWV.Properties.Resources.resources │ │ ├── DAIToolsWV.csproj.FileListAbsolute.txt │ │ ├── DAIToolsWV.csproj.GenerateResource.Cache │ │ ├── DAIToolsWV.exe │ │ ├── DesignTimeResolveAssemblyReferencesInput.cache │ │ ├── TemporaryGeneratedFile_036C0B5B-1481-4323-8D20-8F5ADCB23D92.cs │ │ ├── TemporaryGeneratedFile_5937a670-0e60-4077-877b-f7221da3dda1.cs │ │ └── TemporaryGeneratedFile_E7A71F73-0F8D-4B9B-B56E-8E70B10BC5D3.cs └── res │ └── papertile.jpg ├── README.md └── _cleanup.bat /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto 3 | 4 | # Custom for Visual Studio 5 | *.cs diff=csharp 6 | 7 | # Standard to msysgit 8 | *.doc diff=astextplain 9 | *.DOC diff=astextplain 10 | *.docx diff=astextplain 11 | *.DOCX diff=astextplain 12 | *.dot diff=astextplain 13 | *.DOT diff=astextplain 14 | *.pdf diff=astextplain 15 | *.PDF diff=astextplain 16 | *.rtf diff=astextplain 17 | *.RTF diff=astextplain 18 | -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Reflection; 3 | using System.Runtime.CompilerServices; 4 | using System.Security.Permissions; 5 | using System.Runtime.InteropServices; 6 | 7 | // 8 | // General Information about an assembly is controlled through the following 9 | // set of attributes. Change these attribute values to modify the information 10 | // associated with an assembly. 11 | // 12 | [assembly: AssemblyTitle("Be.Windows.Forms.HexBox")] 13 | [assembly: AssemblyDescription("hex edit control (C# DOTNET)")] 14 | [assembly: AssemblyConfiguration("")] 15 | [assembly: AssemblyCompany("Be")] 16 | [assembly: AssemblyProduct("Be.Windows.Forms.HexBox")] 17 | [assembly: AssemblyCopyright("")] 18 | [assembly: AssemblyTrademark("")] 19 | [assembly: AssemblyCulture("")] 20 | 21 | // 22 | // Version information for an assembly consists of the following four values: 23 | // 24 | // Major Version 25 | // Minor Version 26 | // Build Number 27 | // Revision 28 | // 29 | // You can specify all the values or you can default the Revision and Build Numbers 30 | // by using the '*' as shown below: 31 | 32 | [assembly: AssemblyVersion("1.4.7.*")] 33 | 34 | // 35 | // In order to sign your assembly you must specify a key to use. Refer to the 36 | // Microsoft .NET Framework documentation for more information on assembly signing. 37 | // 38 | // Use the attributes below to control which key is used for signing. 39 | // 40 | // Notes: 41 | // (*) If no key is specified, the assembly is not signed. 42 | // (*) KeyName refers to a key that has been installed in the Crypto Service 43 | // Provider (CSP) on your machine. KeyFile refers to a file which contains 44 | // a key. 45 | // (*) If the KeyFile and the KeyName values are both specified, the 46 | // following processing occurs: 47 | // (1) If the KeyName can be found in the CSP, that key is used. 48 | // (2) If the KeyName does not exist and the KeyFile does exist, the key 49 | // in the KeyFile is installed into the CSP and used. 50 | // (*) In order to create a KeyFile, you can use the sn.exe (Strong Name) utility. 51 | // When specifying the KeyFile, the location of the KeyFile should be 52 | // relative to the project output directory which is 53 | // %Project Directory%\obj\. For example, if your KeyFile is 54 | // located in the project directory, you would specify the AssemblyKeyFile 55 | // attribute as [assembly: AssemblyKeyFile("..\\..\\mykey.snk")] 56 | // (*) Delay Signing is an advanced option - see the Microsoft .NET Framework 57 | // documentation for more information on this. 58 | // 59 | [assembly: AssemblyDelaySign(false)] 60 | 61 | //[assembly: AssemblyKeyFile("../../HexBox.snk")] 62 | //[assembly: AssemblyKeyName("")] 63 | 64 | //[assembly:IsolatedStorageFilePermission(SecurityAction.RequestRefuse, UserQuota=1048576)] 65 | //[assembly:SecurityPermission(SecurityAction.RequestRefuse, UnmanagedCode=true)] 66 | //[assembly:FileIOPermission(SecurityAction.RequestOptional, Unrestricted=true)] 67 | 68 | [assembly:CLSCompliant(true)] 69 | 70 | [assembly:ComVisible(false)] -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/ByteCharConverters.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Be.Windows.Forms 6 | { 7 | /// 8 | /// The interface for objects that can translate between characters and bytes. 9 | /// 10 | public interface IByteCharConverter 11 | { 12 | /// 13 | /// Returns the character to display for the byte passed across. 14 | /// 15 | /// 16 | /// 17 | char ToChar(byte b); 18 | 19 | /// 20 | /// Returns the byte to use when the character passed across is entered during editing. 21 | /// 22 | /// 23 | /// 24 | byte ToByte(char c); 25 | } 26 | 27 | /// 28 | /// The default implementation. 29 | /// 30 | public class DefaultByteCharConverter : IByteCharConverter 31 | { 32 | /// 33 | /// Returns the character to display for the byte passed across. 34 | /// 35 | /// 36 | /// 37 | public virtual char ToChar(byte b) 38 | { 39 | return b > 0x1F && !(b > 0x7E && b < 0xA0) ? (char)b : '.'; 40 | } 41 | 42 | /// 43 | /// Returns the byte to use for the character passed across. 44 | /// 45 | /// 46 | /// 47 | public virtual byte ToByte(char c) 48 | { 49 | return (byte)c; 50 | } 51 | 52 | /// 53 | /// Returns a description of the byte char provider. 54 | /// 55 | /// 56 | public override string ToString() 57 | { 58 | return "Default"; 59 | } 60 | } 61 | 62 | /// 63 | /// A byte char provider that can translate bytes encoded in codepage 500 EBCDIC 64 | /// 65 | public class EbcdicByteCharProvider : IByteCharConverter 66 | { 67 | /// 68 | /// The IBM EBCDIC code page 500 encoding. Note that this is not always supported by .NET, 69 | /// the underlying platform has to provide support for it. 70 | /// 71 | private Encoding _ebcdicEncoding = Encoding.GetEncoding(500); 72 | 73 | /// 74 | /// Returns the EBCDIC character corresponding to the byte passed across. 75 | /// 76 | /// 77 | /// 78 | public virtual char ToChar(byte b) 79 | { 80 | string encoded = _ebcdicEncoding.GetString(new byte[] { b }); 81 | return encoded.Length > 0 ? encoded[0] : '.'; 82 | } 83 | 84 | /// 85 | /// Returns the byte corresponding to the EBCDIC character passed across. 86 | /// 87 | /// 88 | /// 89 | public virtual byte ToByte(char c) 90 | { 91 | byte[] decoded = _ebcdicEncoding.GetBytes(new char[] { c }); 92 | return decoded.Length > 0 ? decoded[0] : (byte)0; 93 | } 94 | 95 | /// 96 | /// Returns a description of the byte char provider. 97 | /// 98 | /// 99 | public override string ToString() 100 | { 101 | return "EBCDIC (Code Page 500)"; 102 | } 103 | } 104 | } 105 | -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/ByteCollection.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | using System.Collections; 4 | 5 | namespace Be.Windows.Forms 6 | { 7 | /// 8 | /// Represents a collection of bytes. 9 | /// 10 | public class ByteCollection : CollectionBase 11 | { 12 | /// 13 | /// Initializes a new instance of ByteCollection class. 14 | /// 15 | public ByteCollection() { } 16 | 17 | /// 18 | /// Initializes a new instance of ByteCollection class. 19 | /// 20 | /// an array of bytes to add to collection 21 | public ByteCollection(byte[] bs) 22 | { AddRange(bs); } 23 | 24 | /// 25 | /// Gets or sets the value of a byte 26 | /// 27 | public byte this[int index] 28 | { 29 | get { return (byte)List[index]; } 30 | set { List[index] = value; } 31 | } 32 | 33 | /// 34 | /// Adds a byte into the collection. 35 | /// 36 | /// the byte to add 37 | public void Add(byte b) 38 | { List.Add(b); } 39 | 40 | /// 41 | /// Adds a range of bytes to the collection. 42 | /// 43 | /// the bytes to add 44 | public void AddRange(byte[] bs) 45 | { InnerList.AddRange(bs); } 46 | 47 | /// 48 | /// Removes a byte from the collection. 49 | /// 50 | /// the byte to remove 51 | public void Remove(byte b) 52 | { List.Remove(b); } 53 | 54 | /// 55 | /// Removes a range of bytes from the collection. 56 | /// 57 | /// the index of the start byte 58 | /// the count of the bytes to remove 59 | public void RemoveRange(int index, int count) 60 | { InnerList.RemoveRange(index, count); } 61 | 62 | /// 63 | /// Inserts a range of bytes to the collection. 64 | /// 65 | /// the index of start byte 66 | /// an array of bytes to insert 67 | public void InsertRange(int index, byte[] bs) 68 | { InnerList.InsertRange(index, bs); } 69 | 70 | /// 71 | /// Gets all bytes in the array 72 | /// 73 | /// an array of bytes. 74 | public byte[] GetBytes() 75 | { 76 | byte[] bytes = new byte[Count]; 77 | InnerList.CopyTo(0, bytes, 0, bytes.Length); 78 | return bytes; 79 | } 80 | 81 | /// 82 | /// Inserts a byte to the collection. 83 | /// 84 | /// the index 85 | /// a byte to insert 86 | public void Insert(int index, byte b) 87 | { 88 | InnerList.Insert(index, b); 89 | } 90 | 91 | /// 92 | /// Returns the index of the given byte. 93 | /// 94 | public int IndexOf(byte b) 95 | { 96 | return InnerList.IndexOf(b); 97 | } 98 | 99 | /// 100 | /// Returns true, if the byte exists in the collection. 101 | /// 102 | public bool Contains(byte b) 103 | { 104 | return InnerList.Contains(b); 105 | } 106 | 107 | /// 108 | /// Copies the content of the collection into the given array. 109 | /// 110 | public void CopyTo(byte[] bs, int index) 111 | { 112 | InnerList.CopyTo(bs, index); 113 | } 114 | 115 | /// 116 | /// Copies the content of the collection into an array. 117 | /// 118 | /// the array containing all bytes. 119 | public byte[] ToArray() 120 | { 121 | byte[] data = new byte[this.Count]; 122 | this.CopyTo(data, 0); 123 | return data; 124 | } 125 | 126 | } 127 | } 128 | -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/BytePositionInfo.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Be.Windows.Forms 6 | { 7 | /// 8 | /// Represents a position in the HexBox control 9 | /// 10 | struct BytePositionInfo 11 | { 12 | public BytePositionInfo(long index, int characterPosition) 13 | { 14 | _index = index; 15 | _characterPosition = characterPosition; 16 | } 17 | 18 | public int CharacterPosition 19 | { 20 | get { return _characterPosition; } 21 | } int _characterPosition; 22 | 23 | public long Index 24 | { 25 | get { return _index; } 26 | } long _index; 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/DataBlock.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Be.Windows.Forms 4 | { 5 | internal abstract class DataBlock 6 | { 7 | internal DataMap _map; 8 | internal DataBlock _nextBlock; 9 | internal DataBlock _previousBlock; 10 | 11 | public abstract long Length 12 | { 13 | get; 14 | } 15 | 16 | public DataMap Map 17 | { 18 | get 19 | { 20 | return _map; 21 | } 22 | } 23 | 24 | public DataBlock NextBlock 25 | { 26 | get 27 | { 28 | return _nextBlock; 29 | } 30 | } 31 | 32 | public DataBlock PreviousBlock 33 | { 34 | get 35 | { 36 | return _previousBlock; 37 | } 38 | } 39 | 40 | public abstract void RemoveBytes(long position, long count); 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/DynamicByteProvider.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace Be.Windows.Forms 5 | { 6 | /// 7 | /// Byte provider for a small amount of data. 8 | /// 9 | public class DynamicByteProvider : IByteProvider 10 | { 11 | /// 12 | /// Contains information about changes. 13 | /// 14 | bool _hasChanges; 15 | /// 16 | /// Contains a byte collection. 17 | /// 18 | List _bytes; 19 | 20 | /// 21 | /// Initializes a new instance of the DynamicByteProvider class. 22 | /// 23 | /// 24 | public DynamicByteProvider(byte[] data) : this(new List(data)) 25 | { 26 | } 27 | 28 | /// 29 | /// Initializes a new instance of the DynamicByteProvider class. 30 | /// 31 | /// 32 | public DynamicByteProvider(List bytes) 33 | { 34 | _bytes = bytes; 35 | } 36 | 37 | /// 38 | /// Raises the Changed event. 39 | /// 40 | void OnChanged(EventArgs e) 41 | { 42 | _hasChanges = true; 43 | 44 | if(Changed != null) 45 | Changed(this, e); 46 | } 47 | 48 | /// 49 | /// Raises the LengthChanged event. 50 | /// 51 | void OnLengthChanged(EventArgs e) 52 | { 53 | if(LengthChanged != null) 54 | LengthChanged(this, e); 55 | } 56 | 57 | /// 58 | /// Gets the byte collection. 59 | /// 60 | public List Bytes 61 | { 62 | get { return _bytes; } 63 | } 64 | 65 | #region IByteProvider Members 66 | /// 67 | /// True, when changes are done. 68 | /// 69 | public bool HasChanges() 70 | { 71 | return _hasChanges; 72 | } 73 | 74 | /// 75 | /// Applies changes. 76 | /// 77 | public void ApplyChanges() 78 | { 79 | _hasChanges = false; 80 | } 81 | 82 | /// 83 | /// Occurs, when the write buffer contains new changes. 84 | /// 85 | public event EventHandler Changed; 86 | 87 | /// 88 | /// Occurs, when InsertBytes or DeleteBytes method is called. 89 | /// 90 | public event EventHandler LengthChanged; 91 | 92 | 93 | /// 94 | /// Reads a byte from the byte collection. 95 | /// 96 | /// the index of the byte to read 97 | /// the byte 98 | public byte ReadByte(long index) 99 | { return _bytes[(int)index]; } 100 | 101 | /// 102 | /// Write a byte into the byte collection. 103 | /// 104 | /// the index of the byte to write. 105 | /// the byte 106 | public void WriteByte(long index, byte value) 107 | { 108 | _bytes[(int)index] = value; 109 | OnChanged(EventArgs.Empty); 110 | } 111 | 112 | /// 113 | /// Deletes bytes from the byte collection. 114 | /// 115 | /// the start index of the bytes to delete. 116 | /// the length of bytes to delete. 117 | public void DeleteBytes(long index, long length) 118 | { 119 | int internal_index = (int)Math.Max(0, index); 120 | int internal_length = (int)Math.Min((int)Length, length); 121 | _bytes.RemoveRange(internal_index, internal_length); 122 | 123 | OnLengthChanged(EventArgs.Empty); 124 | OnChanged(EventArgs.Empty); 125 | } 126 | 127 | /// 128 | /// Inserts byte into the byte collection. 129 | /// 130 | /// the start index of the bytes in the byte collection 131 | /// the byte array to insert 132 | public void InsertBytes(long index, byte[] bs) 133 | { 134 | _bytes.InsertRange((int)index, bs); 135 | 136 | OnLengthChanged(EventArgs.Empty); 137 | OnChanged(EventArgs.Empty); 138 | } 139 | 140 | /// 141 | /// Gets the length of the bytes in the byte collection. 142 | /// 143 | public long Length 144 | { 145 | get 146 | { 147 | return _bytes.Count; 148 | } 149 | } 150 | 151 | /// 152 | /// Returns true 153 | /// 154 | public bool SupportsWriteByte() 155 | { 156 | return true; 157 | } 158 | 159 | /// 160 | /// Returns true 161 | /// 162 | public bool SupportsInsertBytes() 163 | { 164 | return true; 165 | } 166 | 167 | /// 168 | /// Returns true 169 | /// 170 | public bool SupportsDeleteBytes() 171 | { 172 | return true; 173 | } 174 | #endregion 175 | 176 | } 177 | } 178 | -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/FileDataBlock.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Be.Windows.Forms 4 | { 5 | internal sealed class FileDataBlock : DataBlock 6 | { 7 | long _length; 8 | long _fileOffset; 9 | 10 | public FileDataBlock(long fileOffset, long length) 11 | { 12 | _fileOffset = fileOffset; 13 | _length = length; 14 | } 15 | 16 | public long FileOffset 17 | { 18 | get 19 | { 20 | return _fileOffset; 21 | } 22 | } 23 | 24 | public override long Length 25 | { 26 | get 27 | { 28 | return _length; 29 | } 30 | } 31 | 32 | public void SetFileOffset(long value) 33 | { 34 | _fileOffset = value; 35 | } 36 | 37 | public void RemoveBytesFromEnd(long count) 38 | { 39 | if (count > _length) 40 | { 41 | throw new ArgumentOutOfRangeException("count"); 42 | } 43 | 44 | _length -= count; 45 | } 46 | 47 | public void RemoveBytesFromStart(long count) 48 | { 49 | if (count > _length) 50 | { 51 | throw new ArgumentOutOfRangeException("count"); 52 | } 53 | 54 | _fileOffset += count; 55 | _length -= count; 56 | } 57 | 58 | public override void RemoveBytes(long position, long count) 59 | { 60 | if (position > _length) 61 | { 62 | throw new ArgumentOutOfRangeException("position"); 63 | } 64 | 65 | if (position + count > _length) 66 | { 67 | throw new ArgumentOutOfRangeException("count"); 68 | } 69 | 70 | long prefixLength = position; 71 | long prefixFileOffset = _fileOffset; 72 | 73 | long suffixLength = _length - count - prefixLength; 74 | long suffixFileOffset = _fileOffset + position + count; 75 | 76 | if (prefixLength > 0 && suffixLength > 0) 77 | { 78 | _fileOffset = prefixFileOffset; 79 | _length = prefixLength; 80 | _map.AddAfter(this, new FileDataBlock(suffixFileOffset, suffixLength)); 81 | return; 82 | } 83 | 84 | if (prefixLength > 0) 85 | { 86 | _fileOffset = prefixFileOffset; 87 | _length = prefixLength; 88 | } 89 | else 90 | { 91 | _fileOffset = suffixFileOffset; 92 | _length = suffixLength; 93 | } 94 | } 95 | } 96 | } 97 | -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/FindOptions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Be.Windows.Forms 6 | { 7 | /// 8 | /// Defines the type of the Find operation. 9 | /// 10 | public enum FindType 11 | { 12 | /// 13 | /// Used for Text Find operations 14 | /// 15 | Text, 16 | /// 17 | /// Used for Hex Find operations 18 | /// 19 | Hex 20 | } 21 | 22 | /// 23 | /// Defines all state information nee 24 | /// 25 | public class FindOptions 26 | { 27 | /// 28 | /// Gets or sets whether the Find options are valid 29 | /// 30 | public bool IsValid { get; set; } 31 | /// 32 | /// Gets the Find buffer used for case insensitive Find operations. This is the binary representation of Text. 33 | /// 34 | internal byte[] FindBuffer { get; private set; } 35 | /// 36 | /// Gets the Find buffer used for case sensitive Find operations. This is the binary representation of Text in lower case format. 37 | /// 38 | internal byte[] FindBufferLowerCase { get; private set; } 39 | /// 40 | /// Gets the Find buffer used for case sensitive Find operations. This is the binary representation of Text in upper case format. 41 | /// 42 | internal byte[] FindBufferUpperCase { get; private set; } 43 | /// 44 | /// Contains the MatchCase value 45 | /// 46 | bool _matchCase; 47 | /// 48 | /// Gets or sets the value, whether the Find operation is case sensitive or not. 49 | /// 50 | public bool MatchCase 51 | { 52 | get { return _matchCase; } 53 | set 54 | { 55 | _matchCase = value; 56 | UpdateFindBuffer(); 57 | } 58 | } 59 | /// 60 | /// Contains the text that should be found. 61 | /// 62 | string _text; 63 | /// 64 | /// Gets or sets the text that should be found. Only used, when Type is FindType.Hex. 65 | /// 66 | public string Text 67 | { 68 | get { return _text; } 69 | set 70 | { 71 | _text = value; 72 | UpdateFindBuffer(); 73 | } 74 | } 75 | /// 76 | /// Gets or sets the hex buffer that should be found. Only used, when Type is FindType.Hex. 77 | /// 78 | public byte[] Hex { get; set; } 79 | /// 80 | /// Gets or sets the type what should be searched. 81 | /// 82 | public FindType Type { get; set; } 83 | /// 84 | /// Updates the find buffer. 85 | /// 86 | void UpdateFindBuffer() 87 | { 88 | string text = this.Text != null ? this.Text : string.Empty; 89 | FindBuffer = ASCIIEncoding.ASCII.GetBytes(text); 90 | FindBufferLowerCase = ASCIIEncoding.ASCII.GetBytes(text.ToLower()); 91 | FindBufferUpperCase = ASCIIEncoding.ASCII.GetBytes(text.ToUpper()); 92 | } 93 | } 94 | } 95 | -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/HexBox.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/Be.Windows.Forms.HexBox/HexBox.bmp -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/HexBox.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/Be.Windows.Forms.HexBox/HexBox.cs -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/HexBox.snk: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/Be.Windows.Forms.HexBox/HexBox.snk -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/HexCasing.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Be.Windows.Forms 6 | { 7 | /// 8 | /// Specifies the case of hex characters in the HexBox control 9 | /// 10 | public enum HexCasing 11 | { 12 | /// 13 | /// Converts all characters to uppercase. 14 | /// 15 | Upper = 0, 16 | /// 17 | /// Converts all characters to lowercase. 18 | /// 19 | Lower = 1 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/IByteProvider.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/Be.Windows.Forms.HexBox/IByteProvider.cs -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/MemoryDataBlock.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Be.Windows.Forms 4 | { 5 | internal sealed class MemoryDataBlock : DataBlock 6 | { 7 | byte[] _data; 8 | 9 | public MemoryDataBlock(byte data) 10 | { 11 | _data = new byte[] { data }; 12 | } 13 | 14 | public MemoryDataBlock(byte[] data) 15 | { 16 | if (data == null) 17 | { 18 | throw new ArgumentNullException("data"); 19 | } 20 | 21 | _data = (byte[])data.Clone(); 22 | } 23 | 24 | public override long Length 25 | { 26 | get 27 | { 28 | return _data.LongLength; 29 | } 30 | } 31 | 32 | public byte[] Data 33 | { 34 | get 35 | { 36 | return _data; 37 | } 38 | } 39 | 40 | public void AddByteToEnd(byte value) 41 | { 42 | byte[] newData = new byte[_data.LongLength + 1]; 43 | _data.CopyTo(newData, 0); 44 | newData[newData.LongLength - 1] = value; 45 | _data = newData; 46 | } 47 | 48 | public void AddByteToStart(byte value) 49 | { 50 | byte[] newData = new byte[_data.LongLength + 1]; 51 | newData[0] = value; 52 | _data.CopyTo(newData, 1); 53 | _data = newData; 54 | } 55 | 56 | public void InsertBytes(long position, byte[] data) 57 | { 58 | byte[] newData = new byte[_data.LongLength + data.LongLength]; 59 | if (position > 0) 60 | { 61 | Array.Copy(_data, 0, newData, 0, position); 62 | } 63 | Array.Copy(data, 0, newData, position, data.LongLength); 64 | if (position < _data.LongLength) 65 | { 66 | Array.Copy(_data, position, newData, position + data.LongLength, _data.LongLength - position); 67 | } 68 | _data = newData; 69 | } 70 | 71 | public override void RemoveBytes(long position, long count) 72 | { 73 | byte[] newData = new byte[_data.LongLength - count]; 74 | 75 | if (position > 0) 76 | { 77 | Array.Copy(_data, 0, newData, 0, position); 78 | } 79 | if (position + count < _data.LongLength) 80 | { 81 | Array.Copy(_data, position + count, newData, position, newData.LongLength - position); 82 | } 83 | 84 | _data = newData; 85 | } 86 | } 87 | } 88 | -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/NativeMethods.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Drawing; 3 | using System.Runtime.InteropServices; 4 | 5 | namespace Be.Windows.Forms 6 | { 7 | internal static class NativeMethods 8 | { 9 | // Caret definitions 10 | [DllImport("user32.dll", SetLastError=true)] 11 | public static extern bool CreateCaret(IntPtr hWnd, IntPtr hBitmap, int nWidth, int nHeight); 12 | 13 | [DllImport("user32.dll", SetLastError=true)] 14 | public static extern bool ShowCaret(IntPtr hWnd); 15 | 16 | [DllImport("user32.dll", SetLastError=true)] 17 | public static extern bool DestroyCaret(); 18 | 19 | [DllImport("user32.dll", SetLastError=true)] 20 | public static extern bool SetCaretPos(int X, int Y); 21 | 22 | // Key definitions 23 | public const int WM_KEYDOWN = 0x100; 24 | public const int WM_KEYUP = 0x101; 25 | public const int WM_CHAR = 0x102; 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/Properties/Resources.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:4.0.30319.1 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace Be.Windows.Forms.Properties { 12 | using System; 13 | 14 | 15 | /// 16 | /// A strongly-typed resource class, for looking up localized strings, etc. 17 | /// 18 | // This class was auto-generated by the StronglyTypedResourceBuilder 19 | // class via a tool like ResGen or Visual Studio. 20 | // To add or remove a member, edit your .ResX file then rerun ResGen 21 | // with the /str option, or rebuild your VS project. 22 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")] 23 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 24 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 25 | internal class Resources { 26 | 27 | private static global::System.Resources.ResourceManager resourceMan; 28 | 29 | private static global::System.Globalization.CultureInfo resourceCulture; 30 | 31 | [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] 32 | internal Resources() { 33 | } 34 | 35 | /// 36 | /// Returns the cached ResourceManager instance used by this class. 37 | /// 38 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 39 | internal static global::System.Resources.ResourceManager ResourceManager { 40 | get { 41 | if (object.ReferenceEquals(resourceMan, null)) { 42 | global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Be.Windows.Forms.Properties.Resources", typeof(Resources).Assembly); 43 | resourceMan = temp; 44 | } 45 | return resourceMan; 46 | } 47 | } 48 | 49 | /// 50 | /// Overrides the current thread's CurrentUICulture property for all 51 | /// resource lookups using this strongly typed resource class. 52 | /// 53 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 54 | internal static global::System.Globalization.CultureInfo Culture { 55 | get { 56 | return resourceCulture; 57 | } 58 | set { 59 | resourceCulture = value; 60 | } 61 | } 62 | } 63 | } 64 | -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/Properties/Resources.resx: -------------------------------------------------------------------------------- 1 |  2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | text/microsoft-resx 110 | 111 | 112 | 2.0 113 | 114 | 115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | 118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 119 | 120 | -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/Util.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Be.Windows.Forms 6 | { 7 | static class Util 8 | { 9 | /// 10 | /// Contains true, if we are in design mode of Visual Studio 11 | /// 12 | private static bool _designMode; 13 | 14 | /// 15 | /// Initializes an instance of Util class 16 | /// 17 | static Util() 18 | { 19 | _designMode = (System.Diagnostics.Process.GetCurrentProcess().ProcessName.ToLower() == "devenv"); 20 | } 21 | 22 | /// 23 | /// Gets true, if we are in design mode of Visual Studio 24 | /// 25 | /// 26 | /// In Visual Studio 2008 SP1 the designer is crashing sometimes on windows forms. 27 | /// The DesignMode property of Control class is buggy and cannot be used, so use our own implementation instead. 28 | /// 29 | public static bool DesignMode 30 | { 31 | get 32 | { 33 | return _designMode; 34 | } 35 | } 36 | 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/bin/Debug/Be.Windows.Forms.HexBox.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/Be.Windows.Forms.HexBox/bin/Debug/Be.Windows.Forms.HexBox.dll -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/obj/Debug/Be.Windows.Forms.HexBox.csproj.GenerateResource.Cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/Be.Windows.Forms.HexBox/obj/Debug/Be.Windows.Forms.HexBox.csproj.GenerateResource.Cache -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/obj/Debug/Be.Windows.Forms.HexBox.csprojResolveAssemblyReference.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/Be.Windows.Forms.HexBox/obj/Debug/Be.Windows.Forms.HexBox.csprojResolveAssemblyReference.cache -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/obj/Debug/Be.Windows.Forms.HexBox.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/Be.Windows.Forms.HexBox/obj/Debug/Be.Windows.Forms.HexBox.dll -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/obj/Debug/Be.Windows.Forms.HexBox.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/Be.Windows.Forms.HexBox/obj/Debug/Be.Windows.Forms.HexBox.resources -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/obj/Debug/Be.Windows.Forms.Properties.Resources.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/Be.Windows.Forms.HexBox/obj/Debug/Be.Windows.Forms.Properties.Resources.resources -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/obj/Debug/DesignTimeResolveAssemblyReferences.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/Be.Windows.Forms.HexBox/obj/Debug/DesignTimeResolveAssemblyReferences.cache -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/Be.Windows.Forms.HexBox/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache -------------------------------------------------------------------------------- /Be.Windows.Forms.HexBox/obj/Debug/TempPE/Properties.Resources.Designer.cs.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/Be.Windows.Forms.HexBox/obj/Debug/TempPE/Properties.Resources.Designer.cs.dll -------------------------------------------------------------------------------- /DAILibWV/DAILibWV.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | Debug 6 | AnyCPU 7 | {FDF25B35-6AA2-4A5B-B33C-37A215163F6C} 8 | Library 9 | Properties 10 | DAILibWV 11 | DAILibWV 12 | v4.5 13 | 512 14 | 15 | 16 | true 17 | full 18 | false 19 | bin\Debug\ 20 | DEBUG;TRACE 21 | prompt 22 | 4 23 | 24 | 25 | pdbonly 26 | true 27 | bin\Release\ 28 | TRACE 29 | prompt 30 | 4 31 | 32 | 33 | 34 | ref\ICSharpCode.SharpZipLib.dll 35 | 36 | 37 | 38 | 39 | ref\System.Data.SQLite.dll 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 78 | -------------------------------------------------------------------------------- /DAILibWV/Debug.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using System.Windows.Forms; 7 | 8 | namespace DAILibWV 9 | { 10 | public static class Debug 11 | { 12 | [System.Runtime.InteropServices.DllImport("user32.dll")] 13 | public static extern bool LockWindowUpdate(IntPtr hWndLock); 14 | 15 | private static readonly object _sync = new object(); 16 | 17 | public static RichTextBox box = null; 18 | 19 | public static void SetBox(RichTextBox rtb) 20 | { 21 | box = rtb; 22 | } 23 | 24 | public static void Log(string s, bool update = true) 25 | { 26 | lock (_sync) 27 | { 28 | if (box == null) 29 | return; 30 | LockWindowUpdate(box.Parent.Handle); 31 | box.AppendText(s); 32 | if (update) 33 | { 34 | LockWindowUpdate(IntPtr.Zero); 35 | Application.DoEvents(); 36 | } 37 | } 38 | } 39 | 40 | public static void LogLn(string s, bool update = true) 41 | { 42 | Log(s + "\n", update); 43 | } 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /DAILibWV/Frostbite/CASFile.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Collections.Generic; 4 | using System.Security.Cryptography; 5 | using System.Linq; 6 | using System.Text; 7 | using System.Threading.Tasks; 8 | 9 | namespace DAILibWV.Frostbite 10 | { 11 | public class CASFile 12 | { 13 | public string MyPath; 14 | public int casnumber; 15 | public struct CASEntry 16 | { 17 | public uint magic; 18 | public byte[] SHA1; 19 | public uint datasize; 20 | public uint padding; 21 | public uint ucsize; 22 | public uint csize; 23 | public uint unk1; 24 | public uint unk2; 25 | public byte[] data; 26 | } 27 | public CATFile cat; 28 | public List Indexes; 29 | 30 | #region Static methods 31 | 32 | public static string GetCASFileName(uint casnumber) 33 | { 34 | return string.Format("cas_{0:d2}.cas", casnumber); 35 | } 36 | 37 | public static string GetCASFileName(string basepath, uint casnumber) 38 | { 39 | return string.Format("{0}cas_{1:d2}.cas", basepath, casnumber); 40 | } 41 | 42 | #endregion 43 | 44 | public CASFile(string path) 45 | { 46 | MyPath = path; 47 | string s = Path.GetFileNameWithoutExtension(MyPath); 48 | s = s.Substring(s.Length - 2, 2); 49 | casnumber = int.Parse(s); 50 | } 51 | 52 | public void SetCAT(CATFile Cat) 53 | { 54 | cat = Cat; 55 | Indexes = GetIndexes(cat); 56 | } 57 | 58 | public CASEntry ReadEntry(uint[] line, int maxsize = 0x7FFFFFFF) 59 | { 60 | return ReadEntry(line[5], line[6], maxsize); 61 | } 62 | 63 | public CASEntry ReadEntry(int index, int maxsize = 0x7FFFFFFF) 64 | { 65 | uint[] line = cat.lines[Indexes[index]]; 66 | return ReadEntry(line[5], line[6], maxsize); 67 | } 68 | 69 | public CASEntry ReadEntry(uint offset, uint size_, int maxsize) 70 | { 71 | CASEntry result = new CASEntry(); 72 | MemoryStream s = new MemoryStream(ReadBlock(offset - 0x20, size_ + 0x20)); 73 | result.magic = Helpers.ReadUInt(s); 74 | result.SHA1 = new byte[20]; 75 | s.Read(result.SHA1, 0, 20); 76 | result.datasize = Helpers.ReadUInt(s); 77 | result.padding = Helpers.ReadUInt(s); 78 | long totalread = 0; 79 | MemoryStream res = new MemoryStream(); 80 | while (totalread < result.datasize && totalread < maxsize && totalread < size_) 81 | { 82 | int ucsize = Helpers.ReadLEInt(s); 83 | int csize = Helpers.ReadLEInt(s); 84 | totalread += 8; 85 | int size = csize & 0xFFFF; 86 | int type = (int)(csize >> 16); 87 | if (type == 0x270) 88 | { 89 | byte[] buff = new byte[size]; 90 | s.Read(buff, 0, size); 91 | byte[] r = Helpers.DecompressZlib(buff, ucsize); 92 | res.Write(r, 0, r.Length); 93 | totalread += size; 94 | } 95 | else 96 | { 97 | byte[] buff = new byte[size]; 98 | s.Read(buff, 0, size); 99 | res.Write(buff, 0, size); 100 | totalread += size; 101 | } 102 | } 103 | result.data = res.ToArray(); 104 | return result; 105 | } 106 | 107 | public byte[] ReadBlock(uint offset, uint size) 108 | { 109 | FileStream fs = new FileStream(MyPath, FileMode.Open, FileAccess.Read); 110 | fs.Seek(offset, 0); 111 | byte[] buff = Helpers.ReadFull(fs, size); 112 | fs.Close(); 113 | return buff; 114 | } 115 | 116 | public List GetIndexes(CATFile cat) 117 | { 118 | List result = new List(); 119 | for (int i = 0; i < cat.lines.Count; i++) 120 | if (cat.lines[i][7] == casnumber) 121 | result.Add(i); 122 | return result; 123 | } 124 | 125 | public static byte[] MakeHeaderAndContainer(byte[] data) 126 | { 127 | MemoryStream m = new MemoryStream(); 128 | int pos = 0; 129 | while (pos < data.Length) 130 | { 131 | if (data.Length - pos > 0xFFFF) 132 | { 133 | Helpers.WriteLEInt(m, 0xFFFF); 134 | m.WriteByte(0); 135 | m.WriteByte(0x70); 136 | m.WriteByte(0xFF); 137 | m.WriteByte(0xFF); 138 | m.Write(data, pos, 0xFFFF); 139 | pos += 0xFFFF; 140 | } 141 | else 142 | { 143 | int rest = data.Length - pos; 144 | Helpers.WriteLEInt(m, rest); 145 | m.WriteByte(0); 146 | m.WriteByte(0x70); 147 | m.WriteByte((byte)(rest >> 8)); 148 | m.WriteByte((byte)(rest & 0xFF)); 149 | m.Write(data, pos, rest); 150 | pos += rest; 151 | } 152 | } 153 | MemoryStream result = new MemoryStream(); 154 | Helpers.WriteUInt(result, 0xF00FCEFA); 155 | SHA1CryptoServiceProvider sha1 = new SHA1CryptoServiceProvider(); 156 | byte[] Sha1= sha1.ComputeHash(m.ToArray()); 157 | result.Write(Sha1, 0, 0x14); 158 | Helpers.WriteInt(result, (int)m.Length); 159 | Helpers.WriteUInt(result, 0); 160 | result.Write(m.ToArray(),0,(int)m.Length); 161 | return result.ToArray(); 162 | } 163 | } 164 | } 165 | -------------------------------------------------------------------------------- /DAILibWV/Frostbite/CATFile.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Collections.Generic; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Threading.Tasks; 7 | 8 | namespace DAILibWV.Frostbite 9 | { 10 | public class CATFile 11 | { 12 | public string MyPath; 13 | public int Level; 14 | public uint div; 15 | public List lines; 16 | public List> fastlookup; 17 | 18 | public CATFile(string path, int level = 256) //use only 2^x as level, like 2,4,8,16,32 19 | { 20 | MyPath = path; 21 | Level = level; 22 | div = (uint)(0x100000000 / Level); 23 | ReadFile(); 24 | } 25 | 26 | private void ReadFile() 27 | { 28 | FileStream fs = new FileStream(MyPath, FileMode.Open, FileAccess.Read); 29 | for (int i = 0; i < 4; i++) 30 | if (Helpers.ReadUInt(fs) != 0x6E61794E) 31 | return; 32 | lines = new List(); 33 | fastlookup = new List>(); 34 | for (int i = 0; i < Level; i++) 35 | fastlookup.Add(new List()); 36 | while (fs.Position < fs.Length) 37 | { 38 | uint[] line = new uint[9]; 39 | line[8] = (uint)fs.Position; 40 | for (int i = 0; i < 8; i++) 41 | if (i < 5) 42 | line[i] = Helpers.ReadLEUInt(fs); 43 | else 44 | line[i] = Helpers.ReadUInt(fs); 45 | 46 | int dic = (int)(line[0] / div); 47 | List t = fastlookup[dic]; 48 | t.Add(line); 49 | fastlookup[dic] = t; 50 | lines.Add(line); 51 | } 52 | fs.Close(); 53 | } 54 | 55 | public List FindBySHA1(byte[] sha1) 56 | { 57 | MemoryStream m = new MemoryStream(sha1); 58 | List res = new List(); 59 | uint[] sha1ints = new uint[5]; 60 | for (int i = 0; i < 5; i++) 61 | sha1ints[i] = Helpers.ReadLEUInt(m); 62 | int dic = (int)(sha1ints[0] / div); 63 | for (int i = 0; i < fastlookup[dic].Count; i++) 64 | if (fastlookup[dic][i][0] == sha1ints[0] && 65 | fastlookup[dic][i][1] == sha1ints[1] && 66 | fastlookup[dic][i][2] == sha1ints[2] && 67 | fastlookup[dic][i][3] == sha1ints[3] && 68 | fastlookup[dic][i][4] == sha1ints[4]) 69 | { 70 | res.AddRange(fastlookup[dic][i]); 71 | break; 72 | } 73 | return res; 74 | } 75 | } 76 | } 77 | -------------------------------------------------------------------------------- /DAILibWV/Frostbite/SBFile.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Collections.Generic; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Threading.Tasks; 7 | 8 | namespace DAILibWV.Frostbite 9 | { 10 | public class SBFile 11 | { 12 | public string MyPath; 13 | public List lines; 14 | public List bundles; 15 | 16 | public SBFile(string path) 17 | { 18 | MyPath = path; 19 | ReadFile(); 20 | ProcessFile(); 21 | } 22 | 23 | public void Save() 24 | { 25 | Save(MyPath); 26 | } 27 | 28 | public void Save(string path) 29 | { 30 | FileStream fs = new FileStream(path, FileMode.Create, FileAccess.Write); 31 | foreach (BJSON.Entry e in lines) 32 | BJSON.WriteEntry(fs, e); 33 | fs.Close(); 34 | } 35 | 36 | 37 | 38 | private void ReadFile() 39 | { 40 | FileStream fs = new FileStream(MyPath, FileMode.Open, FileAccess.Read); 41 | lines = new List(); 42 | BJSON.ReadEntries(fs, lines); 43 | fs.Close(); 44 | } 45 | 46 | public void ProcessFile() 47 | { 48 | bundles = new List(); 49 | foreach (BJSON.Entry e in lines) 50 | if (e.type == 0x82) 51 | foreach (BJSON.Field f in e.fields) 52 | if (f.fieldname == "bundles") 53 | foreach (BJSON.Entry b in (List)f.data) 54 | bundles.Add(Bundle.Create(b)); 55 | } 56 | } 57 | } 58 | -------------------------------------------------------------------------------- /DAILibWV/Frostbite/TextureMetaResource.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Collections.Generic; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Threading.Tasks; 7 | 8 | namespace DAILibWV.Frostbite 9 | { 10 | public class TextureMetaResource 11 | { 12 | public struct DDSPixelFormat 13 | { 14 | public int dwSize; 15 | public int dwFlags; 16 | public int dwFourCC; 17 | public int dwRGBBitCount; 18 | public uint dwRBitMask; 19 | public uint dwGBitMask; 20 | public uint dwBBitMask; 21 | public uint dwABitMask; 22 | public uint caps2; 23 | } 24 | 25 | public byte[] data; 26 | public int formatID; 27 | public ushort width; 28 | public ushort height; 29 | public int mipCount; 30 | public List mipDataSizes; 31 | public byte[] chunkid; 32 | public DDSPixelFormat ddsPF; 33 | 34 | public TextureMetaResource(byte[] buff) 35 | { 36 | data = buff; 37 | ReadData(); 38 | } 39 | 40 | private void ReadData() 41 | { 42 | MemoryStream m = new MemoryStream(data); 43 | m.Seek(12, 0); 44 | formatID = Helpers.ReadInt(m); 45 | m.Seek(2, SeekOrigin.Current); 46 | width = Helpers.ReadUShort(m); 47 | height = Helpers.ReadUShort(m); 48 | m.Seek(4, SeekOrigin.Current); 49 | mipCount = m.ReadByte(); 50 | m.Seek(1, SeekOrigin.Current); 51 | chunkid = new byte[16]; 52 | m.Read(chunkid, 0, 16); 53 | mipDataSizes = new List(); 54 | for (int i = 0; i < Math.Min(mipCount, 14); i++) 55 | mipDataSizes.Add(Helpers.ReadInt(m)); 56 | SetPixelFormatData(formatID); 57 | } 58 | 59 | public static Dictionary PixelFormatTypes = new Dictionary() 60 | { 61 | { 0x00, 0x31545844 }, 62 | { 0x01, 0x31545844 }, 63 | { 0x03, 0x35545844 }, 64 | { 0x04, 0x31495441 }, 65 | { 0x10, 0x74 }, 66 | { 0x13, 0x32495441 }, 67 | { 0x14, 0x53354342 }, 68 | }; 69 | 70 | private void SetPixelFormatData(int pixelFormatID) 71 | { 72 | ddsPF = new DDSPixelFormat(); 73 | ddsPF.caps2 = 0; 74 | ddsPF.dwSize = 32; 75 | ddsPF.dwFlags = 4; 76 | ddsPF.dwFourCC = 0x31545844; 77 | ddsPF.dwRGBBitCount = 0; 78 | ddsPF.dwRBitMask = 0; 79 | ddsPF.dwGBitMask = 0; 80 | ddsPF.dwBBitMask = 0; 81 | ddsPF.dwABitMask = 0; 82 | if (PixelFormatTypes.ContainsKey(pixelFormatID)) 83 | { 84 | ddsPF.dwFourCC = PixelFormatTypes[pixelFormatID]; 85 | if (pixelFormatID == 0x01) 86 | ddsPF.dwFlags |= 0x01; 87 | } 88 | else 89 | { 90 | switch (pixelFormatID) 91 | { 92 | case 0x0B: 93 | case 0x36: 94 | ddsPF.dwFourCC = 0x00; 95 | ddsPF.dwRGBBitCount = 0x20; 96 | ddsPF.dwRBitMask = 0xFF; 97 | ddsPF.dwGBitMask = 0xFF00; 98 | ddsPF.dwBBitMask = 0xFF0000; 99 | ddsPF.dwABitMask = 0xFF000000; 100 | ddsPF.dwFlags = 0x41; 101 | if (pixelFormatID == 0x36) 102 | ddsPF.caps2 = 0xFE00; 103 | break; 104 | case 0x0C: 105 | ddsPF.dwFourCC = 0x00; 106 | ddsPF.dwRGBBitCount = 0x08; 107 | ddsPF.dwABitMask = 0xFF; 108 | ddsPF.dwFlags = 0x02; 109 | break; 110 | case 0x0D: 111 | ddsPF.dwFourCC = 0x00; 112 | ddsPF.dwRGBBitCount = 0x10; 113 | ddsPF.dwRBitMask = 0xFFFF; 114 | ddsPF.dwFlags = 0x20000; 115 | break; 116 | } 117 | } 118 | } 119 | 120 | public void WriteTextureHeader(Stream s) 121 | { 122 | Helpers.WriteInt(s, 0x20534444); 123 | Helpers.WriteInt(s, 124); 124 | Helpers.WriteInt(s, 0x000A1007); 125 | Helpers.WriteInt(s, height); 126 | Helpers.WriteInt(s, width); 127 | Helpers.WriteInt(s, mipDataSizes[0]); 128 | Helpers.WriteInt(s, 0); 129 | Helpers.WriteInt(s, mipCount); 130 | for (int i = 0; i < 11; i++) 131 | Helpers.WriteInt(s, 0); 132 | Helpers.WriteInt(s, ddsPF.dwSize); 133 | Helpers.WriteInt(s, ddsPF.dwFlags); 134 | Helpers.WriteInt(s, ddsPF.dwFourCC); 135 | Helpers.WriteInt(s, ddsPF.dwRGBBitCount); 136 | Helpers.WriteInt(s, (int)ddsPF.dwRBitMask); 137 | Helpers.WriteInt(s, (int)ddsPF.dwGBitMask); 138 | Helpers.WriteInt(s, (int)ddsPF.dwBBitMask); 139 | Helpers.WriteInt(s, (int)ddsPF.dwABitMask); 140 | Helpers.WriteInt(s,0); 141 | Helpers.WriteInt(s, (int)ddsPF.caps2); 142 | Helpers.WriteInt(s, 0); 143 | Helpers.WriteInt(s, 0); 144 | Helpers.WriteInt(s, 0); 145 | } 146 | } 147 | } 148 | -------------------------------------------------------------------------------- /DAILibWV/GlobalStuff.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace DAILibWV 8 | { 9 | public static class GlobalStuff 10 | { 11 | public static Dictionary settings; 12 | 13 | public static string FindSetting(string name) 14 | { 15 | foreach (KeyValuePair setting in settings) 16 | if (setting.Key == name) 17 | return setting.Value; 18 | return ""; 19 | } 20 | 21 | public static void AssignSetting(string key, string value) 22 | { 23 | settings[key] = value; 24 | DBAccess.SaveSettings(); 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /DAILibWV/HalfUtil.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Runtime.InteropServices; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Threading.Tasks; 7 | 8 | namespace DAILibWV 9 | { 10 | public static class HalfUtils 11 | { 12 | private static readonly ushort[] FloatToHalfBaseTable; 13 | private static readonly byte[] FloatToHalfShiftTable; 14 | private static readonly int[] HalfToFloatExponentTable; 15 | private static readonly uint[] HalfToFloatMantissaTable; 16 | private static readonly uint[] HalfToFloatOffsetTable; 17 | 18 | static HalfUtils() 19 | { 20 | int num; 21 | HalfToFloatMantissaTable = new uint[0x800]; 22 | HalfToFloatExponentTable = new int[0x40]; 23 | HalfToFloatOffsetTable = new uint[0x40]; 24 | FloatToHalfBaseTable = new ushort[0x200]; 25 | FloatToHalfShiftTable = new byte[0x200]; 26 | HalfToFloatMantissaTable[0] = 0; 27 | for (num = 1; num < 0x400; num++) 28 | { 29 | uint num2 = (uint)(num << 13); 30 | uint num3 = 0; 31 | while ((num2 & 0x800000) == 0) 32 | { 33 | num3 -= 0x800000; 34 | num2 = num2 << 1; 35 | } 36 | num2 &= 0xff7fffff; 37 | num3 += 0x38800000; 38 | HalfToFloatMantissaTable[num] = num2 | num3; 39 | } 40 | for (num = 0x400; num < 0x800; num++) 41 | { 42 | HalfToFloatMantissaTable[num] = (uint)(0x38000000 + ((num - 0x400) << 13)); 43 | } 44 | HalfToFloatExponentTable[0] = 0; 45 | for (num = 1; num < 0x3f; num++) 46 | { 47 | if (num >= 0x1f) 48 | { 49 | HalfToFloatExponentTable[num] = -2147483648 + ((num - 0x20) << 0x17); 50 | } 51 | else 52 | { 53 | HalfToFloatExponentTable[num] = num << 0x17; 54 | } 55 | } 56 | HalfToFloatExponentTable[0x1f] = 0x47800000; 57 | HalfToFloatExponentTable[0x20] = -2147483648; 58 | HalfToFloatExponentTable[0x3f] = -947912704; 59 | HalfToFloatOffsetTable[0] = 0; 60 | for (num = 1; num < 0x40; num++) 61 | { 62 | HalfToFloatOffsetTable[num] = 0x400; 63 | } 64 | HalfToFloatOffsetTable[0x20] = 0; 65 | for (num = 0; num < 0x100; num++) 66 | { 67 | int num4 = num - 0x7f; 68 | if (num4 < -24) 69 | { 70 | FloatToHalfBaseTable[num] = 0; 71 | FloatToHalfBaseTable[num | 0x100] = 0x8000; 72 | FloatToHalfShiftTable[num] = 0x18; 73 | FloatToHalfShiftTable[num | 0x100] = 0x18; 74 | } 75 | else if (num4 < -14) 76 | { 77 | FloatToHalfBaseTable[num] = (ushort)(((int)0x400) >> (-num4 - 14)); 78 | FloatToHalfBaseTable[num | 0x100] = (ushort)((((int)0x400) >> (-num4 - 14)) | 0x8000); 79 | FloatToHalfShiftTable[num] = Convert.ToByte((int)(-num4 - 1)); 80 | FloatToHalfShiftTable[num | 0x100] = Convert.ToByte((int)(-num4 - 1)); 81 | } 82 | else if (num4 <= 15) 83 | { 84 | FloatToHalfBaseTable[num] = (ushort)((num4 + 15) << 10); 85 | FloatToHalfBaseTable[num | 0x100] = (ushort)(((num4 + 15) << 10) | 0x8000); 86 | FloatToHalfShiftTable[num] = 13; 87 | FloatToHalfShiftTable[num | 0x100] = 13; 88 | } 89 | else if (num4 >= 0x80) 90 | { 91 | FloatToHalfBaseTable[num] = 0x7c00; 92 | FloatToHalfBaseTable[num | 0x100] = 0xfc00; 93 | FloatToHalfShiftTable[num] = 13; 94 | FloatToHalfShiftTable[num | 0x100] = 13; 95 | } 96 | else 97 | { 98 | FloatToHalfBaseTable[num] = 0x7c00; 99 | FloatToHalfBaseTable[num | 0x100] = 0xfc00; 100 | FloatToHalfShiftTable[num] = 0x18; 101 | FloatToHalfShiftTable[num | 0x100] = 0x18; 102 | } 103 | } 104 | } 105 | 106 | public static ushort Pack(float f) 107 | { 108 | FloatToUint num = new FloatToUint 109 | { 110 | floatValue = f 111 | }; 112 | return (ushort)(FloatToHalfBaseTable[((int)(num.uintValue >> 0x17)) & 0x1ff] + ((num.uintValue & 0x7fffff) >> (FloatToHalfShiftTable[((int)(num.uintValue >> 0x17)) & 0x1ff] & 0x1f))); 113 | } 114 | 115 | public static float Unpack(ushort h) 116 | { 117 | FloatToUint num = new FloatToUint 118 | { 119 | uintValue = HalfToFloatMantissaTable[((int)HalfToFloatOffsetTable[h >> 10]) + (h & 0x3ff)] + ((uint)HalfToFloatExponentTable[h >> 10]) 120 | }; 121 | return num.floatValue; 122 | } 123 | 124 | [StructLayout(LayoutKind.Explicit)] 125 | private struct FloatToUint 126 | { 127 | [FieldOffset(0)] 128 | public float floatValue; 129 | [FieldOffset(0)] 130 | public uint uintValue; 131 | } 132 | } 133 | } 134 | -------------------------------------------------------------------------------- /DAILibWV/OldSupport/DAIMODFile.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Collections.Generic; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Threading.Tasks; 7 | 8 | namespace DAILibWV.OldSupport 9 | { 10 | public class DAIMODFile 11 | { 12 | public string MyPath; 13 | public string XML; 14 | public string Script; 15 | public List Data; 16 | 17 | public DAIMODFile(string path) 18 | { 19 | MyPath = path; 20 | FileStream fs = new FileStream(path, FileMode.Open, FileAccess.Read); 21 | fs.Seek(0xC, 0); 22 | string name = Helpers.ReadNullString(fs); 23 | XML = Helpers.ReadNullString(fs); 24 | Script = Helpers.ReadNullString(fs); 25 | Data = new List(); 26 | int count = Helpers.ReadInt(fs); 27 | for (int i = 0; i < count; i++) 28 | { 29 | byte[] data = new byte[Helpers.ReadInt(fs)]; 30 | fs.Read(data, 0, data.Length); 31 | Data.Add(data); 32 | } 33 | fs.Close(); 34 | } 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /DAILibWV/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // Allgemeine Informationen über eine Assembly werden über die folgenden 6 | // Attribute gesteuert. Ändern Sie diese Attributwerte, um die Informationen zu ändern, 7 | // die mit einer Assembly verknüpft sind. 8 | [assembly: AssemblyTitle("DAILibWV")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("Microsoft")] 12 | [assembly: AssemblyProduct("DAILibWV")] 13 | [assembly: AssemblyCopyright("Copyright © Microsoft 2015")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Durch Festlegen von ComVisible auf "false" werden die Typen in dieser Assembly unsichtbar 18 | // für COM-Komponenten. Wenn Sie auf einen Typ in dieser Assembly von 19 | // COM zugreifen müssen, legen Sie das ComVisible-Attribut für diesen Typ auf "true" fest. 20 | [assembly: ComVisible(false)] 21 | 22 | // Die folgende GUID bestimmt die ID der Typbibliothek, wenn dieses Projekt für COM verfügbar gemacht wird 23 | [assembly: Guid("40c9c03c-7f43-4dac-9751-a465861095bf")] 24 | 25 | // Versionsinformationen für eine Assembly bestehen aus den folgenden vier Werten: 26 | // 27 | // Hauptversion 28 | // Nebenversion 29 | // Buildnummer 30 | // Revision 31 | // 32 | // Sie können alle Werte angeben oder die standardmäßigen Build- und Revisionsnummern 33 | // übernehmen, indem Sie "*" eingeben: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /DAILibWV/SHA1Access.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Collections.Generic; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Threading.Tasks; 7 | using DAILibWV.Frostbite; 8 | 9 | namespace DAILibWV 10 | { 11 | public static class SHA1Access 12 | { 13 | public static CATFile cat_base = null; 14 | public static CATFile cat_patch = null; 15 | public static CASFile cas; 16 | 17 | public static byte[] GetDataBySha1(byte[] sha1, int maxsize = 0x7FFFFFFF) 18 | { 19 | CATFile cat = null; 20 | if (cat_base == null) 21 | { 22 | string path = GlobalStuff.FindSetting("gamepath") + "Data\\cas.cat"; 23 | cat_base = new CATFile(path); 24 | } 25 | List casline = cat_base.FindBySHA1(sha1); 26 | if (casline.Count == 9) 27 | cat = cat_base; 28 | else 29 | { 30 | if (cat_patch == null) 31 | { 32 | string path = GlobalStuff.FindSetting("gamepath") + "Update\\Patch\\Data\\cas.cat"; 33 | cat_patch = new CATFile(path); 34 | } 35 | cat = cat_patch; 36 | casline = cat_patch.FindBySHA1(sha1); 37 | } 38 | if (casline.Count == 9) 39 | { 40 | if (cas == null || cas.casnumber != casline[7]) 41 | { 42 | string[] files = Directory.GetFiles(Path.GetDirectoryName(cat.MyPath)); 43 | foreach (string file in files) 44 | if (Path.GetFileName(file) == CASFile.GetCASFileName(casline[7])) 45 | { 46 | cas = new CASFile(file); 47 | break; 48 | } 49 | } 50 | if (cas != null && cas.casnumber == casline[7]) 51 | { 52 | CASFile.CASEntry ce = cas.ReadEntry(casline.ToArray(), maxsize); 53 | return ce.data; 54 | } 55 | } 56 | return new byte[0]; 57 | } 58 | } 59 | } 60 | -------------------------------------------------------------------------------- /DAILibWV/bin/Debug/DAILibWV.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAILibWV/bin/Debug/DAILibWV.dll -------------------------------------------------------------------------------- /DAILibWV/bin/Debug/ICSharpCode.SharpZipLib.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAILibWV/bin/Debug/ICSharpCode.SharpZipLib.dll -------------------------------------------------------------------------------- /DAILibWV/bin/Debug/System.Data.SQLite.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAILibWV/bin/Debug/System.Data.SQLite.dll -------------------------------------------------------------------------------- /DAILibWV/obj/Debug/DAILibWV.csproj.FileListAbsolute.txt: -------------------------------------------------------------------------------- 1 | D:\CODE\c#\DAIToolsWV\DAILibWV\bin\Debug\DAILibWV.dll 2 | D:\CODE\c#\DAIToolsWV\DAILibWV\bin\Debug\DAILibWV.pdb 3 | D:\CODE\c#\DAIToolsWV\DAILibWV\bin\Debug\ICSharpCode.SharpZipLib.dll 4 | D:\CODE\c#\DAIToolsWV\DAILibWV\bin\Debug\System.Data.SQLite.dll 5 | D:\CODE\c#\DAIToolsWV\DAILibWV\bin\Debug\System.Data.SQLite.xml 6 | D:\CODE\c#\DAIToolsWV\DAILibWV\obj\Debug\DAILibWV.dll 7 | D:\CODE\c#\DAIToolsWV\DAILibWV\obj\Debug\DAILibWV.pdb 8 | D:\CODE\c#\DAIToolsWV\DAILibWV\obj\Debug\DAILibWV.csprojResolveAssemblyReference.cache 9 | D:\CODE\SVN\DAIToolsWV\DAILibWV\bin\Debug\DAILibWV.dll 10 | D:\CODE\SVN\DAIToolsWV\DAILibWV\bin\Debug\DAILibWV.pdb 11 | D:\CODE\SVN\DAIToolsWV\DAILibWV\bin\Debug\ICSharpCode.SharpZipLib.dll 12 | D:\CODE\SVN\DAIToolsWV\DAILibWV\bin\Debug\System.Data.SQLite.dll 13 | D:\CODE\SVN\DAIToolsWV\DAILibWV\bin\Debug\System.Data.SQLite.xml 14 | D:\CODE\SVN\DAIToolsWV\DAILibWV\obj\Debug\DAILibWV.dll 15 | D:\CODE\SVN\DAIToolsWV\DAILibWV\obj\Debug\DAILibWV.pdb 16 | D:\CODE\SVN\DAIToolsWV\DAILibWV\obj\Debug\DAILibWV.csprojResolveAssemblyReference.cache 17 | D:\CODE\GitHub\DAIToolsWV\DAILibWV\bin\Debug\DAILibWV.dll 18 | D:\CODE\GitHub\DAIToolsWV\DAILibWV\bin\Debug\DAILibWV.pdb 19 | D:\CODE\GitHub\DAIToolsWV\DAILibWV\bin\Debug\ICSharpCode.SharpZipLib.dll 20 | D:\CODE\GitHub\DAIToolsWV\DAILibWV\bin\Debug\System.Data.SQLite.dll 21 | D:\CODE\GitHub\DAIToolsWV\DAILibWV\bin\Debug\System.Data.SQLite.xml 22 | D:\CODE\GitHub\DAIToolsWV\DAILibWV\obj\Debug\DAILibWV.dll 23 | D:\CODE\GitHub\DAIToolsWV\DAILibWV\obj\Debug\DAILibWV.pdb 24 | C:\_CODE\Git\DAIToolsWV\DAILibWV\bin\Debug\DAILibWV.dll 25 | C:\_CODE\Git\DAIToolsWV\DAILibWV\bin\Debug\DAILibWV.pdb 26 | C:\_CODE\Git\DAIToolsWV\DAILibWV\bin\Debug\ICSharpCode.SharpZipLib.dll 27 | C:\_CODE\Git\DAIToolsWV\DAILibWV\bin\Debug\System.Data.SQLite.dll 28 | C:\_CODE\Git\DAIToolsWV\DAILibWV\bin\Debug\System.Data.SQLite.xml 29 | C:\_CODE\Git\DAIToolsWV\DAILibWV\obj\Debug\DAILibWV.csprojResolveAssemblyReference.cache 30 | C:\_CODE\Git\DAIToolsWV\DAILibWV\obj\Debug\DAILibWV.dll 31 | C:\_CODE\Git\DAIToolsWV\DAILibWV\obj\Debug\DAILibWV.pdb 32 | D:\CODE\GitHub\DAIToolsWV\DAILibWV\obj\Debug\DAILibWV.csprojResolveAssemblyReference.cache 33 | -------------------------------------------------------------------------------- /DAILibWV/obj/Debug/DAILibWV.csprojResolveAssemblyReference.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAILibWV/obj/Debug/DAILibWV.csprojResolveAssemblyReference.cache -------------------------------------------------------------------------------- /DAILibWV/obj/Debug/DAILibWV.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAILibWV/obj/Debug/DAILibWV.dll -------------------------------------------------------------------------------- /DAILibWV/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAILibWV/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache -------------------------------------------------------------------------------- /DAILibWV/obj/Debug/TemporaryGeneratedFile_036C0B5B-1481-4323-8D20-8F5ADCB23D92.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAILibWV/obj/Debug/TemporaryGeneratedFile_036C0B5B-1481-4323-8D20-8F5ADCB23D92.cs -------------------------------------------------------------------------------- /DAILibWV/obj/Debug/TemporaryGeneratedFile_5937a670-0e60-4077-877b-f7221da3dda1.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAILibWV/obj/Debug/TemporaryGeneratedFile_5937a670-0e60-4077-877b-f7221da3dda1.cs -------------------------------------------------------------------------------- /DAILibWV/obj/Debug/TemporaryGeneratedFile_E7A71F73-0F8D-4B9B-B56E-8E70B10BC5D3.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAILibWV/obj/Debug/TemporaryGeneratedFile_E7A71F73-0F8D-4B9B-B56E-8E70B10BC5D3.cs -------------------------------------------------------------------------------- /DAILibWV/ref/ICSharpCode.SharpZipLib.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAILibWV/ref/ICSharpCode.SharpZipLib.dll -------------------------------------------------------------------------------- /DAILibWV/ref/System.Data.SQLite.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAILibWV/ref/System.Data.SQLite.dll -------------------------------------------------------------------------------- /DAIToolsWV.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio Express 2012 for Windows Desktop 4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DAIToolsWV", "DAIToolsWV\DAIToolsWV.csproj", "{267210E7-BD7F-4FF6-9046-C61F943C5C03}" 5 | EndProject 6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DAILibWV", "DAILibWV\DAILibWV.csproj", "{FDF25B35-6AA2-4A5B-B33C-37A215163F6C}" 7 | EndProject 8 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Be.Windows.Forms.HexBox", "Be.Windows.Forms.HexBox\Be.Windows.Forms.HexBox.csproj", "{26C5F25F-B450-4CAF-AD8B-B8D11AE73457}" 9 | EndProject 10 | Global 11 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 12 | Debug|Any CPU = Debug|Any CPU 13 | Release|Any CPU = Release|Any CPU 14 | EndGlobalSection 15 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 16 | {267210E7-BD7F-4FF6-9046-C61F943C5C03}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 17 | {267210E7-BD7F-4FF6-9046-C61F943C5C03}.Debug|Any CPU.Build.0 = Debug|Any CPU 18 | {267210E7-BD7F-4FF6-9046-C61F943C5C03}.Release|Any CPU.ActiveCfg = Release|Any CPU 19 | {267210E7-BD7F-4FF6-9046-C61F943C5C03}.Release|Any CPU.Build.0 = Release|Any CPU 20 | {FDF25B35-6AA2-4A5B-B33C-37A215163F6C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 21 | {FDF25B35-6AA2-4A5B-B33C-37A215163F6C}.Debug|Any CPU.Build.0 = Debug|Any CPU 22 | {FDF25B35-6AA2-4A5B-B33C-37A215163F6C}.Release|Any CPU.ActiveCfg = Release|Any CPU 23 | {FDF25B35-6AA2-4A5B-B33C-37A215163F6C}.Release|Any CPU.Build.0 = Release|Any CPU 24 | {26C5F25F-B450-4CAF-AD8B-B8D11AE73457}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 25 | {26C5F25F-B450-4CAF-AD8B-B8D11AE73457}.Debug|Any CPU.Build.0 = Debug|Any CPU 26 | {26C5F25F-B450-4CAF-AD8B-B8D11AE73457}.Release|Any CPU.ActiveCfg = Release|Any CPU 27 | {26C5F25F-B450-4CAF-AD8B-B8D11AE73457}.Release|Any CPU.Build.0 = Release|Any CPU 28 | EndGlobalSection 29 | GlobalSection(SolutionProperties) = preSolution 30 | HideSolutionNode = FALSE 31 | EndGlobalSection 32 | EndGlobal 33 | -------------------------------------------------------------------------------- /DAIToolsWV.v11.suo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV.v11.suo -------------------------------------------------------------------------------- /DAIToolsWV/App.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /DAIToolsWV/ContentTools/EBXTool.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Drawing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Threading.Tasks; 10 | using System.Windows.Forms; 11 | using Be.Windows.Forms; 12 | using DAILibWV; 13 | using DAILibWV.Frostbite; 14 | 15 | namespace DAIToolsWV.ContentTools 16 | { 17 | public partial class EBXTool : Form 18 | { 19 | public byte[] ebxdata = null; 20 | public EBXStream ebx = null; 21 | 22 | public EBXTool() 23 | { 24 | InitializeComponent(); 25 | } 26 | 27 | public void LoadEbx(byte[] data) 28 | { 29 | ebxdata = data; 30 | ebx = new EBXStream(new MemoryStream(ebxdata), pb1); 31 | RefreshDisplay(); 32 | } 33 | 34 | private void loadFromBinaryToolStripMenuItem_Click(object sender, EventArgs e) 35 | { 36 | OpenFileDialog d = new OpenFileDialog(); 37 | d.Filter = "*.bin|*.bin"; 38 | if (d.ShowDialog() == System.Windows.Forms.DialogResult.OK) 39 | LoadEbx(File.ReadAllBytes(d.FileName)); 40 | } 41 | 42 | public void RefreshDisplay() 43 | { 44 | hb1.ByteProvider = new DynamicByteProvider(ebxdata); 45 | hb2.ByteProvider = new DynamicByteProvider(ebx.keywordarea); 46 | listBox1.Items.Clear(); 47 | int count = 0; 48 | foreach (EBXStream.StreamingPartitionImportEntry exguid in ebx.imports) 49 | listBox1.Items.Add((count++).ToString("X4") + " : " + exguid.partitionGuid.ToString() + " -> " + exguid.instanceGuid.ToString()); 50 | count = 0; 51 | listBox2.Items.Clear(); 52 | foreach (EBXStream.KeyWordDicStruct entry in ebx.keyWordDic) 53 | listBox2.Items.Add((count++).ToString("X4") + " : Offset = 0x" + entry.offset.ToString("X8") + " Hash = 0x" + entry.hash.ToString("X8") + " Keyword = '" + entry.keyword + "'"); 54 | count = 0; 55 | listBox3.Items.Clear(); 56 | foreach (EBXStream.StreamingPartitionFieldDescriptor f in ebx.fieldDescriptors) 57 | listBox3.Items.Add( 58 | (count++).ToString("X4") 59 | + " : Hash = 0x" 60 | + f.fieldNameHash.ToString("X8") 61 | + " Type = 0x" 62 | + f.flagBits.ToString("X4") 63 | + " Reference = 0x" 64 | + f.fieldTypeIndex.ToString("X4") 65 | + " Offset = 0x" 66 | + f.fieldOffset.ToString("X8") 67 | + " Secondary Offset = 0x" 68 | + f.secondaryOffset.ToString("X8") 69 | + " Name ='" 70 | + f._name + "'"); 71 | count = 0; 72 | listBox4.Items.Clear(); 73 | foreach (EBXStream.StreamingPartitionTypeDescriptor f in ebx.typeDescriptors) 74 | listBox4.Items.Add( 75 | (count++).ToString("X4") 76 | + " : Hash = 0x" 77 | + f.typeNameHash.ToString("X8") 78 | + " StartIndex = 0x" 79 | + f.layoutDescriptorIndex.ToString("X8") 80 | + " NumField = 0x" 81 | + f.fieldCount.ToString("X2") 82 | + " Alignment = 0x" 83 | + f.alignment.ToString("X2") 84 | + " Type = 0x" 85 | + f.typeFlags.ToString("X4") 86 | + " Size = 0x" 87 | + f.instanceSize.ToString("X4") 88 | + " Secondary Size = 0x" 89 | + f.secondaryInstanceSize.ToString("X8") 90 | + " Name ='" 91 | + f._name + "'"); 92 | count = 0; 93 | listBox5.Items.Clear(); 94 | foreach (EBXStream.StreamingPartitionTypeEntry i in ebx.typeList) 95 | listBox5.Items.Add((count++).ToString("X4") + " : Type Desc Index = 0x" + i.typeDescriptorIndex.ToString("X4") + " Repeats = 0x" + i.repetitions.ToString("X4")); 96 | count = 0; 97 | listBox6.Items.Clear(); 98 | foreach (EBXStream.StreamingPartitionArrayEntry a in ebx.arrayList) 99 | listBox6.Items.Add((count++).ToString("X4") + " : Offset = 0x" + a.offset.ToString("X8") + " Type Desc Index = 0x" + a.typeDescriptorIndex.ToString("X8") + " Repeats = 0x" + a.elementCount.ToString("X8")); 100 | treeView1.Nodes.Clear(); 101 | count = 0; 102 | TreeNode t = new TreeNode("Types"); 103 | if (ebx.typeEntryList != null) 104 | foreach (EBXStream.TypeEntryStruct typ in ebx.typeEntryList) 105 | t.Nodes.Add(EBXStream.TypeToNode(typ.type)); 106 | t.ExpandAll(); 107 | treeView1.Nodes.Add(t); 108 | rtb2.Text = ebx.toXML(); 109 | } 110 | } 111 | } 112 | -------------------------------------------------------------------------------- /DAIToolsWV/DAIToolsWV.csproj.user: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | veröffentlichen\ 5 | 6 | 7 | 8 | 9 | 10 | de-DE 11 | false 12 | 13 | -------------------------------------------------------------------------------- /DAIToolsWV/DebugOutputWindow.Designer.cs: -------------------------------------------------------------------------------- 1 | using System.Windows.Forms; 2 | using System.Drawing; 3 | namespace DAIToolsWV 4 | { 5 | public class TransparentLabel : RichTextBox 6 | { 7 | public TransparentLabel() 8 | { 9 | this.SetStyle(ControlStyles.Opaque, true); 10 | this.SetStyle(ControlStyles.OptimizedDoubleBuffer, false); 11 | this.TextChanged += TransparentLabel_TextChanged; 12 | this.VScroll += TransparentLabel_TextChanged; 13 | this.HScroll += TransparentLabel_TextChanged; 14 | } 15 | 16 | void TransparentLabel_TextChanged(object sender, System.EventArgs e) 17 | { 18 | this.ForceRefresh(); 19 | } 20 | protected override CreateParams CreateParams 21 | { 22 | get 23 | { 24 | CreateParams parms = base.CreateParams; 25 | parms.ExStyle |= 0x20; // Turn on WS_EX_TRANSPARENT 26 | return parms; 27 | } 28 | } 29 | public void ForceRefresh() 30 | { 31 | this.UpdateStyles(); 32 | } 33 | } 34 | 35 | partial class DebugOutputWindow 36 | { 37 | 38 | private const int CP_NOCLOSE_BUTTON = 0x200; 39 | protected override CreateParams CreateParams 40 | { 41 | get 42 | { 43 | CreateParams myCp = base.CreateParams; 44 | myCp.ClassStyle = myCp.ClassStyle | CP_NOCLOSE_BUTTON; 45 | return myCp; 46 | } 47 | } 48 | /// 49 | /// Required designer variable. 50 | /// 51 | private System.ComponentModel.IContainer components = null; 52 | 53 | /// 54 | /// Clean up any resources being used. 55 | /// 56 | /// true if managed resources should be disposed; otherwise, false. 57 | protected override void Dispose(bool disposing) 58 | { 59 | if (disposing && (components != null)) 60 | { 61 | components.Dispose(); 62 | } 63 | base.Dispose(disposing); 64 | } 65 | 66 | #region Windows Form Designer generated code 67 | 68 | /// 69 | /// Required method for Designer support - do not modify 70 | /// the contents of this method with the code editor. 71 | /// 72 | private void InitializeComponent() 73 | { 74 | System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(DebugOutputWindow)); 75 | this.rtb1 = new DAIToolsWV.TransparentLabel(); 76 | this.SuspendLayout(); 77 | this.SetStyle(ControlStyles.AllPaintingInWmPaint | ControlStyles.UserPaint | ControlStyles.DoubleBuffer | ControlStyles.SupportsTransparentBackColor, true); 78 | 79 | // 80 | // rtb1 81 | // 82 | this.rtb1.Dock = System.Windows.Forms.DockStyle.Fill; 83 | this.rtb1.Font = new System.Drawing.Font("Courier New", 10, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 84 | this.rtb1.Location = new System.Drawing.Point(0, 0); 85 | this.rtb1.Name = "rtb1"; 86 | this.rtb1.ScrollBars = System.Windows.Forms.RichTextBoxScrollBars.ForcedBoth; 87 | this.rtb1.Size = new System.Drawing.Size(292, 273); 88 | this.rtb1.TabIndex = 0; 89 | this.rtb1.Text = ""; 90 | this.rtb1.WordWrap = false; 91 | // 92 | // DebugOutputWindow 93 | // 94 | this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); 95 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 96 | this.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("$this.BackgroundImage"))); 97 | this.ClientSize = new System.Drawing.Size(292, 273); 98 | this.Controls.Add(this.rtb1); 99 | this.Name = "DebugOutputWindow"; 100 | this.ShowInTaskbar = false; 101 | this.Text = "Debug"; 102 | this.ResumeLayout(false); 103 | 104 | } 105 | 106 | #endregion 107 | 108 | public TransparentLabel rtb1; 109 | } 110 | } -------------------------------------------------------------------------------- /DAIToolsWV/DebugOutputWindow.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Data; 5 | using System.Drawing; 6 | using System.Linq; 7 | using System.Text; 8 | using System.Threading.Tasks; 9 | using System.Windows.Forms; 10 | 11 | namespace DAIToolsWV 12 | { 13 | public partial class DebugOutputWindow : Form 14 | { 15 | public DebugOutputWindow() 16 | { 17 | InitializeComponent(); 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /DAIToolsWV/FileTools/CASContainerCreator.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Drawing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Security.Cryptography; 10 | using System.Threading.Tasks; 11 | using System.Windows.Forms; 12 | using Be.Windows.Forms; 13 | using DAILibWV; 14 | 15 | namespace DAIToolsWV.FileTools 16 | { 17 | public partial class CASContainerCreator : Form 18 | { 19 | public byte[] SHA1; 20 | public byte[] data; 21 | public byte[] header; 22 | public byte[] container; 23 | 24 | public CASContainerCreator() 25 | { 26 | InitializeComponent(); 27 | } 28 | 29 | private void loadBinaryToolStripMenuItem_Click(object sender, EventArgs e) 30 | { 31 | OpenFileDialog d = new OpenFileDialog(); 32 | d.Filter = "*.bin|*.bin"; 33 | if (d.ShowDialog() == System.Windows.Forms.DialogResult.OK) 34 | { 35 | data = File.ReadAllBytes(d.FileName); 36 | ReFresh(); 37 | } 38 | } 39 | 40 | public void ReFresh() 41 | { 42 | hb1.ByteProvider = new DynamicByteProvider(data); 43 | 44 | MemoryStream m = new MemoryStream(); 45 | int pos = 0; 46 | while (pos < data.Length) 47 | { 48 | if (data.Length - pos > 0xFFFF) 49 | { 50 | Helpers.WriteLEInt(m, 0xFFFF); 51 | m.WriteByte(0); 52 | m.WriteByte(0x70); 53 | m.WriteByte(0xFF); 54 | m.WriteByte(0xFF); 55 | m.Write(data, pos, 0xFFFF); 56 | pos += 0xFFFF; 57 | } 58 | else 59 | { 60 | int rest = data.Length - pos; 61 | Helpers.WriteLEInt(m, rest); 62 | m.WriteByte(0); 63 | m.WriteByte(0x70); 64 | m.WriteByte((byte)(rest >> 8)); 65 | m.WriteByte((byte)(rest & 0xFF)); 66 | m.Write(data, pos, rest); 67 | pos += rest; 68 | } 69 | } 70 | container = m.ToArray(); 71 | hb3.ByteProvider = new DynamicByteProvider(container); 72 | 73 | m = new MemoryStream(); 74 | Helpers.WriteUInt(m, 0xF00FCEFA); 75 | SHA1CryptoServiceProvider sha1 = new SHA1CryptoServiceProvider(); 76 | SHA1 = sha1.ComputeHash(container); 77 | m.Write(SHA1, 0, 0x14); 78 | Helpers.WriteInt(m, container.Length); 79 | Helpers.WriteUInt(m, 0); 80 | header = m.ToArray(); 81 | hb2.ByteProvider = new DynamicByteProvider(header); 82 | } 83 | 84 | private void appendToCASToolStripMenuItem_Click(object sender, EventArgs e) 85 | { 86 | OpenFileDialog d = new OpenFileDialog(); 87 | d.Filter = "*.cas|*.cas"; 88 | if (d.ShowDialog() == System.Windows.Forms.DialogResult.OK) 89 | { 90 | FileStream fs = new FileStream(d.FileName, FileMode.Append, FileAccess.Write); 91 | fs.Seek(0, SeekOrigin.End); 92 | fs.Write(header, 0, 0x20); 93 | fs.Write(container, 0, container.Length); 94 | fs.Close(); 95 | MessageBox.Show("Done."); 96 | } 97 | } 98 | } 99 | } 100 | -------------------------------------------------------------------------------- /DAIToolsWV/FileTools/DAIMODSupportTool.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Drawing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Threading; 10 | using System.Threading.Tasks; 11 | using System.Windows.Forms; 12 | using DAILibWV.OldSupport; 13 | using Be.Windows.Forms; 14 | using DAILibWV; 15 | namespace DAIToolsWV.FileTools 16 | { 17 | public partial class DAIMODSupportTool : Form 18 | { 19 | public DAIMODFile mod; 20 | 21 | public DAIMODSupportTool() 22 | { 23 | InitializeComponent(); 24 | } 25 | 26 | private void openOldDAIMODToolStripMenuItem_Click(object sender, EventArgs e) 27 | { 28 | OpenFileDialog d = new OpenFileDialog(); 29 | d.Filter = "*.DAIMOD|*.DAIMOD"; 30 | if (d.ShowDialog() == System.Windows.Forms.DialogResult.OK) 31 | { 32 | mod = new DAIMODFile(d.FileName); 33 | RefreshPreview(); 34 | } 35 | } 36 | 37 | public void RefreshPreview() 38 | { 39 | rtb1.Text = mod.XML; 40 | rtb2.Text = mod.Script; 41 | listBox1.Items.Clear(); 42 | for (int i = 0; i < mod.Data.Count; i++) 43 | listBox1.Items.Add("Data[" + i + "] : Size 0x" + mod.Data[i].Length.ToString("X8")); 44 | } 45 | 46 | private void listBox1_SelectedIndexChanged(object sender, EventArgs e) 47 | { 48 | int n = listBox1.SelectedIndex; 49 | if (n == -1) 50 | return; 51 | hb1.ByteProvider = new DynamicByteProvider(mod.Data[n]); 52 | } 53 | 54 | private void toolStripButton1_Click(object sender, EventArgs e) 55 | { 56 | int n = listBox1.SelectedIndex; 57 | if (n == -1) 58 | return; 59 | SaveFileDialog d = new SaveFileDialog(); 60 | d.Filter = "*.bin|*.bin"; 61 | if (d.ShowDialog() == System.Windows.Forms.DialogResult.OK) 62 | { 63 | File.WriteAllBytes(d.FileName, mod.Data[n]); 64 | MessageBox.Show("Done."); 65 | } 66 | } 67 | } 68 | } 69 | -------------------------------------------------------------------------------- /DAIToolsWV/FileTools/HexTool.Designer.cs: -------------------------------------------------------------------------------- 1 | namespace DAIToolsWV.FileTools 2 | { 3 | partial class HexTool 4 | { 5 | /// 6 | /// Required designer variable. 7 | /// 8 | private System.ComponentModel.IContainer components = null; 9 | 10 | /// 11 | /// Clean up any resources being used. 12 | /// 13 | /// true if managed resources should be disposed; otherwise, false. 14 | protected override void Dispose(bool disposing) 15 | { 16 | if (disposing && (components != null)) 17 | { 18 | components.Dispose(); 19 | } 20 | base.Dispose(disposing); 21 | } 22 | 23 | #region Windows Form Designer generated code 24 | 25 | /// 26 | /// Required method for Designer support - do not modify 27 | /// the contents of this method with the code editor. 28 | /// 29 | private void InitializeComponent() 30 | { 31 | this.button1 = new System.Windows.Forms.Button(); 32 | this.button2 = new System.Windows.Forms.Button(); 33 | this.textBox1 = new System.Windows.Forms.TextBox(); 34 | this.textBox2 = new System.Windows.Forms.TextBox(); 35 | this.label1 = new System.Windows.Forms.Label(); 36 | this.label2 = new System.Windows.Forms.Label(); 37 | this.SuspendLayout(); 38 | // 39 | // button1 40 | // 41 | this.button1.Location = new System.Drawing.Point(197, 10); 42 | this.button1.Name = "button1"; 43 | this.button1.Size = new System.Drawing.Size(75, 23); 44 | this.button1.TabIndex = 0; 45 | this.button1.Text = "Convert"; 46 | this.button1.UseVisualStyleBackColor = true; 47 | this.button1.Click += new System.EventHandler(this.button1_Click); 48 | // 49 | // button2 50 | // 51 | this.button2.Location = new System.Drawing.Point(197, 51); 52 | this.button2.Name = "button2"; 53 | this.button2.Size = new System.Drawing.Size(75, 23); 54 | this.button2.TabIndex = 1; 55 | this.button2.Text = "Convert"; 56 | this.button2.UseVisualStyleBackColor = true; 57 | this.button2.Click += new System.EventHandler(this.button2_Click); 58 | // 59 | // textBox1 60 | // 61 | this.textBox1.Location = new System.Drawing.Point(90, 10); 62 | this.textBox1.Name = "textBox1"; 63 | this.textBox1.Size = new System.Drawing.Size(100, 20); 64 | this.textBox1.TabIndex = 2; 65 | // 66 | // textBox2 67 | // 68 | this.textBox2.Location = new System.Drawing.Point(90, 49); 69 | this.textBox2.Name = "textBox2"; 70 | this.textBox2.Size = new System.Drawing.Size(100, 20); 71 | this.textBox2.TabIndex = 3; 72 | // 73 | // label1 74 | // 75 | this.label1.AutoSize = true; 76 | this.label1.Location = new System.Drawing.Point(13, 10); 77 | this.label1.Name = "label1"; 78 | this.label1.Size = new System.Drawing.Size(71, 13); 79 | this.label1.TabIndex = 4; 80 | this.label1.Text = "7Bit Encoded"; 81 | // 82 | // label2 83 | // 84 | this.label2.AutoSize = true; 85 | this.label2.Location = new System.Drawing.Point(16, 51); 86 | this.label2.Name = "label2"; 87 | this.label2.Size = new System.Drawing.Size(40, 13); 88 | this.label2.TabIndex = 5; 89 | this.label2.Text = "Normal"; 90 | // 91 | // HexTool 92 | // 93 | this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); 94 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 95 | this.ClientSize = new System.Drawing.Size(292, 87); 96 | this.Controls.Add(this.label2); 97 | this.Controls.Add(this.label1); 98 | this.Controls.Add(this.textBox2); 99 | this.Controls.Add(this.textBox1); 100 | this.Controls.Add(this.button2); 101 | this.Controls.Add(this.button1); 102 | this.Name = "HexTool"; 103 | this.Text = "HexTool"; 104 | this.ResumeLayout(false); 105 | this.PerformLayout(); 106 | 107 | } 108 | 109 | #endregion 110 | 111 | private System.Windows.Forms.Button button1; 112 | private System.Windows.Forms.Button button2; 113 | private System.Windows.Forms.TextBox textBox1; 114 | private System.Windows.Forms.TextBox textBox2; 115 | private System.Windows.Forms.Label label1; 116 | private System.Windows.Forms.Label label2; 117 | } 118 | } -------------------------------------------------------------------------------- /DAIToolsWV/FileTools/HexTool.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Drawing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Threading.Tasks; 10 | using System.Windows.Forms; 11 | using DAILibWV; 12 | 13 | namespace DAIToolsWV.FileTools 14 | { 15 | public partial class HexTool : Form 16 | { 17 | public HexTool() 18 | { 19 | InitializeComponent(); 20 | } 21 | 22 | private void button1_Click(object sender, EventArgs e) 23 | { 24 | string t = textBox1.Text.Replace(" ", ""); 25 | textBox2.Text = ""; 26 | try 27 | { 28 | textBox1.Text = t; 29 | byte[] buff = Helpers.HexStringToByteArray(t); 30 | ulong l = Helpers.ReadLEB128(new MemoryStream(buff)); 31 | buff = BitConverter.GetBytes(l); 32 | textBox2.Text = l.ToString("X"); 33 | } 34 | catch (Exception) 35 | { 36 | } 37 | } 38 | 39 | private void button2_Click(object sender, EventArgs e) 40 | { 41 | string t = textBox2.Text.Replace(" ", ""); 42 | textBox1.Text = ""; 43 | try 44 | { 45 | textBox2.Text = t; 46 | int v = Convert.ToInt32(t, 16); 47 | MemoryStream m = new MemoryStream(); 48 | Helpers.WriteLEB128(m, v); 49 | byte[] buff = m.ToArray(); 50 | foreach (byte b in buff) 51 | textBox1.Text += b.ToString("X2"); 52 | } 53 | catch (Exception) 54 | { 55 | } 56 | } 57 | } 58 | } 59 | -------------------------------------------------------------------------------- /DAIToolsWV/FileTools/HexTool.resx: -------------------------------------------------------------------------------- 1 |  2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | text/microsoft-resx 110 | 111 | 112 | 2.0 113 | 114 | 115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | 118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 119 | 120 | -------------------------------------------------------------------------------- /DAIToolsWV/FileTools/INITFSTool.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Drawing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Threading.Tasks; 10 | using System.Windows.Forms; 11 | using DAILibWV; 12 | using DAILibWV.Frostbite; 13 | using Be.Windows.Forms; 14 | 15 | namespace DAIToolsWV.FileTools 16 | { 17 | public partial class INITFSTool : Form 18 | { 19 | struct FileEntry 20 | { 21 | public byte[] data; 22 | public string name; 23 | } 24 | 25 | TOCFile initfs; 26 | List list; 27 | 28 | public INITFSTool() 29 | { 30 | InitializeComponent(); 31 | } 32 | 33 | private void openToolStripMenuItem_Click(object sender, EventArgs e) 34 | { 35 | OpenFileDialog d = new OpenFileDialog(); 36 | d.Filter = "initfs_Win32|initfs_Win32"; 37 | if (d.ShowDialog() == System.Windows.Forms.DialogResult.OK) 38 | { 39 | LoadFile(d.FileName); 40 | } 41 | } 42 | 43 | public void LoadFile(string path) 44 | { 45 | initfs = new TOCFile(path); 46 | list = new List(); 47 | foreach (BJSON.Entry e in initfs.lines) 48 | if (e.fields != null && e.fields.Count != 0) 49 | { 50 | BJSON.Field file = e.fields[0]; 51 | List data = (List)file.data; 52 | FileEntry entry = new FileEntry(); 53 | foreach (BJSON.Field f in data) 54 | switch (f.fieldname) 55 | { 56 | case "name": 57 | entry.name = (string)f.data; 58 | break; 59 | case "payload": 60 | entry.data = (byte[])f.data; 61 | break; 62 | } 63 | list.Add(entry); 64 | } 65 | RefreshList(); 66 | } 67 | 68 | public void RefreshList() 69 | { 70 | listBox1.Items.Clear(); 71 | foreach (FileEntry e in list) 72 | listBox1.Items.Add(e.name); 73 | } 74 | 75 | private void listBox1_SelectedIndexChanged(object sender, EventArgs e) 76 | { 77 | RefreshDisplay(); 78 | } 79 | 80 | private void RefreshDisplay() 81 | { 82 | int n = listBox1.SelectedIndex; 83 | if (n == -1) 84 | return; 85 | FileEntry entry = list[n]; 86 | if (toolStripButton1.Checked) 87 | { 88 | hb1.ByteProvider = new DynamicByteProvider(entry.data); 89 | hb1.BringToFront(); 90 | } 91 | else 92 | { 93 | rtb1.Text = Encoding.Default.GetString(entry.data); 94 | rtb1.BringToFront(); 95 | } 96 | } 97 | 98 | private void toolStripButton2_Click(object sender, EventArgs e) 99 | { 100 | toolStripButton1.Checked = false; 101 | toolStripButton2.Checked = true; 102 | RefreshDisplay(); 103 | } 104 | 105 | private void toolStripButton1_Click(object sender, EventArgs e) 106 | { 107 | toolStripButton2.Checked = false; 108 | toolStripButton1.Checked = true; 109 | RefreshDisplay(); 110 | } 111 | 112 | private void toolStripButton3_Click(object sender, EventArgs e) 113 | { 114 | int n = listBox1.SelectedIndex; 115 | if (n == -1) 116 | return; 117 | FileEntry entry = list[n]; 118 | if (toolStripButton1.Checked) 119 | { 120 | MemoryStream m = new MemoryStream(); 121 | for (long i = 0; i < hb1.ByteProvider.Length; i++) 122 | m.WriteByte(hb1.ByteProvider.ReadByte(i)); 123 | entry.data = m.ToArray(); 124 | } 125 | else 126 | entry.data = Helpers.StringAsByteArray(rtb1.Text); 127 | list[n] = entry; 128 | } 129 | 130 | private void saveToolStripMenuItem_Click(object sender, EventArgs e) 131 | { 132 | SaveFileDialog d = new SaveFileDialog(); 133 | d.Filter = "initfs_Win32|initfs_Win32"; 134 | if (d.ShowDialog() == System.Windows.Forms.DialogResult.OK) 135 | { 136 | SaveFile(d.FileName); 137 | MessageBox.Show("Done"); 138 | } 139 | } 140 | 141 | public void SaveFile(string path) 142 | { 143 | for (int i = 0; i < initfs.lines.Count; i++) 144 | { 145 | BJSON.Entry e = initfs.lines[i]; 146 | if (e.fields != null && e.fields.Count != 0) 147 | { 148 | BJSON.Field file = e.fields[0]; 149 | List data = (List)file.data; 150 | foreach (BJSON.Field f in data) 151 | if (f.fieldname=="payload") 152 | f.data = list[i].data; 153 | } 154 | initfs.lines[i] = e; 155 | } 156 | initfs.Save(path); 157 | RefreshList(); 158 | } 159 | } 160 | } 161 | -------------------------------------------------------------------------------- /DAIToolsWV/FileTools/MFTTool.Designer.cs: -------------------------------------------------------------------------------- 1 | namespace DAIToolsWV.FileTools 2 | { 3 | partial class MFTTool 4 | { 5 | /// 6 | /// Required designer variable. 7 | /// 8 | private System.ComponentModel.IContainer components = null; 9 | 10 | /// 11 | /// Clean up any resources being used. 12 | /// 13 | /// true if managed resources should be disposed; otherwise, false. 14 | protected override void Dispose(bool disposing) 15 | { 16 | if (disposing && (components != null)) 17 | { 18 | components.Dispose(); 19 | } 20 | base.Dispose(disposing); 21 | } 22 | 23 | #region Windows Form Designer generated code 24 | 25 | /// 26 | /// Required method for Designer support - do not modify 27 | /// the contents of this method with the code editor. 28 | /// 29 | private void InitializeComponent() 30 | { 31 | this.rtb1 = new System.Windows.Forms.RichTextBox(); 32 | this.menuStrip1 = new System.Windows.Forms.MenuStrip(); 33 | this.fileToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); 34 | this.openToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); 35 | this.saveToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); 36 | this.menuStrip1.SuspendLayout(); 37 | this.SuspendLayout(); 38 | // 39 | // rtb1 40 | // 41 | this.rtb1.DetectUrls = false; 42 | this.rtb1.Dock = System.Windows.Forms.DockStyle.Fill; 43 | this.rtb1.Font = new System.Drawing.Font("Courier New", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 44 | this.rtb1.HideSelection = false; 45 | this.rtb1.Location = new System.Drawing.Point(0, 24); 46 | this.rtb1.Name = "rtb1"; 47 | this.rtb1.Size = new System.Drawing.Size(292, 249); 48 | this.rtb1.TabIndex = 0; 49 | this.rtb1.Text = ""; 50 | this.rtb1.WordWrap = false; 51 | // 52 | // menuStrip1 53 | // 54 | this.menuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { 55 | this.fileToolStripMenuItem}); 56 | this.menuStrip1.Location = new System.Drawing.Point(0, 0); 57 | this.menuStrip1.Name = "menuStrip1"; 58 | this.menuStrip1.Size = new System.Drawing.Size(292, 24); 59 | this.menuStrip1.TabIndex = 1; 60 | this.menuStrip1.Text = "menuStrip1"; 61 | this.menuStrip1.Visible = false; 62 | // 63 | // fileToolStripMenuItem 64 | // 65 | this.fileToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { 66 | this.openToolStripMenuItem, 67 | this.saveToolStripMenuItem}); 68 | this.fileToolStripMenuItem.Name = "fileToolStripMenuItem"; 69 | this.fileToolStripMenuItem.Size = new System.Drawing.Size(35, 20); 70 | this.fileToolStripMenuItem.Text = "File"; 71 | // 72 | // openToolStripMenuItem 73 | // 74 | this.openToolStripMenuItem.Name = "openToolStripMenuItem"; 75 | this.openToolStripMenuItem.Size = new System.Drawing.Size(152, 22); 76 | this.openToolStripMenuItem.Text = "Open"; 77 | this.openToolStripMenuItem.Click += new System.EventHandler(this.openToolStripMenuItem_Click); 78 | // 79 | // saveToolStripMenuItem 80 | // 81 | this.saveToolStripMenuItem.Name = "saveToolStripMenuItem"; 82 | this.saveToolStripMenuItem.Size = new System.Drawing.Size(152, 22); 83 | this.saveToolStripMenuItem.Text = "Save"; 84 | this.saveToolStripMenuItem.Click += new System.EventHandler(this.saveToolStripMenuItem_Click); 85 | // 86 | // MFTTool 87 | // 88 | this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); 89 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 90 | this.ClientSize = new System.Drawing.Size(292, 273); 91 | this.Controls.Add(this.rtb1); 92 | this.Controls.Add(this.menuStrip1); 93 | this.MainMenuStrip = this.menuStrip1; 94 | this.Name = "MFTTool"; 95 | this.Text = "MFT Tool"; 96 | this.menuStrip1.ResumeLayout(false); 97 | this.menuStrip1.PerformLayout(); 98 | this.ResumeLayout(false); 99 | this.PerformLayout(); 100 | 101 | } 102 | 103 | #endregion 104 | 105 | private System.Windows.Forms.RichTextBox rtb1; 106 | private System.Windows.Forms.MenuStrip menuStrip1; 107 | private System.Windows.Forms.ToolStripMenuItem fileToolStripMenuItem; 108 | private System.Windows.Forms.ToolStripMenuItem openToolStripMenuItem; 109 | private System.Windows.Forms.ToolStripMenuItem saveToolStripMenuItem; 110 | } 111 | } -------------------------------------------------------------------------------- /DAIToolsWV/FileTools/MFTTool.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Drawing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Threading.Tasks; 10 | using System.Windows.Forms; 11 | using DAILibWV; 12 | 13 | namespace DAIToolsWV.FileTools 14 | { 15 | public partial class MFTTool : Form 16 | { 17 | byte[] key = File.ReadAllBytes(Path.GetDirectoryName(Application.ExecutablePath) + "\\ext\\keys\\mft_key.bin"); 18 | bool isEncrypted = false; 19 | 20 | public MFTTool() 21 | { 22 | InitializeComponent(); 23 | } 24 | 25 | private void openToolStripMenuItem_Click(object sender, EventArgs e) 26 | { 27 | OpenFileDialog d = new OpenFileDialog(); 28 | d.Filter = "*.mft|*.mft"; 29 | if(d.ShowDialog() == System.Windows.Forms.DialogResult.OK) 30 | LoadFile(d.FileName); 31 | } 32 | 33 | private void LoadFile(string path) 34 | { 35 | byte[] data = File.ReadAllBytes(path); 36 | uint magic = BitConverter.ToUInt32(data,0); 37 | isEncrypted = false; 38 | if(magic != 0x656D614E) 39 | { 40 | for(int i=0;i 2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | text/microsoft-resx 110 | 111 | 112 | 2.0 113 | 114 | 115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | 118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 119 | 120 | 121 | 17, 17 122 | 123 | -------------------------------------------------------------------------------- /DAIToolsWV/FileTools/SBTool_InputForm.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Data; 5 | using System.Drawing; 6 | using System.Linq; 7 | using System.Text; 8 | using System.Threading.Tasks; 9 | using System.Windows.Forms; 10 | 11 | namespace DAIToolsWV.FileTools 12 | { 13 | public partial class SBTool_InputForm : Form 14 | { 15 | public SBTool_InputForm() 16 | { 17 | InitializeComponent(); 18 | } 19 | 20 | private void doneToolStripMenuItem_Click(object sender, EventArgs e) 21 | { 22 | this.DialogResult = System.Windows.Forms.DialogResult.OK; 23 | Close(); 24 | } 25 | 26 | private void cancelToolStripMenuItem_Click(object sender, EventArgs e) 27 | { 28 | this.DialogResult = System.Windows.Forms.DialogResult.Cancel; 29 | Close(); 30 | } 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /DAIToolsWV/FileTools/SBTool_InputForm.resx: -------------------------------------------------------------------------------- 1 |  2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | text/microsoft-resx 110 | 111 | 112 | 2.0 113 | 114 | 115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | 118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 119 | 120 | 121 | 17, 17 122 | 123 | -------------------------------------------------------------------------------- /DAIToolsWV/FileTools/TOCTool_InputForm.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Data; 5 | using System.Drawing; 6 | using System.Linq; 7 | using System.Text; 8 | using System.Threading.Tasks; 9 | using System.Windows.Forms; 10 | 11 | namespace DAIToolsWV.FileTools 12 | { 13 | public partial class TOCTool_InputForm : Form 14 | { 15 | public TOCTool_InputForm() 16 | { 17 | InitializeComponent(); 18 | } 19 | 20 | private void doneToolStripMenuItem_Click(object sender, EventArgs e) 21 | { 22 | this.DialogResult = System.Windows.Forms.DialogResult.OK; 23 | Close(); 24 | } 25 | 26 | private void cancelToolStripMenuItem_Click(object sender, EventArgs e) 27 | { 28 | this.DialogResult = System.Windows.Forms.DialogResult.Cancel; 29 | Close(); 30 | } 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /DAIToolsWV/FileTools/TOCTool_InputForm.resx: -------------------------------------------------------------------------------- 1 |  2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | text/microsoft-resx 110 | 111 | 112 | 2.0 113 | 114 | 115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | 118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 119 | 120 | 121 | 17, 17 122 | 123 | -------------------------------------------------------------------------------- /DAIToolsWV/FixedByteProvider.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using Be.Windows.Forms; 7 | 8 | namespace DAIToolsWV 9 | { 10 | public class FixedByteProvider : IByteProvider 11 | { 12 | /// 13 | /// Contains information about changes. 14 | /// 15 | bool _hasChanges; 16 | /// 17 | /// Contains a byte collection. 18 | /// 19 | List _bytes; 20 | 21 | /// 22 | /// Initializes a new instance of the DynamicByteProvider class. 23 | /// 24 | /// 25 | public FixedByteProvider(byte[] data) 26 | : this(new List(data)) 27 | { 28 | } 29 | 30 | /// 31 | /// Initializes a new instance of the DynamicByteProvider class. 32 | /// 33 | /// 34 | public FixedByteProvider(List bytes) 35 | { 36 | _bytes = bytes; 37 | } 38 | 39 | /// 40 | /// Raises the Changed event. 41 | /// 42 | void OnChanged(EventArgs e) 43 | { 44 | _hasChanges = true; 45 | 46 | if (Changed != null) 47 | Changed(this, e); 48 | } 49 | 50 | /// 51 | /// Raises the LengthChanged event. 52 | /// 53 | void OnLengthChanged(EventArgs e) 54 | { 55 | if (LengthChanged != null) 56 | LengthChanged(this, e); 57 | } 58 | 59 | /// 60 | /// Gets the byte collection. 61 | /// 62 | public List Bytes 63 | { 64 | get { return _bytes; } 65 | } 66 | 67 | #region IByteProvider Members 68 | /// 69 | /// True, when changes are done. 70 | /// 71 | public bool HasChanges() 72 | { 73 | return _hasChanges; 74 | } 75 | 76 | /// 77 | /// Applies changes. 78 | /// 79 | public void ApplyChanges() 80 | { 81 | _hasChanges = false; 82 | } 83 | 84 | /// 85 | /// Occurs, when the write buffer contains new changes. 86 | /// 87 | public event EventHandler Changed; 88 | 89 | /// 90 | /// Occurs, when InsertBytes or DeleteBytes method is called. 91 | /// 92 | public event EventHandler LengthChanged; 93 | 94 | 95 | /// 96 | /// Reads a byte from the byte collection. 97 | /// 98 | /// the index of the byte to read 99 | /// the byte 100 | public byte ReadByte(long index) 101 | { return _bytes[(int)index]; } 102 | 103 | /// 104 | /// Write a byte into the byte collection. 105 | /// 106 | /// the index of the byte to write. 107 | /// the byte 108 | public void WriteByte(long index, byte value) 109 | { 110 | _bytes[(int)index] = value; 111 | OnChanged(EventArgs.Empty); 112 | } 113 | 114 | /// 115 | /// Deletes bytes from the byte collection. 116 | /// 117 | /// the start index of the bytes to delete. 118 | /// the length of bytes to delete. 119 | public void DeleteBytes(long index, long length) 120 | { 121 | int internal_index = (int)Math.Max(0, index); 122 | int internal_length = (int)Math.Min((int)Length, length); 123 | _bytes.RemoveRange(internal_index, internal_length); 124 | 125 | OnLengthChanged(EventArgs.Empty); 126 | OnChanged(EventArgs.Empty); 127 | } 128 | 129 | /// 130 | /// Inserts byte into the byte collection. 131 | /// 132 | /// the start index of the bytes in the byte collection 133 | /// the byte array to insert 134 | public void InsertBytes(long index, byte[] bs) 135 | { 136 | _bytes.InsertRange((int)index, bs); 137 | 138 | OnLengthChanged(EventArgs.Empty); 139 | OnChanged(EventArgs.Empty); 140 | } 141 | 142 | /// 143 | /// Gets the length of the bytes in the byte collection. 144 | /// 145 | public long Length 146 | { 147 | get 148 | { 149 | return _bytes.Count; 150 | } 151 | } 152 | 153 | /// 154 | /// Returns true 155 | /// 156 | public bool SupportsWriteByte() 157 | { 158 | return true; 159 | } 160 | 161 | /// 162 | /// Returns true 163 | /// 164 | public bool SupportsInsertBytes() 165 | { 166 | return false; 167 | } 168 | 169 | /// 170 | /// Returns true 171 | /// 172 | public bool SupportsDeleteBytes() 173 | { 174 | return false; 175 | } 176 | #endregion 177 | 178 | } 179 | } 180 | -------------------------------------------------------------------------------- /DAIToolsWV/GeneralTools/CATrepair.Designer.cs: -------------------------------------------------------------------------------- 1 | namespace DAIToolsWV.GeneralTools 2 | { 3 | partial class CATrepair 4 | { 5 | /// 6 | /// Required designer variable. 7 | /// 8 | private System.ComponentModel.IContainer components = null; 9 | 10 | /// 11 | /// Clean up any resources being used. 12 | /// 13 | /// true if managed resources should be disposed; otherwise, false. 14 | protected override void Dispose(bool disposing) 15 | { 16 | if (disposing && (components != null)) 17 | { 18 | components.Dispose(); 19 | } 20 | base.Dispose(disposing); 21 | } 22 | 23 | #region Windows Form Designer generated code 24 | 25 | /// 26 | /// Required method for Designer support - do not modify 27 | /// the contents of this method with the code editor. 28 | /// 29 | private void InitializeComponent() 30 | { 31 | this.menuStrip1 = new System.Windows.Forms.MenuStrip(); 32 | this.rtb1 = new System.Windows.Forms.RichTextBox(); 33 | this.fileToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); 34 | this.checkCATToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); 35 | this.repairCATToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); 36 | this.menuStrip1.SuspendLayout(); 37 | this.SuspendLayout(); 38 | // 39 | // menuStrip1 40 | // 41 | this.menuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { 42 | this.fileToolStripMenuItem}); 43 | this.menuStrip1.Location = new System.Drawing.Point(0, 0); 44 | this.menuStrip1.Name = "menuStrip1"; 45 | this.menuStrip1.Size = new System.Drawing.Size(292, 24); 46 | this.menuStrip1.TabIndex = 0; 47 | this.menuStrip1.Text = "menuStrip1"; 48 | this.menuStrip1.Visible = false; 49 | // 50 | // rtb1 51 | // 52 | this.rtb1.DetectUrls = false; 53 | this.rtb1.Dock = System.Windows.Forms.DockStyle.Fill; 54 | this.rtb1.Font = new System.Drawing.Font("Courier New", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 55 | this.rtb1.HideSelection = false; 56 | this.rtb1.Location = new System.Drawing.Point(0, 24); 57 | this.rtb1.Name = "rtb1"; 58 | this.rtb1.ReadOnly = true; 59 | this.rtb1.Size = new System.Drawing.Size(292, 249); 60 | this.rtb1.TabIndex = 3; 61 | this.rtb1.Text = ""; 62 | // 63 | // fileToolStripMenuItem 64 | // 65 | this.fileToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { 66 | this.checkCATToolStripMenuItem, 67 | this.repairCATToolStripMenuItem}); 68 | this.fileToolStripMenuItem.Name = "fileToolStripMenuItem"; 69 | this.fileToolStripMenuItem.Size = new System.Drawing.Size(35, 20); 70 | this.fileToolStripMenuItem.Text = "File"; 71 | // 72 | // checkCATToolStripMenuItem 73 | // 74 | this.checkCATToolStripMenuItem.Name = "checkCATToolStripMenuItem"; 75 | this.checkCATToolStripMenuItem.Size = new System.Drawing.Size(152, 22); 76 | this.checkCATToolStripMenuItem.Text = "Check CAT..."; 77 | this.checkCATToolStripMenuItem.Click += new System.EventHandler(this.checkCATToolStripMenuItem_Click); 78 | // 79 | // repairCATToolStripMenuItem 80 | // 81 | this.repairCATToolStripMenuItem.Name = "repairCATToolStripMenuItem"; 82 | this.repairCATToolStripMenuItem.Size = new System.Drawing.Size(152, 22); 83 | this.repairCATToolStripMenuItem.Text = "Repair CAT"; 84 | this.repairCATToolStripMenuItem.Click += new System.EventHandler(this.repairCATToolStripMenuItem_Click); 85 | // 86 | // CATrepair 87 | // 88 | this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); 89 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 90 | this.ClientSize = new System.Drawing.Size(292, 273); 91 | this.Controls.Add(this.rtb1); 92 | this.Controls.Add(this.menuStrip1); 93 | this.MainMenuStrip = this.menuStrip1; 94 | this.Name = "CATrepair"; 95 | this.Text = "CAT Repair"; 96 | this.menuStrip1.ResumeLayout(false); 97 | this.menuStrip1.PerformLayout(); 98 | this.ResumeLayout(false); 99 | this.PerformLayout(); 100 | 101 | } 102 | 103 | #endregion 104 | 105 | private System.Windows.Forms.MenuStrip menuStrip1; 106 | private System.Windows.Forms.ToolStripMenuItem fileToolStripMenuItem; 107 | private System.Windows.Forms.ToolStripMenuItem checkCATToolStripMenuItem; 108 | private System.Windows.Forms.ToolStripMenuItem repairCATToolStripMenuItem; 109 | private System.Windows.Forms.RichTextBox rtb1; 110 | } 111 | } -------------------------------------------------------------------------------- /DAIToolsWV/GeneralTools/CATrepair.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Drawing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Threading.Tasks; 10 | using System.Windows.Forms; 11 | using DAILibWV.Frostbite; 12 | using DAILibWV; 13 | 14 | namespace DAIToolsWV.GeneralTools 15 | { 16 | public partial class CATrepair : Form 17 | { 18 | public CATFile cat; 19 | 20 | public struct DupEntry 21 | { 22 | public int firstIdx; 23 | public List dupIdx; 24 | } 25 | 26 | public List DupList = null; 27 | public bool[] isDup = new bool[0]; 28 | 29 | public CATrepair() 30 | { 31 | InitializeComponent(); 32 | } 33 | 34 | private void checkCATToolStripMenuItem_Click(object sender, EventArgs e) 35 | { 36 | OpenFileDialog d = new OpenFileDialog(); 37 | d.Filter = "*.cat|*.cat"; 38 | if (d.ShowDialog() == System.Windows.Forms.DialogResult.OK) 39 | { 40 | cat = new CATFile(d.FileName); 41 | Check(); 42 | } 43 | } 44 | 45 | public void Check() 46 | { 47 | DupList = new List(); 48 | int count = cat.lines.Count; 49 | isDup = new bool[count]; 50 | StringBuilder sb = new StringBuilder(); 51 | for (int i = 0; i < count - 1; i++) 52 | if (!isDup[i]) 53 | { 54 | if (i % 100 == 0) 55 | { 56 | rtb1.Text = "Checking " + i + " / " + count; 57 | Application.DoEvents(); 58 | } 59 | DupEntry d = new DupEntry(); 60 | d.firstIdx = i; 61 | d.dupIdx = new List(); 62 | for (int j = i + 1; j < count; j++) 63 | { 64 | if (cat.lines[i][0] == cat.lines[j][0] && 65 | cat.lines[i][1] == cat.lines[j][1] && 66 | cat.lines[i][2] == cat.lines[j][2] && 67 | cat.lines[i][3] == cat.lines[j][3] && 68 | cat.lines[i][4] == cat.lines[j][4]) 69 | { 70 | isDup[i] = isDup[j] = true; 71 | d.dupIdx.Add(j); 72 | } 73 | } 74 | if (d.dupIdx.Count != 0) 75 | { 76 | sb.Append("Found duplicate times " + d.dupIdx.Count + " for Index " + d.firstIdx + "\n"); 77 | DupList.Add(d); 78 | } 79 | } 80 | rtb1.Text = "Checking " + count + " / " + count + "\n"; 81 | rtb1.AppendText(sb.ToString()); 82 | Application.DoEvents(); 83 | } 84 | 85 | private void repairCATToolStripMenuItem_Click(object sender, EventArgs e) 86 | { 87 | if (cat == null || DupList == null || DupList.Count == 0) 88 | return; 89 | rtb1.AppendText("\nRepairing CAT by only using the latest duplicate...\nWriting Header...\n"); 90 | Application.DoEvents(); 91 | MemoryStream m = new MemoryStream(); 92 | Helpers.WriteLEInt(m, 0x4E79616E); 93 | Helpers.WriteLEInt(m, 0x4E79616E); 94 | Helpers.WriteLEInt(m, 0x4E79616E); 95 | Helpers.WriteLEInt(m, 0x4E79616E); 96 | int count = cat.lines.Count; 97 | rtb1.AppendText("Writing non-duplicates...\n"); 98 | Application.DoEvents(); 99 | for (int i = 0; i < count; i++) 100 | if (!isDup[i]) 101 | { 102 | Helpers.WriteLEUInt(m, cat.lines[i][0]); 103 | Helpers.WriteLEUInt(m, cat.lines[i][1]); 104 | Helpers.WriteLEUInt(m, cat.lines[i][2]); 105 | Helpers.WriteLEUInt(m, cat.lines[i][3]); 106 | Helpers.WriteLEUInt(m, cat.lines[i][4]); 107 | Helpers.WriteUInt(m, cat.lines[i][5]); 108 | Helpers.WriteUInt(m, cat.lines[i][6]); 109 | Helpers.WriteUInt(m, cat.lines[i][7]); 110 | } 111 | rtb1.AppendText("Writing latest-of-duplicates...\n"); 112 | Application.DoEvents(); 113 | foreach (DupEntry d in DupList) 114 | { 115 | int idx = d.dupIdx[d.dupIdx.Count - 1]; 116 | Helpers.WriteLEUInt(m, cat.lines[idx][0]); 117 | Helpers.WriteLEUInt(m, cat.lines[idx][1]); 118 | Helpers.WriteLEUInt(m, cat.lines[idx][2]); 119 | Helpers.WriteLEUInt(m, cat.lines[idx][3]); 120 | Helpers.WriteLEUInt(m, cat.lines[idx][4]); 121 | Helpers.WriteUInt(m, cat.lines[idx][5]); 122 | Helpers.WriteUInt(m, cat.lines[idx][6]); 123 | Helpers.WriteUInt(m, cat.lines[idx][7]); 124 | } 125 | File.WriteAllBytes(cat.MyPath, m.ToArray()); 126 | rtb1.AppendText("Done."); 127 | } 128 | 129 | } 130 | } 131 | -------------------------------------------------------------------------------- /DAIToolsWV/GeneralTools/HexToString.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Drawing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Threading.Tasks; 10 | using System.Windows.Forms; 11 | using Be.Windows.Forms; 12 | 13 | namespace DAIToolsWV.GeneralTools 14 | { 15 | public partial class HexToString : Form 16 | { 17 | public HexToString() 18 | { 19 | InitializeComponent(); 20 | hb4.ByteProvider = new DynamicByteProvider(new byte[0]); 21 | } 22 | 23 | private void toolStripButton1_Click(object sender, EventArgs e) 24 | { 25 | MemoryStream m = new MemoryStream(); 26 | for (long i = 0; i < hb4.ByteProvider.Length; i++) 27 | m.WriteByte(hb4.ByteProvider.ReadByte(i)); 28 | StringBuilder sb = new StringBuilder(); 29 | m.Seek(0, 0); 30 | if (withSpaces.Checked) 31 | for (long i = 0; i < m.Length; i++) 32 | sb.Append(((byte)m.ReadByte()).ToString("X2") + " "); 33 | else 34 | for (long i = 0; i < m.Length; i++) 35 | sb.Append(((byte)m.ReadByte()).ToString("X2")); 36 | rtb2.Text = sb.ToString(); 37 | } 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /DAIToolsWV/ModTools/ModEditor.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Data; 5 | using System.Drawing; 6 | using System.Linq; 7 | using System.Text; 8 | using System.Threading.Tasks; 9 | using System.Windows.Forms; 10 | using DAILibWV; 11 | using Be.Windows.Forms; 12 | 13 | namespace DAIToolsWV.ModTools 14 | { 15 | public partial class ModEditor : Form 16 | { 17 | public Mod mod; 18 | public List dataList; 19 | 20 | public ModEditor() 21 | { 22 | InitializeComponent(); 23 | } 24 | 25 | private void openToolStripMenuItem_Click(object sender, EventArgs e) 26 | { 27 | OpenFileDialog d = new OpenFileDialog(); 28 | d.Filter = "*.DAIMWV|*.DAIMWV"; 29 | if (d.ShowDialog() == System.Windows.Forms.DialogResult.OK) 30 | { 31 | mod = new Mod(); 32 | mod.Load(d.FileName); 33 | RefreshMe(); 34 | } 35 | } 36 | 37 | public void RefreshMe() 38 | { 39 | if (mod == null) 40 | return; 41 | rtb1.Text = mod.headerXML; 42 | dataList = new List(); 43 | listBox1.Items.Clear(); 44 | int count = 0; 45 | foreach (Mod.ModJob mj in mod.jobs) 46 | switch (mj.type) 47 | { 48 | case 0: 49 | case 1: 50 | case 2: 51 | dataList.Add(mj.data); 52 | listBox1.Items.Add("Data Blob #" + (count++)); 53 | break; 54 | } 55 | } 56 | 57 | private void listBox1_SelectedIndexChanged(object sender, EventArgs e) 58 | { 59 | int n = listBox1.SelectedIndex; 60 | if (n == -1) 61 | return; 62 | hb1.ByteProvider = new DynamicByteProvider(dataList[n]); 63 | } 64 | 65 | private void importToolStripMenuItem_Click(object sender, EventArgs e) 66 | { 67 | if (mod == null) 68 | return; 69 | OpenFileDialog d = new OpenFileDialog(); 70 | d.Filter = "*.DAIMWV|*.DAIMWV"; 71 | if (d.ShowDialog() == System.Windows.Forms.DialogResult.OK) 72 | { 73 | Mod mi = new Mod(); 74 | mi.Load(d.FileName); 75 | foreach (Mod.ModJob mj in mi.jobs) 76 | mod.jobs.Add(mj); 77 | mod.CreateHeader(); 78 | RefreshMe(); 79 | MessageBox.Show("Done."); 80 | } 81 | } 82 | 83 | private void saveToolStripMenuItem_Click(object sender, EventArgs e) 84 | { 85 | if (mod == null) 86 | return; 87 | SaveFileDialog d = new SaveFileDialog(); 88 | d.Filter = "*.DAIMWV|*.DAIMWV"; 89 | if (d.ShowDialog() == System.Windows.Forms.DialogResult.OK) 90 | { 91 | mod.headerXML = rtb1.Text; 92 | mod.Save(d.FileName, false); 93 | MessageBox.Show("Done."); 94 | } 95 | } 96 | } 97 | } 98 | -------------------------------------------------------------------------------- /DAIToolsWV/ModTools/ModEditor.resx: -------------------------------------------------------------------------------- 1 |  2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | text/microsoft-resx 110 | 111 | 112 | 2.0 113 | 114 | 115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | 118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 119 | 120 | 121 | 17, 17 122 | 123 | -------------------------------------------------------------------------------- /DAIToolsWV/Program.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using System.Windows.Forms; 6 | 7 | namespace DAIToolsWV 8 | { 9 | static class Program 10 | { 11 | /// 12 | /// Der Haupteinstiegspunkt für die Anwendung. 13 | /// 14 | [STAThread] 15 | static void Main() 16 | { 17 | Application.EnableVisualStyles(); 18 | Application.SetCompatibleTextRenderingDefault(false); 19 | Application.Run(new MainForm()); 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /DAIToolsWV/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // Allgemeine Informationen über eine Assembly werden über die folgenden 6 | // Attribute gesteuert. Ändern Sie diese Attributwerte, um die Informationen zu ändern, 7 | // die mit einer Assembly verknüpft sind. 8 | [assembly: AssemblyTitle("DAIToolsWV")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("Microsoft")] 12 | [assembly: AssemblyProduct("DAIToolsWV")] 13 | [assembly: AssemblyCopyright("Copyright © Microsoft 2015")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Durch Festlegen von ComVisible auf "false" werden die Typen in dieser Assembly unsichtbar 18 | // für COM-Komponenten. Wenn Sie auf einen Typ in dieser Assembly von 19 | // COM zugreifen müssen, legen Sie das ComVisible-Attribut für diesen Typ auf "true" fest. 20 | [assembly: ComVisible(false)] 21 | 22 | // Die folgende GUID bestimmt die ID der Typbibliothek, wenn dieses Projekt für COM verfügbar gemacht wird 23 | [assembly: Guid("fa708463-0036-482d-97cb-ad7419b2a521")] 24 | 25 | // Versionsinformationen für eine Assembly bestehen aus den folgenden vier Werten: 26 | // 27 | // Hauptversion 28 | // Nebenversion 29 | // Buildnummer 30 | // Revision 31 | // 32 | // Sie können alle Werte angeben oder die standardmäßigen Build- und Revisionsnummern 33 | // übernehmen, indem Sie "*" eingeben: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.2.*")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /DAIToolsWV/Properties/Resources.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // Dieser Code wurde von einem Tool generiert. 4 | // Laufzeitversion:4.0.30319.34209 5 | // 6 | // Änderungen an dieser Datei können fehlerhaftes Verhalten verursachen und gehen verloren, wenn 7 | // der Code neu generiert wird. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace DAIToolsWV.Properties 12 | { 13 | 14 | 15 | /// 16 | /// Eine stark typisierte Ressourcenklasse zum Suchen von lokalisierten Zeichenfolgen usw. 17 | /// 18 | // Diese Klasse wurde von der StronglyTypedResourceBuilder-Klasse 19 | // über ein Tool wie ResGen oder Visual Studio automatisch generiert. 20 | // Um einen Member hinzuzufügen oder zu entfernen, bearbeiten Sie die .ResX-Datei und führen dann ResGen 21 | // mit der Option /str erneut aus, oder erstellen Sie Ihr VS-Projekt neu. 22 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")] 23 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 24 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 25 | internal class Resources 26 | { 27 | 28 | private static global::System.Resources.ResourceManager resourceMan; 29 | 30 | private static global::System.Globalization.CultureInfo resourceCulture; 31 | 32 | [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] 33 | internal Resources() 34 | { 35 | } 36 | 37 | /// 38 | /// Gibt die zwischengespeicherte ResourceManager-Instanz zurück, die von dieser Klasse verwendet wird. 39 | /// 40 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 41 | internal static global::System.Resources.ResourceManager ResourceManager 42 | { 43 | get 44 | { 45 | if ((resourceMan == null)) 46 | { 47 | global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("DAIToolsWV.Properties.Resources", typeof(Resources).Assembly); 48 | resourceMan = temp; 49 | } 50 | return resourceMan; 51 | } 52 | } 53 | 54 | /// 55 | /// Überschreibt die CurrentUICulture-Eigenschaft des aktuellen Threads für alle 56 | /// Ressourcenlookups, die diese stark typisierte Ressourcenklasse verwenden. 57 | /// 58 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 59 | internal static global::System.Globalization.CultureInfo Culture 60 | { 61 | get 62 | { 63 | return resourceCulture; 64 | } 65 | set 66 | { 67 | resourceCulture = value; 68 | } 69 | } 70 | } 71 | } 72 | -------------------------------------------------------------------------------- /DAIToolsWV/Properties/Resources.resx: -------------------------------------------------------------------------------- 1 |  2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | text/microsoft-resx 107 | 108 | 109 | 2.0 110 | 111 | 112 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 113 | 114 | 115 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | -------------------------------------------------------------------------------- /DAIToolsWV/Properties/Settings.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:4.0.30319.34209 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace DAIToolsWV.Properties 12 | { 13 | 14 | 15 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 16 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "11.0.0.0")] 17 | internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase 18 | { 19 | 20 | private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); 21 | 22 | public static Settings Default 23 | { 24 | get 25 | { 26 | return defaultInstance; 27 | } 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /DAIToolsWV/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /DAIToolsWV/Render/MeshRenderObject.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Collections.Generic; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Drawing; 7 | using System.Windows.Forms; 8 | using System.Threading.Tasks; 9 | using Microsoft.DirectX; 10 | using Microsoft.DirectX.Direct3D; 11 | using DAILibWV.Frostbite; 12 | 13 | namespace DAIToolsWV.Render 14 | { 15 | public class MeshRenderObject : RenderObject 16 | { 17 | public Vector3 min,max,center; 18 | public DAILibWV.Frostbite.Mesh mesh; 19 | public static List RawTriangles; 20 | 21 | public override void Render(Device device) 22 | { 23 | device.VertexFormat = CustomVertex.PositionTextured.Format; 24 | device.RenderState.Lighting = false; 25 | device.RenderState.FillMode = FillMode.Solid; 26 | device.RenderState.CullMode = Cull.None; 27 | foreach(CustomVertex.PositionTextured[] list in RawTriangles) 28 | device.DrawUserPrimitives(PrimitiveType.TriangleList, list.Length / 3, list); 29 | } 30 | 31 | public MeshRenderObject(DAILibWV.Frostbite.Mesh m) 32 | { 33 | mesh = m; 34 | foreach (DAILibWV.Frostbite.Mesh.MeshLOD lod in mesh.header.LODs) 35 | { 36 | if (lod.Sections == null || lod.Sections.Count == 0 || lod.Sections[0].VertexBuffer == null) 37 | continue; 38 | RawTriangles = new List(); 39 | foreach (DAILibWV.Frostbite.Mesh.MeshSection sec in lod.Sections) 40 | { 41 | List list = new List(); 42 | for (int i = 0; i < sec.TriangleCount; i++) 43 | { 44 | list.Add(DAI2DX(sec.VertexBuffer[sec.IndexBuffer[i].i0])); 45 | list.Add(DAI2DX(sec.VertexBuffer[sec.IndexBuffer[i].i1])); 46 | list.Add(DAI2DX(sec.VertexBuffer[sec.IndexBuffer[i].i2])); 47 | } 48 | RawTriangles.Add(list.ToArray()); 49 | } 50 | break; 51 | } 52 | float inf = 10000000000f; 53 | min = new Vector3(inf, inf, inf); 54 | max = new Vector3(-inf, -inf, -inf); 55 | foreach (CustomVertex.PositionTextured[] list in RawTriangles) 56 | { 57 | foreach (CustomVertex.PositionTextured v in list) 58 | { 59 | if (v.X > max.X) max.X = v.X; 60 | if (v.Y > max.Y) max.Y = v.Y; 61 | if (v.Z > max.Z) max.Z = v.Z; 62 | if (v.X < min.X) min.X = v.X; 63 | if (v.Y < min.Y) min.Y = v.Y; 64 | if (v.Z < min.Z) min.Z = v.Z; 65 | } 66 | } 67 | center = (max + min) * 0.5f; 68 | } 69 | 70 | public CustomVertex.PositionTextured DAI2DX(DAILibWV.Frostbite.Mesh.Vertex p) 71 | { 72 | return new CustomVertex.PositionTextured(new Vector3(p.Position.x, p.Position.z, p.Position.y), p.TexCoords.x, p.TexCoords.y); 73 | } 74 | } 75 | } 76 | -------------------------------------------------------------------------------- /DAIToolsWV/Render/RenderObject.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Collections.Generic; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Drawing; 7 | using System.Windows.Forms; 8 | using System.Threading.Tasks; 9 | using Microsoft.DirectX; 10 | using Microsoft.DirectX.Direct3D; 11 | 12 | namespace DAIToolsWV.Render 13 | { 14 | public abstract class RenderObject 15 | { 16 | public abstract void Render(Device device); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /DAIToolsWV/Render/Renderer.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Collections.Generic; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Drawing; 7 | using System.Windows.Forms; 8 | using System.Threading.Tasks; 9 | using Microsoft.DirectX; 10 | using Microsoft.DirectX.Direct3D; 11 | 12 | 13 | namespace DAIToolsWV.Render 14 | { 15 | public class Renderer 16 | { 17 | public Device device = null; 18 | public static PresentParameters presentParams = new PresentParameters(); 19 | public static Material Mat; 20 | public static Texture DefaultTex; 21 | public List list = new List(); 22 | public float CamDistance = 10f; 23 | public Vector3 worldoffset = new Vector3(0, 0, 0); 24 | 25 | public void Init(IntPtr handle, int w, int h) 26 | { 27 | try 28 | { 29 | presentParams.Windowed = true; 30 | presentParams.SwapEffect = SwapEffect.Discard; 31 | presentParams.EnableAutoDepthStencil = true; 32 | presentParams.AutoDepthStencilFormat = DepthFormat.D16; 33 | presentParams.BackBufferWidth = w; 34 | presentParams.BackBufferHeight = h; 35 | device = new Device(0, DeviceType.Hardware, handle, CreateFlags.SoftwareVertexProcessing, presentParams); 36 | Mat = new Material(); 37 | Mat.Diffuse = Color.White; 38 | Mat.Specular = Color.LightGray; 39 | Mat.SpecularSharpness = 15.0F; 40 | device.Material = Mat; 41 | string loc = Path.GetDirectoryName(Application.ExecutablePath); 42 | DefaultTex = TextureLoader.FromFile(device, loc + "\\ext\\img\\Default.bmp"); 43 | } 44 | catch (DirectXException) 45 | { 46 | device = null; 47 | } 48 | } 49 | 50 | public void Render() 51 | { 52 | if (device == null) 53 | return; 54 | try 55 | { 56 | device.SetRenderState(RenderStates.ShadeMode, 1); 57 | device.SetRenderState(RenderStates.ZEnable, true); 58 | device.Clear(ClearFlags.Target, System.Drawing.Color.LightBlue, 1.0f, 0); 59 | device.Clear(ClearFlags.ZBuffer, System.Drawing.Color.Black, 1.0f, 0); 60 | device.BeginScene(); 61 | device.SetTexture(0, DefaultTex); 62 | int iTime = Environment.TickCount; 63 | float fAngle = iTime * (2.0f * (float)Math.PI) / 10000.0f; 64 | device.Transform.World = Matrix.Translation(worldoffset) * Matrix.RotationZ(fAngle); 65 | device.Transform.View = Matrix.LookAtLH(new Vector3(0.0f, CamDistance, CamDistance/ 2), new Vector3(0, 0, 0), new Vector3(0.0f, 0.0f, 1.0f)); 66 | device.Transform.Projection = Matrix.PerspectiveFovLH((float)Math.PI / 4, 1.0f, 0.01f, 100000.0f); 67 | foreach (RenderObject obj in list) 68 | obj.Render(device); 69 | device.EndScene(); 70 | device.Present(); 71 | } 72 | catch (DirectXException) 73 | { 74 | return; 75 | } 76 | } 77 | 78 | } 79 | } 80 | -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/Be.Windows.Forms.HexBox.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/bin/Debug/Be.Windows.Forms.HexBox.dll -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/DAILibWV.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/bin/Debug/DAILibWV.dll -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/DAIToolsWV.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/bin/Debug/DAIToolsWV.exe -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/DAIToolsWV.exe.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/DAIToolsWV.vshost.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/bin/Debug/DAIToolsWV.vshost.exe -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/DAIToolsWV.vshost.exe.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/DAIToolsWV.vshost.exe.manifest: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/DevIL.NET.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/bin/Debug/DevIL.NET.dll -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/DevIL.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/bin/Debug/DevIL.dll -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/ICSharpCode.SharpZipLib.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/bin/Debug/ICSharpCode.SharpZipLib.dll -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/Microsoft.DirectX.Direct3D.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/bin/Debug/Microsoft.DirectX.Direct3D.dll -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/Microsoft.DirectX.Direct3DX.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/bin/Debug/Microsoft.DirectX.Direct3DX.dll -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/Microsoft.DirectX.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/bin/Debug/Microsoft.DirectX.dll -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/System.Data.SQLite.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/bin/Debug/System.Data.SQLite.dll -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/_cleanup.bat: -------------------------------------------------------------------------------- 1 | del database.* 2 | cd tmp 3 | del *.* 4 | cd .. -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/ext/img/Default.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/bin/Debug/ext/img/Default.bmp -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/ext/keys/mft_key.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/bin/Debug/ext/keys/mft_key.bin -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/ext/luacdec/compare.rb: -------------------------------------------------------------------------------- 1 | require 'fileutils' 2 | 3 | def decompfunc(af,bf,pout) 4 | change = false 5 | origlines = 0; 6 | samelines = 0; 7 | sameopcode = 0; 8 | af.each_index do |ai| 9 | bi = ai; 10 | origlines += 1; 11 | if (af[ai] != bf[bi]) and (af[ai] !~ /Defined at line/) and (af[ai] !~ /Original file/) and (af[ai] !~ /; Disassembled:/) then 12 | print " 1>" if pout 13 | puts af[ai] if pout 14 | print " 2>" if pout 15 | puts bf[bi] if pout 16 | change = true 17 | unless bf[bi].nil? 18 | if af[ai] =~ /\[-\]: ([^ ]*)/ then 19 | opcode1 = $1 20 | if bf[bi] =~ /\[-\]: ([^ ]*)/ then 21 | opcode2 = $1 22 | if opcode1==opcode2 then 23 | sameopcode += 1 24 | end 25 | end 26 | end 27 | end 28 | else 29 | samelines += 1; 30 | sameopcode += 1; 31 | end 32 | end 33 | if af.length!=bf.length then 34 | change = true 35 | end 36 | return origlines, samelines, sameopcode, change 37 | end 38 | 39 | def comparedisasm(funcin,afile,bfile,pout) 40 | f = funcin+1 41 | compiled = false 42 | a = `luadec -dis #{afile}`.split("\n") 43 | b = `luadec -dis #{bfile}`.split("\n") 44 | origline = 0 45 | sameline = 0 46 | sameopcode = 0; 47 | x = 0; 48 | change = false 49 | ai=0; 50 | bi=0; 51 | af = [] 52 | bf = [] 53 | if (f==0) then 54 | maxfunc = 0; 55 | a.each do |line| 56 | if line =~ /; Function #([0-9]*):/ then 57 | if $1.to_i>maxfunc then 58 | maxfunc = $1.to_i 59 | end 60 | end 61 | end 62 | while ai temp.lua -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/ext/luacdec/lua.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/bin/Debug/ext/luacdec/lua.exe -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/ext/luacdec/luac.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/bin/Debug/ext/luacdec/luac.exe -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/ext/luacdec/luadec.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/bin/Debug/ext/luacdec/luadec.exe -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/ext/luacdec/temp.lua: -------------------------------------------------------------------------------- 1 | -- Decompiled using luadec 2.0 standard by sztupy (http://luadec51.luaforge.net) 2 | -- Command line was: temp.luac 3 | 4 | compiledlua_33c5d69c_4de4_4713_86bc_2a165b9fb4fa = function(l_1_0, l_1_1, l_1_2, l_1_3, l_1_4) 5 | valid = true 6 | if l_1_0 == nil then 7 | LuaError("No TimelineContext for compute_force_script", false) 8 | print("timeline context not valid") 9 | valid = false 10 | else 11 | print("timeline context valid") 12 | end 13 | force = l_1_2 14 | if force < 0 and valid then 15 | force = DA3.GetAbilityProperty(l_1_0, l_1_1) 16 | if force == nil then 17 | force = 0 18 | end 19 | print("ability force") 20 | end 21 | if force <= 0 then 22 | force = 0.15 23 | print("default force") 24 | end 25 | print("base force = " .. DA3.ToString(force)) 26 | if valid then 27 | sourceCharacter = DA3.GetPartnerCharacter(l_1_0) 28 | print("source = " .. DA3.ToString(sourceCharacter)) 29 | if l_1_3 ~= 0 then 30 | print("tag = " .. DA3.ToString(l_1_3)) 31 | if DA3.CharacterHasTimelineTag(sourceCharacter, l_1_3) then 32 | force = force + l_1_4 33 | print("modified force = " .. DA3.ToString(force)) 34 | end 35 | end 36 | end 37 | force = math.min(force, 1) 38 | print("final force = " .. DA3.ToString(force)) 39 | return force 40 | end 41 | 42 | 43 | -------------------------------------------------------------------------------- /DAIToolsWV/bin/Debug/ext/luacdec/temp.luac: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/bin/Debug/ext/luacdec/temp.luac -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.Browser.BundleBrowser.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.Browser.BundleBrowser.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.Browser.EBXBrowser.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.Browser.EBXBrowser.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.Browser.FileBrowser.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.Browser.FileBrowser.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.Browser.MeshBrowser.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.Browser.MeshBrowser.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.Browser.RESBrowser.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.Browser.RESBrowser.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.Browser.TextureBrowser.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.Browser.TextureBrowser.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.ContentTools.EBXTool.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.ContentTools.EBXTool.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.ContentTools.MeshTool.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.ContentTools.MeshTool.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.ContentTools.SHA1Lookup.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.ContentTools.SHA1Lookup.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.ContentTools.TalktableTool.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.ContentTools.TalktableTool.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.ContentTools.TextureTool.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.ContentTools.TextureTool.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.DebugOutputWindow.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.DebugOutputWindow.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.BundleBuilder.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.BundleBuilder.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.CASContainerCreator.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.CASContainerCreator.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.DAIMODSupportTool.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.DAIMODSupportTool.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.HexTool.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.HexTool.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.INITFSTool.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.INITFSTool.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.MFTTool.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.MFTTool.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.SBTool.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.SBTool.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.SBTool_InputForm.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.SBTool_InputForm.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.TOCTool.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.TOCTool.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.TOCTool_InputForm.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.FileTools.TOCTool_InputForm.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.GeneralTools.CATrepair.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.GeneralTools.CATrepair.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.GeneralTools.FolderCompare.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.GeneralTools.FolderCompare.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.GeneralTools.HexToString.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.GeneralTools.HexToString.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.MainForm.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.MainForm.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.ModTools.ModEditor.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.ModTools.ModEditor.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.ModTools.ModRunner.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.ModTools.ModRunner.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.Properties.Resources.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.Properties.Resources.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.csproj.GenerateResource.Cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.csproj.GenerateResource.Cache -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.csprojResolveAssemblyReference.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.csprojResolveAssemblyReference.cache -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DAIToolsWV.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DAIToolsWV.exe -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DesignTimeResolveAssemblyReferences.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DesignTimeResolveAssemblyReferences.cache -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/TemporaryGeneratedFile_036C0B5B-1481-4323-8D20-8F5ADCB23D92.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/TemporaryGeneratedFile_036C0B5B-1481-4323-8D20-8F5ADCB23D92.cs -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/TemporaryGeneratedFile_5937a670-0e60-4077-877b-f7221da3dda1.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/TemporaryGeneratedFile_5937a670-0e60-4077-877b-f7221da3dda1.cs -------------------------------------------------------------------------------- /DAIToolsWV/obj/Debug/TemporaryGeneratedFile_E7A71F73-0F8D-4B9B-B56E-8E70B10BC5D3.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/Debug/TemporaryGeneratedFile_E7A71F73-0F8D-4B9B-B56E-8E70B10BC5D3.cs -------------------------------------------------------------------------------- /DAIToolsWV/obj/x86/Debug/DAIToolsWV.MainForm.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/x86/Debug/DAIToolsWV.MainForm.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/x86/Debug/DAIToolsWV.Properties.Resources.resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/x86/Debug/DAIToolsWV.Properties.Resources.resources -------------------------------------------------------------------------------- /DAIToolsWV/obj/x86/Debug/DAIToolsWV.csproj.FileListAbsolute.txt: -------------------------------------------------------------------------------- 1 | D:\CODE\c#\DAIToolsWV\DAIToolsWV\bin\x86\Debug\DAIToolsWV.exe.config 2 | D:\CODE\c#\DAIToolsWV\DAIToolsWV\bin\x86\Debug\DAIToolsWV.exe 3 | D:\CODE\c#\DAIToolsWV\DAIToolsWV\bin\x86\Debug\DAIToolsWV.pdb 4 | D:\CODE\c#\DAIToolsWV\DAIToolsWV\obj\x86\Debug\DAIToolsWV.MainForm.resources 5 | D:\CODE\c#\DAIToolsWV\DAIToolsWV\obj\x86\Debug\DAIToolsWV.Properties.Resources.resources 6 | D:\CODE\c#\DAIToolsWV\DAIToolsWV\obj\x86\Debug\DAIToolsWV.csproj.GenerateResource.Cache 7 | D:\CODE\c#\DAIToolsWV\DAIToolsWV\obj\x86\Debug\DAIToolsWV.exe 8 | D:\CODE\c#\DAIToolsWV\DAIToolsWV\obj\x86\Debug\DAIToolsWV.pdb 9 | -------------------------------------------------------------------------------- /DAIToolsWV/obj/x86/Debug/DAIToolsWV.csproj.GenerateResource.Cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/x86/Debug/DAIToolsWV.csproj.GenerateResource.Cache -------------------------------------------------------------------------------- /DAIToolsWV/obj/x86/Debug/DAIToolsWV.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/x86/Debug/DAIToolsWV.exe -------------------------------------------------------------------------------- /DAIToolsWV/obj/x86/Debug/DesignTimeResolveAssemblyReferencesInput.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/x86/Debug/DesignTimeResolveAssemblyReferencesInput.cache -------------------------------------------------------------------------------- /DAIToolsWV/obj/x86/Debug/TemporaryGeneratedFile_036C0B5B-1481-4323-8D20-8F5ADCB23D92.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/x86/Debug/TemporaryGeneratedFile_036C0B5B-1481-4323-8D20-8F5ADCB23D92.cs -------------------------------------------------------------------------------- /DAIToolsWV/obj/x86/Debug/TemporaryGeneratedFile_5937a670-0e60-4077-877b-f7221da3dda1.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/x86/Debug/TemporaryGeneratedFile_5937a670-0e60-4077-877b-f7221da3dda1.cs -------------------------------------------------------------------------------- /DAIToolsWV/obj/x86/Debug/TemporaryGeneratedFile_E7A71F73-0F8D-4B9B-B56E-8E70B10BC5D3.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/obj/x86/Debug/TemporaryGeneratedFile_E7A71F73-0F8D-4B9B-B56E-8E70B10BC5D3.cs -------------------------------------------------------------------------------- /DAIToolsWV/res/papertile.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zeroKilo/DAIToolsWV/09e37d761a183fe268aa5333c9f79537d5a39812/DAIToolsWV/res/papertile.jpg -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | Dragon Age Inquisition Tools by Warranty Voider 2 | 3 | toolset to browse game content, create and run mods -------------------------------------------------------------------------------- /_cleanup.bat: -------------------------------------------------------------------------------- 1 | cd DAIToolsWV\bin\Debug\ 2 | call _cleanup.bat 3 | cd ..\..\.. 4 | del /s *.pdb 5 | --------------------------------------------------------------------------------