Jump to content

Recommended Posts

  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

I haven't modified anything here:

 

Spoiler

void CHARACTER::MainCharacterPacket()
{
    const unsigned mapIndex = GetMapIndex();
    const BGMInfo& bgmInfo = CHARACTER_GetBGMInfo(mapIndex);

    // SUPPORT_BGM
    if (!bgmInfo.name.empty())
    {
        if (CHARACTER_IsBGMVolumeEnable())
        {
            sys_log(1, "bgm_info.play_bgm_vol(%d, name='%s', vol=%f)", mapIndex, bgmInfo.name.c_str(), bgmInfo.vol);
            TPacketGCMainCharacter4_BGM_VOL mainChrPacket;
            mainChrPacket.header = HEADER_GC_MAIN_CHARACTER4_BGM_VOL;
            mainChrPacket.dwVID = m_vid;
            mainChrPacket.wRaceNum = GetRaceNum();
            mainChrPacket.lx = GetX();
            mainChrPacket.ly = GetY();
            mainChrPacket.lz = GetZ();
            mainChrPacket.empire = GetDesc()->GetEmpire();  ------------------------------> 1583
            mainChrPacket.skill_group = GetSkillGroup();
            strlcpy(mainChrPacket.szChrName, GetName(), sizeof(mainChrPacket.szChrName)); -----------------------> 1585

            mainChrPacket.fBGMVol = bgmInfo.vol;
            strlcpy(mainChrPacket.szBGMName, bgmInfo.name.c_str(), sizeof(mainChrPacket.szBGMName));
            GetDesc()->Packet(&mainChrPacket, sizeof(TPacketGCMainCharacter4_BGM_VOL));
        }
        else
        {
            sys_log(1, "bgm_info.play(%d, '%s')", mapIndex, bgmInfo.name.c_str());
            TPacketGCMainCharacter3_BGM mainChrPacket;
            mainChrPacket.header = HEADER_GC_MAIN_CHARACTER3_BGM;
            mainChrPacket.dwVID = m_vid;
            mainChrPacket.wRaceNum = GetRaceNum();
            mainChrPacket.lx = GetX();
            mainChrPacket.ly = GetY();
            mainChrPacket.lz = GetZ();
            mainChrPacket.empire = GetDesc()->GetEmpire();
            mainChrPacket.skill_group = GetSkillGroup();
            strlcpy(mainChrPacket.szChrName, GetName(), sizeof(mainChrPacket.szChrName));
            strlcpy(mainChrPacket.szBGMName, bgmInfo.name.c_str(), sizeof(mainChrPacket.szBGMName));
            GetDesc()->Packet(&mainChrPacket, sizeof(TPacketGCMainCharacter3_BGM));
        }
        //if (m_stMobile.length())
        //        ChatPacket(CHAT_TYPE_COMMAND, "sms");
    }
    // END_OF_SUPPORT_BGM
    else
    {
        sys_log(0, "bgm_info.play(%d, DEFAULT_BGM_NAME)", mapIndex);

        TPacketGCMainCharacter pack;
        pack.header = HEADER_GC_MAIN_CHARACTER;
        pack.dwVID = m_vid;
        pack.wRaceNum = GetRaceNum();
        pack.lx = GetX();
        pack.ly = GetY();
        pack.lz = GetZ();
        pack.empire = GetDesc()->GetEmpire();
        pack.skill_group = GetSkillGroup();
        strlcpy(pack.szName, GetName(), sizeof(pack.szName));
        GetDesc()->Packet(&pack, sizeof(TPacketGCMainCharacter));

        if (m_stMobile.length())
            ChatPacket(CHAT_TYPE_COMMAND, "sms");
    }
}

This system i tried to add.

This is the hidden content, please

 

This is the hidden content, please

Link to comment
https://metin2.dev/topic/18266-error-source/#findComment-99799
Share on other sites

Don't use any images from : imgur, turkmmop, freakgamers, inforge, hizliresim... Or your content will be deleted without notice...
Use : https://metin2.download/media/add/

Please use https://metin2.download/ when uploading files smaller than 100MB, otherwise the approval will take longer due to manual upload.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.