home *** CD-ROM | disk | FTP | other *** search
/ 600 Games / 600games.iso / Aventura / the_lost_vikings.swf / scripts / DefineSprite_626_HelpClass / frame_1 / DoAction.as
Encoding:
Text File  |  2007-03-20  |  1.6 KB  |  84 lines

  1. function Help_Stop(label)
  2. {
  3.    if(this.Obj_Flags & 0x40)
  4.    {
  5.       _root.KeyLocked = 0;
  6.       this.kill();
  7.    }
  8.    else
  9.    {
  10.       this.gotoAndPlay(label);
  11.    }
  12. }
  13. function Help_Win(label)
  14. {
  15.    if(this.Obj_Flags & 0x40)
  16.    {
  17.       _root.KeyLocked = 0;
  18.       this.kill();
  19.       _root.quitGame();
  20.       _root.gotoWin();
  21.    }
  22.    else
  23.    {
  24.       this.gotoAndPlay(label);
  25.    }
  26. }
  27. function Help_Lose(label)
  28. {
  29.    if(this.Obj_Flags & 0x40)
  30.    {
  31.       _root.KeyLocked = 0;
  32.       this.kill();
  33.       _root.quitGame();
  34.       _root.gotoLose();
  35.    }
  36.    else
  37.    {
  38.       this.gotoAndPlay(label);
  39.    }
  40. }
  41. function Help_Cont(label)
  42. {
  43.    if(this.Obj_Flags & 0x40)
  44.    {
  45.       this.Obj_Flags &= 65471;
  46.    }
  47.    else
  48.    {
  49.       this.gotoAndPlay(label);
  50.    }
  51. }
  52. function Help_Loop()
  53. {
  54.    if(this.Keys_pressed[8] & _root.Bits_on[1] || this.Keys_pressed[10] & _root.Bits_on[3] || this.Keys_pressed[4] & _root.Bits_on[6])
  55.    {
  56.       this.Obj_Flags |= 64;
  57.    }
  58. }
  59. this.setHndlr(1,Help_Loop);
  60. this.gotoAndPlay("Help_None");
  61. _root.KEY_LT = 37;
  62. _root.KEY_RT = 39;
  63. _root.KEY_UP = 38;
  64. _root.KEY_DN = 40;
  65. _root.KEY_A = 65;
  66. _root.KEY_B = 83;
  67. _root.KEY_LB = 81;
  68. _root.KEY_RB = 87;
  69. _root.KEY_CHEAT = 17;
  70. _root.Obj_Flags_ALWAYSRUN = 384;
  71. _root.Obj_Flags_BACKGROUND = 256;
  72. _root.Obj_Flags_MICKEY = 128;
  73. _root.Obj_Flags_DEAD = 64;
  74. _root.Obj_Flags_SPECIAL = 32;
  75. _root.Obj_Flags_KILL = 16;
  76. _root.Obj_Flags_KEYBD = 8;
  77. _root.Obj_Flags_GONE = 4;
  78. _root.Obj_Flags_ATTACK = 2;
  79. _root.Obj_Flags_CLIMBING = 1;
  80. this.Obj_X1 = -5;
  81. this.Obj_X2 = 5;
  82. this.Obj_Y1 = -31;
  83. this.Obj_Y2 = 0;
  84.