Jump to content

pidow

Members
  • Posts

    4
  • Joined

  • Last visited

Profile Information

  • Gender
    Male

pidow's Achievements

Poring

Poring (1/15)

0

Reputation

  1. nobody have the solution ? :/ thx !
  2. Hello every body, I have a issue with this script: prontera,150,150,5 script Buffer 100,{ if( @h_last > gettimetick(2) || !slc_bufs ) goto Set_Buffs; set @h_last, gettimetick(2)+5; [email protected] = callsub(Sub_PriceCheck); if( [email protected] > Zeny ) { message strcharinfo(0), "You don't have enough zeny to buff double click the buffer to modify your selection."; end; } for( [email protected] = 0; [email protected] < .len; [email protected]++ ) if( ( slc_bufs & pow( 2, [email protected] ) ) ) { skilleffect .skil_num[[email protected]], .levels[[email protected]]; sc_start .sc_effect[[email protected]], .ticks[[email protected]], .levels[[email protected]]; message strcharinfo(0),"Buff "+.skil_txt$[[email protected]]+" Added!"; } Zeny = Zeny - [email protected]; end; Sub_PriceCheck: for( [email protected] = 0; [email protected] < .len; [email protected]++ ) if( ( slc_bufs & pow( 2, [email protected] ) ) ) [email protected] = [email protected] + .price[[email protected]]; return [email protected]; Set_Buffs: [email protected]_bufs = slc_bufs; [email protected] = callsub(Sub_PriceCheck); function sf { function s; [email protected] = getarg(2); [email protected] = getarg(3); return ( sprintf( getarg(0), s([email protected], [email protected], getarg(1), getarg(4), getarg(5)), s([email protected]++, [email protected], getarg(1), getarg(4), getarg(5)), s([email protected]++, [email protected], getarg(1), getarg(4), getarg(5)), s([email protected]++, [email protected], getarg(1), getarg(4), getarg(5)), s([email protected]++, [email protected], getarg(1), getarg(4), getarg(5)), s([email protected]++, [email protected], getarg(1), getarg(4), getarg(5)), s([email protected]++, [email protected], getarg(1), getarg(4), getarg(5)), s([email protected]++, [email protected], getarg(1), getarg(4), getarg(5)), s([email protected]++, [email protected], getarg(1), getarg(4), getarg(5)), s([email protected]++, [email protected], getarg(1), getarg(4), getarg(5)) ) +(( [email protected]+1 < [email protected] )?":Next":":") +(( [email protected] > 0 )?":Back":":") +":Done:Cancel" ); function s { if( getarg(0) >= getarg(1) ) return ""; else { [email protected]$ = getelementofarray( getarg(2), getarg(0) ); return [email protected]$==""?"":"Buff [ ^0054ff"[email protected]$+"^000000 ] Lv"+getelementofarray( getarg(4), getarg(0) )+" [ "+(getarg(3)&pow(2,getarg(0))?"^35a100On":"^FF0000Off")+"^000000 ]"; } }; }; function nex { return((getarg(0)+10)<getarg(1)?getarg(0)+10:getarg(1)-(getarg(1)%10)); }; function bac { return((getarg(0)-10)>=0?getarg(0)-10:0); }; mes .npc_nm$; mes "Select your buffs!"; next; [email protected] = 0; while( 1 ) { select( sf( .format$, .skil_txt$, [email protected], .len, [email protected]_bufs, .levels ) ); switch( @menu ) { case 11: [email protected] = nex( [email protected], .len ); break; case 12: [email protected] = bac( [email protected] ); break; case 13: mes .npc_nm$; mes "Alright, your current total will be "[email protected]+"z each time you use my buffing service. Is that ok?"; next; if( select("Yes:No") == 1 ) slc_bufs = [email protected]_bufs; case 14: end; default: [email protected] = [email protected][email protected]; if( ( [email protected]_bufs & pow( 2, [email protected] ) ) ) { [email protected]_bufs = [email protected]_bufs - pow( 2, [email protected] ); [email protected] = [email protected] - .price[[email protected]]; } else { [email protected]_bufs = [email protected]_bufs + pow( 2, [email protected] ); [email protected] = [email protected] + .price[[email protected]]; } } } end; OnInit: .npc_nm$ = "[ "+strnpcinfo(1)+" ]"; setarray .sc_effect, SC_INCREASEAGI, SC_BLESSING, SC_ASSUMPTIO, SC_IMPOSITIO, SC_ANGELUS, SC_MAGNIFICAT, SC_GLORIA; setarray .skil_txt$, "Increase Agi", "Blessing", "Assumptio", "Impositio", "Angelus", "Magnificat", "Gloria"; setarray .ticks, 300000, 300000, 300000, 300000, 300000, 300000, 300000; setarray .price, 1000, 1000, 5000, 5000, 5000, 10000, 10000; setarray .skil_num, 29, 34, 361, 66, 33, 74, 75; setarray .levels, 10, 10, 5, 5, 10, 5, 5; .format$ = "%s:%s:%s:%s:%s:%s:%s:%s:%s:%s"; .len = getarraysize(.sc_effect); end; } Something wrong with select menu. First buff is duplicate and when you clic on it, it activate unactivate the next... Do you know why ? Thx a lot for your reply !
  3. thx @Bianca it work fine !
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use and Privacy Policy.