[From string (line 10) ] @startuml !unquoted function DRAW($x) return %set_variable_value($x, 1) !function addBox($part, $box, $colour) !if %variable_exists($part) box "$box" #$colour participant "xXXX" as xx end box !endif !endfunction ^^^^^ This function does not have any !return directive. Declare it as a procedure instead ?