Decompile fn_02846 (CCashEmotionAction_Register::Execute)
Batch #5586 by Yommy: 0 byte-identical, 1 confirmed by peer review. - fn_02846 CCashEmotionAction_Register::Execute: logic confirmed by peer review Peer-reviewed-by: ragnarok-clanker, willerthal, KWDev Accepted without human review: peers confirmed the logic ("same" ahead by at least 3, with 70% of the votes).
This commit is contained in:
parent
7ced568270
commit
33c8f8256f
1 changed files with 24 additions and 0 deletions
|
|
@ -339,6 +339,30 @@ bool CCashEmotionAction_Play::Execute(int packId, int emotionId) {
|
|||
}
|
||||
|
||||
// OFFSET: 0x00591F30
|
||||
// FUNCTION: fn_02846
|
||||
bool CCashEmotionAction_Register::Execute(int packId, int emotionId) {
|
||||
if (packId < 0 || emotionId < 0) {
|
||||
return false;
|
||||
}
|
||||
|
||||
const char* name = g_cashEmotionMgr->GetEmotionName(packId, emotionId);
|
||||
if (!name) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (auto* emotionWnd = reinterpret_cast<UIEmotionWnd*>(g_windowMgr.unknown_0380)) {
|
||||
emotionWnd->SetMacroText(name, -1);
|
||||
return true;
|
||||
}
|
||||
|
||||
ChatSuggestions* suggestions = g_chatSuggestions;
|
||||
if (suggestions && suggestions->input) {
|
||||
suggestions->input->SetText(name);
|
||||
suggestions->input->Slot39();
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
// OFFSET: 0x00591FB0
|
||||
// FUNCTION: fn_02847
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue