fixed endchar and draw commands