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

How to teleport Union relative to player position and move along with player?

I have a shopping cart, I want the the shopping cart to always be infront of the player, they can walk around at all times but I want it attached to the player. I dont want it touching the player tho, slightly infront. I searched how to do stuff like this but could only find videos about welding stuff to body, and they used like khols admin and some building tool lol how would I do this?

3 comments

0

so u want it to move like a pet?

0

and welding is a good idea

0

just offset it a bit ill give u an example

1 answer

✓ Accepted answer

this script should spawn a brick in front of the character; put in StarterCharacterScripts

local root = script.Parent:FindFirstChild("HumanoidRootPart", true)
local brick = Instance.new("Part", workspace)
brick.Size = Vector3.new(1,1,1)

local weld = Instance.new("Weld", brick)
weld.Part0 = root
weld.Part1 = brick
weld.C0 = CFrame.new(0,0,-5)

3 comments

0

btw wat is ur game it seems interesting

0

Lol Im making a store and it gives u a list, u gotta go around get all the items for money and get upgrades ect lol still working out details

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