Jump to content
  • 0

how to change ok,cancel button to next button?


Question

Posted

post-7368-0-83609100-1347586855_thumb.jpg

prontera,148,163,6 script Slot Machine 563,{
set @npc$,"[ Roll Machine ]";
// How many Items can be Choose
set .List,3;
// Hours Delay for each Roll
set .Hours,24;
// Ticket ID used for this Roll Machine
set .TicketID,7539;
// Items Available to Gain through Roll Machine
setarray .Items[0],607,608,609,610,512;
// Amount of Ticket required to change into Items.
setarray .Cost[0],1,3,5,10,50;
if ( #Roll_Claimed > gettimetick(2) ){
mes "You already rolled for the day";
mes "see you tomorrow";
}else{
mes @npc$;
mes "Roll the machine?";
next;
if( select("Yes!:No! not yet") == 2 ) close;
mes @npc$;
mes "Are you sure?";
next;
if( select("Yes, let's roll it!:I change my mind") == 2 ) close;
mes @npc$;
mes "Random Item Flashing....";
mes "Rolling........";
next;
mes @npc$;
mes "Item Apear List :";
mes "[ ^FF0000Required Items^000000 ] [ ^0000FFItem Gain^000000 ]";
for( set .x,0; .x < .List; set .x,.x + 1 ){
 set .Random,rand( getarraysize( .Items ) );
 set .Rolled[.x],.Items[.Random];
 set .RolledCost[.x],.Cost[.Random];
 mes "^FF0000"+.RolledCost[.x]+" x "+getitemname( .TicketID )+" = ^0000FF"+getitemname( .Rolled[.x] )+"^000000";
 set .@Menu$,.@Menu$ + getitemname( .Rolled[.x] )+":";
}
set .@i,select( .@Menu$ ) - 1;
mes "This item cost ^FF0000"+.RolledCost[.@i]+" x "+getitemname( .TicketID )+"^000000.";
next;
if( select("Spend my Ticket:Waste my roll") == 2 ) close;
 mes @npc$;
 if( countitem( .TicketID ) < .RolledCost[.@i] ){
  mes "You need ^0000FF"+.RolledCost[.@i]+" ^0000FF"+getitemname( .TicketID )+"^000000";
  mes "Better luck next time";
 }else{
  mes "Thanks for using Roll Machine";
  set #Roll_Claimed,gettimetick(2) + ( .Hours * 3600 );
  getitem .Rolled[.@i],1;
  delitem .TicketID,.RolledCost[.@i];
 }
}
close;
}

3 answers to this question

Recommended Posts

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...