Not directly with Ren'py, because it lack of a
for
loop statement (there's just a
for
screen statement). But you can do it with a python block :
Python:
label whatever:
python:
for idx in range( 1, 5 ):
myFunction( getattr( store, "listOfDialog_{:03d}".format( idx ) ) )
You build the name of the variable with the
"listOfDialog_{:03d}".format( idx )
part, that will format the number with 3 digits, filling the empty space with "0".
Then you ask Python to give you the attribute having this name in the "store" object, which will be the value past as argument to the function.