Hi, I can’t quite figure out how the plugin works. I would like to open a level from our .pak file I have a pak file with a level in it and the gamemode, character and mesh
I would like to open the level and in the logic of things it should automatically load the gamemode, character… ?
But how to do this?
Hi, you first need to mount the pak file (See documentation). Then you can do anything as usual. Loading maps works with the function “OpenLevel”.Just found the C++ docs for that but there should be a blueprint node for it as well.
https://docs.unrealengine.com/en-US/…vel/index.html
Hi. I’ve bought this plugin a while ago, but never tried it. I just read the doc, and found an error. Page #2, Line #5:
Should probably be “true” …
Also, I know you said:
So I’m going to ask like this: Are you aware of any issue under Linux? And would you be ready to merge a patch, if there were issues, but someone was able to resolve them?
There were a few people saying the example did not work in 4.24/4.25. Were those problems resolved (at least, for 4.25)?
I’d like a “solution” that allows me to do DLCs and Mods using basically the same API (because I can test the “mod” API when I publish a DLC).
I don’t want the mods/DLCs to be built upon the “game source”, as a kind of diff/patch thing, as is usually done, and recommended by Epic.
I’ve looked into Epic’s new Modding API but the “custom editor” is a no-go for me. I don’t want my “modders” to have to build it from source (too complicated), and I probably can’t have the custom editor published to the “marketplace” since my game won’t be in the Epic store.
I think this plugin (assuming it works properly in the UE version I want to use, currently 4.25), would be a great “base” to build a DLC/modding API for my game. The doc says that the PAK themselves should be built as “content-only plugins”. Now, my question is the following:
Can I build a large content-library project, and then create multiple individual PAKs from it, for only a part of the assets?
As a concrete example, I am downloading the “megascan” free content (something like 1-2TB in total). My plan would be to use some of that, and other assets, to build a library of “ground textures”, and then distribute them (downsized!), as separate “DLCs”, like “mountain ground”, “desert ground”, … Without the possibility to create multiple “plugins” from the same project, I would have to first import everything in a “temporary” project, work out what goes where, and then import everything to “individual projects” a second time.
I was hoping I could do something like a big data-table that references all library assets, and then “filter” it into “individual tables” (mountains, desert, …), and create one PAK for each of those tables.
Hi there.
Fixed the typo.
It should work just fine on other platforms but my support for them might be limited as I don’t have Android/iOS development knowledge for example.
The plugin works on Linux. (Mounting a pak file) I’ve tested it in my own game Onset. But keep in mind that when you package a .pak file on Windows it probably won’t work on Linux because of shader compatibility. You might need to try with enabled Vulkan support.
The example projects for 4.25 and 4.26 have been updated on the description page already.
I just want to run Linux servers for multi-player games. The server needs to load the assets, to get the physics working, but doesn’t need to “display” them.
Hey,
I’ve been attempting to use this plugin with UE 4.25.4 for the last few days, with no luck, I’ve followed the documentation perfectly and checked the forum to check for anybody with the same issue. I’m successfully mounting a Pak file, but then no matter how I try to load a class from said file, it results in a fatal error. Logging is also not working(?). Here’s how I’m mounting the pak file (taken from example project):
- Enable Runtime Logging (path = content folder)
- Get the address to the pak file with a dialog box, (eg, “c:/users/person/documents/Modding.PAK”)
- Is it a valid PAK file? If yes, mount it
Filename = above path (this is always correct, I’ve checked). Mount path = blank.
- Has it mounted? If yes, Register Mount Point.
Mount Point = “/Modding/”. Content Path = “…/…/…/ProjectEscapeRedux/Plugins/Modding/Content/”
- Load Asset Registry File
Path = “…/…/…/ProjectEscapeRedux/Plugins/Modding/AssetRegistry.bin”
This works perfectly, no crashes. I can list out the registry for this path and all contents of my external pak file gets listed. Because logging isn’t working I’m listing everything to widgets on the screen (it’s in shipping mode so no print strings). Using “get files in pak directory” using this filename (…/…/…/ProjectEscapeRedux) works too, all gets listed. Here’s what I do next:
- Get all files in pak directory. For Each, check if it’s a .uasset file. If so, then get the file directory (from the for each statement) and attempt to "get pak file class " before casting to type “actor class” (impure cast). This results in fatal crash. I also tried “converting the filename to long package name” which also results in a fatal crash. Finally, I tried appending the package name (without the extension) to the mount point name (so it looks like “/Modding/ThisIsAMod”), then getting the class and casting, this doesn’t work either.
- I gave up on this approach, maybe I’m doing something wrong. Instead, I’ve got the asset registry by path ("/Modding/"), then for each one, I get the class (or asset, i tried both) convert to soft object reference, and cast it to the actor class type. This didn’t work, so I’ve grabbed each object in the foreach, “to soft object path”, then “load asset blocking”, and regardless what I do after that I get the fatal crash again (with no error message).
Please give me some light as to why it’s not working, the secondary issue of having no logging also doesn’t help. I just need to load the pak file, and get the reference to each blueprint found in the file (actor class), i can’t predefine what the files will be so it needs to be dynamic, without c++ if possible. Here’s the structure to the pak file, I’ve removed most to save space:
- LogPakFile: Display: Mount point …/…/…/ProjectEscapeRedux/Plugins/Modding/
- LogPakFile: Display: “AssetRegistry.bin” offset: 0, size: 1360 bytes
- LogPakFile: Display: “Content/Assets/Raingutter_a_c1.uasset” offset: 1433, size: 406 bytes
- LogPakFile: Display: “Content/ReallyCoolMod.uexp” offset: 214922, size: 614 bytes
- LogPakFile: Display: “Content/ShaderArchive-Modding-PCD3D_SM5.ushaderbytecode” offset: 217088, size: 26842 bytes
- LogPakFile: Display: “Metadata/DevelopmentAssetRegistry.bin” offset: 245760, size: 85260 bytes
After upgrading my entire project to 4.26.1 I had everything working within 5 minutes. Seems something isn’t working correctly in 4.25.4. Thanks anyways though, all good now. Question posted on the marketplace has also been removed.
Hi, did anyone make a patch to make it work with 4.27?
Apparently Epic made the destructor of FPakFile private which results in compile errors.
Hey @BlueMountainsIO,
Thank you for making this plugin, it is exactly we are looking for a while.
I have some mysterious issues when I was trying to use it, I hope you can help me to figure it out.
I have created several pak files and use UnrealPak.exe to checked them, then loaded skelatalMesh from the pak file, applied the skeletalMesh to my actor. As the result it worked pretty well. I saw everytime when I start my game, specific skeletalMesh has been applied to my actor.
Then something starts going crazy.
First without loading skelatalMesh from pak, I can play some animation on my actor. But with the changing of skelatalMesh from pak, my actor is not moving anymore.
Second, I also tried to load some animation seq from pak file and set my actor to play this animation (no skelatalMesh loading and changing), still the animation is not playing.
Third, I have checked the animation status using Animation–IsPlaying node, it is reported true. I have tried everything, set rate, set position, set mode, override animation data, nothing really helps here.
Last, I checked the animation I have loaded from pak file, get length gave the correct length in seconds.
Everything is tested with UE4.23 in my actor BP → event begin play. I am quite confident that all the pak file preparison and loading (mount file, register mount point, load reg file and get pak file steps are correctly handled)
Please let me know if you need more information from me and any ideas that I could try are welcome.
Thanks
Hi everyone, when I use the mount file node, my app crashes on android, do you have any idea what the problem is? Iam using unreal 4.25.4, thanks.
I met the same problem. Where can I download the demo project of this plugin for 4.27?
This looks amazing! Is there an early version of this for 4.18?
OR is it possible an 4.18 baked (but not encrypted) pak might be accessible using this in 4.22?
Does this actually allow you to load your old objects back in engine or does it just pass them through to the new bake? (I made my first game in 4.18, have non e of my old files but can access the pak with Gildors tools etc.)
Can this load Blueprints? Maps/Levels audio or? Into the Editor? meaning: Could one take their first game made in 4.18, (for which they long ago lost all the Editor Assets) and load everything into 4.22 (or 4.24…) then rebake the game with new music better lighting and a VR Pawn (for instance?)
THANK YOU!
Hi @BlueMountainsIO,
Bought the plugin a month ago for easy Pak loading and stuff. I know you haven’t promised anything yet for Mobile devices, but I would love to have this working for the same. While testing the plugin for IOS I had encountered a problem. If anybody could help me solve the issue, it would be great!
The problem is I can’t register the mount point in IOS device after mounting the pak file:
Something is failing at the pakprecacher code.
This is the error shown by the log file:
[UE4] [2021.11.28-14.37.18:056][122]LogBlueprintUserMessages: [DefaultPawn_BP_C_2147482535] file:/var/mobile/Containers/Data/Application/9A9E3962-79DA-418D-BB02-DB9FD8242646/Documents/Saved/pakchunk1001-ios.pak
[UE4] [2021.11.28-14.37.18:543][136]LogPakLoader: FPakLoader::FPakLoader()
[UE4] [2021.11.28-14.37.18:547][136]LogPakFile: PakFile PrimaryIndexSize=626
[UE4] [2021.11.28-14.37.18:548][136]LogPakFile: PakFile PathHashIndexSize=308
[UE4] [2021.11.28-14.37.18:548][136]LogPakFile: PakFile FullDirectoryIndexSize=1209
[UE4] [2021.11.28-14.37.18:548][136]LogShaderLibrary: Display: ShaderCodeLibraryPakFileMountedCallback: PakFile ‘/var/mobile/Containers/Data/Application/9A9E3962-79DA-418D-BB02-DB9FD8242646/Documents/Saved/pakchunk1001-ios.pak’ (chunk index 1001, root ‘…/…/…/TestingFirebase/Content/’) mounted
[UE4] [2021.11.28-14.37.18:550][136]LogMetal: Display: No .metalmap file found for global_chunk1001_sf_metal!
[UE4] [2021.11.28-14.37.18:551][136]LogMetal: Display: Failed to create library: Error Domain=MTLLibraryErrorDomain Code=6 “library not found” UserInfo={NSLocalizedDescription=library not found}
[UE4] [2021.11.28-14.37.18:552][136]LogPakFile: OnPakFileMounted2Time == 0.003340
[UE4] [2021.11.28-14.37.18:552][136]LogBlueprintUserMessages: [DefaultPawn_BP_C_2147482535] Mounted File
[UE4] [2021.11.28-14.37.18:553][136]LogStreaming: Display: FlushAsyncLoading: 1 QueuedPackages, 0 AsyncPackages
[UE4] [2021.11.28-14.37.18:553][136]LogPackageLocalizationCache: Processed 1 localized package path(s) for 1 prioritized culture(s) in 0.000065 seconds
[UE4] [2021.11.28-14.37.18:553][136]LogOutputDevice: Warning:
[UE4] Assertion failed: PakPrecacherSingleton [File:/Users/build/Build/++UE4/Sync/Engine/Source/Runtime/PakFile/Private/IPlatformFilePak.cpp] [Line: 1462]
[UE4] [2021.11.28-14.37.18:553][136]Assertion failed: PakPrecacherSingleton [File:/Users/build/Build/++UE4/Sync/Engine/Source/Runtime/PakFile/Private/IPlatformFilePak.cpp] [Line: 1462]
[UE4] [2021.11.28-14.37.18:556][136]LogGenericPlatformMisc: FPlatformMisc::RequestExit(1)
The plugin is kept as a project plugin and I have whitelisted IOS and Mac in the uplugin file.
Would be cool if someone can help me to solve this issue as we have IOS as one of our main targeted platforms.
Maybe it’s a problem with materials?
LogMetal: Display: No .metalmap file found for global_chunk1001_sf_metal!
Is Share Material Shader Code disabled in the project settings?
This also looks suspicious. Did you google for that?
LogMetal: Display: Failed to create library: Error Domain=MTLLibraryErrorDomain Code=6 “library not found” UserInfo={NSLocalizedDescription=library not found}
Hi,
You are right about the share Material Shader code setting. Thanks. I got those two errors gone. But the app is still crashing, and it still points to the line 1462 of IPlatformFilePak.cpp [pakprecacher]. The thing is I can turn this (pakprecacher) off in engine code, but then I have to build the entire engine again, which may also cause problems in future.
Is there a way to call individual objects like skeletal meshes or static meshes without setting a mount point. I also tried the c++ mount point function of unreal, which ended up in the same crash as the plugin. This means if I can bypass the mount point function somehow, may be things could go well. I believe we don’t need a mount point for opening a level, which is great. I just need a way to get individual objects from pak file.
Thank you.
Mounting a pak file is required, otherwise the engine doesn’t know anything about the pak obviously. Yes, calling the engine functions directly will result in the same problem as this plugin is a wrapper around them so people can use them in blueprints without C++ knowledge.
Is it 4.27? What you can do is reporting the engine crash to Epic. Or maybe ask someone else here who has used iOS with the same engine version.
Hi,
The problem is I can mount the Pak file in IOS, I just couldn’t register the mount point [Boolean returns true for mounting]. I just want to bypass registering the mount point, not the mounting process. Is there any way for that. Also, you are right about Unreal’s function causing the crash. Only someone who has made it work in IOS or epic can help with that. Thanks for helping out.
Thanks.
Hi! I have a very simple question regarding the basic usage and mounting points. I did read all the docs but I still fail to understand this part:
Creates a link between a root path and a package content path (mount point).
This is required to make references between assets work. Should be called after mounting a pak.
@RootPath: Top content folder name of where your assets are in (Example: /TestDLC/).
@ContentPath: The path inside a pak to where the RootPath should point to. (Example:
../../../TestProject/Plugins/TestDLC/Content/)
void RegisterMountPoint(const FString &RootPath, const FString &ContentPath);
Can you give a practical example here? I,for example don’t understand why and if I alway have to specifcy the content path with ‘…/…/…/’ .Why? This is relative to what? Also what is RootPath here? Root content path in the project" ? Like, ‘Content’? If I build my pak not from a plugin but from the content directories in the project itself,then how does it look like? I mean, your docs don’t explain some very important stuff. It also would be nice to have in the example project you provide the pak project too,so we can see how it is structured.
Hi! Please see this image on how it works.
It’s just how it works in Unreal. Without registering a mount point the engine doesn’t know the root path of your mounted plugin.
The ContentPath is the mount point of the pak file + the further part to your “Content” folder.
I’ve also updated the documentation to reflect this.
It also would be nice to have in the example project you provide the pak project too,so we can see how it is structured.
What do you mean exactly? The example project contains the project to load the TestDLC.pak which is included as well.