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: How could I do this?

Previous Thread :: Next Thread 
IceSIipper is not online. IceSIipper
Joined: 23 Mar 2013
Total Posts: 10447
22 Jun 2014 05:54 PM
I'm trying to make it so when someone picks up the 'pick' the game ends, but if no one finds it within the amount of time the game will also end. After the game ends I want it to restart too. I use this, it works but you have to wait til the end of the amount of time and get the pick and it doesn't restart.

local hint = Instance.new("Hint")
hint.Parent = game.Workspace
for i = 10,0, -1 do
hint.Text = ("Game ends in"..i)
wait(1)
end
local ToothPick = game.Workspace.ToothPick
repeat wait(1) until ToothPick.Parent ~= game.Workspace
hint:Destroy()
playing = true
print("playing true")

repeat wait(1) until hint.Text == ("0")
hint:Destroy()
ToothPick:Destroy()
playing = true
print("playing true")
Report Abuse
IceSIipper is not online. IceSIipper
Joined: 23 Mar 2013
Total Posts: 10447
22 Jun 2014 05:58 PM
b1
Report Abuse
IceSIipper is not online. IceSIipper
Joined: 23 Mar 2013
Total Posts: 10447
22 Jun 2014 06:00 PM
b2
Report Abuse
IceSIipper is not online. IceSIipper
Joined: 23 Mar 2013
Total Posts: 10447
22 Jun 2014 06:02 PM
b3
Report Abuse
IceSIipper is not online. IceSIipper
Joined: 23 Mar 2013
Total Posts: 10447
22 Jun 2014 06:03 PM
b4
Report Abuse
TrainingToTroll is not online. TrainingToTroll
Joined: 27 Oct 2012
Total Posts: 1757
22 Jun 2014 06:04 PM
I'm waiting until he gets to 9000.
Report Abuse
IceSIipper is not online. IceSIipper
Joined: 23 Mar 2013
Total Posts: 10447
22 Jun 2014 06:05 PM
unless you're going to post something useful don't post at all
Report Abuse
batistapowerbonbtla is not online. batistapowerbonbtla
Joined: 16 Dec 2011
Total Posts: 2203
22 Jun 2014 06:06 PM
1. Check the parent in the for loop
2. Enclose everything in a while loop

You also don't set playing to false anywhere
Report Abuse
TrainingToTroll is not online. TrainingToTroll
Joined: 27 Oct 2012
Total Posts: 1757
22 Jun 2014 06:07 PM
Ok then keep talking to yourself in your lonely thread. I am basically bumping it right now.
Alot of people dont have time for our threads i'm just keepin' ya' company.
Report Abuse
IceSIipper is not online. IceSIipper
Joined: 23 Mar 2013
Total Posts: 10447
22 Jun 2014 06:07 PM
I set playing to true earlier in the script, this is just a portion of it, and I will try what you suggested
Report Abuse
IceSIipper is not online. IceSIipper
Joined: 23 Mar 2013
Total Posts: 10447
22 Jun 2014 06:08 PM
to false i mean
Report Abuse
SenseiWarrior is online. SenseiWarrior
Joined: 09 Apr 2011
Total Posts: 12140
22 Jun 2014 06:09 PM
When the game restarts, just parent 'pick' to Workspace and reposition
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