Jump to content

You're browsing the 2004-2023 VATSIM Forums archive. All content is preserved in a read-only fashion.
For the latest forum posts, please visit https://forum.vatsim.net.

Need to find something? Use the Google search below.

ES SDK: How to draw a line from AC Target position to Cursor


Brendan Chen 943434
 Share

Recommended Posts

Brendan Chen 943434
Posted
Posted

Hi all,

 

I have came across a problem in my ES plugin development.

 

Simply put, I would like to click on a tag item (all coded, not generic TAG editor) which activates a function that allows me to move my mouse anywhere (with a line linking the AC and cursor). When I click again, the heading from AC to my clicked point (cursor) is calculated and set as [Mod - Happy Thoughts]ignedHeading.

 

Just want to ask, how could I do that? If I have not mistaken, there should be some internal function which activates a purple line between the AC and the cursor. Or could even be further as to automatically sets the [Mod - Happy Thoughts]ignedHeading?

 

Cheers,

Brendan Chen

VATPRC Tech Support

You make the difference!

672A68079898-1_zps98cef54d.png

Link to comment
Share on other sites

Gergely Csernak
Posted
Posted

Brendan,

 

Actually that feature has been already implemented in the beta. You can drag and drop that TAG item itself.

There is no function that draws the rubber line for you. When you are dragging anything and you need to refresh the screen then call the CRadarScreen :: RequestRefresh function. That invalidates the screen and calls back with the CRadarScreen :: OnRefresh. There you have a HDC object to draw the line by yourself. Then do it again when the mouse is moved to another place.

 

Gergely.

Gergely.

EuroScope developer

Link to comment
Share on other sites

 Share