|
| 04 Dec 2015 02:25 PM |
I want to make a game like cod gun game. So i would someone to be able to help me. There should be: A starting gun 2nd gun 3rd gun 4th gun 5th gun 6th gun 7th gun 8th gun 9th gun Use these functions Players:GetAllChildren(ppl) - To get all players Instance.new ("IntValue") - To create the value IntValue.Parent = ppl - To put the value into the players IntValue.Value = 0 -- To make the value to 0 (1st starting weapon) if game.ServerScriptStorage.leaderboard.ppl = 1 -- If intvalue is 1 (players got a KO) then local Gun1Clone = game.ServerStorage.Gun1:Clone() -- Clones the gun Gun1Clone = ppl.Backpack -- Puts the cloned gun into the ppl backpack.
if game.ServerScriptStorage.leaderboard.ppl = 10 (lets act like 9 is the final gun)
|
|
|
| Report Abuse |
|
|
| |
|
Casualist
|
  |
| Joined: 26 Jun 2014 |
| Total Posts: 4443 |
|
| |
|
RonDanino
|
  |
| Joined: 21 Dec 2012 |
| Total Posts: 290 |
|
|
| 04 Dec 2015 03:00 PM |
gonna make the whole thing in this post.i doubt it will work cause it's written here and I'm not that experienced, also it'll probably wont be the most efficient way, but it'll give you a lead. I'm not going to use all the functions you gave tho, i'll leave it for you to edit ______________________________________________________ game.Players.PlayerAdded:connect(function(player) local 1stgun = location local 2ndgun = location local 3rdgun = location local 4thgun = location local 5thgun = location local 6thgun = location local 7thgun = location local 8thgun = location local 9thgun = location local kills = player.leaderstats.Kills local deaths = player.leaderstats.Deaths local killstreak = Instance.new("IntValue") local ez = player.Backpack if kills.Value = kills.Value + 1 then killstreak.Value = killstreak.Value + 1 end if deaths.Value = deaths.Value + 1 then killstreak.Value = 0 end --Change the x to the number of kills you want if killstreak.Value >= x then 1stgun:Remove() Gun1 = 2ndgun:clone() Gun1.Parent = ez elseif killstreak.Value >= x then Gun1.Parent = nil Gun2 = 3rdgun:clone() Gun2.Parent = ez elseif killstreak.Value >=x then Gun2.Parent = nil Gun3 = 4thgun:clone() Gun3.Parent = ez elseif killstreak.Value >=x then Gun3.Parent = nil Gun4 = 5thgun:clone() Gun4.Parent = ez elseif killstreak.Value >=x then Gun4.Parent = nil Gun5 = 6thgun:clone() Gun5.Parent = ez elseif killstreak.Value >=x then Gun5.Parent = nil Gun6 = 7thgun:clone() Gun6.Parent = ez elseif killstreak.Value >=x then Gun6.Parent = nil Gun7 = 8thgun:clone() Gun7.Parent = ez elseif killstreak.Value >=x then Gun7.Parent = nil Gun8 = 9thgun:clone() Gun8.Parent = ez end end)
-- It'll probably wont work, It might work tho. |
|
|
| Report Abuse |
|
|
|
| 04 Dec 2015 03:15 PM |
why even waste time with this kid.
http://www.roblox.com/ITS-FREE-item?id=130771265&rbxp=8320118 |
|
|
| Report Abuse |
|
|