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 » Scripting Helpers
Home Search
 

Re: How would I do this?

Previous Thread :: Next Thread 
Stroniax is not online. Stroniax
Joined: 22 Jul 2012
Total Posts: 138
07 Aug 2012 12:53 AM
I'm trying to get a GUI button thing to give me a weapon from lighting. Can anybody help? All I need is the script.
Would it be like
Clone1 = game.Lighting.WeaponsName:clone()
function onClicked()
script.Parent.HoweverManyParentsNeeded.Backpack:makejoints()
End
The little thing for an onClicked function thing

Anything like that? Plz help.

~I spread like a plague, for that is what I am~
Report Abuse
thedeathmaster01 is not online. thedeathmaster01
Joined: 14 Mar 2010
Total Posts: 6331
07 Aug 2012 12:55 AM
function clicked(mouse)
c = game.Lighting.WeaponsName:clone()
c.Parent = script.Parent.Howeverymanyparentsneeded.BackPack
end
script.Parent.MouseButton1Down:connect(function(clicked)

try that, that is a simple gui giver script

Nope! Chuck Testa.
Report Abuse
XiJennyX is not online. XiJennyX
Joined: 29 Oct 2011
Total Posts: 320
07 Aug 2012 01:12 AM
Save 1 line:

function clicked(mouse)
game.Lighting.WeaponsName:clone().Parent = script.GreatGrandParent.BackPack
end
script.Parent.MouseButton1Down:connect(function(clicked)
Report Abuse
Cheater is not online. Cheater
Joined: 29 Jun 2007
Total Posts: 5258
07 Aug 2012 03:55 AM
All in one:

script.Parent.MouseButton1Down:connect(function() game.Lighting.WeaponsName:clone().Parent = script.GreatGrandParent.BackPack end)
Report Abuse
Jlobblet is not online. Jlobblet
Joined: 05 Sep 2010
Total Posts: 587
07 Aug 2012 03:59 AM
No capital P in backpack:

script.Parent.MouseButton1Down:connect(function() game.Lighting.WeaponsName:clone().Parent = script.GreatGrandParent.Backpack end)

~if not ok then return end
Report Abuse
Cheater is not online. Cheater
Joined: 29 Jun 2007
Total Posts: 5258
07 Aug 2012 04:00 AM
I just copy/pasted.
Report Abuse
Jlobblet is not online. Jlobblet
Joined: 05 Sep 2010
Total Posts: 587
07 Aug 2012 04:01 AM
GreatGrandParent? Really...

"GreatGrandParent is not a valid member of script"

script.Parent.MouseButton1Down:connect(function() game.Lighting.WeaponsName:clone().Parent = script.Parent.Parent.Parent.Parent.Backpack end)

~if not ok then return end
Report Abuse
Cheater is not online. Cheater
Joined: 29 Jun 2007
Total Posts: 5258
07 Aug 2012 04:02 AM
Looks like you don't get the meaning of GreatGrandParent. xD
Report Abuse
Jlobblet is not online. Jlobblet
Joined: 05 Sep 2010
Total Posts: 587
07 Aug 2012 04:02 AM
Yes, 4 parents. But in actualy coding it's useless.

~if not ok then return end
Report Abuse
Cheater is not online. Cheater
Joined: 29 Jun 2007
Total Posts: 5258
07 Aug 2012 04:03 AM
You know there could be 5 or 6 or even more Parents. :/
Report Abuse
Jlobblet is not online. Jlobblet
Joined: 05 Sep 2010
Total Posts: 587
07 Aug 2012 04:11 AM
You'd add more Greats, or use the Great(and-many-Greats)GrandParent method.

~if not ok then return end
Report Abuse
Stroniax is not online. Stroniax
Joined: 22 Jul 2012
Total Posts: 138
07 Aug 2012 04:47 PM
none of these methods were successful

~I spread like a plague, for that is what I am~
Report Abuse
epicpatrick123 is not online. epicpatrick123
Joined: 08 Sep 2010
Total Posts: 15039
07 Aug 2012 05:01 PM
LOL greatgrandparent
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • 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