Works! Made some small changes, but it finally works.
THANKS!
BIS_endText =
{
private["_blocks","_block","_blockCount","_blockNr","_blockArray","_blockText","_blockTextF","_blockTextF_","_blockFormat","_formats","_inputData","_processedTextF","_char","_cursorBlinks"];
_blockCount = count _this;
_invisCursor = "<t color ='#00000000' shadow = '0'>_</t>";
// Get screen center position using safezone
private _safeZoneX = (safezoneX + safezoneW / 2);
private _safeZoneY = (safezoneY + safezoneH / 2);
// Process the input data
_blocks = [];
_formats = [];
{
_inputData = _x;
_block = [_inputData, 0, "", [""]] call BIS_fnc_param;
_format = [_inputData, 1, "<t align = 'center' shadow='1' size='2.0'>%1</t><br/>", [""]] call BIS_fnc_param;
// Convert strings into array of chars
_blockArray = toArray _block;
{
_blockArray set [_forEachIndex, toString [_x]]
} forEach _blockArray;
_blocks = _blocks + [_blockArray];
_formats = _formats + [_format];
} forEach _this;
// Do the printing
_processedTextF = "";
{
_blockArray = _x;
_blockNr = _forEachIndex;
_blockFormat = _formats select _blockNr;
_blockText = "";
_blockTextF = "";
_blockTextF_ = "";
{
_char = _x;
_blockText = _blockText + _char;
_blockTextF = format[_blockFormat, _blockText + _invisCursor];
_blockTextF_ = format[_blockFormat, _blockText + "_"];
// Print the output at the center of the screen using safezone
[(_processedTextF + _blockTextF_), 0, _safeZoneY, 35, 0, 0, 90] spawn BIS_fnc_dynamicText;
playSoundUI ["a3\missions_f\data\sounds\click.wss", 0.25];
sleep 0.08;
[(_processedTextF + _blockTextF), 0, _safeZoneY, 35, 0, 0, 90] spawn BIS_fnc_dynamicText;
sleep 0.02;
} forEach _blockArray;
if (_blockNr + 1 < _blockCount) then
{
_cursorBlinks = 5;
}
else
{
_cursorBlinks = 15;
};
for "_i" from 1 to _cursorBlinks do
{
[_processedTextF + _blockTextF_, 0, _safeZoneY, 35, 0, 0, 90] spawn BIS_fnc_dynamicText;
sleep 0.08;
[_processedTextF + _blockTextF, 0, _safeZoneY, 35, 0, 0, 90] spawn BIS_fnc_dynamicText;
sleep 0.02;
};
// Store finished block
_processedTextF = _processedTextF + _blockTextF;
// Do not clear the screen, to keep the text visible
//["", _safeZoneX, _safeZoneY, 35, 0, 0, 90] spawn BIS_fnc_dynamicText;
} forEach _blocks;
};
// Example usage
[
["MISSION COMPLETE","<t align='center' shadow='1' size='2.0'>%1</t><br/>"]
] spawn BIS_endText;
private _playerSide = side player;
if (_playerSide == Winner) then {
// Display win message with typewriter effect
[
[WinMessage, "<t align='center' shadow='1' size='1.0'>%1</t><br/>"]
] spawn BIS_endText;
playMusic ["LeadTrack01_F_Bootcamp", 132];
0 fadeMusic 2;
} else {
// Display lose message with typewriter effect
[
[LoseMessage, "<t align='center' shadow='1' size='1.0'>%1</t><br/>"]
] spawn BIS_endText;
playMusic "BackgroundTrack03_F_EPC";
0 fadeMusic 2;
};
_start = diag_tickTime;
[0, 1, true, false] call NUP_fnc_cinematicBorder;
// Get the position of the NUP_endMissionCamera object
private _cameraPos = getPos NUP_endMissionCamera;
// Calculate starting and ending positions for the camera
private _startPos = [
(_cameraPos select 0), // Same X position
(_cameraPos select 1), // Same Y position
(_cameraPos select 2) + 10 // 10 meters above
];
private _endPos = [
(_cameraPos select 0), // Same X position
(_cameraPos select 1), // Same Y position
(_cameraPos select 2) + 50 // 50 meters above (40 meters up during 30 seconds)
];
// Create the camera
private _camera = "camera" camCreate _startPos;
_camera cameraEffect ["internal", "back"];
_camera camSetTarget NUP_endMissionCamera;
_camera camSetFOV 0.5;
_camera camCommit 0;
// Move the camera over 30 seconds
_camera camSetPos _endPos;
_camera camCommit 30;
waitUntil { diag_tickTime - _start >= 25 };
5 fadeMusic 0;
// Wait until the camera has finished its trajectory
waitUntil { camCommitted _camera };
// Terminate the camera effect and destroy the camera
//_camera cameraEffect ["terminate", "back"];
//camDestroy _camera;
// Force all players back to the lobby after the outro
endMission "end";
Edit: A separate script appears to not be necessary.
By storing the above in a local variable in the actual endMission function, (_NUP_endSequence), I can then spawn that via remoteExec. So far, seems to work!
"_NUP_endSequence" remoteExec ["spawn", 0]; // remoteExec to every player locally
They may see about trying that however I will mention that the current settings in their basic.cfg were recommended by the server provider (armahosts) from someone there who said they frequently run ~100 player operations.