20 Commits

Author SHA1 Message Date
yoan stamant
6d66e2376c [StateTree] moved some types to the execution types header
#rb mikko.mononen

[CL 26255567 by yoan stamant in 5.3 branch]
2023-06-27 09:09:35 -04:00
mikko mononen
03109406a8 StateTree: Changed EnterState and TickState to events to allow latent tasks
- Added new EnterState and TickState and deprecated olds ones
- Added function to finish the state

#jira UE-187149

[CL 25947504 by mikko mononen in ue5-main branch]
2023-06-13 05:56:36 -04:00
yoan stamant
dfdc26f0d4 [StateTree] added possibility to disable States and Tasks. Also possible to force condition result to true/false.
#jira UE-187154
#rb mikko.mononen

[CL 25796491 by yoan stamant in ue5-main branch]
2023-06-05 13:12:19 -04:00
henrik karlsson
9a1d5b1ad4 [Engine/Plugins]
* Ran IWYU on ~170 plugins to remove includes not needed. Public api still keep old includes inside #if UE_ENABLE_INCLUDE_ORDER_DEPRECATED_IN_5_2

#preflight 63d09351574ab9cae4670216
#rb none

[CL 23844750 by henrik karlsson in ue5-main branch]
2023-01-25 02:42:36 -05:00
mikko mononen
e2fd3455a9 StateTree: Allow tasks to request transitions
- Added ability for tasks to request transitions
- Added buffered transition requests
- Added callback method to FStateTreeTaskBase which is called during transition triggering
- Allow FStateTreeStateLink to be added to tasks and conditions (resolved automatically during compile)

#jira UE-174250
#preflight 63ca7ee8977c62635603afcb

[CL 23815873 by mikko mononen in ue5-main branch]
2023-01-23 12:48:04 -05:00
mikko mononen
0bc7b2da87 StateTree
- restored deprecation (was comments out due to submitting code via multiple CLs)
- cleaned up logging
- skip property binding to not take place when task is not ticked

#rb Mieszko.Zielinski
#preflight 636373961608da6ba1c3a8f2

[CL 22959061 by mikko mononen in ue5-main branch]
2022-11-03 14:21:53 -04:00
mikko mononen
186e03b32e StateTree: Improved event handling
- Moved event queue to it's own struct
- Changed the SendEvent() API to accept struct view to prevent instanced struct copy in common cases
- Fixed event handling in case EnterState() fails.
- Added option for Tasks to disavble ticking, or to be ticked only when there are events
- Added option for Tasks handle when properties are copied
- Changed DebugText to use external Actor reference
- Changed DelayTask to use the new GetInstanceData which does not need type
- Added TStateTreeInstanceDataStructRef which can be used to access struct instance data in delegates

#rb Maxime.Mercier Luciano.Ferraro
#preflight 6360dd302b5338aceb2d0343

[CL 22888708 by mikko mononen in ue5-main branch]
2022-11-01 15:11:19 -04:00
mikko mononen
f7c48b982d StateTree: Change Task EnterState/ExitState signature
- Removed change type from EnterState/ExitState and moved it to transition result
- Added bShouldStateChangeOnReselect which allows to configure a task to behave more like state
- Updated existing tasks

#jira UE-156544
#rb Mieszko.Zielinski
#preflight 6333f6dca907d7192f5f0ccc

[CL 22221382 by mikko mononen in ue5-main branch]
2022-09-28 09:55:53 -04:00
mikko mononen
344561a7f0 StateTree: Fix for abstract classes showing up in class selector
- added condition to prevent abstract classes being selected
- made some base node types hidden

#jira UE-149895
#rb Mieszko.Zielinski
#preflight 62849197614041edb75978ea

[CL 20258008 by mikko mononen in ue5-main branch]
2022-05-18 02:35:34 -04:00
Yoan StAmant
f4f130cbae GameplatStateTree Plugin
- moved StateTreeBrainComponent (from StateTreeModule) and renamed StateTreeComponent
- added FStateTreeTaskCommonBase (similar to FStateTreeTaskCommonCondition)
#rnx
#rb mikko.mononen
#preflight 626fd50d645c64f3a236325a

[CL 20007596 by Yoan StAmant in ue5-main branch]
2022-05-02 09:15:14 -04:00
mikko mononen
ef8889a1c4 StateTree: Added functionality to call and reuse a subtree
- Removed unnecessary checks for specific transition (handled in enter state logic)
- Added state type to StateTreeState, State, Group, or Linked
- StateTreeState property customization hides properties based on type
- Allow a state to link to another state
- Changed baker binding validation to handle linked states
- Added linked state handling in execution context
- Updated UI deal with linked states
- Updated gameplay debugger to deal with linked states
- Moved automatic Root state adding from Editor data to editor open (tests were broken due to extra root state)
- Fixed tests and added simple test for linked state
- Added meta to tag to state link to allow to select only direct states (no next, etc)
- Added counter to track state changes (mainly for debugging)

