generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripters
Home Search
 

Re: How to make this work with FE?

Previous Thread :: Next Thread 
xCrystalGem is not online. xCrystalGem
Joined: 08 Jan 2016
Total Posts: 220
02 Jul 2016 03:06 AM
I need some help converting this, I'm unsure how. It's a script inside of a button of a GUI, that when you press it, these parts with these names become visible in a morph.

local player = script.Parent.Parent.Parent.Parent.Parent
local torso = player.Character:FindFirstChild("Torso")
function onClick(mouse)

player.Character.Chest.S5.Transparency = 0
player.Character.Chest.S6.Transparency = 0
player.Character.Chest.S7.Transparency = 0
player.Character.Chest.S8.Transparency = 0
player.Character.Chest.S9.Transparency = 0
player.Character.Chest.S10.Transparency = 0
player.Character.Chest.S11.Transparency = 0

end

script.Parent.MouseButton1Down:connect(onClick)


Unfortunately whenever FilteringEnabled is checked, these kind of scripts break..
Report Abuse
0Dan is not online. 0Dan
Joined: 22 Oct 2009
Total Posts: 2552
02 Jul 2016 03:15 AM
Tell me if this works

--RemoteEvent in Workspace
script.Parent.OnServerEvent:connect(function(player)
print(player.Name)
if(player.Character:FindFirstChild("Torso")~=nil)then
player.Character.Chest.S5.Transparency = 0
player.Character.Chest.S6.Transparency = 0
player.Character.Chest.S7.Transparency = 0
player.Character.Chest.S8.Transparency = 0
player.Character.Chest.S9.Transparency = 0
player.Character.Chest.S10.Transparency = 0
player.Character.Chest.S11.Transparency = 0
end
end)

--LocalScript inside TextButton
script.Parent.MouseButton1Down:connect(function()
game.Workspace.RemoteEvent:FireServer()
end)


local l={e={a={v={e=function()print("bye")end}}}} l.e.a.v.e()
Report Abuse
xCrystalGem is not online. xCrystalGem
Joined: 08 Jan 2016
Total Posts: 220
02 Jul 2016 03:22 AM
Ah it works! Thank you SO much for the help, I appreciate it!
Report Abuse
xCrystalGem is not online. xCrystalGem
Joined: 08 Jan 2016
Total Posts: 220
02 Jul 2016 03:24 AM
Oh wAIT- It works in Play mode but when I save it, and play it as a normal game it doesn't work. That's odd?
Report Abuse
xCrystalGem is not online. xCrystalGem
Joined: 08 Jan 2016
Total Posts: 220
02 Jul 2016 04:06 PM
Does anyone know why this is happening?
Report Abuse
CyberNugget is not online. CyberNugget
Joined: 04 Dec 2011
Total Posts: 568
02 Jul 2016 04:31 PM
Use WaitForChild() or Wait() for a couple of seconds. Studio does that to me too.


Report Abuse
xCrystalGem is not online. xCrystalGem
Joined: 08 Jan 2016
Total Posts: 220
02 Jul 2016 05:07 PM
Hmm. Whenever I add that, the scripts break in test mode now. Like this?

--(Script that's in the button)
repeat wait() until Player.Character
Character = Player.Character
Character:WaitForChild()
script.Parent.MouseButton1Down:connect(function()
game.Workspace.RemoteEvent:FireServer()
end)


--(Script that's in the RemoteEvent)
repeat wait() until Player.Character
Character = Player.Character
Character:WaitForChild()
script.Parent.OnServerEvent:connect(function(player)
print(player.Name)
if(player.Character:FindFirstChild("Torso")~=nil)then
player.Character.Chest.Hologram.Transparency = 0
end
end)
Report Abuse
CyberNugget is not online. CyberNugget
Joined: 04 Dec 2011
Total Posts: 568
02 Jul 2016 05:11 PM
No, no. I meant something like wait a certain amount of seconds. Even if it's just one, you have to give your game time to load all the assets. Use something like wait(1) or game.Workspace:WaitForChild("Blah")


Report Abuse
xCrystalGem is not online. xCrystalGem
Joined: 08 Jan 2016
Total Posts: 220
02 Jul 2016 05:54 PM
Oh. Okay, so does that go into the same script as those up there ^^^

Or is it its own thing? I'm sorry, I'm not too experienced.
Report Abuse
CyberNugget is not online. CyberNugget
Joined: 04 Dec 2011
Total Posts: 568
02 Jul 2016 05:57 PM
It's no problem, you ask what you need to, that's what a forum is here for. Yes, it would go before the majority of your functions.


Report Abuse
SloeGin is not online. SloeGin
Joined: 22 Jan 2011
Total Posts: 322
02 Jul 2016 06:04 PM
You'll learn to love WaitForChild() in a way. It does have my children.


218,230 slices of pizza and counting
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image