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: Rounds help

Previous Thread :: Next Thread 
DeSpizer27 is not online. DeSpizer27
Joined: 13 Jul 2012
Total Posts: 2679
05 Apr 2014 12:55 PM
I have a simple round script, it requires 2 players, but when I play online it doesn't work.

Here's the script:

mini = 2

local knife = game.ServerStorage.Knife:Clone()

local coordinates = {Vector3.new(1.64, 1.8, -179.7), Vector3.new(2.44, 1.8, -396.5),
Vector3.new(83.5, 1.8, -287.5), Vector3.new(-80.9, 1.8, -286.5)}

randomCoor = coordinates[math.random(#coordinates)]

local playertorsovar = game.Players.LocalPlayer.Character.Torso

local playerclone = game.Players.LocalPlayer.StarterGear

while true do
if game.Players.NumPlayers > 1 then
wait(5)
playertorsovar.CFrame = CFrame.new(randomCoor)
knife.Parent = playerclone
end
if game.Players.NumPlayers < mini then
print ("Waiting for"..mini.."players to join.")
end
end


What's wrong with it? I don't know what I did wrong.
Report Abuse
islandmaker2012 is not online. islandmaker2012
Joined: 07 Nov 2012
Total Posts: 9327
05 Apr 2014 12:55 PM
while wait() do
Report Abuse
secretidagent is online. secretidagent
Joined: 07 Nov 2010
Total Posts: 1600
05 Apr 2014 12:56 PM
You dont need everything as a local variable. They arent in any functions, you are just defining them at the top of the script.
Report Abuse
vlekje513 is not online. vlekje513
Joined: 28 Dec 2010
Total Posts: 9057
05 Apr 2014 12:56 PM
srs
knife
murder mystery




output?
Report Abuse
vlekje513 is not online. vlekje513
Joined: 28 Dec 2010
Total Posts: 9057
05 Apr 2014 12:57 PM
also, when no one is in game, or 1 player only, there is a while true do end loop.
Report Abuse
DeSpizer27 is not online. DeSpizer27
Joined: 13 Jul 2012
Total Posts: 2679
05 Apr 2014 12:58 PM
It says something about local stuff in output.

No this isn't a murder mystery copy, it's a game where you have rounds, everyone gets a knife, last person alive wins @^ So sorta like a deathmatch.

So how do I fix it? :\
Report Abuse
DeSpizer27 is not online. DeSpizer27
Joined: 13 Jul 2012
Total Posts: 2679
05 Apr 2014 01:25 PM
bump
Report Abuse
DeSpizer27 is not online. DeSpizer27
Joined: 13 Jul 2012
Total Posts: 2679
05 Apr 2014 01:52 PM
I really need help with this.
Report Abuse
DeSpizer27 is not online. DeSpizer27
Joined: 13 Jul 2012
Total Posts: 2679
05 Apr 2014 02:24 PM
bump
how do I fix it?
Report Abuse
DeSpizer27 is not online. DeSpizer27
Joined: 13 Jul 2012
Total Posts: 2679
05 Apr 2014 02:58 PM
does anyone even know how to fix this script
or not
Report Abuse
DeSpizer27 is not online. DeSpizer27
Joined: 13 Jul 2012
Total Posts: 2679
05 Apr 2014 05:37 PM
bump
Report Abuse
DeSpizer27 is not online. DeSpizer27
Joined: 13 Jul 2012
Total Posts: 2679
05 Apr 2014 06:20 PM
:(
Report Abuse
DeSpizer27 is not online. DeSpizer27
Joined: 13 Jul 2012
Total Posts: 2679
05 Apr 2014 07:05 PM
You guys never answered, figured it out myself...
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