Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Flipper 6.0 Help File - <b>obj_snap()</b> c_exam11,c_demo http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
OBJ_SNAP()                                                 C_EXAM11,C_DEMO
   Moves an object guided by a line to a new position.

   Syntax
         nIndex = OBJ_SNAP(nIndex)

   Arguments
         nIndex      Object number.

   Returns
         nIndex      Returns the object number if successful, a 0 if there was
                     no object with that number or the move was cancelled, or
                     a negative of the object number if it overlaps another
                     object.

   Description
         OBJ_SNAP() will move an object by drawing a line from the point
         where the mouse cursor was last pressed until the operation is
         finished when the DrawButton (the default is the left mouse button,
         see CAD_SETUP()) is pressed. This type of moving function is called a
         snap because the object is not seen moving on the screen. This
         works best when large objects require a great deal of time to redraw.

         If CHECK_OLAP() was set on, it will also check to see if the object
         coordinates directly overlay another object of its same type. If
         it does, OBJ_SNAP() will return the negative of the object number
         snapped.

See Also: CHECK_OLAP() OBJ_COPY() OBJ_MOVE() OBJ_MOVPNT() OBJ_SNAPNT()

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson