Forum Jump :

Author Message


Posts: 4
Rank:


Level: Member

Country: dk
Location:
Occupation:
Age:
In-game name:

 
#1 Posted at 2017-11-06 23:41        
     
So recently I started making a mission with a small fly-by intro. I made the Intro.sqs and it worked great, both MP and SP. But all of a sudden it stopped working and it no longer plays the intro.sqs in Multiplayer, only in singleplayer. I am nowhere near a good scripter so I have no idea if anything is wrong with this. The Intro.sqs is as following:

;=== Create Camera Start
_camera = "camera" camcreate [3695.91,3610.04,2.00]
_camera cameraEffect ["internal","back"]
;=== Create Camera End

;=== Intro Start

;comment "Camera 1st Position";
_camera camPrepareTarget [62702.37,101970.02,-12709.96];
_camera camPreparePos [11948.17,16755.07,4.27];
_camera camPrepareFOV 0.700;
_camera camCommitPrepared 0
@camCommitted _camera

;comment "1:18:56";
_camera camPrepareTarget [-61654.05,80241.80,-23310.99];
_camera camPreparePos [11996.67,16757.38,10.19];
_camera camPrepareFOV 0.700;
_camera camCommitPrepared 5
@camCommitted _camera

;comment "1:37:31";
_camera camPrepareTarget [-69520.05,69852.39,-23264.80];
_camera camPreparePos [11995.08,16819.83,2.14];
_camera camPrepareFOV 0.700;
_camera camCommitPrepared 5
@camCommitted _camera

~2

player cameraEffect ["terminate","back"]
camDestroy _camera

And the INIT for ann the playable characters (6) are:

this exec "Intro.sqs";

Is anyone able to spot my mistake? I can't seem to find it.


Author Message


Posts: 263
Rank:


Level: Videomaker

Country: ro
Location:
Occupation: freelancer
Age:
In-game name: ALIAS

 
#2 Posted at 2017-11-07 12:57        
     
Should work if you run the script from init.sqf. Otherwise you need to broadcast it using remoteexec, tho when you do this you have to make sure the script runs only for players who didn't saw the intro already, see the wiki for remoteexec' parameters or use a variable check.
The only thing i would add is a line at the beginning of the script just to avoid the script to run on server side, not that would have an effect but is better to avoid running scripts where aren't needed:
if {!hasinterface} exitwith {};
You also have to think if you want every player to see the intro if JIPs or respawns. JIPing in the middle of the action and being forced to watch the intro maybe isn't something you'd want.

Did you try my intro or movie maker script?
http://www.armaholic.com/page.php?id=30731
http://steamcommunity.com/sharedfiles/filedetails/?id=725091897 - this one i don't remember if i've updated it on Armaholic yet, so is better you pick it up from STEAM. I have plans to do a small update on it anyways.


Advertisement


Author Message


Posts: 4
Rank:


Level: Member

Country: dk
Location:
Occupation:
Age:
In-game name:

 
#3 Posted at 2017-11-08 02:04        
     
# aliascartoons : Should work if you run the script from init.sqf. Otherwise you need to broadcast it using remoteexec, tho when you do this you have to make sure the script runs only for players who didn't saw the intro already, see the wiki for remoteexec' parameters or use a variable check.
The only thing i would add is a line at the beginning of the script just to avoid the script to run on server side, not that would have an effect but is better to avoid running scripts where aren't needed:
if {!hasinterface} exitwith {};
You also have to think if you want every player to see the intro if JIPs or respawns. JIPing in the middle of the action and being forced to watch the intro maybe isn't something you'd want.

Did you try my intro or movie maker script?
http://www.armaholic.com/page.php?id=30731
http://steamcommunity.com/sharedfiles/filedetails/?id=725091897 - this one i don't remember if i've updated it on Armaholic yet, so is better you pick it up from STEAM. I have plans to do a small update on it anyways.

Problem is, it's already in the Init but it's not executing it in multiplayer. Only in singleplayer.

And if they die, they fail the mission and load a save so no worries, it won't repeat :P But I'll d efinetly check out that script