|
| 02 Feb 2017 08:37 PM |
this script is inside a gui by the way
its purpose is to take a brick inside the player and duplicate it, then put it outside the body, make it part of the workspace, and then anchor it
bin = script.Parent
b1 = game.Workspace.Player1:FindFirstChild("Brick1") torso = game.Workspace.Player1:FindFirstChild("Torso") local p1 = b1:clone()
function Click() p1.CFrame = torso.CFrame * CFrame.new(Vector3.new(0.5,0,0)) p1.Parent = game.Workspace wait(1) p1.Anchored = true
end bin.MouseButton1Click:connect(Click)
|
|
|
| Report Abuse |
|
|
|
| 02 Feb 2017 08:38 PM |
well more specifically
what am i doing wrong here |
|
|
| Report Abuse |
|
|
Eventive
|
  |
| Joined: 28 Jul 2011 |
| Total Posts: 9827 |
|
|
| 02 Feb 2017 08:40 PM |
| First going to ######## ## it an R15 or R6 rig? ATR'er since 2013. |
|
|
| Report Abuse |
|
|
| |
|
|
| 02 Feb 2017 08:40 PM |
| it's a custom brick that i added to the body via another script |
|
|
| Report Abuse |
|
|
|
| 02 Feb 2017 08:42 PM |
| Do you have FilteringEnabled ###### ### |
|
|
| Report Abuse |
|
|
|
| 02 Feb 2017 08:42 PM |
(oh wow roblox filters have really dirty minds)
Is Filtering Enabled on? |
|
|
| Report Abuse |
|
|
| |
|
|
| 02 Feb 2017 08:44 PM |
| i'm new to scripting sorry :-0 |
|
|
| Report Abuse |
|
|
|
| 02 Feb 2017 08:45 PM |
| Click on workspace, and on the Properties menu, is the box next to FilteringEnabled checked? |
|
|
| Report Abuse |
|
|
|
| 02 Feb 2017 08:48 PM |
oh no it's not
should it be? |
|
|
| Report Abuse |
|
|
|
| 02 Feb 2017 08:57 PM |
| well that made no change :B |
|
|
| Report Abuse |
|
|
Eventive
|
  |
| Joined: 28 Jul 2011 |
| Total Posts: 9827 |
|
|
| 02 Feb 2017 09:04 PM |
FilteringEnabled scripting is a whole other thing. Uncheck it, but if you do that, in the future your game will be 13+ only. This will have to be re-written using FilteringEnabled.
ATR'er since 2013. |
|
|
| Report Abuse |
|
|
|
| 02 Feb 2017 09:05 PM |
uh okay
well i guess i don't get what that has to do with my script |
|
|
| Report Abuse |
|
|
|
| 02 Feb 2017 09:07 PM |
| Is the GUI a TextButton? (Just making sure) |
|
|
| Report Abuse |
|
|
Eventive
|
  |
| Joined: 28 Jul 2011 |
| Total Posts: 9827 |
|
|
| 02 Feb 2017 09:07 PM |
If you're planning to make this a legitimate game, you need to have FilteringEnabled. FilteringEnabled affects your scripts majorly.
ATR'er since 2013. |
|
|
| Report Abuse |
|
|
|
| 02 Feb 2017 09:08 PM |
uh why are you using Player1
|
|
|
| Report Abuse |
|
|
|
| 02 Feb 2017 09:09 PM |
"Is the GUI a TextButton? (Just making sure)"
yes it is
unfortunately i can't figure out why it's not working ):>
"If you're planning to make this a legitimate game, you need to have FilteringEnabled. FilteringEnabled affects your scripts majorly."
how so |
|
|
| Report Abuse |
|
|
Eventive
|
  |
| Joined: 28 Jul 2011 |
| Total Posts: 9827 |
|
|
| 02 Feb 2017 09:09 PM |
Are you wanting this to happen with every player?
ATR'er since 2013. |
|
|
| Report Abuse |
|
|
|
| 02 Feb 2017 09:09 PM |
"why are you using Player1"
because i'm testing
this script is for solo purposes only at the moment
|
|
|
| Report Abuse |
|
|
|
| 02 Feb 2017 09:10 PM |
"Are you wanting this to happen with every player?"
no but it doesn't have anything to do with Player1 i'm pretty sure
i'm just using that code for testing I know it wouldn't work in the actual game |
|
|
| Report Abuse |
|
|
Eventive
|
  |
| Joined: 28 Jul 2011 |
| Total Posts: 9827 |
|
|
| 02 Feb 2017 09:10 PM |
FilteringEnabled protects your games from hackers, soon Roblox is making it so games that aren't FE are 13+ only. FilteringEnabled in order to protect you, has to do some things to the Server and Client. Therefore, you'd have to re-work your scripts.
ATR'er since 2013. |
|
|
| Report Abuse |
|
|
Eventive
|
  |
| Joined: 28 Jul 2011 |
| Total Posts: 9827 |
|
|
| 02 Feb 2017 09:13 PM |
Is this in a LocalScript or ServerScript (AKA a regular script)
ATR'er since 2013. |
|
|
| Report Abuse |
|
|
Eventive
|
  |
| Joined: 28 Jul 2011 |
| Total Posts: 9827 |
|
|
| 02 Feb 2017 09:17 PM |
Try this.
local bin = script.Parent local b1 = game.Workspace.Player1:FindFirstChild("Brick1") local torso = game.Players.LocalPlayer.Character.Torso local p1 = b1:clone()
script.Parent.MouseButton1Down:connect(function() p1.CFrame = torso.CFrame * CFrame.new(Vector3.new(1,0,0)) p1.Parent = game.Workspace wait() p1.Anchored = true end)
This is going to do it for every player if they click the button though.
ATR'er since 2013. |
|
|
| Report Abuse |
|
|
|
| 02 Feb 2017 09:40 PM |
okay that works!!
the only problem is it spawns several bricks
how can i make it so it's just one? |
|
|
| Report Abuse |
|
|