104 Commits

Author SHA1 Message Date
patrick boutot
92b3e3e6fa StateTree: Compile the StateTree after each load in the editor. That ensures the data is valid when cooking and that if the cpp code changed, the new properties are properly converted. Do not mark the asset as dirty when it compiles. It should only mark the asset dirty when a user does the manipulation. Any automatic conversion should be transparent for the user.
#jira UE-222447
#rb Yoan.StAmant
#p4v-cherrypick 36157962

[CL 36331606 by patrick boutot in 5.5 branch]
2024-09-17 08:06:50 -04:00
patrick boutot
98036c2050 StateTree: Delay Link after the package is loaded or when first used.
#rb Yoan.StAmant

[CL 35965260 by patrick boutot in ue5-main branch]
2024-09-03 09:15:07 -04:00
patrick boutot
7cf86db302 StateTree: Remove all objects that a StateTree compilation creates when recompiling. That helps to keep the object name consistent between recompilation and help reduce the diff cook package size.
#rb Yoan.StAmant
#jira UE-189890

[CL 35692664 by patrick boutot in ue5-main branch]
2024-08-21 05:52:51 -04:00
patrick boutot
b5959b59f4 StateTree: Add option to print the result of a StateTree compilation. Moved FStateTreeExecutionContext::GetDebugPrintString to UStateTree. Added transitions, global tasks and conditions. Update other FStateTreeExecutionContext functions to use StringBuilder.
#rb Yoan.StAmant

[CL 35592149 by patrick boutot in ue5-main branch]
2024-08-16 09:07:06 -04:00
jurre debaare
1454040a2b StateTree editor
- StateTreeEditorMode, which now holds all of the state-tree editing behavior previously part of StateTreeEditor
- StateTreeEditorModeToolkit, responsible for UI/widgets used by StateTreeEditorMode
- StateTreeEditorModeUILayer used to host StateTreeEditorMode inside of the StateTreeEditor
- Exposed StateTreeViewModel
- Introduced IStateTreeEditorHost, interface to-be implemented for supporting StateTreeEditorMode within an Asset editor
- Moved compilation/validation to UStateTreeEditingSubsystem (editor sub system)
- Added layout extensions for StateTreeEditor

#rb Patrick.Boutot

[CL 35491719 by jurre debaare in ue5-main branch]
2024-08-13 09:09:54 -04:00
patrick boutot
ff595e18ef StateTree: Move the module callback to static variables to prevent issues with the initialization. For commandlet, they can load objects before the module has a chance to load. This is temporary, we should create a subsystem that handles link and compilation.
#jira UE-221399

[CL 35397334 by patrick boutot in ue5-main branch]
2024-08-08 11:29:24 -04:00
patrick boutot
9af223defa StateTree: Use a thread safe delegate for internal bind to delegates that are out of StateTree controls. This is a quick fix to unblock internal projects from building. A better solution is a link/compile manager that knows the current instances or use the TObjectIterator to find the instances.
#jira UE-218319
#rb mikko.mononen

[CL 35366072 by patrick boutot in ue5-main branch]
2024-08-07 08:47:03 -04:00
mikko mononen
c058f457ea StateTrees: Logging an error when an event with empty tag and payload has been sent to ST.
- Fixed event matching logic.
- Fixed validating instance data for property functions

[CL 34636151 by mikko mononen in ue5-main branch]
2024-06-25 04:59:22 -04:00
yoan stamant
dacfa4f383 Moved StructUtils types (InstancedStruct, StructView, PropertyBag, etc.) to CoreUObject
StructUtilsTestSuite has been moved to Developper
StructUtilsEditor has been moved to Engine/Editor
NetSerialization for FInstancedStruct not using native serialization has been moved to the engine module since FRepLayout is not available in CoreUObject module.
Old plugins and modules are kept temporarily and will be remove in a different CL
Temporary header files added to facilitate transition to the new include path
#jira UE-216472
#rb Devin.Doucette, Francis.Hurteau

[CL 34509881 by yoan stamant in ue5-main branch]
2024-06-19 15:22:25 -04:00
yoan stamant
938f456b05 Moved UserDefinedStruct to CoreUObject
#jira UE-216472
#rb Devin.Doucette

[CL 34495793 by yoan stamant in ue5-main branch]
2024-06-19 08:00:57 -04:00
gary yuan
f85b2347ba [Backout] - CL34482589
[FYI] Yoan.StAmant
Original CL Desc
-----------------------------------------------------------------
Moved UserDefinedStruct to CoreUObject
#jira UE-216472
#rb Devin.Doucette

[CL 34486763 by gary yuan in ue5-main branch]
2024-06-18 20:05:51 -04:00
yoan stamant
b9344fb62e Moved UserDefinedStruct to CoreUObject
#jira UE-216472
#rb Devin.Doucette