#jira UE-147509
#review
#preflight 624beb69637925b5d306d8e7

[CL 19621621 by mikko mononen in ue5-main branch]
2022-04-05 03:20:57 -04:00
mikko mononen
841dd874f1 StateTree: Renamed item to node
- Renamed uses of item to node
- Added base class for Conditions, Evals & Tasks

#jira UE-140363
#rb mieszko.zielinski
#preflight 61fa4083db42673a6020f1fb
#lockdown julien.marchand

#ROBOMERGE-AUTHOR: mikko.mononen
#ROBOMERGE-SOURCE: CL 18841581 in //UE5/Release-5.0/... via CL 18841871 via CL 18842048
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v910-18824042)

[CL 18842354 by mikko mononen in ue5-main branch]
2022-02-03 09:13:49 -05:00
mikko mononen
6a8caf79a7 StateTree UI improvements
- fixed description display on BP conditions
- added class cache that contains also BP classes and is kept up to date as the assets and BPs change
- the condition/evaluator/task selector now shows struct and class based items in same menu
- added meta = (Hidden) support for structs to prevent them displaying in the item selector

#jira UE-135723
#review-18322707
#robomerge 5.0
#preflight 61a7302e9c77d6100788c8ad

[CL 18336889 by mikko mononen in ue5-main branch]
2021-12-01 03:41:24 -05:00
mikko mononen
0e7aa10d82 StateTree tweaks
- removed pure virtuals from StateTree nodes
- cosmetic change when StateTree current state is set

#jira none
#review-18322438
#robomerge 5.0
#preflight 61a5e27e801b36197842b262

[CL 18322563 by mikko mononen in ue5-main branch]
2021-11-30 03:53:20 -05:00
mikko mononen
3f4f44a364 StateTree: UObject and BP support
- connect GetWorld() of FStateTreeExecutionContext explicitly to the owner
- take MassSignalSubsystem as parameter to FMassStateTreeExecutionContext directly
- separated DataViewIndex (what others see) and InstanceIndex/bInstanceIsObject (where the pointert comes from) on StateTree items
- allow item instance to be a struct or object
- added editor support for both struct or object based instance
- added Blueprint base classes for Eval, Task and Condition
- Update UStateTreeBrainComponent

#jira UE-135723
#review-18267822
#robomerge 5.0

[CL 18280804 by mikko mononen in ue5-main branch]
2021-11-24 04:26:12 -05:00
mikko mononen
9cb403b9ab StateTree: allow task/evaluator/condition to have separate data for isntance and item in the tree.
- Changed conditions to use the same code structure as tasks and evals
- Tasks, Evaluators, and Conditions can have separate struct for instance and tree item
- Converted existing tasks/evals/conds to use the new setup
- Updated the UI to use the new setup
- Limited the property binding to only first level properties in the instance struct
- Removed StateTreeConditionItemDetails (uses the same details customization as tasks/evals)
- Removed bunch of old test tasks and evals

#jira UE-133870
#rb Yoan.StAmant
#robomerge 5.0

[CL 18165353 by mikko mononen in ue5-main branch]
2021-11-12 05:48:11 -05:00
mikko mononen
a434bdedfb StateTree: Resolve external dependecies at load time instead of bake time
- added StateTree linker
- added Link() method to tasks and evaluators
- added templated item reference which makes getter code less error prone

#jira none
#review-17921724
#robomerge 5.0

[CL 17941680 by mikko mononen in ue5-main branch]
2021-10-27 06:10:12 -04:00
mikko mononen
09243f59e4 StateTree: renamed task2 and evaluator2
#jira none
#review-17882783
#robomerge 5.0

[CL 17882855 by mikko mononen in ue5-main branch]
2021-10-21 04:51:39 -04:00
mikko mononen
667a0bf417 StateTree: Remove V1
#jira none
#review-17748193
#robomerge 5.0

[CL 17882720 by mikko mononen in ue5-main branch]
2021-10-21 04:08:20 -04:00
mieszko zielinski
c019c2635f Moved GameplayBehaviors out of restricted folder over to Experimental
Moved SmartObjects out of restricted folder
Moved StateTree out of restricted folder
Moved ZoneGraph out of restricted folder
Moved ZoneGraphAnnotations out of restricted folder

#jira UE-115297

#ROBOMERGE-OWNER: mieszko.zielinski
#ROBOMERGE-AUTHOR: mieszko.zielinski
#ROBOMERGE-SOURCE: CL 17648223 via CL 17648246 via CL 17648261 via CL 17648385 via CL 17648390 via CL 17648742
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Test -> Main) (v875-17642767)

[CL 17648750 by mieszko zielinski in ue5-main branch]
2021-09-28 13:33:17 -04:00