Jump to content

Intro Music with Welcome Messages for 1061


Bricktop

Recommended Posts

*** I claim no credit for this code - Credit goes to blurgaming and all the "welcome messages and intro music" script writers out there.

- I just want to share what I did to make it work on 1061 since the init.sqf is different now. 

=======================================

1) Create your introSong.ogg file and place it in the mission folder (same location as init.sqf)

I use this - https://audio.online-convert.com/convert-to-ogg

2) Create a file named playerspawn.sqf with this code and place it in the mission folder (same location as init.sqf) 

Spoiler

// Written by blur <3
//you can edit the text here to say anything you want.
//you can change the color of the text by changing color='#ff0000
//you can change the font type by changing font='Zeppelin33'  
//you can change the text size by changing size='2.25'  
waitUntil{!isNull (findDisplay 46)};  
_textString1 = "<t size='2.25' font='Zeppelin33' color='#ffff00' align='center'>Welcome to ManUp PvP Powered by ManUp Survival inc</t>";  
_textString2 = "<t size='2.25' font='Zeppelin33' color='#ffff00' align='center'>THE SERVER RULES ARE ON YOUR MOUSE WHEEL</t>";  
_textString3 = "<t size='2.25' font='Zeppelin33' color='#ffff00' align='center'>MOUSE WHEEL OPTIONS [ADMIN] [DEPLOY] [RULES] [DEATH]</t>";  
_textString4 = "<t size='2.25' font='Zeppelin33' color='#ffff00' align='center'>RIGHT CLICK OPTIONS [GPS]   [BINOS] [RFINDER] [MAP]   [KNIFE]</t>";
_textString5 = "<t size='2.25' font='Zeppelin33' color='#ffff00' align='center'>:I-NOTE-I: MAINTAIN YOUR PLOTPOLE ONCE EVERY WEEK</t>";
_textString6 = ""; //Leave this blank


if ( alive player ) then {
//if ( alive player && ! isTouchingGround player ) then {  //this might work to make it so the music only plays when you are haloing in.
      sleep 15;
    playsound "introSong";
    hint parseText (_textString1); sleep 20;
    hint parseText (_textString5);
    hint parseText (_textString2); sleep 20;
    hint parseText (_textString5);
    hint parseText (_textString3); sleep 20;
    hint parseText (_textString5);
    hint parseText (_textString4); sleep 20;
    hint parseText (_textString5);
    hint parseText (_textString5); sleep 20;
    hint parseText (_textString5);

};

Screenshot of messages - https://imgur.com/a/Xk5Aw

3) Add the code in red to the class CfgSounds section in the description.ext located in your mission folder

- it should look something like this 

Spoiler

class CfgSounds
{
    sounds[] =
    {
        Radio_Message_Sound
    };
    class Radio_Message_Sound
    {
        name = "Radio_Message_Sound";
        sound[] = {scripts\radio\radio.ogg,0.4,1};
        titles[] = {};
    };
    class Brief_Open_Sound
    {
        name = "Brief_Open_Sound";
        sound[] = {addons\mbc\brief_open.ogg,0.4,1};
        titles[] = {};
    };
    class introSong
    {
    name="introSong";
    sound[]={introSong.ogg,0.9,1};
    titles[] = {};
    };

};

 

4) Add the code in red to your init.sqf

Spoiler

if (!isDedicated) then {
    enableSaving [false, false];
    startLoadingScreen ["","RscDisplayLoadCustom"];
    progressLoadingScreen 0;
    [] execVM "scripts\service_point\service_point.sqf";
    dayz_loadScreenMsg = localize 'str_login_missionFile';
    _id = player addEventHandler ["Respawn", {_id = [] spawn player_death; _nul = [] execVM "playerspawn.sqf";}];
    progress_monitor = [] execVM "\z\addons\dayz_code\system\progress_monitor.sqf";
    _nul = [] execVM "playerspawn.sqf";
    0 cutText ['','BLACK',0];
    0 fadeSound 0;
    0 fadeMusic 0;

All done! 

*** Don't forget to edit the playerspawn.sqf unless you want to advertise my server :)

Link to comment
Share on other sites

  • 6 months later...

@Bricktop

I have tried to install this script exactly as per instructions, and I get this error:

Spoiler

17:57:53 Error in expression <ize 'str_login_missionFile'; _id = player addEventHandler ["Respawn">

17:57:53 Error position: <r addEventHandler ["Respawn">

17:57:53 Error Missing ;

17:57:53 File mpmissions\DayZ_Epoch_13.Tavi\init.sqf, line 85

Any ideas?

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Advertisement
  • Discord

×
×
  • Create New...