Topic: Boost Rings (Version 2.0)

http://i826.photobucket.com/albums/zz187/SilverstepP/s000.png

V2.0
http://dl.dropbox.com/u/24102763/s014.png

Alpha (0.1)http://www.mediafire.com/?867f81y24c38aa2
Beta (0.2) http://www.mediafire.com/?w3d57cwd5zhvkao
Version 1.0 http://www.mediafire.com/?3jolrvtqpwpo8ja
Final Version http://dl.dropbox.com/u/24102763/BoostRingsFinal.zip



So... I'm now proving that the scripting system requires no programming knowledge... big_smile

This is 8 directional boost rings. I scripted them and made the gfx (improved and redone) myself. The ring will center your position and reset your momentum, which means you won't be flying around randomly like the springs send you. The known bugs have been resolved in version 1.0.

The reason these are present is because I can't change the action the player is doing as he/she enters the rings (in other words, if you jump into them, you stay in a ball if you hit the rings, and if you run through one and get propelled in the air, you continue running on thin air). Can I have any help with this issue (if anyone knows how)?

Also, these things are fun! You can make chain paths of them, make them act as one-way doors, or even make a full-blown maze of them. It all just depends on your creativity.

In the Beta:

The Cyan rings will add 300 to your score, but will disappear upon use. There is a sfx for them (which will be improved, I know it isn't all that good yet).

The GFX were redesigned to look more original.

They force you into a spring animation.

In the First Version:

The rings force you into a spring animation, which stopped the glitches and made it look cooler.

In the Final Version:

Absolutely all the code is redone and these now work with the new physics system. They look more original in graphics. I removed the Cyan rings, as I personally never really used them. If anyone else wants them again, I'll program those in as well.

(Requires variables in your release, so get the nightly build)

Where to put where:

obj goes in objects
spr's goes in sprites
png's goes in images
wav goes in samples

Requires: Nightly Build 229 or Higher
(500 or so with the newest version)

Last edited by SilverstepP (2011-07-04 02:33:53)

Re: Boost Rings (Version 2.0)

NICE FOR BIG RING

http://www.powersonic.com.br/downloads/gifs/sonic_32bits/sonicknucklesemeraldsma.gif

Re: Boost Rings (Version 2.0)

'updated'

Re: Boost Rings (Version 2.0)

lol. I haven't even finished documenting the stuff and you people are already using the technology tongue You guys should really help me out by documenting things. cool

This is really impressive, considering that the object scripting system hasn't been fully documented yet. In order to avoid the problems you've said, you can move the player yourself by disabling the platform movement. After you're done with the boost rings, you should enable the platform movement again. It's essentially the same technique as one could use if a simple pipe system was the object being made.

Again, things are not fully documented yet, but since you've made this, maybe you can figure things out.

Re: Boost Rings (Version 2.0)

I have just downloaded the beta and:

Loading sprite 'B'
Can't redefine sprite 'B'

You should really give better names to the sprites (i.e., put a prefix). Generic names like 'B' and 'C' can really mess things up, specially if the user has 50+ objects installed in his/her engine.

In short, there's a conflict.

Re: Boost Rings (Version 2.0)

Alexandre wrote:

I have just downloaded the beta and:

Loading sprite 'B'
Can't redefine sprite 'B'

You should really give better names to the sprites (i.e., put a prefix). Generic names like 'B' and 'C' can really mess things up, specially if the user has 50+ objects installed in his/her engine.

In short, there's a conflict.

Hmm.. I had trouble with the up left ring. That was the only one with one letter (That and its counterpart).
So wait, it doesn't work? But it works on mine...

Last edited by SilverstepP (2010-09-03 21:55:02)

Re: Boost Rings (Version 2.0)

Alexandre wrote:

In order to avoid the problems you've said, you can move the player yourself by disabling the platform movement. After you're done with the boost rings, you should enable the platform movement again.

I can't find the command for this.

Re: Boost Rings (Version 2.0)

Boost rings are amazing smile

Alex, I wanted to ask, is there an attribute to change the character action? Like to send them in a boost and also send them into a spin? It used to be p->spin; in the old code. I looked around I only saw change character animation which allows you to change into the "spin" animation but not the action. I also changed knuckles into LadyBugsy with the command with hilarious results (sorry I don't have the screenshot.

Last edited by wrath1138 (2010-09-04 04:32:17)

Re: Boost Rings (Version 2.0)

wrath1138 wrote:

Boost rings are amazing smile

Alex, I wanted to ask, is there an attribute to change the character action? Like to send them in a boost and also send them into a spin? It used to be p->spin; in the old code. I looked around I only saw change character animation which allows you to change into the "spin" animation but not the action. I also changed knuckles into LadyBugsy with the command with hilarious results (sorry I don't have the screenshot.

I can confirm that Knuckles is lady bugsy. He showed me this on Skype. big_smile

I need to be able to change the actions of the players to 'spring'...

Re: Boost Rings (Version 2.0)

No.

I don't want to mess up too much by creating very specific commands to interact with the movement engine because that's going to be rewritten, and this may cause incompatibilities later. Depending on what you're trying to do, these aren't necessary.

What are you trying to do?

I also changed knuckles into LadyBugsy with the command with hilarious results (sorry I don't have the screenshot.

wut? LOL

Re: Boost Rings (Version 2.0)

Alexandre wrote:

No.

I don't want to mess up too much by creating very specific commands to interact with the movement engine because that's going to be rewritten, and this may cause incompatibilities later. Depending on what you're trying to do, these aren't necessary.

What are you trying to do?

We're trying to force the player into a different 'action'. Like how hitting springs forces you into that 'flying up' action regardless of what you were doing before you hit it.

I was thinking something like player_change_action with one parameter. You could change it to 'running', 'walking', 'spinning', or 'spring'. That way we could make our items force players into actions... this is very important for these rings especially, as THIS may fix that flying glitch as well.

Plus, Wrath wants Sonic 4 Style Boosters that force you into a roll. big_smile Which could actually be fun.

Edit: I worded this way wrong the first time.

Last edited by SilverstepP (2010-09-04 05:07:26)

Re: Boost Rings (Version 2.0)

yeah that's how they worked in my code, they would boost you into a spin to kill enemies or send you out to S loops and ended up breaking walls. I guess the S loops can be done now without the boost needed but breaking walls and killing enemies at high speeds is still fun if done well. xD

Re: Boost Rings (Version 2.0)

there's no action such as "walking" or "running". It's just a matter of changing the speed of the character. You can't make it roll or get in spring mode. However, if you disable the movement of the player, you can do pretty much anything with it by using move_player.

Sonic 4 Style Boosters that force you into a roll

video?

Re: Boost Rings (Version 2.0)

We can actually create commands that make players roll and etc. , but the problem is that there are just too many actions that players can perform, and for each command we make now, we'd perhaps have to change it later when the new physics system gets released. So, people would be happy now with rolling and getting into spring mode, but then there is flying, gliding, climbing, getting invincible, getting super fast, bla bla bla... That will be fine when we finish the physics system, but for now it's complicated to have too many of these.

Making just these two (roll & spring) would be okay.

Re: Boost Rings (Version 2.0)

http://www.youtube.com/watch?v=PytOb0Z8Vh8

Its showcased in minute 1:20 onwards. Breaks walls and to kill enemies.

here is the old code I had, just a modification of springs.

case IT_SPEEDPADLEFT:
{
    speedpad_activate_on_touch(item, team, "SD_SPEEDPADLEFT", v2d_new(-1400,0));
    break;
}

/* SPEED PAD */
void speedpad_activate_on_touch(item_t *spring, player_t *team[], const char *animation, v2d_t strength)
{
    int i;
    sound_t *bang = sound_load("samples/spindash1.wav");
    animation_t *idle = sprite_get_animation(animation, 0);
    v2d_t hot_spot;
    double *bang_timer = &(spring->value[0]);

    /* timer */
    *bang_timer += game_delta();

    /* collision detection */
    for(i=0; i<3; i++) {
        if(!team[i]->dieing && actor_pixelperfect_collision(team[i]->actor, spring->actor)) 
        {
            team[i]->actor->speed.x = fabs(strength.x)>EPSILON ? strength.x : team[i]->actor->speed.x;
            team[i]->actor->speed.y = fabs(strength.y)>EPSILON ? strength.y : team[i]->actor->speed.y;
    
//spin        
            team[i]->spin = TRUE;

            team[i]->flying = team[i]->climbing = team[i]->landing = team[i]->getting_hit = team[i]->is_fire_jumping = FALSE;

            if(strength.x > EPSILON)
                team[i]->actor->mirror &= ~IF_HFLIP;
            else if(strength.x < -EPSILON)
                team[i]->actor->mirror |= IF_HFLIP;


            hot_spot = spring->actor->hot_spot;
            actor_change_animation(spring->actor, sprite_get_animation(animation, 1));
            spring->actor->hot_spot = hot_spot;
            if(*bang_timer >= SPRING_BANG_TIMER) {
                sound_play(bang);
                *bang_timer = 0.0;
            }
        }
    }
}

Last edited by wrath1138 (2010-09-04 05:29:34)

Re: Boost Rings (Version 2.0)

Alexandre wrote:

We can actually create commands that make players roll and etc. , but the problem is that there are just too many actions that players can perform, and for each command we make now, we'd perhaps have to change it later when the new physics system gets released. So, people would be happy now with rolling and getting into spring mode, but then there is flying, gliding, climbing, getting invincible, getting super fast, bla bla bla... That will be fine when we finish the physics system, but for now it's complicated to have too many of these.

Making just these two (roll & spring) would be okay.

Really, for now, its all that's necessary.

Re: Boost Rings (Version 2.0)

Your rings are the BEST! big_smile You will see my Light Dash rings. Inspired in your technology wink

Piece of cake...!

Re: Boost Rings (Version 2.0)

SilverstepP wrote:

I was thinking something like player_change_action with one parameter. You could change it to 'running', 'walking', 'spinning', or 'spring'. That way we could make our items force players into actions... this is very important for these rings especially, as THIS may fix that flying glitch as well.

LOL, I wanted to do this, too.
By the way, do we have any commands that disables players' movements for a certain amount of time?

Your teacher asks you. What to answer? Say this:
"I thought the teacher is supposed to know."

Re: Boost Rings (Version 2.0)

SoniChris wrote:
SilverstepP wrote:

I was thinking something like player_change_action with one parameter. You could change it to 'running', 'walking', 'spinning', or 'spring'. That way we could make our items force players into actions... this is very important for these rings especially, as THIS may fix that flying glitch as well.

LOL, I wanted to do this, too.
By the way, do we have any commands that disables players' movements for a certain amount of time?

lol.

Try disable_player_movement

Renabled by enable_player_movement (You need this or else you're stuck.)

Re: Boost Rings (Version 2.0)

Revision 229 is your friend.

Commands: springfy_player, roll_player. They don't receive any parameters.

Re: Boost Rings (Version 2.0)

Alexandre wrote:

Revision 229 is your friend.

Commands: springfy_player, roll_player. They don't receive any parameters.

Yay!!! big_smile

Re: Boost Rings (Version 2.0)

Alexandre wrote:

Revision 229 is your friend.

Commands: springfy_player, roll_player. They don't receive any parameters.


: D thanks alex!

Re: Boost Rings (Version 2.0)

'Updated'

I changed "B" and "C" as well.

Plus, I can't find any bugs! :-D

Re: Boost Rings (Version 2.0)

SoniChris wrote:
SilverstepP wrote:

Try disable_player_movement
Renabled by enable_player_movement (You need this or else you're stuck.)

Exactly what I did. No satisfying results

Forget it. Figured out already.

Your teacher asks you. What to answer? Say this:
"I thought the teacher is supposed to know."

Re: Boost Rings (Version 2.0)

Your version 1.0 give me an error: 'Can´t redefine the sprite Boost Down Left'.
Do you know what I have to do to repair it?

Piece of cake...!