Jump to content

Ikarus_

Developer
  • Posts

    402
  • Joined

  • Last visited

  • Days Won

    20
  • Feedback

    0%

Everything posted by Ikarus_

  1. VERY BIG DISCLAIMER: I m going to show you where the level delta is applied and how they made the constants, but they are used for all monsters, and not only for Stones. long answer: short answer: Conclusions: The influence of difference of level on dropping is exactly how you described. If my level is lower than the level of the monster/stone i get a drop bonus. if my level is equal to the level of the monster/stone i don't get a bonus and neither a malus. if my level is higher than level of the monster i get a malus
  2. Post here the .msa files used for the buggy skill. You can find them in playersettingmodule.py, around def __LoadGameWarriorEx .msa files can cause this, the reason is here: At least one Motion Event must be Type 4 for skills.
  3. You never bought from me, and you never worked with me. I prefer my customers to recommend me, not those who buy from my resellers. "Go to turkish" means go to the (turkish) reseller who sold you my shop
  4. I usually prefer to put the 3th part libraries on extern folder, but you can move it whenever you want. The important thing is to change the -I and -L directives with your directories. An example would be: #Mysql Dynamic LIBDIR += -L../../../extern/lib/mysql INCDIR += -I../../../extern/include/mysql LIBS += -lmysqlclient #Mysql Static INCDIR += -I../../../extern/include/mysql LIBS += ../../../extern/lib/mysql/libmysqlclient.a the first three lines are for a dynamic linking (it might prefer to link using libmysqlclient.so rather than libmysqlclient.a where both are available) the second two lines are for a static linking (where we are forcing it to use libmysqlclient.a) You can choice the way you prefer.
  5. i ll send you my include and lib folders for mysql80, they are for freebsd 11.3 only (32 bit obv) give me a moment to make the zip You can't use a lib and an include which are from differents version of mysql... you will get runtime errors (segmentation fault)
  6. You should put it in your extern/lib. I don't think you will find it in your machine x64, you need the 32bit one. What version of freebsd are u using? pkg.freebsd.org may help you to find it easly
  7. Are you compiling on a i386 machine? or an amd64? Amd64 machines will install you the lib built in 64bit which are incompatible with your game and db executables (which you are building in 32bit). Here you changed the -I and -L paths you are adding to LIBDIR and INCDIR, but can u find the lib in the directory you moved to?
  8. Uhm, yep, nullptr is not declared means you are not using c++11(+) and pkMsg is of non-class type SQLMsg* means you are using .reset on a raw pointer (and .reset is not needed even for smart ptr). You solved differently but maybe someone is interested in knowing why errors are received when they are received, as well as knowing how to fix it. No it is correct. std::unique_ptr<SQLMsg> will delete the memory from heap when its destructor is called. smart pointers have the overload of the operator -> and this help to use them as classic (raw) pointers. (e.g. where you used Msg->Get())
  9. please test it and report here the result. I'v not the time to test it for you. into the function void CHARACTER::AutoRecoveryItemProcess(const EAffectTypes type) search for if (avail > amount) { const int pct_of_used = amount_of_used * 100 / amount_of_full; const int pct_of_will_used = (amount_of_used + amount) * 100 / amount_of_full; bool bLog = false; if ((pct_of_will_used / 10) - (pct_of_used / 10) >= 1) bLog = true; pItem->SetSocket(idx_of_amount_of_used, amount_of_used + amount, bLog); } else { amount = avail; ITEM_MANAGER::instance().RemoveItem( pItem ); } replace it with: if (avail > amount) { const int pct_of_used = amount_of_used * 100 / amount_of_full; const int pct_of_will_used = (amount_of_used + amount) * 100 / amount_of_full; bool bLog = false; if ((pct_of_will_used / 10) - (pct_of_used / 10) >= 1) bLog = true; pItem->SetSocket(idx_of_amount_of_used, amount_of_used + amount, bLog); } else { amount = avail; if(pItem->GetCount() <= 1) ITEM_MANAGER::instance().RemoveItem( pItem ); else { pItem->SetCount(pItem->GetCount() - 1); pItem->SetSocket(1, 0); } }
  10. you pasted all wrong, i suggest you to remove the system and install it again once
  11. nullptr is defined since c++11 and i guess you are using reset on a raw pointer (the reset wasn't really needed btw)
  12. I think you are trying to read a stripped file. When game and db are linked they got all debug information used from gdb to read where is it crashing. The process called stripping remove the debug symbols from the executable (and so reduce its size). Unfortunately doesn't give any information try to read a db.core using a stripped db file. You have to find the unstripped file and to read its symbol table. You might have a "-s" flag to your linking commands in your makefile that strip the output file automatically.
  13. double AttBonusMin = static_cast<double>(pkItemAbsorbed->alValues[3] + pkItemAbsorbed->alValues[5]); AttBonusMin *= acceItem->GetSocket(ACCE_ABSORPTION_SOCKET); AttBonusMin /= 100; AttBonusMin += 0.5; //todebug if(ch->IsPhase(PHASE_GAME)) ch->ChatPacket(CHAT_TYPE_INFO, "Going to add to your attack : min(%0.2f) max(%0.2f) ", AttBonusMin, AttBonusMax); *pdamMax += static_cast<int>(AttBonusMax); *pdamMin += static_cast<int>(AttBonusMin); They are just rounded to integer (throught static_cast<int>) after the chat packet, that's why you are getting them as float in your chat. but the way you may add more chat packets in this function to check step by step how it is calculating the values
  14. In my code i ve used the identical formula client-side and server-side, so the result values are equal. Also in python the formula is identical, so why are u trying to change the formula? Also you can't define what is a 'normal round' and what isn't. for example a number like 15.5 can be consider in many cases as 15 and in other cases as 16. Doesn't exists a standard to apply in this case, that's why we have to add a + 0.5 every where, in order to round always to the upper integer number, both python and c++. without the +0.5 we may find different values on python rouding and on c++ rounding.
  15. check how it is calculated and you will know why. I ve just used the identical formula on c++ (serverside and clientside) and in python so all values now should be aligned.
  16. I've updated the code at the first message about void CPythonPlayer::__UpdateBattleStatus() copy it again from there and let me know. I think i ve solved both the problem you reported
  17. can i see your Status board (aka character window) while wearing the sash and without sash?
  18. Ok so the bug is just a visual bug. You have to wear a sash with att min and max and to read the client syserr.txt Let's debug it. (look at //todebug comment) void CPythonPlayer::__UpdateBattleStatus() { m_playerStatus.SetPoint(POINT_NONE, 0); m_playerStatus.SetPoint(POINT_EVADE_RATE, __GetEvadeRate()); m_playerStatus.SetPoint(POINT_HIT_RATE, __GetHitRate()); m_playerStatus.SetPoint(POINT_MIN_WEP, m_dwWeaponMinPower+m_dwWeaponAddPower); m_playerStatus.SetPoint(POINT_MAX_WEP, m_dwWeaponMaxPower+m_dwWeaponAddPower); m_playerStatus.SetPoint(POINT_MIN_MAGIC_WEP, m_dwWeaponMinMagicPower+m_dwWeaponAddPower); m_playerStatus.SetPoint(POINT_MAX_MAGIC_WEP, m_dwWeaponMaxMagicPower+m_dwWeaponAddPower); m_playerStatus.SetPoint(POINT_MIN_ATK, __GetTotalAtk(m_dwWeaponMinPower, m_dwWeaponAddPower)); m_playerStatus.SetPoint(POINT_MAX_ATK, __GetTotalAtk(m_dwWeaponMaxPower, m_dwWeaponAddPower)); #ifdef ENABLE_ACCE_SYSTEM //change it with your sash define auto ItemData = GetItemData({INVENTORY, c_Costume_Slot_Acce}); if (ItemData) { auto AbsorbedVnum = ItemData->alSockets[1]; if (AbsorbedVnum != 0 && CItemManager::Instance().SelectItemData(AbsorbedVnum)) { auto SelectedItemData = CItemManager::Instance().GetSelectedItemDataPointer(); if (SelectedItemData->GetType() == CItemData::ITEM_TYPE_WEAPON) { auto oldMinWep = m_playerStatus.GetPoint(POINT_MIN_WEP); auto oldMaxWep = m_playerStatus.GetPoint(POINT_MAX_WEP); auto oldMinMag = m_playerStatus.GetPoint(POINT_MIN_MAGIC_WEP); auto oldMaxMag = m_playerStatus.GetPoint(POINT_MAX_MAGIC_WEP); double sashAbsorbPerc = static_cast<double>(ItemData->alSockets[0]); auto sashMinWep = static_cast<double>(SelectedItemData->GetValue(3) + SelectedItemData->GetValue(5)) * (sashAbsorbPerc/100.0); auto sashMaxWep = static_cast<double>(SelectedItemData->GetValue(4) + SelectedItemData->GetValue(5)) * (sashAbsorbPerc/100.0); auto sashMinMag = static_cast<double>(SelectedItemData->GetValue(1) + SelectedItemData->GetValue(5)) * (sashAbsorbPerc/100.0); auto sashMaxMag = static_cast<double>(SelectedItemData->GetValue(2) + SelectedItemData->GetValue(5)) * (sashAbsorbPerc/100.0); //todebug TraceError("Going to add to your points : wep(min %f max %f) mag(min %f max%f)", sashMinWep, sashMaxWep, sashMinMag, sashMaxMag); m_playerStatus.SetPoint(POINT_MIN_WEP, oldMinWep + sashMinWep); m_playerStatus.SetPoint(POINT_MAX_WEP, oldMaxWep + sashMaxWep); m_playerStatus.SetPoint(POINT_MIN_MAGIC_WEP, oldMinMag + sashMinMag); m_playerStatus.SetPoint(POINT_MAX_MAGIC_WEP, oldMaxMag + sashMaxMag); } } } #endif } We should replace the if statement with this: if (SelectedItemData->GetType() == CItemData::ITEM_TYPE_WEAPON || (SelectedItemData->GetType() == CItemData::ITEM_TYPE_COSTUME && SelectedItemData->GetSubType() == CItemData::COSTUME_WEAPON))
  19. I ve confused you i think. here the complete ifstatement if(ch->GetDesc()->IsPhase(PHASE_GAME))
  20. Let's debug it one by one. At first, the hit damage adjustments. //todebug help you to find where i ve added debug #ifdef ENABLE_ACCE_SYSTEM //replace it with your define for sash static void ApplyAcceAttackValue(LPITEM pkItem, int* pdamMin, int* pdamMax) { LPCHARACTER ch = pkItem ? pkItem->GetOwner() : NULL; if (!ch) return; LPITEM acceItem = ch->GetWear(WEAR_COSTUME_ACCE); if (!acceItem) return; TItemTable* pkItemAbsorbed = ITEM_MANAGER::instance().GetTable(acceItem->GetSocket(ACCE_ABSORBED_SOCKET)); if (!pkItemAbsorbed) return; if (pkItemAbsorbed->bType != ITEM_WEAPON) return; double AttBonusMax = static_cast<double>(pkItemAbsorbed->alValues[4] + pkItemAbsorbed->alValues[5]); AttBonusMax *= acceItem->GetSocket(ACCE_ABSORPTION_SOCKET); AttBonusMax /= 100; AttBonusMax += 0.5; double AttBonusMin = static_cast<double>(pkItemAbsorbed->alValues[3] + pkItemAbsorbed->alValues[5]); AttBonusMin *= acceItem->GetSocket(ACCE_ABSORPTION_SOCKET); AttBonusMin /= 100; AttBonusMin += 0.5; //todebug if(ch->IsPhase(PHASE_GAME)) ch->ChatPacket(CHAT_TYPE_INFO, "Going to add to your attack : min(%0.2f) max(%0.2f) ", AttBonusMin, AttBonusMax); *pdamMax += static_cast<int>(AttBonusMax); *pdamMin += static_cast<int>(AttBonusMin); } You may need to add #include "desc.h" at the beginning of the file if you got errors on IsPhase line In order to debug the code you need to use a sash with attack min and max as bonuses and to hit a mob
  21. Can you please show me your void CPythonPlayer::__UpdateBattleStatus() Can you please try to hit a mob with and without the sash to check if server-side the bonus are applied? And last question, can you tell me if you changed the define with your one?
×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.