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: "Argument 1 missing or nil"

Previous Thread :: Next Thread 
aaront2000 is not online. aaront2000
Joined: 27 Oct 2009
Total Posts: 189
23 Sep 2016 06:19 PM
This script is supposed to give you a gear by saying the URL of it
Example: https://www.roblox.com/catalog/125013769/Linked-Sword

----------------------------------------------------------------------------------------

function processCommand(speaker, message)
if string.sub(message, 1, 31) == "https://www.roblox.com/catalog/" then
local extract = string.sub(message, 32, string.len(message))
##################################################################################################################################################################################################################################################### assetID = (assetID .. letterArray[i])
end
assetID = tonumber(assetID)
local items = game:GetService("InsertService"):LoadAsset(assetID):GetChildren()
for i=1, #items do
items[i].Parent = speaker.Backpack
end
end
end

game.Players.PlayerAdded:connect(function(player)
player.Chatted:connect(function(message)
processCommand(player, message)
end)
end)

----------------------------------------------------------------------------------------

19:17:59.527 - Argument 1 missing or nil
19:17:59.527 - Stack Begin
19:17:59.528 - Script 'Workspace.GearURL', Line 15 - global processCommand
19:17:59.528 - Script 'Workspace.GearURL', Line 24
19:17:59.529 - Stack End
Report Abuse
aaront2000 is not online. aaront2000
Joined: 27 Oct 2009
Total Posts: 189
23 Sep 2016 06:19 PM
welp it got hashtagged, thanks a lot roblox -_-
Report Abuse
pullman45 is not online. pullman45
Joined: 09 Jul 2012
Total Posts: 2891
23 Sep 2016 06:20 PM
rip
Report Abuse
aaront2000 is not online. aaront2000
Joined: 27 Oct 2009
Total Posts: 189
23 Sep 2016 06:20 PM
#####################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################
Report Abuse
Crimsonal is not online. Crimsonal
Joined: 23 Apr 2011
Total Posts: 1795
23 Sep 2016 06:20 PM
pastebin
Report Abuse
aaront2000 is not online. aaront2000
Joined: 27 Oct 2009
Total Posts: 189
23 Sep 2016 06:22 PM
it's in the description here:

https://www.roblox.com/games/508400227/The-script
Report Abuse
Kodran is not online. Kodran
Joined: 15 Aug 2013
Total Posts: 5330
23 Sep 2016 06:28 PM
Clearly AssetID is not a number. You should really learn about pattern matching and stuff to do this better.


Report Abuse
aaront2000 is not online. aaront2000
Joined: 27 Oct 2009
Total Posts: 189
23 Sep 2016 06:33 PM
I see my fault here:
I was supposed to do
local letter = string.sub(extract, i, i)
not
local letter = string.sub(message, i, i)
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