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: Gear all players

Previous Thread :: Next Thread 
ELETROG is not online. ELETROG
Joined: 11 Jul 2013
Total Posts: 604
22 Sep 2014 10:03 AM
Can someone translate this to a script:

while true do
wait(30)
---Gear all players "Sword" <---- translate this
end
Report Abuse
HyroadCoder is not online. HyroadCoder
Joined: 15 Jul 2014
Total Posts: 813
22 Sep 2014 10:05 AM
for _,p in pairs(game.Players:GetPlayers()) do
if p then
game.Lighting.Sword:Clone().Parent = p.Backpack
end
end
Report Abuse
MrCss is not online. MrCss
Joined: 10 Jul 2014
Total Posts: 235
22 Sep 2014 10:14 AM
--[[Just copy the whole script and replace the gear Id with "00000". This script is tested, if you wan't help with something else, feel free to PM me ]]

local gearID = 00000 -- Add the ID of gear here
for _,plrs in pairs(game.Players:GetChildren()) do if plrs:IsA('Player') and plrs:FindFirstChild('Backpack') then
local Gear=game:GetService("InsertService"):LoadAsset(gearID)
for _, v in pairs(Gear:GetChildren()) do
if not(plrs.Backpack:FindFirstChild(v.Name))then
v:Clone().Parent = plrs.Backpack
end
end
end end
Report Abuse
VividNeon is not online. VividNeon
Joined: 24 Apr 2012
Total Posts: 1607
22 Sep 2014 10:38 AM
I recommend using Hyroad's:

for _,p in pairs(game.Players:GetPlayers()) do
if p then
game.Lighting.Sword:Clone().Parent = p.Backpack
end
end

And then just put the sword that you want to clone in lightning and name it "Sword".
Report Abuse
MrCss is not online. MrCss
Joined: 10 Jul 2014
Total Posts: 235
22 Sep 2014 10:45 AM
well, he said gear, it means he needs a gear to insert, Indirectly, Hyroad is right too, but I could have said that. the thing is, I posted what he asked for.


Support():
Liked our help, please support us by joining:

http://www.roblox.com/My/Groups.aspx?gid=1129425
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