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

How to access the StarterPack in a script?

hello I have a quick question how do you access the starter pack in code, I wrote StarterPack but the output said it wasn't valid, any ideas?


script.Parent.Parent.Parent.Parent.StarterPack.G17.ACS_Modulo.Variaveis.Suppressor = true


1 answer

First, to access the StarterPack, you should use ther word Backpack, Secondly, you should get the player(it ' more recomendable than getting the backpack with script.Parent)

I will give you a little code that prints the name of a Tool that the player has in it's backpack in a LocalScript.

local plr = game:GetService('Players').LocalPlayer

local tool = plr.Backpack:FindFirstChildWhichIsA('Tool')

print(tool.Name)

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