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: Very simple logic why not work?!

Previous Thread :: Next Thread 
noobguest2236 is not online. noobguest2236
Joined: 22 Jan 2010
Total Posts: 138
28 Jan 2012 10:25 PM
function playerJOIN(player)
player.Backpack.ChildAdded:connect(function()
local msg = Instance.new("Hint",Workspace)
msg.Text = "WORK!"
game:GetService("Debris"):AddItem(msg,5)
end)
end
game.Players.PlayerAdded:connect(playerJOIN)
Report Abuse
Wowgnomes is not online. Wowgnomes
Joined: 27 Sep 2009
Total Posts: 26255
28 Jan 2012 10:25 PM
[ Content Deleted ]
Report Abuse
noobguest2236 is not online. noobguest2236
Joined: 22 Jan 2010
Total Posts: 138
28 Jan 2012 10:27 PM
There is no output that is saying its not working. So when I pick up the tool the message does not appear, its getting on my nerve.
Report Abuse
noobguest2236 is not online. noobguest2236
Joined: 22 Jan 2010
Total Posts: 138
28 Jan 2012 10:37 PM
Anyone?
Report Abuse
KnightmareXD is not online. KnightmareXD
Joined: 14 Jul 2009
Total Posts: 11189
28 Jan 2012 10:39 PM
Yea, but when you pick up a tool, it goes to the character. I assume you deselect it, then it goes to Backpack, though, and it still doesn't work?

† KMXD †
Report Abuse
xvgigakid is not online. xvgigakid
Joined: 22 Jun 2008
Total Posts: 4407
28 Jan 2012 10:40 PM
function playerJOIN(player)
wait(0.1) --The backpack still doesnt exist. Give it some time to load it.
player.Backpack.ChildAdded:connect(function()
local msg = Instance.new("Hint",Workspace)
msg.Text = "WORK!"
game:GetService("Debris"):AddItem(msg,5)
end)
end
game.Players.PlayerAdded:connect(playerJOIN)

@Wowgnome
I thought you were saying you didnt know what an output was,
Till I read it over again.
DewottNinja got me all confused on that topic >.<
Report Abuse
noobguest2236 is not online. noobguest2236
Joined: 22 Jan 2010
Total Posts: 138
28 Jan 2012 10:48 PM
@Knightmare kinda good point but yeah when I deselect still nothing. BUT WAIT! I GOT MAYBE ILL TRY:

player.Character.ChildAdded:connect(InsteadOFBackpack)
Report Abuse
KnightmareXD is not online. KnightmareXD
Joined: 14 Jul 2009
Total Posts: 11189
28 Jan 2012 10:49 PM
I guess you could try. :S And maybe take a look at xv's.

† KMXD †
Report Abuse
noobguest2236 is not online. noobguest2236
Joined: 22 Jan 2010
Total Posts: 138
28 Jan 2012 11:28 PM
Well the child added didn't work. Sorry for late reply I had to eat, I will now try xv's script.
Report Abuse
noobguest2236 is not online. noobguest2236
Joined: 22 Jan 2010
Total Posts: 138
28 Jan 2012 11:51 PM
It did not work ): Please someone if you know what to do please help me.
Report Abuse
xvgigakid is not online. xvgigakid
Joined: 22 Jun 2008
Total Posts: 4407
28 Jan 2012 11:55 PM
What exactly are you expecting to get added to backpack?
Report Abuse
noobguest2236 is not online. noobguest2236
Joined: 22 Jan 2010
Total Posts: 138
29 Jan 2012 12:03 AM
Anything. Model, tools, hat etc, aslong as it triggers the message it will be fine.
Report Abuse
SDuke524 is not online. SDuke524
Joined: 29 Jul 2008
Total Posts: 6267
29 Jan 2012 12:16 AM
And this is everything you have in your script?
Report Abuse
noobguest2236 is not online. noobguest2236
Joined: 22 Jan 2010
Total Posts: 138
29 Jan 2012 12:28 AM
Yes it's the only code in it
Report Abuse
SDuke524 is not online. SDuke524
Joined: 29 Jul 2008
Total Posts: 6267
29 Jan 2012 12:29 AM
Try adding

repeat Wait(); until player.Backpack

just under your function declaration.
Report Abuse
noobguest2236 is not online. noobguest2236
Joined: 22 Jan 2010
Total Posts: 138
29 Jan 2012 12:36 AM
Okay.
Report Abuse
noobguest2236 is not online. noobguest2236
Joined: 22 Jan 2010
Total Posts: 138
29 Jan 2012 01:27 AM
It didn't work):
Report Abuse
blueymaddog is not online. blueymaddog
Joined: 23 Sep 2009
Total Posts: 5459
29 Jan 2012 01:45 AM
try this:

function playerJOIN(player)
repeat wait() until player:FindFirstChild("Backpack")
player.Backpack.ChildAdded:connect(function()
local msg = Instance.new("Hint",player.PlayerGui)
msg.Text = "WORK!"
game:GetService("Debris"):AddItem(msg,5)
end)
end
game.Players.PlayerAdded:connect(playerJOIN)
Report Abuse
noobguest2236 is not online. noobguest2236
Joined: 22 Jan 2010
Total Posts: 138
29 Jan 2012 05:53 AM
Nope didn't work ): Sorry I had to reply very late, I had to go to church, someone professional enough who have encountered this problem and solved it please help me!
Report Abuse
noobguest2236 is not online. noobguest2236
Joined: 22 Jan 2010
Total Posts: 138
29 Jan 2012 06:55 AM
BUMP
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