alvin1104
|
  |
| Joined: 22 Feb 2011 |
| Total Posts: 681 |
|
|
| 30 Aug 2014 04:45 AM |
--This code is supposed to put a hat on a player when they enter the game if they are in a group. But for some reason it won't work!
local gid = 989031 --group id local hatid = 1098277 --hat id
game.Players.PlayerAdded:connect(function(v) if v:IsInGroup(gid) then v.CharacterAdded:connect(function(vplr) repeat wait() until v and vplr vplr:WaitForChild("Humanoid") game:GetService("InsertService"):LoadAsset(hatid):GetChildren()[1].Parent=vplr end) end end) |
|
|
| Report Abuse |
|
|
alvin1104
|
  |
| Joined: 22 Feb 2011 |
| Total Posts: 681 |
|
| |
|
alvin1104
|
  |
| Joined: 22 Feb 2011 |
| Total Posts: 681 |
|
| |
|
|
| 30 Aug 2014 05:10 AM |
| Remove the WaitForChild() and weld the hat to the player's head. |
|
|
| Report Abuse |
|
|
alvin1104
|
  |
| Joined: 22 Feb 2011 |
| Total Posts: 681 |
|
| |
|
|
| 30 Aug 2014 05:16 AM |
| By creating the weld and setting the Part0, Part1 and C0 property? |
|
|
| Report Abuse |
|
|
WishNite
|
  |
| Joined: 11 Feb 2009 |
| Total Posts: 15828 |
|
| |
|
| |
|