Name | Author | Game Mode | Rating | |||||
---|---|---|---|---|---|---|---|---|
RabbitCity 2 | P4rr0t | Single player | 7.7 |
/*************************************************
Created by Parrot86 - RabbitCity 2: The Secret Room
*************************************************/
void onLevelLoad() {
jjAlert("||Level Name: |Welcome To Airship 13 / 15");
jjAlert("||RabbitCity 2: The Secret Room - Level: |76");
jjAlert("");
jjAlert("");
jjTexturedBGFadePositionY = -0;
jjUseLayer8Speeds = true;
// Blaster is limited ammo - Thank for zepect!
jjWeapons[WEAPON::BLASTER].infinite = false;
jjWeapons[WEAPON::BLASTER].maximum = maxBlaster;
}
//Blaster Reloading - Thank for zepect!
bool pressedR = false;
const int maxBlaster = 15;
void doReload() {
for(int i = 0; i < jjLocalPlayerCount; i++)
if(jjLocalPlayers[i].ammo[WEAPON::BLASTER] == 0)
jjLocalPlayers[i].ammo[WEAPON::BLASTER] = maxBlaster;
}
bool onDrawAmmo(jjPLAYER@ player, jjCANVAS@ canvas) {
if(player.ammo[WEAPON::BLASTER] == 0)
canvas.drawString(80, jjResolutionHeight - 30, "Press [R] to reload your Blaster!", STRING::MEDIUM, STRING::BOUNCE, 1);
return false;
}
// Doors - Thank for zepect!
array<bool> keyPressed(256, false); //arrays holds the state of the keys
int myArea = 0;
bool inArea(jjPLAYER@ p, int x1, int y1, int x2, int y2) {
return ((p.xPos > (x1*32)) && (p.xPos < x2*32 + 32) && (p.yPos > (y1*32)) && (p.yPos < y2*32 + 32));
}
void onKeyDown(jjPLAYER@ p, int key) {
if(key == 0x26) { //0x26 is up arrow key (all keys at http://msdn.microsoft.com/en-us/library/dd375731(VS.85).aspx)
if(myArea == 1) p.warpToID(2, true);
else if(myArea == 2) p.warpToID(1, true);
else if(myArea == 3) p.warpToID(4, true);
else if(myArea == 4) p.warpToID(3, true);
else if(myArea == 15) p.warpToID(16, true);
else if(myArea == 16) p.warpToID(15, true);
else if(myArea == 17) p.warpToID(18, true);
else if(myArea == 18) p.warpToID(17, true);
else if(myArea == 19) p.warpToID(20, true);
else if(myArea == 20) p.warpToID(19, true);
}
}
void onPlayer(jjPLAYER@ p) {
for(int i = 0; i < 256; i++) { //loop through all the keys
if(jjKey[i] && !keyPressed[i]) {
onKeyDown(p, i);
keyPressed[i] = true;
} else if(!jjKey[i] && keyPressed[i]) keyPressed[i] = false;
}
if(inArea(p, 601, 61, 601, 61)) myArea = 1;
else if(inArea(p, 610, 101, 610, 101)) myArea = 2;
else if(inArea(p, 644, 112, 644, 112)) myArea = 3;
else if(inArea(p, 567, 72, 567, 72)) myArea = 4;
else if(inArea(p, 370, 38, 370, 38)) myArea = 15;
else if(inArea(p, 587, 144, 587, 144)) myArea = 16;
else if(inArea(p, 150, 89, 150, 89)) myArea = 17;
else if(inArea(p, 139, 142, 139, 142)) myArea = 18;
else if(inArea(p, 150, 136, 150, 136)) myArea = 19;
else if(inArea(p, 140, 83, 140, 83)) myArea = 20;
else myArea = 0;
}
bool onDrawHealth(jjPLAYER@ player, jjCANVAS@ canvas) {
if(myArea == 1 || myArea == 2 || myArea == 3 || myArea == 4 || myArea == 15 || myArea == 16 || myArea == 17 || myArea == 18 || myArea == 19 || myArea == 20) {
canvas.drawString(135, 300, "Press UP to walk through!", STRING::MEDIUM, STRING::BOUNCE, 1);
}
return false;
}
void onMain() {
if(jjKey[0x52] && !pressedR) {
doReload();
pressedR = true;
} else if(!jjKey[0x52]) pressedR = false;
updateGems();
}
void updateGems()
{
for(int i=1;i<jjObjectCount;i++)
{
if(jjObjects[i].isActive)
{
if(jjObjects[i].eventID==OBJECT::SUPERGEM)
{
jjObjects[i].var[0]=jjParameterGet(jjObjects[i].xOrg/32,jjObjects[i].yOrg/32,0,2)+1;
}
if(jjObjects[i].eventID==OBJECT::FLICKERGEM)
{
if(jjEventGet(jjObjects[i].xOrg/32,jjObjects[i].yOrg/32)==OBJECT::SUPERGEM)
{
jjObjects[i].var[0]=jjParameterGet(jjObjects[i].xOrg/32,jjObjects[i].yOrg/32,0,2)+1;
}
else if(jjEventGet(jjObjects[i].xOrg/32,jjObjects[i].yOrg/32+1)==OBJECT::GEMSTOMP)
{
jjObjects[i].var[0]=jjParameterGet(jjObjects[i].xOrg/32,jjObjects[i].yOrg/32+1,0,2)+1;
}
if(jjObjects[i].var[0]==2||jjObjects[i].var[0]==3)
{
jjObjects[i].points=500*(jjObjects[i].var[0]-1);
}
}
}
}
}
void onFunction1() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("GreenSpaz:||||| Good job, Player!");
jjAlert("Player:||||| Yay, i found a silver key from Tuf Boss. Thanks!");
jjAlert("GreenSpaz:||||| Player, unlock this door for all jails, please");
jjAlert("Player:||||| OK, i find at another control room");
}
void onFunction2() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| Whoa, another helicopter from the second police station");
}
void onFunction3() {
p.kill();
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| AAAAHHH!");
}
void onFunction4() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| Can I suicide this? It's fall in death...");
}
void onFunction5() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| No rabbit allowed ? WAT!");
}
void onFunction6() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| Oh damn... video surveillance is here!");
}
void onFunction7() {
p.warpToID(0,true);
p.showText("@@@@Video Surveillance was detected you!", STRING::MEDIUM);
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("|*******************************************");
jjAlert("|*** WARNING! PLAYER HAS BEEN DETECTED ***");
jjAlert("|*******************************************");
jjAlert("");
}
void onFunction8() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("|*** NOTICE: RESTRICTED AREA ***");
jjAlert("This area is under 24hour video surveillance");
jjAlert("|*** WARNING! NO GUNS ALLOWED ***");
jjAlert("");
}
void onFunction9() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("|*** IT'S LOCKED ***");
jjAlert("");
jjAlert("Player:||||| Hmmm...");
}
void onFunction10() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| Hide my blaster, because my gun is not allowed here...");
}
void onFunction11() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("|*** IT'S LOCKED - ELEVATOR IS OUT OF ORDER ***");
jjAlert("");
jjAlert("Player:||||| this door will not open");
}
void onFunction12() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("|*** WARNING ***");
jjAlert("|*** ELEVATOR IS OUT OF ORDER - DO NOT ENTER ***");
jjAlert("Player:||||| Bhe...");
}
void onFunction13() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| Found a red card !");
}
void onFunction14() {
p.kill();
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("|*** Killed by Red Laser Of Death ***");
jjAlert("");
jjAlert("Player:||||| AUGH!!!");
}
void onFunction15() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| Red laser ?");
}
void onFunction16() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| Oh, Try hide boxes");
}
void onFunction17() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| Cannon? What the hell");
}
void onFunction18() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| Uh? This is Control laser cannon room!");
}
void onFunction19() {
p.kill();
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("|*** killed by Flame Burned ***");
jjAlert("");
jjAlert("Player:||||| AUGH!!!");
}
void onFunction20() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| Jail rabbit only? What is that ?");
}
void onFunction21() {
p.warpToID(0,true);
p.showText("@@@@Enemy was watched you!", STRING::MEDIUM);
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("|*******************************************");
jjAlert("|*** WARNING! PLAYER HAS BEEN DETECTED ***");
jjAlert("|*******************************************");
jjAlert("");
}
void onFunction22() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| Shh... It's two enemies, do not follow it");
}
void onFunction23() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("*** IT'S UNLOCKED - BLUE ACCESS CARD ***");
jjAlert("");
jjAlert("Player:||||| Oh My GOD!");
}
void onFunction24() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| Whoa!");
}
void onFunction25() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| Devan room??? Bleh...");
}
void onFunction26() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| Oh, Devan room is here !");
}
void onFunction27() {
jjAlert("|*** WARNING DO NOT USE starting fluid in big engines ***");
jjAlert("|||*** CAUTION: This is big engine damage will be destroy your airship!");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| Wow, is this really danger ?");
}
void onFunction28() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| Whooooaaaa, biggest engine...");
}
void onFunction29() {
p.showText("@@@@@@@@#YOU FOUND A SECRET!", STRING::MEDIUM);
}
void onFunction30() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| Uhm.... What happened to no more enemies ?");
}
void onFunction31() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("*** IT'S UNLOCKED - RED ACCESS CARD ***");
jjAlert("");
jjAlert("Player:||||| Yey!");
}
void onFunction32() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("|*** IT'S LOCKED - UNKNOWN ACCESS CARD REQIRED ***");
jjAlert("");
jjAlert("Player:||||| What is this ?");
}
void onFunction33() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| Uh ?");
}
void onFunction34() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| It's video surveillance is disabled ! Yay");
}
void onFunction35() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("Player:||||| Finally, the red laser is disabled !");
}
void onFunction36() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("*** IT'S UNLOCKED - SILVER KEY ***");
jjAlert("");
jjAlert("Player:||||| Yeeees!");
}
void onFunction37() {
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("");
jjAlert("People:||||| Help! PLAYER! Help me!");
jjAlert("Player:||||| Hmm it's locked, what can i do?");
}
void onDrawLayer4(jjPLAYER@ p, jjCANVAS@ canvas) {
canvas.drawString(654*32+10, 75*32-16, "|Airship 3000",STRING::MEDIUM);
canvas.drawString(603*32+10, 69*32-16, "||||LEVEL - D",STRING::MEDIUM);
canvas.drawString(439*32+10, 71*32-16, "||||LEVEL - C",STRING::MEDIUM);
canvas.drawString(225*32+10, 71*32-16, "||||LEVEL - B",STRING::MEDIUM);
canvas.drawString(138*32+10, 71*32-16, "||||LEVEL - A",STRING::MEDIUM);
canvas.drawString(246*32+10, 88*32-16, "||||<- Jail Rabbit Only",STRING::MEDIUM);
canvas.drawString(103*32+10, 88*32-16, "||||<- Engine Room",STRING::MEDIUM);
canvas.drawString(113*32+10, 70*32-16, "|<- Devan Room",STRING::SMALL);
canvas.drawString(58*32+10, 51*32-16, "|<- Devan Room",STRING::SMALL);
canvas.drawString(103*32+10, 51*32-16, "|<- Devan Room",STRING::SMALL);
canvas.drawString(26*32+10, 77*32-16, "||||HIGH VOLGATE",STRING::MEDIUM);
canvas.drawString(25*32+30, 75*32-16, "||DANGER",STRING::LARGE);
canvas.drawString(551*32+10, 23*32-16, "||||Control Room",STRING::SMALL);
}
Jazz2Online © 1999-INFINITY (Site Credits). We have a Privacy Policy. Jazz Jackrabbit, Jazz Jackrabbit 2, Jazz Jackrabbit Advance and all related trademarks and media are ™ and © Epic Games. Lori Jackrabbit is © Dean Dodrill. J2O development powered by Loops of Fury and Chemical Beats.
Eat your lima beans, Johnny.