Skip to content

Commit

Permalink
-Help gen: Made sure trigger and action list properly update
Browse files Browse the repository at this point in the history
  • Loading branch information
mostlikely4r committed May 30, 2023
1 parent 5dfcbfa commit 968d17a
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions playerbot/PlayerbotHelpMgr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -434,7 +434,10 @@ void PlayerbotHelpMgr::GenerateTriggerHelp()

std::sort(trigLinks.begin(), trigLinks.end());

botHelpText["list:" + className + " trigger"].m_templateText = className + " triggers : \n" + makeList(trigLinks);

if (botHelpText["list:" + className + " trigger"].m_templateText != " triggers : \n" + makeList(trigLinks))
botHelpText["list:" + className + " trigger"].m_templateChanged = true;
botHelpText["list:" + className + " trigger"].m_templateText = className + " triggers : \n" + makeList(trigLinks);
}
}

Expand Down Expand Up @@ -553,7 +556,9 @@ void PlayerbotHelpMgr::GenerateActionHelp()

std::sort(actionLinks.begin(), actionLinks.end());

botHelpText["list:" + className + " action"].m_templateText = className + " actions : \n" + makeList(actionLinks);
if (botHelpText["list:" + className + " action"].m_templateText != " action : \n" + makeList(actionLinks))
botHelpText["list:" + className + " action"].m_templateChanged = true;
botHelpText["list:" + className + " action"].m_templateText = className + " action : \n" + makeList(actionLinks);
}
}

Expand Down

0 comments on commit 968d17a

Please sign in to comment.