Jump to content

Photo

Gameboy mini boss warp?


  • Please log in to reply
21 replies to this topic

#1 Lemmy Koopa

Lemmy Koopa

    We are the champions

  • Members
  • Location:Ohio

Posted 21 June 2010 - 12:10 AM

Can someone script the mini boss warp from the Gameboy Zelda games?

#2 Moosh

Moosh

    Tiny Little Questmaker

  • ZC Developers

Posted 21 June 2010 - 12:30 PM

This can be done without scripting using screen state carryovers.

#3 Lemmy Koopa

Lemmy Koopa

    We are the champions

  • Members
  • Location:Ohio

Posted 24 June 2010 - 06:01 AM

QUOTE(Pokemonmaster64 @ Jun 21 2010, 01:30 PM) View Post

This can be done without scripting using screen state carryovers.


How would I do that? I tried to carry over the mini boss screen to the dungeon entrance screen but nothing changes.

#4 cosmofield

cosmofield

    Magical Girl

  • Members
  • Location:Sweden

Posted 24 June 2010 - 10:17 AM

QUOTE(Hot Water Music man @ Jun 24 2010, 01:01 PM) View Post

How would I do that? I tried to carry over the mini boss screen to the dungeon entrance screen but nothing changes.


The room needs to have the "treat as interior" option set.

#5 Lemmy Koopa

Lemmy Koopa

    We are the champions

  • Members
  • Location:Ohio

Posted 24 June 2010 - 06:49 PM

I did that and it still doesn't do it.
Do I do it in the room where the boss is?

I want it to make the entrance's secrets go off when I defeat the boss and the boss room's secrets go off.

Edited by Hot Water Music man, 24 June 2010 - 06:57 PM.


#6 Mariolink263

Mariolink263

    Senior

  • Members
  • Real Name:Nick
  • Location:Mushroom Hyrule

Posted 24 June 2010 - 10:16 PM

In the part where you set the Room to Carry over, check the box
No Reset-> Secrets

#7 Lemmy Koopa

Lemmy Koopa

    We are the champions

  • Members
  • Location:Ohio

Posted 25 June 2010 - 12:31 AM

STILL not working.

edit: Nevermind I didn't know you had to set both of them to carry over to eachother.

Edited by Hot Water Music man, 25 June 2010 - 02:04 AM.


#8 Joe123

Joe123

    Retired

  • Members

Posted 26 June 2010 - 08:09 AM

pkmnfrk wrote one over at AGN.

#9 Lemmy Koopa

Lemmy Koopa

    We are the champions

  • Members
  • Location:Ohio

Posted 26 June 2010 - 09:54 AM

Could someone help me set up the script?
Do I place it in both rooms?
what's the "level" argument mean?

I tried to mess with it but nothing shows up when I kill the boss.
I think I did the script wrong.

CODE

//Global variables
int mb_defeated=0;

//Function written by Mike Caron. See credits section below.
int setbit(int v, int num, bool b)
{
    int mask = Pow(2, num);
    
    if(b) return (v | mask);
    else if(getbit(v,num)) return(v - mask);
    else return(v);
}

//Function written by Mike Caron. See credits section below.
bool getbit(int v, int num)
{
    if(num <= 0) return(false);
    
    int ret = v >> num;
    return((ret & 1b) == 1);
}

//If a miniboss consists of standard/custom enemies, attach this
//script to an FFC and place it anywhere in the miniboss room. Set
//the enemy flag "Dungeon Boss" to prevent enemies from returning.
//D0: level #
ffc script miniboss_versionone
{
    void run(int lev)
    {
        if(!getbit(mb_defeated,lev)) //if miniboss has not been defeated
        {
            while(Screen->NumNPCs()==0) Waitframe(); //wait until the enemy (or enemies) appear
            while(Screen->NumNPCs()>0) Waitframe(); //wait until all of the enemies are killed
            mb_defeated=setbit(mb_defeated,lev,true);
        }
    }
}

//Original function was written by Mike Caron. See credits section below.
//Modified slightly by Elmensajero
//D0: level #
//D1: combo id of a sensitive warp combo
//Setup: Use a transparent combo for the ffc and place it on the tile where you want the
//    warp portal to appear. Next, use the input D1 to specify where the warp portal is
//    located in the combo pages. Set the tile warp through ZQuest, and make sure Link
//    does not appear on another warp, or he will keep on warping between them forever.
ffc script minibosswarp
{
    void run(int lev, int wt)
    {
        //Wait until the miniboss is dead
        while(getbit(mb_defeated, lev) == false) Waitframe();
        
        //Change ffc to warp portal
        this->Data=wt;
        
        //In case he's standing on top of the warp when it appears
        while(Link->X + 8 >= this->X && Link->X <= this->X + 8 && Link->Y + 8 >= this->Y && Link->Y <= this->Y + 8) Waitframe();
        while(Link->X + 8 < this->X || Link->X > this->X + 8 || Link->Y + 8 < this->Y || Link->Y > this->Y + 8) Waitframe();
        
        Link->X = this->X;
        Link->Y = this->Y;
        Link->Action = LA_FROZEN;
        Link->Dir = DIR_DOWN;
        
        int i;
        
        for(i = 6; i >= 0; i--)
        {
            Link->Dir = DIR_LEFT;
            Waitframes(i);
            Link->Dir = DIR_UP;
            Waitframes(i);
            Link->Dir = DIR_RIGHT;
            Waitframes(i);
            Link->Dir = DIR_DOWN;
            Waitframes(i);
        }
        Link->Action = LA_NONE;
        
        Screen->ComboD[ComboAt(Link->X, Link->Y)] = wt;
        Waitframe();
    }
}

Edited by Hot Water Music man, 26 June 2010 - 10:10 AM.


#10 Lemmy Koopa

Lemmy Koopa

    We are the champions

  • Members
  • Location:Ohio

Posted 29 June 2010 - 07:18 AM

So I guess no one can help me with this?

#11 Joe123

Joe123

    Retired

  • Members

Posted 29 June 2010 - 11:50 AM

OK, I liked the idea of pkmnfrk's but I wasn't mad keen on how he wrote it and I made my own version, I'll give it a poke around and then post it up for you.

#12 Lemmy Koopa

Lemmy Koopa

    We are the champions

  • Members
  • Location:Ohio

Posted 29 June 2010 - 12:52 PM

Well I'm using state carry overs right now, but I'd like the spinning and warping effect with the sfx like in the Gameboy version.

#13 Joe123

Joe123

    Retired

  • Members

Posted 29 June 2010 - 12:58 PM

Yeah, I've got half a code going on here, when I'm finished I'll post it up.

#14 Lemmy Koopa

Lemmy Koopa

    We are the champions

  • Members
  • Location:Ohio

Posted 01 July 2010 - 11:41 AM

Thanks

#15 Lemmy Koopa

Lemmy Koopa

    We are the champions

  • Members
  • Location:Ohio

Posted 06 July 2010 - 03:30 AM

Getting any closer to getting the script done? no rush.


0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users