Instead of aval.AddElectron you should use aval.AvalancheElectron. In addition you can retrieve the resulting avalanche size using aval.GetAvalancheSize.
Dear @newconcept1979
The gain is subject to fluctuations and cannot be evaluated based on a single event. You can only draw conclusions from distributions. So run the simulation 1000 times for each potential point and make a distribution of the gain. What we consider gain at that point is the average or most probable value of that distribution. If in individual cases you see gain is 1 then that means that your electron has been attached. You could have found this out by making an event display yourself.
Kind regards
Piet