Tomb Rabbit presets

Version:

1.0

Added on:

10 Feb 2013 12:23

Tags:

Description:
Nothing special, it's just a bunch of basic expression to use in a Tomb Rabbit level.
//TOMB RABBIT LEVELS PRESETS
uint minimusic = 0;  //Mini musics to use for trigger events and enemy ambushes.
void onLevelLoad()
{
p.jumpStrength = -5;  //Harshly reduces the character's jump height.
jjObjectPresets[OBJECT::BAT].energy = 10;
jjObjectPresets[OBJECT::BEE].energy = 10;
jjObjectPresets[OBJECT::DEMON].energy = 90;
jjObjectPresets[OBJECT::DOGGYDOGG].energy = 30;
jjObjectPresets[OBJECT::DRAGON].energy = 10;
jjObjectPresets[OBJECT::LIZARD].energy = 10;
jjObjectPresets[OBJECT::MONKEY].energy = 20;
jjObjectPresets[OBJECT::NORMTURTLE].energy = 10;
jjObjectPresets[OBJECT::RAVEN].energy = 20;
jjObjectPresets[OBJECT::SKELETON].energy = 120;
jjObjectPresets[OBJECT::STANDMONKEY].energy = 20;
jjObjectPresets[OBJECT::TUFTURT].energy = 40;
jjObjectPresets[OBJECT::BLASTERBULLET].counterEnd = 250;
jjObjectPresets[OBJECT::BOUNCERBULLET].counterEnd = 250;
jjObjectPresets[OBJECT::ICEBULLET].counterEnd = 250;
jjObjectPresets[OBJECT::ICEBULLET].xSpeed = -4;
jjObjectPresets[OBJECT::SEEKERBULLET].animSpeed = 10;
jjObjectPresets[OBJECT::SEEKERBULLET].counterEnd = 250;
jjObjectPresets[OBJECT::RFBULLET].animSpeed = 5;
jjObjectPresets[OBJECT::ELECTROBULLET].xSpeed = 0;
jjObjectPresets[OBJECT::ELECTROBULLET].ySpeed = 0;
jjObjectPresets[OBJECT::BOUNCERBULLET].animSpeed = 5;
jjObjectPresets[OBJECT::ELECTROBULLET].animSpeed = 110;
}
void onMain()
{
p.alreadyDoubleJumped = true;
p.food = 50;                    //numbers 0-98 would work as well, anti-sugar rush mode.
p.xSpeed = p.xSpeed * 0.875;    //This command will reduce the character's speed.
if (p.ySpeed < -7) //These commands
{                  //are meant
p.xPos = p.xOrg;   //to prevent
p.yPos = p.yOrg;   //the characters
p.ySpeed = 0;      //from using
}                  //their special
if (p.xSpeed < -9  //moves.
|| p.xSpeed > 9)   //They also
{                  //relocate
p.xPos = p.xOrg;   //the player
p.yPos = p.yOrg;   //to the start
p.xSpeed = 0;      //so he can't
}                  //kill enemies.
if (p.currWeapon == WEAPON::BLASTER) //Regular Gun almost
p.fastfire = 1000;                   //has no auto trigger.
if (p.currWeapon == WEAPON::BOUNCER) //Bouncer shoots
p.fastfire = 10;                     //WAY faster.
if (p.currWeapon == WEAPON::ICE)     //Same as
p.fastfire = 1000;                   //the Blaster.
if (p.currWeapon == WEAPON::GUN8)    //Let the trigger quickly
p.fastfire = 1;                      //or you will waste all the pepper!
if (p.currWeapon == WEAPON::TOASTER) //Toasty Gun creates
p.fastfire = 0;                      //a ravaging firestorm.
if (p.currWeapon == WEAPON::GUN9)    //Electro Blaster
p.fastfire = 20;                     //shoots a little faster.
if (minimusic > 0)
minimusic = minimusic - 1;   //How long the mini music lasts.
}
void onPlayer()
{
p.cameraFreeze(p.xPos, p.yPos, true, true);  //This command will center the camera even more.
p.lives = 1;                                 //Same as unlimited lives
}
void onFunction1() { p.morphTo(CHAR::JAZZ, false); } //Spare a lot of televisions from blasts!
void onFunction2() { p.morphTo(CHAR::SPAZ, false); } //Become Jazz or Spaz according to the situation.
//THERE ARE STILL A FEW THINGS I CAN'T WORK OUT, LIKE MAKING THE SPIKES KILL YOU EVEN AT FULL HEALTH, SETTING MAX HEALTH IN SP MODE, MAKING BOLDERS KEEP ON ROLLING EVEN WHEN THEY TOUCH THE CHARACTER AND DISABLING HORIZONTAL MOVES IN MIDAIR.