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

Previous Thread :: Next Thread 
Accost is not online. Accost
Joined: 26 Mar 2013
Total Posts: 8840
02 Jul 2013 10:00 PM
I just want a script that every 20 seconds, it will clone the model that it is in to workspace and delete the old model.

❀I'm a flower.❀
Report Abuse
robthehobo2 is not online. robthehobo2
Joined: 05 Jun 2013
Total Posts: 142
02 Jul 2013 10:28 PM
If it's simple, then why don't you make it yourself?
Report Abuse
DehMonsta is not online. DehMonsta
Joined: 13 Jun 2013
Total Posts: 3
02 Jul 2013 10:30 PM
i will help
Report Abuse
justin2865 is not online. justin2865
Joined: 30 Dec 2011
Total Posts: 4677
02 Jul 2013 10:37 PM
while wait(20) do
b = game:FindFirstChild("GameMap")
b:Destroy()
a = game.Lighting:Clone()
a.Parent = Workspace
end
Report Abuse
KnightmareXD is not online. KnightmareXD
Joined: 14 Jul 2009
Total Posts: 11189
02 Jul 2013 10:48 PM
@Justing

That would error should b not exist, and you tried to clone Lighting/parent it.
Report Abuse
Lonewarrior07 is not online. Lonewarrior07
Joined: 12 Jun 2011
Total Posts: 646
02 Jul 2013 10:54 PM
object = script.Parent
if (object ~= nil) and (object ~= game.Workspace) then
model = object
backup = model:clone() -- Make the backup
waitTime = 20 --Time to wait between regenerations, in your case 20 seconds
wait(math.random(0, waitTime))
while true do
wait(waitTime) -- Regen wait time

message.Parent = game.Workspace
model:remove()

wait(1) -- How long it takes to regen

model = backup:clone()
model.Parent = game.Workspace Change Workspace to wahtever parent you want
model:makeJoints()
end
end

-Lonewarrior07
Report Abuse
Lonewarrior07 is not online. Lonewarrior07
Joined: 12 Jun 2011
Total Posts: 646
02 Jul 2013 10:55 PM
By the way this is scripting helpers, not givers, I was feeling nice lol. Next time try to make it.
Report Abuse
SpleenYanks is not online. SpleenYanks
Joined: 24 Aug 2008
Total Posts: 921
02 Jul 2013 10:56 PM
local Model = [MODELHERE... so like, workspace.Model]
local OldClone = nil
while true do
pcall(function() OldClone:remove() end)
local NewClone = Model:clone()
NewClone.Parent = workspace
NewClone:MakeJoints()
OldClone = NewClone
wait(20)
end
Report Abuse
SpleenYanks is not online. SpleenYanks
Joined: 24 Aug 2008
Total Posts: 921
02 Jul 2013 10:56 PM
Beat me to it...
Darn floodcheck...
Report Abuse
Lonewarrior07 is not online. Lonewarrior07
Joined: 12 Jun 2011
Total Posts: 646
02 Jul 2013 10:57 PM
xD I hate it too
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