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: Permanent Weapons until D/C

Previous Thread :: Next Thread 
DandamanGAMEZ is not online. DandamanGAMEZ
Joined: 13 Mar 2013
Total Posts: 156
24 Feb 2015 03:34 AM
Im currently using this local script that gives the player a set of tools (weapons) when he/she pushes the GUI button. The GUI no longer shows up (Its a loadout GUI) I want the weapon to be permanent until Disconnect. Not gone on Death, Not persistent on disconnect.

This is the code:

local player = game.Players.LocalPlayer
local backpack = player.Backpack

function chooseClass(class)
for i, v in pairs(backpack:GetChildren()) do v:remove() end
for i, v in pairs(class:GetChildren()) do
if v:IsA("Tool") then
v:clone().Parent = backpack
elseif v:IsA("HopperBin") then
v:clone().Parent = backpack
end
end
script.Parent.Main.Visible = false
end

for i, v in pairs(script.Parent.Main:GetChildren()) do
v.MouseButton1Up:connect(function () chooseClass(v) end)
end


What am I doing wrong?
Report Abuse
GOLDC3PO is not online. GOLDC3PO
Joined: 31 May 2011
Total Posts: 509
24 Feb 2015 03:36 AM
Staarrrttterrrrrgearrrrr
Report Abuse
DandamanGAMEZ is not online. DandamanGAMEZ
Joined: 13 Mar 2013
Total Posts: 156
24 Feb 2015 03:43 AM
Ah. I see.
Report Abuse
xElectroBear is not online. xElectroBear
Joined: 13 Feb 2011
Total Posts: 1207
24 Feb 2015 03:45 AM
Facepalm
Report Abuse
DandamanGAMEZ is not online. DandamanGAMEZ
Joined: 13 Mar 2013
Total Posts: 156
24 Feb 2015 03:57 AM
*facedesk*
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