- Joined
- Dec 1, 2008
- Messages
- 68
- Reaction score
- 1
I think I came too late. Someone must have gotten rid of the information.
I believe the information is so that you can make your own reader.ok he can read the dyo but no write ^^ i must have a dyo writer no reader xD i must make a npc spawn but i can not =(
X Z Y
X Y Z
Just thought i would share something with all of you.
In xadets example code, the Y and Z axis's are mixed up.
It actually parses it in this order:
Code:X Z Y
Instead of:
Code:X Y Z
Also, I think that only the X and Y gets multiplied by 4.
Not sure about Z, but I will try out later.
The positioning is a tidy bit off, even when multiplying.
Just try it and you'll see. ^^
static void ReadObject(BinaryReader fh)
{
Console.WriteLine("Y Rotation: {0}", fh.ReadSingle());
Console.WriteLine("Axis Rotation: X: {0}; Y: {1}; Z: {2}", fh.ReadSingle(), fh.ReadSingle(), fh.ReadSingle());
Console.WriteLine("Position: X: {0}; Y: {1}; Z: {2}", fh.ReadSingle(), fh.ReadSingle(), fh.ReadSingle());
Console.WriteLine("Scale: X: {0}; Y: {1}; Z: {2}", fh.ReadSingle(), fh.ReadSingle(), fh.ReadSingle());
Console.WriteLine("Set AI: {0}", fh.ReadInt32() == 5);
Console.WriteLine("Object ID: {0}", fh.ReadInt32());
Console.WriteLine("Unknown: {0}", fh.ReadInt32());
Console.WriteLine("AI Type: {0}", (AIType)fh.ReadInt32());
Console.WriteLine("Unknown: {0}", fh.ReadInt32());
}
Console.WriteLine("Position: X: {0}; Y: {1}; Z: {2}", fh.ReadSingle(), fh.ReadSingle(), fh.ReadSingle());
X: 1739.609; Y: 100; Z: 802.9472
X: 6958.434; Y: 400; Z: 802.9472
1739.609; Y: 802.9472; Z: 100
X: 6958.434; Y: 3211.788; Z: 100