Modifying the JournalQuestMenu
Introduction
For my mod Dark Beauclair, I had the problem that I was required to set the world of my quests to AN_Undefined instead of AN_DarkBeauclair in order for the quest map pins to work correctly. Therefore, I wanted to change the region display directly in the JournalQuestMenu to show the correct region.
Wrapping the Menu
By wrapping the generateFlashObjectForQuest and GetQuestIconByType methods, I was able to change the region displayed for the quest, called secondLabel, without risking merge conflicts with other mods.
Note that if you want to use this yourself, you have to change the key panel_journal_filters_area_dark_beauclair to something like panel_journal_filters_area_<modname> and add it with a value to your String Database.
I agree that the OR-based check of the Unique Script Tag for the quests is not the prettiest solution, but I chose it instead of using something like Type, Content Type, World, or Title, because it is the easiest and safest way to identify your own quests without modifying the attributes of other quests you did not intend to modify.
Code
@wrapMethod(CR4JournalQuestMenu) function generateFlashObjectForQuest( targetQuest : CJournalQuest, optional initSelection : bool ) : CScriptedFlashObject { var l_questsDataFlashObject : CScriptedFlashObject; var t_Tag : name; t_Tag = targetQuest.GetUniqueScriptTag(); l_questsDataFlashObject = wrappedMethod(targetQuest, initSelection); // Getting the already created flashobject by the wrapped method if ( t_Tag == 'db_q_mq_an_impenetrable_threshold' || t_Tag == 'db_q_mq_palace_of_nightmare' || t_Tag == 'db_q_mq_find_the_sunstone' || t_Tag == 'db_q_mq_unsuccessful_investigations' || t_Tag == 'db_q_mq_collect_artifacts' || t_Tag == 'db_q_mq_delayed_funeral' || t_Tag == 'db_q_mq_crones_hunt' || t_Tag == 'db_q_mq_nightmare_ritual' || t_Tag == 'db_q_sq_the_lost_path' || t_Tag == 'db_q_sq_the_ruins_of_byrgenwatch' || t_Tag == 'db_q_sq_the_hidden_garden' || t_Tag == 'db_q_sq_mystery_of_the_murder' || t_Tag == 'db_q_sq_echo_of_prisoners' || t_Tag == 'db_q_mh_monster_of_the_lake' || t_Tag == 'db_q_mh_blood_in_the_mist' || t_Tag == 'db_q_th_riddle_of_the_lost_library' || t_Tag == 'db_q_th_fallen_prince') { l_questsDataFlashObject.SetMemberFlashInt( "epIndex", 57347384 ); //Choose an unique index here to avoid any collisions l_questsDataFlashObject.SetMemberFlashString( "secondLabel", GetLocStringByKeyExt('panel_journal_filters_area_dark_beauclair') ); // Changes the mapregion of the quest l_questsDataFlashObject.SetMemberFlashString( "iconPath", GetQuestIconByType( targetQuest.GetType(), 57347384 ) ); // Changes the icon (path) of the quest to make it more distinct with the vanilla quests } return l_questsDataFlashObject; } @wrapMethod(CR4JournalQuestMenu) function GetQuestIconByType( type : eQuestType, optional epIndex : int ) : string { var retStr : string; retStr = "icons/quests/"; if ( epIndex == 57347384) { // Here the check for the custom index switch(type) { case Story : case Chapter : case Side : retStr += "db_quest.png"; // the icons acually placed here (via DLC mod mounting): dlc\dark_beauclair\data\gameplay\gui_new\icons\quests\ (take a look here for information about mounters: https://cdprojektred.atlassian.net/wiki/spaces/W3REDkit/pages/6328346/DLC+Mods#DLC-Mounters) break; case MonsterHunt : retStr += "db_monsterhunt.png"; break; case TreasureHunt : retStr += "db_treasurehunt.png"; break; } } else { retStr = wrappedMethod(type, epIndex); } return retStr; }
The final look

Note: I tried changing the banner of the quest as well but did not archive anything there :
@wrapMethod(CR4JournalQuestMenu) function OnConfigUI() { wrappedMethod(); m_fxSetExpansionTexture.InvokeSelfTwoArgs( FlashArgInt(57347384), FlashArgString("img://icons/quests/ep_logos/dark_beauclair_logo_all.png") ); //Trying to make the own banner work } @wrapMethod(CR4JournalQuestMenu) function GetEpTextureName( epIndex : int ) : string { //Trying to add a custom banner to the quest background by chaning the path based on the epIndex var path : string; //GetWitcherPlayer().DisplayHudMessage("Got called with intex: " + epIndex); if (epIndex == 57347384) { // Check somehow not working, if i check for epIndex == 1 or epIndex == 2 it overrides the banner from HoS or B&W path = "img://icons/quests/ep_logos/dark_beauclair_logo_all.png"; //path = "img://icons/quests/ep_logos/ep1_logo_en.png"; } else { path = wrappedMethod(epIndex); } return path; }