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: Tournament Script

Previous Thread :: Next Thread 
Ronldino is not online. Ronldino
Joined: 26 Sep 2010
Total Posts: 494
24 Mar 2014 06:14 PM
I'm trying to creat a game where 2 people get teleported to a certain spot, and play until a certain amount of goals is reached. I found this tournament script and I would like to know if it's all good. Also, where and how do you change the position they spawn in?

while true do
local plr = game.Players:GetChildren()
local randplr = [math.random(#plr)] --Selects a random player.
local plr2 = game.Players:GetChildren()
local randplr2 = [math.random(#plr2)] --Selects a random player.
wait(120)
local msg = Instance.new("Message")
msg.Text = randplr.Name.." has been selected for a 1v1!"
msg.Parent = game.Workspace
wait(5)
msg.Text = randplr2.Name.." has also been selected for a 1v1!"
wait(3)
msg.Text = "Get ready!"
randplr.Character.Torso.CFrame = CFrame.new(-59.5, 1.5, 242.5) <---- is it here?
randplr2.Character.Torso.CFrame = CFrame.new(-57.5, 1.5, 1.5) <---- and here?
randplr.Character.Torso.Anchored = true
randplr2.Character.Torso.Anchored = true
wait(4)
msg.Text = "Let's score some goals!"
wait(1)
msg:Remove()
randplr.Character.Torso.Anchored = false
randplr2.Character.Torso.Anchored = false
end


Et fac quod vis facere ad laborandum est ad
Report Abuse
TheLagScript is not online. TheLagScript
Joined: 13 Apr 2012
Total Posts: 2004
24 Mar 2014 06:16 PM
yes, yes it is.
It's where u stated.

Instead of a useless signature, just read my Bio. It tells all about me. http://www.roblox.com/User.aspx?ID=25748866
Report Abuse
drco12 is not online. drco12
Joined: 26 Sep 2009
Total Posts: 234
24 Mar 2014 06:16 PM
Yes, it is there. However, this is not the best tournament script there is; you might want to try looking for another one the works with iv in pairs.
Report Abuse
Ronldino is not online. Ronldino
Joined: 26 Sep 2010
Total Posts: 494
24 Mar 2014 06:20 PM
See the thing is, I looked everywhere and can only find Sword Fighting tournament scripts, and I tried looking even in more depth to try to create the script myself, but I feel like it's too complicated for a new scripter like myself. Any suggestions?

Et fac quod vis facere ad laborandum est ad
Report Abuse
tyleralex123 is not online. tyleralex123
Joined: 01 Apr 2009
Total Posts: 19934
24 Mar 2014 06:21 PM
@dr

When working with iv, in pairs, does it ensure that the same player is not picked twice?
Report Abuse
drco12 is not online. drco12
Joined: 26 Sep 2009
Total Posts: 234
24 Mar 2014 06:31 PM
No, because if math is random anything can happen. However, the most I have ever experienced a player being picked in a row is 3 times with iv in pairs... then it moves on to new players. It is rare that it picks the same player, but it still happens.
Report Abuse
drco12 is not online. drco12
Joined: 26 Sep 2009
Total Posts: 234
24 Mar 2014 06:32 PM
@ Ron look up 'minigame script' in free models. That should give you a starting place for making a tournament script. Currently, there is no free SF tournament script that is good.
Report Abuse
Ronldino is not online. Ronldino
Joined: 26 Sep 2010
Total Posts: 494
24 Mar 2014 09:27 PM
I dont want a sword fighting script though, all of them are mostly based around sword fighting. I just need a simple script that randomly teleports 2 players to set position, they play, someone wins, than it will randomly pick again.

Et fac quod vis facere ad laborandum est ad
Report Abuse
roboslayer10 is not online. roboslayer10
Joined: 08 Aug 2011
Total Posts: 206
24 Mar 2014 09:31 PM
this could be a problem. I know, I tried.

if you select a random player, then select another random player, what if you chose the same player twice?

You have to have a setup such that when a player is selected he is removed from a table of non-selected players, then a new player is chosen from the non-players and told to fight against the first player.
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