home *** CD-ROM | disk | FTP | other *** search
/ 600 Games / 600games.iso / Acao / batman_cobble.swf / scripts / frame_22 / DoAction.as < prev   
Encoding:
Text File  |  2006-06-13  |  1.9 KB  |  72 lines

  1. _root.game.onEnterFrame = _global.cameraLogic;
  2. _root.game.player.onEnterFrame = _global.playerLogic;
  3. _root.game.combo.onEnterFrame = _global.comboLogic;
  4. for(n in _root.game)
  5. {
  6.    if(n.substring(0,4) == "boss")
  7.    {
  8.       _root.game[n].onEnterFrame = _global.penguinAI;
  9.       _root.game[n].speed = 6;
  10.       _root.game[n].dir = 1;
  11.       _root.game[n].state = "stand";
  12.       _root.game[n].jumping = false;
  13.       _root.game[n].health = 200;
  14.       _root.game[n].range = 0;
  15.       _root.game[n].stength = 5;
  16.       _root.game[n].enemyHeight = 50;
  17.       _root.game[n].enemyWidth = 50;
  18.       _root.game[n].attackCount = 0;
  19.       _root.game[n].fallCount = 0;
  20.       _root.game[n].dy = 0;
  21.       _root.game[n].enemy_y = _root.game[n]._y;
  22.    }
  23.    if(n.substring(0,7) == "item_br")
  24.    {
  25.       _root.game[n].onEnterFrame = _global.itemLogic;
  26.    }
  27.    if(n.substring(0,6) == "health")
  28.    {
  29.       _root.game[n].onEnterFrame = _global.lifeLogic;
  30.    }
  31. }
  32. stop();
  33. _root.gravity = 5;
  34. _root.globalGravity = 5;
  35. _root.FPS = 0;
  36. _root.fpsSet = false;
  37. _root.frameCount = 0;
  38. _root.gotoLast = "level1c";
  39. _root.camDelay = 0;
  40. _root.camHeight = 270;
  41. _root.camJump = 4;
  42. _root.camMin = 250;
  43. _root.camMax = 2150;
  44. _root.camOffset = 0;
  45. _root.camZoom = 100;
  46. _root.playerDx = 0;
  47. _root.playerDy = 0;
  48. _root.playerDir = 1;
  49. _root.playerSpeed = 19;
  50. _root.playerState = "fall";
  51. _root.playerJumping = true;
  52. _root.playerAttacking = false;
  53. _root.playerShooting = false;
  54. _root.playerSwinging = false;
  55. _root.playerInvincible = false;
  56. _root.playerLives = 3;
  57. _root.playerOnElevator = false;
  58. if(_root.playerHealth == undefined || _root.playerHealth <= 0)
  59. {
  60.    _root.playerHealth = 100;
  61. }
  62. _root.playerStrength = 10;
  63. _root.playerHeight = 75;
  64. _root.playerWidth = 50;
  65. _root.weaponCount = 1000;
  66. _root.currentWeapon = "batarang";
  67. _root.comboMeter = false;
  68. _root.bgScroll = 6;
  69. _root.key_z = false;
  70. _root.key_x = false;
  71. _root.key_c = false;
  72.