A collection of exported and imported objects.
Inheritance: Alexandria.Engines.Unreal.Core.Object
 public override object Read(object target, Package package, BinaryReader reader, long end)
 {
     return reader.ReadPlane3f();
 }
Ejemplo n.º 2
0
 /// <summary>Open a given package.</summary>
 /// <param name="name"></param>
 /// <returns></returns>
 public Package OpenPackage(string name)
 {
     foreach (var package in Packages)
         if (package.Export.Name == name)
             return package;
     foreach (var path in PackagePaths) {
         var fileName = path.Replace("*", name);
         if (FileManager.Exists(fileName)) {
             var package = new Package(this, fileName);
             Packages.Add(package);
             return package;
         }
     }
     throw new Exception("Package " + name + " could not be found.");
 }
 public override object Read(object target, Package package, BinaryReader reader, long end)
 {
     int count = UIndex.Read(reader); return reader.ReadBytes(count);
 }
 public override object Read(object target, Package package, BinaryReader reader, long end)
 {
     return package.ReadExport(reader);
 }
 public override object Read(object target, Package package, BinaryReader reader, long end)
 {
     return reader.ReadIndexCountArray<Vector3f>(reader.ReadVector3f);
 }
 public override object Read(object target, Package package, BinaryReader reader, long end)
 {
     return Bounds.Read(reader);
 }
 public override object Read(object target, Package package, BinaryReader reader, long end)
 {
     int offset = -1; return Statement.Load(package, reader, ref offset, end);
 }
 public override object Read(object target, Package package, BinaryReader reader, long end)
 {
     return reader.ReadIndexCountList(() => package.ReadNameValue(reader));
 }
 public override object Read(object target, Package package, BinaryReader reader, long end)
 {
     return AttributeDictionary.Load(package, reader);
 }
 public override object Read(object target, Package package, BinaryReader reader, long end)
 {
     return new Guid(reader.ReadBytes(16));
 }
Ejemplo n.º 11
0
 /// <summary></summary>
 public static InitialAllianceInfo Read(BinaryReader reader, Package package)
 {
     return new InitialAllianceInfo() { AllianceName = package.ReadNameValue(reader), Level = reader.ReadSingle(), Permanent = reader.ReadByte() != 0 };
 }
Ejemplo n.º 12
0
 /// <summary>
 /// Read the <see cref="PointRegion"/> from the <paramref name="reader"/>.
 /// </summary>
 /// <param name="reader">The <see cref="BinaryReader"/> to read the <see cref="Bounds"/> from.</param>
 /// <param name="package"></param>
 /// <returns>The new <see cref="PointRegion"/> object.</returns>
 public static PointRegion Read(BinaryReader reader, Package package)
 {
     return new PointRegion() {
         ZoneReference = package.ReadReference(reader),
         Leaf = reader.ReadInt32(),
         ZoneNumber = reader.ReadByte()
     };
 }
Ejemplo n.º 13
0
 public Reference(Package package, int index)
 {
     Package = package;
     Index = index;
 }