fenixplayscz 16 Posted February 11, 2015 Share Posted February 11, 2015 Hi, i maked new GMLevel (GM_VIP) in char.cpp have if (GetGMLevel() == GM_VIP) { m_afAffectFlag.Set(AFF_VIP); } in affect.h on line 45 AFF_VIP, in instancebase.h have AFFECT_VIP = 45, in PythonCharacterModule.cpp have PyModule_AddIntConstant(poModule, "AFFECT_VIP", CInstanceBase::AFFECT_VIP); in playersettingmodule.py have chrmgr.RegisterEffect(chrmgr.EFFECT_AFFECT+45, "Bip01", localeInfo.FN_VIP_MARK) and in game i didn't see my Vip logo on my hat.. where i have error? .. Link to comment Share on other sites More sharing options...
Ken 904 Posted February 11, 2015 Share Posted February 11, 2015 char szQuery[512]; snprintf(szQuery,sizeof(szQuery),"SELECT isvip FROM player.player WHERE id = %u",GetPlayerID()) std::auto_ptr<SQLMsg> pMsg(DBManager::instance().DirectQuery(szQuery)); if(pMsg.get() && pMsg->Get()->uiNumRows > 0) { MYSQL_ROW row = mysql_fetch_row(pMsg->Get()->pSQLResult); BYTE temp = 0; str_to_number(temp,row[0]); bool isVip = temp ? true : false; if(isVip) m_afAffectFlag.Set(AFF_VIP); } Check player is vip or not. Kind Regards Ken ~ TA Do not be sorry, be better. Link to comment Share on other sites More sharing options...
fenixplayscz 16 Posted February 11, 2015 Author Share Posted February 11, 2015 i have this if (!test_server) { if (GetGMLevel() > GM_LOW_WIZARD) { m_afAffectFlag.Set(AFF_YMIR); m_bPKMode = PK_MODE_PROTECT; } if (GetGMLevel() == GM_VIP) { m_afAffectFlag.Set(AFF_VIP); } } if player have GMLevel GM_VIP in gmlist game set AFF_VIP if i change AFF_VIP to AFF_YMIR and i'm VIP i see GM logo on my had.. Link to comment Share on other sites More sharing options...
pbuzz 31 Posted February 12, 2015 Share Posted February 12, 2015 you need to add that affect in uiaffectshower.py too Link to comment Share on other sites More sharing options...
fenixplayscz 16 Posted February 12, 2015 Author Share Posted February 12, 2015 where in uiaffectshower ? Link to comment Share on other sites More sharing options...
Former Staff flygun 304 Posted February 12, 2015 Former Staff Share Posted February 12, 2015 did you add GM_VIP in database table ?? Link to comment Share on other sites More sharing options...
fenixplayscz 16 Posted February 12, 2015 Author Share Posted February 12, 2015 yea all work with GM_VIP GM_VIP Command Too only logo not.. Link to comment Share on other sites More sharing options...
Premium Necro 78 Posted July 5, 2015 Premium Share Posted July 5, 2015 Have you already solved this? Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now