Jump to content

Trukken

Inactive Member
  • Posts

    5
  • Joined

  • Last visited

  • Feedback

    0%

About Trukken

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

Trukken's Achievements

Contributor

Contributor (5/16)

  • First Post
  • Dedicated
  • One Year In
  • One Month Later
  • Week One Done

Recent Badges

1

Reputation

  1. Old topic, but this might solve your issue: Client src: UserInterface/PythonApplication.cpp //Search if (LocaleService_IsYMIR()) { char szEmpireTextConvFile[256]; for (DWORD dwEmpireID=1; dwEmpireID<=3; ++dwEmpireID) { sprintf(szEmpireTextConvFile, "%s/lang%d.cvt", localePath, dwEmpireID); if (!rkNetStream.LoadConvertTable(dwEmpireID, szEmpireTextConvFile)) { TraceError("LoadLocaleData - CPythonNetworkStream::LoadConvertTable(%d, %s) FAILURE", dwEmpireID, szEmpireTextConvFile); } } } //Add after PAY ATTENTION TO THE PATH, you might have it different char szGuildBuildingList[256] = { 0 }; snprintf(szGuildBuildingList, sizeof(szGuildBuildingList), "%s/texts/guildbuildinglist.txt", localePath); if (!CPythonLoading::Instance().LoadGuildBuilding(szGuildBuildingList)) Tracenf("LoadLocaleData - LoadGuildBuilding(%s) Error", szGuildBuildingList); If you are using Owsap's Loading performance module, make sure to call guild.GetGuildBuildingList() method.
  2. Looking back at it, it's actually garbage code. Do this instead: service.h #define ENABLE_BLOCK_RIDE_SPAM // < Block Do Ride Spam char.h // Search const CHARACTER_SET& GetChainLightingExcept() const { return m_setExceptChainLighting; } // Add after #ifdef ENABLE_BLOCK_RIDE_SPAM int m_iRideSpamBlockAfter; int m_iRideSpamTime; #endif cmd_general.cpp // Search, the curly bracket { might be on the same line! ACMD(do_ride) { // Add BEFORE #ifdef ENABLE_BLOCK_RIDE_SPAM /** * Determine wether the player is spamming do_ride */ bool isLimitedToMount(LPCHARACTER ch){ constexpr int timeoutSeconds = 5; if ((thecore_pulse() < (ch->m_iRideSpamTime + timeoutSeconds * 25))) { if (ch->m_iRideSpamBlockAfter < 6) { ch->m_iRideSpamBlockAfter++; return false; } return true; } ch->m_iRideSpamBlockAfter = 0; ch->m_iRideSpamTime = thecore_pulse(); return false; } #endif // Now go back to ACMD(do_ride) { // Add AFTER #ifdef ENABLE_BLOCK_RIDE_SPAM if (isLimitedToMount(ch)) { ch->ChatPacket(CHAT_TYPE_INFO, "WAIT 5 SECONDS"); return; } #endif Pros: - It actually works - Uses memory instead of DB - Won't get an integer overflow at Epochalypse
  3. Little late to the party, but here's my take. // Prevent user spam if used more than 6 times in a 5 second window const int mountSpam = ch->GetQuestFlag("mount.spam"); int mountSpamTimeout = ch->GetQuestFlag("mount.spam_timeout"); const long globalTime = get_global_time(); if (mountSpam >= 6 || mountSpamTimeout != 0) { if (mountSpamTimeout == 0) { ch->SetQuestFlag("mount.spam_timeout", globalTime); mountSpamTimeout = globalTime; } ch->SetQuestFlag("mount.spam", 0); if (globalTime < mountSpamTimeout + 5) { ch->ChatPacket(CHAT_TYPE_INFO, "WAIT 5 SECONDS"); return; } ch->SetQuestFlag("mount.spam_timeout", 0); } ch->SetQuestFlag("mount.spam", std::max(mountSpam + 1, 1)); Let me know if you have a better solution.
  4. Boss GROUPS (g) need at least 5-5 X and Y deviation. Otherwise the parser goes ape shit.
  5. Shogun was on the right track. However it is all client side, no need to modify anything server side or in the DB. Extract locale.eix or rrlocale.eix, search for skilldesc.txt look for flags and remove them from the desired skills. Shaman buffs IDs are (Dragon) 94-95-96 and (Heal) 109-110-111. Remove the | separator as well. If you want to be able to buff in the no attack circles, you also need to modify the Client exe. Look for UserInterface/PythonPlayerSkill.cpp } else { if (pkInstTarget->IsInSafe()) { PyCallClassMemberFunc(m_ppyGameWindow, "OnCannotUseSkill", Py_BuildValue("(is)", GetMainCharacterIndex(), "CANNOT_ATTACK_ENEMY_IN_SAFE_AREA")); return false; } Extend the if statement with an pSkillData->IsAttackSkill() call. } else { if (pkInstTarget->IsInSafe() && pSkillData->IsAttackSkill()) { PyCallClassMemberFunc(m_ppyGameWindow, "OnCannotUseSkill", Py_BuildValue("(is)", GetMainCharacterIndex(), "CANNOT_ATTACK_ENEMY_IN_SAFE_AREA")); return false; } You should be able to buff anyone to your desire afterwards.
×
×
  • 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.