Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

how do i make car ownership suach as a lock GUI?

Asked by 11 years ago

hi im trying to make a car ownership for 1 of my games im working on ive tried and tried but it just dosent seem to work can someone help me plz

2 answers

Log in to vote
1
Answered by
Mowblow 117
11 years ago

You could use a string value and connect it to the player once they sit. Put this script in the seat. And make a stringvalue called "OwnerValue" In the seat too.

01local seat = script.Parent
02local ownervalue = seat.OwnerValue
03 
04seat.ChildAdded:connect(function(child)
05if child:IsA("Weld") and child.Name == "SeatWeld" then
06local character = child.Part1.Parent
07local player = game.Players:GetPlayerFromCharacter(character)
08ownervalue.Value = player.Name
09 
10end
11end)

Hope this helped! PM me @Mowblow on roblox for more help!

Ad
Log in to vote
-1
Answered by 11 years ago

You could use values??

Answer this question