handsomematt / botw-modding Goto Github PK
View Code? Open in Web Editor NEWThe Legend of Zelda: Breath of the Wild - Modding Documentation and Tools
The Legend of Zelda: Breath of the Wild - Modding Documentation and Tools
Hello, excellent job describing BotW files structures. Following you explanation I have been able to decompress yaz0 and unpack byml and sarc.
BotW have a lot of aamp files that I did like to take a look at them, do you have any information about them?
Whipped this one up tonight on a whim. Checked a fair chunk of the files and none of the asserts tripped, they may be version numbers or constants. Doesn't handle uncompressing the archive, or unzipping the archive.
Edits files found in /content/Game/Stats/archive
The map is broken up into a 10x8 (width:height) grid labeled A-J and 1-8 respectively. Each map section is broken up into four sub pieces in the form of "A-1.00", "A-1.01", "A-1.11", "A-1.10" (so all four combinations of two bits).
I don't have an automated way to decompress and de-archive and test these on all files.
// Forward Declare
struct Data;
typedef struct // Vector2
{
float x; float y;
} Vector2 <read=Vector2Read, write=Vector2Write, bgcolor=0xe3adff>;
typedef struct // Header
{
char signature[4]; // STAT
uint16 Unknown1; // 1
uint16 Unknown2; // 0
uint16 Unknown3; // 0
uint16 Unknown4; // 1
uint32 HeaderSize; // 40
Vector2 BoundsCenter;
Vector2 BoundsBoxSize;
uint32 SizeX; // 100
uint32 SizeY; // 100
Data FileData <open=true>;
Assert(Unknown1 == 1, "Header Unknown1 isn't 1");
Assert(Unknown2 == 0, "Header Unknown2 isn't 0");
Assert(Unknown3 == 0, "Header Unknown3 isn't 0");
Assert(Unknown4 == 1, "Header Unknown4 isn't 1");
} Header <bgcolor=0xCDFFFF>;
typedef struct // Data
{
uint16 Unknown1; // 0
enum <uint16> ElementTypes
{
Byte = 0,
UnsignedByte = 8,
Short = 4,
UnsignedShort = 6,
Int = 10
} ElementType <format=decimal, bgcolor=0xb1ffad>;
uint32 ElementCount; // 1
uint16 Unknown2;
uint16 Unknown3;
uint32 DataTableSizePlus4;
if(ElementType == 0)
{
byte DataTable[DataTableSizePlus4 - 4] <bgcolor=0xCFDEF2>;
}
else if(ElementType == 8)
{
// (byte and ubyte might have types swapped)
ubyte DataTable[DataTableSizePlus4 - 4] <bgcolor=0xCFDEF2>;
}
else if(ElementType == 06)
{
ushort DataTable[(DataTableSizePlus4-4)/2] <bgcolor=0xCFDEF2>;
}
else if(ElementType == 04)
{
// (short and ushort might have types swapped)
short DataTable[(DataTableSizePlus4-4)/2] <bgcolor=0xCFDEF2>;
}
else if(ElementType == 10)
{
int DataTable[(DataTableSizePlus4-4)/4] <format=binary, bgcolor=0xCFDEF2>;
}
string Name;
Assert(Unknown1 == 0, "Data Unknown1 isn't 0");
Assert(Unknown2 == 0, "Data Unknown2 isn't 0");
Assert(Unknown3 == 8, "Data Unknown3 isn't 8");
} Data <bgcolor=0x9ef442>;
string Vector2Read(Vector2 &v)
{
string s;
SPrintf(s, "(%f, %f)", v.x, v.y);
return s;
}
void Vector2Write(Vector2 &v, string s)
{
SScanf(s, "(%f, %f)", v.x, v,y);
}
// ==== File Contents ==================================================================================================
BigEndian();
BitfieldRightToLeft();
Header file <open=true>;
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.