home *** CD-ROM | disk | FTP | other *** search
/ Program Metropolis - Software Boutique 95 / SOFTWARECD.iso / topas5 / disk3 / install.dat < prev    next >
Encoding:
INSTALL Professional project  |  1993-11-22  |  28.7 KB  |  990 lines

  1. @DefineProject
  2.     @Name = "Crystal TOPAS Professional Demo"
  3.     @Version = "5.0"
  4.     @OutDrive = C
  5.     @Subdir = "\\TOPAS"
  6.     @InDiskBell = 1
  7. @EndProject
  8.  
  9. @DefineVars
  10.     @QString @RunBatch  = "TOPAS"
  11.     @QString @Exefile   = "dealanim"
  12.     @Integer @HasModels = 1
  13.     @Integer @HasPics   = 1
  14.     @Integer @HasPicFiles   = 1
  15.     @Integer @HasAnims  = 1
  16.     @Integer @HasAnimScripts = 0
  17.     @Integer @HasBatch  = 1
  18.     @Integer @HasMats   = 1
  19.     @Integer @HasCAD    = 1
  20.     @Integer @HasFonts  = 1
  21.     @Integer @HasCams   = 1
  22.     @Integer @HasProcs  = 1
  23.     @Integer @HasProcFiles  = 1
  24.     @Integer @HasRMAN   = 0
  25.     @Integer @HasDVE    = 0
  26.     @QString @CFGName   = "CRYSTAL"
  27. @EndVars
  28.  
  29.  
  30. // software name information
  31. @DefineVars
  32.     @Integer @NamePos  = (39 - (@StrLen(@Name) + 10)/2)
  33.     @QString @SerialNumber = ""
  34. @EndVars
  35.  
  36.  
  37. // memory requirement constants
  38. @DefineVars
  39.     @Integer @K         = 1024
  40.     @Integer @M         = (@K*@K)
  41.     @Integer @RAMReq    = (200*@K)
  42.     @Integer @RAMReqK   = (@RAMReq/@K)
  43.     @Integer @ExtReq    = (5*@M)
  44.     @Integer @ExtReqM   = (@ExtReq/@M)
  45. @EndVars
  46.  
  47. @DefineVars
  48.     @Dir @Models   = "@Subdir\\Models"
  49.     @Dir @CAD      = "@Subdir\\CAD"
  50.     @Dir @Pictures = "@Subdir\\Pictures"
  51.     @Dir @Fonts    = "@Subdir\\Fonts"
  52.     @Dir @Cameras  = "@Subdir\\Cameras"
  53.     @Dir @Procs    = "@Subdir\\Procs"
  54.     @Dir @Script   = "@Subdir\\Anim"
  55.     @Dir @Batch    = "@Subdir\\Batch"
  56.     @Dir @Material = "@Subdir\\Material"
  57.     @Dir @DVE      = "@Subdir\\DVEator"
  58.     @QString @TmpFileType = ""
  59.     @Dir @TmpDir  = ""
  60. @EndVars
  61.  
  62. @DefineVars
  63.     @Integer @ProgramReqM = 4   /* M */
  64.     @Integer @ModelReqK   = 0   /* K */
  65.     @Integer @CADReqK     = 0   /* K */
  66.     @Integer @ScriptReqK  = 0   /* K */
  67.     @Integer @PictureReqM = 3   /* M */
  68.     @Integer @FontReqM    = 2   /* M */
  69.     @Integer @CameraReqK  = 1   /* K */
  70.     @Integer @MatReqK     = 1   /* K */
  71.     @Integer @ProcReqK    = 4   /* K */
  72. @EndVars
  73.  
  74. // Calculate the disk space required for the installation
  75. // since we have ifdef the values above, the calculation is constant for
  76. // all packages
  77. @DefineVars
  78.     @Integer @DiskReq   = (@ProgramReqM * @M + @ModelReqK * @K +
  79.                @CADReqK * @K + @PictureReqM * @M +
  80.                @FontReqM * @M + @CameraReqK * @K +
  81.                @MatReqK * @K + @ProcReqK * @K +
  82.                @ScriptReqK * @K)
  83.     @Integer @DiskReqK  = (@DiskReq/@K)
  84.     @Integer @DiskFreeK  = (@DiskFree @OutDrive /1024)
  85.     @Integer @DiskSpaceLeftK = (@DiskFreeK -@DiskReqK)
  86.     @Integer @TmpValue = 0
  87.     @QString @TmpDiskReqStr = ""
  88.     @QString @TmpDiskFreeStr = ""
  89.     @QString @TmpDiskSpaceLeftStr = ""
  90. @EndVars
  91.  
  92.  
  93. @setoption(31)    /* model path is the same */
  94. @setoption(32)    /* cad path is the same */
  95. @setoption(33)    /* picture path is the same */
  96. @setoption(34)    /* fonts path is the same */
  97. @setoption(35)    /* cameras path is the same */
  98. @setoption(36)    /* procedural path is the same */
  99. @setoption(37)    /* script path is the same */
  100. @setoption(38)    /* batch path is the same */
  101. @setoption(39)    /* material path is the same */
  102. @setoption(40)    /* material path is the same */
  103.  
  104. @setoption(41)    /* install program */
  105. @if (@HasModels == 1)
  106.    @setoption(42)    /* install models */
  107. @endif
  108. @if (@HasCAD == 1)
  109.    @setoption(43)    /* install cad files */
  110. @endif
  111. @if (@HasPicFiles == 1)
  112.    @setoption(44)    /* install pictures */
  113. @endif
  114. @if (@HasFonts == 1)
  115.    @setoption(45)    /* install fonts */
  116. @endif
  117. @if (@HasCams == 1)
  118.    @setoption(46)    /* install cameras */
  119. @endif
  120. @if (@HasMats == 1)
  121.    @setoption(47)    /* install material files */
  122. @endif
  123. @if (@HasProcFiles == 1)
  124.    @setoption(48)    /* install procedurals */
  125. @endif
  126. @if (@HasAnimScripts == 1)
  127.    @setoption(50)    /* install scripts */
  128. @endif
  129.  
  130.  
  131. // Display the greeting screen
  132. @Display
  133. @cls
  134. @move(1, 15)┌──────────────────────────────────────────────┐
  135. @move(2, 15)│
  136. @movecstr(2, @NamePos, 15+16,"@Name Installer")
  137. @movecstr(2, 62, 15+16, "│")
  138. @move(3, 15)│                Copyright 1993                │
  139. @move(4, 15)│             CrystalGraphics, Inc.            │
  140. @move(5, 15)└──────────────────────────────────────────────┘
  141.  
  142.      This utility will install the @Name software
  143.      on your computer system. It will use the settings shown on the next
  144.      screen to install the files. You may change these default settings
  145.      if you want to specify the directory structure, or the files to be
  146.      installed.
  147.  
  148.      Before performing the install, we recommend you use a disk repair and
  149.      defragmentation utility such as The Norton Utilities from Symantec or
  150.      PCTools from Central Point. This will insure that you are installing
  151.      the software on a "healthy" system with optimal disk performance.
  152.  
  153.                                       @pause
  154. @enddisplay
  155.  
  156.  
  157. // Display Hardware problems (if any)
  158. @Display
  159.   @if ((@cpu < 386) || (@RAMAvail < @RAMReq) || (@ExtTotal < @ExtReq) ||
  160.        (10 [= @option))
  161.   @cls
  162.   Hardware Problems
  163.   ──────────────────────────────────────────────────────────────────────────
  164.   There are problems with your current hardware configuration, which must be
  165.   resolved before @Name can be run.
  166.   ──────────────────────────────────────────────────────────────────────────
  167.  
  168.   They are:
  169.  
  170.     @if (@cpu < 386)
  171.        @move(9, 2)- You need a 386 or better machine.
  172.     @endif
  173.     @if (@RAMAvail < @RAMReq)
  174.        @move(10, 2)- You need more DOS memory. You will need at least @RAMReqK K.
  175.     @endif
  176.     @if (@ExtTotal < @ExtReq)
  177.        @move(11, 2)- You need more extended memory.  You will need at least @ExtReqM M
  178.     @endif
  179.  
  180.  
  181.  
  182.  
  183.                                       @pause
  184.   @endif
  185. @enddisplay
  186.  
  187. // Display Math CoProcessor warnig if none present
  188. @Display
  189.   @if (@NDP == 0)
  190.   @cls
  191.   No Math Co-processor Installed
  192.   ──────────────────────────────────────────────────────────────────────────
  193.   No math  co-processor has been detected. While the software does not
  194.   require a math co-processor to run, it will run as much as 6 times faster
  195.   with one installed. Adding a math co-processor is the single most
  196.   important thing you can do to improve the performance of @Name.
  197.   ──────────────────────────────────────────────────────────────────────────
  198.  
  199.  
  200.                                       @pause
  201.   @endif
  202. @enddisplay
  203.  
  204.  
  205. SETTINGS:
  206.  
  207. // decide free space - round it down
  208. @DiskFreeK = (@DiskFree @OutDrive / @K)
  209. @if (@DiskFreeK >= @K)
  210.   @TmpValue = (@DiskFree @OutDrive / @M)
  211.   @TmpDiskFreeStr = "@TmpValue M free"
  212. @else
  213.   @TmpDiskFreeStr = "@DiskFreeK K free"
  214. @endif
  215.  
  216. // decide disk required - round it up
  217. @if (@DiskReqK >= @K)
  218.    @TmpValue = (@DiskReq / @M)
  219.    @if (@DiskReq > (@TmpValue * @M))
  220.       @TmpValue = (@TmpValue + 1)
  221.    @endif
  222.    @TmpDiskReqStr = "@TmpValue M required"
  223. @else
  224.    @TmpDiskReqStr = "@DiskReqK K required"
  225. @endif
  226.  
  227. // Determine whether we are doing a Default or Custom install
  228. // decide file directory should use default or custom
  229. @if ((31 [= @option) && (32 [= @option) && (33 [= @option) &&
  230.      (34 [= @option) && (35 [= @option) && (36 [= @option) &&
  231.      (37 [= @option) && (38 [= @option) && (39 [= @option) &&
  232.      (40 [= @option))
  233.     @TmpFileType = "File directories:  @subdir\\<defaults>"
  234. @else
  235.     @TmpFileType = "File directories:  \\<custom>"
  236. @endif
  237.  
  238.  
  239. // Display and allow user to set the Installation Settings
  240. @flushgroups
  241. @getgroups
  242. @if ((@CADReqK > 0) || (@ProcReqK > 0) || (@FontReqM > 0) || (@MatReqK > 0) ||
  243.      (@CameraReqK > 0) || (@PictureReqM > 0) || (@ScriptReqK > 0))
  244.     @localwindow(14,14)        // Have files to install
  245. @else
  246.     @localwindow(13,14)        // Don't have files to install
  247. @endif
  248. @set A = "INSTALL"
  249. @set B = "Program drive"
  250. @set C = "Program directory"
  251. @set D = "File directories"
  252. @if ((@CADReqK > 0) || (@ProcReqK > 0) || (@FontReqM > 0) || (@MatReqK > 0) ||
  253.      (@CameraReqK > 0) || (@PictureReqM > 0) || (@ScriptReqK > 0))
  254.     @set E = "Files to install"
  255. @endif
  256. @cls
  257.   Current Installation Settings
  258.   ─────────────────────────────────────────────────────────────────────────
  259.   These are the current settings to be used by the Installer. Select an
  260.   option to change within the Install options list box, or proceed with the
  261.   installation by selecting "INSTALL".
  262.   ─────────────────────────────────────────────────────────────────────────
  263.  
  264.   Install options:          Current settings:
  265. @movecstr(12, 28, 15+16, "Program drive:     @outdrive:")
  266. @movecstr(12, 59, 15+16, @TmpDiskFreeStr)
  267. @movecstr(13, 28, 15+16, "Program directory: @subdir")
  268. @movecstr(14, 28, 15+16, @TmpFileType)
  269. @if ((@CADReqK > 0) || (@ProcReqK > 0) || (@FontReqM > 0) || (@MatReqK > 0) ||
  270.      (@CameraReqK > 0) || (@PictureReqM > 0) || (@ScriptReqK > 0))
  271.    @if ((41 [! @option) ||
  272.         (@HasModels && (42 [! @option)) ||
  273.         (@HasCad && (43 [! @option)) ||
  274.     (@HasPicFiles && (44 [! @option)) ||
  275.         (@HasFonts && (45 [! @option)) ||
  276.         (@HasCams && (46 [! @option)) ||
  277.         (@HasMats && (47 [! @option)) ||
  278.         (@HasProcFiles && (48 [! @option)) ||
  279.     (@HasAnimScripts && (50 [! @option)))
  280.       @movecstr(15, 28, 15+16, "Files to install:  Partial")
  281.    @else
  282.       @movecstr(15, 28, 15+16, "Files to install:  All")
  283.    @endif
  284. @endif
  285. @movecstr(15, 59, 15+16, @TmpDiskReqStr)
  286. @movecstr(21, 2, 15+32, " [Arrow Keys]=Scroll                                                          ")
  287. @movecstr(22, 2, 15+32, "      [ENTER]=Select                                               [ESC]=Quit ")
  288. @endgroups
  289.  
  290. @if ( 'A' [= @group )
  291.    @goto CONTINUE
  292. @elseif ( 'B' [= @group )
  293.    @goto DRIVES
  294. @elseif ( 'C' [= @group )
  295.    @goto DIRS
  296. @elseif ( 'D' [= @group )
  297.    @goto FILEDIRS
  298. @else
  299.    @goto SELECTFILES
  300. @endif
  301.  
  302.  
  303. DRIVES:
  304.  
  305. // decide free space & free space left - round it down
  306. @DiskFreeK = (@DiskFree @OutDrive / @K)
  307. @if (@DiskFreeK >= @K)
  308.    @TmpValue = (@DiskFree @OutDrive / @M)
  309.    @TmpDiskFreeStr = "@TmpValue M"
  310.    @DiskSpaceLeftK = (@TmpValue * @K)
  311. @else
  312.    @TmpDiskFreeStr = "@DiskFreeK K"
  313.    @DiskSpaceLeftK = (@DiskFreeK)
  314. @endif
  315.  
  316. // decide disk required & update free space left - round it up
  317. @if (@DiskReqK >= @K)
  318.    @TmpValue = (@DiskReq / @M)
  319.    @if (@DiskReq > (@TmpValue * @M))
  320.       @TmpValue = (@TmpValue + 1)
  321.    @endif
  322.    @TmpDiskReqStr = "@TmpValue M"
  323.    @DiskSpaceLeftK = (@DiskSpaceLeftK - @TmpValue * @K)
  324. @else
  325.    @TmpDiskReqStr = "@DiskReqK K"
  326.    @DiskSpaceLeftK = (@DiskSpaceLeftK - @DiskReqK)
  327. @endif
  328.  
  329. // decide free space left - round it down
  330. @if (@DiskSpaceLeftK < 0)
  331.   @TmpValue = (-@DiskSpaceLeftK)
  332.   @if (@TmpValue >= @K)
  333.     @TmpValue = (@DiskSpaceLeftK / @K)
  334.     @TmpDiskSpaceLeftStr = "@TmpValue M"
  335.   @else
  336.     @TmpDiskSpaceLeftStr = "@DiskSpaceLeftK K"
  337.   @endif
  338. @else
  339.   @if (@DiskSpaceLeftK >= @K)
  340.     @TmpValue = (@DiskSpaceLeftK / @K)
  341.     @TmpDiskSpaceLeftStr = "@TmpValue M"
  342.   @else
  343.     @TmpDiskSpaceLeftStr = "@DiskSpaceLeftK K"
  344.   @endif
  345. @endif
  346.  
  347.  
  348. // Get the drive to do the installation on
  349. @GetOutDrive
  350. // disallow (known) removable media drives
  351. @suppress A
  352. @suppress B
  353. @localwindow(15, 9)
  354. @cls
  355.   Program Drive
  356.   ─────────────────────────────────────────────────────────────────────────
  357.   Current setting indicates the current drive and the amount of space
  358.   available on it. Select the drive where you wish the software installed.
  359.   ─────────────────────────────────────────────────────────────────────────
  360.  
  361.   Available drives:    Current setting:
  362.  
  363.              Program Drive:                     @OutDrive:
  364.              Currently available:               @TmpDiskFreeStr
  365.              Files chosen to install require:   @TmpDiskReqStr
  366.              Available after installation:      @TmpDiskSpaceLeftStr
  367.  
  368. @movecstr(21, 2, 15+32, " [Arrow Keys]=Scroll                                                          ")
  369. @movecstr(22, 2, 15+32, "      [ENTER]=Select                                               [ESC]=Quit ")
  370. @EndOutDrive
  371.  
  372. @goto SETTINGS
  373.  
  374.  
  375. DIRS:
  376. @getsubdir  @Subdir
  377. @Prompt = " New directory: "
  378. @cls
  379.   Program Directory
  380.   ─────────────────────────────────────────────────────────────────────────
  381.   Enter the name of the directory where you want to install the software.
  382.   If it does not exist, it will be created; if it does exist, any files
  383.   which have the same name as a file being installed will be overwritten.
  384.   ─────────────────────────────────────────────────────────────────────────
  385.  
  386.   Current directory:     @Subdir
  387. @movecstr(21, 2, 15+32, " [ENTER]=Accept                                                               ")
  388. @movecstr(22, 2, 15+32, "                                                                   [ESC]=Quit ")
  389. @move(10,2)
  390. @endsubdir
  391.  
  392. // reset all paths after a change of subdir if necessary
  393. @if (31 [= @option)
  394.   @Models  = "@Subdir\\Models"
  395. @endif
  396. @if (32 [= @option)
  397.   @CAD     = "@Subdir\\CAD"
  398. @endif
  399. @if (33 [= @option)
  400.   @Pictures = "@Subdir\\Pictures"
  401. @endif
  402. @if (34 [= @option)
  403.   @Fonts   = "@Subdir\\Fonts"
  404. @endif
  405. @if (35 [= @option)
  406.   @Cameras = "@Subdir\\Cameras"
  407. @endif
  408. @if (36 [= @option)
  409.   @Procs   = "@Subdir\\Procs"
  410. @endif
  411. @if (37 [= @option)
  412.   @Script   = "@Subdir\\Anim"
  413. @endif
  414. @if (38 [= @option)
  415.   @Batch    = "@Subdir\\Batch"
  416. @endif
  417. @if (39 [= @option)
  418.   @Material = "@Subdir\\Material"
  419. @if (40 [= @option)
  420.   @DVE = "@Subdir\\DVEator"
  421. @endif
  422.  
  423. @goto SETTINGS
  424.  
  425.  
  426. FILEDIRS:
  427. // reset all paths after a change of subdir if necessary
  428. @if (31 [= @option)
  429.   @Models  = "@Subdir\\Models"
  430. @endif
  431. @if (32 [= @option)
  432.   @CAD     = "@Subdir\\CAD"
  433. @endif
  434. @if (33 [= @option)
  435.   @Pictures = "@Subdir\\Pictures"
  436. @endif
  437. @if (34 [= @option)
  438.   @Fonts   = "@Subdir\\Fonts"
  439. @endif
  440. @if (35 [= @option)
  441.   @Cameras = "@Subdir\\Cameras"
  442. @endif
  443. @if (36 [= @option)
  444.   @Procs   = "@Subdir\\Procs"
  445. @endif
  446. @if (37 [= @option)
  447.   @Script   = "@Subdir\\Anim"
  448. @endif
  449. @if (38 [= @option)
  450.   @Batch    = "@Subdir\\Batch"
  451. @endif
  452. @if (39 [= @option)
  453.   @Material = "@Subdir\\Material"
  454. @endif
  455. @if (40 [= @option)
  456.   @DVE = "@Subdir\\DVEator"
  457. @endif
  458.  
  459. @flushgroups()
  460. @getgroups
  461. @localwindow(15, 20)
  462. @set A = "CONTINUE"
  463. @if (@HasModels == 1)
  464.    @set B = "Models:       @Models "
  465. @endif
  466. @if (@HasCAD == 1)
  467.    @set C = "CAD:          @CAD    "
  468. @endif
  469. @if (@HasPics == 1)
  470.    @set D = "Pictures:     @Pictures"
  471. @endif
  472. @if (@HasFonts == 1)
  473.    @set E = "Fonts:        @Fonts  "
  474. @endif
  475. @if (@HasCams == 1)
  476.    @set F = "Cameras:      @Cameras"
  477. @endif
  478. @if (@HasProcs == 1)
  479.    @set G = "Procedurals:  @Procs"
  480. @endif
  481. @if (@HasAnims == 1)
  482.    @set H = "Scripts:      @Script"
  483. @endif
  484. @if (@HasBatch == 1)
  485.    @set I = "Batch:        @Batch"
  486. @endif
  487. @if (@HasMats == 1)
  488.    @set J = "Material:     @Material"
  489. @endif
  490. @if (@HasDVE == 1)
  491.    @set K = "DVE Images:   @DVE"
  492. @endif
  493. @cls
  494.   File Directories
  495.   ─────────────────────────────────────────────────────────────────────────
  496.   These are the directories where the specified file types will be
  497.   installed and where the software will by default expect to find them.
  498.   Select an item to change its directory, or select "CONTINUE" to return
  499.   to the Installation Settings screen.
  500.   ─────────────────────────────────────────────────────────────────────────
  501.   Current directories:
  502. @movecstr(21, 2, 15+32, " [Arrow Keys]=Scroll                                                          ")
  503. @movecstr(22, 2, 15+32, "      [ENTER]=Select                                               [ESC]=Quit ")
  504. @endgroups
  505.  
  506. @if ( 'A' [= @group )
  507.   @goto SETTINGS
  508. @elseif ( 'B' [= @group )
  509.   @TmpFileType = "Models"
  510.   @TmpDir = @Models
  511. @elseif ( 'C' [= @group )
  512.   @TmpFileType = "CAD"
  513.   @TmpDir = @CAD
  514. @elseif ( 'D' [= @group )
  515.   @TmpFileType = "Pictures"
  516.   @TmpDir = @Pictures
  517. @elseif ( 'E' [= @group )
  518.   @TmpFileType = "Fonts"
  519.   @TmpDir = @Fonts
  520. @elseif ( 'F' [= @group )
  521.   @TmpFileType = "Cameras"
  522.   @TmpDir = @Cameras
  523. @elseif ( 'G' [= @group )
  524.   @TmpFileType = "Procedurals"
  525.   @TmpDir = @Procs
  526. @elseif ( 'H' [= @group )
  527.   @TmpFileType = "Scripts"
  528.   @TmpDir = @Script
  529. @elseif ( 'I' [= @group )
  530.   @TmpFileType = "Batch"
  531.   @TmpDir = @Batch
  532. @elseif ( 'J' [= @group )
  533.   @TmpFileType = "Material"
  534.   @TmpDir = @Material
  535. @elseif ( 'k' [= @group )
  536.   @TmpFileType = "DVE Images"
  537.   @TmpDir = @DVE
  538. @endif
  539.  
  540. @getsubdir @TmpDir
  541. @Prompt = " New @TmpFileType directory: "
  542. @cls
  543.   @TmpFileType Directory
  544.   ─────────────────────────────────────────────────────────────────────────
  545.   Enter a new directory for files of this type.  If the directory does
  546.   not exist, it will be created.  If it does exist, any files which have
  547.   the same name as a file being installed will be overwritten.
  548.   ─────────────────────────────────────────────────────────────────────────
  549.  
  550.   Current @TmpFileType directory:  @TmpDir
  551. @movecstr(21, 2, 15+32, " [ENTER]=Accept                                                               ")
  552. @movecstr(22, 2, 15+32, "                                                                   [ESC]=Quit ")
  553. @move(10,2)
  554. @endsubdir
  555.  
  556. @if ( 'B' [= @group )
  557.   @if (@strfind("@TmpDir", "@Models") == (-1))
  558.     @clearoption(31)
  559.   @endif
  560.   @Models = @TmpDir
  561. @elseif ( 'C' [= @group )
  562.   @if (@strfind("@TmpDir", "@CAD") == (-1))
  563.     @clearoption(32)
  564.   @endif
  565.   @CAD = @TmpDir
  566. @elseif ( 'D' [= @group )
  567.   @if (@strfind("@TmpDir", "@CAD") == (-1))
  568.     @clearoption(33)
  569.   @endif
  570.   @Pictures = @TmpDir
  571. @elseif ( 'E' [= @group )
  572.   @if (@strfind("@TmpDir", "@Fonts") == (-1))
  573.     @clearoption(34)
  574.   @endif
  575.   @Fonts = @TmpDir
  576. @elseif ( 'F' [= @group )
  577.   @if (@strfind("@TmpDir", "@Cameras") == (-1))
  578.     @clearoption(35)
  579.   @endif
  580.   @Cameras = @TmpDir
  581. @elseif ( 'G' [= @group )
  582.   @if (@strfind("@TmpDir", "@Procs") == (-1))
  583.     @clearoption(36)
  584.   @endif
  585.   @Procs = @TmpDir
  586. @elseif ( 'H' [= @group )
  587.   @if (@strfind("@TmpDir", "@Script") == (-1))
  588.     @clearoption(37)
  589.   @endif
  590.   @Script = @TmpDir
  591. @elseif ( 'I' [= @group )
  592.   @if (@strfind("@TmpDir", "@Batch") == (-1))
  593.     @clearoption(38)
  594.   @endif
  595.   @Batch = @TmpDir
  596. @elseif ( 'J' [= @group )
  597.   @if (@strfind("@TmpDir", "@Material") == (-1))
  598.     @clearoption(39)
  599.   @endif
  600.   @Material = @TmpDir
  601. @elseif ( 'K' [= @group )
  602.   @if (@strfind("@TmpDir", "@DVE") == (-1))
  603.     @clearoption(40)
  604.   @endif
  605.   @DVE = @TmpDir
  606. @endif
  607.  
  608. @goto FILEDIRS
  609.  
  610.  
  611. SELECTFILES:
  612.  
  613. // decide disk required - round it up
  614. @DiskReqK = (@DiskReq/1024)
  615. @if (@DiskReqK >= @K)
  616.   @TmpValue = (@DiskReq / @M)
  617.   @if (@DiskReq > (@TmpValue * @M))
  618.     @TmpValue = (@TmpValue + 1)
  619.   @endif
  620.   @TmpDiskReqStr = "@TmpValue M"
  621. @else
  622.   @TmpDiskReqStr = "@DiskReqK K"
  623. @endif
  624.  
  625. @getoption
  626. @checkbox
  627. @option 41  = "Program & Support Files    @ProgramReqM M"
  628. @if (@ModelReqK > 0)
  629.    @option 42  = "Models                     @ModelReqK K"
  630. @endif
  631. @if (@CADReqK > 0)
  632.    @option 43  = "CAD                        @CADReqK K"
  633. @endif
  634. @if (@PictureReqM > 0)
  635.    @option 44  = "Pictures                   @PictureReqM M"
  636. @endif
  637. @if (@FontReqM > 0)
  638.    @option 45  = "Fonts                      @FontReqM M"
  639. @endif
  640. @if (@CameraReqK > 0)
  641.    @option 46  = "Cameras                    @CameraReqK K"
  642. @endif
  643. @if (@MatReqK > 0)
  644.    @option 47  = "Materials & Palettes       @MatReqK K"
  645. @endif
  646. @if (@ProcReqK > 0)
  647.    @option 48  = "Procedurals                @ProcReqK K"
  648. @endif
  649. @if (@ScriptReqK > 0)
  650.    @option 50  = "Scripts                    @ScriptReqK K"
  651. @endif
  652. @localwindow(15, 24)
  653. @cls
  654.   Files To Install
  655.   ─────────────────────────────────────────────────────────────────────────
  656.   These are the installable files. Program & Support Files are required to
  657.   run the software; the others are optional. Files in the install directory
  658.   having the same name as files being installed will be overwritten.
  659.   ─────────────────────────────────────────────────────────────────────────
  660.  
  661.       Files:                Size:  Install:
  662. @movecstr(8, 48, 15+16, "Current Installation Uses: @TmpDiskReqStr")
  663. @movecstr(21, 2, 15+32, " [Arrow Keys]=Scroll   [SPACE]=Toggle                                         ")
  664. @movecstr(22, 2, 15+32, "      [ENTER]=Accept                                               [ESC]=Quit ")
  665. @endoption
  666.  
  667. // change required disk space
  668. @DiskReq = (0)
  669. @if (41 [= @option)
  670.    @DiskReq = (@DiskReq + @ProgramReqM * @M)
  671. @endif
  672. @if (42 [= @option)
  673.    @DiskReq = (@DiskReq + @ModelReqK * @K)
  674. @endif
  675. @if (43 [= @option)
  676.    @DiskReq = (@DiskReq + @CADReqK * @K)
  677. @endif
  678. @if (44 [= @option)
  679.    @DiskReq = (@DiskReq + @PictureReqM * @M)
  680. @endif
  681. @if (45 [= @option)
  682.    @DiskReq = (@DiskReq + @FontReqM * @M)
  683. @endif
  684. @if (46 [= @option)
  685.    @DiskReq = (@DiskReq + @CameraReqK * @K)
  686. @endif
  687. @if (47 [= @option)
  688.    @DiskReq = (@DiskReq + @MatReqK * @K)
  689. @endif
  690. @if ((@HasProcFiles == 1) && (48 [= @option))
  691.    @DiskReq = (@DiskReq + @ProcReqK * @K)
  692. @endif
  693. @if ((@HasAnimScripts == 1) && (50 [= @option))
  694.    @DiskReq = (@DiskReq + @ScriptReqK * @K)
  695. @endif
  696. @DiskReqK = (@DiskReq / @K)
  697.  
  698. @goto SETTINGS
  699.  
  700.  
  701. CONTINUE:
  702.  
  703. // check required disk space
  704. @if (@DiskReq == 0)
  705. @Display
  706. @cls
  707.    No files chosen for installation.
  708.     @pause
  709. @enddisplay
  710. @goto SETTINGS
  711. @endif
  712.  
  713.  
  714. // Disk Space less than required for installation
  715. @if (@DiskReqK > @DiskFreeK)
  716. @Display
  717.   @cls
  718.   Insufficient Disk Space
  719.   ──────────────────────────────────────────────────────────────────────────
  720.   The current installation of @Name requires
  721.   @DiskReqK K of disk space, but only @DiskFreeK K of disk space is
  722.   available on the Program Drive you have chosen. Select another Program
  723.   Drive, reduce the amount of disk space required by installing fewer files
  724.   or Quit the installation and delete some files before installing
  725.   @Name.
  726.   ──────────────────────────────────────────────────────────────────────────
  727.                 @pause
  728. @enddisplay
  729. @goto SETTINGS
  730. @endif
  731.  
  732. // Get the serial number if they installed the executable
  733. @if (41 [= @option)
  734. @getstring @SerialNumber
  735.   Serialization
  736.   ─────────────────────────────────────────────────────────────────────────
  737.   Enter the serial number for your copy of @Name.
  738.   You will find it on your registration card.  Look for a number in the
  739.   following format:  XXXX-XXXX-XXXX
  740.   ─────────────────────────────────────────────────────────────────────────
  741.  
  742.   Note: You must enter a serial number for @Name
  743.   to be installed. [Esc] will stop installation.
  744. @movecstr(21, 2, 15+32, " [ENTER]=Accept                                                               ")
  745. @movecstr(22, 2, 15+32, "                                                                   [ESC]=Quit ")
  746. @move(10, 3)
  747. @Prompt = " Serial Number: "
  748. @endstring
  749.  
  750. @if (@strlen(@SerialNumber) == 0)
  751. @goto CONTINUE
  752. @endif
  753. @endif /* option 41 */
  754.  
  755.  
  756. INSTALL:
  757.  
  758. // Make required directories
  759. @if (@HasModels == 1)
  760.    @mkdir("@outdrive:@Models")
  761. @endif
  762. @if (@HasCAD == 1)
  763.    @mkdir("@outdrive:@CAD")
  764. @endif
  765. @if (@HasPics == 1)
  766.    @mkdir("@outdrive:@Pictures")
  767. @endif
  768. @if (@HasBatch == 1)
  769.    @mkdir("@outdrive:@Batch")
  770. @endif
  771. @if (@HasCams == 1)
  772.    @mkdir("@outdrive:@Cameras")
  773. @endif
  774. @if (@HasFonts == 1)
  775.    @mkdir("@outdrive:@Fonts")
  776. @endif
  777. @if (@HasMats == 1)
  778.    @mkdir("@outdrive:@Material")
  779. @endif
  780. @if (@HasAnims == 1)
  781.    @mkdir("@outdrive:@Script")
  782. @endif
  783. @if (@HasProcs == 1)
  784.    @mkdir("@outdrive:@Procs")
  785. @endif
  786. @if (@HasRMAN == 1)
  787.    @mkdir("@outdrive:\\@Subdir\\rman")
  788. @endif
  789. @if (@HasDVE == 1)
  790.    @mkdir("@outdrive:@DVE")
  791. @endif
  792. // Make a TSR files directory
  793. @mkdir("@outdrive:\\@Subdir\\vesa")
  794. @mkdir("@outdrive:\\@Subdir\\aawin")
  795. @mkdir("@outdrive:\\@Subdir\\ffutil")
  796.  
  797. @definedisk
  798.    @label = "@Name v@Version disk 1"
  799.    @if (41 [= @option)
  800.       @file read_me.txt
  801.       @beginlib @Exefile.001
  802.      @file @Exefile.exe @out @outdrive:\@Subdir\*.*
  803.       @endlib
  804.    @endif
  805. @enddisk
  806.  
  807. @definedisk
  808.    @label = "@Name v@Version disk 2"
  809.    @if (41 [= @option)
  810.       @beginlib @Exefile.002
  811.      @file @Exefile.exe @out @outdrive:\@Subdir\*.*
  812.       @endlib
  813.       @beginlib support.lif
  814.      @file *.* @out @outdrive:\@Subdir\*.*
  815.       @endlib
  816.       @if (@HasRMAN == 1)
  817.      @beginlib rman.lif
  818.         @file *.* @out @outdrive:\@Subdir\rman\*.*
  819.      @endlib
  820.       @endif
  821.       @beginlib setup.lif
  822.      @file *.* @out @outdrive:\@Subdir\*.*
  823.       @endlib
  824.       @beginlib vesa.lif
  825.          @file *.* @out @outdrive:\@Subdir\vesa\*.*
  826.       @endlib
  827.       @beginlib aawin.lif
  828.      @file *.* @out @outdrive:\@Subdir\aawin\*.*
  829.       @endlib
  830.       @beginlib ffutil.lif
  831.      @file *.* @out @outdrive:\@Subdir\ffutil\*.*
  832.       @endlib
  833.    @endif // option 41
  834.    @if ((@ProcReqK > 0) && (48 [= @option))
  835.       @beginlib procs.lif
  836.      @file *.* @out @outdrive:\@Procs\*.*
  837.       @endlib
  838.    @endif
  839.    @if ((@MatReqK > 0) && (47 [= @option))
  840.       @beginlib material.lif
  841.      @file *.* @out @outdrive:\@material\*.*
  842.       @endlib
  843.    @endif // option 47
  844.    @if ((@CameraReqK > 0) && (46 [= @option))
  845.       @beginlib cameras.lif
  846.      @file *.* @out @outdrive:\@Cameras\*.*
  847.       @endlib
  848.    @endif // option 46
  849. @enddisk
  850.  
  851. @definedisk
  852.    @label = "@Name v@Version disk 3"
  853.    @if ((@PictureReqM > 0) && (44 [= @option))
  854.       @beginlib pictures.lif
  855.      @file *.* @out @outdrive:\@Pictures\*.*
  856.       @endlib
  857.    @endif // option 44
  858.    @if (@HasDVE == 1)
  859.       @beginlib dvafiles.lif
  860.      @file *.* @out @outdrive:\@DVE\*.*
  861.       @endlib
  862.    @endif
  863. @enddisk
  864.  
  865. @definedisk
  866.    @label = "@Name v@Version disk 4"
  867.    @if ((@FontReqM > 0) && (45 [= @option))
  868.       @beginlib fonts.lif
  869.      @file *.* @out @outdrive:\@Fonts\*.*
  870.       @endlib
  871.    @endif // option 45
  872. @enddisk
  873.  
  874. END:
  875.  
  876. @finish
  877.  
  878. @chdrive @outdrive
  879. @chdir "@subdir"
  880.  
  881. @if (41 [= @option)
  882.    // update serial number
  883.    @if (@system("serial @SerialNumber") != 0)
  884.       Unable to serialize @Name.
  885.    @endif
  886.    @if (@system("del serial.exe") != 0)
  887.       Unable to delete serial.exe.
  888.    @endif
  889. @endif
  890.  
  891.  
  892. // If they installed the executable and they don't have a .cfg file
  893. // then run the mini-setup
  894. @if ((@Exists("@OutDrive:\\@SubDir\\@CFGName.CFG") != @True) && (41 [= @option))
  895.    @cls
  896.  
  897.   // Create an initial .CFG file with default graphics driver
  898.    @if ((@videocard == 'V') && (@spawn("isvesa") != 0))
  899.       @write("@CFGName.CFG", "at", "Screen STD_VGA.s32   # \"VGA (Standard VGA)\"\n")
  900.    @else
  901.       @write("@CFGName.CFG", "at", "Screen VESA_VGA.s32   # \"VESA Compatible VGA (no TSR)\"\n")
  902.    @endif
  903.  
  904.    @if (@system("setup msetup.dat @RunBatch") != 0)
  905.       Unable to execute setup.
  906.    @endif
  907. @else
  908.    @cls
  909.   Installation Complete
  910.   ──────────────────────────────────────────────────────────────────────────
  911.   To run the software, type @Runbatch at the DOS prompt, and hit enter. To
  912.   customize your software preferences, type SETUP at the DOS prompt and hit
  913.   enter.
  914.   ──────────────────────────────────────────────────────────────────────────
  915.    @pause
  916. @endif
  917. @if (41 [= @option)
  918.    @if (@system("del isvesa.com") != 0)
  919.       Unable to delete isvesa.com.
  920.    @endif
  921. @endif
  922.  
  923. // Create a batch file at the root directory of the C: drive to run the SW.
  924. @if (@Exists("C:\\@RunBatch.BAT") == @False)
  925.    @write("C:\\@RunBatch.BAT", "at", "\@ECHO OFF\n")
  926.    @write(, , "@OutDrive:\n")
  927.    @write(, , "CD \\@SubDir\n")
  928.    @write(, , "@RunBatch\n")
  929. @endif
  930.  
  931. // no need to ifdef this, cause if they can't change it, they didnt
  932. @if (31 [! @option)        /* Model path has changed */
  933.    @write("@CFGName.CFG", "at", "ModelPath @Models\n")
  934.    @write(, , "OBFPath @Models\n")
  935.    @write(, , "GroupPath @Models\n")
  936.    @write(, , "AMFPath @Models\n")
  937. @endif
  938.  
  939. @if (32 [! @option)        /* CAD path has changed */
  940.    @write("@CFGName.CFG", "at", "DXFPath @CAD\n")
  941.    @write(, , "IGESPath @CAD\n")
  942. @endif
  943.  
  944. @if (33 [! @option)        /* Pictures path has changed */
  945.    @write("@CFGName.CFG", "at", "PicturePath @Pictures\n")
  946. @endif
  947.  
  948. @if (34 [! @option)        /* Fonts path has changed */
  949.    @write("@CFGName.CFG", "at", "FontPath @Fonts\n")
  950. @endif
  951.  
  952. @if (35 [! @option)        /* Cameras path has changed */
  953.    @write("@CFGName.CFG", "at", "CameraPath @Cameras\n")
  954. @endif
  955.  
  956. @if (36 [! @option)        /* Procedural path has changed */
  957.    @write("@CFGName.CFG", "at", "ProceduralPath @Procs\n")
  958. @endif
  959.  
  960. @if (37 [! @option)        /* Script path has changed */
  961.    @write("@CFGName.CFG", "at", "AnimPath @Script\n")
  962. @endif
  963.  
  964. @if (38 [! @option)        /* Batch path has changed */
  965.    @write("@CFGName.CFG", "at", "BatchPath @Batch\n")
  966. @endif
  967.  
  968. @if (39 [! @option)        /* Material path has changed */
  969.    @write("@CFGName.CFG", "at", "MatPath @Material\n")
  970. @endif
  971.  
  972. @if (40 [! @option)        /* Material path has changed */
  973.    @write("@CFGName.CFG", "at", "DVEImages @DVE\n")
  974. @endif
  975.  
  976. @if ((@Exists("@OutDrive:\\@SubDir\\@CFGName.CFG") == @False) && (41 [= @option))
  977.    @write("@CFGName.CFG", "at", "ShiftfKey 1 Grid\n")
  978.    @write(, , "ShiftfKey 2 View Mode\n")
  979.    @write(, , "ShiftfKey 3 Show Tree\n")
  980.    @write(, , "ShiftfKey 4 Hide All\n")
  981.    @write(, , "ShiftfKey 5 Show All\n")
  982.    @write(, , "ShiftfKey 6 Axes:\n")
  983.    @write(, , "ShiftfKey 7 Camera:\n")
  984.    @write(, , "ShiftfKey 8 Polygon Plane\n")
  985.    @write(, , "ShiftfKey 9 Keyframe\n")
  986.    @write(, , "ShiftfKey 10 Edit Frame\n")
  987. @endif
  988.  
  989. @endfinish
  990.