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 » Scripters
Home Search
 

Re: Cutscene Script Problem.

Previous Thread :: Next Thread 
ColdUndermined is not online. ColdUndermined
Joined: 25 Jan 2010
Total Posts: 1819
24 Dec 2014 10:40 PM
Hey, So I have this script. What it does is start the game at start_game() then go to run_game() and play a cutscene. The problem is the cutscene only plays for Player 1, This game requires 8 Players, So players 2-8 won't see the cutscene at all. run_game() has more code after it (including more cutscenes). But I need a fix for this so that everyone see's the cutscene. Thanks -Cold

function run_game()
script.IntroHarmony:Play()
for _,player in pairs(game.Players:GetPlayers()) do
local new_script = script.CutsceneB1:clone()
new_script.Parent = player.Backpack
new_script.Disabled = false
script.Message.Text= "I never thought the Zombie apocalypse would happen"
wait(3)
script.Message.Text= "When it did, nobody was ready"
wait(3)
script.Message.Text= ""
wait(3)
script.Message.Text= "There was chaos in the streets"
wait(3)
script.Message.Text="The zombies killed everyone in a matter of days"
wait(3)
script.Message.Text= ""
wait(3)
script.Message.Text="They say it started in a lab in Atlanta City"
wait(3)
script.Message.Text="They were trying to create a chemical weapon, But it all went wrong"
wait(3)
new_script.Disabled = true
script.IntroMusic:Play()
script.Message.Text=""
for _,player in pairs(game.Players:GetPlayers()) do
local new_script = script.IntroGUI:clone()
new_script.Parent = player.PlayerGui
wait(1)
new_script.Frame.TextLabel.Text = "OutBreak"
wait(1)
script.Teleport.Value = true
wait(1)
script.Teleport.Value = false
wait(8)
new_script.Frame.TextLabel.Text = "FOUR DAYS LATER"
wait(5)
new_script:Remove()

function start_game()
running = true
script.Theme:Play()
wait(math.random(10,20))
script.DeadPlayers.Value = 0
script.StartPlayers.Value = 0
print("Starting a new game of OutBreak.")
script.Message.Text = "Welcome to OutBreak."
wait(3)
script.Message.Text = "OutBreak will begin in: 5."
script.Five:Play()
wait(1)
script.Message.Text = "OutBreak will begin in: 4."
script.Four:Play()
wait(1)
script.Message.Text = "OutBreak will begin in: 3."
script.Three:Play()
wait(1)
script.Message.Text = "OutBreak will begin in: 2."
script.Two:Play()
wait(1)
script.Message.Text = "OutBreak will begin in: 1."
script.One:Play()
wait(1)
script.Message.Text = "OutBreak will begin in: 0."
script.Start:Play()
wait(1)
script.Message.Text = ""
script.Game.Value = true
--script.StartPlayers.Value = game.Players.NumPlayers
script.Theme:Stop()
run_game()
end
Report Abuse
ColdUndermined is not online. ColdUndermined
Joined: 25 Jan 2010
Total Posts: 1819
24 Dec 2014 10:41 PM
Just noticed. There are is a series of "end" at the end of the run_game() function.
Report Abuse
ColdUndermined is not online. ColdUndermined
Joined: 25 Jan 2010
Total Posts: 1819
25 Dec 2014 01:25 AM
~Bump~
Report Abuse
ColdUndermined is not online. ColdUndermined
Joined: 25 Jan 2010
Total Posts: 1819
25 Dec 2014 03:16 AM
~Bump~
Report Abuse
eLunate is not online. eLunate
Joined: 29 Jul 2014
Total Posts: 13268
25 Dec 2014 03:20 AM
Wrap your for loops with

coroutine.wrap(function()
-- For loops and script in here
end)()
Report Abuse
ColdUndermined is not online. ColdUndermined
Joined: 25 Jan 2010
Total Posts: 1819
25 Dec 2014 03:48 PM
Didn't work
Report Abuse
ColdUndermined is not online. ColdUndermined
Joined: 25 Jan 2010
Total Posts: 1819
25 Dec 2014 04:07 PM
~Bump~
Report Abuse
ColdUndermined is not online. ColdUndermined
Joined: 25 Jan 2010
Total Posts: 1819
25 Dec 2014 05:54 PM
~Bump~
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • 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