<> <> <> DIRECTORY DM, DragOpsCross, DMDragonModel; DMDragonModelImpl: CEDAR PROGRAM IMPORTS DM EXPORTS DMDragonModel = BEGIN OPEN DMDragonModel; Create: PUBLIC PROC [subComponents: DM.ComponentList] RETURNS [dm: DM.Component] = { dm _ NEW [DM.ComponentRec _ [ action: [Reset, PhA, EvPhA, PhB, EvPhB], history: NIL, componentType: $Dragon, subComponents: subComponents, specific: NIL ]] }; PhA: DM.ActionProc = { DM.ListApply[component.subComponents, PhA] }; EvPhA: DM.ActionProc = { DM.ListApply[component.subComponents, EvPhA] }; PhB: DM.ActionProc = { DM.ListApply[component.subComponents, PhB] }; EvPhB: DM.ActionProc = { DM.ListApply[component.subComponents, EvPhB] }; Reset: DM.ActionProc = { DM.ListApply[component.subComponents, Reset]; component.history _ NIL }; END.