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
 

Need help with script!

Previous Thread :: Next Thread 
jameswizard8 is not online. jameswizard8
Joined: 24 Jan 2010
Total Posts: 5405
28 Jul 2012 07:48 PM
game.Players.PlayerAdded:connect(function(player)
player.CharacterAdded:wait()
local leaderstats = Instance.new("Model", player)
leaderstats.Name = "leaderstats"
local something = Instance.new("IntValue", leaderstats)
something.Name = "Stolen"
something.Value = 0
end)

function longMessage(text)
local message = Instance.new("Message")
message.Text = text
wait(10)
message:Destroy()
end

function mediumMessage(text)
local message = Instance.new("Message")
message.Text = text
wait(5)
message:Destroy()
end

function shortMessage(text)
local message = Instance.new("Message")
message.Text = text
wait(3)
message:Destroy()
end

function quickMessage(text)
local message = Instance.new("Message")
message.Text = text
wait(1)
message:Destroy()
end

function mediumHint(text)
local hint = Instance.new("Hint")
hint.Text = text
wait(5)
hint:Destroy()
end

function shortHint(text)
local hint = Instance.new("Hint")
hint.Text = text
wait(3)
hint:Destroy()
end

function quickHint(text)
local hint = Instance.new("Hint")
hint.Text = text
wait(1)
hint:Destroy()
end

local sword = Workspace.Sword


game.Players.PlayerAdded:connect(function(player)
while wait() do
if game.Players.NumPlayers >= 2 then
wait(5)
local copy = sword:Clone()
copy.Parent = player.Backpack
wait(1)
mediumMessage("The game is starting! Get to the start!")
wait(10)
shortMessage("I hope you are ready, because HERE WE GO!")
wait(3)
quickHint("5")
wait(1)
quickHint("4")
wait(1)
quickHint("3")
wait(1)
quickHint("2")
wait(1)
quickHint("1")
wait(1)
quickMessage("GO!")
game.Workspace.Start.Transparency = 0.6
game.Workspace.Start.CanCollide = false
else
local message = Instance.new("Message")
message.Text = "Not enough players! Invite some friends!"
end
end
end)

--I cant find out what is wrong with it because there isnt any output. When I join the game, it doesnt say "Not enough players! Invite some friends!"

~★That, is why we live in a world full of morons★~
Report Abuse
thedeathmaster01 is not online. thedeathmaster01
Joined: 14 Mar 2010
Total Posts: 6331
28 Jul 2012 07:51 PM
You keep naming the variable 'message' it has to change everytime.
Report Abuse
jameswizard8 is not online. jameswizard8
Joined: 24 Jan 2010
Total Posts: 5405
28 Jul 2012 07:53 PM
@thedeathmaster01

So I have to do:

local message1 = ...
local message2 = ...
local message3 = ...

???

~★That, is why we live in a world full of morons★~
Report Abuse
Mathfreak231 is not online. Mathfreak231
Joined: 21 Jun 2010
Total Posts: 5311
28 Jul 2012 08:31 PM
james is that u from RT?

~This sig is false~
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