Why a TextDialog triggered before a delay will be shown after delay end?

Your delay will not work like that. Use a clock timer event to start the delay then run the items you want after the delay.

Also see here: