Step > Next Combo SFX
#1
Posted 08 February 2012 - 03:30 AM
I have a wonderful script that plays a SFX when the combo directly under the FFC
changes, but that script prevents the Step > Next combo from changing into
the next combo.
#2
Posted 08 February 2012 - 09:01 AM
Put the combo you want to play the sound between the step->next combo and the combo you want it to switch to.
#3
Posted 08 February 2012 - 10:10 AM
Here's an alternative version. Just place the FFC script over the combo you want it to check, then it'll play the sfx in d0.
// FFC script that will play a sound effect when the combo under it changes
// d0 = The sound effect to play
ffc script sfxOnComboChange
{
void run(int sfx)
{
int comboLoc = ComboAt(this->X+8, this->Y+8);
int comboNum = Screen->ComboD[comboLoc];
while(Screen-ComboD[comboLoc] == comboNum)
Waitframe();
Game->PlaySound(sfx);
}
}
Note that I'm not at a computer that has ZQuest, so I can't test it, but I'm pretty certain it'll work.
#4
Posted 08 February 2012 - 01:48 PM
Here's an alternative script if you only need one per screen (well, you could also put more than one of these FFC scripts on the screen if you need more, but that would be annoying if you have a bunch). Also, Poke's version will incrememnt the combo id by one after the step -> next combo goes into effect. Not that that's a problem, or anything. It's just an FYI.
Here's an alternative version. Just place the FFC script over the combo you want it to check, then it'll play the sfx in d0.
// FFC script that will play a sound effect when the combo under it changes
// d0 = The sound effect to play
ffc script sfxOnComboChange
{
void run(int sfx)
{
int comboLoc = ComboAt(this->X+8, this->Y+8);
int comboNum = Screen->ComboD[comboLoc];
while(Screen-ComboD[comboLoc] == comboNum)
Waitframe();
Game->PlaySound(sfx);
}
}
Note that I'm not at a computer that has ZQuest, so I can't test it, but I'm pretty certain it'll work.
Tiny correction, for those likely to copy and paste:
// FFC script that will play a sound effect when the combo under it changes
// d0 = The sound effect to play
ffc script sfxOnComboChange
{
void run(int sfx)
{
int comboLoc = ComboAt(this->X+8, this->Y+8);
int comboNum = Screen->ComboD[comboLoc];
while(Screen->ComboD[comboLoc] == comboNum)
Waitframe();
Game->PlaySound(sfx);
}
}
#5
Posted 08 February 2012 - 05:32 PM
Tiny correction, for those likely to copy and paste:
// FFC script that will play a sound effect when the combo under it changes
// d0 = The sound effect to play
ffc script sfxOnComboChange
{
void run(int sfx)
{
int comboLoc = ComboAt(this->X+8, this->Y+8);
int comboNum = Screen->ComboD[comboLoc];
while(Screen->ComboD[comboLoc] == comboNum)
Waitframe();
Game->PlaySound(sfx);
}
}
This has the same problem. The FFC above the step > next combo prevents the
step > next combo from changing to the next combo.
Now to test Pokemonmaster64's script.
EDIT: Pokemonmaster64's script worked. Thanks
Edited by Cukeman, 08 February 2012 - 05:48 PM.
#6
Posted 21 February 2012 - 08:01 AM
Can anybody help me please?
#7
Posted 21 February 2012 - 02:13 PM
I need such a script for "step->secrets (permanent)"-combos.
Can anybody help me please?
I have a script that will do what you need:
To use this script, make a combo for your "step->secrets (permanent)"-combo (#1).
A combo for it to change to (#2) (and then duplicate #2 in the combo slot immediately following #2 to make #3).
D0 = combo (#2) in my example
D1 = SFX
Put a secret flag on your "step->secrets (permanent)"-combo (#1).
And set that secret flag to combo (#2) in my example.
This will work anytime combo (#2) is present on the screen, so one FFC can
be used for multiple secrets, and you don't need to place the FFC anywhere in particular.
Edited by Cukeman, 26 February 2012 - 07:49 PM.
#8
Posted 22 February 2012 - 11:27 AM
Edit:
The only thing, the second script does, is to don't activate the secret. XD
I will try the first one.
Edit2:
The first one works, thank you.
Edited by Lord Settra!, 22 February 2012 - 12:24 PM.
#9
Posted 22 February 2012 - 08:07 PM
That part is taken care of in the combo and flags used.
But the choice is yours.
Edited by Cukeman, 26 February 2012 - 07:49 PM.
#10
Posted 26 February 2012 - 01:12 PM
#11
Posted 26 February 2012 - 07:46 PM
EDIT:
I'm sorry, Lord Settra! you are correct. My thinker must be tired.
The very reason I requested the script you are using was because step next combos
don't change to the next combo when the other ffc script is above them
Edited by Cukeman, 26 February 2012 - 07:51 PM.
#12
Posted 28 February 2012 - 07:45 AM
#13
Posted 04 July 2012 - 08:08 PM
#15
Posted 04 July 2012 - 09:20 PM
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users


