Scripted plugin modifier Arrays and other problems

Hello, I'm trying to make a maxscript into a modifier (ziboo's spline Scatter, think I got it from here actually). It's not going as badly as I thought it would: I managed to figure out that by putting "parameters main rollout:blahblah" at the top, and then predeclaring the variables before the rollout controls the modifier remembers all the spinner control values and so on.

So, I add this as a modifier to a spline, and it scatters a bunch of objects along the path like I want. What I'm having trouble with is getting the modifier to remember that it has generated these objects, I guess by storing them in an array or something like that, so that I can delete or change them next time I click on the spline. I can't find a way of predeclaring an array like I have done with the other variables.

Without pasting the whole thing, the structure of it is basically like this:

plugin modifier blahblah
name:"blahblah"
classID:#(12345, 54321)
replaceUI:true
(
 
parameters main rollout:  blahblah
 
(
 
int1 type:#integer ui:int1
 
)
 
rollout blahblah "blahblah Parameters"
 
(
 
global splineone = $Line01
spinner int1 "number" range:[0,100,0] type:#integer ui:int1
 
--functions
 
fn do funkystuff =
(
--cool function
 
)
 
-- events
 
on blahblah open do
	(
		--something
	)
 
)
)

I seem to get the impression that I shouldn't really be using maxscript to make modifiers, and I'm not even sure if what I'm trying to do is possible with this method, so any help at all is very appreciated.