|
| 23 Jul 2014 12:13 PM |
| Im making a fairy tail game i have the magics ready and I put them all in starterpack when I join the game I have all the magics obviously Could someone tell me how to make it so they spawn with only one random magic out of them? Thank you alot |
|
|
| Report Abuse |
|
|
|
| 23 Jul 2014 12:14 PM |
game.CharacterSpawned:connect(function(char) char:CorePowerEnabled("Fly",true) -- Enables 'flying' ability. end) |
|
|
| Report Abuse |
|
|
fret13103
|
  |
| Joined: 15 Mar 2010 |
| Total Posts: 881 |
|
| |
|
fret13103
|
  |
| Joined: 15 Mar 2010 |
| Total Posts: 881 |
|
|
| 23 Jul 2014 12:15 PM |
| Is this some kind of crazy magic? |
|
|
| Report Abuse |
|
|
|
| 23 Jul 2014 12:15 PM |
| The thread has been answered. |
|
|
| Report Abuse |
|
|
|
| 23 Jul 2014 12:16 PM |
| What do you mean it makes you fly or does it do a random magic?Do i just copy that into a script and put it in workspace? |
|
|
| Report Abuse |
|
|
| |
|
|
| 23 Jul 2014 12:18 PM |
super pls, you don't need to troll.
owait im a hypocrite |
|
|
| Report Abuse |
|
|
|
| 23 Jul 2014 12:19 PM |
Oh and, if you want it to give random magic then here:
game.CharacterSpawned:connect(function(char) char:CorePowerEnabled(math.random(1,#Powers),true) -- Enables random ability. end) |
|
|
| Report Abuse |
|
|
|
| 23 Jul 2014 12:22 PM |
| by that it gives them a random magic from the starterpack right qq im a noob |
|
|
| Report Abuse |
|
|
|
| 23 Jul 2014 12:23 PM |
| No, it gives them magic powers built in by Roblox. |
|
|
| Report Abuse |
|
|
fret13103
|
  |
| Joined: 15 Mar 2010 |
| Total Posts: 881 |
|
|
| 23 Jul 2014 12:26 PM |
This one is more detailed
function OnPlayerEntered(LaaaLaaa Operaaaaah)
Player.CoreMagicPowers:PowersActive.PowerActivated = CoreMagicPowers:math.random(-pi,pi);
Should work. |
|
|
| Report Abuse |
|
|
fret13103
|
  |
| Joined: 15 Mar 2010 |
| Total Posts: 881 |
|
|
| 23 Jul 2014 12:26 PM |
wait forgot to put this on the end
game.Players.PlayerAdded:connect(onPlayerEntered) onPlayerEntered(game.Players:WaitForChild("Laaa Laaa Operaaaah")) |
|
|
| Report Abuse |
|
|
|
| 23 Jul 2014 12:28 PM |
| I just want a script that only gives one random tool from starterpack :( |
|
|
| Report Abuse |
|
|
|
| 23 Jul 2014 12:29 PM |
okie trolls, you can leave now
make a model in ReplicatedStorage named Magix with all the tools in it
local magix = game.ReplicatedStorage.Magix:GetChildren()
game.Players.PlayerAdded:connect(function(player) local magic = magix[math.random(1, #magix)]:Clone() magic.Parent = player.Backpack end)
owait im a hypocrite |
|
|
| Report Abuse |
|
|
|
| 23 Jul 2014 12:30 PM |
Edit:
local magix = game.ReplicatedStorage.Magix:GetChildren()
game.Players.PlayerAdded:connect(function(player) player.CharacterAdded:connect(function() local magic = magix[math.random(1, #magix)]:Clone() magic.Parent = player.Backpack end) end)
owait im a hypocrite |
|
|
| Report Abuse |
|
|
|
| 23 Jul 2014 12:30 PM |
| is that a troll?If it is im getting really annoyed |
|
|
| Report Abuse |
|
|
fret13103
|
  |
| Joined: 15 Mar 2010 |
| Total Posts: 881 |
|
|
| 23 Jul 2014 12:30 PM |
Shadow, do what Devious posted :)
we were just having some fun. |
|
|
| Report Abuse |
|
|
|
| 23 Jul 2014 12:31 PM |
It's not a troll.
owait im a hypocrite |
|
|
| Report Abuse |
|
|
|
| 23 Jul 2014 12:32 PM |
OK
MOVE ALL THE TOOLS IN STARTERPACK INSIDE ReplicatedStorage
and put this inside a script in workspace --
game.Players.PlayerAdded:connect(function(plr) plr.CharacterAdded:connect(function(char) repeat wait() until plr.Backpack
storage = game.ReplicatedStorage
newPower = storage:GetChildren()[math.random(1,#storage:GetChildren())]
newPower:clone() newPower.Parent = plr.Backpack
end) end) |
|
|
| Report Abuse |
|
|
|
| 23 Jul 2014 12:35 PM |
| where do I put the script in workspace right? |
|
|
| Report Abuse |
|
|
|
| 23 Jul 2014 12:35 PM |
@ DeviousDeviation
I didn't know you posted one already :c |
|
|
| Report Abuse |
|
|
| |
|
|
| 23 Jul 2014 12:36 PM |
No, put it in ServerScriptService.
owait im a hypocrite |
|
|
| Report Abuse |
|
|
| |
|