You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
#lockdown Nick.Penwarden #rb none ========================== MAJOR FEATURES + CHANGES ========================== Change 3284469 on 2017/02/02 by Saul.Abreu Fixed comment on Slate Brush for getting the resource object and what kind of object it may be. Change 3284410 on 2017/02/02 by Ben.Zeigler Add FSlateBrush subclass constructors that take resource objects, to create static brushes at startup time that refer to already loaded UTextures Change 3284381 on 2017/02/02 by Saul.Abreu #fortnite Added functionality to common button to actually use the single material brush setting and automatically create and expose access to a material instance dynamic. Also fixed some potential object lifetime issues in CommonButton. Change 3282423 on 2017/02/01 by Ben.Zeigler Fix issue with synchronous load of objects not invalidating cached nulls for asset ptrs. This was always an issue but my recent change to assetptr SynchronousLoad made it manifest more often. In the future we may want to invalidate cached nulls on object creation to handle cases like save games Change 3282265 on 2017/02/01 by Ian.Fox #UE4, #XMPP - Reduce verbosity of strophe receive-stanza log Change 3282159 on 2017/02/01 by Ben.Zeigler Fix issue where async loading null string reference would deadlock Change 3282054 on 2017/02/01 by James.Longstreet #fortnite #jira FORT-28234 Fix sceImeDialogTerm() warning We were calling sceImeDialogTerm() in cases where the dialog wasn't active. The only state it's legitimate to call sceImeDialogTerm() in is SCE_IME_DIALOG_STATUS_FINISHED. Change 3282051 on 2017/02/01 by James.Longstreet #fortnite #jira FORT-30021 Respect bVirtualKeyboardSendsTextChanged on PS4 Change 3281799 on 2017/02/01 by Nick.Cooper #Fortnite - Removed code on PS4 that was adding a EMouseButtons::Left press when the right shoulder button was pressed #jira FORT-35821 Change 3281771 on 2017/02/01 by Lukasz.Furman fixed end of path conditions breaking movement when path starts with a navlink and turn back below #jira FORT-36375 Change 3280579 on 2017/01/31 by Ben.Zeigler Remove ForEachProperty and switch AssetManager to use TPropertyValueIterator instead. Code review changes to TPropertyValueIterator. Add InitializeAssetBundlesFromMetadata to AssetManager which parses AssetBundles metadata at load/save time and uses that to assign asset references to specific bundles. Add RecursivelyExpandBundleData to allow recursively acquiring bundle dependencies. Add AssetBundles to the PropertyMetadata list. Sorted list and fixed some comment typos. Change it so the DataAsset factory won't show blueprintable native classes as valid, the editor doesn't like it when you have both blueprinted and non-blueprinted assets of the same base class. Change AssetPtr.LoadSynchronous to be const and to behave the same as Get(). This was a licensee complaint and the old behavior to null out the reference because of a transient load error can cause data loss. Change 3280176 on 2017/01/31 by Lukasz.Furman fixed missing navmesh update on replacing existing floor/roof #jira FORT-36369 Change 3279761 on 2017/01/31 by Saul.Abreu #fortnite Added ability to keep common buttons interactable even when they're selected, so they can still be clicked. Old default behavior is preserved. Change 3279678 on 2017/01/31 by Saul.Abreu #fortnite Moved GetCurrentInputType from UCommonActionWidget to UCommonUIContext for reuse. Change 3278593 on 2017/01/30 by Ben.Zeigler Delay initialization of asset registry tag filter list until it is needed, to make sure it catches modules that were loaded after the asset registry module. Fixes issues with tags not inherting to child classes Change 3278592 on 2017/01/30 by Ben.Zeigler Add TPropertyValueIterator to replace ForEachProperty. This is a recursive iterator instead of a predicate search, and also allows extracting the property chain, which I need for metadata parsing. AssetManager has an example of both uses, will delete ForEachProperty tomorrow. Change 3277859 on 2017/01/30 by Lukasz.Furman fixed navigation path postprocessing not working with vertical navlinks near start point required by taker portal up move #jira FORT-36570 Change 3277580 on 2017/01/30 by Ben.Zeigler #jira FORT-36662 Return streamable manager to always use hard references, weak references do not work during AddReferencedObjects at all, because of the unreachable flag that is set during GC. This returns the behavior of forcing assets to be "Force Deleted" if they were loaded by asset manager. Change 3276903 on 2017/01/29 by Bob.Tellez #BlueprintContext Updated copyright notice for 2017 Change3276902on 2017/01/29 by Bob.Tellez #CommonUI Updated some missed copyright notices for 2017 Change 3276731 on 2017/01/29 by Jeff.Campeau Forward modified warning messages Change 3276642 on 2017/01/28 by Jeff.Campeau Change specific errors from packaging multiple configurations into a single package into warnings. Change 3276228 on 2017/01/27 by Ben.Zeigler Fix crash/data loss when a Pin's DefaultObject points to an ObjectRedirector. FixObject will return redirectors so you need to correct for that Change 3276073 on 2017/01/27 by Ben.Zeigler Add some utility functions to core asset manager and streamablemanager and fix various editor interactions. Add startup and cook interaction hooks to AssetManager directly and call them form Engine in addition to the game-specific hooks. Add concept of BulkScanning to AssetManager, use this when scanning many directories. Fix issues with string asset references being wrong for blueprint classes, this would be easier if the assetdata pointed to the class and not the possibly-missing blueprint. Change StreamableManager to keep referenced objects as weak pointers. These pointers are effectively soft in the editor, hard outside of the editor. By storing them as raw pointers it was difficult to guarantee their safety without causing issues with deleting assets. Change 3276058 on 2017/01/27 by Ben.Zeigler Add UStruct::ForEachProperty, which recursively iterates properties of a struct and calls a lambda. Add some new BaseStructure accessors Change 3275981 on 2017/01/27 by Alex.Thurman Move Item Management Screen input handling into child activatable panels. #JIRA FORT-35759 #JIRA FORT-35758 Change 3275626 on 2017/01/27 by John.Pollard First pass at implementing net relevancy for replays * All connections are considered when determing if an actor is relevant * Enable by setting demo.UseNetRelevancy to 1 * Override cull distance with demo.CullDistanceOverride Change 3275221 on 2017/01/27 by John.Pollard FORT-36482 - Fix issue with using wrong serializer for re-mapping objects Change 3274149 on 2017/01/26 by Alex.Thurman Expose the Common Widget Switcher as part of the common UI plugin library. #fort Change 3274103 on 2017/01/26 by Michael.Trepka Fixed a crash on startup on Mac when using a shader cache populated during cooking and re-enabled cook time cache generation in Fortnite Change 3273867 on 2017/01/26 by James.Hopkin Enabled Stomp for PS4 #jira FORT-35517 Change 3273749 on 2017/01/26 by James.Hopkin Added libwebsocket libraries for PS4 #jira FORT-35517 Change 3273105 on 2017/01/26 by James.Hopkin Moved libwebsockets.h into platform-specific folders (in preparation for PS4 building against slightly more recent version) Change 3273020 on 2017/01/26 by Jeff.Campeau Stage manifest files from loose folder, not binary folder (appdata.bin is no longer created in the binary directory) Change 3272825 on 2017/01/25 by Saad.Nader #fort Added function to set the auto activation on or off on a common widget switcher. Updated CommonTabListWidget to temporarily turn off activation when setting a linked switcher. Added some missing delegate cleanup code. Change 3272598 on 2017/01/25 by Justin.Augspurger #fortnite Add activatable panel function that returns if an input handler is set. Change 3272411 on 2017/01/25 by Michael.Trepka Increased g.TimeoutForBlockOnRenderFence on Mac to 5 minutes Change 3271913 on 2017/01/25 by Lukasz.Furman fixed conditions of movement's destinaiton oveshot check to work with setup in FTest maps #jira FORT-36375 Change 3271723 on 2017/01/25 by Bob.Tellez #UE4 Disabled MfMedia on windows. Change 3271223 on 2017/01/25 by Jeff.Campeau Allow packaging to fall back to the engine directory for the lastchunk file if it's not present in the staged version. Change 3271066 on 2017/01/24 by Chris.Gagnon - Properly clean up the UIManager and Analog Cursor when game/pie exists. - FortAnalogCursor now sequesters the mouse during InputSuspension. - Change the callback order for activate and deactivate so the classes can chain activate. Change3271064on 2017/01/24 by Chris.Gagnon - NavigateToWidget() added to SlateApplication - SlistView and it's descendants now have the ability to navigate to the widget scrolled into view Change 3270778 on 2017/01/24 by Michael.Trepka Fixed and enabled cook time binary shader cache generation for Mac Change 3270645 on 2017/01/24 by Jeff.Campeau - New manifest generation (backward compatible) - True support for multiconfig packages - Settings all based in target settings in editor - Localized package resources with support to reduce redundancies - Resource table generation and manifest generation combined - Further reduced unneeded deploy copies #jira FORT-36413 Change 3270191 on 2017/01/24 by Lukasz.Furman reverted file unrelated to DecoyDistance fix Change 3270133 on 2017/01/24 by Lukasz.Furman fixed item scoring in DecoyDistance test #jira FORT-36034 Change 3269363 on 2017/01/24 by James.Hopkin #online #stomp Added error logging for loss of heartbeat #jira FORT-34763 Change 3268921 on 2017/01/23 by Saul.Abreu #fortnite Renamed CommonWidgetGroup to emphasize that it is an abstract base class. Added ability to get the selected button out of CommonButtonGroup. Change 3268913 on 2017/01/23 by Saul.Abreu #fortnite Recreated some minor changes to UEnumProperty so that TMap properties don't assert with enums as keys. Change 3268436 on 2017/01/23 by Michael.Trepka Added rhi.Metal.AllowRHIThread to allow games to disable RHI thread on Mac to be able to use shader cache, which currently is incompatible with RHI thread. Disabled RHI thread on Mac in Fortnite. Also, temporarily disabled Metal validation layer in Fortnite until I have more information on the cost of various levels of validation. Change 3266945 on 2017/01/20 by Bob.Tellez #UE4 Allowing more configurations to generate debug symbols Change 3266814 on 2017/01/20 by Bob.Tellez #UE4 Moved MfMedia video track handling to the render thread, which removes the need for some buffer management in MediaTextureResource.cpp. Also, Mfmedia now emits the PlaybackEndReached event. #JIRA FORT-31753 Change 3266541 on 2017/01/20 by Lukasz.Furman moved navigation export of building actor's static mesh into owning actor data instead of using parent chain, attempt to fix husks passing through walls that lost navigation data at some point during game #jira FORT-35741 Change 3266269 on 2017/01/20 by Fred.Kimberley Change async loading of gameplay cues so that the gameplay cue manager maintains ownership of the assets and can control their lifetime. Change 3266053 on 2017/01/20 by Michael.Trepka Fixed issues with shader cache not working properly with Mac Metal (but it still requires -norhithread to work at all). Enabled the shader cache by default if RHI thread is disabled. Change 3265585 on 2017/01/20 by Bart.Hawthorne Enable Oodle in Fortnite Change 3264678 on 2017/01/19 by Lukasz.Furman fixed crash on opening behavior trees with invalid decorator class (empty redirectors) #ue4 Change 3264473 on 2017/01/19 by Fred.Kimberley Tell the streamable manager to manage gameplay cue assets that are async loaded. #jira FORT-35171 Change 3262846 on 2017/01/18 by John.Pollard FORT-30352 - Fix by lowering network logging verbosity for benign condition Change 3262535 on 2017/01/18 by Michael.Trepka Fix for FORT-35776 Make sure to set reasterizer state when rendering with a material in FSlateRHIRenderingPolicy::DrawElements Change 3262386 on 2017/01/18 by John.Pollard Deprecate bPendingNetUpdate, NetUpdateTime and LastNetUpdateTime Change 3262375 on 2017/01/18 by Ian.Fox #UE4, #XMPP - Handle Message stanza errors #JIRA OGS-505 Change 3262262 on 2017/01/18 by John.Pollard Turn on adaptive network updates by default Change 3262215 on 2017/01/18 by Rob.Cannaday Fix for returned XMPP messages (to invalid recipient) triggering on message received delegates Change 3262094 on 2017/01/18 by Jamie.Dale Cook on the fly builds now resolve string asset references Change 3262091 on 2017/01/18 by Jamie.Dale Guarding against potentially invalid call to FString::Mid Change 3262089 on 2017/01/18 by Jamie.Dale Fixing RedirectCollector issues with projects outside the UE4 directory It was storing relative paths, but MakeStandardFilename wouldn't make a relative path for anything outside of the UE4 directory. In addition to this, some code was testing filters using package style paths, so I converted all the code to use package style paths instead. Change 3261201 on 2017/01/17 by Ben.Zeigler Perf improvements to PackageName that improve cooked load times by around a second. These string functions get called very often and Split is very slow, especially backwards searching or case insensitive. Change 3261098 on 2017/01/17 by John.Pollard Fix for FORT-35711 - Edited buildings do not always replicate correctly We were removing the actor from the network object list too soon Change3260515on 2017/01/17 by John.Abercrombie Fix MoveTo task ending with success when it's interrupted - Default the task to an invalid status rather than assuming we are successful #jira FORT-35497 - Defender can pick up a weapon from far away as they get knocked DBNO Change 3260343 on 2017/01/17 by Lukasz.Furman fixed end of path conditions for crowd simulation when using string pulled path #jira FORT-35713 Change 3259419 on 2017/01/16 by John.Pollard Network actor list fixes: * Don't add add actor to network list if it will just immediately get removed * Remove destroyed actors from actor list on clients * Make sure actor Role is set to correct value before adding to network actor list Change 3259104 on 2017/01/16 by Michael.Trepka Change the default for rhi.Metal.RuntimeDebugLevel to 2, as 3 is too expensive for Development builds and disable METAL_DEBUG_OPTIONS in Test builds Change 3259017 on 2017/01/16 by Saad.Nader #fort Added a missing remove delegate handler when widget is destructed. Change 3258901 on 2017/01/16 by Saad.Nader #fort Added the ability to remove an input action from the list of actions we are listening for in an activatable panel. Change 3258844 on 2017/01/16 by Ryan.Rauschkolb #fortnite Fixed issue where UUMGSequencePlayer:Tick would broadcast OnAnimationFinished before the final frame of the animation plays Change 3258734 on 2017/01/16 by Michael.Trepka Fixed a crash on exit on Mac in FCocoaWindow's windowWillResize: #jira FORT-35720 Change 3258353 on 2017/01/16 by James.Hopkin #xmpp Fixed UserJid constructor to be constructed by value - same efficiency, less code and allows any combination of rvalues and lvalues. Change 3257640 on 2017/01/13 by Saul.Abreu #fortnite #jira FORT-35387 Item Quantity List widget, not yet complete. Minor tweak to widget factory (for pooling) to support player controllers as "outer"s. In progress refactor of list of resources given for a mulch operation, using the item quantity list widget. Change 3257310 on 2017/01/13 by Bob.Tellez #UE4 Default stack size for windows is now configurable. There is a different number for windows editor targets than non-editor targets. Change 3257094 on 2017/01/13 by John.Pollard Refactor network actor list management to be more efficient * Move dormancy list management to FNetworkObjectList * Optimize actor network dormancy by removing actors from the active list that are dormant on all connections * Removed NetUpdateTime on actor, and now use the NextUpdateTime on FNetworkObjectInfo (these values are more hot in the cache too) * We now early out of the consider logic faster when possible * Remove other misc unused network state/code and general cleanup Change 3255891 on 2017/01/12 by Chris.Gagnon Added "Back" action to squads screens and armory landing. Added activation widget centering for squads screens. Added a couple Explicit navigations to get a better navigation experience. Added a bunch of Fkeys to the input binding table. Added PanelButton Widget. Change 3254809 on 2017/01/11 by Bob.Tellez #UE4 Crash fix for shader views that get destroyed but still have pointers to them in the SRV cache. Change 3254651 on 2017/01/11 by Bob.Tellez #UE4 Changed MfMedia track sync mode to Unbuffered since buffered causes a crash shortly after playing. #JIRA FORT-35566 Change 3254307 on 2017/01/11 by Lukasz.Furman fixed "Ftest start" command interfering with automation passes #jira FORT-35459 Change 3253625 on 2017/01/11 by Lukasz.Furman more accurate overshot detection for crowd simulation trying to reach last path corner #jira FORT-35502 Change 3252864 on 2017/01/10 by Lina.Halper fix for invalid anim curve issue when duplicating curves. #jira: FORT-35151 Change 3252427 on 2017/01/10 by Ben.Zeigler #jira UE-40390 Fix crash saving blueprint with an inherited DataTable/CurveTable reference. Delta serialization meant that the necessary name wasn't in the name table, so adding it manually now. Copied from CL #3252418 Change 3252344 on 2017/01/10 by Lukasz.Furman added navmesh tile observation to hotspots now they will be able to reevaluate unreachable slots if nearby navmesh is updated (active only when more than half melee slots is unreachable) #jira FORT-35450 Change 3251644 on 2017/01/09 by Saul.Abreu #fortnite #jira FORT-35388 Refactored common input so that the actions hold the per-platform key mappings. A config file holds the mapping of individual keys to their per-platform display data (icon-only for now). ALL ENTRIES IN THE INPUT ACTION DATA TABLE ARE NOW MISSING THEIR KEYS. RE-ADD THEM. I did test that it works. Change 3251118 on 2017/01/09 by David.Hamm Corrected ability system logging messages that are turning up in bug reports. Change 3250932 on 2017/01/09 by Bob.Tellez #UE4 Unshelved from DanielW. Fix for memory usage during map save for large maps Change 3250093 on 2017/01/06 by Jeff.Campeau libstrophe UE4 modifications Change 3249787 on 2017/01/06 by John.Pollard Add some replay/network stats Change 3248808 on 2017/01/05 by Chris.Gagnon Fix for ensuring Main Tabs properly activates it's content. Includes a pretty hacky delay, will need to deal with that at somepoint. Change 3248693 on 2017/01/05 by Chris.Gagnon NavigationEvent now gets populated with the modifier keys so that Shift and Ctrl behaviors of the list work. Change 3248647 on 2017/01/05 by Saul.Abreu Fixed shadowed variable warning in Create Event node. Change 3248358 on 2017/01/05 by Saul.Abreu Added return type/outputs to the signature displayed in the CreateEvent node. Also added tooltip describing the syntax for display since it's non-standard. Change 3247937 on 2017/01/05 by Chris.Gagnon - Refactored the Custom Navigation Event to be a part of the Viewport so that it functions properly with Multi PIE and doesn't interfere with the Editor while PIE is running. - Added the ability for an FReply to specify an explict navigation attempt directly. - Added ENavigationGenesis to the navigation system allowing SListView and STileView's bHandleGamepadEvents functionality to be hooked up again. Change 3247887 on 2017/01/05 by Bob.Tellez #UE4 UpdateExistingPackagePriorities does not work in EDL. It is now disabled. #JIRA FORT-35193 Change 3247770 on 2017/01/05 by Fred.Kimberley Fix an issue where PreAttributeBaseChange was not always being called and sometimes called after the attribute base value had changed. Change3247133on 2017/01/04 by Saul.Abreu UWidget designer method renaming to avoid extremely likely naming collisions. Change 3246507 on 2017/01/04 by Chris.Gagnon Created CommonBorder and UCommonBorderStyle very simple but will allow consistent sharing of styles. Cleaned up palette category usage and a few misc things. Updated the UI test material, and created a UI Test BorderStyle to utilize it. Change 3245517 on 2017/01/03 by Chris.Gagnon Copying over slate material changes to provide more functionalit. Added a UITest Material as an example Change 3245371 on 2017/01/03 by Lukasz.Furman fixed husks attacking props from far away #jira FORT-34655 Change 3245363 on 2017/01/03 by Justin.Sargent Tracked down a CEF viewport scaling issue to some changes made for supporting high DPI. After talking it over with Trepka, we decided to revert the specific change causing the CEF viewport regression. Trepka will be following up with a proper fix. #jira OPP-6513 Change 3244525 on 2017/01/02 by Chris.Gagnon Activatable panels now clear out action handlers when the slate widgets are released. Change 3244517 on 2017/01/02 by Chris.Gagnon New frontend major refactors. - New content api for UI States - New intro / outro functionality for activatable panels - New CommonWidgetStack widget - Landing pages - Navigation suport for SListView, STileView - Navigation changes - Lots of New UI layout changes and functionality changes - More things that I'm forgetting Change 3242434 on 2016/12/21 by Ben.Zeigler Improve package saving time by stopping export sorting from recursing into dependencies outside of the package. It has no control over them so it doesn't care about their load order. Change 3242433 on 2016/12/21 by Ben.Zeigler Small perf improvement for quad tree, stop it from constantly reallocating memory when removing nodes as they will likely get filled again or the node will get deleted Change 3242294 on 2016/12/21 by Bob.Tellez #UE4 Re-applying the fix for rendering editor primitives when r.EarlyZPassOnlyMaterialMasking is enabled Change 3241034 on 2016/12/20 by John.Abercrombie Add or UpdateBlueprintSearchMetadata when we don't have a TargetPlatform - Better fix for issue mentioned in CL 3241023 Change 3241023 on 2016/12/20 by John.Abercrombie Fixed UBlueprint::PreSave crashing when there is no TargetPlatform (default behavior) Change 3240988 on 2016/12/20 by Lukasz.Furman fixed melee defenders not finishing move then their goal is outside tether range #jira FORT-34673 Change 3240966 on 2016/12/20 by Ben.Zeigler Disable find in blueprint query when cooking for non editor platforms, saves around 50 seconds off of a Fortnite fast cook. UBlueprint::PreSave gets called even though they get filtered out of cooked builds, as the filtering is after PreSave. Change 3240898 on 2016/12/20 by Lukasz.Furman fixed memory corruption in template A* solver #fortnite Change 3239920 on 2016/12/19 by Ben.Zeigler Fix warning display for string asset references while cooking, now that failed to find errors add to KnownMissing, we need to check KnownMissing before doing the find, and turn off the internal warnings as the redirect collector has more context info Change 3239819 on 2016/12/19 by Lukasz.Furman fixed uninitialized debug draw delegate pointers #ue4 Change 3238789 on 2016/12/16 by Ben.Zeigler Fix issue where spawned cues triggered from async loads wouldn't have a proper world Fix issue where bShouldSyncLoad/bShouldAsyncLoad were backwards Change 3238782 on 2016/12/16 by Ben.Zeigler #jira FORT-34825 Fix issue where Macro CDOs had corrupted persistent ubergraph frames during blueprint compile on load, by changing it so no CDOs have persistent frames. This also saves memory as using persistent frames is incorrect for CDOs, things like latent functions do not make sense. Fix from Dan O'Connor Change 3238685 on 2016/12/16 by Bob.Tellez #UE4 Graceful recovery for actors that changed mobility between frames in TextureInstanceManager. #JIRA FORT-34833 Change 3238671 on 2016/12/16 by Ben.Zeigler Fix ensure opening widget palette view, it was trying to create asset data for trash classes becuase it was just doing a raw class iterator, which is no longer supported. Change 3238606 on 2016/12/16 by Rob.Cannaday Fix crash in FInternetAddrBSD::SetIp when InAddr is an empty string. #jira FORT-34826 Change 3238594 on 2016/12/16 by Ben.Zeigler #jira FORT-34704 Fix bNetTemporary actors to be created with reliable packets, to keep sending until their initial send is done. The code that used to resend incomplete net temporary actors appears to have stopped working sometime during UE4 networking refactors. Remove unused flags related to that code Change3238315on 2016/12/16 by Lukasz.Furman fixed composite navigation path usage for husks not controlled by crowd simulation #jira FORT-34509 Change 3238145 on 2016/12/16 by Lukasz.Furman fixed crash in EQS profiler #jira FORT-34831 Change 3237479 on 2016/12/15 by Ben.Zeigler Don't crash if cue manager has no world, not sure how it got into this state Change 3236992 on 2016/12/15 by Michael.Trepka Don't fall back to SM4 on Intel GPUs on Mac any more Change 3236929 on 2016/12/15 by Bob.Tellez #UE4 Fixed an ensure that was caused by an FResourceSizeEx being initialized with the wrong type Change 3236867 on 2016/12/15 by Bob.Tellez #Fortinte Submitted change from Gil to fix EDL crash loading into Outpost on PS4 #JIRA FORT-34794 Change 3236747 on 2016/12/15 by Ben.Zeigler Fortnite fixes for asset manager/async loading changes FortItemDefinitions now async load needed assets on demand. Currently this is only loading AttributeTemplate, which may not even be in use The blueprints needed for weapons are now async loaded when the player puts them on their quickbar, instead of being loaded once and staying in memory forever FortAssetManager is now being used in parallel to the loading code in FortGlobals, I will remove the FortGlobals code in the next checkin once I know things are working Change it so the MissionEventNames are loaded asynchronously when clicking the picker, this code was half completed already so I finished it up Change it so GameplayCueNotifies get async loaded on demand instead of async loaded at startup, this improves startup load times Change it so the CommonUIModule uses the global assetmanager instead of a passed in StreamableManagerHandler Item json changed because it got resorted, no actual json changes other than a few cosmetics that were added yesterday Change it so FortItem implements the mcp item interface directly, instead of FortWorldItem and FortAccountItem implementing it separately Change 3236746 on 2016/12/15 by Ben.Zeigler Add ProcessAsyncLoadingUntilComplete which will process async loading until a predicate is true or time runs out Change streamable manager to return a handle structure, that can be used to block or poll as needed. Active handles will keep objects in memory even after the load finishes FStreamableManager::SynchronousLoad now does high-priority-async-load-and-wait instead of doing a full async flush/static load object if asynch loading is in progress, this should make stalls much shorter when sync loading a single asset Deprecate some of the StreamableManager functions now that handles exist. The fact that SynchronousLoad kept an object from ever GCing was not expected behavior by most users Add Experimental feature AssetManager, which is a global singleton that supports loading assets on demand. It is disabled by default Add concept of PrimaryAssetID which is a Type:Name pair that globally identifies an asset. This is returned by GetPrimaryAssetId on UObject and is needed for the asset manager to work Add PrimaryAssetData class, which supports the primary asset and bundle concepts natively Add concept of an AssetBundleEntry/Data, which is a scoped map from name -> list of assets. If you modify an AssetBundleData it will get baked into the asset registry at runtime Fix KismetSystemLibrary and GameplayCueManager to use the new streaming functionality Change 3234031 on 2016/12/13 by Ian.Fox #UE4, #XMPP - Finish libstrophe MUC (Multi-User Chat) implementation - Pull history when joining channels - Handle configuring of XMPP channels we create (and global chat rooms if we managed to create them) [CL 3291644 by Bob Tellez in Main branch]
380 lines
9.4 KiB
C++
380 lines
9.4 KiB
C++
// Copyright 1998-2017 Epic Games, Inc. All Rights Reserved.
|
|
|
|
#include "FunctionalAITest.h"
|
|
#include "TimerManager.h"
|
|
#include "Engine/World.h"
|
|
#include "FuncTestManager.h"
|
|
#include "FunctionalTestingManager.h"
|
|
#include "AI/Navigation/NavigationSystem.h"
|
|
#include "AIController.h"
|
|
#include "Blueprint/AIBlueprintHelperLibrary.h"
|
|
|
|
AFunctionalAITest::AFunctionalAITest( const FObjectInitializer& ObjectInitializer )
|
|
: Super(ObjectInitializer)
|
|
, CurrentSpawnSetIndex(INDEX_NONE)
|
|
, bSingleSetRun(false)
|
|
{
|
|
SpawnLocationRandomizationRange = 0.f;
|
|
bWaitForNavMesh = true;
|
|
}
|
|
|
|
bool AFunctionalAITest::IsOneOfSpawnedPawns(AActor* Actor)
|
|
{
|
|
APawn* Pawn = Cast<APawn>(Actor);
|
|
return Pawn != NULL && SpawnedPawns.Contains(Pawn);
|
|
}
|
|
|
|
void AFunctionalAITest::BeginPlay()
|
|
{
|
|
// do a post-load step and remove all disabled spawn sets
|
|
for(int32 Index = SpawnSets.Num()-1; Index >= 0; --Index)
|
|
{
|
|
FAITestSpawnSet& SpawnSet = SpawnSets[Index];
|
|
if (SpawnSet.bEnabled == false)
|
|
{
|
|
UE_LOG(LogFunctionalTest, Log, TEXT("Removing disabled spawn set \'%s\'."), *SpawnSets[Index].Name.ToString());
|
|
SpawnSets.RemoveAt(Index, 1, false);
|
|
}
|
|
else
|
|
{
|
|
// update all spawn info that doesn't have spawn location set, and set spawn set name
|
|
for (int32 SpawnIndex = 0; SpawnIndex < SpawnSet.SpawnInfoContainer.Num(); ++SpawnIndex)
|
|
{
|
|
FAITestSpawnInfo& SpawnInfo = SpawnSet.SpawnInfoContainer[SpawnIndex];
|
|
SpawnInfo.SpawnSetName = SpawnSet.Name;
|
|
if (SpawnInfo.SpawnLocation == NULL)
|
|
{
|
|
SpawnInfo.SpawnLocation = SpawnSet.FallbackSpawnLocation ? SpawnSet.FallbackSpawnLocation : this;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
SpawnSets.Shrink();
|
|
|
|
Super::BeginPlay();
|
|
}
|
|
|
|
bool AFunctionalAITest::RunTest(const TArray<FString>& Params)
|
|
{
|
|
KillOffSpawnedPawns();
|
|
ClearPendingDelayedSpawns();
|
|
|
|
RandomNumbersStream.Reset();
|
|
|
|
bSingleSetRun = Params.Num() > 0;
|
|
if (bSingleSetRun)
|
|
{
|
|
TTypeFromString<int32>::FromString(CurrentSpawnSetIndex, *Params[0]);
|
|
}
|
|
else
|
|
{
|
|
++CurrentSpawnSetIndex;
|
|
}
|
|
|
|
if (!SpawnSets.IsValidIndex(CurrentSpawnSetIndex))
|
|
{
|
|
return false;
|
|
}
|
|
|
|
StartSpawning();
|
|
|
|
return Super::RunTest(Params);
|
|
}
|
|
|
|
bool AFunctionalAITest::IsReady_Implementation()
|
|
{
|
|
return Super::IsReady_Implementation() && IsNavMeshReady();
|
|
}
|
|
|
|
void AFunctionalAITest::StartSpawning()
|
|
{
|
|
if (bWaitForNavMesh && !IsNavMeshReady())
|
|
{
|
|
GetWorldTimerManager().SetTimer(NavmeshDelayTimer, this, &AFunctionalAITest::StartSpawning, 0.5f, false);
|
|
return;
|
|
}
|
|
|
|
if (!SpawnSets.IsValidIndex(CurrentSpawnSetIndex))
|
|
{
|
|
FinishTest(EFunctionalTestResult::Failed, FString::Printf(TEXT("Unable to use spawn set: %d"), CurrentSpawnSetIndex));
|
|
return;
|
|
}
|
|
|
|
UWorld* World = GetWorld();
|
|
check(World);
|
|
const FAITestSpawnSet& SpawnSet = SpawnSets[CurrentSpawnSetIndex];
|
|
|
|
bool bSuccessfullySpawnedAll = true;
|
|
|
|
// NOTE: even if some pawns fail to spawn we don't stop spawning to find all spawns that will fails.
|
|
// all spawned pawns get filled off in case of failure.
|
|
CurrentSpawnSetName = SpawnSet.Name.ToString();
|
|
|
|
for (int32 SpawnIndex = 0; SpawnIndex < SpawnSet.SpawnInfoContainer.Num(); ++SpawnIndex)
|
|
{
|
|
const FAITestSpawnInfo& SpawnInfo = SpawnSet.SpawnInfoContainer[SpawnIndex];
|
|
if (SpawnInfo.IsValid())
|
|
{
|
|
if (SpawnInfo.PreSpawnDelay > 0)
|
|
{
|
|
FPendingDelayedSpawn PendingSpawnInfo(SpawnInfo);
|
|
PendingSpawnInfo.TimeToNextSpawn = SpawnInfo.PreSpawnDelay;
|
|
PendingSpawnInfo.NumberToSpawnLeft = SpawnInfo.NumberToSpawn;
|
|
|
|
PendingDelayedSpawns.Add(PendingSpawnInfo);
|
|
}
|
|
else if (SpawnInfo.SpawnDelay == 0.0)
|
|
{
|
|
for (int32 SpawnedCount = 0; SpawnedCount < SpawnInfo.NumberToSpawn; ++SpawnedCount)
|
|
{
|
|
bSuccessfullySpawnedAll &= SpawnInfo.Spawn(this);
|
|
}
|
|
}
|
|
else
|
|
{
|
|
bSuccessfullySpawnedAll &= SpawnInfo.Spawn(this);
|
|
if (SpawnInfo.NumberToSpawn > 1)
|
|
{
|
|
PendingDelayedSpawns.Add(SpawnInfo);
|
|
}
|
|
}
|
|
}
|
|
else
|
|
{
|
|
const FString SpawnFailureMessage = FString::Printf(TEXT("Spawn set \'%s\' contains invalid entry at index %d")
|
|
, *SpawnSet.Name.ToString()
|
|
, SpawnIndex);
|
|
|
|
UE_LOG(LogFunctionalTest, Warning, TEXT("%s"), *SpawnFailureMessage);
|
|
|
|
bSuccessfullySpawnedAll = false;
|
|
}
|
|
}
|
|
|
|
if (bSuccessfullySpawnedAll == false)
|
|
{
|
|
KillOffSpawnedPawns();
|
|
|
|
// wait a bit if it's in the middle of StartTest call
|
|
FTimerHandle DummyHandle;
|
|
World->GetTimerManager().SetTimer(DummyHandle, this, &AFunctionalAITest::OnSpawningFailure, 0.1f, false);
|
|
}
|
|
else
|
|
{
|
|
if (PendingDelayedSpawns.Num() > 0)
|
|
{
|
|
SetActorTickEnabled(true);
|
|
}
|
|
}
|
|
}
|
|
|
|
void AFunctionalAITest::OnSpawningFailure()
|
|
{
|
|
FinishTest(EFunctionalTestResult::Failed, TEXT("Unable to spawn AI"));
|
|
}
|
|
|
|
bool AFunctionalAITest::WantsToRunAgain() const
|
|
{
|
|
return bSingleSetRun == false && CurrentSpawnSetIndex + 1 < SpawnSets.Num();
|
|
}
|
|
|
|
void AFunctionalAITest::GatherRelevantActors(TArray<AActor*>& OutActors) const
|
|
{
|
|
Super::GatherRelevantActors(OutActors);
|
|
|
|
for (auto SpawnSet : SpawnSets)
|
|
{
|
|
if (SpawnSet.FallbackSpawnLocation)
|
|
{
|
|
OutActors.AddUnique(SpawnSet.FallbackSpawnLocation);
|
|
}
|
|
|
|
for (auto SpawnInfo : SpawnSet.SpawnInfoContainer)
|
|
{
|
|
if (SpawnInfo.SpawnLocation)
|
|
{
|
|
OutActors.AddUnique(SpawnInfo.SpawnLocation);
|
|
}
|
|
}
|
|
}
|
|
|
|
for (auto Pawn : SpawnedPawns)
|
|
{
|
|
if (Pawn)
|
|
{
|
|
OutActors.Add(Pawn);
|
|
}
|
|
}
|
|
}
|
|
|
|
void AFunctionalAITest::CleanUp()
|
|
{
|
|
Super::CleanUp();
|
|
CurrentSpawnSetIndex = INDEX_NONE;
|
|
|
|
KillOffSpawnedPawns();
|
|
ClearPendingDelayedSpawns();
|
|
}
|
|
|
|
FString AFunctionalAITest::GetAdditionalTestFinishedMessage(EFunctionalTestResult TestResult) const
|
|
{
|
|
FString ResultStr;
|
|
|
|
if (SpawnedPawns.Num() > 0)
|
|
{
|
|
if (CurrentSpawnSetName.Len() > 0 && CurrentSpawnSetName != TEXT("None"))
|
|
{
|
|
ResultStr = FString::Printf(TEXT("spawn set \'%s\', pawns: "), *CurrentSpawnSetName);
|
|
}
|
|
else
|
|
{
|
|
ResultStr = TEXT("pawns: ");
|
|
}
|
|
|
|
|
|
for (int32 PawnIndex = 0; PawnIndex < SpawnedPawns.Num(); ++PawnIndex)
|
|
{
|
|
ResultStr += FString::Printf(TEXT("%s, "), *GetNameSafe(SpawnedPawns[PawnIndex]));
|
|
}
|
|
}
|
|
|
|
return ResultStr;
|
|
}
|
|
|
|
FString AFunctionalAITest::GetReproString() const
|
|
{
|
|
return FString::Printf(TEXT("%s%s%d"), *(GetFName().ToString())
|
|
, FFunctionalTesting::ReproStringParamsSeparator
|
|
, CurrentSpawnSetIndex);
|
|
}
|
|
|
|
void AFunctionalAITest::KillOffSpawnedPawns()
|
|
{
|
|
for (int32 PawnIndex = 0; PawnIndex < SpawnedPawns.Num(); ++PawnIndex)
|
|
{
|
|
if (SpawnedPawns[PawnIndex])
|
|
{
|
|
SpawnedPawns[PawnIndex]->Destroy();
|
|
}
|
|
}
|
|
|
|
SpawnedPawns.Reset();
|
|
}
|
|
|
|
void AFunctionalAITest::ClearPendingDelayedSpawns()
|
|
{
|
|
SetActorTickEnabled(false);
|
|
PendingDelayedSpawns.Reset();
|
|
}
|
|
|
|
void AFunctionalAITest::Tick(float DeltaSeconds)
|
|
{
|
|
Super::Tick(DeltaSeconds);
|
|
|
|
for (auto& DelayedSpawn : PendingDelayedSpawns)
|
|
{
|
|
DelayedSpawn.Tick(DeltaSeconds, this);
|
|
}
|
|
}
|
|
|
|
void AFunctionalAITest::AddSpawnedPawn(APawn& SpawnedPawn)
|
|
{
|
|
SpawnedPawns.Add(&SpawnedPawn);
|
|
OnAISpawned.Broadcast(Cast<AAIController>(SpawnedPawn.GetController()), &SpawnedPawn);
|
|
}
|
|
|
|
FVector AFunctionalAITest::GetRandomizedLocation(const FVector& Location) const
|
|
{
|
|
return Location + FVector(RandomNumbersStream.FRandRange(-SpawnLocationRandomizationRange, SpawnLocationRandomizationRange), RandomNumbersStream.FRandRange(-SpawnLocationRandomizationRange, SpawnLocationRandomizationRange), 0);
|
|
}
|
|
|
|
bool AFunctionalAITest::IsNavMeshReady() const
|
|
{
|
|
UNavigationSystem* NavSys = UNavigationSystem::GetCurrent(GetWorld());
|
|
if (NavSys && NavSys->NavDataSet.Num() > 0 && !NavSys->IsNavigationBuildInProgress())
|
|
{
|
|
return true;
|
|
}
|
|
|
|
return false;
|
|
}
|
|
|
|
//----------------------------------------------------------------------//
|
|
// FAITestSpawnInfo
|
|
//----------------------------------------------------------------------//
|
|
bool FAITestSpawnInfo::Spawn(AFunctionalAITest* AITest) const
|
|
{
|
|
check(AITest);
|
|
|
|
bool bSuccessfullySpawned = false;
|
|
|
|
APawn* SpawnedPawn = UAIBlueprintHelperLibrary::SpawnAIFromClass(AITest->GetWorld(), PawnClass, BehaviorTree
|
|
, AITest->GetRandomizedLocation(SpawnLocation->GetActorLocation())
|
|
, SpawnLocation->GetActorRotation()
|
|
, /*bNoCollisionFail=*/true);
|
|
|
|
if (SpawnedPawn == NULL)
|
|
{
|
|
FString FailureMessage = FString::Printf(TEXT("Failed to spawn \'%s\' pawn (\'%s\' set) ")
|
|
, *GetNameSafe(PawnClass)
|
|
, *SpawnSetName.ToString());
|
|
|
|
UE_LOG(LogFunctionalTest, Warning, TEXT("%s"), *FailureMessage);
|
|
}
|
|
else if (SpawnedPawn->GetController() == NULL)
|
|
{
|
|
FString FailureMessage = FString::Printf(TEXT("Spawned Pawn %s (\'%s\' set) has no controller ")
|
|
, *GetNameSafe(SpawnedPawn)
|
|
, *SpawnSetName.ToString());
|
|
|
|
UE_LOG(LogFunctionalTest, Warning, TEXT("%s"), *FailureMessage);
|
|
}
|
|
else
|
|
{
|
|
IGenericTeamAgentInterface* TeamAgent = Cast<IGenericTeamAgentInterface>(SpawnedPawn);
|
|
if (TeamAgent == nullptr)
|
|
{
|
|
TeamAgent = Cast<IGenericTeamAgentInterface>(SpawnedPawn->GetController());
|
|
}
|
|
|
|
if (TeamAgent != nullptr)
|
|
{
|
|
TeamAgent->SetGenericTeamId(TeamID);
|
|
}
|
|
|
|
AITest->AddSpawnedPawn(*SpawnedPawn);
|
|
bSuccessfullySpawned = true;
|
|
}
|
|
|
|
return bSuccessfullySpawned;
|
|
}
|
|
|
|
//----------------------------------------------------------------------//
|
|
//
|
|
//----------------------------------------------------------------------//
|
|
|
|
FPendingDelayedSpawn::FPendingDelayedSpawn(const FAITestSpawnInfo& Source)
|
|
: NumberToSpawnLeft(0), bFinished(false)
|
|
{
|
|
*((FAITestSpawnInfo*)this) = Source;
|
|
TimeToNextSpawn = Source.SpawnDelay;
|
|
NumberToSpawnLeft = Source.NumberToSpawn - 1;
|
|
}
|
|
|
|
void FPendingDelayedSpawn::Tick(float TimeDelta, AFunctionalAITest* AITest)
|
|
{
|
|
if (bFinished)
|
|
{
|
|
return;
|
|
}
|
|
|
|
TimeToNextSpawn -= TimeDelta;
|
|
|
|
if (TimeToNextSpawn <= 0)
|
|
{
|
|
Spawn(AITest);
|
|
TimeToNextSpawn = SpawnDelay;
|
|
bFinished = (--NumberToSpawnLeft <= 0);
|
|
}
|
|
}
|