[15.3] What about XCMDs? Are they just the same?

XCMDs and XFCNs are Macintosh code resource formats originally created for Hypercard and subsequently supported by a number of other applications. XCMDs have a different interface structure to XObjects, which Director for Mac supports via a built-in XObject called XCMDGlue. Director for Windows cannot use XCMDs at all, just as it cannot use Macintosh XObjects.

Although XCMDGlue is as XObject, you do not need to use it in the same way as normal XObjects -- Director takes care of the usual XObject mechanics behind the scenes whenever you open or close a file containing XCMD or XFCN resources. As a result, many XCMDs and XFCNs can be used almost transparently with Director. Once the file containing the XCMD has been opened (with a call to openXLib, just as with XObjects) the functions it provides can be called just like any other Lingo routines:

    openXlib "blah XCMD"
    blah "explode", "Seattle"
XCMDs and XFCNs do not support standard XObject methods such as mNew, mDispose and mDescribe.

For more info on using XCMDs with Director, see Appendix A of the "Using Lingo" manual.