Skip to content

Commit

Permalink
fix fruitspace gdps comments crash
Browse files Browse the repository at this point in the history
  • Loading branch information
Cvolton committed Oct 1, 2024
1 parent 67925c7 commit 32259b6
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/CommentCell.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,10 @@ using namespace geode::node_ids;
auto winSize = CCDirector::sharedDirector()->getWinSize();

bool smallCommentsMode = this->m_height == 36; //this is how robtop does the check
bool usernameNotInMenu = !m_comment->m_userScore || !m_comment->m_userScore->m_accountID || m_accountComment || m_comment->m_hasLevelID;
bool usernameNotInMenu = m_comment->m_accountID <= 0 || m_accountComment || m_comment->m_hasLevelID;

//there is a chance m_comment->m_accountID is not set properly before loadFromComment
//but this is fixed inside loadFromComment itself, so that case is also handled

if(!smallCommentsMode) getChildOfType<CCScale9Sprite>(m_mainLayer, 0)->setID("background");

Expand Down

0 comments on commit 32259b6

Please sign in to comment.