1
發生了什麼事是隊列獲取的是隊列到達該函數時的值,而不是隊列首先被設置時的值。我該如何解決?用於創建隊列和隊列不能接收正確的變量
ms = false;
for(var x in Apps['f-game'].m['gD']['game_data']['lr']['sk']) {
if(Apps['f-game'].m['gD']['game_data']['lr']['sk'][x] == 1) {
Apps['f-game'].m['aQ'].queue(function() {
Apps['f-game'].wGBF(x);
if(!mS) {
Apps['f-game'].m['aQ'].delay(200);
Apps['f-game'].m['aQ'].queue(function() {
Apps['f-game'].wGBP(x, 5);
});
}
Apps['f-game'].m['aQ'].delay(500);
});
}
}
實例 應用[ 'F-遊戲'] M [ '的gD'] [ 'game_data'] [ 'LR'] [ 'SK'] = {1:1,54:1 ,115894:1}
整個文件將調用Apps ['f-game']。wGBP(x,5);每次x將是115894。