what's the best way to go about drawing objects onto the smart client, i.e. circles etc.?
e.g. drawing a small circle somewhere on the minimap at coords x,y?
what's the best way to go about drawing objects onto the smart client, i.e. circles etc.?
e.g. drawing a small circle somewhere on the minimap at coords x,y?
Simba Code:procedure SMART_DrawCircle(Clear: Boolean; Center: TPoint; Radius: Integer; Fill: Boolean; Color: TColor);
//example:
SMART_DrawCircle(False, Point(252, 50), 5, False, clRed);
if 'Fill' is true it will fill the circle, otherwise it draws just the border.
if 'Clear' is true it will clear the SMART Canvas: meaning it will remove the drawing.
Insert your coords x,y in Point(x,y)
Creds to DannyRS for this wonderful sig!
awesome! this'll make debugging so much easier =D
oh, i forgot to ask... deleting/moving the circle around?
or better yet would probably be documentation of the smart functions?
haven't found the documentation but i did find this function...
Simba Code:procedure SMART_ClearCanvasArea(Area: TBox);
would constant clearing/redrawing to keep it updated lag up the processing of the script too much? or would there be a better way to keep the objects where i need them dynamically?
oh and another edit... if that is the way to do it (constant clear/redraw) is there a way to multithread so I can have it running while my script is running? yes, I know i can just put it in the main loop, but i'd rather multithread it if possible
Last edited by ookamocka; 03-09-2013 at 04:56 PM.
TTimer, doesn't work as far as I know; thus multithreading with your current build won't happen in the script runtime.
You can, however, add some waits to your loops to help lower intensive CPU functions.
There are currently 1 users browsing this thread. (0 members and 1 guests)