View Single Post
  #11  
Old 14.10.2019, 19:34
mgpai mgpai is offline
Script Master
 
Join Date: Sep 2013
Posts: 733
Default

Quote:
Originally Posted by Demongornot View Post
So if I understand, we can use a condition with "return" to return the data passed as argument in the function when the condition is true ?
Will create an array which contains only the elements which pass the test.

Quote:
Originally Posted by Demongornot View Post
I would be more familiar with :
array.filter(word => word.toString().indexOf(host) > -1).reverse();
Looks like it is a ECMAScript 6 method. You can only use ECMAScript 5 (if I am correct) methods in eventscripter.
Reply With Quote