Adding A Zip

Irrlicht.Net is no longer developed or supported, Irrlicht.Net Cross Platform is a much more complete wrapper. Please ask your C# related questions on their forums first.
Locked
Joe_Oliveri
Posts: 448
Joined: Tue Oct 05, 2004 3:24 am
Location: Boston, MA

Adding A Zip

Post by Joe_Oliveri »

Well I have been trying this all day and I can't seem to get my code to work! I wrote it a long time ago using C++ when I started my game project! However I can't seem to get my mind to convert it into C# has anyone done this yet? The documents didn't help me really! Thank you...
Irrlicht Moderator || Game Designer
Learn the basics at </dream.in.code>
Zitzu
Posts: 28
Joined: Sun Jul 03, 2005 9:18 am

Re: Adding A Zip

Post by Zitzu »

Hi Joe, I'm not sure but... do you mean this?

Code: Select all

string path =@"..\..\media\" ;
IrrlichtDevice device =new IrrlichtDevice(DriverType.DIRECTX9,new Dimension2D(640,480),16,false,false,false);
Irrlicht.IO.IFileSystem fileSystem=m_device.FileSystem;

// is this what you're looking for?
m_fileSystem.AddZipFileArchive(path+"map-20kdm2.pk3");
I did a quick copy and paste so I hope I didn't forget anything! ;)

Ciao,
-Francesco

BTW: I am italian too! ;)
Joe_Oliveri
Posts: 448
Joined: Tue Oct 05, 2004 3:24 am
Location: Boston, MA

Post by Joe_Oliveri »

Thank you very much that is exactly what I'm looking for! :)
Irrlicht Moderator || Game Designer
Learn the basics at </dream.in.code>
Joe_Oliveri
Posts: 448
Joined: Tue Oct 05, 2004 3:24 am
Location: Boston, MA

Post by Joe_Oliveri »

ANd for those of you who would also like to see the code that you can just copy and paste into your project here you go!

Code: Select all

device.FileSystem.AddZipFileArchive("myzip.zip");
Irrlicht Moderator || Game Designer
Learn the basics at </dream.in.code>
Locked