May I ask for assistance regarding this matter? Is there a way for this script to display only one value? I understand that it loops because of for loop value added in .@itmCnt++; but is there a way to display only 1 value of this loop stored value?
function script Aqua_Set{
getinventorylist;
setarray .@rental[0],61500,61501,61502,61503,61504;.@itmCnt=0;for(.@i=0;.@i< getarraysize(.@rental);.@i++){if(countitem(.@rental[.@i])==1){.@itmCnt++;}}for(set.@i,0;.@i<@inventorylist_count;set.@i,.@i+1){for(set.@ii,0;.@ii< getarraysize(.@rental);set.@ii,.@ii+1){if(@inventorylist_id[.@i]==.@rental[.@ii]&& countitem(.@rental[.@ii])==1){set.@itemCount,.@itemCount+1;}}}if(.@itmCnt>=2){// this is the part that I want to fix, if possible to only display 1 loop value.
mes .@itmCnt;
end;}}
I'm tryin to make an Etc. or charm type of items that depend on number of parts available, it must only read unique id, any duplicate in the inventory will render that part of the combo unusable, and will not add any stats.
Question
mawjustin
Hi Team,
May I ask for assistance regarding this matter? Is there a way for this script to display only one value? I understand that it loops because of for loop value added in .@itmCnt++; but is there a way to display only 1 value of this loop stored value?
I'm tryin to make an Etc. or charm type of items that depend on number of parts available, it must only read unique id, any duplicate in the inventory will render that part of the combo unusable, and will not add any stats.
this is the result in my end.
Link to comment
Share on other sites
10 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.