Danz Posted October 11, 2016 Group: Members Topic Count: 9 Topics Per Day: 0.00 Content Count: 12 Reputation: 0 Joined: 01/25/13 Last Seen: September 7, 2020 Share Posted October 11, 2016 This script IS NOT WORKING, accuses hum error, I tried fix more NOT work, helpe-me please me.. prontera,164,175,4 script Loteria 76,{ mes .M$; mes "Números vencedores da Loteria: ^777777("+$LID[2]+")^000000:"; mes "- ^0000FF["+$LW[1]+"] ["+$LW[2]+"] ["+$LW[3]+"] ["+$LW[4]+"] ["+$LW[5]+"] ["+$LW[6]+"]^000000"; if(#LID){ mes "Seu bilhete: ("+#LID+"):"; mes "- ^FF0000["+#LW[1]+"] ["+#LW[2]+"] ["+#LW[3]+"] ["+#LW[4]+"] ["+#LW[5]+"] ["+#LW[6]+"]^000000"; } mes "Próximo sorteio ID: ^FF0000"+$LID[1]+"^000000."; next; if(getgroupid() > 90){ set .@i,select("Pegar Prêmio:Comprar Bilhete:[GM]Do Draw Now:[GM]Rig the Lottery:Cancelar"); }else{ set .@i,select("Pegar Prêmio:Comprar Bilhete:::Cancelar"); } switch(.@i){ case 1: if (#LID != $LID[2]){ mes .M$; mes "Desculpe, mas seu bilhete é inválido."; close; } for(.@i = 1; .@i < 7; .@i++){ for(.@u = 1: .@u < 7; .@u++){ if(#LW[.@i] == $LW[.@u]) .@P += 1; } } if(.@P){ mes .M$; mes "You have matched at least "+.@P+" numbers!"; mes "Você ganhou: ^0000FF"+.Prizes[.@P * 2]+"x "+getitemname(.Prizes[.@P * 2 - 1])+"^000000."; announce "[Loteria]: " + strcharinfo(0) + " ganhou ["+.Prizes[.@P * 2]+"x "+getitemname(.Prizes[.@P * 2 - 1])+"]!",bc_all,0x87CEFF; set #LID,0; getitem .Prizes[.@P * 2 - 1],.Prizes[.@P * 2]; close; } else { mes .M$; mes "Que pena, você não teve muita sorte, seu bilhete não foi prêmiado."; close; } case 2: if (#LID == $LID && #LW[1] != 0){ mes .M$; mes "Você já comprou um bilhete hoje, só é permitido um bilhete por dia."; close; } mes .M$; mes "Preço do Bilhete: ^0000FF"+.Cost[1]+"x "+getitemid(.Cost[0])+"^000000."; mes "Os prêmios da Loteria são:"; mes "[1] ^0000FF"+.Prizes[2]+"x "+getitemname(.Prizes[1])+"^000000."; mes "[2] ^0000FF"+.Prizes[4]+"x "+getitemname(.Prizes[3])+"^000000."; mes "[3] ^0000FF"+.Prizes[6]+"x "+getitemname(.Prizes[5])+"^000000."; mes "[4] ^0000FF"+.Prizes[8]+"x "+getitemname(.Prizes[7])+"^000000."; mes "[5] ^0000FF"+.Prizes[10]+"x "+getitemname(.Prizes[9])+"^000000."; mes "[6] ^0000FF"+.Prizes[12]+"x "+getitemname(.Prizes[11])+"^000000."; next; if(select("Comprar Bilhete:^FF0000Cancelar^000000") > 1){ break; }else if(countitem(.Cost[0]) < .Cost[1]){ mes .M$; mes "Você não pode pagar por este bilhete, desculpe."; close; }else{ mes .M$; mes "Você prefere números escolhido por você ou gerados pelo sistema?"; next; switch("Gerar pelo Sistema:Escolher:Renovar Bilhete"){ case 1: while(!.@x){ for(.@i = 1; .@i < 7; .@i++){ set .@LW[.@i],rand(1,40); } while(.@LW[2] == .@LW[1]) set .@LW[2],rand(1,40); while(.@LW[3] == .@LW[1] || .@LW[2] == .@LW[3]) set .@LW[3],rand(1,40); while(.@LW[4] == .@LW[1] || .@LW[2] == .@LW[4] || .@LW[4] == .@LW[3]) set .@LW[4],rand(1,40); while(.@LW[5] == .@LW[1] || .@LW[2] == .@LW[5] || .@LW[5] == .@LW[3]] || .@LW[4] == .@LW[5]) set .@LW[5],rand(1,40); while(.@LW[6] == .@LW[1] || .@LW[2] == .@LW[6] || .@LW[6] == .@LW[3]] || .@LW[4] == .@LW[6] || .@LW[6] == .@LW[5]) set .@LW[6],rand(1,40); mes .M$; mes "O sistema gerou os seguintes números:"; mes "- ^0000FF"+@L1+" "+@L2+" "+@L3+" "+@L4+" "+@L5+" "+@L6+"^000000"; next; if(select("Confirmar:Re-Gerar") == 1) .@x = 1; } copyarray #LW[1],@LW[1],6; break; case 2: while(!.@x){ mes .M$; mes "Por favor, escolhe os seus números ^0000FF(1-40)^000000:"; mes "^FF0000Atenção: os números não podem ser repetidos.^000000"; for(.@i = 1; .@i < 7; .@i++){ input @LW[.@i],1,40; mes @LW[.@i] } while(.@LW[2] == .@LW[1]){ mes "Re-digite o 2 número."; input @LW[2],1,40; } while(.@LW[3] == .@LW[1] || .@LW[2] == .@LW[3]){ mes "Re-digite o 3 número."; input @LW[3],1,40; } while(.@LW[4] == .@LW[1] || .@LW[2] == .@LW[4] || .@LW[4] == .@LW[3]){ mes "Re-digite o 4 número."; input @LW[4],1,40; } while(.@LW[5] == .@LW[1] || .@LW[2] == .@LW[5] || .@LW[5] == .@LW[3]] || .@LW[4] == .@LW[5]){ mes "Re-digite o 5 número."; input @LW[5],1,40; } while(.@LW[6] == .@LW[1] || .@LW[2] == .@LW[6] || .@LW[6] == .@LW[3]] || .@LW[4] == .@LW[6] || .@LW[6] == .@LW[5]){ mes "Re-digite o 6 número."; input @LW[6],1,40; } next; mes .M$; mes "Seus números são:"; mes "- ^0000FF"+@L1+" "+@L2+" "+@L3+" "+@L4+" "+@L5+" "+@L6+"^000000"; next; if(select("Confirmar:Re-Escolher") == 1) .@x = 1; } copyarray #LW[1],@LW[1],6; break; case 3: if(!#LID){ mes .M$; mes "Desculpe, mais você tem um bilhete inválido."; close; } break; } } delitem .Cost[0],.Cost[1]; set #LID,$LID[1]; mes .M$; mes "O sorteio da Loteria acontece às ^0000FF21:00 horas^000000."; close; case 3: callsub OnClock2045; break; case 4: while(!.@x){ mes .M$; mes "Por favor, escolhe os seus números ^0000FF(1-40)^000000:"; mes "^FF0000Atenção: os números não podem ser repetidos.^000000"; for(.@i = 1; .@i < 7; .@i++){ input @LW[.@i],1,40; mes @LW[.@i] } while(.@LW[2] == .@LW[1]){ mes "Re-digite o 2 número."; input @LW[2],1,40; } while(.@LW[3] == .@LW[1] || .@LW[2] == .@LW[3]){ mes "Re-digite o 3 número."; input @LW[3],1,40; } while(.@LW[4] == .@LW[1] || .@LW[2] == .@LW[4] || .@LW[4] == .@LW[3]){ mes "Re-digite o 3 número."; input @LW[4],1,40; } while(.@LW[5] == .@LW[1] || .@LW[2] == .@LW[5] || .@LW[5] == .@LW[3]] || .@LW[4] == .@LW[5]){ mes "Re-digite o 5 número."; input @LW[5],1,40; } while(.@LW[6] == .@LW[1] || .@LW[2] == .@LW[6] || .@LW[6] == .@LW[3]] || .@LW[4] == .@LW[6] || .@LW[6] == .@LW[5]){ mes "Re-digite o 6 número."; input @LW[6],1,40; } next; mes .M$; mes "Os seus números são:"; mes "^0000FF" + @L1 + " " + @L2 + " " + @L3 + " " + @L4 + " " + @L5 + " " + @L6 + "^000000"; next; if(select("Confirmar:Re-Escolher") == 1) .@x = 1; } copyarray $LR[1],@LW[1],6; next; mes .M$; mes "Loteria fraudada para o próximo sorteio."; set $LR[0],1; close; case 5: } mes .M$; mes "Volte logo!"; close; OnClock2045: if($LR[0]){ set $LW[1],$LR[1]; set $LW[2],$LR[2]; set $LW[3],$LR[3]; set $LW[4],$LR[4]; set $LW[5],$LR[5]; set $LW[6],$LR[6]; $LR[0] = 0; }else{ for(.@i = 1; .@i < 7; .@i++){ set $LW[.@i],rand(1,40); } while($LW[2] == $LW[1]) set $LW[2],rand(1,40); while($LW[3] == $LW[1] || $LW[2] == $LW[3]) set $LW[3],rand(1,40); while($LW[4] == $LW[1] || $LW[2] == $LW[4] || $LW[4] == $LW[3]) set $LW[4],rand(1,40); while($LW[5] == $LW[1] || $LW[2] == $LW[5] || $LW[5] == $LW[3]] || $LW[4] == $LW[5]) set $LW[5],rand(1,40); while($LW[6] == $LW[1] || $LW[2] == $LW[6] || $LW[6] == $LW[3]] || $LW[4] == $LW[6] || $LW[6] == $LW[5]) set $LW[6],rand(1,40); } announce "[Loteria]: O sorteio da loteria foi realizado. Já temos os números vencedores!",bc_all,0x87CEFF; sleep 5000; announce "[Loteria]: Os números prêmiados foram: ["+$LW[1]+"] ["+$LW[2]+"] ["+$LW[3]+"] ["+$LW[4]+"] ["+$LW[5]+"] ["+$LW[6]+"].",bc_all,0x87CEFF; sleep 5000; announce "[Loteria]: Parabéns aos vencedores, os prêmios já podem ser retirados!",bc_all,0x87CEFF; if($LID[1] < 100000) $LID[1] += 99999; $LID[2] = $LID[1]; $LID[1] += rand(10); end; OnInit: // Prêmios da loteria. setarray .Prizes,0,12221,1,7711,1,14232,5,7929,1,7179,2,4399,1; // Custo do bilhete. setarray .Cost,7227,5; set .M$,"^FF0000[Loteria]^000000"; end; } T_T help-me Quote Link to comment Share on other sites More sharing options...
0 _Okuz_ Posted October 11, 2016 Group: Members Topic Count: 0 Topics Per Day: 0 Content Count: 92 Reputation: 17 Joined: 08/11/12 Last Seen: August 30, 2017 Share Posted October 11, 2016 Danz, Could you please give us information about the errors that you got?Thanks. Quote Link to comment Share on other sites More sharing options...
0 Danz Posted October 11, 2016 Group: Members Topic Count: 9 Topics Per Day: 0.00 Content Count: 12 Reputation: 0 Joined: 01/25/13 Last Seen: September 7, 2020 Author Share Posted October 11, 2016 Accuses error and locks in this part, more precisely #LID if(#LID){ mes "Seu bilhete: ("+#LID+"):"; mes "- ^FF0000["+#LW[1]+"] ["+#LW[2]+"] ["+#LW[3]+"] ["+#LW[4]+"] ["+#LW[5]+"] ["+#LW[6]+"]^000000"; } mes "Próximo sorteio ID: ^FF0000"+$LID[1]+"^000000."; Accuses error and locks in this part, More Precisely #LID Quote Link to comment Share on other sites More sharing options...
Question
Danz
This script IS NOT WORKING, accuses hum error, I tried fix more NOT work, helpe-me please me..
T_T help-me
Link to comment
Share on other sites
2 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.