Hard Light Productions Forums
Off-Topic Discussion => Programming => Topic started by: blackhole on November 11, 2009, 03:46:55 am
-
Undocumented features are so nice. Like this little one in Raknet where ALMOST NOTHING F*CKING WORKS IF YOU COMPILE IT AS A DLL
*screams in rage*
I would really appreciate it if they actually mentioned this somewhere instead of making you believe that you can use more then the bare-bones functionality in the DLL.
-
In what way doesn't it work?, and it sounds like there's been a mistake in linking.
-
well what happens is that it's been exported with __declspec(dllexport) but not imported with __declspec(dllimport), which means you can't create any of the classes inside your DLL or it'll explode when you try to delete them. Hence you have to use the built in factory class to build and destroy the classes for you. Said factory only actually lets you build/create about 15 classes, so if you use any other class, your f*cked >C
-
or you can let yourself have a memory leak, or do something really crazy like manual memory management.
-
or you can let yourself have a memory leak, or do something really crazy like manual memory management.
I'm not sure if even that would work, because it would likely choke up when you manually invoked the constructor/destructor.
-
only one way to find out.
-
only one way to find out.
Or I could just use the static lib.
-
Make a dll out of the lib?
-
Make a dll out of the lib?
I could switch over the code to __declspec(dllimport), which would take something like 2 hours.
...or I could just use the static lib. :p
-
oh, your no fun at all
-
oh, your no fun at all
Not yet :p