Hi redarme
Unfortunately I cannot spend as much time as I would like on this as I have other commitments, but the attached (untested) should show you the principle of a counter and the method for resetting it, and also the counter condition for your lay trigger. I am still unsure of the purpose of your proposed remember trigger. Is it to remember the selections that fit your > 30%, because you seem to have done it all in the lay trigger? Anyway, I’m sure you can sort that bit out.
A couple of observations:
It is better to initialise user variables – can be done using a trigger or a constant
I think you may find the overall trigger will operate too sluggishly for inplay. I mention this because of the number of ‘no more often than’ in the file. And, if I am seeing where you are going with this, you might be adding some more soon. ‘no more often than’ in V6 used lots of CPU, and my experience has been that any more than 2-3 in a trigger file will slow the program down a lot. My suggestion would be to see if you can use existing variables for your purpose. I know you are working on LTP, but perhaps you might be able to use lpdif_ and l_growth.
I hope this is of help