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 do I add a weapon into my game?

Previous Thread :: Next Thread 
iChairman is not online. iChairman
Joined: 05 Jun 2012
Total Posts: 4773
27 Feb 2017 04:32 PM
Ok, I'm trying to put a Taser into my game. What I am trying does not currently work.

game:get("rbxassetid://82357123")[1].Parent = workspace

If it does, do I have to edit it, or get a brand new script?


Working on [WIP] Bar Fight!
Report Abuse
IcedVapour is not online. IcedVapour
Joined: 10 Nov 2013
Total Posts: 2741
27 Feb 2017 04:33 PM
Use InsertService
Report Abuse
Wunder_Wulfe is online. Wunder_Wulfe
Joined: 13 Sep 2016
Total Posts: 8356
27 Feb 2017 04:33 PM
i cant help you with that




without a license thats illegal

:(
Report Abuse
iChairman is not online. iChairman
Joined: 05 Jun 2012
Total Posts: 4773
27 Feb 2017 04:34 PM
Do I put the script in there?


Working on [WIP] Bar Fight!
Report Abuse
Wunder_Wulfe is online. Wunder_Wulfe
Joined: 13 Sep 2016
Total Posts: 8356
27 Feb 2017 04:35 PM
no you should look at the wiki more often as it will tell you what it can be used for
Report Abuse
iChairman is not online. iChairman
Joined: 05 Jun 2012
Total Posts: 4773
27 Feb 2017 04:48 PM
when i go to the wiki and i type in insertservice and i scroll down to click the example, it pops up security. i do not think this is very helpful


Working on [WIP] Bar Fight!
Report Abuse
Gomlsauresrex is not online. Gomlsauresrex
Joined: 25 Mar 2016
Total Posts: 3588
27 Feb 2017 04:51 PM
local id = 82357123
local assetmodel = game:GetService("InsertService"):LoadAsset(id)
if assetmodel then
local asset = assetmodel:GetChildren()[1]
if asset then asset.Parent = game.Workspace end
end

Now get out.





















lawl
Report Abuse
SwaggyNob is not online. SwaggyNob
Joined: 12 Jan 2017
Total Posts: 91
27 Feb 2017 04:51 PM
just put it into starterpack if you wanna spawn in with it?
Report Abuse
Wunder_Wulfe is online. Wunder_Wulfe
Joined: 13 Sep 2016
Total Posts: 8356
27 Feb 2017 04:52 PM
because you are not using it correctly
it says that you can use LoadAsset on it and it shows what LoadAsset requires as arguments, what it does, and what it will return

in this case it says it is a method, returns the loaded asset (or nil), and requires the asset id

also why would you need to use the insert service when you can store the weapon and clone it
Report Abuse
iChairman is not online. iChairman
Joined: 05 Jun 2012
Total Posts: 4773
27 Feb 2017 04:54 PM
no i do not want it in starterpack
its for a gamepass


Working on [WIP] Bar Fight!
Report Abuse
Wunder_Wulfe is online. Wunder_Wulfe
Joined: 13 Sep 2016
Total Posts: 8356
27 Feb 2017 04:54 PM
you still do not need insert service ^
Report Abuse
lagio2 is not online. lagio2
Joined: 11 Mar 2010
Total Posts: 4001
27 Feb 2017 04:56 PM
"for a gamepass"

check if player has gamepass
if player has gamepass then
COPY FROM REPLICATEDSTORAGE/SERVERSTORAGE into player's backpack


no need to use insertservice
Report Abuse
iChairman is not online. iChairman
Joined: 05 Jun 2012
Total Posts: 4773
27 Feb 2017 04:57 PM
IcedVapour replied first and said that i need insertservice so thats why i started asking about it


Working on [WIP] Bar Fight!
Report Abuse
iChairman is not online. iChairman
Joined: 05 Jun 2012
Total Posts: 4773
27 Feb 2017 04:58 PM
i put in gomi's script yet the item is not in explorer


Working on [WIP] Bar Fight!
Report Abuse
iChairman is not online. iChairman
Joined: 05 Jun 2012
Total Posts: 4773
27 Feb 2017 05:01 PM
im going to have to come back to this later. i have a group training right now, sorry.


Working on [WIP] Bar Fight!
Report Abuse
Mister_Manakin is not online. Mister_Manakin
Joined: 16 Sep 2009
Total Posts: 1935
27 Feb 2017 05:02 PM
I'm sure he's not gonna stop until someone writes him a script.
Report Abuse
iChairman is not online. iChairman
Joined: 05 Jun 2012
Total Posts: 4773
27 Feb 2017 06:29 PM
im sure ur not going to be nice to people until you have good attitude.


Working on [WIP] Bar Fight!
Report Abuse
Mister_Manakin is not online. Mister_Manakin
Joined: 16 Sep 2009
Total Posts: 1935
27 Feb 2017 07:53 PM
So you do want a script then...
Report Abuse
iChairman is not online. iChairman
Joined: 05 Jun 2012
Total Posts: 4773
28 Feb 2017 07:26 AM
im not really looking for a script. i just want to know how to insert a new model of a taser and then put it in a gamepass. i also want to know how to put a baton in the same gamepass
Report Abuse
Eventive is not online. Eventive
Joined: 28 Jul 2011
Total Posts: 9827
28 Feb 2017 07:38 AM
Put the weapon in ReplicatedStorage, use MarketPlaceService, check fior the pass, if they have it clone it from ReplicatedStorage into that players backpack. No need to insert it otherwise.


ATR'er since 2013.
Report Abuse
iChairman is not online. iChairman
Joined: 05 Jun 2012
Total Posts: 4773
28 Feb 2017 04:18 PM
Actually I found a simpler way to do it.
My gamepass works now!
Sorry for the troubles, but thanks for the help!


Working on [WIP] Bar Fight!
Report Abuse
lagio2 is not online. lagio2
Joined: 11 Mar 2010
Total Posts: 4001
28 Feb 2017 04:34 PM
Bruh
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