x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Async load in string format

I'm trying to figure out what string format should be for async loading. FStreamableManager::RequestAsyncLoad take an const TArray<FSoftObjectPath>& TargetsToStream argument. Following functions calls into the engine i found function FStreamableManager::StreamInternal with the same argument and following code.

             // We always queue a new request in case the existing one gets cancelled
             FString Package = TargetName.ToString();
             int32 FirstDot = Package.Find(TEXT("."));
             if (FirstDot != INDEX_NONE)
             {
                 Package = Package.Left(FirstDot);
             }
 
             Existing->bAsyncLoadRequestOutstanding = true;
             Existing->bLoadFailed = false;
             LoadPackageAsync(Package, FLoadPackageAsyncDelegate::CreateSP(Handle, &FStreamableHandle::AsyncLoadCallbackWrapper, TargetName), Priority);

It takes everything before first dot and tries to load it instead, using full name for callback it seems. Next function int32 LoadPackageAsync(const FString& InName, const FGuid* InGuid, const TCHAR* InPackageToLoadFrom, FLoadPackageAsyncDelegate InCompletionDelegate, EPackageFlags InPackageFlags , int32 InPIEInstanceID, int32 InPackagePriority) where InName is a chunk of my actual string and nPackageToLoadFrom always nullptr, since it's looking for some variable in FAsyncPackage class i don't have access to. What I'm trying to achieve is to mount pak file, read map asset and load it. That wasn't going to well so i thought i'd to simply load asset first.

Product Version: UE 4.18
Tags:
more ▼

asked Apr 02 '18 at 12:20 PM in C++ Programming

avatar image

MrMcKvarz
241 2 6 15

avatar image MrMcKvarz Apr 05 '18 at 03:55 PM

In FPackageName when loading function FindPackageFileWithoutExtension check if file exist on disk by asking platform specific code for time stamps. Mounted files does not exist in the mounting point as i expected them to be, but function IterateDirectoryRecursively show that they exist in the mounting point.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

What I tried to do was to load pak file from another project, and that is something not supported.

more ▼

answered Mar 20 '19 at 10:43 AM

avatar image

MrMcKvarz
241 2 6 15

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question