]> git.draconx.ca Git - upkg.git/blobdiff - src/uobject/uobject.h
uobject: Add a helper function to load objects from packages.
[upkg.git] / src / uobject / uobject.h
index 116b7835a259941aa2ac8ef7b1dbed75bfa23959..0d0d45c1692b2568da4655f369143d3786617866 100644 (file)
@@ -1,6 +1,6 @@
 /*
  *  upkg: tool for manipulating Unreal Tournament packages.
- *  Copyright (C) 2009 Nick Bowler
+ *  Copyright © 2009-2011 Nick Bowler
  *
  *  This program is free software: you can redistribute it and/or modify
  *  it under the terms of the GNU General Public License as published by
@@ -42,17 +42,18 @@ struct UObject {
 
        struct upkg *pkg;
        struct upkg_file *pkg_file;
-       unsigned long pkg_idx;
 };
 
 struct UObjectClass {
        GObjectClass parent;
 
-       int (*deserialize)(UObject *obj, struct upkg_file *f);
+       int (*deserialize)(UObject *obj);
 };
 
 GType u_object_get_type(void);
 
 int u_object_deserialize(GObject *obj, struct upkg *pkg, unsigned long idx);
 
+GObject *u_object_new_from_package(struct upkg *pkg, unsigned long idx);
+
 #endif