#how do i reference the player character from within a script, within a tool?
88 messages · Page 1 of 1 (latest)
starterpack
?
Ok so, when a player joins the game, the tool will clone and parent to player's backpack, so if you have the scrip inside the tool, you could do
local plr = script.Parent.Parent.Parent
print(plr)
And it should print your name
Thats for a server script, but if its a local script, you could just do
local plr = game.Players.LocalPlayer
that didnt seem to work
Any errors or anything?
Or just
game.Player.PlayerAdded:Connect(function(plr) <-this player
end)
Ig yea, it would work like that too
still didnt work
literally all im asking for is to define the player character from a script thats in a tool thats in the starterpack
did you reference the character
well no ive been trying to do that
what is it printing when you print plr
i dont need to print anything
Printing is a really helpful thing in script
yeah
Do a print and see what you get
it tells you exactly what the script sees
or you can just tell me how to define the character from the script in the tool
thats in the starterpack
ok but we need to know what the script sees and kind of go from there
omg thats what we are trying to do but we also need your help to tell us what plr is
i just need to get the position of the humanoidrootpart
i think its something like plr.Character:WaitForChild('HumanoidRootPart')
yeah well plr isnt referenced yet so the script doesnt know what plr is
because like i said i still havent referenced the goddamn fucking player character
theres no way its this complex bro
Its not, but we also need your help to tell us what the fuck is plr for you
bro i dnt even know what plr is
Im starting to get mad, its like talking to a wall
swearing
any part of the body
ok well im pretty sure you can't reference a player's tool through the starterpack
All you need
yes this is discord a 13+ platform so if you cant handle a little bit of swearing go onto whatsapp or something buddy
Now do a print(plr) and tell us what you get
Can't handle a few bad words?
I told you like 5 minutes ago wtf
...
10 minutes, my bad
im pretty sure you have to reference a tool through the player's backpack though
swearing is for gay people
guess im gay then
exactly
sorry fucking loser!
and you just admitted
ok
Yea.... While trying to shame me for saying fuck...
damn
i dont remember saying i hate gay people
so you think swearing is gay
i say im gay then
and then you say
"exactly you just admitted"
that really insinuates like theres a problem with me being gay
im not gay btw
Saying "this is bad" followed by "this is for X people" its just a stupid thing to say, it means you have problems with X peoples
man when did this go wrong
** You are now Level 2! **
Mods shut this down
well when elpromaximus joined
When a kid got mad cuz I said a "bad word"
bye
yeah it says everything about your intolerance of difference
also nobody will help you with your "problem" (ElPro)
ok so the tool script thing
It should be done, I even test it