AggrorJorn Posted August 30, 2012 Share Posted August 30, 2012 I am trying to set the ZipstreamPassword but it keeps crashing. SetZipStreamPassword("assets.pak","2012"); I have made a zip file with password of the assets folders using winrar. Renamed the .zip to .pak. http://www.leadwerks.com/werkspace/topic/4379-using-pak-solved/page__hl__encryption Anything else I should add or change? Quote Link to comment Share on other sites More sharing options...
flachdrache Posted August 30, 2012 Share Posted August 30, 2012 I had no issues with using it in 2.31 - i dont remember if i had to set the default path to where the pak file actually is ... i have it setup like this : Initialize(); // RegisterAbstractPath("C:/Leadwerks Engine SDK/"); // Standalone : // copy archive of shaders/data into main and set values as needed. RegisterAbstractPath("./Data"); RegisterAbstractPath("./Media"); SetZipStreamPassword("Shaders.pak", "schlumperdingeryohoho"); TFramework fw = CreateFramework(); if( fw == NULL ) return FALSE; // Set Lua framework object SetGlobalObject( "fw", fw ); // Set Lua framework variable BP lua = GetLuaState(); // .... Quote AMD 64 X2 Dual 5k - 4GB - XFX GForce9800GT - nv196.21 - WinXP Sp3 zBrush4R2 - Silo2Pro - Unwrap3DPro - Gile - MaPZone2.5 Xxploration FPS in progress ... Link to comment Share on other sites More sharing options...
flachdrache Posted August 30, 2012 Share Posted August 30, 2012 iirc i couldnt stream the video and had to use a "media" folder for the .ogg but the "Data" bit is actually the data.pak while the "Shaders.pak" is where the exe is. I have that sample "boxed" and not all media in the folder e.g. cant simply rebuild and test it atm. Quote AMD 64 X2 Dual 5k - 4GB - XFX GForce9800GT - nv196.21 - WinXP Sp3 zBrush4R2 - Silo2Pro - Unwrap3DPro - Gile - MaPZone2.5 Xxploration FPS in progress ... Link to comment Share on other sites More sharing options...
Marleys Ghost Posted August 30, 2012 Share Posted August 30, 2012 I am trying to set the ZipstreamPassword but it keeps crashing. SetZipStreamPassword("assets.pak","2012"); I have made a zip file with password of the assets folders using winrar. Renamed the .zip to .pak. http://www.leadwerks..._hl__encryption Anything else I should add or change? Try using Winzip. Make sure .zip format is selected in Winrar Make sure the URL for the .pak is correct in relation to the .exe http://www.leadwerks.com/werkspace/topic/4488-pak-files-relative-to-exe/page__hl__setzipstream#entry39257 http://www.leadwerks.com/werkspace/topic/3435-exploring-of-setzipstreampassword/page__hl__setzipstream Quote AMD Bulldozer FX-4 Quad Core 4100 Black Edition 2 x 4GB DDR3 1333Mhz Memory Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5 Windows 7 Home 64 bit BlitzMax 1.50 • Lua 5.1 • MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro 3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET LE 2.5/3.4 • Skyline • UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0 Marleys Ghost's YouTube Channel • Marleys Ghost's Blog "I used to be alive like you .... then I took an arrow to the head" Link to comment Share on other sites More sharing options...
shadmar Posted August 30, 2012 Share Posted August 30, 2012 Aggror jut to check, does the pak work without any pw (just to rule that out) LE crashes hard if doesn't find a soundfile etc.. I was unable to create the asset.pak due to missing abstract in paths etc.. (lecp) Quote HP Omen - 16GB - i7 - Nvidia GTX 1060 6GB Link to comment Share on other sites More sharing options...
AggrorJorn Posted August 30, 2012 Author Share Posted August 30, 2012 Lets see without password - The assets.pak resides in the root like the exe. - I created a zip and then renamed it to pak. - Assets like textures get loaded correctly. When I try it again, only this time with a password, it crashes as soon as I reach SetStreaMPassword. And not just the game, visual studio also hangs itself. Quote Link to comment Share on other sites More sharing options...
Daimour Posted August 30, 2012 Share Posted August 30, 2012 Looks like a bug. It should work. Try to use simple password like "123" without special symbols. Try to use short project path like "c:\myproject". May be you use some custom version of engine DLL? Try to run engine.exe with start.lua with single command: SetZipStreamPassword("assets.pak","123") Quote Link to comment Share on other sites More sharing options...
Marleys Ghost Posted August 30, 2012 Share Posted August 30, 2012 I have used it in both Blitzmax and C++ (http://www.leadwerks.com/werkspace/topic/5185-leadwerks-25x-darkbasics-dark-ai/) recently and experienced no issues. Quote AMD Bulldozer FX-4 Quad Core 4100 Black Edition 2 x 4GB DDR3 1333Mhz Memory Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5 Windows 7 Home 64 bit BlitzMax 1.50 • Lua 5.1 • MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro 3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET LE 2.5/3.4 • Skyline • UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0 Marleys Ghost's YouTube Channel • Marleys Ghost's Blog "I used to be alive like you .... then I took an arrow to the head" Link to comment Share on other sites More sharing options...
AggrorJorn Posted August 30, 2012 Author Share Posted August 30, 2012 Looks like a bug. It should work. Try to use simple password like "123" without special symbols. Try to use short project path like "c:\myproject". May be you use some custom version of engine DLL? Try to run engine.exe with start.lua with single command: SetZipStreamPassword("assets.pak","123") Tried all of that, but doesn't seem to work. Thanks for the help though. Quote Link to comment Share on other sites More sharing options...
shadmar Posted August 30, 2012 Share Posted August 30, 2012 This worked for me in the r316 lecp build : (use after camera is created..) ... // get framework main camera _camera = GetLayerCamera(GetFrameworkLayer(0)); PositionEntity(_camera, Vec3(0, 0, -2)); //Loading the assets.pak SetZipStreamPassword("Assets.pak","lol99"); // add the first state and switch to it _stateMgr.AddState(new LogoState("logo", &_stateMgr)); _stateMgr.Switch("logo"); ... Quote HP Omen - 16GB - i7 - Nvidia GTX 1060 6GB Link to comment Share on other sites More sharing options...
AggrorJorn Posted August 30, 2012 Author Share Posted August 30, 2012 Awesome work Shadmar. I wonder how this works in the background though. If you would put it right after the switch state, it no longer works. Quote Link to comment Share on other sites More sharing options...
Josh Posted August 30, 2012 Share Posted August 30, 2012 There is no correlation between those functions, and no reason it should matter. Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Daimour Posted August 31, 2012 Share Posted August 31, 2012 If you would put it right after the switch state, it no longer works. Are you using any assets in LogoState? That may be a reason. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.