025110
|
  |
| Joined: 23 Nov 2012 |
| Total Posts: 57661 |
|
|
| 10 Jul 2016 11:35 AM |
so when the player leaves, I want the script to check if in the players backpack, they have a tool that is numbered 1 - 48, and just print that number that is returned
this is what I have so far
game.Players.PlayerRemoving:connect(function(player) --player.Backpack so op end)
|
|
|
| Report Abuse |
|
|
025110
|
  |
| Joined: 23 Nov 2012 |
| Total Posts: 57661 |
|
| |
|
025110
|
  |
| Joined: 23 Nov 2012 |
| Total Posts: 57661 |
|
| |
|
025110
|
  |
| Joined: 23 Nov 2012 |
| Total Posts: 57661 |
|
| |
|
Sir_ka
|
  |
| Joined: 23 Apr 2015 |
| Total Posts: 1646 |
|
|
| 10 Jul 2016 11:59 AM |
--i think that would be something like this: hi1 = 1 hi2 = 2 hi3 = 3
game.Players.PlayerRemoving:connect(function(player) for i,v in pairs(game.Players:GetChildren())do if v.Character.BackPack.hi1 == true then print("hi1 is in backpack") else if v.Character.BackPack.hi2 == true then print("hi2 is in backpack") else if v.Character.BackPack.hi2 == true then print("hi3 is in the backpack") end end end
end end)
--not that sure though im not the best at scripting
|
|
|
| Report Abuse |
|
|
Sir_ka
|
  |
| Joined: 23 Apr 2015 |
| Total Posts: 1646 |
|
|
| 10 Jul 2016 12:01 PM |
sorry i made a mistake at line 7 change BackPack to Backpack
|
|
|
| Report Abuse |
|
|
025110
|
  |
| Joined: 23 Nov 2012 |
| Total Posts: 57661 |
|
| |
|