I have this part in my script where like every car gets it’s own unique identifier, but problem is I dont want to use actual objects in game, how can I change it so that its table oriented basically
local ID = Instance.new("IntValue")
ID.Name = "ID"
ID.Value = math.random(1,500000000)
ID.Parent = car
Maybe you could use a method to create a new object:
local car_objects = {} --//Storage for all car tables
local function Create_Car(car_model)
local car = {}
car.ID = math.random(1, 5000000000)
car.car_model = car_model
table.insert(car_objects, car)
end
Not really sure what you need, but here’s a rough draft.