Part position recording (ModuleScript.Source)

Hi there, I’m trying to record the position, and want this to be applied in a ModuleScript. I want it to to apply every 0.2 seconds, with a new line. Problem is, I have no idea how to do this. I want to do this all in the command bar, because I’m not that familiar with plugins and such. I’ve tried the following, but can’t really get what I want to.

local part = workspace.Part
local module = game.ServerScriptService.TestModule
-- The part, obv.
while wait(1/5) do
local string = [[ [1] = part.Position ]]
-- The string, "1" for the first time it's being recorded in the script, but I want this number to change among to the amount it's being recorded (adding more lines with the position of course.)
module.Source = string
end

But the problem is that the modulescript puts it as:
[1] = part.Position

Sorry if I sound confusing, I don’t really know how to explain this perfectly. But is there any way how I can have it record each line with the while wait speed, and have the “1” changed? And of course the part.Position should say its Vector3. Again, sorry for sounding confusing, I don’t have experience with changing modules and such. Thanks.

local part = workspace.Part

local positions = {}

while part:IsDescendantOf(workspace) do
    table.insert(positions, part.Position)
    wait(1/5)
end

I don’t get why you need to use a module to record positions, a table should be fine.

You can only use the command bar to change the Source property of a script. Server, Client, Module.

Source

Yeah, I want to change it in the command bar. And the reason I want to have it recorded in a modulescript is because I just want to make a system around it.

Then create a function in the module script that records positions, then require that in the main code.

Isn’t it possible how I want it? Because that’s basically all I need for info.

Just use a table, you won’t be able to change the source live in-game.

I’m trying to convert a modulescript with these positions in studio using the command bar. That works all fine, tho I have no idea how to actually apply real-time positions in it, instead of part.Position

Use a for loop then, and loop through all the positions?