How to combine activity (beta) and state diagrams

0 votes
asked May 11, 2020 in Question / help by savishnu (120 points)
Hello team,

I'm looking to get the best features of the various diagrams like activity and state, please do advice me if this is possible or not.

I'm looking to do something like this an activity (beta) diagram.

@startuml

start

:something
...
...

Run  : Character is running
Walk : Character is walking
Jump : Character is Jumping
[*] --> Run
[*] --> Walk
[*] --> Jump

...
...

stop

@enduml

1 Answer

+3 votes
answered May 26, 2020 by The-Lu (64,340 points)

Hello S.,

You can use embedded diagram or sub-diagram with use of '{{' and '}}':

See more details: with “Embed diagrams in notes and other texts” from /7140 which point out: the creation of this feature on /2427.

start
:something;
:...;
:<u><i>here is a state diagram on a activity diagram
{{
Run  : Character is running
Walk : Character is walking
Jump : Character is Jumping
[*] --> Run
[*] --> Walk
[*] --> Jump
}}
;
:...;
stop

If that can help,
Regards,
Th.

commented May 26, 2020 by savishnu (120 points)
Thank you so much.
...