[CL 34482607 by yoan stamant in ue5-main branch]
2024-06-18 17:57:11 -04:00
mikko mononen
54eb8e271f StateTree: Introduced PropertyFunctions (contributed) (take2)
- Added property functions which can be executed and chained during property binding to set values of properties

[CL 34087989 by mikko mononen in ue5-main branch]
2024-06-04 03:56:38 -04:00
justin peterson
4b5e90f42a [Backout] - CL33856504 - CIS Cook Warning
[FYI] mikko.mononen
Original CL Desc
-----------------------------------------------------------------
StateTree: Introduced PropertyFunctions (contributed)
- Added property functions which can be executed and chained during property binding to set values of properties

[CL 33868630 by justin peterson in ue5-main branch]
2024-05-23 14:06:53 -04:00
mikko mononen
8fb0559486 StateTree: Introduced PropertyFunctions (contributed)
- Added property functions which can be executed and chained during property binding to set values of properties

[CL 33856515 by mikko mononen in ue5-main branch]
2024-05-23 04:48:59 -04:00
juan portillo
cc6661e0ff State Tree: added instance data mismatch auto-fix
#jira UE-215581
#rb mikko.mononen

[CL 33836195 by juan portillo in ue5-main branch]
2024-05-22 13:29:00 -04:00
mikko mononen
a583516941 StateTrees: Made FStateTreeNodeBase::PostLoad available in all kinds of builds.
[CL 33197099 by mikko mononen in ue5-main branch]
2024-04-24 08:49:40 -04:00
guillaume arruda
4f79176477 Add compile in StateTree PostLoad and compile on PIE begin to state tree so that the trees are never out of sync with the editor state in game
Add validation warning if the state tree is not compiled to prevent uncompiled state tree to be submitted
#rb mikko.mononen

[CL 33001894 by guillaume arruda in ue5-main branch]
2024-04-16 11:14:34 -04:00
guillaume arruda
5b085806fd Add postload callback to state tree node in editor
Use callback to sync parameters in FStateTreeRunParallelStateTreeTask
#rb mikko.mononen
#rnx

[CL 32396757 by guillaume arruda in ue5-main branch]
2024-03-21 08:38:57 -04:00
matt breindel
2a0454735e Making the asset gatherer tick run on a background thread. In order to do this, it was also necessary to refactor PostLoadAssetRegistryTags, deprecating the existing function and implementing a new ThreadedPostLoadAssetRegistryTagsOverride. The multithreading functionality is disabled in this checkin. -dpcvars=AssetRegistry.TickGatherOnGTOnly=0 will enable it.
#jira UE-204058
[REVIEW] [at]*matt.peters [at]dan.oconnor [at]ben.zeigler [at]robert.millar
[FYI] [at]francis.hurteau
#rb Matt.Peters

[CL 32388964 by matt breindel in ue5-main branch]
2024-03-20 20:13:47 -04:00
mikko mononen
a82ca89e98 StateTree: Added support for event payload in transitions and event capture for states. (contributed) [take 2]
- Transitions can now be set up to require a specific payload type and/or a gameplay tag
- Required transition event payload is visible to property bindind for transition conditions
- States can require an event type as enter condition, the event is captured when state is selected
- Required state event payload is visible to binding for state enter conditions, tasks and transistions

[CL 32150454 by mikko mononen in ue5-main branch]
2024-03-11 04:54:44 -04:00
bob tellez
0189872e84 [Backout] - CL32082262
[FYI] mikko.mononen
Original CL Desc
-----------------------------------------------------------------
StateTree: Added support for event payload in transitions and event capture for states. (contributed)
- Transitions can now be set up to require a specific payload type and/or a gameplay tag
- Required transition event payload is visible to property bindind for transition conditions
- States can require an event type as enter condition, the event is captured when state is selected
- Required state event payload is visible to binding for state enter conditions, tasks and transistions

[CL 32113027 by bob tellez in ue5-main branch]
2024-03-07 23:49:50 -05:00
mikko mononen
cec24c894d StateTree: Added support for event payload in transitions and event capture for states. (contributed)
- Transitions can now be set up to require a specific payload type and/or a gameplay tag
- Required transition event payload is visible to property bindind for transition conditions
- States can require an event type as enter condition, the event is captured when state is selected
- Required state event payload is visible to binding for state enter conditions, tasks and transistions

[CL 32082269 by mikko mononen in ue5-main branch]
2024-03-07 06:53:02 -05:00
mikko mononen
4079007ba6 StateTree: Introduced TStateTreePropertyRefExternalHandle.
- also InstanceDataStorage is stored as a sharedptr now

[CL 30996128 by mikko mononen in ue5-main branch]
2024-01-30 03:18:31 -05:00
mikko mononen
dd16540a54 StateTree: Storing global parameters data in instance storage.
- Implies that parameters are only set once at start
- Allows parameters to be safely mutated if needed, e.g. via property references

[CL 30765232 by mikko mononen in ue5-main branch]
2024-01-22 05:38:03 -05:00