/* Authors: Arkeon */ /* Last update: 10.01.03 */ /* Version: 1.0 */ typeof plugin = S;; typeof class = S;; typeof ed = PluginEditor;; typeof SavedType = S;; typeof e_speed = ObjText;; typeof ToObj = ObjCheck;; var speed=100;; proto save=fun [ [Inst r1] ] [[S r1] [S r1] [[S r1]r1] [[S r1]r1]];; fun openedit(win, param) = let strextr param -> l in let _GETwindowSizePosition win -> [w h x y] in { set ed = startPluginEditor _channel win 0 0 w h WN_CHILDINSIDE|WN_NOBORDER class; set speed = let getInfo l "speed" -> tmp in if tmp == nil then 100 else atoi tmp; _CRtext _channel ed.PluginEditorEditWin 5 30 120 20 ET_ALIGN_RIGHT "Anim speed :"; set e_speed = _CReditLine _channel ed.PluginEditorEditWin 130 30 100 20 ET_DOWN itoa speed; set ToObj = _SETcheck _CRcheck _channel ed.PluginEditorEditWin 5 5 90 20 0 "To object" if !strcmpi getInfo l "ToObj" "on" then 1 else 0; }; 0;; fun closeedit() = strbuild ("speed"::(_GETtext e_speed)::nil):: ("ToObj"::(let _GETcheck ToObj -> x in if x then "on" else "off")::nil):: nil ;; fun savesuppdmi(l) = if l==nil then nil else let l->[a n] in ("actionC"::(strcat a.nameInst ".set")::nil):: ("action"::(strcat a.nameInst ".set2all")::nil):: savesuppdmi n ;; fun save(l)= [ nil /* registerF */ nil /* register */ ("plugin"::plugin::nil)::nil /* supplemental Dat */ savesuppdmi l /* supplemental Dmi */ ];; fun IniPlug(file) = set plugin=file; set class=getInfo strextr _getpack _checkpack file "name"; PlugRegister class @save nil @openedit @closeedit;;