From bf30482687e90e6e859ca263dc20474bad4d7daf Mon Sep 17 00:00:00 2001 From: toms Date: Thu, 24 Apr 2008 11:35:18 +0000 Subject: * Fixed hugel_bingo making an unneeded infinite loop bugreport:1349 * Partially fixed bugreport:1285 (item 13697) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12646 54d463be-8e91-2dee-dedb-b68131a5f0ec --- npc/Changelog.txt | 3 ++- npc/other/hugel_bingo.txt | 10 +++++----- 2 files changed, 7 insertions(+), 6 deletions(-) (limited to 'npc') diff --git a/npc/Changelog.txt b/npc/Changelog.txt index da2c53091..1bb543f50 100644 --- a/npc/Changelog.txt +++ b/npc/Changelog.txt @@ -1,6 +1,7 @@ Date Added ====== -2008/04/22 +2008/04/24 + * Rev. 12646 Fixed hugel_bingo making an unneeded infinite loop bugreport:1349 [Toms] * Rev. 12645 Corrected a typo error ";;" bugreport:919 [Toms] 2008/04/21 * Rev. 12629 Fixed yet another WoE SE Bug (Juno castle 3) [L0ne_W0lf] diff --git a/npc/other/hugel_bingo.txt b/npc/other/hugel_bingo.txt index 569b66afb..10ad4e1ee 100644 --- a/npc/other/hugel_bingo.txt +++ b/npc/other/hugel_bingo.txt @@ -192,13 +192,13 @@ OnTimer2000: OnTimer5000: mapannounce "que_bingo","Eukran: Now, let the game begin!",1,0xFFAB54; setarray $@bingoarray[0],1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25; + set .@max_index, 24; for(set .@i,0; .@i < 25; set .@i,.@i +1) { -L_Roll: - set $@bingo0,rand(0,24); - setarray $bingo[.@i],$@bingoarray[$@bingo0]; - if(!$bingo[.@i]) goto L_Roll; - cleararray $@bingoarray[$@bingo0],0,1; + set $@bingo0,rand(0,.@max_index); + set $bingo[.@i],$@bingoarray[$@bingo0]; + set $@bingoarray[$@bingo0], $@bingoarray[.@max_index]; + set .@max_index, .@max_index - 1; } end; -- cgit v1.2.3-60-g2f50