Tile Behaviour Combinations

Contents
1. Bouncy Behaviour

1. Bouncy Behaviour

Import code below using ASM Patch Template. Can be used as the note block.

#include "nsmb.h"

void doBehavior(MarioActor* athis, u32 i)
{
        if(i == 0x000100FF)
        {
                athis->yAccel = 17000;
                athis->yPos += 300;
                athis->xAccel = 0;
        }
}

void hook_0211f840(MarioActor* athis)
{
        u32 x = athis->xPos>>12;
        u32 y = (-athis->yPos)>>12;
        doBehavior(athis, getTileBehaviorAtPos2(x+6, y+3));
        doBehavior(athis, getTileBehaviorAtPos2(x-6, y+3));
}


Adds tile behavior "FF 00 01 00". Stuff taken from dead NSMBCR.

Remember that this will not give you an animated tile. Just the upward momentum.

Everything above is quoted from RicBent. Code is shared within NSMBCR but can be used in personal hacks.