API Panel.Position.SetCoords
<sidebar>API contents</sidebar> Sets an objects coordinates based on a position
Contents
Parameters
HANDLE Dest
- The position or component to update
HANDLE Source
- The position or component to read from
Return value
This call does not return a value
Detailed description
No additional information
Examples
Calling in a calculation
- Add to a calculation icon:
::Panel.Position.SetCoords(dest, source)
Flowcode example file
Download File:SIMAPI Panel Position SetCoords.fcf and open it in Flowcode v6. In this example there are two spheres (sourceball & destinationball) and a LCD showing the coordinates of each sphere. Every two seconds the program will move the red sphere to the coordinates of the yellow sphere, and then return the red sphere to its original position. The red sphere is slightly larger than the yellow sphere. This is purely to illustrate the red sphere moves to its correct destination (if the spheres are the exact same size then you may or may not see the red sphere properly as the program is rendering two spheres of exact dimensions in exactly the same coordinates)
The screenshots below show the effect and also highlight the code used by the example.