Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Where to save values?

If I generate some values in a script, where would be a good place to store them for later use? The values are Vector3's (Positions), and I'm storing them to be used as a path for a humanoid character after they're generated.

2 comments

0

Be more specific -- what are the values? What do you use them for? What do you mean by "store"? What is the later use? (Edit your question please)

0

Okay, done.

1 answer

If it's more than one value, store them in a table like so:

local PointsTable = {
	Vector3.new(10, 10, 10),
	Vector3.new(20, 20, 20),
}

2 comments

0

Is this in the same script that the points are being generated in? How do I insert new points into the table?

0

Sorry for taking so long to reply, but yes, it's in the same script. Insert new points like so: table.insert(PointsTable, Vector3.new(20, 20, 20))

This discussion is preserved as it was. New answers, comments, and votes are closed.