Jump to content
sizraide

Cutscene Script won't stop looping.

Recommended Posts

I'm fairly new to scripting and mission editing in general. I used a script called MovieMaker by aliascartoons

I have a init.sqf file that runs the script for me. Here it is.
 

Quote

cut_scene_1 = [] execVM "AL_movie\cut_scene_screen_effect.sqf";
waitUntil {scriptdone cut_scene_1};
sleep 1;
null = [] execVM "AL_movie\cut_scene_screen_effect.sqf";


then I have the cut_scene_screen_effect.sqf that is the cutscene itself.

Quote

sleep 15;
if (!hasInterface) exitWith {};
cutText ["", "BLACK IN", 0];
-----------------------------------------------------------------------------------------------------------*/

// 
loopdone = false;
while {!loopdone} do {
//


// CUTSCENE

// text
_txt_1 = ["DEATH FROM ABOVE",5,"center","3","#d99e30"] execVM "AL_movie\txt_display.sqf";
// -------------------------------------
_firstshot = [cam1, cam1, target_scene_1, 10, 1, 0.8, true, 0, 0, 2,"grain","none",0,"uav1",FALSE] execVM "AL_movie\camera_work.sqf";
waitUntil {scriptdone _firstshot};

// text
_txt_2 = ["15 minutes after the crash",3,"top_right","1","#FFFFFF"] execVM "AL_movie\txt_display.sqf";
// -------------------------------------
_secondshot = [cam2, cam2, target_scene_2, 7, 1, 0.8, true, 0, 0, 2,"grain","none",0,"uav2",FALSE] execVM "AL_movie\camera_work.sqf";
waitUntil {scriptdone _secondshot};

// text
_txt_3 = ["Map created by sizraide",3,"bottom_right","1","#FFFFFF"] execVM "AL_movie\txt_display.sqf";
// -------------------------------------
_thirdshot = [cam3, cam3, target_scene_3, 5, 0.8, 1, true, 0, 0, 2,"grain","none",0,"intro_music",FALSE] execVM "AL_movie\camera_work.sqf";
waitUntil {scriptdone _thirdshot};

// --------------->> end of camera shots <<---------------------------------------------------------
};
cutText [" ", "BLACK IN", 3];
_camera = "camera" camCreate (getpos player);
_camera cameraeffect ["terminate", "back"];
camDestroy _camera;
"dynamicBlur" ppEffectEnable true;   
"dynamicBlur" ppEffectAdjust [100];   
"dynamicBlur" ppEffectCommit 0;     
"dynamicBlur" ppEffectAdjust [0.0];  
"dynamicBlur" ppEffectCommit 4;



When I play the scenario, the scene plays as normal with no errors. But it doesn't stop looping the cutscene. I want it to stop looping.

I tried terminate and it doesn't work. Any help?

Share this post


Link to post
Share on other sites

In the first block (init.sqf) you have it running the script twice.

You can delete the last 3 lines.

 

Then in the second block (cut_scene_screen_effect.sqf) you have it running in a loop.

Remove the while {!loopdone} do { };

 

Using "while" is a forever loop as long as the part in the brackets are True.

(on my phone and can't type more details)

  • Thanks 1

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×