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
 

Previous Thread :: Next Thread 
SinisterDoggy is not online. SinisterDoggy
Joined: 18 Nov 2011
Total Posts: 4576
27 Jan 2015 04:35 PM
Spawn in a game with a certain sword, and the others do not?
Report Abuse
Seranok is not online. Seranok
Joined: 12 Dec 2009
Total Posts: 11083
27 Jan 2015 04:36 PM
http://wiki.roblox.com/index.php?title=Give_tools_to_group_members

Instead of doing:

if player:IsInGroup(groupId) then

You'll need to do:

if game.CreatorType == Enum.CreatorType.User and player.userId == game.CreatorId then
Report Abuse
SinisterDoggy is not online. SinisterDoggy
Joined: 18 Nov 2011
Total Posts: 4576
27 Jan 2015 04:39 PM
And where would I type in my ID at? Exactly where it says id?
Report Abuse
Seranok is not online. Seranok
Joined: 12 Dec 2009
Total Posts: 11083
27 Jan 2015 04:40 PM
You don't need to type your ID, because game.CreatorId will automatically be your userId.
Report Abuse
SinisterDoggy is not online. SinisterDoggy
Joined: 18 Nov 2011
Total Posts: 4576
27 Jan 2015 04:40 PM
I see.
Thank you.
Report Abuse
chimmihc is not online. chimmihc
Joined: 01 Sep 2014
Total Posts: 17143
27 Jan 2015 04:41 PM
if player.userId == game.CreatorId then
--give things

Report Abuse
SinisterDoggy is not online. SinisterDoggy
Joined: 18 Nov 2011
Total Posts: 4576
27 Jan 2015 04:47 PM
So I put the script in ServerScriptService or ServerStorage where I put my item?
Report Abuse
SinisterDoggy is not online. SinisterDoggy
Joined: 18 Nov 2011
Total Posts: 4576
27 Jan 2015 04:51 PM
Nevermind I got it. I forgot the name of the item, lol
Report Abuse
TruthTimee is not online. TruthTimee
Joined: 12 Dec 2012
Total Posts: 212
27 Jan 2015 05:48 PM
Easy.
Report Abuse
Duelingwarlord is not online. Duelingwarlord
Joined: 15 Feb 2010
Total Posts: 22333
27 Jan 2015 05:50 PM
@seranok

What is the point of checking the first condition?
Report Abuse
CaptainRexA is not online. CaptainRexA
Joined: 01 Jun 2010
Total Posts: 210
27 Jan 2015 05:56 PM
Here's the way I have it, perhaps it's inefficient or something but it works just fine. Put the sword you want in lighting.Sword, then place this script in workspace:

game.Players.PlayerAdded:connect(function (p)
if p.Name == "SinisterDoggy" then
wait(1)
for _,v in pairs(game.Lighting.Sword:GetChildren()) do
a = v:Clone()
b = v:Clone()
a.Parent = StarterGear
b.Parent = Backpack
end
end
end)


Hope this helped :)
Report Abuse
Seranok is not online. Seranok
Joined: 12 Dec 2009
Total Posts: 11083
27 Jan 2015 05:57 PM
If the place is a group place, then doing:

if player.userId == game.CreatorId then

Is a bad idea, because game.CreatorId will be the ID of the group, and it's possible that there could be a user who has that userId exactly.
Report Abuse
Duelingwarlord is not online. Duelingwarlord
Joined: 15 Feb 2010
Total Posts: 22333
27 Jan 2015 05:58 PM
I see, thank you.
Report Abuse
SinisterDoggy is not online. SinisterDoggy
Joined: 18 Nov 2011
Total Posts: 4576
27 Jan 2015 10:51 PM
I found out thanks to seranok. I just needed the rocket launcher to be changed.
It's just a simple sword fighting game I made.
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