Jump to content
  • 0
WhiteEagle

Countinarray

Question

Gives here in hercules anything what is similar with "countinarray" from rathena?

*countinarray <array name>{[<start index>]},<array name>{[<start index>]};

 I Need this for this part here:
 

setarray .@gqname$[0],"Kill Mantis","Kill Bees","Kill Soils","Kill Porings";
	.@null$ = "NULL";
	while(countinarray(.@gqname$[0], .@null$) != 2)
		.@gqname$[rand(getarraysize(.@gqname$))] = .@null$;

	switch(select(replacestr(implode(.@gqname$, ":"), .@null$, ""))) {
		case 1:
			mes("mantis");
			close;
		case 2:
			mes("bees");
			close;
		case 3:
			mes("soils");
			close;
		case 4:
			mes("porings.");
			close;
	}

 

Edited by WhiteEagle

Share this post


Link to post
Share on other sites

2 answers to this question

Recommended Posts

  • 0

Thanks Dastgir.
Why is not this basically present in hercules?
Just a question. :D 

 

PS:
I get now the error message: 

    parse_simpleexpr: unmatched ')'

in this line here and the part with "("

 while(array_count"(".@gqname$,2))

 

Edited by WhiteEagle

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.