home *** CD-ROM | disk | FTP | other *** search
/ Revista CD Expert 42 / CDGAMER42.iso / Egoboo / egoboo.exe / egoboo / modules / advent.mod / objects / ubutton.obj / script.txt < prev    next >
Text File  |  1999-06-27  |  1KB  |  39 lines

  1. // ZZ> This function makes the button go up or down
  2. tmpx = 20                // Threshold weight
  3. tmpy = weight                // Weight of characters on top
  4. IfXIsLessThanY                //
  5.   tmpargument = 1              //
  6.   IfStateIs                  // Only go down if it's up
  7.     tmpargument = 1                // NOP
  8.   Else                      //
  9.     tmpargument = ACTIONMG            //
  10.     DoAction                    //
  11.       tmpargument = 1                  // 1 is down
  12.       SetState                      //
  13.       tmpargument = passage              //
  14.       OpenPassage                  //
  15.       KeepAction                  // Make it stay on last frame
  16.       tmpargument = 5                  //
  17.       SetBumpHeight                  //
  18. Else                    // Pop up
  19.   tmpargument = 1              //
  20.   IfStateIs                  // Only pop up if it's down
  21.     tmpargument = ACTIONMJ            //
  22.     DoAction                    //
  23.       tmpargument = 0                  // 0 is up
  24.       SetState                      //
  25.       KeepAction                  // Make it stay on last frame
  26.       tmpargument = 35                  //
  27.       SetBumpHeight                  //
  28.       tmpargument = passage              // Make sure it goes up
  29.       ClosePassage                  //
  30.         tmpargument = 2                    // NOP
  31.       Else                      //
  32.         tmpargument = 2                    //
  33.         SetState                    //
  34.   tmpargument = 2              //
  35.   IfStateIs                  //
  36.     tmpargument = passage            //
  37.     ClosePassage                //
  38. End                    // Finished with this character
  39.