|
| 04 Oct 2012 11:22 PM |
it works in play solo, it is a regular script in the workspace like this:
Weld--script -Player--string value -Tool--object value of tool
all variables are correct and I will put -- by commas to show what it says "prints"...
function print(first, ...) local rest = {...} console =game.Players[script.Player.Value].PlayerGui.Messages.Center.Print console.Visible=true console.Script.Value=script.Parent:GetFullName() console.Print.Value=tostring(first) for _, v in pairs(rest) do console.Print.Value= console.Print.Value .. " '" .. tostring(v) .. "'" end end
print("started script")--prints
function Weld(x,y) local W = Instance.new("Weld") W.Part0 = x W.Part1 = y local CJ = CFrame.new(x.Position) local C0 = x.CFrame:inverse()*CJ local C1 = y.CFrame:inverse()*CJ W.C0 = C0 W.C1 = C1 W.Parent = x print("Weld(x,y) works")--prints... end function Get(A) if A.className == "Part" then Weld(script.Tool.Value.Handle, A) A.Anchored = false else local C = A:GetChildren() for i=1, #C do Get(C[i]) end end end print("Get(A) works")--prints... function Finale() Get(script.Tool.Value) end script.Tool.Value.Equipped:connect(Finale) script.Tool.Value.Unequipped:connect(Finale) print("equipped/unequiped works")--prints this Finale() print("Final works")--prints this...
game.Players.PlayerRemoving:connect(function(player) if player.Name==script.Player.Value then script:Destroy() end end)
|
|
|
| Report Abuse |
|
|
MrChubbs
|
  |
| Joined: 14 Oct 2010 |
| Total Posts: 4969 |
|
|
| 05 Oct 2012 01:05 AM |
| Most of the time it is because you have it in the wrong type of script, generally if it is in a script in this case it needs to be in a local script or vica versa. |
|
|
| Report Abuse |
|
|
|
| 05 Oct 2012 01:09 AM |
| if it was in a local script then it would not work because it is in the workspace... |
|
|
| Report Abuse |
|
|
|
| 05 Oct 2012 09:34 AM |
| Make sure the player string value gets its value |
|
|
| Report Abuse |
|
|
|
| 05 Oct 2012 06:31 PM |
| tried as a local script in the players backpack it also does not work |
|
|
| Report Abuse |
|
|
| |
|
| |
|
|
| 05 Oct 2012 09:48 PM |
y u no help meh?
almost at 100 posts... plawx guise? |
|
|
| Report Abuse |
|
|
| |
|
|
| 05 Oct 2012 11:54 PM |
| Rename the print Function something else. |
|
|
| Report Abuse |
|
|
|
| 06 Oct 2012 12:28 AM |
| print function works fine... |
|
|
| Report Abuse |
|
|
| |
|
|
| 06 Oct 2012 12:36 PM |
| correction: print function does not change the text unless in play solo, not in multiplayer, I renamed it but it did not help... |
|
|
| Report Abuse |
|
|
| |
|
| |
|
| |
|
| |
|
sirsavary
|
  |
| Joined: 27 May 2008 |
| Total Posts: 1222 |
|
|
| 08 Oct 2012 07:44 PM |
Rename the print function. Print is something that is built into Rbx.Lua, there is likely a conflict.
Join the Tamerac RPG Beta Group for exclusive updates! Also, TRADE REQUESTS! |
|
|
| Report Abuse |
|
|
|
| 08 Oct 2012 08:47 PM |
| it does not conflict with other scripts and i tried renaming it already |
|
|
| Report Abuse |
|
|
sirsavary
|
  |
| Joined: 27 May 2008 |
| Total Posts: 1222 |
|
|
| 08 Oct 2012 08:48 PM |
Where is the script located and what is it's purpose?
Join the Tamerac RPG Beta Group for exclusive updates! Also, TRADE REQUESTS! |
|
|
| Report Abuse |
|
|
|
| 08 Oct 2012 10:42 PM |
1st script a textbutton to clone 2nd script either to workspace or to a players backpack. 2nd script. Welds a tool when it is equiped, needs to be outside of the tool because the players character that is holding the tool is in the currentcamera |
|
|
| Report Abuse |
|
|
sirsavary
|
  |
| Joined: 27 May 2008 |
| Total Posts: 1222 |
|
|
| 09 Oct 2012 07:49 AM |
| Yeah, sounds like you need to make it a localscript. |
|
|
| Report Abuse |
|
|