refactoring of optional and conditional events detection
drawing of conditional nodes