diff --git a/Source/Client/Mode/CGameMode.h b/Source/Client/Mode/CGameMode.h index 162664677..cb2660617 100644 --- a/Source/Client/Mode/CGameMode.h +++ b/Source/Client/Mode/CGameMode.h @@ -730,7 +730,7 @@ public: void ReceiveItem1758List(const unsigned char* packet); void ReceiveOpenedVendingItemList(const unsigned char* packet); void ReceiveItem1748List(const unsigned char* packet); - void ReceiveActorStatusValue(std::uint32_t aid, int status, int amount, int option); + void ReceiveActorStatusValue(std::uint32_t aid, int status, std::int64_t amount); void ReceiveActorSkillResult(const unsigned char* packet); void UpdateSkillCooldown(std::uint16_t skill, std::uint32_t remaining, std::uint32_t duration); void LoadCooldownSnapshot(const void* packet); diff --git a/Source/Client/Mode/GameMode.cpp b/Source/Client/Mode/GameMode.cpp index 88ade24c2..493a04e8c 100644 --- a/Source/Client/Mode/GameMode.cpp +++ b/Source/Client/Mode/GameMode.cpp @@ -503,7 +503,7 @@ bool CGameMode::HasResurrectionItem() { // FUNCTION: fn_21287 void CGameMode::SendMousePointerState(int value) { if (this->mousePointer) { - this->mousePointer->SendMsg(nullptr, AM_HIDEMOUSE, 0, value, value >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->mousePointer->SendMsg(nullptr, AM_HIDEMOUSE, value, 0, 0, 0, 0, 0); } } @@ -2927,7 +2927,7 @@ int CGameMode::SendMsg(int event, int argument1, int argument2, int argument3, i std::strcat(text, " !! "); std::strcat(text, LookupMessage(MSI_LOVE_SKILL)); const int address = reinterpret_cast(text); - actor->SendMsg(nullptr, AM_CHAT, 0, address, address >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_CHAT, address, 0, 0, 0, 0, 0); return 0; } if (argument1 == WE_CALLPARTNER) { @@ -2939,7 +2939,7 @@ int CGameMode::SendMsg(int event, int argument1, int argument2, int argument3, i std::strcat(text, " !! "); std::strcat(text, skillName); const int address = reinterpret_cast(text); - actor->SendMsg(nullptr, AM_CHAT, 0, address, address >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_CHAT, address, 0, 0, 0, 0, 0); return 0; } if (argument1 == DC_SCREAM || argument1 == BA_FROSTJOKER || argument1 == ITEM_ENCHANTARMS || @@ -2949,7 +2949,7 @@ int CGameMode::SendMsg(int event, int argument1, int argument2, int argument3, i std::strcpy(skillName, CSkillInfo::DisplayName(*g_session.m_hotkeyScript, argument1)); std::strcat(skillName, " !!"); const int address = reinterpret_cast(skillName); - actor->SendMsg(nullptr, AM_CHAT, 0, address, address >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_CHAT, address, 0, 0, 0, 0, 0); return 0; } case MM_REQ_CHANGE_MEMBERPOS: { @@ -4452,7 +4452,7 @@ int CGameMode::SendMsg(int event, int argument1, int argument2, int argument3, i } case MM_CONTACTNPC: { if (this->scene->player != nullptr) { - this->scene->player->SendMsg(nullptr, AM_FREEZE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_FREEZE, 0, 0, 0, 0, 0, 0); } const auto* request = reinterpret_cast(argument1); if (request[1] == 0x2D) { @@ -4747,7 +4747,7 @@ std::uint64_t CGameMode::LaunchDummyEffect(const vector3d* position, int effectI CDummyEffectLauncher* launcher = new CDummyEffectLauncher; if (launcher != nullptr) { const int address = reinterpret_cast(position); - launcher->SendMsg(nullptr, AM_SETPOS, 0, address, address >> 31, effectId, effectId >> 31, lifeFrames, lifeFrames >> 31, value, value >> 31, 0, 0, 0, 0); + launcher->SendMsg(nullptr, AM_SETPOS, address, effectId, lifeFrames, value, 0, 0); this->scene->objects.push_back(launcher); return launcher->identity; } @@ -4773,12 +4773,12 @@ void CGameMode::RequestPlayerAction(int target, int argument) { switch (reinterpret_cast(this->skillUseType)) { case SUT_NOSKILL: - this->scene->player->SendMsg(nullptr, AM_PROCEEDATTACK, 0, target, 0, argument, argument >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_PROCEEDATTACK, static_cast(target), argument, 0, 0, 0, 0); break; case SUT_TO_CHARACTER: case SUT_TO_ALL: - this->scene->player->SendMsg(nullptr, AM_PROCEEDSKILL, 0, target, 0, value, value >> 31, 0, 0, 0, 0, 0, 0, 0, 0); - this->scene->player->SendMsg(nullptr, AM_SET_SKILL_USE_LEVEL, 0, this->skillUseLevel, this->skillUseLevel >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_PROCEEDSKILL, static_cast(target), value, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_SET_SKILL_USE_LEVEL, this->skillUseLevel, 0, 0, 0, 0, 0); break; } } @@ -4821,7 +4821,7 @@ void CGameMode::SendMousePointerPosition(float x, float y, int value) { position[0] = x; position[1] = y; const std::intptr_t address = reinterpret_cast(position); - this->mousePointer->SendMsg(nullptr, AM_SETPOSMOUSE, 0, address, address >> 31, value, value >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + this->mousePointer->SendMsg(nullptr, AM_SETPOSMOUSE, address, value, 0, 0, 0, 0); } // OFFSET: 0x00CED330 @@ -6527,7 +6527,7 @@ void CGameMode::ChangeZoneServer(std::string mapName, int x, int y, int ip, int this->noMove = 1; this->noMoveStartTick = timeGetTime(); - this->scene->player->SendMsg(nullptr, AM_FREEZE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_FREEZE, 0, 0, 0, 0, 0, 0); if (g_screenShakeDuration > 0) { g_screenShakeDuration = g_screenShakeMode == 2 ? 10001 : g_screenShakeDuration; } @@ -7173,7 +7173,7 @@ void CGameMode::PlayItemUseEffect(int itemId, std::uint32_t aid) { if (effectId > 0) { while (static_cast(actor)->HasId(effectId)) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, effectId, effectId >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, effectId, 0, 0, 0, 0, 0); } if (g_effectMgr->HasAllocator(effectId)) { g_effectMgr->Spawn(actor->render.accountId, effectId, vector3d{0.0f, 0.0f, 0.0f}, 0, -1, 0, 0); @@ -7184,7 +7184,7 @@ void CGameMode::PlayItemUseEffect(int itemId, std::uint32_t aid) { if (secondEffectId > 0) { while (static_cast(actor)->HasId(secondEffectId)) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, secondEffectId, secondEffectId >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, secondEffectId, 0, 0, 0, 0, 0); } if (g_effectMgr->HasAllocator(secondEffectId)) { g_effectMgr->Spawn(actor->render.accountId, secondEffectId, vector3d{0.0f, 0.0f, 0.0f}, 0, -1, 0, 0); @@ -7972,7 +7972,7 @@ void CGameMode::Initialize(const char* name) { } if (g_screenShakeMode == 2) { - this->scene->player->SendMsg(nullptr, AM_STATUS_CHANGE, 0, 0x22, 0, g_screenShakeDuration <= 10000 && g_screenShakeDuration != 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_STATUS_CHANGE, 0x22, g_screenShakeDuration <= 10000 && g_screenShakeDuration != 0, 0, 0, 0, 0); } if (g_session.GetOption(6) > 0) { @@ -8627,9 +8627,9 @@ int CGameMode::ProcessGroundClick(int result) { if (this->scene->player) { const int skill = this->skillId; - this->scene->player->SendMsg(nullptr, AM_PROCEEDGROUNDSKILL, 0, skill, skill >> 31, column, column >> 31, row, row >> 31, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_PROCEEDGROUNDSKILL, skill, column, row, 0, 0, 0); const int level = this->skillUseLevel; - this->scene->player->SendMsg(nullptr, AM_SET_SKILL_USE_LEVEL, 0, level, level >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_SET_SKILL_USE_LEVEL, level, 0, 0, 0, 0, 0); } } @@ -8684,7 +8684,7 @@ int CGameMode::ProcessGroundClick(int result) { g_windowMgr.UpdateNavigationList(); clickTick = timeGetTime(); if (HIBYTE(GetAsyncKeyState(VK_SHIFT)) || g_windowMgr.chatRoomWnd || this->scene->player->render.state == 6) { - this->scene->player->SendMsg(nullptr, AM_REQ_CHANGE_DIR, 0, column, column >> 31, row, row >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_REQ_CHANGE_DIR, column, row, 0, 0, 0, 0); return result; } @@ -8711,7 +8711,7 @@ int CGameMode::ProcessGroundClick(int result) { g_windowMgr.CloseWindow(WID_MENUWND); } if (this->scene->player) { - this->scene->player->SendMsg(nullptr, AM_REQ_MOVE, 0, column, column >> 31, row, row >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_REQ_MOVE, column, row, 0, 0, 0, 0); } return result; } @@ -8800,10 +8800,10 @@ void CGameMode::Update() { if (g_windowMgr.menuWnd != nullptr) { g_windowMgr.CloseWindow(WID_MENUWND); } - this->scene->player->SendMsg(nullptr, AM_REQ_MOVE, 0, x, x >> 31, y, y >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_REQ_MOVE, x, y, 0, 0, 0, 0); } } else { - this->scene->player->SendMsg(nullptr, AM_REQ_CHANGE_DIR, 0, x, x >> 31, y, y >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_REQ_CHANGE_DIR, x, y, 0, 0, 0, 0); } } } @@ -8971,7 +8971,7 @@ void CGameMode::ProcessInput() { if (g_mouse.buttons[0] == 3) { if (this->scene->player) { - this->scene->player->SendMsg(nullptr, AM_ATTACKCLICKUP, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_ATTACKCLICKUP, 0, 0, 0, 0, 0, 0); } this->SendMsg(MM_DROP, g_mouse.x, g_mouse.y, 0, 0); UIMenuWnd* menu = static_cast(g_windowMgr.menuWnd); @@ -10791,7 +10791,7 @@ int CGameMode::HandleActorPick(ActorPickInfo* pick, int result) { int column; int row; this->WorldCell(actor->render.position.x, actor->render.position.z, column, row); - this->scene->player->SendMsg(nullptr, AM_REQ_CHANGE_DIR, 0, column, column >> 31, row, row >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_REQ_CHANGE_DIR, column, row, 0, 0, 0, 0); if (g_windowMgr.HasPendingDialog() == true) { g_windowMgr.SendNotice(UIM_OPENCHATWND, 0, 0, 0, 0, 0); g_windowMgr.SendNotice(UIM_PUSHINTOCHATHISTORY, reinterpret_cast(LookupMessage(MSI_VIEW_CHANGE_EQUIPMENT_PROPERTIES_MSG)), 255, 25, 0, 0); @@ -11027,10 +11027,10 @@ int CGameMode::HandleActorPick(ActorPickInfo* pick, int result) { this->isAutoMoveClickOn = 0; const int skillUse = reinterpret_cast(&this->skillUseType); if (!HIBYTE(GetAsyncKeyState(VK_CONTROL)) && forceOption == 0) { - this->scene->player->SendMsg(nullptr, AM_PROCEEDTOUCHSKILL, 0, pick->accountId, 0, skillUse, skillUse >> 31, 1, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_PROCEEDTOUCHSKILL, pick->accountId, skillUse, 1, 0, 0, 0); this->forcedAttack = 0; } else { - this->scene->player->SendMsg(nullptr, AM_PROCEEDTOUCHSKILL, 0, pick->accountId, 0, skillUse, skillUse >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_PROCEEDTOUCHSKILL, pick->accountId, skillUse, 0, 0, 0, 0); this->forcedAttack = 1; } return result; @@ -11038,7 +11038,7 @@ int CGameMode::HandleActorPick(ActorPickInfo* pick, int result) { default: if (reinterpret_cast(this->skillUseType) == 5) { const long long skillUse = static_cast(reinterpret_cast(this)) + offsetof(CGameMode, skillUseType); - this->scene->player->SendMsg(nullptr, AM_PROCEEDTOUCHSKILL, 0, pick->accountId, 0, static_cast(skillUse), static_cast(skillUse >> 32), 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_PROCEEDTOUCHSKILL, pick->accountId, skillUse, 0, 0, 0, 0); } return result; } @@ -11047,7 +11047,7 @@ int CGameMode::HandleActorPick(ActorPickInfo* pick, int result) { return 0; case 1: if (g_mouse.buttons[0] == 1 && reinterpret_cast(this->skillUseType) == 0) { - this->scene->player->SendMsg(nullptr, AM_PROCEEDPICKUPITEM, 0, pick->accountId, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_PROCEEDPICKUPITEM, pick->accountId, 0, 0, 0, 0, 0); } break; case 4: { diff --git a/Source/Client/Mode/GameModeHandlers.cpp b/Source/Client/Mode/GameModeHandlers.cpp index 81faca6c9..c9e8b8b89 100644 --- a/Source/Client/Mode/GameModeHandlers.cpp +++ b/Source/Client/Mode/GameModeHandlers.cpp @@ -393,11 +393,11 @@ void CGameMode::ReceiveGroundSkillExtended(const unsigned char* record) { return; } CGraffiSkill* skill = new CGraffiSkill; - skill->SendMsg(nullptr, AM_SETMASTERGID, 0, packet.aid, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SETMASTERGID, packet.aid, 0, 0, 0, 0, 0); const int address = reinterpret_cast(packet.text); const int x = packet.x; const int y = packet.y; - skill->SendMsg(nullptr, AM_SET_SKILL, 0, address, address >> 31, x, x >> 31, y, y >> 31, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SET_SKILL, address, x, y, 0, 0, 0); this->scene->objects.push_back(skill); this->scene->skills.push_back(skill); return; @@ -442,7 +442,7 @@ void CGameMode::ReceiveGroundSkillExtended(const unsigned char* record) { } skill->sourceActorId = packet.owner; const int address = reinterpret_cast(&data); - skill->SendMsg(nullptr, AM_SKILLSTANDENTRY, 0, address, address >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SKILLSTANDENTRY, address, 0, 0, 0, 0, 0); } // OFFSET: 0x00D413F0 @@ -483,10 +483,11 @@ void CGameMode::SpawnGroundSkill(std::uint32_t aid, std::uint32_t owner, int val } skill->sourceActorId = owner; const int address = reinterpret_cast(&data); - skill->SendMsg(nullptr, AM_SKILLSTANDENTRY, 0, address, address >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SKILLSTANDENTRY, address, 0, 0, 0, 0, 0); } else { this->SpawnMirrorActor(aid, owner, x, y); } + } struct GameOptionEntry { @@ -786,10 +787,7 @@ void CGameMode::ReceivePetAct(unsigned char* packet) { if (kind == 2) { const std::int64_t emotion = value; const std::int64_t basePack = g_cashEmotionMgr->BasePackId(); - actor->SendMsg( - nullptr, 160, 0, static_cast(basePack), static_cast(basePack >> 32), static_cast(emotion), static_cast(emotion >> 32), 0, 0, 0, - 0, 0, 0, 0, 0 - ); + actor->SendMsg(nullptr, 160, basePack, emotion, 0, 0, 0, 0); return; } @@ -802,7 +800,7 @@ void CGameMode::ReceivePetAct(unsigned char* packet) { g_session.FormatMonsterSpeech(talk, speech, *reinterpret_cast(packet + 2), 1 - kind); if (std::strcmp(speech, "") != 0) { const std::int64_t text = reinterpret_cast(speech); - actor->SendMsg(nullptr, AM_CHAT, 0, static_cast(text), static_cast(text >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_CHAT, text, 0, 0, 0, 0, 0); if (!g_serviceOptions.Get(114) && !g_serviceOptions.Get(148)) { g_windowMgr.SendNotice(UIM_PUSHINTOCHATHISTORY, reinterpret_cast(speech), 0xFAFAFA, 0, 0, 0); } @@ -891,7 +889,7 @@ void CGameMode::ReceivePlayerMessage82(const unsigned char* packet) { return; } - player->SendMsg(nullptr, AM_MAKE_SKILL_RECHARGEGAGE, 0, *reinterpret_cast(packet + 6) * 1000, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, AM_MAKE_SKILL_RECHARGEGAGE, static_cast(*reinterpret_cast(packet + 6) * 1000), 0, 0, 0, 0, 0); g_session.playerStatusFlags[0x0A] = true; } @@ -1324,7 +1322,7 @@ void CGameMode::ReceiveActorMessage32(const unsigned char* packet) { } const std::int64_t argument = reinterpret_cast(&message); - actor->SendMsg(nullptr, AM_MAKE_CHAT_TITLE, 0, static_cast(argument), static_cast(argument >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MAKE_CHAT_TITLE, argument, 0, 0, 0, 0, 0); } // OFFSET: 0x00D3F3E0 @@ -1579,7 +1577,7 @@ void CGameMode::ReceiveSummonHpInit(const unsigned char* buffer) { CRenderObject* actor = this->scene->GetGameActorByAID(packet->summonId); if (actor != nullptr) { const std::int64_t id = packet->summonId; - actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, static_cast(id), static_cast(id >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_UPDATEGAGE, id, 0, 0, 0, 0, 0); } } @@ -1603,7 +1601,7 @@ void CGameMode::ReceiveSummonHpUpdate(const unsigned char* buffer) { CRenderObject* actor = this->scene->GetGameActorByAID(packet->summonId); if (actor != nullptr) { const std::int64_t id = packet->summonId; - actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, static_cast(id), static_cast(id >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_UPDATEGAGE, id, 0, 0, 0, 0, 0); } } @@ -2555,8 +2553,7 @@ void CGameMode::ReceiveStatusChangeEffect2(const unsigned char* packet) { // FUNCTION: fn_22018 void CGameMode::ReceiveActorStatusValuePacket2(const unsigned char* packet) { this->ReceiveActorStatusValue( - *reinterpret_cast(packet + 2), *reinterpret_cast(packet + 6), *reinterpret_cast(packet + 10), - *reinterpret_cast(packet + 14) + *reinterpret_cast(packet + 2), *reinterpret_cast(packet + 6), *reinterpret_cast(packet + 10) ); } @@ -2676,7 +2673,7 @@ void CGameMode::Zc_Skill_Entry(const unsigned char* record) { skill->sourceActorId = packet.owner; const int address = reinterpret_cast(&data); - skill->SendMsg(nullptr, AM_SKILLSTANDENTRY, 0, address, address >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SKILLSTANDENTRY, address, 0, 0, 0, 0, 0); } // OFFSET: 0x00D40730 @@ -2698,9 +2695,9 @@ void CGameMode::Zc_Skill_Entry2(const unsigned char* record) { CGraffiSkill* skill = new CGraffiSkill; this->scene->objects.push_back(skill); this->scene->skills.push_back(skill); - skill->SendMsg(nullptr, AM_SETMASTERGID, 0, packet.aid, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SETMASTERGID, packet.aid, 0, 0, 0, 0, 0); const int address = reinterpret_cast(packet.text); - skill->SendMsg(nullptr, AM_SET_SKILL, 0, address, address >> 31, data.x, data.x >> 31, data.y, data.y >> 31, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SET_SKILL, address, data.x, data.y, 0, 0, 0); return; } @@ -2726,7 +2723,7 @@ void CGameMode::Zc_Skill_Entry2(const unsigned char* record) { } const int address = reinterpret_cast(&data); - skill->SendMsg(nullptr, AM_SKILLSTANDENTRY, 0, address, address >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SKILLSTANDENTRY, address, 0, 0, 0, 0, 0); } // OFFSET: 0x00D40970 @@ -2740,11 +2737,11 @@ void CGameMode::ReceiveGroundSkill8(const unsigned char* record) { CGraffiSkill* skill = new CGraffiSkill; this->scene->objects.push_back(skill); this->scene->skills.push_back(skill); - skill->SendMsg(nullptr, AM_SETMASTERGID, 0, packet.aid, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SETMASTERGID, packet.aid, 0, 0, 0, 0, 0); const int address = reinterpret_cast(packet.text); const int x = packet.x; const int y = packet.y; - skill->SendMsg(nullptr, AM_SET_SKILL, 0, address, address >> 31, x, x >> 31, y, y >> 31, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SET_SKILL, address, x, y, 0, 0, 0); return; } @@ -2785,7 +2782,7 @@ void CGameMode::ReceiveGroundSkill8(const unsigned char* record) { } skill->sourceActorId = packet.owner; const int address = reinterpret_cast(&data); - skill->SendMsg(nullptr, AM_SKILLSTANDENTRY, 0, address, address >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SKILLSTANDENTRY, address, 0, 0, 0, 0, 0); } // OFFSET: 0x00D40BC0 @@ -2799,11 +2796,11 @@ void CGameMode::ReceiveGroundSkill32(const unsigned char* record) { CGraffiSkill* skill = new CGraffiSkill; this->scene->objects.push_back(skill); this->scene->skills.push_back(skill); - skill->SendMsg(nullptr, AM_SETMASTERGID, 0, packet.aid, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SETMASTERGID, packet.aid, 0, 0, 0, 0, 0); const int address = reinterpret_cast(packet.text); const int x = packet.x; const int y = packet.y; - skill->SendMsg(nullptr, AM_SET_SKILL, 0, address, address >> 31, x, x >> 31, y, y >> 31, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SET_SKILL, address, x, y, 0, 0, 0); return; } @@ -2846,7 +2843,7 @@ void CGameMode::ReceiveGroundSkill32(const unsigned char* record) { } skill->sourceActorId = packet.owner; const int address = reinterpret_cast(&data); - skill->SendMsg(nullptr, AM_SKILLSTANDENTRY, 0, address, address >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SKILLSTANDENTRY, address, 0, 0, 0, 0, 0); } #pragma pack(push, 1) diff --git a/Source/Client/Mode/GameModeNotices.cpp b/Source/Client/Mode/GameModeNotices.cpp index cae580aae..c4a09f33d 100644 --- a/Source/Client/Mode/GameModeNotices.cpp +++ b/Source/Client/Mode/GameModeNotices.cpp @@ -564,9 +564,7 @@ void CGameMode::StopActorMove(std::uint32_t aid, std::int16_t x, std::int16_t y, } } - actor->SendMsg(nullptr, AM_STOPMOVE, 0, static_cast(static_cast(x)), static_cast(static_cast(x) >> 32), - static_cast(static_cast(y)), static_cast(static_cast(y) >> 32), 0, 0, - static_cast(static_cast(flag)), static_cast(static_cast(flag) >> 32), 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STOPMOVE, x, y, 0, flag, 0, 0); } // OFFSET: 0x00D69140 @@ -977,7 +975,7 @@ void CGameMode::ReceiveEffectRemove(const unsigned char* data) { if (actor) { while (static_cast(actor)->HasId(packet->effectId)) { const std::int64_t effectId = packet->effectId; - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, static_cast(effectId), static_cast(effectId >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, effectId, 0, 0, 0, 0, 0); } } @@ -1091,7 +1089,7 @@ void CGameMode::ReceiveActorMessage144(const unsigned char* data) { if (actor) { const std::int64_t y = packet->y; const std::int64_t x = packet->x; - actor->SendMsg(nullptr, AM_FALLEN_ANGEL, 0, static_cast(x), static_cast(x >> 32), static_cast(y), static_cast(y >> 32), 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_FALLEN_ANGEL, x, y, 0, 0, 0, 0); } } @@ -1235,11 +1233,11 @@ void CGameMode::ReceiveActorEffect228(const unsigned char* data) { auto* gameActor = static_cast(actor); if (StateFlag01(gameActor->GetStateFlags()) == true || StateFlag02(gameActor->GetStateFlags()) == true) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 228, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 228, 0, 0, 0, 0, 0); } if (0 == packet->state) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 228, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 228, 0, 0, 0, 0, 0); } else if (1 != packet->state || static_cast(actor)->HasId(228)) { return; } @@ -1579,35 +1577,35 @@ void CGameMode::ReceiveItemEffectResult(const unsigned char* data) { break; case 2: if (static_cast(g_modeMgr.GetGameMode())->scene->player->HasId(305)) { - static_cast(g_modeMgr.GetGameMode())->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 305, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + static_cast(g_modeMgr.GetGameMode())->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 305, 0, 0, 0, 0, 0); } static_cast(g_modeMgr.GetGameMode())->scene->player->LaunchEffect(305, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); text = FormatOwnedString(LookupMessage(MSI_MAKE_TARGET_SUCCEESS_MSG), item.DisplayName(0).c_str()).c_str(); break; case 3: if (static_cast(g_modeMgr.GetGameMode())->scene->player->HasId(306)) { - static_cast(g_modeMgr.GetGameMode())->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + static_cast(g_modeMgr.GetGameMode())->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 306, 0, 0, 0, 0, 0); } static_cast(g_modeMgr.GetGameMode())->scene->player->LaunchEffect(306, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); text = FormatOwnedString(LookupMessage(MSI_MAKE_TARGET_FAIL_MSG), item.DisplayName(0).c_str()).c_str(); break; case 4: if (static_cast(g_modeMgr.GetGameMode())->scene->player->HasId(1015)) { - static_cast(g_modeMgr.GetGameMode())->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 1015, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + static_cast(g_modeMgr.GetGameMode())->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 1015, 0, 0, 0, 0, 0); } static_cast(g_modeMgr.GetGameMode())->scene->player->LaunchEffect(1015, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); text = FormatOwnedString(LookupMessage(MSI_MAKE_TARGET_SUCCEESS_MSG), item.DisplayName(0).c_str()).c_str(); break; case 5: if (static_cast(g_modeMgr.GetGameMode())->scene->player->HasId(1016)) { - static_cast(g_modeMgr.GetGameMode())->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 1016, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + static_cast(g_modeMgr.GetGameMode())->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 1016, 0, 0, 0, 0, 0); } static_cast(g_modeMgr.GetGameMode())->scene->player->LaunchEffect(1016, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); text = FormatOwnedString(LookupMessage(MSI_MAKE_TARGET_FAIL_MSG), item.DisplayName(0).c_str()).c_str(); break; case 6: { if (static_cast(g_modeMgr.GetGameMode())->scene->player->HasId(1017)) { - static_cast(g_modeMgr.GetGameMode())->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 1017, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + static_cast(g_modeMgr.GetGameMode())->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 1017, 0, 0, 0, 0, 0); } static_cast(g_modeMgr.GetGameMode())->scene->player->LaunchEffect(1017, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); text = FormatOwnedString(LookupMessage(MSI_MAKE_TARGET_FAIL_MSG), item.DisplayName(0).c_str()).c_str(); @@ -1619,7 +1617,7 @@ void CGameMode::ReceiveItemEffectResult(const unsigned char* data) { } case 7: { if (static_cast(g_modeMgr.GetGameMode())->scene->player->HasId(1018)) { - static_cast(g_modeMgr.GetGameMode())->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 1018, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + static_cast(g_modeMgr.GetGameMode())->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 1018, 0, 0, 0, 0, 0); } static_cast(g_modeMgr.GetGameMode())->scene->player->LaunchEffect(1018, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); text = FormatOwnedString(LookupMessage(MSI_MAKE_TARGET_FAIL_MSG), item.DisplayName(0).c_str()).c_str(); @@ -2556,7 +2554,7 @@ void CGameMode::ReceiveRodexMailReturn(const unsigned char* data) { // FUNCTION: fn_22144 void CGameMode::ReceiveActorStatusValuePacket(const unsigned char* data) { const auto* packet = reinterpret_cast(data); - this->ReceiveActorStatusValue(packet->aid, packet->status, packet->value, packet->value >> 31); + this->ReceiveActorStatusValue(packet->aid, packet->status, packet->value); } // OFFSET: 0x00D73E20 @@ -4032,7 +4030,7 @@ void CGameMode::ReceiveNotifyGroundSkill(const unsigned char* packet) { if (*reinterpret_cast(packet + 4) == g_session.m_aid) { const std::int64_t value = reinterpret_cast(&message); - this->scene->player->SendMsg(nullptr, AM_GROUNDSKILL, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_GROUNDSKILL, value, 0, 0, 0, 0, 0); actor = this->scene->player; if (actor != nullptr) { job = actor->GetEffectiveJob(-1); @@ -4041,7 +4039,7 @@ void CGameMode::ReceiveNotifyGroundSkill(const unsigned char* packet) { CGameActor* gameActor = static_cast(this->scene->GetGameActorByAID(*reinterpret_cast(packet + 4))); if (gameActor != nullptr) { const std::int64_t value = reinterpret_cast(&message); - gameActor->SendMsg(nullptr, AM_GROUNDSKILL, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + gameActor->SendMsg(nullptr, AM_GROUNDSKILL, value, 0, 0, 0, 0, 0); actor = gameActor; job = actor->GetEffectiveJob(-1); } @@ -4618,7 +4616,7 @@ void CGameMode::ReceiveItemDropEntry(const unsigned char* data) { } const std::int64_t entryAddress = reinterpret_cast(&entry); - item->SendMsg(nullptr, AM_INITSTANDENTRY, 0, static_cast(entryAddress), static_cast(entryAddress >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + item->SendMsg(nullptr, AM_INITSTANDENTRY, entryAddress, 0, 0, 0, 0, 0); } #pragma pack(push, 1) struct SpriteChangePacket { @@ -4690,7 +4688,7 @@ void CGameMode::ReceiveSpriteChange(const unsigned char* data) { return; } if (packet->type == LOOK_BASE) { - skill->SendMsg(nullptr, AM_SETJOB, 0, packet->value, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SETJOB, packet->value, 0, 0, 0, 0, 0); } return; } @@ -4804,7 +4802,7 @@ void CGameMode::ReceiveSpriteChange2(const unsigned char* data) { return; } if (packet->type == LOOK_BASE) { - skill->SendMsg(nullptr, AM_SETJOB, 0, value, packet->valueHigh, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SETJOB, packet->value, 0, 0, 0, 0, 0); } return; } @@ -4879,12 +4877,12 @@ void CGameMode::ReceiveSpriteChange2(const unsigned char* data) { case LOOK_BODY2: actor->SetBodyCostume(value, 1); if (StateFlag04(actor->GetStateFlags())) { - actor->SendMsg(nullptr, AM_DELETE_BIRD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - actor->SendMsg(nullptr, AM_MAKE_BIRD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_BIRD, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MAKE_BIRD, 0, 0, 0, 0, 0, 0); } if (StateFlag20(actor->GetStateFlags())) { - actor->SendMsg(nullptr, AM_DELETE_WOLF, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - actor->SendMsg(nullptr, AM_MAKE_WOLF, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_WOLF, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MAKE_WOLF, 0, 0, 0, 0, 0, 0); } break; case 14: @@ -5768,7 +5766,7 @@ void CGameMode::ReceiveStatusChangeNotice(const unsigned char* data) { if (CRenderObject* actor = this->scene->GetGameActorByAID(packet->aid)) { const std::int64_t state = packet->state; const std::int64_t type = packet->type; - actor->SendMsg(nullptr, AM_STATUS_CHANGE, 0, static_cast(type), static_cast(type >> 32), static_cast(state), static_cast(state >> 32), 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STATUS_CHANGE, type, state, 0, 0, 0, 0); } } @@ -6807,19 +6805,19 @@ void CGameMode::ReceiveStatusChangeNotice(const unsigned char* data) { break; case EFST_SIREN: if (packet->aid == g_session.m_aid) { - this->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 879, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 879, 0, 0, 0, 0, 0); } std::sprintf(message, ""); break; case EFST_DEEP_SLEEP: if (packet->aid == g_session.m_aid) { - this->scene->player->SendMsg(nullptr, AM_DELETE_SLEEP_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_DELETE_SLEEP_EFFECT, 0, 0, 0, 0, 0, 0); } std::sprintf(message, ""); break; case EFST_NETHERWORLD: if (packet->aid == g_session.m_aid) { - this->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 453, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 453, 0, 0, 0, 0, 0); } std::sprintf(message, ""); break; @@ -6827,7 +6825,7 @@ void CGameMode::ReceiveStatusChangeNotice(const unsigned char* data) { if (packet->aid == g_session.m_aid) { CPlayer* player = this->scene->player; while (player->HasId(752)) { - player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 752, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, AM_DELETE_EFFECT, 752, 0, 0, 0, 0, 0); } } std::sprintf(message, ""); @@ -6883,14 +6881,14 @@ void CGameMode::ReceiveStatusChangeNotice(const unsigned char* data) { break; case EFST_HANDICAPSTATE_ICEEXPLO: if (packet->aid == g_session.m_aid && this->scene->player) { - this->scene->player->SendMsg(nullptr, AM_RETURN_COLOR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_RETURN_COLOR, 0, 0, 0, 0, 0, 0); } break; case EFST_DARKCROW: if (packet->aid == g_session.m_aid) { CPlayer* player = this->scene->player; while (player->HasId(1040)) { - player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 1040, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, AM_DELETE_EFFECT, 1040, 0, 0, 0, 0, 0); } } break; @@ -6898,7 +6896,7 @@ void CGameMode::ReceiveStatusChangeNotice(const unsigned char* data) { if (packet->aid == g_session.m_aid) { CPlayer* player = this->scene->player; while (player->HasId(1061)) { - player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 1061, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, AM_DELETE_EFFECT, 1061, 0, 0, 0, 0, 0); } } break; @@ -6937,7 +6935,7 @@ void CGameMode::ReceiveStatusChangeNotice(const unsigned char* data) { if (packet->aid == g_session.m_aid) { g_session.madogearType = 0; } - actor->SendMsg(nullptr, AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0); break; } case EFST_RELIEVE_DAMAGE: @@ -6954,7 +6952,7 @@ void CGameMode::ReceiveStatusChangeNotice(const unsigned char* data) { actor = this->scene->GetGameActorByAID(packet->aid); } if (actor) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 1601, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 1601, 0, 0, 0, 0, 0); } break; } @@ -6967,7 +6965,7 @@ void CGameMode::ReceiveStatusChangeNotice(const unsigned char* data) { actor = this->scene->GetGameActorByAID(packet->aid); } if (actor) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 1610, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 1610, 0, 0, 0, 0, 0); } break; } @@ -7074,7 +7072,7 @@ void CGameMode::ReceiveStatusChangeNotice(const unsigned char* data) { if (packet->aid == g_session.m_aid) { const std::int64_t state = packet->state; const std::int64_t type = packet->type; - this->scene->player->SendMsg(nullptr, AM_STATUS_CHANGE, 0, static_cast(type), static_cast(type >> 32), static_cast(state), static_cast(state >> 32), 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_STATUS_CHANGE, type, state, 0, 0, 0, 0); } } diff --git a/Source/Client/Mode/GameModePackets.cpp b/Source/Client/Mode/GameModePackets.cpp index fcc819f40..ff4bf4b5c 100644 --- a/Source/Client/Mode/GameModePackets.cpp +++ b/Source/Client/Mode/GameModePackets.cpp @@ -668,7 +668,7 @@ __declspec(noinline) void CGameMode::ReceiveActorText(const unsigned char* packe text[80] = '\0'; if (CRenderObject* actor = this->scene->GetGameActorByAID(*reinterpret_cast(packet + 2))) { const std::int64_t value = reinterpret_cast(text); - actor->SendMsg(nullptr, AM_MAKE_BUYING_SHOP_TITLE, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MAKE_BUYING_SHOP_TITLE, value, 0, 0, 0, 0, 0); } } @@ -756,7 +756,7 @@ void CGameMode::ReceiveDevotionList(const unsigned char* packet) { if (actor != nullptr) { for (int index = 0; index < 5; ++index) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 232, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 232, 0, 0, 0, 0, 0); } } @@ -788,7 +788,7 @@ void CGameMode::ReceiveDevotionList(const unsigned char* packet) { // FUNCTION: fn_21686 __declspec(noinline) void CGameMode::ReceiveActorSignal(const unsigned char* packet) { if (CRenderObject* actor = this->scene->GetGameActorByAID(*reinterpret_cast(packet + 2))) { - actor->SendMsg(nullptr, AM_DELETE_BUYING_SHOP_TITLE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_BUYING_SHOP_TITLE, 0, 0, 0, 0, 0, 0); } } @@ -1340,7 +1340,7 @@ void CGameMode::ReceiveHpSpRecovery(const unsigned char* packet, int variant) { g_session.hp = hp; g_session.RefreshHpSpWindows(); } - player->SendMsg(nullptr, AM_MAKE_NUMBER, 0, amount, amount >> 31, static_cast(0xFF00FF00), 0, 114, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, AM_MAKE_NUMBER, amount, 0xFF00FF00u, 114, 0, 0, 0); player->LaunchEffect(331, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; } @@ -1352,7 +1352,7 @@ void CGameMode::ReceiveHpSpRecovery(const unsigned char* packet, int variant) { sp = value; g_session.RefreshHpSpWindows(); } - player->SendMsg(nullptr, AM_MAKE_NUMBER, 0, amount, amount >> 31, static_cast(0xFF0000FF), 0, 114, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, AM_MAKE_NUMBER, amount, 0xFF0000FFu, 114, 0, 0, 0); player->LaunchEffect(332, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; } @@ -1628,7 +1628,7 @@ __declspec(noinline) void CGameMode::ReceiveActorStatusBlock(const unsigned char g_session.elementalMaxHp = *reinterpret_cast(packet + 0xA); g_session.elementalMaxSp = *reinterpret_cast(packet + 0x12); if (CRenderObject* actor = this->scene->GetGameActorByAID(*reinterpret_cast(packet + 2))) { - actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, 0, 0, 0, 0, 0); } } @@ -1652,7 +1652,7 @@ __declspec(noinline) void CGameMode::ReceiveActorStatusUpdate(const unsigned cha break; } if (CRenderObject* actor = this->scene->GetGameActorByAID(g_session.elementalGid)) { - actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, 0, 0, 0, 0, 0); } } } @@ -1665,7 +1665,7 @@ void CGameMode::ReceiveActorTitle(const unsigned char* packet) { text[80] = '\0'; if (CRenderObject* actor = this->scene->GetGameActorByAID(*reinterpret_cast(packet + 2))) { const std::int64_t value = reinterpret_cast(text); - actor->SendMsg(nullptr, AM_MAKE_SHOP_TITLE, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MAKE_SHOP_TITLE, value, 0, 0, 0, 0, 0); } } @@ -1674,7 +1674,7 @@ void CGameMode::ReceiveActorTitle(const unsigned char* packet) { __declspec(noinline) void CGameMode::ReceiveActorInt8(const unsigned char* packet) { if (CRenderObject* actor = this->scene->GetGameActorByAID(*reinterpret_cast(packet + 2))) { const std::int64_t value = *reinterpret_cast(packet + 6); - actor->SendMsg(nullptr, AM_UPDATE_MONSTER_GAGE, 0, static_cast(value), static_cast(value >> 32), 0x14, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_UPDATE_MONSTER_GAGE, value, 0x14, 0, 0, 0, 0); } } @@ -1684,9 +1684,7 @@ __declspec(noinline) void CGameMode::ReceiveActorInt64Pair(const unsigned char* if (CRenderObject* actor = this->scene->GetGameActorByAID(*reinterpret_cast(packet + 2))) { const std::int64_t first = *reinterpret_cast(packet + 6); const std::int64_t second = *reinterpret_cast(packet + 0xA); - actor->SendMsg( - nullptr, AM_UPDATE_MONSTER_GAGE, 0, static_cast(first), static_cast(first >> 32), static_cast(second), static_cast(second >> 32), 0, 0, 0, 0, 0, 0, 0, 0 - ); + actor->SendMsg(nullptr, AM_UPDATE_MONSTER_GAGE, first, second, 0, 0, 0, 0); } } @@ -2218,9 +2216,7 @@ __declspec(noinline) void CGameMode::ReceiveActorMessage7(const unsigned char* p char text[256]; std::memcpy(text, packet + 8, length); const std::int64_t value = reinterpret_cast(text); - actor->SendMsg( - nullptr, AM_CHAT, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 - ); + actor->SendMsg(nullptr, AM_CHAT, value, 0, 0, 0, 0, 0); } // OFFSET: 0x00D7AEB0 // FUNCTION: fn_22194 @@ -2273,11 +2269,11 @@ void CGameMode::ApplyActorStatusEffects(std::uint32_t aid, int state, int flag, if (actor->IsPlayerClass(actor->GetEffectiveJob(-1))) { if (StateFlag01(actor->GetStateFlags()) || StateFlag02(actor->GetStateFlags())) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 203, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 254, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 1132, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 418, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 586, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 203, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 254, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 1132, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 418, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 586, 0, 0, 0, 0, 0); return; } @@ -2376,10 +2372,10 @@ void CGameMode::ApplyActorStatusEffects(std::uint32_t aid, int state, int flag, } if (StateFlag01(actor->GetStateFlags()) || StateFlag02(actor->GetStateFlags())) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 203, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 254, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 1132, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 418, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 203, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 254, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 1132, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 418, 0, 0, 0, 0, 0); return; } @@ -2395,7 +2391,7 @@ void CGameMode::ApplyActorStatusEffects(std::uint32_t aid, int state, int flag, } } else { while (actor->HasId(420)) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 420, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 420, 0, 0, 0, 0, 0); actor->LaunchEffect(540, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } } @@ -2406,7 +2402,7 @@ void CGameMode::ApplyActorStatusEffects(std::uint32_t aid, int state, int flag, } } else { while (actor->HasId(427)) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 427, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 427, 0, 0, 0, 0, 0); } } @@ -2417,8 +2413,8 @@ void CGameMode::ApplyActorStatusEffects(std::uint32_t aid, int state, int flag, } } else { while (actor->HasId(254)) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 254, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 1132, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 254, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 1132, 0, 0, 0, 0, 0); } } @@ -2428,7 +2424,7 @@ void CGameMode::ApplyActorStatusEffects(std::uint32_t aid, int state, int flag, } } else { while (actor->HasId(655)) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 655, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 655, 0, 0, 0, 0, 0); actor->LaunchEffect(656, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } } @@ -2439,7 +2435,7 @@ void CGameMode::ApplyActorStatusEffects(std::uint32_t aid, int state, int flag, } } else { while (actor->HasId(667)) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 667, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 667, 0, 0, 0, 0, 0); } } @@ -2449,7 +2445,7 @@ void CGameMode::ApplyActorStatusEffects(std::uint32_t aid, int state, int flag, } } else { while (actor->HasId(375)) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 375, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 375, 0, 0, 0, 0, 0); } } @@ -2459,7 +2455,7 @@ void CGameMode::ApplyActorStatusEffects(std::uint32_t aid, int state, int flag, } } else { while (actor->HasId(744) == 1) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 744, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 744, 0, 0, 0, 0, 0); } } } @@ -2467,7 +2463,7 @@ void CGameMode::ApplyActorStatusEffects(std::uint32_t aid, int state, int flag, // OFFSET: 0x00D7B350 // FUNCTION: fn_22201 __declspec(noinline) void CGameMode::ReceivePlayerRouteClear(const unsigned char*) { - this->scene->player->SendMsg(nullptr, AM_CLEAR_ROUTE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_CLEAR_ROUTE, 0, 0, 0, 0, 0, 0); } // OFFSET: 0x00D78010 @@ -2921,19 +2917,19 @@ void CGameMode::ReceiveNotifySkill(const unsigned char* packet) { if (sourceAid == g_session.m_aid) { const std::int64_t value = reinterpret_cast(&message); - this->scene->player->SendMsg(nullptr, AM_SKILL, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_SKILL, value, 0, 0, 0, 0, 0); source = this->scene->player; job = source->GetEffectiveJob(-1); } else { gameActor = static_cast(this->scene->GetGameActorByAID(sourceAid)); if (gameActor != nullptr) { const std::int64_t value = reinterpret_cast(&message); - gameActor->SendMsg(nullptr, AM_SKILL, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + gameActor->SendMsg(nullptr, AM_SKILL, value, 0, 0, 0, 0, 0); source = gameActor; job = source->GetEffectiveJob(-1); } else if (CRenderObject* skill = this->scene->GetSkillByAID(sourceAid)) { const std::int64_t value = reinterpret_cast(&message); - skill->SendMsg(nullptr, AM_SKILL, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SKILL, value, 0, 0, 0, 0, 0); } } @@ -3405,19 +3401,19 @@ void CGameMode::ReceiveActorSkillAction(const unsigned char* packet) { if (*reinterpret_cast(packet + 4) == g_session.m_aid) { const std::int64_t value = reinterpret_cast(&message); - this->scene->player->SendMsg(nullptr, AM_SKILL, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_SKILL, value, 0, 0, 0, 0, 0); actor = this->scene->player; job = actor->GetEffectiveJob(-1); } else { gameActor = static_cast(this->scene->GetGameActorByAID(*reinterpret_cast(packet + 4))); if (gameActor != nullptr) { const std::int64_t value = reinterpret_cast(&message); - gameActor->SendMsg(nullptr, AM_SKILL, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + gameActor->SendMsg(nullptr, AM_SKILL, value, 0, 0, 0, 0, 0); actor = gameActor; job = actor->GetEffectiveJob(-1); } else if (CRenderObject* skill = this->scene->GetSkillByAID(*reinterpret_cast(packet + 4))) { const std::int64_t value = reinterpret_cast(&message); - skill->SendMsg(nullptr, AM_SKILL, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SKILL, value, 0, 0, 0, 0, 0); } } @@ -3456,17 +3452,17 @@ void CGameMode::ReceiveActorSkillMessage(const unsigned char* packet) { if (*reinterpret_cast(packet + 4) == g_session.m_aid) { actor = this->scene->player; const std::int64_t value = reinterpret_cast(&message); - actor->SendMsg(nullptr, AM_SKILL, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_SKILL, value, 0, 0, 0, 0, 0); job = actor->GetEffectiveJob(-1); } else { actor = static_cast(this->scene->GetGameActorByAID(*reinterpret_cast(packet + 4))); if (actor != nullptr) { const std::int64_t value = reinterpret_cast(&message); - actor->SendMsg(nullptr, AM_SKILL, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_SKILL, value, 0, 0, 0, 0, 0); job = actor->GetEffectiveJob(-1); } else if (CRenderObject* skill = this->scene->GetSkillByAID(*reinterpret_cast(packet + 4))) { const std::int64_t value = reinterpret_cast(&message); - skill->SendMsg(nullptr, AM_SKILL, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SKILL, value, 0, 0, 0, 0, 0); actor = nullptr; } } @@ -3513,9 +3509,9 @@ void CGameMode::ReceiveDispel(const unsigned char* packet) { const auto* dispel = reinterpret_cast(packet); if (dispel->aid == g_session.m_aid) { - this->scene->player->SendMsg(nullptr, AM_DELETE_BEGIN_SPELL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->scene->player->SendMsg(nullptr, AM_DELETE_MAGIC_TARGET, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->scene->player->SendMsg(nullptr, AM_DELETE_SKILL_RECHARGEGAGE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_DELETE_BEGIN_SPELL, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_DELETE_MAGIC_TARGET, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_DELETE_SKILL_RECHARGEGAGE, 0, 0, 0, 0, 0, 0); CPlayer* player = this->scene->player; if (player->render.state == 8) { player->SetState(0, 1); @@ -3528,9 +3524,9 @@ void CGameMode::ReceiveDispel(const unsigned char* packet) { return; } - actor->SendMsg(nullptr, AM_DELETE_BEGIN_SPELL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - actor->SendMsg(nullptr, AM_DELETE_MAGIC_TARGET, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - actor->SendMsg(nullptr, AM_DELETE_SKILL_RECHARGEGAGE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_BEGIN_SPELL, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_MAGIC_TARGET, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_SKILL_RECHARGEGAGE, 0, 0, 0, 0, 0, 0); g_effectMgr->Retire(dispel->aid, 1114); if (actor->render.state == 8) { actor->SetState(0, 1); @@ -3650,7 +3646,7 @@ void CGameMode::ReceiveItem1748List(const unsigned char* packet) { // OFFSET: 0x00D5F5C0 // FUNCTION: fn_21970 -void CGameMode::ReceiveActorStatusValue(std::uint32_t aid, int status, int amount, int option) { +void CGameMode::ReceiveActorStatusValue(std::uint32_t aid, int status, std::int64_t amount) { CGameActor* actor; if (aid == g_session.m_aid) { actor = this->scene->player; @@ -3664,40 +3660,40 @@ void CGameMode::ReceiveActorStatusValue(std::uint32_t aid, int status, int amoun if (status == EF_HPTIME) { if (aid == g_session.m_aid) { g_session.UpdateRandomStats(); - const int hp = g_session.hp + amount; + const int hp = g_session.hp + static_cast(amount); if (g_session.hp != hp) { g_session.hp = hp; g_session.RefreshHpSpWindows(); } } - actor->SendMsg(nullptr, AM_MAKE_NUMBER, 0, amount, option, 0xFF00FF00, 0, 0x72, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MAKE_NUMBER, amount, 0xFF00FF00, 0x72, 0, 0, 0); } else if (status == EF_SPTIME) { if (aid == g_session.m_aid) { g_session.UpdateRandomStats(); int& sp = *reinterpret_cast(&g_session.spAndHomunculusStats[0]); - const int value = sp + amount; + const int value = sp + static_cast(amount); if (sp != value) { sp = value; g_session.RefreshHpSpWindows(); } } - actor->SendMsg(nullptr, AM_MAKE_NUMBER, 0, amount, option, 0xFF0000FF, 0, 0x72, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MAKE_NUMBER, amount, 0xFF0000FF, 0x72, 0, 0, 0); } else if (status == EF_GREEN_NUMBER) { - actor->SendMsg(nullptr, AM_MAKE_NUMBER, 0, amount, option, 0xFF00FF00, 0, 0x72, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MAKE_NUMBER, amount, 0xFF00FF00, 0x72, 0, 0, 0); } else if (status == EF_BLUE_NUMBER) { - actor->SendMsg(nullptr, AM_MAKE_NUMBER, 0, amount, option, 0xFF0000FF, 0, 0x72, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MAKE_NUMBER, amount, 0xFF0000FF, 0x72, 0, 0, 0); } else if (status == EF_RED_NUMBER) { - actor->SendMsg(nullptr, AM_MAKE_NUMBER, 0, amount, option, 0xFFFF0000, 0, 0x72, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MAKE_NUMBER, amount, 0xFFFF0000, 0x72, 0, 0, 0); } else if (status == EF_PURPLE_NUMBER) { - actor->SendMsg(nullptr, AM_MAKE_NUMBER, 0, amount, option, 0xFFFF00FF, 0, 0x72, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MAKE_NUMBER, amount, 0xFFFF00FF, 0x72, 0, 0, 0); } else if (status == EF_BLACK_NUMBER) { - actor->SendMsg(nullptr, AM_MAKE_NUMBER, 0, amount, option, 0xFF000000, 0, 0x72, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MAKE_NUMBER, amount, 0xFF000000, 0x72, 0, 0, 0); } else if (status == EF_WHITE_NUMBER) { - actor->SendMsg(nullptr, AM_MAKE_NUMBER, 0, amount, option, 0xFFFFFFFF, 0, 0x72, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MAKE_NUMBER, amount, 0xFFFFFFFF, 0x72, 0, 0, 0); } else if (status == EF_YELLOW_NUMBER) { - actor->SendMsg(nullptr, AM_MAKE_NUMBER, 0, amount, option, 0xFFFFFF00, 0, 0x72, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MAKE_NUMBER, amount, 0xFFFFFF00, 0x72, 0, 0, 0); } else if (status == EF_PINK_NUMBER) { - actor->SendMsg(nullptr, AM_MAKE_NUMBER, 0, amount, option, 0xFFFF55B1, 0, 0x72, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MAKE_NUMBER, amount, 0xFFFF55B1, 0x72, 0, 0, 0); } EffectLists* effects = g_effectMgr; @@ -3852,7 +3848,7 @@ void CGameMode::Zc_Spirits2(const unsigned char* data) { break; } - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, effectId, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, static_cast(effectId), 0, 0, 0, 0, 0); return; } @@ -3910,13 +3906,13 @@ void CGameMode::UpdateActorSpiritCount(std::uint32_t aid, std::int16_t count) { break; case JT_GUNSLINGER: case JT_GUNSLINGER_B: - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 629, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 629, 0, 0, 0, 0, 0); if (count == 0) { return; } break; case JT_MONK_B: - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 504, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 504, 0, 0, 0, 0, 0); if (count == 0) { return; } @@ -3930,7 +3926,7 @@ void CGameMode::UpdateActorSpiritCount(std::uint32_t aid, std::int16_t count) { } break; default: - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 228, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 228, 0, 0, 0, 0, 0); if (count == 0) { return; } @@ -4542,10 +4538,10 @@ void CGameMode::ReceiveParChange(unsigned char* data) { if (packet->value < 0) { text = FormatOwnedString(LookupMessage(MSI_BAD_MANNER_REMAIN), -packet->value); const int emotion = g_cashEmotionMgr->GetSpecialEmotion(CashEmotionSpecial::ChatProhibit); - this->scene->player->SendMsg(nullptr, AM_CASH_EMOTION, 0, 0, 0, emotion, emotion >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_CASH_EMOTION, 0, emotion, 0, 0, 0, 0); } else { text = LookupMessage(MSI_BAD_MANNER_END); - this->scene->player->SendMsg(nullptr, AM_DELETE_PROHIBITEFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_DELETE_PROHIBITEFFECT, 0, 0, 0, 0, 0, 0); } g_windowMgr.SendNotice(UIM_PUSHINTOCHATHISTORY, reinterpret_cast(text.c_str()), 0xFFFF, 0, 0, 0); *reinterpret_cast(&g_session.healthPoints[4]) = packet->value; @@ -4874,9 +4870,7 @@ void CGameMode::ApplyStatusChange( if (aid != g_session.m_aid) { CRenderObject* actor = this->scene->GetGameActorByAID(aid); if (actor) { - actor->SendMsg( - nullptr, AM_STATUS_CHANGE, 0, type, type >> 31, on, 0, value1, value1 >> 31, value2, value2 >> 31, flag, 0, value3, value3 >> 31 - ); + actor->SendMsg(nullptr, AM_STATUS_CHANGE, type, on, value1, value2, flag, value3); } if (type == EFST_SPELLFIST && actor) { @@ -5135,7 +5129,7 @@ void CGameMode::ApplyStatusChange( case EFST_SIREN: if (aid == g_session.m_aid) { CPlayer* player = this->scene->player; - player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 879, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, AM_DELETE_EFFECT, 879, 0, 0, 0, 0, 0); player->LaunchEffect(879, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); std::sprintf(message, ""); } @@ -5143,7 +5137,7 @@ void CGameMode::ApplyStatusChange( case EFST_SONG_OF_MANA: if (aid == g_session.m_aid) { CPlayer* player = this->scene->player; - player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 865, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, AM_DELETE_EFFECT, 865, 0, 0, 0, 0, 0); player->LaunchEffect(865, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); std::sprintf(message, ""); } @@ -5151,7 +5145,7 @@ void CGameMode::ApplyStatusChange( case EFST_DANCE_WITH_WUG: if (aid == g_session.m_aid) { CPlayer* player = this->scene->player; - player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 867, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, AM_DELETE_EFFECT, 867, 0, 0, 0, 0, 0); player->LaunchEffect(867, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); std::sprintf(message, ""); } @@ -5159,20 +5153,20 @@ void CGameMode::ApplyStatusChange( case EFST_LERADS_DEW: if (aid == g_session.m_aid) { CPlayer* player = this->scene->player; - player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 871, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, AM_DELETE_EFFECT, 871, 0, 0, 0, 0, 0); player->LaunchEffect(871, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); std::sprintf(message, ""); } break; case EFST_DEEP_SLEEP: if (aid == g_session.m_aid) { - this->scene->player->SendMsg(nullptr, AM_MAKE_SLEEP_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_MAKE_SLEEP_EFFECT, 0, 0, 0, 0, 0, 0); std::sprintf(message, ""); } break; case EFST_NETHERWORLD: if (aid == g_session.m_aid) { - this->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 453, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 453, 0, 0, 0, 0, 0); std::sprintf(message, ""); } break; @@ -5641,7 +5635,7 @@ void CGameMode::ApplyStatusChange( case EFST_KYOUGAKU: case EFST_ACTIVE_MONSTER_TRANSFORM: if (aid == g_session.m_aid) { - this->scene->player->SendMsg(nullptr, AM_STATUS_CHANGE, 0, type, type >> 31, on, 0, value1, value1 >> 31, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_STATUS_CHANGE, type, on, value1, 0, 0, 0); this->RefreshStatusStateEffect(aid); } return; @@ -5652,19 +5646,19 @@ void CGameMode::ApplyStatusChange( break; case EFST_FLOWER_LEAF: if (aid == g_session.m_aid) { - this->scene->player->SendMsg(nullptr, AM_STATUS_CHANGE, 0, 675, 0, on, 0, value1, value1 >> 31, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_STATUS_CHANGE, 675, on, value1, 0, 0, 0); this->RefreshStatusStateEffect(aid); } return; case EFST_RAY_OF_PROTECTION: if (aid == g_session.m_aid) { - this->scene->player->SendMsg(nullptr, AM_STATUS_CHANGE, 0, 676, 0, on, 0, value1, value1 >> 31, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_STATUS_CHANGE, 676, on, value1, 0, 0, 0); this->RefreshStatusStateEffect(aid); } break; case EFST_HANDICAPSTATE_ICEEXPLO: if (aid == g_session.m_aid) { - this->scene->player->SendMsg(nullptr, AM_STATUS_CHANGE, 0, 710, 0, on, 0, value1, value1 >> 31, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_STATUS_CHANGE, 710, on, value1, 0, 0, 0); this->RefreshStatusStateEffect(aid); } break; @@ -5725,7 +5719,7 @@ void CGameMode::ApplyStatusChange( g_session.madogearType = 1; } } - actor->SendMsg(nullptr, AM_MAKE_CHICKEN, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MAKE_CHICKEN, 0, 0, 0, 0, 0, 0); break; } case EFST_SPELLFIST: @@ -5948,13 +5942,13 @@ void CGameMode::ApplyStatusChange( CPlayer* player = this->scene->player; const int stage = value1 & 3; if (stage == 0) { - player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 735, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, AM_DELETE_EFFECT, 735, 0, 0, 0, 0, 0); } else if (stage == 1) { - player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 736, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, AM_DELETE_EFFECT, 736, 0, 0, 0, 0, 0); } else if (stage == 2) { - player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 737, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, AM_DELETE_EFFECT, 737, 0, 0, 0, 0, 0); } else if (stage == 3) { - player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 738, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, AM_DELETE_EFFECT, 738, 0, 0, 0, 0, 0); } } std::sprintf(message, ""); @@ -6249,19 +6243,19 @@ void CGameMode::ApplyStatusChange( break; case EFST_SIREN: if (aid == g_session.m_aid) { - this->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 879, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 879, 0, 0, 0, 0, 0); } std::sprintf(message, ""); break; case EFST_DEEP_SLEEP: if (aid == g_session.m_aid) { - this->scene->player->SendMsg(nullptr, AM_DELETE_SLEEP_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_DELETE_SLEEP_EFFECT, 0, 0, 0, 0, 0, 0); } std::sprintf(message, ""); break; case EFST_NETHERWORLD: if (aid == g_session.m_aid) { - this->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 453, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_DELETE_EFFECT, 453, 0, 0, 0, 0, 0); } std::sprintf(message, ""); break; @@ -6269,7 +6263,7 @@ void CGameMode::ApplyStatusChange( if (aid == g_session.m_aid) { CPlayer* player = this->scene->player; while (player->HasId(752)) { - player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 752, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, AM_DELETE_EFFECT, 752, 0, 0, 0, 0, 0); } std::sprintf(message, ""); } @@ -6438,9 +6432,7 @@ void CGameMode::ApplyStatusChange( } if (aid == g_session.m_aid) { - this->scene->player->SendMsg( - nullptr, AM_STATUS_CHANGE, 0, type, type >> 31, on, 0, value1, value1 >> 31, value2, value2 >> 31, flag, 0, value3, value3 >> 31 - ); + this->scene->player->SendMsg(nullptr, AM_STATUS_CHANGE, type, on, value1, value2, flag, value3); } } @@ -6496,7 +6488,7 @@ __declspec(noinline) void CGameMode::ReceiveActorColorChat(const unsigned char* CRenderObject* actor = this->scene->GetGameActorByAID(*reinterpret_cast(packet + 4)); if (actor != nullptr) { const int color = *reinterpret_cast(packet + 8); - actor->SendMsg(nullptr, AM_CHAT, 0, reinterpret_cast(text), reinterpret_cast(text) >> 31, color, color >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_CHAT, reinterpret_cast(text), color, 0, 0, 0, 0); } if (g_session.m_whisperRecord != 0) { @@ -6729,7 +6721,7 @@ void CGameMode::ReceiveItemFallEntry(const unsigned char* packet) { } const int entryAddress = reinterpret_cast(&entry); - item->SendMsg(nullptr, AM_INITSTANDENTRY, 0, entryAddress, entryAddress >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + item->SendMsg(nullptr, AM_INITSTANDENTRY, entryAddress, 0, 0, 0, 0, 0); } // OFFSET: 0x00D266C0 @@ -7816,7 +7808,7 @@ void CGameMode::ReceiveActorBroadcastText(const unsigned char* data) { } if (CRenderObject* actor = this->scene->GetGameActorByAID(aid)) { const std::int64_t value = reinterpret_cast(text.data()); - actor->SendMsg(nullptr, AM_CHAT, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_CHAT, value, 0, 0, 0, 0, 0); } if (g_session.m_whisperRecord != 0) { this->WriteChatLog(text.data()); @@ -9007,7 +8999,7 @@ void CGameMode::ReceiveFeedResult(const unsigned char* data) { g_windowMgr.SendNotice(UIM_PUSHINTOCHATHISTORY2, reinterpret_cast(text.c_str()), 0x1E1EF5, 0, 0, 0); if (CRenderObject* actor = this->scene->GetGameActorByAID(*reinterpret_cast(&g_session.spAndHomunculusStats[8]))) { const int emotion = g_cashEmotionMgr->GetSpecialEmotion(CashEmotionSpecial::Sweat); - actor->SendMsg(nullptr, AM_CASH_EMOTION, 0, 0, 0, emotion, emotion >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_CASH_EMOTION, 0, emotion, 0, 0, 0, 0); } } } @@ -9036,7 +9028,7 @@ void CGameMode::ReceivePetChangeState(const unsigned char* data) { g_session.petGid = packet->aid; if (actor) { g_session.petJob = actor->GetEffectiveJob(-1); - actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, 0, 0, 0, 0, 0); actor->objectType = 7; } break; @@ -9067,7 +9059,7 @@ void CGameMode::ReceivePetChangeState(const unsigned char* data) { g_session.petHunger = packet->value; if (actor) { g_session.petJob = actor->GetEffectiveJob(-1); - actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, 0, 0, 0, 0, 0); } if (g_windowMgr.petInfoWnd) { g_windowMgr.petInfoWnd->Invalidate(); @@ -9317,10 +9309,10 @@ void CGameMode::ReceiveSkillFailure(const unsigned char* data) { break; case USESKILL_FAIL: if (packet->skillId == WL_TETRAVORTEX || packet->skillId == WL_TETRAVORTEX_FIRE || packet->skillId == WL_TETRAVORTEX_WATER || packet->skillId == WL_TETRAVORTEX_WIND || packet->skillId == WL_TETRAVORTEX_GROUND) { - this->scene->player->SendMsg(nullptr, AM_EFFECT_LOOP_COUNT, 0, 0x2DF, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->scene->player->SendMsg(nullptr, AM_EFFECT_LOOP_COUNT, 0, 0x2E0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->scene->player->SendMsg(nullptr, AM_EFFECT_LOOP_COUNT, 0, 0x2E1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->scene->player->SendMsg(nullptr, AM_EFFECT_LOOP_COUNT, 0, 0x2E2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_EFFECT_LOOP_COUNT, 0x2DF, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_EFFECT_LOOP_COUNT, 0x2E0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_EFFECT_LOOP_COUNT, 0x2E1, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_EFFECT_LOOP_COUNT, 0x2E2, 0, 0, 0, 0, 0); } if (!showMessage) { return; @@ -9642,7 +9634,7 @@ void CGameMode::ReceiveChatRoomMemberList(const unsigned char* data) { joined = true; } } - actor->SendMsg(nullptr, AM_DELETE_CHAT_TITLE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_CHAT_TITLE, 0, 0, 0, 0, 0, 0); if (joined) { const int count = static_cast(packet->length - sizeof(ChatRoomMemberListPacket)) / sizeof(ChatRoomMemberRecord); std::list> members; @@ -10075,7 +10067,7 @@ void CGameMode::ReceiveActorChat(const unsigned char* data) { g_windowMgr.SendNotice(UIM_PUSHINTOCHATHISTORY, reinterpret_cast(text.data()), 0xFFFFFF, 1, 0, 0); } if (CRenderObject* actor = this->scene->GetGameActorByAID(aid)) { - actor->SendMsg(nullptr, AM_CHAT, 0, reinterpret_cast(text.data()), reinterpret_cast(text.data()) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_CHAT, reinterpret_cast(text.data()), 0, 0, 0, 0, 0); } } if (g_session.m_whisperRecord != 0) { @@ -10101,12 +10093,12 @@ void CGameMode::ReceivePartyChat(const unsigned char* data) { const std::uint32_t aid = *reinterpret_cast(data + 4); if (aid == g_session.m_aid) { g_windowMgr.SendNotice(UIM_PUSHINTOCHATHISTORY, reinterpret_cast(text.data()), 0xC8FF, 3, 0, 0); - this->scene->player->SendMsg(nullptr, AM_CHAT, 0, reinterpret_cast(text.data()), reinterpret_cast(text.data()) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_CHAT, reinterpret_cast(text.data()), 0, 0, 0, 0, 0); } else { g_windowMgr.SendNotice(UIM_OPENCHATWND, 0, 0, 0, 0, 0); g_windowMgr.SendNotice(UIM_PUSHINTOCHATHISTORY, reinterpret_cast(text.data()), 0xC8C8FF, 3, 0, 0); if (CRenderObject* actor = this->scene->GetGameActorByAID(aid)) { - actor->SendMsg(nullptr, AM_CHAT, 0, reinterpret_cast(text.data()), reinterpret_cast(text.data()) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_CHAT, reinterpret_cast(text.data()), 0, 0, 0, 0, 0); } } if (g_session.m_whisperRecord != 0) { @@ -10172,8 +10164,8 @@ void CGameMode::ReceiveEffectNumber(const unsigned char* data) { } if (!IsAdminAccount(actor->render.accountId) || g_session.IsAdminSubMode(7)) { - actor->SendMsg(nullptr, AM_CHANGE_RANK, 0, packet->value, packet->value >> 31, packet->count, packet->count >> 31, 0, 0, 0, 0, 0, 0, 0, 0); - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x9F, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_CHANGE_RANK, packet->value, packet->count, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0x9F, 0, 0, 0, 0, 0); if (packet->count <= 10) { if (CRagEffect* effect = actor->LaunchEffect(0x9F, deltaPos, 0.0f)) { effect->SendMsg(nullptr, AM_SETCOUNT, 0, packet->count, 0, 0, 0, 0); @@ -10373,7 +10365,7 @@ void CGameMode::ReceiveActorAction( char text[256]; g_session.GetMonsterTalkText(static_cast(actor)->GetEffectiveJob(-1), 0, 0, text, sourceAid); if (std::strcmp(text, "") != 0) { - actor->SendMsg(nullptr, AM_CHAT, 0, reinterpret_cast(text), reinterpret_cast(text) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_CHAT, reinterpret_cast(text), 0, 0, 0, 0, 0); if (!g_serviceOptions.Get(114) && !g_serviceOptions.Get(148)) { g_windowMgr.SendNotice(UIM_PUSHINTOCHATHISTORY, reinterpret_cast(text), 0xFAFAFA, 0, 0, 0); } @@ -10381,7 +10373,7 @@ void CGameMode::ReceiveActorAction( } } const std::int64_t value = reinterpret_cast(&act); - actor->SendMsg(nullptr, AM_ACTION, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_ACTION, value, 0, 0, 0, 0, 0); } #pragma pack(push, 1) @@ -10407,7 +10399,7 @@ void CGameMode::ReceiveActorDisappear(const unsigned char* data) { switch (packet->type) { case CLR_OUTSIGHT: if (CRenderObject* actor = this->scene->GetGameActorByAID(packet->aid)) { - actor->SendMsg(nullptr, AM_OUTOFSIGHT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_OUTOFSIGHT, 0, 0, 0, 0, 0, 0); this->SendMsg(MM_DELETEREGISTERPOS, packet->aid, 0, 0, 0); } if (this->scene->RemoveItem(packet->aid) == true) { @@ -10423,7 +10415,7 @@ void CGameMode::ReceiveActorDisappear(const unsigned char* data) { if (packet->aid == static_cast(player->proceedTargetGid)) { player->proceedTargetGid = 0; } - actor->SendMsg(nullptr, AM_WILL_BE_DEAD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_WILL_BE_DEAD, 0, 0, 0, 0, 0, 0); const int job = actor->GetEffectiveJob(-1); if (g_session.IsMonsterClass(job) || actor->objectType == 9 || g_session.IsCompanionJob(job) || actor->GetEffectiveJob(-1) == 0x235) { @@ -10440,8 +10432,8 @@ void CGameMode::ReceiveActorDisappear(const unsigned char* data) { break; } - this->scene->player->SendMsg(nullptr, AM_CANCELATTACK, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->scene->player->SendMsg(nullptr, AM_WILL_BE_DEAD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_CANCELATTACK, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_WILL_BE_DEAD, 0, 0, 0, 0, 0, 0); this->isOnQuest = 1; this->isPlayerDead = 1; g_windowMgr.CloseWindow(WID_QUITWND); @@ -11224,11 +11216,11 @@ void LaunchSkillCastEffect(CGameMode* mode, CGameActor* source, CGameActor* targ return; } - scope->SendMsg(nullptr, AM_SETMASTERGID, 0, source->render.accountId, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - scope->SendMsg(nullptr, AM_SETPOS, 0, column, column >> 31, row, row >> 31, 0, 0, 0, 0, 0, 0, 0, 0); - scope->SendMsg(nullptr, AM_SETTIME, 0, timeGetTime() + delay, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + scope->SendMsg(nullptr, AM_SETMASTERGID, static_cast(source->render.accountId), 0, 0, 0, 0, 0); + scope->SendMsg(nullptr, AM_SETPOS, column, row, 0, 0, 0, 0); + scope->SendMsg(nullptr, AM_SETTIME, static_cast(timeGetTime() + delay), 0, 0, 0, 0, 0); const int id = skillId; - scope->SendMsg(nullptr, AM_SET_SKILL, 0, id, id >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + scope->SendMsg(nullptr, AM_SET_SKILL, id, 0, 0, 0, 0, 0); mode->scene->objects.push_back(scope); return; } @@ -11239,7 +11231,7 @@ void LaunchSkillCastEffect(CGameMode* mode, CGameActor* source, CGameActor* targ if (g_session.IsHirelingJob(target->GetEffectiveJob(-1)) || target->objectType == 9) { if (mode->scene->isPKZone != 0 || mode->scene->isSiegeMode != 0 || !IsSupportSkill(skillId)) { - source->SendMsg(nullptr, AM_SET_TARGET_AID, 0, target->render.accountId, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_SET_TARGET_AID, static_cast(target->render.accountId), 0, 0, 0, 0, 0); } } @@ -11256,7 +11248,7 @@ void LaunchSkillCastEffect(CGameMode* mode, CGameActor* source, CGameActor* targ } const int delayFrames = delay / 16; - target->SendMsg(nullptr, AM_MAKE_MAGIC_TARGET, 0, 0x3C, 0, delayFrames, delayFrames >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_MAKE_MAGIC_TARGET, 0x3C, delayFrames, 0, 0, 0, 0); switch (skillId) { case CR_ACIDDEMONSTRATION: @@ -11276,15 +11268,15 @@ void LaunchSkillCastEffect(CGameMode* mode, CGameActor* source, CGameActor* targ return; } case WL_JACKFROST: - target->SendMsg(nullptr, AM_DELETE_MAGIC_TARGET, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - target->SendMsg(nullptr, AM_MAKE_MAGIC_TARGET, 0, 0x5A8, 0, delayFrames, delayFrames >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_DELETE_MAGIC_TARGET, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_MAKE_MAGIC_TARGET, 0x5A8, delayFrames, 0, 0, 0, 0); return; case WL_CHAINLIGHTNING: - target->SendMsg(nullptr, AM_DELETE_MAGIC_TARGET, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_DELETE_MAGIC_TARGET, 0, 0, 0, 0, 0, 0); g_effectMgr->Spawn(target->render.accountId, 0x665, vector3d{0.0f, 0.0f, 0.0f}, 0, -1, 0, 0); return; case RA_AIMEDBOLT: - target->SendMsg(nullptr, AM_DELETE_MAGIC_TARGET, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_DELETE_MAGIC_TARGET, 0, 0, 0, 0, 0, 0); effect = g_effectMgr->Spawn(target->render.accountId, 0x673, vector3d{0.0f, 0.0f, 0.0f}, 0, -1, 0, 0); if (effect) { effect->SetLifeTime(delay); @@ -11417,10 +11409,10 @@ void ApplyActorSkillState(CGameActor* actor, std::uint16_t skillId, int duration actor->LaunchEffect(0x192, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; case WL_TETRAVORTEX: - actor->SendMsg(nullptr, AM_EFFECT_LOOP_COUNT, 0, 0x2DF, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0); - actor->SendMsg(nullptr, AM_EFFECT_LOOP_COUNT, 0, 0x2E1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0); - actor->SendMsg(nullptr, AM_EFFECT_LOOP_COUNT, 0, 0x2E0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0); - actor->SendMsg(nullptr, AM_EFFECT_LOOP_COUNT, 0, 0x2E2, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_EFFECT_LOOP_COUNT, 0x2DF, 1, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_EFFECT_LOOP_COUNT, 0x2E1, 1, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_EFFECT_LOOP_COUNT, 0x2E0, 1, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_EFFECT_LOOP_COUNT, 0x2E2, 1, 0, 0, 0, 0); break; case ABC_CHAIN_REACTION_SHOT: actor->SetFrameSequence(88, 0, 0, 88, 0, 0, 0, 0); @@ -11480,7 +11472,7 @@ void CGameMode::NotifySkillCasting( source->SetState(motion, 1); if (skillId != 0x3E && skillId != 0x39 && delay != 0) { - source->SendMsg(nullptr, AM_MAKE_SKILL_RECHARGEGAGE, 0, delay, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_MAKE_SKILL_RECHARGEGAGE, static_cast(delay), 0, 0, 0, 0, 0); } LaunchSkillActorEffect(source, x, y, skillId, delay, effectId); @@ -11951,14 +11943,14 @@ void CGameMode::SpawnStandingPc( CGameActor* actor = static_cast(this->scene->GetGameActorByAID(aid)); if (actor) { const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_STANDENTRY2, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY2, value, 0, 0, 0, 0, 0); } else { CPc* pc = new CPc; this->scene->objects.push_back(pc); this->scene->actors.push_back(pc); actor = pc; const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_INITSTANDENTRY2, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY2, value, 0, 0, 0, 0, 0); } actor->storedActorEntry = 1; } @@ -11993,14 +11985,14 @@ void CGameMode::SpawnStandingPc2( CGameActor* actor = static_cast(this->scene->GetGameActorByAID(aid)); if (actor) { const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_STANDENTRY2, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY2, value, 0, 0, 0, 0, 0); } else { CPc* pc = new CPc; this->scene->objects.push_back(pc); this->scene->actors.push_back(pc); actor = pc; const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_INITSTANDENTRY2, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY2, value, 0, 0, 0, 0, 0); } actor->storedActorEntry = 1; } @@ -12044,7 +12036,7 @@ void CGameMode::SpawnMirrorActor(std::uint32_t aid, std::uint32_t owner, short x CPc* pc = new CPc; const std::int64_t value = reinterpret_cast(&entry); - pc->SendMsg(nullptr, AM_INITSTANDENTRY2, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + pc->SendMsg(nullptr, AM_INITSTANDENTRY2, value, 0, 0, 0, 0, 0); pc->objectType = 7; pc->LaunchEffect(0x3C3, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); this->scene->objects.push_back(pc); @@ -12071,7 +12063,7 @@ void CGameMode::SpawnMirrorActor(std::uint32_t aid, std::uint32_t owner, short x data.visible = 1; CSkill* skill = new CSkill(0); const std::int64_t value = reinterpret_cast(&data); - skill->SendMsg(nullptr, AM_SKILLSTANDENTRY, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SKILLSTANDENTRY, value, 0, 0, 0, 0, 0); this->scene->objects.push_back(skill); this->scene->skills.push_back(skill); } @@ -12235,9 +12227,7 @@ void CGameMode::ReceiveBroadcast(const unsigned char* packet) { } else { g_windowMgr.SendNotice(UIM_PUSHINTOCHATHISTORY, reinterpret_cast(text.empty() ? nullptr : &text[0]), 0xFF00, 1, 0, 0); char* message = text.empty() ? nullptr : &text[0]; - this->scene->player->SendMsg( - nullptr, AM_CHAT, 0, reinterpret_cast(message), reinterpret_cast(message) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 - ); + this->scene->player->SendMsg(nullptr, AM_CHAT, reinterpret_cast(message), 0, 0, 0, 0, 0); } if (g_session.m_whisperRecord != 0) { @@ -12429,7 +12419,7 @@ void CGameMode::ReceiveActorStandEntry(const unsigned char* data) { } } const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_STANDENTRY2, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY2, value, 0, 0, 0, 0, 0); if (g_session.GetSiegeMode() && entry.head != 0x2E && actor->sceneNameWindow == 0 && (g_session.IsPlayerJobId(actor->GetEffectiveJob(-1)) || g_session.IsGuardianJob(actor->GetEffectiveJob(-1)))) { this->ShowGuildEmblem(actor, packet->guildId, packet->guildVersion); @@ -12464,7 +12454,7 @@ void CGameMode::ReceiveActorStandEntry(const unsigned char* data) { this->scene->actors.push_back(actor); if (actor) { const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_INITSTANDENTRY2, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY2, value, 0, 0, 0, 0, 0); if (g_session.GetSiegeMode() && entry.head != 0x2E && actor->sceneNameWindow == 0 && (g_session.IsPlayerJobId(actor->GetEffectiveJob(-1)) || g_session.IsGuardianJob(actor->GetEffectiveJob(-1)))) { this->ShowGuildEmblem(actor, packet->guildId, packet->guildVersion); @@ -12523,7 +12513,7 @@ void CGameMode::ReceiveActorStandEntryFont(const unsigned char* data) { } } const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_STANDENTRY2, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY2, value, 0, 0, 0, 0, 0); if (g_session.GetSiegeMode() && entry.head != 0x2E && actor->sceneNameWindow == 0 && (g_session.IsPlayerJobId(actor->GetEffectiveJob(-1)) || g_session.IsGuardianJob(actor->GetEffectiveJob(-1)))) { this->ShowGuildEmblem(actor, packet->guildId, packet->guildVersion); @@ -12558,7 +12548,7 @@ void CGameMode::ReceiveActorStandEntryFont(const unsigned char* data) { this->scene->actors.push_back(actor); if (actor) { const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_INITSTANDENTRY2, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY2, value, 0, 0, 0, 0, 0); if (g_session.GetSiegeMode() && entry.head != 0x2E && actor->sceneNameWindow == 0 && (g_session.IsPlayerJobId(actor->GetEffectiveJob(-1)) || g_session.IsGuardianJob(actor->GetEffectiveJob(-1)))) { this->ShowGuildEmblem(actor, packet->guildId, packet->guildVersion); @@ -12626,7 +12616,7 @@ void CGameMode::ReceiveActorTypedEntry(const unsigned char* data) { } } const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_STANDENTRY, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY, value, 0, 0, 0, 0, 0); if (g_session.GetSiegeMode() && packet->objectType != 7 && actor->sceneNameWindow == 0 && (g_session.IsPlayerJobId(actor->GetEffectiveJob(-1)) || g_session.IsGuardianJob(actor->GetEffectiveJob(-1)))) { this->ShowGuildEmblem(actor, packet->guildId, packet->guildVersion); @@ -12662,7 +12652,7 @@ void CGameMode::ReceiveActorTypedEntry(const unsigned char* data) { this->scene->actors.push_back(actor); if (actor) { const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_INITSTANDENTRY, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY, value, 0, 0, 0, 0, 0); if (g_session.GetSiegeMode() && packet->objectType != 7 && actor->sceneNameWindow == 0 && (g_session.IsPlayerJobId(actor->GetEffectiveJob(-1)) || g_session.IsGuardianJob(actor->GetEffectiveJob(-1)))) { this->ShowGuildEmblem(actor, packet->guildId, packet->guildVersion); @@ -12712,7 +12702,7 @@ void CGameMode::ReceiveNpcStandEntry(const unsigned char* data) { CGameActor* actor = static_cast(this->scene->GetGameActorByAID(entry.aid)); if (actor) { const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_STANDENTRY, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY, value, 0, 0, 0, 0, 0); const int actorJob = actor->GetEffectiveJob(-1); if ((actorJob > JT_WARPNPC && actorJob < 1000) || (actorJob > 1000 && actorJob < 3999) || static_cast(actorJob - 20021) <= 11978) { const std::uint32_t guildId = (packet->accessory2 << 16) | packet->accessory3; @@ -12729,7 +12719,7 @@ void CGameMode::ReceiveNpcStandEntry(const unsigned char* data) { this->scene->objects.push_back(actor); this->scene->actors.push_back(actor); const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_INITSTANDENTRY, 0, static_cast(value), static_cast(value >> 32), 1, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY, value, 1, 0, 0, 0, 0); const int actorJob = actor->GetEffectiveJob(-1); if ((actorJob > JT_WARPNPC && actorJob < 1000) || (actorJob > 1000 && actorJob < 3999) || static_cast(actorJob - 20021) <= 11978) { const std::uint32_t guildId = (packet->accessory2 << 16) | packet->accessory3; @@ -12944,7 +12934,7 @@ void CGameMode::ReceiveActorMoveEntryLegacy(const unsigned char* data) { member->second.y = entry.dstY; } } - actor->SendMsg(nullptr, AM_MOVEENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MOVEENTRY2, reinterpret_cast(&entry), 0, 0, 0, 0, 0); } else { CGameActor* created; if (packet->objectType == 0) { @@ -12968,7 +12958,7 @@ void CGameMode::ReceiveActorMoveEntryLegacy(const unsigned char* data) { entry.appearanceVariant = 0; } g_championMonsterMgr->ApplyEffects(entry.job, actor, entry.aid); - actor->SendMsg(nullptr, AM_INITMOVEENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITMOVEENTRY2, reinterpret_cast(&entry), 0, 0, 0, 0, 0); } std::int64_t bossFlag = 0; @@ -13002,15 +12992,12 @@ void CGameMode::ReceiveActorMoveEntryLegacy(const unsigned char* data) { case NPC_ELEMENTAL_TYPE: { const std::int64_t hp = packet->hp; const std::int64_t maxHp = packet->maxHp; - actor->SendMsg( - nullptr, AM_UPDATE_MONSTER_GAGE, 0, static_cast(hp), static_cast(hp >> 32), static_cast(maxHp), static_cast(maxHp >> 32), - static_cast(bossFlag), static_cast(bossFlag >> 32), 0, 0, 0, 0, 0, 0 - ); + actor->SendMsg(nullptr, AM_UPDATE_MONSTER_GAGE, hp, maxHp, bossFlag, 0, 0, 0); break; } case NPC_ABR_TYPE: case NPC_BIONIC_TYPE: - actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, packet->aid, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_UPDATEGAGE, packet->aid, 0, 0, 0, 0, 0); break; } @@ -13078,7 +13065,7 @@ void CGameMode::SpawnMovingActor( member->second.y = entry.dstY; } } - actor->SendMsg(nullptr, AM_MOVEENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MOVEENTRY2, reinterpret_cast(&entry), 0, 0, 0, 0, 0); } else { CGameActor* created; if (objectType == 0) { @@ -13101,7 +13088,7 @@ void CGameMode::SpawnMovingActor( } else if (!((objectType == 1 || objectType == 6 || objectType == 12) && IsPlayerJob(job))) { entry.appearanceVariant = 0; } - actor->SendMsg(nullptr, AM_INITMOVEENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITMOVEENTRY2, reinterpret_cast(&entry), 0, 0, 0, 0, 0); } g_championMonsterMgr->ApplyEffects(entry.job, actor, entry.aid); @@ -13136,15 +13123,12 @@ void CGameMode::SpawnMovingActor( case NPC_ELEMENTAL_TYPE: { const std::int64_t currentHp = hp; const std::int64_t currentMaxHp = maxHp; - actor->SendMsg( - nullptr, AM_UPDATE_MONSTER_GAGE, 0, static_cast(currentHp), static_cast(currentHp >> 32), static_cast(currentMaxHp), - static_cast(currentMaxHp >> 32), static_cast(bossFlag), static_cast(bossFlag >> 32), 0, 0, 0, 0, 0, 0 - ); + actor->SendMsg(nullptr, AM_UPDATE_MONSTER_GAGE, currentHp, currentMaxHp, bossFlag, 0, 0, 0); break; } case NPC_ABR_TYPE: case NPC_BIONIC_TYPE: - actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, gid, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_UPDATEGAGE, gid, 0, 0, 0, 0, 0); break; } @@ -13224,7 +13208,7 @@ void CGameMode::ReceiveActorMoveEntryOld(const unsigned char* data) { CGameActor* actor = static_cast(this->scene->GetGameActorByAID(packet->aid)); if (actor) { const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_MOVEENTRY2, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MOVEENTRY2, value, 0, 0, 0, 0, 0); if (entry.head == 0x2E) { if (g_session.petGid == packet->aid) { g_session.petAccessory = entry.accessory; @@ -13275,7 +13259,7 @@ void CGameMode::ReceiveActorMoveEntryOld(const unsigned char* data) { this->scene->objects.push_back(actor); this->scene->actors.push_back(actor); const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_INITMOVEENTRY2, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITMOVEENTRY2, value, 0, 0, 0, 0, 0); if (g_session.GetSiegeMode() && entry.head != 0x2E && actor->sceneNameWindow == 0 && (g_session.IsPlayerJobId(actor->GetEffectiveJob(-1)) || g_session.IsGuardianJob(actor->GetEffectiveJob(-1)))) { this->ShowGuildEmblem(actor, packet->guildId, packet->guildVersion); @@ -13358,7 +13342,7 @@ void CGameMode::ReceiveActorMoveEntryOld2(const unsigned char* data) { if (actor) { actor->characterLevel = packet->level; const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_MOVEENTRY2, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MOVEENTRY2, value, 0, 0, 0, 0, 0); if (packet->objectType == 7) { if (g_session.petGid == packet->aid) { g_session.petAccessory = entry.accessory; @@ -13412,7 +13396,7 @@ void CGameMode::ReceiveActorMoveEntryOld2(const unsigned char* data) { this->scene->objects.push_back(actor); this->scene->actors.push_back(actor); const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_INITMOVEENTRY2, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITMOVEENTRY2, value, 0, 0, 0, 0, 0); if (g_session.GetSiegeMode() && packet->objectType == 7 && actor->sceneNameWindow == 0 && (g_session.IsPlayerJobId(actor->GetEffectiveJob(-1)) || g_session.IsGuardianJob(actor->GetEffectiveJob(-1)))) { this->ShowGuildEmblem(actor, packet->guildId, packet->guildVersion); @@ -13505,7 +13489,7 @@ void CGameMode::ReceiveActorMoveEntryNamed(const unsigned char* data) { if (actor) { actor->characterLevel = packet->level; *reinterpret_cast(actor->render.fontSequenceBytes) = packet->font; - actor->SendMsg(nullptr, AM_MOVEENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MOVEENTRY2, reinterpret_cast(&entry), 0, 0, 0, 0, 0); if (packet->objectType == 7) { if (g_session.petGid == packet->aid) { g_session.petAccessory = entry.accessory; @@ -13557,7 +13541,7 @@ void CGameMode::ReceiveActorMoveEntryNamed(const unsigned char* data) { actor->objectType = packet->objectType; this->scene->objects.push_back(actor); this->scene->actors.push_back(actor); - actor->SendMsg(nullptr, AM_INITMOVEENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITMOVEENTRY2, reinterpret_cast(&entry), 0, 0, 0, 0, 0); *reinterpret_cast(actor->render.fontSequenceBytes) = packet->font; actor->characterLevel = packet->level; if (g_session.GetSiegeMode() && packet->objectType == 7 && actor->sceneNameWindow == 0 && @@ -13640,7 +13624,7 @@ void CGameMode::ReceiveActorMoveEntryOld0(const unsigned char* data) { CGameActor* actor = static_cast(this->scene->GetGameActorByAID(packet->aid)); if (actor) { - actor->SendMsg(nullptr, AM_MOVEENTRY, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MOVEENTRY, reinterpret_cast(&entry), 0, 0, 0, 0, 0); const int actorJob = actor->GetEffectiveJob(-1); if ((actorJob > 45 && actorJob < 1000) || (actorJob > 1000 && actorJob < 3999) || static_cast(actorJob - 20021) <= 11978) { const std::uint32_t emblem = (packet->accessory2 << 16) | packet->accessory3; @@ -13681,7 +13665,7 @@ void CGameMode::ReceiveActorMoveEntryOld0(const unsigned char* data) { } this->scene->objects.push_back(actor); this->scene->actors.push_back(actor); - actor->SendMsg(nullptr, AM_INITMOVEENTRY, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITMOVEENTRY, reinterpret_cast(&entry), 0, 0, 0, 0, 0); const int actorJob = actor->GetEffectiveJob(-1); if ((actorJob > 45 && actorJob < 1000) || (actorJob > 1000 && actorJob < 3999) || static_cast(actorJob - 20021) <= 11978) { const std::uint32_t emblem = (packet->accessory2 << 16) | packet->accessory3; @@ -13940,10 +13924,10 @@ void CGameMode::ReceiveActorStandEntryLegacy(const unsigned char* data) { if (actor) { if (packet->objectType == 0) { const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_STANDENTRY2, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY2, value, 0, 0, 0, 0, 0); } else { const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_STANDENTRY, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY, value, 0, 0, 0, 0, 0); } } else { CGameActor* created; @@ -13965,11 +13949,11 @@ void CGameMode::ReceiveActorStandEntryLegacy(const unsigned char* data) { actor->SetGroupMemberVisible(1); } const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_INITSTANDENTRY2, 0, static_cast(value), static_cast(value >> 32), 2, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY2, value, 2, 0, 0, 0, 0); } else { entry.appearanceVariant = 0; const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_INITSTANDENTRY, 0, static_cast(value), static_cast(value >> 32), 1, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY, value, 1, 0, 0, 0, 0); } g_championMonsterMgr->ApplyEffects(entry.job, actor, entry.aid); } @@ -14005,15 +13989,12 @@ void CGameMode::ReceiveActorStandEntryLegacy(const unsigned char* data) { case NPC_ELEMENTAL_TYPE: { const std::int64_t hp = packet->hp; const std::int64_t maxHp = packet->maxHp; - actor->SendMsg( - nullptr, AM_UPDATE_MONSTER_GAGE, 0, static_cast(hp), static_cast(hp >> 32), static_cast(maxHp), static_cast(maxHp >> 32), - static_cast(bossFlag), static_cast(bossFlag >> 32), 0, 0, 0, 0, 0, 0 - ); + actor->SendMsg(nullptr, AM_UPDATE_MONSTER_GAGE, hp, maxHp, bossFlag, 0, 0, 0); break; } case NPC_ABR_TYPE: case NPC_BIONIC_TYPE: - actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, packet->aid, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_UPDATEGAGE, packet->aid, 0, 0, 0, 0, 0); break; } @@ -14125,7 +14106,7 @@ void CGameMode::ReceiveActorStandEntryNamedOld(const unsigned char* data) { *reinterpret_cast(actor->render.fontSequenceBytes) = packet->font; if (created) { const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_INITSTANDENTRY2, 0, static_cast(value), static_cast(value >> 32), 2, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY2, value, 2, 0, 0, 0, 0); if (this->partyPosList.find(packet->aid) != this->partyPosList.end() || this->guildPosList.find(packet->aid) != this->guildPosList.end()) { actor->SetGroupMemberVisible(1); } @@ -14133,7 +14114,7 @@ void CGameMode::ReceiveActorStandEntryNamedOld(const unsigned char* data) { this->scene->actors.push_back(actor); } else { const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_STANDENTRY2, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY2, value, 0, 0, 0, 0, 0); } if (g_session.GetSiegeMode() && actor->sceneNameWindow == 0) { this->ShowGuildEmblem(actor, packet->guildId, packet->guildVersion); @@ -14156,10 +14137,10 @@ void CGameMode::ReceiveActorStandEntryNamedOld(const unsigned char* data) { this->scene->objects.push_back(actor); this->scene->actors.push_back(actor); const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_INITSTANDENTRY, 0, static_cast(value), static_cast(value >> 32), 1, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY, value, 1, 0, 0, 0, 0); } else { const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_STANDENTRY, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY, value, 0, 0, 0, 0, 0); } if (g_session.IsGuardianJob(packet->job) && g_session.GetSiegeMode() && actor->sceneNameWindow == 0) { this->ShowGuildEmblem(actor, packet->guildId, packet->guildVersion); @@ -14254,7 +14235,7 @@ void CGameMode::ReceiveActorStandEntryOld(const unsigned char* data) { actor->SetActionName(ResourceMgr::Instance(), g_session.GetPetAccActName(entry.accessory)); } } - actor->SendMsg(nullptr, AM_STANDENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY2, reinterpret_cast(&entry), 0, 0, 0, 0, 0); if (g_session.GetSiegeMode() && entry.head != 0x2E && actor->sceneNameWindow == 0 && (g_session.IsPlayerJobId(actor->GetEffectiveJob(-1)) || g_session.IsGuardianJob(actor->GetEffectiveJob(-1)))) { this->ShowGuildEmblem(actor, packet->guildId, packet->guildVersion); @@ -14286,7 +14267,7 @@ void CGameMode::ReceiveActorStandEntryOld(const unsigned char* data) { } this->scene->objects.push_back(actor); this->scene->actors.push_back(actor); - actor->SendMsg(nullptr, AM_INITSTANDENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY2, reinterpret_cast(&entry), 2, 0, 0, 0, 0); if (isPc && !IsAdminAccount(packet->aid) && !StateFlag06(packet->effectState)) { actor->LaunchEffect(0x158, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } @@ -14378,7 +14359,7 @@ void CGameMode::ReceiveActorStandEntryOld2(const unsigned char* data) { actor->SetActionName(ResourceMgr::Instance(), g_session.GetPetAccActName(entry.accessory)); } } - actor->SendMsg(nullptr, AM_STANDENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY2, reinterpret_cast(&entry), 0, 0, 0, 0, 0); actor->characterLevel = packet->level; if (g_session.GetSiegeMode() && entry.head != 0x2E && actor->sceneNameWindow == 0 && (g_session.IsPlayerJobId(actor->GetEffectiveJob(-1)) || g_session.IsGuardianJob(actor->GetEffectiveJob(-1)))) { @@ -14411,7 +14392,7 @@ void CGameMode::ReceiveActorStandEntryOld2(const unsigned char* data) { } this->scene->objects.push_back(actor); this->scene->actors.push_back(actor); - actor->SendMsg(nullptr, AM_INITSTANDENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY2, reinterpret_cast(&entry), 2, 0, 0, 0, 0); actor->characterLevel = packet->level; if (isPc && !IsAdminAccount(packet->aid) && !StateFlag06(packet->effectState)) { actor->LaunchEffect(0x158, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -14507,7 +14488,7 @@ void CGameMode::ReceiveActorStandEntryOld3(const unsigned char* data) { actor->SetActionName(ResourceMgr::Instance(), g_session.GetPetAccActName(entry.accessory)); } } - actor->SendMsg(nullptr, AM_STANDENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY2, reinterpret_cast(&entry), 0, 0, 0, 0, 0); if (g_session.GetSiegeMode() && entry.head != 0x2E && actor->sceneNameWindow == 0 && (g_session.IsPlayerJobId(actor->GetEffectiveJob(-1)) || g_session.IsGuardianJob(actor->GetEffectiveJob(-1)))) { this->ShowGuildEmblem(actor, packet->guildId, packet->guildVersion); @@ -14539,7 +14520,7 @@ void CGameMode::ReceiveActorStandEntryOld3(const unsigned char* data) { } this->scene->objects.push_back(actor); this->scene->actors.push_back(actor); - actor->SendMsg(nullptr, AM_INITSTANDENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY2, reinterpret_cast(&entry), 2, 0, 0, 0, 0); actor->characterLevel = packet->level; if (isPc) { *reinterpret_cast(actor->render.fontSequenceBytes) = packet->font; @@ -14642,7 +14623,7 @@ void CGameMode::ReceiveActorStandEntryOld0(const unsigned char* data) { actor->SetActionName(g_session.GetPetAccActName(entry.accessory)); } } - actor->SendMsg(nullptr, AM_STANDENTRY, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY, reinterpret_cast(&entry), 0, 0, 0, 0, 0); } else { int isPc = 0; const short job = packet->job; @@ -14670,7 +14651,7 @@ void CGameMode::ReceiveActorStandEntryOld0(const unsigned char* data) { } this->scene->objects.push_back(actor); this->scene->actors.push_back(actor); - actor->SendMsg(nullptr, AM_INITSTANDENTRY, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY, reinterpret_cast(&entry), 2, 0, 0, 0, 0); const int actorJob = actor->GetEffectiveJob(-1); if ((actorJob >= 45 && actorJob < 1000) || (actorJob > 1000 && actorJob < 3999) || static_cast(actorJob - 20021) <= 11978) { const std::uint32_t emblem = (packet->accessory2 << 16) | packet->accessory3; @@ -14790,13 +14771,13 @@ void CGameMode::ReceiveActorStateEntryNamedOld(const unsigned char* data) { actor->characterLevel = packet->level; if (created) { const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_INITSTANDENTRY2, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY2, value, 0, 0, 0, 0, 0); if (this->partyPosList.find(packet->aid) != this->partyPosList.end() || this->guildPosList.find(packet->aid) != this->guildPosList.end()) { actor->SetGroupMemberVisible(1); } } else { const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_STANDENTRY2, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY2, value, 0, 0, 0, 0, 0); } if (g_session.GetSiegeMode() && actor->sceneNameWindow == 0) { this->ShowGuildEmblem(actor, packet->guildId, packet->guildVersion); @@ -14817,10 +14798,10 @@ void CGameMode::ReceiveActorStateEntryNamedOld(const unsigned char* data) { if (created) { const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_INITSTANDENTRY, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY, value, 0, 0, 0, 0, 0); } else { const std::int64_t value = reinterpret_cast(&entry); - actor->SendMsg(nullptr, AM_STANDENTRY, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY, value, 0, 0, 0, 0, 0); } if (g_session.IsGuardianJob(packet->job) && g_session.GetSiegeMode() && actor->sceneNameWindow == 0) { this->ShowGuildEmblem(actor, packet->guildId, packet->guildVersion); @@ -14920,7 +14901,7 @@ void CGameMode::ReceiveActorStateEntryOld(const unsigned char* data) { actor->SetActionName(g_session.GetPetAccActName(entry.accessory)); } } - actor->SendMsg(nullptr, AM_STANDENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY2, reinterpret_cast(&entry), 0, 0, 0, 0, 0); if (g_session.GetSiegeMode() && entry.head != 0x2E && actor->sceneNameWindow == 0 && (g_session.IsPlayerJobId(actor->GetEffectiveJob(-1)) || g_session.IsGuardianJob(actor->GetEffectiveJob(-1)))) { this->ShowGuildEmblem(actor, packet->guildId, packet->guildVersion); @@ -14951,7 +14932,7 @@ void CGameMode::ReceiveActorStateEntryOld(const unsigned char* data) { this->scene->objects.push_back(actor); this->scene->actors.push_back(actor); if (actor) { - actor->SendMsg(nullptr, AM_INITSTANDENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY2, reinterpret_cast(&entry), 0, 0, 0, 0, 0); if (g_session.GetSiegeMode() && entry.head != 0x2E && actor->sceneNameWindow == 0 && (g_session.IsPlayerJobId(actor->GetEffectiveJob(-1)) || g_session.IsGuardianJob(actor->GetEffectiveJob(-1)))) { this->ShowGuildEmblem(actor, packet->guildId, packet->guildVersion); @@ -15019,9 +15000,9 @@ void CGameMode::SpawnStandingActor( CGameActor* actor = static_cast(this->scene->GetGameActorByAID(entry.aid)); if (actor) { if (objectType == 0) { - actor->SendMsg(nullptr, AM_STANDENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY2, reinterpret_cast(&entry), 0, 0, 0, 0, 0); } else { - actor->SendMsg(nullptr, AM_STANDENTRY, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY, reinterpret_cast(&entry), 0, 0, 0, 0, 0); } } else { CGameActor* created; @@ -15042,12 +15023,12 @@ void CGameMode::SpawnStandingActor( if (this->partyPosList.find(aid) != this->partyPosList.end() || this->guildPosList.find(aid) != this->guildPosList.end()) { actor->SetGroupMemberVisible(1); } - actor->SendMsg(nullptr, AM_INITSTANDENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY2, reinterpret_cast(&entry), 2, 0, 0, 0, 0); } else { if (!((objectType == 1 || objectType == 6 || objectType == 5) && IsPlayerJob(job))) { entry.appearanceVariant = 0; } - actor->SendMsg(nullptr, AM_INITSTANDENTRY, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY, reinterpret_cast(&entry), 1, 0, 0, 0, 0); } g_championMonsterMgr->ApplyEffects(entry.job, actor, entry.aid); } @@ -15083,15 +15064,12 @@ void CGameMode::SpawnStandingActor( case NPC_ELEMENTAL_TYPE: { const std::int64_t currentHp = hp; const std::int64_t currentMaxHp = maxHp; - actor->SendMsg( - nullptr, AM_UPDATE_MONSTER_GAGE, 0, static_cast(currentHp), static_cast(currentHp >> 32), static_cast(currentMaxHp), - static_cast(currentMaxHp >> 32), static_cast(bossFlag), static_cast(bossFlag >> 32), 0, 0, 0, 0, 0, 0 - ); + actor->SendMsg(nullptr, AM_UPDATE_MONSTER_GAGE, currentHp, currentMaxHp, bossFlag, 0, 0, 0); break; } case NPC_ABR_TYPE: case NPC_BIONIC_TYPE: - actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, gid, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_UPDATEGAGE, gid, 0, 0, 0, 0, 0); break; } @@ -15295,9 +15273,9 @@ void CGameMode::SpawnStateActor( CGameActor* actor = static_cast(this->scene->GetGameActorByAID(entry.aid)); if (actor) { if (objectType == 0) { - actor->SendMsg(nullptr, AM_STANDENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY2, reinterpret_cast(&entry), 0, 0, 0, 0, 0); } else { - actor->SendMsg(nullptr, AM_STANDENTRY, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY, reinterpret_cast(&entry), 0, 0, 0, 0, 0); } } else { CGameActor* created; @@ -15318,14 +15296,14 @@ void CGameMode::SpawnStateActor( if (this->partyPosList.find(aid) != this->partyPosList.end() || this->guildPosList.find(aid) != this->guildPosList.end()) { actor->SetGroupMemberVisible(1); } - actor->SendMsg(nullptr, AM_INITSTANDENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY2, reinterpret_cast(&entry), 0, 0, 0, 0, 0); } else { if ((objectType == 1 || objectType == 6 || objectType == 12) && IsPlayerJob(job)) { entry.bodyCostume = job; } else { entry.appearanceVariant = 0; } - actor->SendMsg(nullptr, AM_INITSTANDENTRY, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY, reinterpret_cast(&entry), 0, 0, 0, 0, 0); } g_championMonsterMgr->ApplyEffects(entry.job, actor, entry.aid); } @@ -15361,15 +15339,12 @@ void CGameMode::SpawnStateActor( case NPC_ELEMENTAL_TYPE: { const std::int64_t currentHp = hp; const std::int64_t currentMaxHp = maxHp; - actor->SendMsg( - nullptr, AM_UPDATE_MONSTER_GAGE, 0, static_cast(currentHp), static_cast(currentHp >> 32), static_cast(currentMaxHp), - static_cast(currentMaxHp >> 32), static_cast(bossFlag), static_cast(bossFlag >> 32), 0, 0, 0, 0, 0, 0 - ); + actor->SendMsg(nullptr, AM_UPDATE_MONSTER_GAGE, currentHp, currentMaxHp, bossFlag, 0, 0, 0); break; } case NPC_ABR_TYPE: case NPC_BIONIC_TYPE: - actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, gid, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_UPDATEGAGE, gid, 0, 0, 0, 0, 0); break; } @@ -15718,9 +15693,9 @@ void CGameMode::ReceiveActorStateEntryLegacy(const unsigned char* data) { CGameActor* actor = static_cast(this->scene->GetGameActorByAID(entry.aid)); if (actor) { if (packet->objectType == 0) { - actor->SendMsg(nullptr, AM_STANDENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY2, reinterpret_cast(&entry), 0, 0, 0, 0, 0); } else { - actor->SendMsg(nullptr, AM_STANDENTRY, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_STANDENTRY, reinterpret_cast(&entry), 0, 0, 0, 0, 0); } } else { CGameActor* created; @@ -15741,10 +15716,10 @@ void CGameMode::ReceiveActorStateEntryLegacy(const unsigned char* data) { if (this->partyPosList.find(packet->aid) != this->partyPosList.end() || this->guildPosList.find(packet->aid) != this->guildPosList.end()) { actor->SetGroupMemberVisible(1); } - actor->SendMsg(nullptr, AM_INITSTANDENTRY2, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY2, reinterpret_cast(&entry), 0, 0, 0, 0, 0); } else { entry.appearanceVariant = 0; - actor->SendMsg(nullptr, AM_INITSTANDENTRY, 0, reinterpret_cast(&entry), reinterpret_cast(&entry) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_INITSTANDENTRY, reinterpret_cast(&entry), 0, 0, 0, 0, 0); } g_championMonsterMgr->ApplyEffects(entry.job, actor, entry.aid); } @@ -15780,15 +15755,12 @@ void CGameMode::ReceiveActorStateEntryLegacy(const unsigned char* data) { case NPC_ELEMENTAL_TYPE: { const std::int64_t hp = packet->hp; const std::int64_t maxHp = packet->maxHp; - actor->SendMsg( - nullptr, AM_UPDATE_MONSTER_GAGE, 0, static_cast(hp), static_cast(hp >> 32), static_cast(maxHp), static_cast(maxHp >> 32), - static_cast(bossFlag), static_cast(bossFlag >> 32), 0, 0, 0, 0, 0, 0 - ); + actor->SendMsg(nullptr, AM_UPDATE_MONSTER_GAGE, hp, maxHp, bossFlag, 0, 0, 0); break; } case NPC_ABR_TYPE: case NPC_BIONIC_TYPE: - actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, packet->aid, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_UPDATEGAGE, static_cast(packet->aid), 0, 0, 0, 0, 0); break; } @@ -16032,7 +16004,7 @@ void LaunchSkillActorEffect(CGameActor* actor, short x, short y, std::uint16_t s g_effectMgr->Spawn(actor->render.accountId, effectId, actor->render.position, 0, -1, 0, 0); } else { const int delayFrames = delay / 16; - actor->SendMsg(nullptr, AM_MAKE_BEGIN_SPELL, 0, effectId, effectId >> 31, delayFrames, delayFrames >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MAKE_BEGIN_SPELL, effectId, delayFrames, 0, 0, 0, 0); } CEffect* effect; @@ -16596,11 +16568,11 @@ void LaunchSkillActorEffect(CGameActor* actor, short x, short y, std::uint16_t s int column; int row; static_cast(g_modeMgr.GetGameMode())->WorldCell(actor->render.position.x, actor->render.position.z, column, row); - scope->SendMsg(nullptr, AM_SETMASTERGID, 0, actor->render.accountId, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - scope->SendMsg(nullptr, AM_SETPOS, 0, column, column >> 31, row, row >> 31, 0, 0, 0, 0, 0, 0, 0, 0); - scope->SendMsg(nullptr, AM_SETTIME, 0, timeGetTime() + delay, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + scope->SendMsg(nullptr, AM_SETMASTERGID, static_cast(actor->render.accountId), 0, 0, 0, 0, 0); + scope->SendMsg(nullptr, AM_SETPOS, column, row, 0, 0, 0, 0); + scope->SendMsg(nullptr, AM_SETTIME, static_cast(timeGetTime() + delay), 0, 0, 0, 0, 0); const int id = skillId; - scope->SendMsg(nullptr, AM_SET_SKILL, 0, id, id >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + scope->SendMsg(nullptr, AM_SET_SKILL, id, 0, 0, 0, 0, 0); static_cast(g_modeMgr.GetGameMode())->scene->objects.push_back(scope); return; } @@ -16855,7 +16827,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t source->SetState(7, motion); } else { if (motion == 2 || motion == 9) { - source->SendMsg(nullptr, AM_SET_TARGET_AID, 0, targetAid, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_SET_TARGET_AID, targetAid, 0, 0, 0, 0, 0); if (CSkillActionMgr::GetInstance()->SuppressSupportSkillArrow(skillId)) { source->SetArrowEffectSuppressed(true); } @@ -16986,16 +16958,16 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t case KN_TWOHANDQUICKEN: case KN_ONEHAND: if (source != nullptr) { - source->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_DELETE_EFFECT, 0x82, 0, 0, 0, 0, 0); source->LaunchEffect(0x82, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; case KN_AUTOCOUNTER: if (source != nullptr) { - source->SendMsg(nullptr, AM_MAKE_SKILL_RECHARGEGAGE, 0, level * 400, (level * 400) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_MAKE_SKILL_RECHARGEGAGE, level * 400, 0, 0, 0, 0, 0); source->SetState(13, 1); if (sourceAid != g_session.m_aid) { - source->SendMsg(nullptr, AM_DELETE_SKILL_RECHARGEGAGE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_DELETE_SKILL_RECHARGEGAGE, 0, 0, 0, 0, 0, 0); } } break; @@ -17047,7 +17019,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t static_cast(skill)->LaunchEffect(0x6F, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); if (source->statusEffects[0] != 0) { const int address = reinterpret_cast(&skill->render.position); - reinterpret_cast(source->statusEffects[0])->SendMsg(nullptr, AM_REQ_ATTACK, 0, address, address >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + reinterpret_cast(source->statusEffects[0])->SendMsg(nullptr, AM_REQ_ATTACK, address, 0, 0, 0, 0, 0); } } } @@ -17240,7 +17212,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t break; case MG_SRECOVERY: if (target != nullptr) { - target->SendMsg(nullptr, AM_MAKE_NUMBER, 0, effectLevel, effectLevel >> 31, static_cast(0xFF0000FF), 0, 0x72, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_MAKE_NUMBER, effectLevel, 0xFF0000FFu, 0x72, 0, 0, 0); } break; case CR_DEVOTION: @@ -17271,7 +17243,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t break; case CR_SPEARQUICKEN: if (source != nullptr) { - source->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0xFA, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_DELETE_EFFECT, 0xFA, 0, 0, 0, 0, 0); source->LaunchEffect(0xFA, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; @@ -17289,7 +17261,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t if (source != nullptr) { g_modeMgr.GetGameMode()->SendMsg(MM_QUAKE, 0, 0, 0, 0); g_soundMgr->PlayWave("effect\\mon_폭기.wav", 0.0f, 0.0f, 0.0f, 250, 40, 1.0f, 0); - source->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0xCB, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_DELETE_EFFECT, 0xCB, 0, 0, 0, 0, 0); source->LaunchEffect(0xCB, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); source->LaunchEffect(0x105, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); source->SetSequenceInterval(30); @@ -17313,7 +17285,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t case BS_OVERTHRUST: case WS_OVERTHRUSTMAX: if (source != nullptr) { - source->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x80, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_DELETE_EFFECT, 0x80, 0, 0, 0, 0, 0); source->LaunchEffect(0x80, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; @@ -17325,7 +17297,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t case WE_FEMALE: if (target != nullptr) { target->LaunchEffect(0xFD, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); - target->SendMsg(nullptr, AM_MAKE_NUMBER, 0, level, level >> 31, static_cast(0xFF0000FF), 0, 0x72, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_MAKE_NUMBER, level, 0xFF0000FFu, 0x72, 0, 0, 0); } break; case WE_BABY: @@ -17335,9 +17307,9 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t break; case LK_AURABLADE: if (source != nullptr) { - source->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x16F, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_DELETE_EFFECT, 0x16F, 0, 0, 0, 0, 0); source->LaunchEffect(0x16F, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); - source->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1DA, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1DA, 0, 0, 0, 0, 0); source->LaunchEffect(0x1DA, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); source->SetFrameSequence(0x20, 0, 5, 0x20, 5, 1, 1000, 0); g_soundMgr->PlayWave("effect\\오라 블레이드.wav", 0.0f, 0.0f, 0.0f, 250, 40, 1.0f, 0); @@ -17345,7 +17317,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t break; case LK_CONCENTRATION: if (source != nullptr) { - source->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x171, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_DELETE_EFFECT, 0x171, 0, 0, 0, 0, 0); source->LaunchEffect(0x171, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; @@ -17513,7 +17485,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t break; case HW_MAGICPOWER: if (target != nullptr) { - target->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x17E, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_DELETE_EFFECT, 0x17E, 0, 0, 0, 0, 0); target->LaunchEffect(0x17E, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); g_soundMgr->PlayWave("effect\\마법력 증폭.wav", 0.0f, 0.0f, 0.0f, 250, 40, 1.0f, 0); } @@ -17569,7 +17541,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t break; case ST_CHASEWALK: if (source != nullptr) { - source->SendMsg(nullptr, AM_MAKE_SMOKE_FFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_MAKE_SMOKE_FFECT, 0, 0, 0, 0, 0, 0); } break; case ST_REJECTSWORD: @@ -17630,12 +17602,12 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t if (source != nullptr) { g_soundMgr->PlayWave("effect\\T_바람방출.wav", 0.0f, 0.0f, 0.0f, 250, 40, 1.0f, 0); while (source->HasId(0x1CD)) { - source->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1CD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1CD, 0, 0, 0, 0, 0); } source->LaunchEffect(0x1CD, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); const int effectId = effectLevel + 0x1D2; while (source->HasId(effectId)) { - source->SendMsg(nullptr, AM_DELETE_EFFECT, 0, effectId, effectId >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_DELETE_EFFECT, effectId, 0, 0, 0, 0, 0); } source->LaunchEffect(effectId, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } @@ -17643,11 +17615,11 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t case TK_HIGHJUMP: if (source != nullptr) { if (source->HasId(0x1BE)) { - source->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1BE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1BE, 0, 0, 0, 0, 0); } source->LaunchEffect(0x1BE, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); while (source->HasId(0x1BD)) { - source->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1BD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1BD, 0, 0, 0, 0, 0); } } break; @@ -17655,9 +17627,9 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t case SG_MOON_WARM: case SG_STAR_WARM: if (source != nullptr && target != nullptr) { - source->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1A2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1A2, 0, 0, 0, 0, 0); source->LaunchEffect(0x1A2, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); - source->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x220, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_DELETE_EFFECT, 0x220, 0, 0, 0, 0, 0); source->LaunchEffect(0x220, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); source->LaunchEffect(0x23C, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } @@ -17666,7 +17638,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t case SG_MOON_COMFORT: case SG_STAR_COMFORT: if (source != nullptr) { - source->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1E8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1E8, 0, 0, 0, 0, 0); source->LaunchEffect(0x1E8, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); source->LaunchEffect(0x21F, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } @@ -17674,7 +17646,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t case SG_HATE: if (target != nullptr) { g_soundMgr->PlayWave("effect\\T_등록.wav", 0.0f, 0.0f, 0.0f, 250, 40, 1.0f, 0); - target->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x21F, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_DELETE_EFFECT, 0x21F, 0, 0, 0, 0, 0); target->LaunchEffect(0x21F, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; @@ -17712,7 +17684,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t case SL_KAITE: if (target != nullptr) { g_soundMgr->PlayWave("effect\\T_마법반사.wav", 0.0f, 0.0f, 0.0f, 250, 40, 1.0f, 0); - target->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1A3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1A3, 0, 0, 0, 0, 0); target->LaunchEffect(0x1A3, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); target->LaunchEffect(0x21E, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } @@ -17720,7 +17692,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t case SL_SWOO: if (target != nullptr) { g_soundMgr->PlayWave("effect\\T_슈웃.wav", 0.0f, -50.0f, 0.0f, 250, 40, 1.0f, 0); - target->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1A4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1A4, 0, 0, 0, 0, 0); target->LaunchEffect(0x1A4, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); target->LaunchEffect(0x24D, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } @@ -17728,7 +17700,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t case SL_SKE: if (target != nullptr) { g_soundMgr->PlayWave("effect\\T_공격력.wav", 0.0f, 0.0f, 0.0f, 250, 40, 1.0f, 0); - target->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1AB, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1AB, 0, 0, 0, 0, 0); target->LaunchEffect(0x1AB, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; @@ -17736,8 +17708,8 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t if (target != nullptr) { g_soundMgr->PlayWave("effect\\T_방어형.wav", 0.0f, 0.0f, 0.0f, 250, 40, 1.0f, 0); g_modeMgr.GetGameMode()->SendMsg(MM_QUAKE, 0, 0, 0, 0); - target->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0xFE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - target->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x46C, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_DELETE_EFFECT, 0xFE, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_DELETE_EFFECT, 0x46C, 0, 0, 0, 0, 0); target->LaunchEffect(0xFE, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); target->LaunchEffect(0x46C, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); target->LaunchEffect(0x105, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -17814,10 +17786,10 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t break; case MB_M_TELEPORT: if (source != nullptr) { - source->SendMsg(nullptr, AM_MAKE_SMOKE_FFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_MAKE_SMOKE_FFECT, 0, 0, 0, 0, 0, 0); } if (target != nullptr) { - target->SendMsg(nullptr, AM_MAKE_SMOKE_FFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_MAKE_SMOKE_FFECT, 0, 0, 0, 0, 0, 0); target->LaunchEffect(0x158, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; @@ -17889,7 +17861,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t if (CRagEffect* effect = target->LaunchEffect(0x1F7, vector3d{0.0f, 0.0f, 0.0f}, 0.0f)) { effect->SendMsg(nullptr, AM_SETPOS, 0, reinterpret_cast(&offset), 0, 0, 0, 0); } - target->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1A8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1A8, 0, 0, 0, 0, 0); target->LaunchEffect(0x1A8, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; @@ -18025,7 +17997,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t case DC_WINKCHARM: if (source != nullptr && target != nullptr) { const std::int64_t emotion = g_cashEmotionMgr->GetSpecialEmotion(CashEmotionSpecial::Chup); - source->SendMsg(nullptr, AM_CASH_EMOTION, 0, 0, 0, static_cast(emotion), static_cast(emotion >> 32), 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_CASH_EMOTION, 0, emotion, 0, 0, 0, 0); g_soundMgr->PlayWave("effect\\vallentine.wav", 0.0f, 0.0f, 0.0f, 250, 40, 1.0f, 0); if (CRagEffect* effect = source->LaunchEffect(0x25F, vector3d{0.0f, 0.0f, 0.0f}, 0.0f)) { vector3d position = target->render.position; @@ -18970,7 +18942,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t if (source != nullptr) { source->LaunchEffect(0x1BE, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); while (source->HasId(0x430)) { - source->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x430, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_DELETE_EFFECT, 0x430, 0, 0, 0, 0, 0); } } break; @@ -18995,7 +18967,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t source->LaunchEffect(0x1BE, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); g_effectMgr->Spawn(source->render.accountId, 0x4B3, 0.0f, 0.0f, 0.0f, 0, -1, 0, 0); while (source->HasId(0x1BD)) { - source->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1BD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1BD, 0, 0, 0, 0, 0); } } break; @@ -19031,7 +19003,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t vector3d data{0.0f, static_cast(target->render.accountId), 0.0f}; effect->SendMsg(nullptr, AM_SETPOS, 0, reinterpret_cast(&data), 0, 0, 0, 0); } - target->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1A8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1A8, 0, 0, 0, 0, 0); target->LaunchEffect(0x1A8, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); switch (skillId) { case SP_SOULGOLEM: @@ -19181,7 +19153,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t if (source != nullptr) { source->LaunchEffect(0x1BE, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); while (source->HasId(0x1BD)) { - source->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1BD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1BD, 0, 0, 0, 0, 0); } source->LaunchEffect(0x19B, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } @@ -19831,7 +19803,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t effectId = 7; } target->LaunchEffect(effectId, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); - target->SendMsg(nullptr, AM_MAKE_NUMBER, 0, level, level >> 31, static_cast(0xFF00FF00), 0, 0x72, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_MAKE_NUMBER, level, 0xFF00FF00u, 0x72, 0, 0, 0); } break; case MH_SILENT_BREEZE: @@ -19875,7 +19847,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t case MS_PARRYING: case ML_AUTOGUARD: if (source != nullptr) { - source->SendMsg(nullptr, AM_MAKE_GUARD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_MAKE_GUARD, 0, 0, 0, 0, 0, 0); } break; case CR_DEFENDER: @@ -19888,7 +19860,7 @@ void CGameMode::ReceiveSkillUse(std::uint16_t skillId, int level, std::uint32_t case LK_FURY: case MS_BERSERK: if (source != nullptr) { - source->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x170, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + source->SendMsg(nullptr, AM_DELETE_EFFECT, 0x170, 0, 0, 0, 0, 0); source->LaunchEffect(0x170, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); g_modeMgr.GetGameMode()->SendMsg(MM_QUAKE, 0, 0, 0, 0); g_soundMgr->PlayWave("effect\\버서크.wav", 0.0f, 0.0f, 0.0f, 250, 40, 1.0f, 0); @@ -21572,7 +21544,7 @@ void CGameMode::ProcessIncomingPackets() { g_session.SyncServerTime(path.tick); if (actor) { const int pathAddress = reinterpret_cast(&path); - actor->SendMsg(nullptr, AM_MOVE, 0, pathAddress, pathAddress >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MOVE, pathAddress, 0, 0, 0, 0, 0); } break; } @@ -21582,7 +21554,7 @@ void CGameMode::ProcessIncomingPackets() { DecodeSrcDst(g_gameModePacketBuffer + 6, &path.srcX, &path.srcY, &path.dstX, &path.dstY, &path.subX, &path.subY); g_session.SyncServerTime(path.tick); const int pathAddress = reinterpret_cast(&path); - this->scene->player->SendMsg(nullptr, AM_MOVE, 0, pathAddress, pathAddress >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_MOVE, pathAddress, 0, 0, 0, 0, 0); break; } case ID_ZC_STOPMOVE: { @@ -21623,7 +21595,7 @@ void CGameMode::ProcessIncomingPackets() { } } const int actAddress = reinterpret_cast(&act); - actor->SendMsg(nullptr, AM_ACTION, 0, actAddress, actAddress >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_ACTION, actAddress, 0, 0, 0, 0, 0); break; } case ID_ZC_NPCACK_ENABLE: @@ -21655,7 +21627,7 @@ void CGameMode::ProcessIncomingPackets() { } } actor->render.angle = static_cast(45 * (packet->direction + 4)); - actor->SendMsg(nullptr, AM_SET_HEAD_DIR, 0, packet->headDirection, packet->headDirection >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_SET_HEAD_DIR, packet->headDirection, 0, 0, 0, 0, 0); break; } case ID_ZC_ITEM_ENTRY: @@ -21682,7 +21654,7 @@ void CGameMode::ProcessIncomingPackets() { } const int entryAddress = reinterpret_cast(&entry); - item->SendMsg(nullptr, AM_INITSTANDENTRY, 0, entryAddress, entryAddress >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + item->SendMsg(nullptr, AM_INITSTANDENTRY, entryAddress, 0, 0, 0, 0, 0); break; } case ID_ZC_ITEM_DISAPPEAR: { @@ -21793,7 +21765,7 @@ void CGameMode::ProcessIncomingPackets() { if (item.identity[1]) { g_session.RemoveInventoryItem(packet->index, item.quantity - packet->amount); if (item.IsAboveItemId600()) { - this->scene->player->SendMsg(nullptr, AM_USEITEM_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_USEITEM_EFFECT, 0, 0, 0, 0, 0, 0); } } } @@ -21900,7 +21872,7 @@ void CGameMode::ProcessIncomingPackets() { } } const int emotion = g_gameModePacketBuffer[6]; - actor->SendMsg(nullptr, AM_CASH_EMOTION, 0, 0, 0, emotion, emotion >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_CASH_EMOTION, 0, emotion, 0, 0, 0, 0); break; } case ID_ZC_USER_COUNT: { @@ -22034,7 +22006,7 @@ void CGameMode::ProcessIncomingPackets() { case ID_ZC_DESTROY_ROOM: { const std::uint32_t roomId = *reinterpret_cast(g_gameModePacketBuffer + 2); if (CRenderObject *actor = this->scene->GetGameActorByAID(this->chatRoomActorIds[roomId])) { - actor->SendMsg(nullptr, AM_DELETE_CHAT_TITLE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_CHAT_TITLE, 0, 0, 0, 0, 0, 0); } if (g_windowMgr.chatRoomWnd && static_cast(g_windowMgr.chatRoomWnd)->roomStatus.roomId == static_cast(roomId)) { g_windowMgr.CloseWindow(WID_CHATROOMWND); @@ -22221,7 +22193,7 @@ void CGameMode::ProcessIncomingPackets() { const int hp = *reinterpret_cast(g_gameModePacketBuffer + 6); const int maxHp = *reinterpret_cast(g_gameModePacketBuffer + 8); if (CRenderObject *actor = this->scene->GetGameActorByAID(aid)) { - actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, hp, hp >> 31, maxHp, maxHp >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_UPDATEGAGE, hp, maxHp, 0, 0, 0, 0); } if (g_windowMgr.messengerGroupWnd) { g_windowMgr.messengerGroupWnd->SendMsg(nullptr, UM_COMMAND, 34, aid, hp, maxHp); @@ -22260,9 +22232,9 @@ void CGameMode::ProcessIncomingPackets() { case ID_ZC_MVP: { const std::uint32_t aid = *reinterpret_cast(g_gameModePacketBuffer + 2); if (aid == g_session.m_aid) { - this->scene->player->SendMsg(nullptr, AM_MVP, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_MVP, 0, 0, 0, 0, 0, 0); } else if (CRenderObject *actor = this->scene->GetGameActorByAID(aid)) { - actor->SendMsg(nullptr, AM_MVP, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MVP, 0, 0, 0, 0, 0, 0); } break; } @@ -22326,7 +22298,7 @@ void CGameMode::ProcessIncomingPackets() { } if (actor) { const int stateAddress = reinterpret_cast(state); - actor->SendMsg(nullptr, AM_ATTR_STATE_CHANGE, 0, stateAddress, stateAddress >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_ATTR_STATE_CHANGE, stateAddress, 0, 0, 0, 0, 0); } break; } @@ -22499,13 +22471,13 @@ void CGameMode::ProcessIncomingPackets() { title[80] = 0; if (CRenderObject *actor = this->scene->GetGameActorByAID(*reinterpret_cast(g_gameModePacketBuffer + 2))) { const int titleAddress = reinterpret_cast(title); - actor->SendMsg(nullptr, AM_MAKE_SHOP_TITLE, 0, titleAddress, titleAddress >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MAKE_SHOP_TITLE, titleAddress, 0, 0, 0, 0, 0); } break; } case ID_ZC_DISAPPEAR_ENTRY: if (CRenderObject *actor = this->scene->GetGameActorByAID(*reinterpret_cast(g_gameModePacketBuffer + 2))) { - actor->SendMsg(nullptr, AM_DELETE_SHOP_TITLE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_SHOP_TITLE, 0, 0, 0, 0, 0, 0); } break; case ID_ZC_DELETEITEM_FROM_MCSTORE: @@ -22519,12 +22491,12 @@ void CGameMode::ProcessIncomingPackets() { if (CRenderObject *actor = this->scene->GetGameActorByAID(aid)) { const int x = *reinterpret_cast(packet + 6); const int y = *reinterpret_cast(packet + 8); - actor->SendMsg(nullptr, AM_CORRECT_POS, 0, x, x >> 31, y, y >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_CORRECT_POS, x, y, 0, 0, 0, 0); } const int playerX = *reinterpret_cast(packet + 0x0A); const int playerY = *reinterpret_cast(packet + 0x0C); - this->scene->player->SendMsg(nullptr, AM_CORRECT_POS, 0, playerX, playerX >> 31, playerY, playerY >> 31, 0, 0, 0, 0, 0, 0, 0, 0); - this->scene->player->SendMsg(nullptr, AM_RESUMEPROCEEDATTACK, 0, aid, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_CORRECT_POS, playerX, playerY, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_RESUMEPROCEEDATTACK, aid, 0, 0, 0, 0, 0); break; } case ID_ZC_ATTACK_RANGE: @@ -22600,10 +22572,10 @@ void CGameMode::ProcessIncomingPackets() { case ID_ZC_RESURRECTION: { const std::uint32_t aid = *reinterpret_cast(g_gameModePacketBuffer + 2); if (CRenderObject *actor = this->scene->GetGameActorByAID(aid)) { - actor->SendMsg(nullptr, AM_RESURRECTION, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_RESURRECTION, 0, 0, 0, 0, 0, 0); } if (aid == g_session.m_aid) { - this->scene->player->SendMsg(nullptr, AM_RESURRECTION, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->scene->player->SendMsg(nullptr, AM_RESURRECTION, 0, 0, 0, 0, 0, 0); this->isOnQuest = 0; this->isPlayerDead = 0; } @@ -22935,7 +22907,7 @@ void CGameMode::ProcessIncomingPackets() { case ID_ZC_TALKBOX_CHATCONTENTS: if (CRenderObject *skill = this->scene->GetSkillByAID(*reinterpret_cast(g_gameModePacketBuffer + 2))) { const int textAddress = reinterpret_cast(g_gameModePacketBuffer + 6); - skill->SendMsg(nullptr, AM_CHAT, 0, textAddress, textAddress >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_CHAT, textAddress, 0, 0, 0, 0, 0); } break; case ID_ZC_UPDATE_MAPINFO: { @@ -23031,14 +23003,14 @@ void CGameMode::ProcessIncomingPackets() { case ID_ZC_SKILL_UPDATE: if (CGameActor *skill = static_cast(this->scene->GetSkillByAID(*reinterpret_cast(g_gameModePacketBuffer + 2)))) { if (skill->GetEffectiveJob(-1) > 138 && skill->GetEffectiveJob(-1) <= 153) { - skill->SendMsg(nullptr, AM_SKILL_UPDATE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SKILL_UPDATE, 0, 0, 0, 0, 0, 0); } switch (skill->GetEffectiveJob(-1)) { case UNT_DEEPBLINDTRAP: case UNT_SOLIDTRAP: case UNT_SWIFTTRAP: case UNT_FLAMETRAP: - skill->SendMsg(nullptr, AM_SKILL_UPDATE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SKILL_UPDATE, 0, 0, 0, 0, 0, 0); break; } } @@ -23500,7 +23472,7 @@ void CGameMode::ProcessIncomingPackets() { } if (actor) { const int stateAddress = reinterpret_cast(state); - actor->SendMsg(nullptr, AM_ATTR_STATE_CHANGE, 0, stateAddress, stateAddress >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_ATTR_STATE_CHANGE, stateAddress, 0, 0, 0, 0, 0); } break; } @@ -23577,7 +23549,7 @@ void CGameMode::ProcessIncomingPackets() { if (CRenderObject *actor = this->scene->GetGameActorByAID(*reinterpret_cast(g_gameModePacketBuffer + 2))) { const int x = *reinterpret_cast(g_gameModePacketBuffer + 0x1E); const int y = *reinterpret_cast(g_gameModePacketBuffer + 0x20); - actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, x, x >> 31, y, y >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_UPDATEGAGE, x, y, 0, 0, 0, 0); } break; case ID_ZC_NOTIFY_ACT2: @@ -23671,13 +23643,13 @@ void CGameMode::ProcessIncomingPackets() { break; case ID_ZC_PROGRESS: if (CPlayer *player = this->scene->player) { - player->SendMsg(nullptr, AM_MAKE_SKILL_RECHARGEGAGE, 0, *reinterpret_cast(g_gameModePacketBuffer + 6) * 1000, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, AM_MAKE_SKILL_RECHARGEGAGE, static_cast(*reinterpret_cast(g_gameModePacketBuffer + 6) * 1000), 0, 0, 0, 0, 0); g_session.playerStatusFlags[0x0A] = true; } break; case ID_ZC_PROGRESS_CANCEL: if (CPlayer *player = this->scene->player) { - player->SendMsg(nullptr, AM_DELETE_SKILL_RECHARGEGAGE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, AM_DELETE_SKILL_RECHARGEGAGE, 0, 0, 0, 0, 0, 0); if (*reinterpret_cast(&player->render.motionFinishThreshold) == 8) { player->SetState(0, 1); } @@ -24143,7 +24115,7 @@ void CGameMode::ProcessIncomingPackets() { if (CRenderObject *actor = this->scene->GetGameActorByAID(*reinterpret_cast(g_gameModePacketBuffer + 2))) { const int hp = *reinterpret_cast(g_gameModePacketBuffer + 6); const int maxHp = *reinterpret_cast(g_gameModePacketBuffer + 0xA); - actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, hp, hp >> 31, maxHp, maxHp >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_UPDATEGAGE, hp, maxHp, 0, 0, 0, 0); } if (g_windowMgr.messengerGroupWnd) { g_windowMgr.messengerGroupWnd->SendMsg(nullptr, UM_COMMAND, 34, *reinterpret_cast(g_gameModePacketBuffer + 2), @@ -24197,7 +24169,7 @@ void CGameMode::ProcessIncomingPackets() { } const int entryAddress = reinterpret_cast(&entry); - item->SendMsg(nullptr, AM_INITSTANDENTRY, 0, entryAddress, entryAddress >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + item->SendMsg(nullptr, AM_INITSTANDENTRY, entryAddress, 0, 0, 0, 0, 0); break; } case ID_ZC_NOTIFY_ACT3: @@ -24784,7 +24756,7 @@ void CGameMode::ProcessIncomingPackets() { break; case progressbarunit: if (CRenderObject *actor = this->scene->GetGameActorByAID(*reinterpret_cast(g_gameModePacketBuffer + 2))) { - actor->SendMsg(nullptr, AM_MAKE_SKILL_RECHARGEGAGE, 0, *reinterpret_cast(g_gameModePacketBuffer + 0xA) * 1000, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_MAKE_SKILL_RECHARGEGAGE, static_cast(*reinterpret_cast(g_gameModePacketBuffer + 0xA) * 1000), 0, 0, 0, 0, 0); } break; case ID_ZC_PARTY_REQ_MASTER_TO_JOIN: { @@ -24818,7 +24790,7 @@ void CGameMode::ProcessIncomingPackets() { if (CRenderObject *actor = this->scene->GetGameActorByAID(*reinterpret_cast(g_gameModePacketBuffer + 2))) { const int hp = *reinterpret_cast(g_gameModePacketBuffer + 6); const int maxHp = *reinterpret_cast(g_gameModePacketBuffer + 0xA); - actor->SendMsg(nullptr, AM_UPDATEGAGE, 0, hp, hp >> 31, maxHp, maxHp >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_UPDATEGAGE, hp, maxHp, 0, 0, 0, 0); } } break; @@ -24851,7 +24823,7 @@ void CGameMode::ProcessIncomingPackets() { } const int first = *reinterpret_cast(g_gameModePacketBuffer + 6); const int second = *reinterpret_cast(g_gameModePacketBuffer + 8); - actor->SendMsg(nullptr, AM_CASH_EMOTION, 0, first, first >> 31, second, second >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_CASH_EMOTION, first, second, 0, 0, 0, 0); break; } case 0xBEB: @@ -24965,11 +24937,11 @@ void CGameMode::ProcessIncomingPackets() { } if (*reinterpret_cast(g_gameModePacketBuffer + 2) - 27 > 0) { CGraffiSkill *skill = new CGraffiSkill; - skill->SendMsg(nullptr, AM_SETMASTERGID, 0, *reinterpret_cast(g_gameModePacketBuffer + 4), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SETMASTERGID, static_cast(*reinterpret_cast(g_gameModePacketBuffer + 4)), 0, 0, 0, 0, 0); const int address = reinterpret_cast(g_gameModePacketBuffer + 0x1B); const int x = *reinterpret_cast(g_gameModePacketBuffer + 0x10); const int y = *reinterpret_cast(g_gameModePacketBuffer + 0x12); - skill->SendMsg(nullptr, AM_SET_SKILL, 0, address, address >> 31, x, x >> 31, y, y >> 31, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_SET_SKILL, address, x, y, 0, 0, 0); this->scene->objects.push_back(skill); this->scene->skills.push_back(skill); } diff --git a/Source/Client/Session/Session.cpp b/Source/Client/Session/Session.cpp index 329e8e903..03b3dbfcf 100644 --- a/Source/Client/Session/Session.cpp +++ b/Source/Client/Session/Session.cpp @@ -1802,7 +1802,7 @@ void CSession::RemovePartyMemberByName(const char* name) { CRenderObject* actor = mode->scene->GetGameActorByAidIncludeMe(it->accountId); if (actor != nullptr && static_cast(actor)->HasId(160) == true) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 160, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 160, 0, 0, 0, 0, 0); } this->m_partyMembers.erase(it); @@ -3280,7 +3280,7 @@ void CSession::ClearItemContainers() { for (std::list::iterator it = this->m_partyMembers.begin(); it != this->m_partyMembers.end(); ++it) { CRenderObject* actor = mode->scene->GetGameActorByAidIncludeMe(it->accountId); if (actor != nullptr && static_cast(actor)->HasId(160) == true) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 160, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 160, 0, 0, 0, 0, 0); } } } diff --git a/Source/Contents/Actors/EffectActors.h b/Source/Contents/Actors/EffectActors.h index 79c3ada82..2877fc289 100644 --- a/Source/Contents/Actors/EffectActors.h +++ b/Source/Contents/Actors/EffectActors.h @@ -12,7 +12,7 @@ public: ~CBlowEffect() override; bool OnProcess() override; void SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) override; }; @@ -22,7 +22,7 @@ public: ~CCorpse() override; bool OnProcess() override; void SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) override; void Render(int argument) override; @@ -47,7 +47,7 @@ public: ~CNumEffect() override; bool OnProcess() override; void SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) override; /* 0138 */ float baseHeight; diff --git a/Source/Contents/Actors/GameActor.cpp b/Source/Contents/Actors/GameActor.cpp index 31aee73df..975cfec33 100644 --- a/Source/Contents/Actors/GameActor.cpp +++ b/Source/Contents/Actors/GameActor.cpp @@ -104,9 +104,7 @@ void CGameActor::ProcessDamageMessages() { } ActorDamageMessage& message = *it; - this->SendMsg( - nullptr, message.action, message.action >> 31, reinterpret_cast(&message.targetAid), 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0); + this->SendMsg(nullptr, message.action, reinterpret_cast(&message.targetAid), 0, 0, 0, 0, 0); it = this->willBeAttackedList.erase(it); } else { ++it; @@ -165,7 +163,7 @@ bool CGameActor::ProcessState() { this->isCounter = 0; this->render.isMotionFreezed = false; this->SetState(0, 1); - this->SendMsg(nullptr, AM_DELETE_SKILL_RECHARGEGAGE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_SKILL_RECHARGEGAGE, 0, 0, 0, 0, 0, 0); } this->ProcessMotion(); this->lastProcessStateTime = timeGetTime(); @@ -588,7 +586,7 @@ void CGameActor::UpdateGaugePositions() { if (this->actorWindows[3] != 0) { if (timeGetTime() > this->skillRechargeEndTick) { - this->SendMsg(nullptr, AM_DELETE_SKILL_RECHARGEGAGE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_SKILL_RECHARGEGAGE, 0, 0, 0, 0, 0, 0); if (this->render.state == 8) { this->SetState(0, 1); } @@ -666,7 +664,7 @@ void CGameActor::ReleaseAttachments() { } for (std::list::iterator it = this->msgEffectList.begin(); it != this->msgEffectList.end(); ++it) { - (*it)->SendMsg(nullptr, AM_MSGMASTER_DEAD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + (*it)->SendMsg(nullptr, AM_MSGMASTER_DEAD, 0, 0, 0, 0, 0, 0); } this->msgEffectList.erase(this->msgEffectList.begin(), this->msgEffectList.end()); diff --git a/Source/Contents/Actors/GameActor.h b/Source/Contents/Actors/GameActor.h index 3c0c6f7db..67aa7f7c3 100644 --- a/Source/Contents/Actors/GameActor.h +++ b/Source/Contents/Actors/GameActor.h @@ -71,7 +71,7 @@ public: CGameActor(); ~CGameActor() override; bool OnProcess() override = 0; - void SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m) override; + void SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) override; /* 0158 */ int movementState[6]; /* 0170 */ unsigned char destinationAndSpeed[0x08]; diff --git a/Source/Contents/Actors/GameObject.cpp b/Source/Contents/Actors/GameObject.cpp index 3f2fe6cfa..836326b0b 100644 --- a/Source/Contents/Actors/GameObject.cpp +++ b/Source/Contents/Actors/GameObject.cpp @@ -114,7 +114,7 @@ bool CGameObject::OnProcess() { // OFFSET: 0x00CBF850 // FUNCTION: fn_21113 -void CGameObject::SendMsg(CGameObject*, int, int, int, int, int, int, int, int, int, int, int, int, int, int) { +void CGameObject::SendMsg(CGameObject*, std::int64_t, std::int64_t, std::int64_t, std::int64_t, std::int64_t, std::int64_t, std::int64_t) { } // OFFSET: 0x00CB20A0 @@ -907,10 +907,7 @@ void CRenderObject::SetActionSpeed(float speed) { // FUNCTION: fn_21109 void CRenderObject::SendValueMessage(int value, CGameObject* target) { if (target) { - const std::int64_t wide = value; - target->SendMsg( - nullptr, AM_REQ_ATTACK, 0, static_cast(wide), static_cast(wide >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 - ); + target->SendMsg(nullptr, AM_REQ_ATTACK, value, 0, 0, 0, 0, 0); } } @@ -948,8 +945,8 @@ void CGameActor::ApplySavedShapeShift() { // OFFSET: 0x00CB4100 // FUNCTION: fn_21111 -void EffectActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int, int, int, int, int, int, int, int) { - switch (static_cast(a) << 32 | static_cast(message)) { +void EffectActor::SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t, std::int64_t, std::int64_t, std::int64_t) { + switch (message) { case AM_MASTER_DEAD: for (auto it = this->state.effects.begin(); it != this->state.effects.end(); ++it) { (*it)->SendMsg(this, AM_MASTER_DEAD, 0, 0, 0, 0, 0, 0); @@ -960,15 +957,13 @@ void EffectActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case AM_MAKE_MAGIC_TARGET: if (!this->state.second) { - this->state.second = this->LaunchEffect(b, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); + this->state.second = this->LaunchEffect(static_cast(b), vector3d{0.0f, 0.0f, 0.0f}, 0.0f); if (!this->state.second) { return; } } - this->state.second->SendMsg( - nullptr, AM_SET_DURATION, 0, static_cast(e) << 32 | static_cast(d), 0, 0, 0, 0 - ); + this->state.second->SendMsg(nullptr, AM_SET_DURATION, 0, c, 0, 0, 0, 0); break; case AM_DELETE_MAGIC_TARGET: @@ -986,21 +981,21 @@ void EffectActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case AM_MAKE_BEGIN_SPELL: if (!this->state.first) { - this->state.first = this->LaunchEffect(b, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); + this->state.first = this->LaunchEffect(static_cast(b), vector3d{0.0f, 0.0f, 0.0f}, 0.0f); if (!this->state.first) { return; } } - if ((static_cast(c) << 32 | static_cast(b)) > 0) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, b, c, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->state.first = this->LaunchEffect(b, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); + if (b > 0) { + this->SendMsg(nullptr, AM_DELETE_EFFECT, b, 0, 0, 0, 0, 0); + this->state.first = this->LaunchEffect(static_cast(b), vector3d{0.0f, 0.0f, 0.0f}, 0.0f); if (!this->state.first) { return; } } - this->state.first->SendMsg(nullptr, AM_SET_DURATION, 0, static_cast(e) << 32 | static_cast(d), 0, 0, 0, 0); + this->state.first->SendMsg(nullptr, AM_SET_DURATION, 0, c, 0, 0, 0, 0); break; case AM_DELETE_BEGIN_SPELL: @@ -1036,8 +1031,8 @@ void EffectActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case AM_DELETE_EFFECT: - if (g_effectMgr->HasAllocator(b) && sender) { - g_effectMgr->Retire(static_cast(sender)->render.accountId, b); + if (g_effectMgr->HasAllocator(static_cast(b)) && sender) { + g_effectMgr->Retire(static_cast(sender)->render.accountId, static_cast(b)); return; } @@ -1045,7 +1040,7 @@ void EffectActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, CRagEffect* const effect = *it; if (!effect) { this->state.effects.erase(it); - } else if (effect->state.type == (static_cast(c) << 32 | static_cast(b))) { + } else if (effect->state.type == b) { effect->SendMsg(this, AM_MASTER_DEAD, 0, 0, 0, 0, 0, 0); this->state.effects.erase(it); return; @@ -1054,8 +1049,8 @@ void EffectActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case AM_DELETE_TAGGED_EFFECT: - if (g_effectMgr->HasAllocator(d) && sender) { - g_effectMgr->Retire(static_cast(sender)->render.accountId, b, d); + if (g_effectMgr->HasAllocator(static_cast(c)) && sender) { + g_effectMgr->Retire(static_cast(sender)->render.accountId, static_cast(b), static_cast(c)); return; } @@ -1063,8 +1058,8 @@ void EffectActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, CRagEffect* const effect = *it; if (!effect) { this->state.effects.erase(it); - } else if (static_cast(effect->state.tag) == (static_cast(c) << 32 | static_cast(b)) && - effect->state.type == (static_cast(e) << 32 | static_cast(d))) { + } else if (static_cast(effect->state.tag) == b && + effect->state.type == c) { effect->SendMsg(this, AM_MASTER_DEAD, 0, 0, 0, 0, 0, 0); this->state.effects.erase(it); return; @@ -1077,16 +1072,16 @@ void EffectActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, CRagEffect* const effect = *it; if (!effect) { this->state.effects.erase(it); - } else if (effect->state.type == (static_cast(c) << 32 | static_cast(b))) { - effect->SendMsg(this, AM_EFFECT_LOOP_COUNT, 0, static_cast(c) << 32 | static_cast(b), d, e, 0, 0); + } else if (effect->state.type == b) { + effect->SendMsg(this, AM_EFFECT_LOOP_COUNT, 0, b, static_cast(c), static_cast(c >> 32), 0, 0); } } break; case AM_IS_HAVE_EFFECT: - if (g_effectMgr->HasAllocator(b) == true && sender) { - if (g_effectMgr->Has(static_cast(sender)->render.accountId, b) == true) { - *reinterpret_cast(b) = -1; + if (g_effectMgr->HasAllocator(static_cast(b)) == true && sender) { + if (g_effectMgr->Has(static_cast(sender)->render.accountId, static_cast(b)) == true) { + *reinterpret_cast(static_cast(b)) = -1; } return; } @@ -1095,8 +1090,8 @@ void EffectActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, CRagEffect* const effect = *it; if (!effect) { this->state.effects.erase(it); - } else if (*reinterpret_cast(b) == effect->state.type) { - *reinterpret_cast(b) = -1; + } else if (*reinterpret_cast(static_cast(b)) == effect->state.type) { + *reinterpret_cast(static_cast(b)) = -1; return; } } @@ -1191,7 +1186,7 @@ struct PcMoveEntry { // OFFSET: 0x00CB4800 // FUNCTION: fn_21112 -void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m) { +void CGameActor::SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) { CGameMode* mode = static_cast(g_modeMgr.GetGameMode()); bool visible = true; if (this->render.accountId != g_session.m_aid) { @@ -1200,7 +1195,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } } - switch (static_cast(a) << 32 | static_cast(message)) { + switch (message) { case 21: break; case AM_DELETE_PROHIBITEFFECT: @@ -1245,20 +1240,20 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } break; case AM_SET_TARGET_AID: - this->hitTargetAid = b; + this->hitTargetAid = static_cast(b); break; case AM_MAKE_NUMBER: { if ((g_session.GetSiegeMode() != 0 || g_session.GetBattleFieldMode() != 0) && g_session.IsAdminSubMode(7) == 0) { break; } - if ((static_cast(c) << 32 | static_cast(b)) == -29999) { + if (b == -29999) { break; } - int damage = b; + int damage = static_cast(b); if (this->render.accountId == g_session.m_aid && (g_session.HasActiveSkillEffect(0x22) != 0 || g_session.HasActiveSkillEffect(0x15B) != 0)) { damage = std::rand() % 22001 + 10000; } - this->SpawnDamageDigits(reinterpret_cast(sender), damage, d, f); + this->SpawnDamageDigits(reinterpret_cast(sender), damage, static_cast(c), static_cast(d)); break; } case AM_MVP: { @@ -1272,9 +1267,9 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, if (!g_serviceOptions.Get(0x35)) { break; } - CMsgEffect* effect = mode->SpawnDamageMsgEffect(&this->render.position, b, this->render.accountId); + CMsgEffect* effect = mode->SpawnDamageMsgEffect(&this->render.position, static_cast(b), this->render.accountId); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); ++this->damageNumberCount; break; } @@ -1284,18 +1279,18 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case AM_MAKE_LUCKY: { CMsgEffect* effect = mode->SpawnMsgEffect(0xD, &this->render.position, this->render.accountId, true); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); break; } case AM_CASH_EMOTION: { if (mode == nullptr) { break; } - if (!g_cashEmotionMgr->IsChatProhibitEmotion(d)) { - CMsgEffect* effect = mode->SpawnCashEmotion(reinterpret_cast(&this->render.position), b, d, this->render.accountId); + if (!g_cashEmotionMgr->IsChatProhibitEmotion(static_cast(c))) { + CMsgEffect* effect = mode->SpawnCashEmotion(reinterpret_cast(&this->render.position), static_cast(b), static_cast(c), this->render.accountId); if (effect != nullptr) { this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); break; } } else { @@ -1303,10 +1298,10 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; } CGameObject** slot = reinterpret_cast(&this->statusEffects[10]); - *slot = mode->SpawnCashEmotion(reinterpret_cast(&this->render.position), b, d, this->render.accountId); + *slot = mode->SpawnCashEmotion(reinterpret_cast(&this->render.position), static_cast(b), static_cast(c), this->render.accountId); if (*slot != nullptr) { this->msgEffectList.push_back(*slot); - (*slot)->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + (*slot)->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); break; } } @@ -1331,14 +1326,14 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } CMsgEffect* effect = mode->SpawnMsgEffect(effectIds[row][baby], &this->render.position, this->render.accountId, true); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); this->statusEffects[1] = reinterpret_cast(effect); break; } case AM_DELETE_CART: case AM_DELETE_WOLF: if (this->statusEffects[1] != 0) { - reinterpret_cast(this->statusEffects[1])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + reinterpret_cast(this->statusEffects[1])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); this->statusEffects[1] = 0; } break; @@ -1378,14 +1373,14 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } CMsgEffect* effect = mode->SpawnMsgEffect(effectId, &this->render.position, this->render.accountId, true); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); effect->SetAnimationSpeed(6.0f); this->statusEffects[0] = reinterpret_cast(effect); break; } case AM_DELETE_BIRD: if (this->statusEffects[0] != 0) { - reinterpret_cast(this->statusEffects[0])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + reinterpret_cast(this->statusEffects[0])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); reinterpret_cast(this->statusEffects[0])->m_visible = false; this->statusEffects[0] = 0; } @@ -1415,7 +1410,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } CMsgEffect* effect = mode->SpawnMsgEffect(effectId, &this->render.position, this->render.accountId, true); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); this->statusEffects[1] = reinterpret_cast(effect); break; } @@ -1425,13 +1420,13 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } CMsgEffect* effect = mode->SpawnMsgEffect(2, &this->render.position, this->render.accountId, true); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); this->statusEffects[2] = reinterpret_cast(effect); break; } case AM_DELETE_PKEFFECT: if (this->statusEffects[2] != 0) { - reinterpret_cast(this->statusEffects[2])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + reinterpret_cast(this->statusEffects[2])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); this->statusEffects[2] = 0; } break; @@ -1441,14 +1436,14 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } CMsgEffect* effect = mode->SpawnMsgEffect(3, &this->render.position, this->render.accountId, visible); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); this->statusEffects[3] = reinterpret_cast(effect); break; } case AM_DELETE_ICEEFFECT: case 107: if (this->statusEffects[3] != 0) { - reinterpret_cast(this->statusEffects[3])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + reinterpret_cast(this->statusEffects[3])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); this->statusEffects[3] = 0; } break; @@ -1458,13 +1453,13 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } CMsgEffect* effect = mode->SpawnMsgEffect(6, &this->render.position, this->render.accountId, true); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); this->statusEffects[4] = reinterpret_cast(effect); break; } case AM_DELETE_CURSE_EFFECT: if (this->statusEffects[4] != 0) { - reinterpret_cast(this->statusEffects[4])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + reinterpret_cast(this->statusEffects[4])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); this->statusEffects[4] = 0; } break; @@ -1474,14 +1469,14 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } CMsgEffect* effect = mode->SpawnMsgEffect(7, &this->render.position, this->render.accountId, true); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); this->statusEffects[5] = reinterpret_cast(effect); this->SetState(10, 1); break; } case AM_DELETE_SLEEP_EFFECT: if (this->statusEffects[5] != 0) { - reinterpret_cast(this->statusEffects[5])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + reinterpret_cast(this->statusEffects[5])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); this->statusEffects[5] = 0; this->SetState(this->render.previousState, 1); } @@ -1492,13 +1487,13 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } CMsgEffect* effect = mode->SpawnMsgEffect(8, &this->render.position, this->render.accountId, true); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); this->statusEffects[6] = reinterpret_cast(effect); break; } case AM_DELETE_STUN_EFFECT: if (this->statusEffects[6] != 0) { - reinterpret_cast(this->statusEffects[6])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + reinterpret_cast(this->statusEffects[6])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); this->statusEffects[6] = 0; } break; @@ -1506,7 +1501,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, this->LaunchEffect(0x316, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; case AM_DELETE_BURNING_EFFECT: - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x316, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x316, 0, 0, 0, 0, 0); break; case AM_MAKE_SILENCE_EFFECT: { if (this->statusEffects[7] != 0) { @@ -1514,13 +1509,13 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } CMsgEffect* effect = mode->SpawnMsgEffect(9, &this->render.position, this->render.accountId, true); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); this->statusEffects[7] = reinterpret_cast(effect); break; } case AM_DELETE_SILENCE_EFFECT: if (this->statusEffects[7] != 0) { - reinterpret_cast(this->statusEffects[7])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + reinterpret_cast(this->statusEffects[7])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); this->statusEffects[7] = 0; } break; @@ -1530,13 +1525,13 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } CMsgEffect* effect = mode->SpawnMsgEffect(0xA, &this->render.position, this->render.accountId, true); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); this->statusEffects[8] = reinterpret_cast(effect); break; } case AM_DELETE_ANGELUS_EFFECT: if (this->statusEffects[8] != 0) { - reinterpret_cast(this->statusEffects[8])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + reinterpret_cast(this->statusEffects[8])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); this->statusEffects[8] = 0; } break; @@ -1546,38 +1541,38 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } CMsgEffect* effect = mode->SpawnMsgEffect(0xB, &this->render.position, this->render.accountId, true); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); this->statusEffects[9] = reinterpret_cast(effect); break; } case AM_DELETE_CRUCIS_EFFECT: if (this->statusEffects[9] != 0) { - reinterpret_cast(this->statusEffects[9])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + reinterpret_cast(this->statusEffects[9])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); this->statusEffects[9] = 0; } break; case AM_MAKE_SMOKE_FFECT: { CMsgEffect* effect = mode->SpawnMsgEffect(5, &this->render.position, this->render.accountId, true); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); break; } case AM_MAKE_ICEBREAKE_FFECT: { CMsgEffect* effect = mode->SpawnMsgEffect(4, &this->render.position, this->render.accountId, visible); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); break; } case AM_MAKE_CRITICAL_EFFECT: { CMsgEffect* effect = mode->SpawnMsgEffect(0xC, &this->render.position, this->render.accountId, true); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); break; } case 131: { CMsgEffect* effect = mode->SpawnMsgEffect(0x16, &this->render.position, this->render.accountId, true); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); break; } case AM_USEITEM_EFFECT: @@ -1617,13 +1612,13 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } CMsgEffect* effect = mode->SpawnMsgEffect(0x1F, &this->render.position, this->render.accountId, true); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); this->statusEffects[11] = reinterpret_cast(effect); break; } case 135: if (this->statusEffects[11] != 0) { - reinterpret_cast(this->statusEffects[11])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + reinterpret_cast(this->statusEffects[11])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); this->statusEffects[11] = 0; } break; @@ -1633,13 +1628,13 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } CMsgEffect* effect = mode->SpawnMsgEffect(0x43, &this->render.position, this->render.accountId, true); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); this->statusEffects[12] = reinterpret_cast(effect); break; } case AM_DELETE_LASSITUDE_EFFECT: if (this->statusEffects[12] != 0) { - reinterpret_cast(this->statusEffects[12])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + reinterpret_cast(this->statusEffects[12])->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); this->statusEffects[12] = 0; } break; @@ -1652,7 +1647,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case AM_ATTACKED_SKILL: case AM_ATTACKEDNOMOTION_SKILL: { this->render.overrideColor = 0xFFFF0000; - const int effectId = reinterpret_cast(b)->effectId; + const int effectId = reinterpret_cast(static_cast(b))->effectId; if (effectId == 0xC6) { this->render.overrideColor = 0xFF042BA4; } else { @@ -1667,8 +1662,8 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case AM_ATTACKED_MANYTIMES2: case AM_ATTACKED_MANYTIMES2DASH: case 148: { - const std::int64_t id = static_cast(a) << 32 | static_cast(message); - const ActorDamageMessage* damageMessage = reinterpret_cast(b); + const std::int64_t id = message; + const ActorDamageMessage* damageMessage = reinterpret_cast(static_cast(b)); const int hitEffect = damageMessage->hitEffect; const int skillEffect = damageMessage->effectId; const int monsterValue = damageMessage->monsterValue; @@ -1696,7 +1691,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } if (id == 94) { - this->SendMsg(nullptr, AM_MAKE_LUCKY, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_LUCKY, 0, 0, 0, 0, 0, 0); } else { bool negative = false; if (damage < 0 && damage != -29999) { @@ -1709,12 +1704,12 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, if ((job >= 45 && job < 1000) || g_session.IsMonsterClass(job)) { if ((this->render.accountId == g_session.m_aid && g_session.HasActiveSkillEffect(19)) || (this->render.accountId == g_session.m_aid && g_session.HasActiveSkillEffect(104))) { - this->SendMsg(nullptr, AM_MAKE_GUARD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_GUARD, 0, 0, 0, 0, 0, 0); } else { - attacker->SendMsg(nullptr, AM_MAKE_MISS, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + attacker->SendMsg(nullptr, AM_MAKE_MISS, static_cast(-1), 0, 0, 0, 0, 0); } } else { - attacker->SendMsg(nullptr, AM_MAKE_MISS, 0, static_cast(0xFFFF0000), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + attacker->SendMsg(nullptr, AM_MAKE_MISS, 0xFFFF0000u, 0, 0, 0, 0, 0); } } } else { @@ -1850,12 +1845,12 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, preMessage = 0; if (id == 132) { } else if (id == 111) { - this->SendMsg(nullptr, AM_MAKE_NUMBER, 0, damage, damage >> 31, damageMessage->blueDamage != 0 ? static_cast(0xFF1E90FF) : -1, 0, 21, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_NUMBER, damage, damageMessage->blueDamage != 0 ? 0xFF1E90FFu : 0xFFFFFFFFu, 21, 0, 0, 0); kind = 22; color = 0xFFFFFF00; } else if (id == 148) { - this->SendMsg(nullptr, AM_MAKE_CRITICAL_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_MAKE_NUMBER, 0, damage, damage >> 31, static_cast(0xFFFFFF00), 0, 16, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_CRITICAL_EFFECT, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_NUMBER, damage, 0xFFFFFF00u, 16, 0, 0, 0); kind = 22; color = 0xFFFFFF00; } else { @@ -1874,9 +1869,9 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, color = 0xFF1E90FF; } if (preMessage != 0) { - this->SendMsg(nullptr, static_cast(preMessage), static_cast(preMessage >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, preMessage, 0, 0, 0, 0, 0, 0); } - this->SendMsg(nullptr, AM_MAKE_NUMBER, 0, value, value >> 31, static_cast(color), 0, static_cast(kind), static_cast(kind >> 32), 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_NUMBER, value, static_cast(color), kind, 0, 0, 0); if (!negative) { const auto isPlayer = IsPlayerJob(this->GetEffectiveJob(-1)); @@ -1906,7 +1901,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } if (this->willBeDead != 0 && this->willBeAttackedList.size() <= 1) { - this->SendMsg(nullptr, AM_DEAD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DEAD, 0, 0, 0, 0, 0, 0); } break; } @@ -1919,55 +1914,55 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, this->SetAnimationSpeed(1.0f); this->render.previousAnimation += this->Get8Dir(this->render.angle); if (this->willBeDead != 0 && this->willBeAttackedList.size() <= 1) { - this->SendMsg(nullptr, AM_DEAD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DEAD, 0, 0, 0, 0, 0, 0); } break; case AM_WILL_BE_ATTACKED: { - ActorDamageMessage* damage = reinterpret_cast(b); - if ((static_cast(e) << 32 | static_cast(d)) != 0) { + ActorDamageMessage* damage = reinterpret_cast(static_cast(b)); + if (c != 0) { if (damage->action != 0x94) { damage->action = 0x6F; } - damage->monsterValue = d; + damage->monsterValue = static_cast(c); } this->willBeAttackedList.push_back(*damage); break; } case AM_WILL_BE_ATTACKED2: { - ActorDamageMessage* damage = reinterpret_cast(b); - if ((static_cast(e) << 32 | static_cast(d)) != 0) { - damage->monsterValue = d; + ActorDamageMessage* damage = reinterpret_cast(static_cast(b)); + if (c != 0) { + damage->monsterValue = static_cast(c); damage->action = 0x81; } this->willBeAttackedList.push_back(*damage); break; } case AM_WILL_BE_ATTACKED2DASH: { - ActorDamageMessage* damage = reinterpret_cast(b); - if ((static_cast(e) << 32 | static_cast(d)) != 0) { - damage->monsterValue = d; + ActorDamageMessage* damage = reinterpret_cast(static_cast(b)); + if (c != 0) { + damage->monsterValue = static_cast(c); damage->action = 0x84; } this->willBeAttackedList.push_back(*damage); break; } case AM_SKILL: - this->ProcessSkillMessage(sender, reinterpret_cast(b), d, f); + this->ProcessSkillMessage(sender, reinterpret_cast(static_cast(b)), static_cast(c), static_cast(d)); break; case AM_GROUNDSKILL: - this->PlayGroundSkillEffect(reinterpret_cast(sender), reinterpret_cast(b), d, f); + this->PlayGroundSkillEffect(reinterpret_cast(sender), reinterpret_cast(static_cast(b)), static_cast(c), static_cast(d)); break; case AM_ACTION: - this->ProcessHitMessage(sender, reinterpret_cast(b), d, f); + this->ProcessHitMessage(sender, reinterpret_cast(static_cast(b)), static_cast(c), static_cast(d)); break; case AM_ATTR_STATE_CHANGE: { - const int* states = reinterpret_cast(b); + const int* states = reinterpret_cast(static_cast(b)); this->SetStatusStates(states[0], states[1], states[2], true); this->healthState = states[3]; break; } case AM_STANDENTRY: { - PcStandEntry* entry = reinterpret_cast(b); + PcStandEntry* entry = reinterpret_cast(static_cast(b)); switch (this->objectType) { case 8: case 9: @@ -1992,7 +1987,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; } case AM_INITSTANDENTRY: { - PcStandEntry* entry = reinterpret_cast(b); + PcStandEntry* entry = reinterpret_cast(static_cast(b)); switch (this->objectType) { case 8: case 9: @@ -2042,16 +2037,16 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, this->SetGuildInfo(entry->guildId, entry->guildVersion); } this->SetPropensityInfo(entry->honor, entry->virtue); - if ((static_cast(e) << 32 | static_cast(d)) == 1) { + if (c == 1) { this->render.color = 0x44FFFFFF; - } else if ((static_cast(e) << 32 | static_cast(d)) == 2 && !StateFlag06(entry->stateFlags)) { + } else if (c == 2 && !StateFlag06(entry->stateFlags)) { this->LaunchEffect(0x158, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; } case AM_INITMOVEENTRY: case AM_INITMOVEENTRY2: { - PcMoveEntry* entry = reinterpret_cast(b); + PcMoveEntry* entry = reinterpret_cast(static_cast(b)); switch (this->objectType) { case 8: case 9: @@ -2089,7 +2084,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } case AM_MOVEENTRY: case AM_MOVEENTRY2: { - PcMoveEntry* entry = reinterpret_cast(b); + PcMoveEntry* entry = reinterpret_cast(static_cast(b)); switch (this->objectType) { case 8: case 9: @@ -2117,7 +2112,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; } case AM_MOVE: { - const int* route = reinterpret_cast(b); + const int* route = reinterpret_cast(static_cast(b)); this->routeStartTick = route[0]; if (this->FindRoute(route[1], route[2], route[3], route[4], route[5], route[6], *reinterpret_cast(&this->destinationAndSpeed[4]))) { this->movementState[5] = route[5]; @@ -2178,7 +2173,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, ); g_windowMgr.AddRenderedFront(reinterpret_cast(this->actorWindows[3])); } - this->skillRechargeEndTick = timeGetTime() + b; + this->skillRechargeEndTick = timeGetTime() + static_cast(b); this->skillRechargeStartTick = timeGetTime(); break; case AM_DELETE_SKILL_RECHARGEGAGE: @@ -2195,14 +2190,14 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } break; case AM_CHAT: { - std::string text(reinterpret_cast(b)); + std::string text(reinterpret_cast(static_cast(b))); if (g_windowMgr.chatWnd != nullptr) { - text = static_cast(g_windowMgr.chatWnd)->ConvertChat(std::string(reinterpret_cast(b))); + text = static_cast(g_windowMgr.chatWnd)->ConvertChat(std::string(reinterpret_cast(static_cast(b)))); } std::string linked; DisplayNavigationLink(linked, text); text = std::move(linked); - const char* message = reinterpret_cast(b); + const char* message = reinterpret_cast(static_cast(b)); if (text.size() != 0) { message = text.c_str(); } @@ -2221,8 +2216,8 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, reinterpret_cast(this->actorWindows[0])->m_fontMode = static_cast(this->render.fontSequenceState); } reinterpret_cast(this->actorWindows[0])->SetText(message, 35); - if ((static_cast(e) << 32 | static_cast(d)) != 0) { - reinterpret_cast(this->actorWindows[0])->m_textColor = d; + if (c != 0) { + reinterpret_cast(this->actorWindows[0])->m_textColor = static_cast(c); reinterpret_cast(this->actorWindows[0])->m_outlineColor = 0; } UIWindow* balloon = reinterpret_cast(this->actorWindows[0]); @@ -2242,20 +2237,20 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, int subRow; mode->WorldSubcell(this->render.position.x, this->render.position.z, column, row, subColumn, subRow); bool found; - if (f == 0) { - found = this->FindRoute(column, row, subColumn, subRow, b, d, this->isAsuraAttack != 0 ? 55 : 2); + if (static_cast(d) == 0) { + found = this->FindRoute(column, row, subColumn, subRow, static_cast(b), static_cast(c), this->isAsuraAttack != 0 ? 55 : 2); } else { - found = this->FindRoute(column, row, subColumn, subRow, b, d, f); + found = this->FindRoute(column, row, subColumn, subRow, static_cast(b), static_cast(c), static_cast(d)); } bool lying = false; - if ((static_cast(i) << 32 | static_cast(h)) == 0) { + if (e == 0) { lying = true; } - this->movementState[5] = b; - *reinterpret_cast(this->destinationAndSpeed) = d; + this->movementState[5] = static_cast(b); + *reinterpret_cast(this->destinationAndSpeed) = static_cast(c); if (found) { CGameMode* gameMode = static_cast(g_modeMgr.GetGameMode()); - gameMode->CellCenter(b, d, this->render.position.x, this->render.position.z); + gameMode->CellCenter(static_cast(b), static_cast(c), this->render.position.x, this->render.position.z); this->render.position.y = gameMode->scene->terrain->Height(this->render.position.x, this->render.position.z); this->UnRegisterPos(); @@ -2265,7 +2260,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } this->SetState(1, lying); this->pathStartCell = 0; - if (f == 0) { + if (static_cast(d) == 0) { this->isNeverAnimation = 1; } else { this->isNeverAnimation = 0; @@ -2287,9 +2282,9 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; } case AM_CORRECT_POS: - this->movementState[5] = b; - *reinterpret_cast(this->destinationAndSpeed) = d; - mode->CellCenter(b, d, this->render.position.x, this->render.position.z); + this->movementState[5] = static_cast(b); + *reinterpret_cast(this->destinationAndSpeed) = static_cast(c); + mode->CellCenter(static_cast(b), static_cast(c), this->render.position.x, this->render.position.z); break; case AM_RESURRECTION: this->render.state = 0; @@ -2394,7 +2389,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, if (*reinterpret_cast(&g_session.jobLevelLimits[0x68]) > 0) { second = *reinterpret_cast(&g_session.jobLevelLimits[0x68]); } - } else if ((static_cast(a) << 32 | static_cast(message)) == 0x93) { + } else if (message == 0x93) { first = 0x3D2; second = 0x3D3; if (*reinterpret_cast(&g_session.jobLevelLimits[0x54]) > 0) { @@ -2405,7 +2400,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } } else { second = 0x3FF; - if ((static_cast(a) << 32 | static_cast(message)) == 0x92) { + if (message == 0x92) { if (*reinterpret_cast(&g_session.jobLevelLimits[0x5C]) > 0) { first = *reinterpret_cast(&g_session.jobLevelLimits[0x5C]); } @@ -2478,8 +2473,8 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; } case AM_STATUS_CHANGE: { - const bool on = (static_cast(e) << 32 | static_cast(d)) != 0; - switch (static_cast(c) << 32 | static_cast(b)) { + const bool on = c != 0; + switch (b) { case EFST_PROVOKE: case EFST_ENDURE: case EFST_CONCENTRATION: @@ -2527,7 +2522,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case EFST_TWOHANDQUICKEN: case EFST_ONEHANDQUICKEN: { while (this->HasId(0xA6)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0xA6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0xA6, 0, 0, 0, 0, 0); } if (on) { CRagEffect* effect = this->LaunchEffect(0xA6, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2539,7 +2534,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } case EFST_SPEARQUICKEN: { while (this->HasId(0xA6)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0xA6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0xA6, 0, 0, 0, 0, 0); } if (on) { CRagEffect* effect = this->LaunchEffect(0xA6, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2551,7 +2546,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } case EFST_NJ_BUNSINJYUTSU: while (this->HasId(0x269)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x269, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x269, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x269, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2561,20 +2556,20 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, if (this->render.accountId != g_session.m_aid) { break; } - if (f >= 2 && f <= 11) { - const int effectId = f + 0x1D9; + if (static_cast(d) >= 2 && static_cast(d) <= 11) { + const int effectId = static_cast(d) + 0x1D9; if (!this->HasId(effectId)) { this->LaunchEffect(0x1E7, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); g_soundMgr->PlayWave("effect\\_blind.wav", 0.0f, -100.0f, 0.0f, 250, 40, 1.0f, 0); } for (int id = 0x1DB; id < 0x1E5; ++id) { if (this->HasId(id) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, id, id >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, id, 0, 0, 0, 0, 0); } } this->LaunchEffect(effectId, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0xA4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0xA4, 0, 0, 0, 0, 0); CPlayer* player = static_cast(g_modeMgr.GetGameMode())->scene->player; if (player) { player->skillEffect = this->LaunchEffect(0xA4, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2586,7 +2581,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, if (this->HasId(0x28F)) { vector3d position{0.0f, 0.0f, 0.0f}; do { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x28F, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x28F, 0, 0, 0, 0, 0); this->LaunchEffect(0x290, position, 0.0f); } while (this->HasId(0x28F)); } @@ -2610,13 +2605,13 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_EXPLOSIONSPIRITS: { while (this->HasId(0xCB)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0xCB, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0xCB, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0xCB, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } while (this->HasId(0xA6)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0xA6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0xA6, 0, 0, 0, 0, 0); } if (on) { CRagEffect* effect = this->LaunchEffect(0xA6, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2629,8 +2624,8 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case EFST_STEELBODY: case EFST_DBARRIER: { while (this->HasId(0xFE)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0xFE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x46C, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0xFE, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x46C, 0, 0, 0, 0, 0); } if (this->render.accountId == g_session.m_gid || IsPlayerJob(this->GetEffectiveJob(-1))) { CPc* pc = static_cast(this); @@ -2649,10 +2644,10 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case EFST_SG_MOON_WARM: case EFST_SG_STAR_WARM: while (this->HasId(0x1A2)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1A2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1A2, 0, 0, 0, 0, 0); } while (this->HasId(0x220)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x220, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x220, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x1A2, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2661,10 +2656,10 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_DAURA: while (this->HasId(0x1A2)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1A2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1A2, 0, 0, 0, 0, 0); } while (this->HasId(0x220)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x220, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x220, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x1A2, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2673,7 +2668,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_KAITE: while (this->HasId(0x1A3)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1A3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1A3, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x1A3, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2681,10 +2676,10 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_AURABLADE: while (this->HasId(0x16F)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x16F, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x16F, 0, 0, 0, 0, 0); } while (this->HasId(0x1DA)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1DA, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1DA, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x16F, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2693,12 +2688,12 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_STOP: while (this->HasId(0x1C5)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1C5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1C5, 0, 0, 0, 0, 0); } break; case EFST_MOON: { while (this->HasId(0x18A)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x18A, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x18A, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x18A, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2706,9 +2701,9 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; } case EFST_MARIONETTE_MASTER: { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x18B, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x18B, 0, 0, 0, 0, 0); while (this->HasId(0x18C)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x18C, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x18C, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x18C, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2717,7 +2712,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } case EFST_MARIONETTE: { while (this->HasId(0x18C)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x18C, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x18C, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x18C, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2725,7 +2720,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; } case EFST_LKCONCENTRATION: { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x171, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x171, 0, 0, 0, 0, 0); if (on) { this->LaunchEffect(0x171, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } @@ -2733,7 +2728,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } case EFST_BERSERK: { while (this->HasId(0x170)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x170, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x170, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x170, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2743,7 +2738,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case EFST_RG_CCONFINE_M: case EFST_RG_CCONFINE_S: { while (this->HasId(0x25C)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x25C, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x25C, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x25C, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2752,7 +2747,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } case EFST_WZ_SIGHTBLASTER: { while (this->HasId(0x259)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x259, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x259, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x259, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2761,7 +2756,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } case EFST_POWERUP: { while (this->HasId(0x1C7)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1C7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1C7, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x1C7, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2772,7 +2767,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, if (this->HasId(0x1BA)) { this->LaunchEffect(0x1BB, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1BA, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1BA, 0, 0, 0, 0, 0); break; } case EFST_TING: { @@ -2780,13 +2775,13 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, g_soundMgr->PlayWave("effect\\T_벽튕김.wav", this->render.position.x - player.x, 0.0f, this->render.position.z - player.z, 250, 40, 1.0f, 0); this->LaunchEffect(0x1AA, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); if (this->HasId(0x1BA)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1BA, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1BA, 0, 0, 0, 0, 0); } break; } case EFST_MAGICPOWER: { while (this->HasId(0x17E)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x17E, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x17E, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x17E, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2796,7 +2791,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case EFST_OVERTHRUST: case EFST_OVERTHRUSTMAX: { while (this->HasId(0xA6)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0xA6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0xA6, 0, 0, 0, 0, 0); } if (on) { CRagEffect* effect = this->LaunchEffect(0xA6, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2808,7 +2803,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } case EFST_ENERGYCOAT: { while (this->HasId(0xA6)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0xA6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0xA6, 0, 0, 0, 0, 0); } if (on) { CRagEffect* effect = this->LaunchEffect(0xA6, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2860,7 +2855,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_RICHMANKIM: { if (this->HasId(0x363) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x363, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x363, 0, 0, 0, 0, 0); } if (on == true) { this->LaunchEffect(0x363, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2871,7 +2866,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case EFST_HUMMING: case EFST_INTOABYSS: { if (this->HasId(0x361) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x361, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x361, 0, 0, 0, 0, 0); } if (on == true) { this->LaunchEffect(0x361, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2881,7 +2876,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case EFST_RINGNIBELUNGEN: case EFST_SIEGFRIED: { if (this->HasId(0x36B) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x36B, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x36B, 0, 0, 0, 0, 0); } if (on == true) { this->LaunchEffect(0x36B, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2890,7 +2885,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } case EFST_APPLEIDUN: { if (this->HasId(0x35D) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x35D, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x35D, 0, 0, 0, 0, 0); } if (on == true) { this->LaunchEffect(0x35D, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2900,7 +2895,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case EFST_ETERNALCHAOS: case EFST_ROKISWEIL: { if (this->HasId(0x360) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x360, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x360, 0, 0, 0, 0, 0); } if (on == true) { this->LaunchEffect(0x360, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2910,7 +2905,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case EFST_ASSASSINCROSS: case EFST_SERVICEFORYOU: { if (this->HasId(0x369) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x369, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x369, 0, 0, 0, 0, 0); } if (on == true) { this->LaunchEffect(0x369, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2920,7 +2915,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case EFST_FORTUNEKISS: case EFST_DRUMBATTLEFIELD: { if (this->HasId(0x367) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x367, 0, 0, 0, 0, 0); } if (on == true) { this->LaunchEffect(0x367, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2929,7 +2924,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } case EFST_DONTFORGETME: { if (this->HasId(0x26) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x26, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x26, 0, 0, 0, 0, 0); } if (on == true) { this->LaunchEffect(0x26, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2938,7 +2933,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } case EFST_POEMBRAGI: { if (this->HasId(0x36D) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x36D, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x36D, 0, 0, 0, 0, 0); } if (on == true) { this->LaunchEffect(0x36D, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2947,7 +2942,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } case EFST_DA_CONTRACT: { while (this->HasId(0x24A)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x24A, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x24A, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x24A, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2956,7 +2951,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } case EFST_DUPLELIGHT: { while (this->HasId(0x341)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x341, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x341, 0, 0, 0, 0, 0); } if (on) { CRagEffect* effect = this->LaunchEffect(0x341, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2969,7 +2964,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } case EFST_ORATIO: while (this->HasId(0x2F3)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x2F3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x2F3, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x2F3, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2977,7 +2972,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_BLOOD_SUCKER: while (this->HasId(0x170)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x170, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x170, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x170, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3012,7 +3007,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case EFST_STRIKING: if (IsPlayerJob(this->GetEffectiveJob(-1))) { while (this->HasId(0x39D)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x39D, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x39D, 0, 0, 0, 0, 0); } if (on) { CRagEffect* effect = this->LaunchEffect(0x39D, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3024,7 +3019,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_VENOMIMPRESS: while (this->HasId(0x314)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x314, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x314, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x314, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3032,7 +3027,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_FROSTMISTY: while (this->HasId(0x315)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x315, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x315, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x315, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3040,39 +3035,39 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_COLD: while (this->HasId(0x3AC)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x3AC, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x3AC, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x3AC, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; case EFST_SUMMON1: - this->SetTetraBall(0, d, f); + this->SetTetraBall(0, static_cast(c), static_cast(d)); break; case EFST_SUMMON2: - this->SetTetraBall(1, d, f); + this->SetTetraBall(1, static_cast(c), static_cast(d)); break; case EFST_SUMMON3: - this->SetTetraBall(2, d, f); + this->SetTetraBall(2, static_cast(c), static_cast(d)); break; case EFST_SUMMON4: - this->SetTetraBall(3, d, f); + this->SetTetraBall(3, static_cast(c), static_cast(d)); break; case EFST_SUMMON5: - this->SetTetraBall(4, d, f); + this->SetTetraBall(4, static_cast(c), static_cast(d)); break; case EFST_ROLLINGCUTTER: - if ((static_cast(e) << 32 | static_cast(d)) == 1) { - const std::int64_t level = static_cast(g) << 32 | static_cast(f); + if (c == 1) { + const std::int64_t level = d; if (level <= 10 && level > 0) { for (int id = 0x514; id < 0x51E; ++id) { g_effectMgr->Retire(this->render.accountId, id); g_effectMgr->Retire(this->render.accountId, id + 0xA7); } if (g_serviceOptions.Get(0xE5)) { - g_effectMgr->Spawn(this->render.accountId, f + 0x5BA, vector3d{0.0f, 0.0f, 0.0f}, 0, -1, 0, 0); + g_effectMgr->Spawn(this->render.accountId, static_cast(d) + 0x5BA, vector3d{0.0f, 0.0f, 0.0f}, 0, -1, 0, 0); } else { - g_effectMgr->Spawn(this->render.accountId, f + 0x513, vector3d{0.0f, 0.0f, 0.0f}, 0, -1, 0, 0); + g_effectMgr->Spawn(this->render.accountId, static_cast(d) + 0x513, vector3d{0.0f, 0.0f, 0.0f}, 0, -1, 0, 0); } } } else { @@ -3083,41 +3078,41 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } break; case EFST_SIREN: - if ((static_cast(e) << 32 | static_cast(d)) == 1) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x36F, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + if (c == 1) { + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x36F, 0, 0, 0, 0, 0); this->LaunchEffect(0x36F, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } else { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x36F, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x36F, 0, 0, 0, 0, 0); } break; case EFST_SONG_OF_MANA: - if ((static_cast(e) << 32 | static_cast(d)) == 1) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x361, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + if (c == 1) { + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x361, 0, 0, 0, 0, 0); this->LaunchEffect(0x361, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; case EFST_DANCE_WITH_WUG: - if ((static_cast(e) << 32 | static_cast(d)) == 1) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x363, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + if (c == 1) { + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x363, 0, 0, 0, 0, 0); this->LaunchEffect(0x363, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; case EFST_LERADS_DEW: - if ((static_cast(e) << 32 | static_cast(d)) == 1) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + if (c == 1) { + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x367, 0, 0, 0, 0, 0); this->LaunchEffect(0x367, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; case EFST_DEEP_SLEEP: - if ((static_cast(e) << 32 | static_cast(d)) == 1) { - this->SendMsg(nullptr, AM_MAKE_SLEEP_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + if (c == 1) { + this->SendMsg(nullptr, AM_MAKE_SLEEP_EFFECT, 0, 0, 0, 0, 0, 0); } else { - this->SendMsg(nullptr, AM_DELETE_SLEEP_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_SLEEP_EFFECT, 0, 0, 0, 0, 0, 0); } break; case EFST_NETHERWORLD: while (this->HasId(0x1C5)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1C5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1C5, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x1C5, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3125,7 +3120,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_CAMOUFLAGE: while (this->HasId(0x2E8)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x2E8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x2E8, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x2E8, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3140,7 +3135,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_MANHOLE: while (this->HasId(0x337)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x337, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x337, 0, 0, 0, 0, 0); } if (on) { g_soundMgr->PlayWave("effect\\manhole.wav", 0.0f, 0.0f, 0.0f, 250, 40, 1.0f, 0); @@ -3151,8 +3146,8 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_SHADOWFORM: while (this->HasId(0x329)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x329, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x333, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x329, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x333, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x329, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3160,7 +3155,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_STEALTHFIELD: while (this->HasId(0x2E8)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x2E8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x2E8, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x2E8, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3168,7 +3163,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_WUGDASH: while (this->HasId(0x2F0)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x2F0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x2F0, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x2F0, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3182,37 +3177,37 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_MER_FLEE: { const int text = reinterpret_cast("FLEE UP!"); - this->SendMsg(nullptr, AM_CHAT, 0, text, text >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CHAT, text, 0, 0, 0, 0, 0); this->LaunchEffect(0x1C8, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; } case EFST_MER_ATK: { const int text = reinterpret_cast("ATK UP!"); - this->SendMsg(nullptr, AM_CHAT, 0, text, text >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CHAT, text, 0, 0, 0, 0, 0); this->LaunchEffect(0x1C8, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; } case EFST_MER_HIT: { const int text = reinterpret_cast("DEX UP!"); - this->SendMsg(nullptr, AM_CHAT, 0, text, text >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CHAT, text, 0, 0, 0, 0, 0); this->LaunchEffect(0x1C8, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; } case EFST_MER_HP: { const int text = reinterpret_cast("HP UP!"); - this->SendMsg(nullptr, AM_CHAT, 0, text, text >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CHAT, text, 0, 0, 0, 0, 0); this->LaunchEffect(0x1C8, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; } case EFST_MER_SP: { const int text = reinterpret_cast("SP UP!"); - this->SendMsg(nullptr, AM_CHAT, 0, text, text >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CHAT, text, 0, 0, 0, 0, 0); this->LaunchEffect(0x1C8, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; } case EFST_UNLIMITED_HUMMING_VOICE: if (this->HasId(0x361) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x361, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x361, 0, 0, 0, 0, 0); } if (on == true) { this->LaunchEffect(0x361, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3220,7 +3215,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_MELODYOFSINK: if (this->HasId(0x57) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x57, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x57, 0, 0, 0, 0, 0); } if (on == true) { this->LaunchEffect(0x57, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3228,7 +3223,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_BEYOND_OF_WARCRY: if (this->HasId(0x31F) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x31F, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x31F, 0, 0, 0, 0, 0); } if (on == true) { this->LaunchEffect(0x31F, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3236,7 +3231,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_SATURDAY_NIGHT_FEVER: if (this->HasId(0x360) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x360, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x360, 0, 0, 0, 0, 0); } if (on == true) { this->LaunchEffect(0x360, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3254,13 +3249,13 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case EFST_EQUIPPED_HOLY_ARMOR: break; case EFST_EQUIPED_FLOOR: - g_effectMgr->SpawnLevel99(this, on, f); + g_effectMgr->SpawnLevel99(this, on, static_cast(d)); break; case EFST_GRANITIC_ARMOR: while (this->HasId(0x3C3)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x3C3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x3C3, 0, 0, 0, 0, 0); } - if ((static_cast(e) << 32 | static_cast(d)) != 0) { + if (c != 0) { this->LaunchEffect(0x3C3, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; @@ -3269,7 +3264,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, this->SetState(0, 1); } int job; - if ((static_cast(e) << 32 | static_cast(d)) > 0) { + if (c > 0) { this->SetRiding(1); job = this->GetEffectiveJob(-1); } else { @@ -3299,8 +3294,8 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, slot = 0; break; } - if ((static_cast(e) << 32 | static_cast(d)) != 0) { - this->SetTransformJob(f, slot); + if (c != 0) { + this->SetTransformJob(static_cast(d), slot); } else { this->SetTransformJob(-1, slot); if (this->render.state == 3) { @@ -3311,31 +3306,31 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } case EFST_KO_JYUMONJIKIRI: g_effectMgr->Retire(this->render.accountId, 0x3E6); - if ((static_cast(e) << 32 | static_cast(d)) != 0 && g_effectMgr->HasAllocator(0x3E6)) { + if (c != 0 && g_effectMgr->HasAllocator(0x3E6)) { g_effectMgr->Spawn(this->render.accountId, 0x3E6, this->render.position, 0, -1, 0, 0); } break; case EFST_KYOMU: while (this->HasId(0x3C3)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x3C3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x3C3, 0, 0, 0, 0, 0); } - if ((static_cast(e) << 32 | static_cast(d)) != 0) { + if (c != 0) { this->LaunchEffect(0x3C3, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; case EFST_KAGEMUSYA: while (this->HasId(0x3EC)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x3EC, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x3EC, 0, 0, 0, 0, 0); } - if ((static_cast(e) << 32 | static_cast(d)) != 0) { + if (c != 0) { this->LaunchEffect(0x3EC, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; case EFST_MEIKYOUSISUI: while (this->HasId(0x18A)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x18A, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x18A, 0, 0, 0, 0, 0); } - if ((static_cast(e) << 32 | static_cast(d)) != 0) { + if (c != 0) { CRagEffect* effect = this->LaunchEffect(0x18A, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); if (effect) { effect->state.colorChannels[0] = 180; @@ -3346,71 +3341,71 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_ZANGETSU: while (this->HasId(0x3EB)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x3EB, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x3EB, 0, 0, 0, 0, 0); } - if ((static_cast(e) << 32 | static_cast(d)) != 0) { + if (c != 0) { this->LaunchEffect(0x3EB, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; case EFST_GENSOU: g_effectMgr->Retire(this->render.accountId, 0x3ED); - if ((static_cast(e) << 32 | static_cast(d)) != 0 && g_effectMgr->HasAllocator(0x3ED)) { + if (c != 0 && g_effectMgr->HasAllocator(0x3ED)) { CEffect* orb = g_effectMgr->Spawn(this->render.accountId, 0x3ED, vector3d{0.0f, 0.0f, 0.0f}, 0, -1, 0, 0); if (orb) { static_cast(orb)->SetCount(10); } } while (this->HasId(0x3C3)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x3C3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x3C3, 0, 0, 0, 0, 0); } - if ((static_cast(e) << 32 | static_cast(d)) != 0) { + if (c != 0) { this->LaunchEffect(0x3C3, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; case EFST_AKAITSUKI: while (this->HasId(0x220)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x220, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x220, 0, 0, 0, 0, 0); } - if ((static_cast(e) << 32 | static_cast(d)) != 0) { + if (c != 0) { this->LaunchEffect(0x220, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; case EFST_SHOW_HP: - this->hasHp = (static_cast(e) << 32 | static_cast(d)) != 0; + this->hasHp = c != 0; break; case EFST_HAT_EFFECT: - this->SetStackedEffect(0x3F4, (static_cast(e) << 32 | static_cast(d)) > 0); + this->SetStackedEffect(0x3F4, c > 0); break; case EFST_MOONSTAR: - this->SetStackedEffect(0x40A, (static_cast(e) << 32 | static_cast(d)) > 0); + this->SetStackedEffect(0x40A, c > 0); break; case EFST_DECORATION_OF_MUSIC: - this->SetStackedEffect(0x437, (static_cast(e) << 32 | static_cast(d)) > 0); + this->SetStackedEffect(0x437, c > 0); break; case EFST_STRANGELIGHTS: - this->SetStackedEffect(0x40B, (static_cast(e) << 32 | static_cast(d)) > 0); + this->SetStackedEffect(0x40B, c > 0); break; case EFST_SUPER_STAR: - this->SetStackedEffect(0x40C, (static_cast(e) << 32 | static_cast(d)) > 0); + this->SetStackedEffect(0x40C, c > 0); break; case EFST_ON_PUSH_CART: - if ((static_cast(e) << 32 | static_cast(d)) != 0) { - if (static_cast(this->maxHp) == (static_cast(g) << 32 | static_cast(f))) { + if (c != 0) { + if (static_cast(this->maxHp) == d) { break; } - this->maxHp = f; + this->maxHp = static_cast(d); if (StateFlag01(this->stateFlags) || StateFlag02(this->stateFlags) || StateFlag06(this->stateFlags)) { break; } - this->SendMsg(nullptr, AM_DELETE_CART, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_MAKE_CART, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_CART, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_CART, 0, 0, 0, 0, 0, 0); } else { this->maxHp = 0; - this->SendMsg(nullptr, AM_DELETE_CART, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_CART, 0, 0, 0, 0, 0, 0); } break; case EFST_FLOWER_LEAF: - if ((static_cast(e) << 32 | static_cast(d)) != 0) { + if (c != 0) { g_effectMgr->Spawn(this->render.accountId, 0x3F5, vector3d{0.0f, 0.0f, 0.0f}, 0, -1, 0, 0); } else { g_effectMgr->Retire(this->render.accountId, 0x3F5); @@ -3418,32 +3413,32 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_RAY_OF_PROTECTION: while (this->HasId(0x3FB)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x3FB, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x3FB, 0, 0, 0, 0, 0); } - if ((static_cast(e) << 32 | static_cast(d)) != 0) { + if (c != 0) { this->LaunchEffect(0x3FB, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; case EFST_CLAN_INFO: - this->hasSp = (static_cast(i) << 32 | static_cast(h)) != 0; - this->spGaugeValue = h; + this->hasSp = e != 0; + this->spGaugeValue = static_cast(e); break; case EFST_HANDICAPSTATE_ICEEXPLO: - if ((static_cast(e) << 32 | static_cast(d)) != 0) { - this->SendMsg(nullptr, AM_CHANGE_COLOR, 0, 50, 0, 150, 0, 255, 0, 0, 0, 0, 0, 0, 0); + if (c != 0) { + this->SendMsg(nullptr, AM_CHANGE_COLOR, 50, 150, 255, 0, 0, 0); } break; case EFST_MAXPAIN: while (this->HasId(0x40D)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x40D, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x40D, 0, 0, 0, 0, 0); } - if ((static_cast(e) << 32 | static_cast(d)) != 0) { + if (c != 0) { this->LaunchEffect(0x40D, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; case EFST_DARKCROW: while (this->HasId(0x410)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x410, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x410, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x410, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3453,7 +3448,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_TELEKINESIS_INTENSE: while (this->HasId(0x418)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x418, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x418, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x418, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3461,7 +3456,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_ILLUSIONDOPING: while (this->HasId(0x419)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x419, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x419, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x419, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3469,7 +3464,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_WIDEWEB: while (this->HasId(0x194)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x194, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x194, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x194, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3477,7 +3472,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_BURNT: while (this->HasId(0x41E)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x41E, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x41E, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x41E, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3485,7 +3480,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_CHILL: while (this->HasId(0x41F)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x41F, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x41F, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x41F, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3493,14 +3488,14 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_OFFERTORIUM: while (this->HasId(0x421)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x421, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x421, 0, 0, 0, 0, 0); } if (on) { this->LaunchEffect(0x421, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; case EFST_C_MARKER: - this->SendMsg(this, AM_DELETE_EFFECT, 0, 0x433, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 0x433, 0, 0, 0, 0, 0); if (on) { if (g_session.actorEffectStates.find(static_cast(this->render.accountId)) == g_session.actorEffectStates.end() && g_effectMgr->HasAllocator(0x425)) { g_effectMgr->Spawn(this->render.accountId, 0x425, this->render.position, 0, -1, 0, 0); @@ -3529,19 +3524,19 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_H_MINE_SPLASH: if (on) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x425, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x425, 0, 0, 0, 0, 0); g_effectMgr->Spawn(0, 0x432, this->render.position, 0, -1, 0, 0); } break; case EFST_FLOWERSMOKE: - this->SetStackedEffect(0x43B, (static_cast(e) << 32 | static_cast(d)) > 0); + this->SetStackedEffect(0x43B, c > 0); break; case EFST_HALLUCINATIONWALK: case EFST_NPC_HALLUCINATIONWALK: { while (this->HasId(0x318)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x318, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x318, 0, 0, 0, 0, 0); } - if ((static_cast(e) << 32 | static_cast(d)) == 0) { + if (c == 0) { break; } CRagEffect* effect = this->LaunchEffect(0x318, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3557,91 +3552,91 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case EFST_SOULFALCON: case EFST_SOULGOLEM: if (this->render.accountId == g_session.m_aid) { - if ((static_cast(e) << 32 | static_cast(d)) != 0) { + if (c != 0) { g_weatherEffect.StartDarken(); break; } g_weatherEffect.StopDarken(); - } else if ((static_cast(e) << 32 | static_cast(d)) != 0) { + } else if (c != 0) { break; } while (this->HasId(0x1A8)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1A8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1A8, 0, 0, 0, 0, 0); } break; case EFST_HAPPINESS_STAR: - if ((static_cast(e) << 32 | static_cast(d)) > 0) { + if (c > 0) { this->SetStackedEffect(0x43F, true); } else { this->SetStackedEffect(0x43F, false); } break; case EFST_FSTONE: - if ((static_cast(e) << 32 | static_cast(d)) > 0) { + if (c > 0) { this->SetStackedEffect(0x43C, true); } else { this->SetStackedEffect(0x43C, false); } break; case EFST_QSCARABA: - if ((static_cast(e) << 32 | static_cast(d)) > 0) { + if (c > 0) { this->SetStackedEffect(0x43D, true); } else { this->SetStackedEffect(0x43D, false); } break; case EFST_LJOSALFAR: - if ((static_cast(e) << 32 | static_cast(d)) > 0) { + if (c > 0) { this->SetStackedEffect(0x43E, true); } else { this->SetStackedEffect(0x43E, false); } break; case EFST_MAPLE_FALLS: - if ((static_cast(e) << 32 | static_cast(d)) > 0) { + if (c > 0) { this->SetStackedEffect(0x441, true); } else { this->SetStackedEffect(0x441, false); } break; case EFST_DRESS_UP: - g_session.playerAppearanceState = g_session.m_aid == this->render.accountId ? f : g_session.playerAppearanceState; - this->mountedState = f; + g_session.playerAppearanceState = g_session.m_aid == this->render.accountId ? static_cast(d) : g_session.playerAppearanceState; + this->mountedState = static_cast(d); this->SetSprJob(this->GetEffectiveJob(-1)); this->SetImfFileName(); this->SetHeadPaletteName(); this->SetBodyPaletteName(); break; case EFST_MARKING_USE_CHANGEMONSTER: - if ((static_cast(e) << 32 | static_cast(d)) != 0) { + if (c != 0) { g_effectMgr->Spawn(this->render.accountId, 0x442, this->render.position, 0, -1, 0, 0); } else { g_effectMgr->Retire(this->render.accountId, 0x442); } break; case EFST_MAGICAL_FEATHER: - if ((static_cast(e) << 32 | static_cast(d)) > 0) { + if (c > 0) { this->SetStackedEffect(0x443, true); } else { this->SetStackedEffect(0x443, false); } break; case EFST_MERMAID_LONGING: - if ((static_cast(e) << 32 | static_cast(d)) > 0) { + if (c > 0) { this->SetStackedEffect(0x444, true); } else { this->SetStackedEffect(0x444, false); } break; case EFST_TIME_ACCESSORY: - if ((static_cast(e) << 32 | static_cast(d)) > 0) { + if (c > 0) { this->SetStackedEffect(0x447, true); } else { this->SetStackedEffect(0x447, false); } break; case EFST_HEAD_EQUIPMENT_EFFECT: - this->SetStackedEffect(f + 0x9B5, (static_cast(e) << 32 | static_cast(d)) > 0); + this->SetStackedEffect(static_cast(d) + 0x9B5, c > 0); break; case EFST_SPRITEMABLE: g_effectMgr->Retire(this->render.accountId, 0x448); @@ -3708,7 +3703,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case EFST_IMMUNE_PROPERTY_DARKNESS: case EFST_IMMUNE_PROPERTY_TELEKINESIS: case EFST_IMMUNE_PROPERTY_UNDEAD: { - const int effectId = b + 0x87; + const int effectId = static_cast(b) + 0x87; if (on == true) { g_effectMgr->Spawn(this->render.accountId, effectId, vector3d{0.0f, 0.0f, 0.0f}, 0, -1, 0, 0); } else if (g_effectMgr->Has(this->render.accountId, effectId) == true) { @@ -3790,14 +3785,14 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case EFST_ASSUMPTIO2: case EFST_ASSUMPTIO_BUFF: while (this->HasId(0x177)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x177, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x177, 0, 0, 0, 0, 0); } - if ((static_cast(e) << 32 | static_cast(d)) != 0) { + if (c != 0) { this->LaunchEffect(0x177, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } break; case EFST_SOULCURSE: - if ((static_cast(e) << 32 | static_cast(d)) == 1) { + if (c == 1) { if (g_effectMgr->Find(this->render.accountId, 0x552)) { break; } @@ -3830,7 +3825,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, actor = static_cast(mode->scene->GetGameActorByAID(actor->render.accountId)); } if (actor->HasId(0x576)) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x576, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0x576, 0, 0, 0, 0, 0); } if (on == true) { actor->LaunchEffect(0x576, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3843,7 +3838,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, actor = static_cast(mode->scene->GetGameActorByAID(actor->render.accountId)); } if (actor->HasId(0x18C)) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x18C, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0x18C, 0, 0, 0, 0, 0); } if (on == true) { actor->LaunchEffect(0x18C, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3856,7 +3851,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, actor = static_cast(mode->scene->GetGameActorByAID(actor->render.accountId)); } if (actor->HasId(0x58C)) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x58C, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0x58C, 0, 0, 0, 0, 0); } if (on == true) { actor->LaunchEffect(0x58C, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3869,7 +3864,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, actor = static_cast(mode->scene->GetGameActorByAID(actor->render.accountId)); } if (actor->HasId(0x5F5)) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x5F5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0x5F5, 0, 0, 0, 0, 0); } if (on == true) { actor->LaunchEffect(0x5F5, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3884,8 +3879,8 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, if (!target) { break; } - if ((static_cast(e) << 32 | static_cast(d)) == 1) { - if ((static_cast(g) << 32 | static_cast(f)) == 2) { + if (c == 1) { + if (d == 2) { target->SetMadogearType(2); if (this->render.accountId == g_session.m_aid) { g_session.madogearType = 2; @@ -3896,13 +3891,13 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, g_session.madogearType = 1; } } - target->SendMsg(nullptr, AM_MAKE_CHICKEN, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_MAKE_CHICKEN, 0, 0, 0, 0, 0, 0); } else { target->SetMadogearType(0); if (this->render.accountId == g_session.m_aid) { g_session.madogearType = 0; } - target->SendMsg(nullptr, AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0); } break; } @@ -3929,7 +3924,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; } if (actor->HasId(0x641)) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x641, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0x641, 0, 0, 0, 0, 0); } if (on == true) { actor->LaunchEffect(0x641, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3945,7 +3940,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; } if (actor->HasId(0x64A)) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x64A, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0x64A, 0, 0, 0, 0, 0); } if (on == true) { actor->LaunchEffect(0x64A, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3956,47 +3951,47 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, if (this->render.accountId != g_session.m_aid) { break; } - if ((static_cast(e) << 32 | static_cast(d)) == 1) { + if (c == 1) { if (!this->HasId(0x14E)) { this->LaunchEffect(0x14E, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } g_overrideColor = 1; - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0xA4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0xA4, 0, 0, 0, 0, 0); CPlayer* const player = static_cast(g_modeMgr.GetGameMode())->scene->player; if (player) { player->skillEffect = this->LaunchEffect(0xA4, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } } else { if (this->HasId(0x14E) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x14E, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x14E, 0, 0, 0, 0, 0); } g_overrideColor = 0; } this->SetInstantValue(0x10, on); break; case EFST_HANDICAPSTATE_DEEPSILENCE: - if ((static_cast(e) << 32 | static_cast(d)) == 1) { - this->SendMsg(nullptr, AM_MAKE_DEEPSILENCE_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + if (c == 1) { + this->SendMsg(nullptr, AM_MAKE_DEEPSILENCE_EFFECT, 0, 0, 0, 0, 0, 0); } else { - this->SendMsg(nullptr, AM_DELETE_DEEPSILENCE_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_DEEPSILENCE_EFFECT, 0, 0, 0, 0, 0, 0); } break; case EFST_HANDICAPSTATE_SWOONING: - if ((static_cast(e) << 32 | static_cast(d)) == 1) { - this->SendMsg(nullptr, AM_MAKE_DEEPSILENCE_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + if (c == 1) { + this->SendMsg(nullptr, AM_MAKE_DEEPSILENCE_EFFECT, 0, 0, 0, 0, 0, 0); g_effectMgr->Retire(this->render.accountId, 0x8C5); g_effectMgr->Spawn(this->render.accountId, 0x8C5, vector3d{0.0f, 0.0f, 0.0f}, 0, -1, 0, 0); } else { - this->SendMsg(nullptr, AM_DELETE_DEEPSILENCE_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_DEEPSILENCE_EFFECT, 0, 0, 0, 0, 0, 0); g_effectMgr->Retire(this->render.accountId, 0x8C5); } break; case EFST_HANDICAPSTATE_LASSITUDE: - if ((static_cast(e) << 32 | static_cast(d)) == 1) { - this->SendMsg(nullptr, AM_MAKE_LASSITUDE_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + if (c == 1) { + this->SendMsg(nullptr, AM_MAKE_LASSITUDE_EFFECT, 0, 0, 0, 0, 0, 0); g_effectMgr->Spawn(this->render.accountId, 0x8C4, vector3d{0.0f, 0.0f, 0.0f}, 0, -1, 0, 0); } else { - this->SendMsg(nullptr, AM_DELETE_LASSITUDE_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_LASSITUDE_EFFECT, 0, 0, 0, 0, 0, 0); } break; case EFST_HANDICAPSTATE_FROSTBITE: @@ -4029,46 +4024,46 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_HANDICAPSTATE_HOLYFLAME: if (on == true) { - this->SendMsg(nullptr, AM_CHANGE_COLOR, 0, 0xFF, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CHANGE_COLOR, 0xFF, 0, 0, 0, 0, 0); g_effectMgr->Spawn(this->render.accountId, 0x8C6, vector3d{0.0f, 0.0f, 0.0f}, 0, -1, 0, 0); } else { - this->SendMsg(nullptr, AM_RETURN_COLOR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_RETURN_COLOR, 0, 0, 0, 0, 0, 0); } this->SetInstantValue(0xC, on); break; case EFST_HANDICAPSTATE_CONFLAGRATION: if (on == true) { - this->SendMsg(nullptr, AM_CHANGE_COLOR, 0, 0xFF, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CHANGE_COLOR, 0xFF, 0, 0, 0, 0, 0); g_effectMgr->Retire(this->render.accountId, 0x8DD); g_effectMgr->Spawn(this->render.accountId, 0x8DD, vector3d{0.0f, 0.0f, 0.0f}, 0, -1, 0, 0); } else { - this->SendMsg(nullptr, AM_RETURN_COLOR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_RETURN_COLOR, 0, 0, 0, 0, 0, 0); g_effectMgr->Retire(this->render.accountId, 0x8DD); } this->SetInstantValue(0xD, on); break; case EFST_HANDICAPSTATE_MISFORTUNE: if (on == true) { - this->SendMsg(nullptr, AM_MAKE_MISFORTUNE_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_MISFORTUNE_EFFECT, 0, 0, 0, 0, 0, 0); } else { - this->SendMsg(nullptr, AM_DELETE_MISFORTUNE_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_MISFORTUNE_EFFECT, 0, 0, 0, 0, 0, 0); } break; case EFST_HANDICAPSTATE_DEADLYPOISON: if (on == true) { - this->SendMsg(nullptr, AM_CHANGE_COLOR, 0, 0xAA, 0, 0, 0, 0xAA, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CHANGE_COLOR, 0xAA, 0, 0xAA, 0, 0, 0); g_effectMgr->Spawn(this->render.accountId, 0x8E2, vector3d{0.0f, 0.0f, 0.0f}, 0, -1, 0, 0); } else { - this->SendMsg(nullptr, AM_RETURN_COLOR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_RETURN_COLOR, 0, 0, 0, 0, 0, 0); g_effectMgr->Retire(this->render.accountId, 0x8E2); } this->SetInstantValue(0xE, on); break; case EFST_HANDICAPSTATE_DEPRESSION: if (on == true) { - this->SendMsg(nullptr, AM_CHANGE_COLOR, 0, 0, 0, 0, 0, 0xFF, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CHANGE_COLOR, 0, 0, 0xFF, 0, 0, 0); } else { - this->SendMsg(nullptr, AM_RETURN_COLOR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_RETURN_COLOR, 0, 0, 0, 0, 0, 0); } this->SetInstantValue(0xF, on); break; @@ -4149,7 +4144,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, case EFST_CLIMAX: g_effectMgr->Retire(this->render.accountId, 0x708); if (on == true) { - g_effectMgr->Spawn(this->render.accountId, 0x708, this->render.position, 0, f, 0, 0); + g_effectMgr->Spawn(this->render.accountId, 0x708, this->render.position, 0, static_cast(d), 0, 0); } break; case EFST_FIRST_FAITH_POWER: @@ -4244,7 +4239,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; case EFST_E_SLASH_COUNT: if (on == true) { - g_effectMgr->Spawn(this->render.accountId, 0x779, this->render.position, 0, f, 0, 0); + g_effectMgr->Spawn(this->render.accountId, 0x779, this->render.position, 0, static_cast(d), 0, 0); } else { g_effectMgr->Retire(this->render.accountId, 0x779); } @@ -4253,7 +4248,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, if (on == true) { this->LaunchEffect(0x2e8, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } else if (this->HasId(0x2e8) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x2e8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x2e8, 0, 0, 0, 0, 0); } break; case EFST_BO_HELL_DUSTY: @@ -4265,14 +4260,14 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, if (on == true) { this->LaunchEffect(0x8e5, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } else if (this->HasId(0x8e5) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x8e5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x8e5, 0, 0, 0, 0, 0); } break; case EFST_SPORE_EXPLOSION_DEBUFF: if (on == true) { this->LaunchEffect(0x8e6, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } else if (this->HasId(0x8e6) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x8e6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x8e6, 0, 0, 0, 0, 0); } break; case EFST_FIRM_FAITH: @@ -4327,9 +4322,9 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; default: if (on == true) { - CSkillActionMgr::GetInstance()->OnEfstBegin(b, f, h, l, this, (static_cast(k) << 32 | static_cast(j)) != 0); + CSkillActionMgr::GetInstance()->OnEfstBegin(static_cast(b), static_cast(d), static_cast(e), static_cast(g), this, f != 0); } else { - CSkillActionMgr::GetInstance()->OnEfstEnd(b, f, h, l, this); + CSkillActionMgr::GetInstance()->OnEfstEnd(static_cast(b), static_cast(d), static_cast(e), static_cast(g), this); } break; } @@ -4348,11 +4343,11 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, unsigned char* const target = reinterpret_cast(&this->render.targetTintColor); target[0] = 0xFF; target[1] = static_cast(b); - target[2] = static_cast(d); - target[3] = static_cast(f); - const std::int64_t red = static_cast(c) << 32 | static_cast(b); - const std::int64_t green = static_cast(e) << 32 | static_cast(d); - this->render.color = static_cast(red << 16 | green << 8 | f | 0xFF000000); + target[2] = static_cast(c); + target[3] = static_cast(d); + const std::int64_t red = b; + const std::int64_t green = c; + this->render.color = static_cast(red << 16 | green << 8 | static_cast(d) | 0xFF000000); break; } case AM_RETURN_COLOR: @@ -4389,19 +4384,19 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, } if (CEffect* fallenAngel = g_effectMgr->Find(this->render.accountId, 0x474)) { vector3d position{0.0f, 0.0f, 0.0f}; - static_cast(g_modeMgr.GetGameMode())->CellCenter(b, d, position.x, position.z); + static_cast(g_modeMgr.GetGameMode())->CellCenter(static_cast(b), static_cast(c), position.x, position.z); position.y = this->render.position.y; static_cast(fallenAngel)->SetPosition(position); } } - this->SendMsg(nullptr, AM_STOPMOVE, 0, b, b >> 31, d, d >> 31, 15, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_STOPMOVE, b, d, 15, 0, 0, 0); this->SetAction(this->render.animation, 6, 1); this->render.curMotion = 7; this->render.isMotionFreezed = true; break; case AM_UPDATE_MONSTER_GAGE: - if ((static_cast(c) << 32 | static_cast(b)) == -1 || - (static_cast(e) << 32 | static_cast(d)) == -1) { + if (b == -1 || + c == -1) { if (this->hpGaugeWindow == 0) { break; } @@ -4409,7 +4404,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, this->hpGaugeWindow = 0; break; } - if ((static_cast(g) << 32 | static_cast(f)) == 1 && this->hpGaugeWindow != 0) { + if (d == 1 && this->hpGaugeWindow != 0) { g_windowMgr.Schedule(reinterpret_cast(this->hpGaugeWindow)); this->hpGaugeWindow = 0; } @@ -4419,7 +4414,7 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, gage->SetSize(60, 5); g_windowMgr.AddRenderedFront(reinterpret_cast(this->hpGaugeWindow)); } - reinterpret_cast(this->hpGaugeWindow)->SetValues(b, d); + reinterpret_cast(this->hpGaugeWindow)->SetValues(static_cast(b), static_cast(c)); reinterpret_cast(this->hpGaugeWindow)->Move( this->render.screenX - reinterpret_cast(this->hpGaugeWindow)->geometry.width / 2, static_cast(static_cast(ScaleByScreenHeight(12)) * this->render.distanceScale + static_cast(this->render.screenY)) @@ -4429,13 +4424,13 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, if (this->firstFollowerEffect == 0) { CGameObject* effect = mode->SpawnMsgEffect(68, &this->render.position, this->render.accountId, true); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); this->firstFollowerEffect = reinterpret_cast(effect); } break; case AM_DELETE_MISFORTUNE_EFFECT: if (this->firstFollowerEffect != 0) { - reinterpret_cast(this->firstFollowerEffect)->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + reinterpret_cast(this->firstFollowerEffect)->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); this->firstFollowerEffect = 0; } break; @@ -4443,18 +4438,18 @@ void CGameActor::SendMsg(CGameObject* sender, int message, int a, int b, int c, if (this->secondFollowerEffect == 0) { CGameObject* effect = mode->SpawnMsgEffect(9, &this->render.position, this->render.accountId, true); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); this->secondFollowerEffect = reinterpret_cast(effect); } break; case AM_DELETE_DEEPSILENCE_EFFECT: if (this->secondFollowerEffect != 0) { - reinterpret_cast(this->secondFollowerEffect)->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + reinterpret_cast(this->secondFollowerEffect)->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); this->secondFollowerEffect = 0; } break; default: - this->EffectActor::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + this->EffectActor::SendMsg(sender, message, b, c, d, e, 0, 0); break; } } diff --git a/Source/Contents/Actors/GameObject.h b/Source/Contents/Actors/GameObject.h index d7e5b4d5e..a61a29663 100644 --- a/Source/Contents/Actors/GameObject.h +++ b/Source/Contents/Actors/GameObject.h @@ -10,7 +10,7 @@ public: CGameObject(); virtual ~CGameObject(); virtual bool OnProcess(); - virtual void SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m); + virtual void SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g); virtual void Render(int argument); virtual int Get8Dir(float angle); int Get8Dir2(float rot, int flag); diff --git a/Source/Contents/Actors/GndRiser.h b/Source/Contents/Actors/GndRiser.h index 155f243a1..7695743bb 100644 --- a/Source/Contents/Actors/GndRiser.h +++ b/Source/Contents/Actors/GndRiser.h @@ -10,7 +10,7 @@ public: CGndRiser(); bool OnProcess() override; void SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) override; void Render(int argument) override; diff --git a/Source/Contents/Actors/GroundScope.cpp b/Source/Contents/Actors/GroundScope.cpp index b82d09a8b..778814ca6 100644 --- a/Source/Contents/Actors/GroundScope.cpp +++ b/Source/Contents/Actors/GroundScope.cpp @@ -190,27 +190,27 @@ void CGroundScope::Render(int argument) { // OFFSET: 0x00E50DB0 // FUNCTION: fn_24299 -void CGroundScope::SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int, int, int, int) { - switch (static_cast(a) << 32 | static_cast(message)) { +void CGroundScope::SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) { + switch (message) { case AM_SETPOS: - this->m_cellX = b; - this->m_cellY = d; + this->m_cellX = static_cast(b); + this->m_cellY = static_cast(c); return; case AM_SETMASTERGID: - this->m_masterGid = b; + this->m_masterGid = static_cast(b); return; case AM_SETTIME: - this->m_lastingTime = b; + this->m_lastingTime = static_cast(b); return; case AM_SET_SKILL: - this->m_size = this->SkillScopeType(b) + 2; + this->m_size = this->SkillScopeType(static_cast(b)) + 2; this->m_angleSpeed = this->m_size != 0 ? 0.5f / static_cast(this->m_size) : 0.0f; - this->m_skillId = b; + this->m_skillId = static_cast(b); return; } - this->EffectActor::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + this->EffectActor::SendMsg(sender, message, b, c, d, e, 0, 0); } diff --git a/Source/Contents/Actors/GroundScope.h b/Source/Contents/Actors/GroundScope.h index 20e5616db..3153fb54e 100644 --- a/Source/Contents/Actors/GroundScope.h +++ b/Source/Contents/Actors/GroundScope.h @@ -11,7 +11,7 @@ class CGroundScope : public EffectActor { public: CGroundScope(); bool OnProcess() override; - void SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m) override; + void SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) override; void Render(int argument) override; int SkillScopeType(int skillId); diff --git a/Source/Contents/Actors/Item.cpp b/Source/Contents/Actors/Item.cpp index d8f1aeacb..8c7c4a3b5 100644 --- a/Source/Contents/Actors/Item.cpp +++ b/Source/Contents/Actors/Item.cpp @@ -131,14 +131,14 @@ void CItem::Render(int argument) { // OFFSET: 0x00D8B720 // FUNCTION: fn_22252 -void CItem::SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int, int, int, int) { +void CItem::SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) { CGameMode* mode = static_cast(g_modeMgr.GetGameMode()); - if (message != 4 || a != 0) { - this->EffectActor::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + if (message != 4) { + this->EffectActor::SendMsg(sender, message, b, c, d, e, 0, 0); return; } - const ItemFallEntry* entry = reinterpret_cast(b); + const ItemFallEntry* entry = reinterpret_cast(static_cast(b)); this->itemAid = entry->aid; this->name = entry->itemId; std::string itemName = this->name; diff --git a/Source/Contents/Actors/Item.h b/Source/Contents/Actors/Item.h index 905e9497c..62a103a27 100644 --- a/Source/Contents/Actors/Item.h +++ b/Source/Contents/Actors/Item.h @@ -13,7 +13,7 @@ public: void SubD8B5A0(); void SubD8B5B0(); bool OnProcess() override; - void SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m) override; + void SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) override; void Render(int argument) override; void SetRenderInfo(const float* bounds, float x, float y) override; diff --git a/Source/Contents/Actors/MousePointer.cpp b/Source/Contents/Actors/MousePointer.cpp index a9865296a..b865a6e7f 100644 --- a/Source/Contents/Actors/MousePointer.cpp +++ b/Source/Contents/Actors/MousePointer.cpp @@ -24,23 +24,23 @@ bool CMousePointer::OnProcess() { // OFFSET: 0x00CBF860 // FUNCTION: fn_21114 -void CMousePointer::SendMsg(CGameObject*, int message, int a, int b, int c, int d, int e, int, int, int, int, int, int, int, int) { - if (message == 1 && a == 0) { - const float* const position = reinterpret_cast(b); +void CMousePointer::SendMsg(CGameObject*, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t, std::int64_t, std::int64_t, std::int64_t) { + if (message == 1) { + const float* const position = reinterpret_cast(static_cast(b)); this->render.position.x = position[0]; this->render.position.z = position[1]; CGameMode* mode = static_cast(g_modeMgr.GetGameMode()); this->render.position.y = mode->scene->terrain->Height(this->render.position.x, this->render.position.z); this->render.visible = 1; this->m_remainingFrames = 0; - if ((d | e) != 0) { + if (c != 0) { this->render.color = 0xFFFF0000; } else { this->render.color = 0xFFFFFFFF; } - } else if (message == 2 && a == 0) { - if ((b | c) != 0) { - this->m_remainingFrames = b; + } else if (message == 2) { + if (b != 0) { + this->m_remainingFrames = static_cast(b); } else { this->render.visible = 0; } diff --git a/Source/Contents/Actors/MousePointer.h b/Source/Contents/Actors/MousePointer.h index 8f5c6f791..d353756cd 100644 --- a/Source/Contents/Actors/MousePointer.h +++ b/Source/Contents/Actors/MousePointer.h @@ -11,7 +11,7 @@ class CMousePointer : public CRenderObject { public: CMousePointer(); bool OnProcess() override; - void SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m) override; + void SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) override; /* 0138 */ int m_remainingFrames; /* 013C */ int padding_013C; diff --git a/Source/Contents/Actors/Npc.h b/Source/Contents/Actors/Npc.h index f81e7f386..4aacb2003 100644 --- a/Source/Contents/Actors/Npc.h +++ b/Source/Contents/Actors/Npc.h @@ -14,7 +14,7 @@ public: ~CNpc() override; bool OnProcess() override; void SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) override; void Render(int argument) override; void SetState(int state, int unused) override; @@ -52,7 +52,7 @@ public: CCharacterNpc(); ~CCharacterNpc() override; void SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) override; void Render(int argument) override; void SetSprJob(int value) override; @@ -66,7 +66,7 @@ public: ~CHalluNPC() override; bool OnProcess() override; void SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) override; void Render(int argument) override; @@ -84,7 +84,7 @@ public: ~CHalluPlant() override; bool OnProcess() override; void SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) override; void Render(int argument) override; diff --git a/Source/Contents/Actors/Pc.h b/Source/Contents/Actors/Pc.h index fa03c95bd..2a8106081 100644 --- a/Source/Contents/Actors/Pc.h +++ b/Source/Contents/Actors/Pc.h @@ -35,7 +35,7 @@ public: ~CPc() override; bool OnProcess() override; void SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) override; void Render(int argument) override; @@ -165,7 +165,7 @@ public: ~CBlurPC() override; bool OnProcess() override; void SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) override; void Render(int argument) override; }; @@ -176,7 +176,7 @@ public: ~CHalluPC() override; bool OnProcess() override; void SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) override; void Render(int argument) override; @@ -190,7 +190,7 @@ public: ~CHalluPC2() override; bool OnProcess() override; void SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) override; void Render(int argument) override; @@ -203,7 +203,7 @@ public: CPlayer(); bool OnProcess() override; void SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) override; static int AngleToDirection(float angle); @@ -256,7 +256,7 @@ class CGrannyPc : public CGameActor { public: bool OnProcess() override; void SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) override; void Render(int argument) override; void SetAction(unsigned animation, int motion, int repeat) override; diff --git a/Source/Contents/Actors/Player.cpp b/Source/Contents/Actors/Player.cpp index 7889bd1a0..172173be0 100644 --- a/Source/Contents/Actors/Player.cpp +++ b/Source/Contents/Actors/Player.cpp @@ -274,9 +274,9 @@ void CPc::SetHeadPalette(int value) { void CGrannyPc::SetHonor(int value) { if (value < 0) { const std::int64_t emotion = g_cashEmotionMgr->GetSpecialEmotion(CashEmotionSpecial::ChatProhibit); - this->SendMsg(nullptr, AM_CASH_EMOTION, 0, 0, 0, static_cast(emotion), static_cast(emotion >> 32), 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CASH_EMOTION, 0, emotion, 0, 0, 0, 0); } else { - this->SendMsg(nullptr, AM_DELETE_PROHIBITEFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_PROHIBITEFFECT, 0, 0, 0, 0, 0, 0); } this->honor = value; } @@ -286,9 +286,9 @@ void CGrannyPc::SetHonor(int value) { void CPc::SetHonor(int value) { if (value < 0) { const std::int64_t emotion = g_cashEmotionMgr->GetSpecialEmotion(CashEmotionSpecial::ChatProhibit); - this->SendMsg(nullptr, AM_CASH_EMOTION, 0, 0, 0, static_cast(emotion), static_cast(emotion >> 32), 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CASH_EMOTION, 0, emotion, 0, 0, 0, 0); } else { - this->SendMsg(nullptr, AM_DELETE_PROHIBITEFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_PROHIBITEFFECT, 0, 0, 0, 0, 0, 0); } this->honor = value; } @@ -1503,9 +1503,9 @@ void CPc::SetSprAccessory2(int value) { ); if (this->HasId(678)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 678, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 679, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 680, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 678, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 679, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 680, 0, 0, 0, 0, 0); } } @@ -2151,7 +2151,7 @@ void CPc::RenderOverlaySprite(const float* matrix, int) { } int effectId; - this->SendMsg(nullptr, AM_IS_HAVE_EFFECT, 0, reinterpret_cast(&effectId), reinterpret_cast(&effectId) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_IS_HAVE_EFFECT, reinterpret_cast(&effectId), 0, 0, 0, 0, 0); this->DrawQuad(quad, palette, 0x101, 0.0f, 0.0f, 0); } @@ -2270,7 +2270,7 @@ bool CPc::OnProcess() { if (!this->msgEffect) { CMsgEffect* effect = static_cast(g_modeMgr.GetGameMode())->SpawnMsgEffect(44, &this->render.position, this->render.accountId, true); this->AddMsgEffect(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); this->msgEffect = effect; } return result; @@ -2278,7 +2278,7 @@ bool CPc::OnProcess() { } if (this->msgEffect) { - this->msgEffect->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->msgEffect->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); this->msgEffect = nullptr; } @@ -2599,7 +2599,7 @@ __declspec(noinline) void CPlayer::UpdateMsgEffect(bool show) { if (!this->msgEffect) { CMsgEffect* effect = static_cast(g_modeMgr.GetGameMode())->SpawnMsgEffect(44, &this->render.position, this->render.accountId, true); this->AddMsgEffect(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); this->msgEffect = effect; } return; @@ -2607,7 +2607,7 @@ __declspec(noinline) void CPlayer::UpdateMsgEffect(bool show) { } if (this->msgEffect) { - this->msgEffect->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->msgEffect->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); this->msgEffect = nullptr; } } @@ -2861,7 +2861,7 @@ bool CPlayer::OnProcess() { request.destinationX = reinterpret_cast(this->destCellX); request.destinationY = this->destCellZ; const long long address = reinterpret_cast(&request); - this->SendMsg(nullptr, AM_MOVE, 0, static_cast(address), static_cast(address >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MOVE, address, 0, 0, 0, 0, 0); } this->UpdatePendingAction(); @@ -2953,13 +2953,13 @@ void CPlayer::UpdatePendingAction() { reinterpret_cast(this->destCellX) = cellX; this->destCellZ = cellY; this->tickOfMoveForAttack = timeGetTime(); - this->SendMsg(nullptr, AM_REQ_MOVE_PRIMITIVE, 0, cellX, cellX >> 31, cellY, cellY >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_REQ_MOVE_PRIMITIVE, cellX, cellY, 0, 0, 0, 0); } return; } if (this->attackMode == 2) { - this->SendMsg(nullptr, AM_CANCELATTACK, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CANCELATTACK, 0, 0, 0, 0, 0, 0); } if (this->isAttackRequest != 0 || timeGetTime() <= this->attackReqTime + 1200) { return; @@ -2968,9 +2968,9 @@ void CPlayer::UpdatePendingAction() { this->attackReqTime = timeGetTime(); this->isAttackRequest = 1; if (this->attackMode != 2) { - this->SendMsg(nullptr, AM_REQ_ATTACK_REPEAT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_REQ_ATTACK_REPEAT, 0, 0, 0, 0, 0, 0); } else { - this->SendMsg(nullptr, AM_REQ_ATTACK, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_REQ_ATTACK, 0, 0, 0, 0, 0, 0); } return; } @@ -3004,7 +3004,7 @@ void CPlayer::UpdatePendingAction() { ); const bool inRange = static_cast(range * 5) + 5.5f >= distance; if ((reinterpret_cast(this->destCellX) == column && this->destCellZ == row) || inRange) { - this->SendMsg(nullptr, AM_REQ_SKILL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_REQ_SKILL, 0, 0, 0, 0, 0, 0); break; } @@ -3017,7 +3017,7 @@ void CPlayer::UpdatePendingAction() { this->destCellZ = cellY; reinterpret_cast(this->destCellX) = cellX; this->ApplyFollowOffset(target, x, z, &cellY, &cellX); - this->SendMsg(nullptr, AM_REQ_MOVE_PRIMITIVE, 0, cellX, cellX >> 31, cellY, cellY >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_REQ_MOVE_PRIMITIVE, cellX, cellY, 0, 0, 0, 0); return; } case PT_GROUNDSKILL: { @@ -3039,7 +3039,7 @@ void CPlayer::UpdatePendingAction() { const float distance = this->CalcDist(x, this->render.position.y, z); const bool inRange = static_cast(range * 5) + 5.5f >= distance; if ((reinterpret_cast(this->destCellX) == column && this->destCellZ == row) || inRange) { - this->SendMsg(nullptr, AM_REQ_GROUND_SKILL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_REQ_GROUND_SKILL, 0, 0, 0, 0, 0, 0); break; } @@ -3051,7 +3051,7 @@ void CPlayer::UpdatePendingAction() { } this->destCellZ = groundY; reinterpret_cast(this->destCellX) = groundX; - this->SendMsg(nullptr, AM_REQ_MOVE_PRIMITIVE, 0, groundX, groundX >> 31, groundY, groundY >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_REQ_MOVE_PRIMITIVE, groundX, groundY, 0, 0, 0, 0); return; } case PT_PICKUPITEM: { @@ -3075,7 +3075,7 @@ void CPlayer::UpdatePendingAction() { } if (mode->IsWithinRange(column, row, targetX, targetY, 1)) { - this->SendMsg(nullptr, AM_REQ_CHANGE_DIR, 0, targetX, targetX >> 31, targetY, targetY >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_REQ_CHANGE_DIR, targetX, targetY, 0, 0, 0, 0); if (!mode->HasPendingItemPickup(this->proceedTargetGid)) { mode->AddPendingItemPickup(this->proceedTargetGid); mode->SendMsg(MM_ITEMPICKUP, this->proceedTargetGid, 0, 0, 0); @@ -3088,7 +3088,7 @@ void CPlayer::UpdatePendingAction() { } this->destCellZ = itemY; reinterpret_cast(this->destCellX) = itemX; - this->SendMsg(nullptr, AM_REQ_MOVE_PRIMITIVE, 0, itemX, itemX >> 31, itemY, itemY >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_REQ_MOVE_PRIMITIVE, itemX, itemY, 0, 0, 0, 0); return; } case PT_TOUCH_SKILL: { @@ -3128,7 +3128,7 @@ void CPlayer::UpdatePendingAction() { } this->destCellZ = cellY; reinterpret_cast(this->destCellX) = cellX; - this->SendMsg(nullptr, AM_REQ_MOVE_PRIMITIVE, 0, cellX, cellX >> 31, cellY, cellY >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_REQ_MOVE_PRIMITIVE, cellX, cellY, 0, 0, 0, 0); return; } @@ -3145,7 +3145,7 @@ void CPlayer::UpdatePendingAction() { case UNT_FLAMETRAP: if (this->skillId == 0) { if (this->attackMode == 2) { - this->SendMsg(nullptr, AM_CANCELATTACK, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CANCELATTACK, 0, 0, 0, 0, 0, 0); } if (this->isAttackRequest != 0 || timeGetTime() <= this->attackReqTime + 1200) { return; @@ -3154,22 +3154,22 @@ void CPlayer::UpdatePendingAction() { this->attackReqTime = timeGetTime(); this->isAttackRequest = 1; if (this->attackMode != 2) { - this->SendMsg(nullptr, AM_REQ_ATTACK_REPEAT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_REQ_ATTACK_REPEAT, 0, 0, 0, 0, 0, 0); } else { - this->SendMsg(nullptr, AM_REQ_ATTACK, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_REQ_ATTACK, 0, 0, 0, 0, 0, 0); } return; } break; } - this->SendMsg(nullptr, AM_REQ_SKILL, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_REQ_SKILL, 0, 0, 0, 0, 0, 0); break; } default: return; } - this->SendMsg(nullptr, AM_CANCELATTACK, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CANCELATTACK, 0, 0, 0, 0, 0, 0); } // OFFSET: 0x00DB68B0 @@ -3293,12 +3293,12 @@ void CPlayer::ReapplySkillEffects() { } for (int id = 0x1DB; id < 0x1E5; ++id) { if (this->HasId(id) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, id, id >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, id, 0, 0, 0, 0, 0); } } this->LaunchEffect(effectId, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0xA4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0xA4, 0, 0, 0, 0, 0); this->skillEffect = this->LaunchEffect(0xA4, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; } @@ -3325,7 +3325,7 @@ void CPlayer::ReapplySkillEffects() { break; case EFST_DUPLELIGHT: { while (this->HasId(0x341)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x341, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x341, 0, 0, 0, 0, 0); } CRagEffect* effect = this->LaunchEffect(0x341, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); vector3d scale{2.0f, 0.0f, 0.0f}; @@ -3342,7 +3342,7 @@ void CPlayer::ReapplySkillEffects() { break; case EFST_STRIKING: { while (this->HasId(0x39D)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x39D, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x39D, 0, 0, 0, 0, 0); } CRagEffect* effect = this->LaunchEffect(0x39D, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); if (effect) { @@ -3436,24 +3436,24 @@ void CPlayer::ReapplySkillEffects() { break; case EFST_MELODYOFSINK: if (this->HasId(0x57) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x57, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x57, 0, 0, 0, 0, 0); } this->LaunchEffect(0x57, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; case EFST_BEYOND_OF_WARCRY: if (this->HasId(0x31F) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x31F, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x31F, 0, 0, 0, 0, 0); } this->LaunchEffect(0x31F, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; case EFST_SATURDAY_NIGHT_FEVER: if (this->HasId(0x360) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x360, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x360, 0, 0, 0, 0, 0); } this->LaunchEffect(0x360, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; case EFST_EQUIPED_FLOOR: - this->SendMsg(nullptr, AM_STATUS_CHANGE, 0, 0x23B, 0, 1, 0, value, value >> 31, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_STATUS_CHANGE, 0x23B, 1, value, 0, 0, 0); break; case EFST_ALL_RIDING: this->SetRiding(1); @@ -3461,41 +3461,41 @@ void CPlayer::ReapplySkillEffects() { this->SetBodyPalette(this->render.bodyPalette); break; case EFST_ON_PUSH_CART: - this->SendMsg(nullptr, AM_STATUS_CHANGE, 0, type, type >> 31, 1, 0, g_session.replayPacketMode, g_session.replayPacketMode >> 31, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_STATUS_CHANGE, type, 1, g_session.replayPacketMode, 0, 0, 0); break; case EFST_TELEKINESIS_INTENSE: while (this->HasId(0x418)) { - this->SendMsg(this, AM_DELETE_EFFECT, 0, 0x418, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 0x418, 0, 0, 0, 0, 0); } this->LaunchEffect(0x418, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; case EFST_WIDEWEB: while (this->HasId(0x194)) { - this->SendMsg(this, AM_DELETE_EFFECT, 0, 0x194, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 0x194, 0, 0, 0, 0, 0); } this->LaunchEffect(0x194, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; case EFST_BURNT: while (this->HasId(0x41E)) { - this->SendMsg(this, AM_DELETE_EFFECT, 0, 0x41E, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 0x41E, 0, 0, 0, 0, 0); } this->LaunchEffect(0x41E, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; case EFST_CHILL: while (this->HasId(0x41F)) { - this->SendMsg(this, AM_DELETE_EFFECT, 0, 0x41F, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 0x41F, 0, 0, 0, 0, 0); } this->LaunchEffect(0x41F, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; case EFST_OFFERTORIUM: while (this->HasId(0x421)) { - this->SendMsg(this, AM_DELETE_EFFECT, 0, 0x421, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 0x421, 0, 0, 0, 0, 0); } this->LaunchEffect(0x421, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; case EFST_ZANGETSU: while (this->HasId(0x3EB)) { - this->SendMsg(this, AM_DELETE_EFFECT, 0, 0x3EB, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 0x3EB, 0, 0, 0, 0, 0); } this->LaunchEffect(0x3EB, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; @@ -3508,13 +3508,13 @@ void CPlayer::ReapplySkillEffects() { } } while (this->HasId(0x3C3)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x3C3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x3C3, 0, 0, 0, 0, 0); } this->LaunchEffect(0x3C3, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; case EFST_KAGEMUSYA: while (this->HasId(0x3EC)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x3EC, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x3EC, 0, 0, 0, 0, 0); } this->LaunchEffect(0x3EC, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; @@ -3532,7 +3532,7 @@ void CPlayer::ReapplySkillEffects() { break; case EFST_DARKCROW: while (this->HasId(0x410)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x410, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x410, 0, 0, 0, 0, 0); } this->LaunchEffect(0x410, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); this->LaunchEffect(0x410, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -3541,7 +3541,7 @@ void CPlayer::ReapplySkillEffects() { case EFST_HALLUCINATIONWALK: case EFST_NPC_HALLUCINATIONWALK: { while (this->HasId(0x318)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x318, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x318, 0, 0, 0, 0, 0); } CRagEffect* effect = this->LaunchEffect(0x318, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); if (effect) { @@ -3659,19 +3659,19 @@ void CPlayer::ReapplySkillEffects() { break; case EFST_HANDICAPSTATE_DEEPBLIND: if (this->HasId(0x14E) == true) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x14E, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x14E, 0, 0, 0, 0, 0); } this->LaunchEffect(0x14E, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); g_overrideColor = 1; - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0xA4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0xA4, 0, 0, 0, 0, 0); this->skillEffect = this->LaunchEffect(0xA4, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); break; case EFST_HANDICAPSTATE_DEEPSILENCE: case EFST_HANDICAPSTATE_SWOONING: - this->SendMsg(nullptr, AM_MAKE_DEEPSILENCE_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_DEEPSILENCE_EFFECT, 0, 0, 0, 0, 0, 0); break; case EFST_HANDICAPSTATE_LASSITUDE: - this->SendMsg(nullptr, AM_MAKE_LASSITUDE_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_LASSITUDE_EFFECT, 0, 0, 0, 0, 0, 0); break; case EFST_HANDICAPSTATE_FROSTBITE: g_effectMgr->Spawn(this->render.accountId, 0x8DE, 0.0f, 0.0f, 0.0f, 0, -1, 0, 0); @@ -3685,21 +3685,21 @@ void CPlayer::ReapplySkillEffects() { g_effectMgr->Spawn(this->render.accountId, 0x8E1, 0.0f, 0.0f, 0.0f, 0, -1, 0, 0); break; case EFST_HANDICAPSTATE_CONFLAGRATION: - this->SendMsg(nullptr, AM_CHANGE_COLOR, 0, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CHANGE_COLOR, 255, 0, 0, 0, 0, 0); g_effectMgr->Retire(this->render.accountId, 0x8DD); g_effectMgr->Spawn(this->render.accountId, 0x8DD, 0.0f, 0.0f, 0.0f, 0, -1, 0, 0); break; case EFST_HANDICAPSTATE_MISFORTUNE: - this->SendMsg(nullptr, AM_MAKE_MISFORTUNE_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_MISFORTUNE_EFFECT, 0, 0, 0, 0, 0, 0); break; case EFST_HANDICAPSTATE_DEADLYPOISON: - this->SendMsg(nullptr, AM_CHANGE_COLOR, 0, 170, 0, 0, 0, 170, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CHANGE_COLOR, 170, 0, 170, 0, 0, 0); break; case EFST_HANDICAPSTATE_DEPRESSION: - this->SendMsg(nullptr, AM_CHANGE_COLOR, 0, 0, 0, 0, 0, 255, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CHANGE_COLOR, 0, 0, 255, 0, 0, 0); break; case EFST_HANDICAPSTATE_HOLYFLAME: - this->SendMsg(nullptr, AM_CHANGE_COLOR, 0, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CHANGE_COLOR, 255, 0, 0, 0, 0, 0); break; case EFST_DRAGONIC_AURA: g_effectMgr->Retire(this->render.accountId, 0x6BE); @@ -3796,7 +3796,7 @@ void CPlayer::ReapplySkillEffects() { break; case EFST_EQUIPPED_DIVINE_ARMOR: case EFST_EQUIPPED_HOLY_ARMOR: - this->SendMsg(nullptr, AM_STATUS_CHANGE, 0, type, type >> 31, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_STATUS_CHANGE, type, 1, 0, 0, 0, 0); break; default: switch (type) { @@ -3814,7 +3814,7 @@ void CPlayer::ReapplySkillEffects() { case EFST_MERMAID_LONGING: case EFST_MAGICAL_FEATHER: case EFST_TIME_ACCESSORY: - this->SendMsg(nullptr, AM_STATUS_CHANGE, 0, type, type >> 31, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_STATUS_CHANGE, type, 1, 0, 0, 0, 0); break; case EFST_HEAD_EQUIPMENT_EFFECT: this->ApplyEffectState(value + 0x9B5, true); @@ -3843,10 +3843,10 @@ struct PlayerSkillRequest { // OFFSET: 0x00DB9A00 // FUNCTION: fn_22672 void CPlayer::SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) { CGameMode* mode = static_cast(g_modeMgr.GetGameMode()); - switch (static_cast(a) << 32 | static_cast(message)) { + switch (message) { case AM_REQ_GROUND_SKILL: { PlayerSkillRequest request; request.skill = this->skillId; @@ -3898,17 +3898,17 @@ void CPlayer::SendMsg( } break; case AM_REQ_MOVE: - this->SendMsg(nullptr, AM_CANCELATTACK, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CANCELATTACK, 0, 0, 0, 0, 0, 0); if (this->render.state != 0x4B) { if (this->IsSpecialState(this->render.state)) { this->isPreengageStateOfMove = 1; - this->preengageXOfMove = b; - this->preengageYOfMove = d; + this->preengageXOfMove = static_cast(b); + this->preengageYOfMove = static_cast(c); } else { this->isPreengageStateOfMove = 0; this->preengageXOfMove = -1; this->preengageYOfMove = -1; - this->SendMsg(nullptr, AM_REQ_MOVE_PRIMITIVE, 0, b, b >> 31, d, d >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_REQ_MOVE_PRIMITIVE, b, c, 0, 0, 0, 0); } } break; @@ -3916,7 +3916,7 @@ void CPlayer::SendMsg( g_moveRequestPending = false; if (timeGetTime() > this->standTick + 350) { this->standTick = timeGetTime(); - mode->SendMsg(MM_REQUEST_MOVE, b, d, 0, 0); + mode->SendMsg(MM_REQUEST_MOVE, static_cast(b), static_cast(c), 0, 0); } break; case AM_REQ_CHANGE_DIR: { @@ -3926,7 +3926,7 @@ void CPlayer::SendMsg( } float targetX; float targetZ; - mode->CellCenter(b, d, targetX, targetZ); + mode->CellCenter(static_cast(b), static_cast(c), targetX, targetZ); const float heading = CRenderObject::Heading(this->render.position.x, this->render.position.z, targetX, targetZ); const float facing = static_cast((CPlayer::AngleToDirection(static_cast(heading + 22.5)) + 4) * 45); int delta = static_cast(this->render.angle - facing); @@ -3983,12 +3983,12 @@ void CPlayer::SendMsg( case AM_PREMOVE: this->preMoveOn = 1; this->preMoveStartTick = timeGetTime(); - reinterpret_cast(this->destCellX) = b; - this->destCellZ = d; + reinterpret_cast(this->destCellX) = static_cast(b); + this->destCellZ = static_cast(c); break; case AM_MOVE: { this->preMoveOn = 0; - const int* route = reinterpret_cast(b); + const int* route = reinterpret_cast(static_cast(b)); this->routeStartTick = route[0]; if (this->FindRoute(route[1], route[2], route[3], route[4], route[5], route[6], *reinterpret_cast(g_session.healthPoints))) { this->movementState[5] = route[5]; @@ -4032,33 +4032,31 @@ void CPlayer::SendMsg( if (this->attackMode != 0) { this->attackMode = 2; if (this->totalAttackReqCnt != 0) { - this->SendMsg(nullptr, AM_CANCELATTACK, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_CANCELATTACK, 0, 0, 0, 0, 0, 0); mode->SendMsg(MM_CANCEL_LOCKON, 0, 0, 0, 0); } } break; } case AM_SET_SKILL_USE_LEVEL: - this->skillUseLevel = b; + this->skillUseLevel = static_cast(b); break; case AM_PROCEEDGROUNDSKILL: if (this->render.state != 6 && - (!StateFlag01(this->stateFlags) || (b == 0x89 && c == 0) || (b == 0xD4 && c == 0) || (b == 0x211 && c == 0) || - (b == 0x212 && c == 0))) { + (!StateFlag01(this->stateFlags) || b == 0x89 || b == 0xD4 || b == 0x211 || b == 0x212)) { this->proceedType = 4; - this->skillId = b; - this->gSkillDx = d; - this->gSkillDy = f; + this->skillId = static_cast(b); + this->gSkillDx = static_cast(c); + this->gSkillDy = static_cast(d); this->proceedTargetGid = 0; } break; case AM_PROCEEDSKILL: if (this->render.state != 6 && - (!StateFlag01(this->stateFlags) || (d == 0x89 && e == 0) || (d == 0xD4 && e == 0) || (d == 0x211 && e == 0) || - (d == 0x212 && e == 0) || (d == 0x250 && e == 0))) { + (!StateFlag01(this->stateFlags) || c == 0x89 || c == 0xD4 || c == 0x211 || c == 0x212 || c == 0x250)) { this->proceedType = 3; - this->proceedTargetGid = b; - this->skillId = d; + this->proceedTargetGid = static_cast(b); + this->skillId = static_cast(c); } break; case AM_RESUMEPROCEEDATTACK: @@ -4066,7 +4064,7 @@ void CPlayer::SendMsg( const int attackMode = this->proceedType == 1 ? 5 : 1; this->tickOfMoveForAttack = timeGetTime() - 1200; this->proceedType = attackMode; - this->proceedTargetGid = b; + this->proceedTargetGid = static_cast(b); this->isAttackRequest = 0; this->totalAttackReqCnt = 0; reinterpret_cast(this->destCellX) = -1; @@ -4075,16 +4073,16 @@ void CPlayer::SendMsg( break; case AM_PROCEEDATTACK: if (this->render.state != 6 && !StateFlag01(this->stateFlags)) { - CRenderObject* target = mode->scene->GetGameActorByAID(b); + CRenderObject* target = mode->scene->GetGameActorByAID(static_cast(b)); if (target != nullptr) { this->proceedType = static_cast(*reinterpret_cast(g_session.healthPoints) * 4 / 3) < reinterpret_cast(static_cast(target)->destinationAndSpeed)[1] ? 5 : 1; - this->proceedTargetGid = b; + this->proceedTargetGid = static_cast(b); this->isAttackRequest = 0; - this->attackMode = d; + this->attackMode = static_cast(c); this->totalAttackReqCnt = 0; } } @@ -4092,17 +4090,17 @@ void CPlayer::SendMsg( case AM_PROCEEDPICKUPITEM: if (this->render.state != 6 && !StateFlag01(this->stateFlags)) { this->proceedType = 2; - this->proceedTargetGid = b; + this->proceedTargetGid = static_cast(b); } break; case AM_PROCEEDTOUCHSKILL: if (this->render.state != 6 && !StateFlag01(this->stateFlags)) { - const int* skill = reinterpret_cast(d); + const int* skill = reinterpret_cast(static_cast(c)); this->proceedType = 6; this->skillId = skill[1]; this->skillUseLevel = skill[3]; - this->proceedTargetGid = b; - this->attackMode = f; + this->proceedTargetGid = static_cast(b); + this->attackMode = static_cast(d); this->isAttackRequest = 0; this->totalAttackReqCnt = 0; } @@ -4111,7 +4109,7 @@ void CPlayer::SendMsg( this->route.points.clear(); break; default: - this->CPc::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, j, k, l, m); + this->CPc::SendMsg(sender, message, b, c, d, e, f, g); break; } } @@ -4326,7 +4324,7 @@ void CPlayer::Initialize() { this->SetSprRobe(g_session.m_robe, 0); if (g_session.playerAppearanceState != 0) { const int value = g_session.playerAppearanceState; - this->SendMsg(nullptr, AM_STATUS_CHANGE, 0, 856, 0, 1, 0, value, value >> 31, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_STATUS_CHANGE, 856, 1, value, 0, 0, 0); } this->bodyState = bodyState; this->stateFlags = stateFlags; @@ -4335,7 +4333,7 @@ void CPlayer::Initialize() { *reinterpret_cast(&g_session.statusLevelEffects[0]), g_session.m_jobFlags, *reinterpret_cast(&g_session.statusLevelEffects[4]), false ); - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0xA4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0xA4, 0, 0, 0, 0, 0); this->skillEffect = this->LaunchEffect(0xA4, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); if (!g_statusRefreshSuppressed) { this->ReapplySkillEffects(); @@ -4762,13 +4760,13 @@ struct PcMoveEntry { // OFFSET: 0x00DAE890 // FUNCTION: fn_22602 void CPc::SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) { CGameMode* mode = static_cast(g_modeMgr.GetGameMode()); - switch (*reinterpret_cast(&message)) { + switch (message) { case AM_SET_HEAD_DIR: if (this->render.state == 0 || this->render.state == 6) { - this->render.curMotion = b; + this->render.curMotion = static_cast(b); } break; case AM_REMOVEGAGE: @@ -4783,12 +4781,12 @@ void CPc::SendMsg( this->gaugeWindow->SetSize(60, 5); g_windowMgr.AddRenderedFront(this->gaugeWindow); } - static_cast(this->gaugeWindow)->SetValues(b, d); + static_cast(this->gaugeWindow)->SetValues(static_cast(b), static_cast(c)); static_cast(this->gaugeWindow)->SetLimits(0, 0); this->gaugeWindow->Move(this->render.screenX - 30, ScaleByScreenHeight(12) + this->render.screenY); break; case AM_STANDENTRY: { - PcStandEntry* entry = reinterpret_cast(b); + PcStandEntry* entry = reinterpret_cast(static_cast(b)); mode->CellCenter(entry->cellX, entry->cellY, this->render.position.x, this->render.position.z); this->render.position.y = mode->scene->terrain->Height(this->render.position.x, this->render.position.z); @@ -4825,7 +4823,7 @@ void CPc::SendMsg( break; } case AM_STANDENTRY2: { - PcStandEntry* entry = reinterpret_cast(b); + PcStandEntry* entry = reinterpret_cast(static_cast(b)); this->bodyStyle = entry->bodyStyle; mode->CellCenter(entry->cellX, entry->cellY, this->render.position.x, this->render.position.z); this->render.position.y = @@ -4881,7 +4879,7 @@ void CPc::SendMsg( break; } case AM_INITSTANDENTRY: { - PcStandEntry* entry = reinterpret_cast(b); + PcStandEntry* entry = reinterpret_cast(static_cast(b)); this->render.accountId = entry->aid; CGameMode* gameMode = static_cast(g_modeMgr.GetGameMode()); gameMode->CellCenter(entry->cellX, entry->cellY, this->render.position.x, this->render.position.z); @@ -4918,14 +4916,14 @@ void CPc::SendMsg( this->SetState(0, 1); break; } - if (d == 2 && e == 0 && !StateFlag06(this->stateFlags)) { + if (c == 2 && !StateFlag06(this->stateFlags)) { this->LaunchEffect(0x158, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } this->ShowPartyMemberEffect(entry->aid); break; } case AM_INITSTANDENTRY2: { - PcStandEntry* entry = reinterpret_cast(b); + PcStandEntry* entry = reinterpret_cast(static_cast(b)); this->bodyStyle = entry->bodyStyle; this->render.accountId = entry->aid; CGameMode* gameMode = static_cast(g_modeMgr.GetGameMode()); @@ -4964,7 +4962,7 @@ void CPc::SendMsg( this->SetState(0, 1); break; } - if (d == 2 && e == 0 && !StateFlag06(this->stateFlags)) { + if (c == 2 && !StateFlag06(this->stateFlags)) { this->LaunchEffect(0x158, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } this->ShowPartyMemberEffect(entry->aid); @@ -4972,7 +4970,7 @@ void CPc::SendMsg( break; } case AM_INITMOVEENTRY: { - PcMoveEntry* entry = reinterpret_cast(b); + PcMoveEntry* entry = reinterpret_cast(static_cast(b)); this->render.accountId = entry->aid; *reinterpret_cast(&this->destinationAndSpeed[4]) = entry->speed; this->routeStartTick = entry->moveStartTick; @@ -5003,7 +5001,7 @@ void CPc::SendMsg( break; } case AM_INITMOVEENTRY2: { - PcMoveEntry* entry = reinterpret_cast(b); + PcMoveEntry* entry = reinterpret_cast(static_cast(b)); this->bodyStyle = entry->bodyStyle; this->render.accountId = entry->aid; *reinterpret_cast(&this->destinationAndSpeed[4]) = entry->speed; @@ -5037,7 +5035,7 @@ void CPc::SendMsg( break; } case AM_MOVEENTRY: { - PcMoveEntry* entry = reinterpret_cast(b); + PcMoveEntry* entry = reinterpret_cast(static_cast(b)); this->bodyStyle = entry->bodyStyle; this->render.accountId = entry->aid; *reinterpret_cast(&this->destinationAndSpeed[4]) = entry->speed; @@ -5063,7 +5061,7 @@ void CPc::SendMsg( break; } case AM_MOVEENTRY2: { - PcMoveEntry* entry = reinterpret_cast(b); + PcMoveEntry* entry = reinterpret_cast(static_cast(b)); this->bodyStyle = entry->bodyStyle; this->render.accountId = entry->aid; *reinterpret_cast(&this->destinationAndSpeed[4]) = entry->speed; @@ -5091,8 +5089,8 @@ void CPc::SendMsg( break; } case AM_CHANGE_RANK: - this->pkRank = d; - this->pkTotal = b; + this->pkRank = static_cast(c); + this->pkTotal = static_cast(b); break; case AM_MAKE_BIRD: { if (this->statusEffects[0] != 0) { @@ -5131,7 +5129,7 @@ void CPc::SendMsg( break; } CMsgEffect* effect = mode->SpawnMsgEffect(effectId, &this->render.position, this->render.accountId, true); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); effect->SetAnimationSpeed(6.0f); this->AddMsgEffect(effect); this->statusEffects[0] = reinterpret_cast(effect); @@ -5168,13 +5166,13 @@ void CPc::SendMsg( if (!effect) { break; } - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); this->AddMsgEffect(effect); this->statusEffects[1] = reinterpret_cast(effect); break; } default: - CGameActor::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, j, k, l, m); + CGameActor::SendMsg(sender, message, b, c, d, e, f, g); break; case 77: break; @@ -5184,13 +5182,13 @@ void CPc::SendMsg( // OFFSET: 0x00DADE30 // FUNCTION: fn_22601 void CGrannyPc::SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) { CGameMode* mode = static_cast(g_modeMgr.GetGameMode()); - switch (*reinterpret_cast(&message)) { + switch (message) { case AM_SET_HEAD_DIR: if (this->render.state == 0 || this->render.state == 6) { - this->render.curMotion = b; + this->render.curMotion = static_cast(b); } break; case AM_REMOVEGAGE: @@ -5205,12 +5203,12 @@ void CGrannyPc::SendMsg( this->gaugeWindow->SetSize(60, 5); g_windowMgr.AddRenderedFront(this->gaugeWindow); } - static_cast(this->gaugeWindow)->SetValues(b, d); + static_cast(this->gaugeWindow)->SetValues(static_cast(b), static_cast(c)); static_cast(this->gaugeWindow)->SetLimits(0, 0); this->gaugeWindow->Move(this->render.screenX - 30, ScaleByScreenHeight(12) + this->render.screenY); break; case AM_STANDENTRY: { - PcStandEntry* entry = reinterpret_cast(b); + PcStandEntry* entry = reinterpret_cast(static_cast(b)); mode->CellCenter(entry->cellX, entry->cellY, this->render.position.x, this->render.position.z); this->render.position.y = mode->scene->terrain->Height(this->render.position.x, this->render.position.z); @@ -5247,7 +5245,7 @@ void CGrannyPc::SendMsg( break; } case AM_STANDENTRY2: { - PcStandEntry* entry = reinterpret_cast(b); + PcStandEntry* entry = reinterpret_cast(static_cast(b)); mode->CellCenter(entry->cellX, entry->cellY, this->render.position.x, this->render.position.z); this->render.position.y = mode->scene->terrain->Height(this->render.position.x, this->render.position.z); @@ -5296,7 +5294,7 @@ void CGrannyPc::SendMsg( } case AM_INITSTANDENTRY: case AM_INITSTANDENTRY2: { - PcStandEntry* entry = reinterpret_cast(b); + PcStandEntry* entry = reinterpret_cast(static_cast(b)); this->render.accountId = entry->aid; CGameMode* gameMode = static_cast(g_modeMgr.GetGameMode()); gameMode->CellCenter(entry->cellX, entry->cellY, this->render.position.x, this->render.position.z); @@ -5333,14 +5331,14 @@ void CGrannyPc::SendMsg( this->SetState(0, 1); break; } - if (d == 2 && e == 0 && !StateFlag06(this->stateFlags)) { + if (c == 2 && !StateFlag06(this->stateFlags)) { this->LaunchEffect(0x158, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } this->ShowPartyMemberEffect(entry->aid); break; } case AM_INITMOVEENTRY: { - PcMoveEntry* entry = reinterpret_cast(b); + PcMoveEntry* entry = reinterpret_cast(static_cast(b)); this->render.accountId = entry->aid; *reinterpret_cast(&this->destinationAndSpeed[4]) = entry->speed; this->routeStartTick = entry->moveStartTick; @@ -5371,7 +5369,7 @@ void CGrannyPc::SendMsg( break; } case AM_INITMOVEENTRY2: { - PcMoveEntry* entry = reinterpret_cast(b); + PcMoveEntry* entry = reinterpret_cast(static_cast(b)); this->render.accountId = entry->aid; *reinterpret_cast(&this->destinationAndSpeed[4]) = entry->speed; this->routeStartTick = entry->moveStartTick; @@ -5406,7 +5404,7 @@ void CGrannyPc::SendMsg( } case AM_MOVEENTRY: case AM_MOVEENTRY2: { - PcMoveEntry* entry = reinterpret_cast(b); + PcMoveEntry* entry = reinterpret_cast(static_cast(b)); this->render.accountId = entry->aid; *reinterpret_cast(&this->destinationAndSpeed[4]) = entry->speed; this->routeStartTick = entry->moveStartTick; @@ -5430,11 +5428,11 @@ void CGrannyPc::SendMsg( break; } case AM_CHANGE_RANK: - this->pkRank = d; - this->pkTotal = b; + this->pkRank = static_cast(c); + this->pkTotal = static_cast(b); break; default: - CGameActor::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + CGameActor::SendMsg(sender, message, b, c, d, e, 0, 0); break; case 77: break; @@ -5590,7 +5588,7 @@ void CPlayer::SetState(int state, int resetPosition) { this->isPreengageStateOfMove = 0; this->preengageXOfMove = -1; this->preengageYOfMove = -1; - this->SendMsg(nullptr, AM_REQ_MOVE_PRIMITIVE, 0, cellX, cellX >> 31, cellY, cellY >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_REQ_MOVE_PRIMITIVE, cellX, cellY, 0, 0, 0, 0); } if (state == 3) { diff --git a/Source/Contents/Actors/RenderObject.cpp b/Source/Contents/Actors/RenderObject.cpp index c57253314..648584a05 100644 --- a/Source/Contents/Actors/RenderObject.cpp +++ b/Source/Contents/Actors/RenderObject.cpp @@ -438,7 +438,7 @@ void CRenderObject::PlayFrameSounds() { // OFFSET: 0x00CBF920 // FUNCTION: fn_21115 -void CRenderObject::SendMsg(CGameObject*, int, int, int, int, int, int, int, int, int, int, int, int, int, int) { +void CRenderObject::SendMsg(CGameObject*, std::int64_t, std::int64_t, std::int64_t, std::int64_t, std::int64_t, std::int64_t, std::int64_t) { } // OFFSET: 0x00CBF930 @@ -1081,7 +1081,7 @@ void CGameActor::PlayGroundSkillEffect(int sender, const int* skill, int argumen mode->LaunchDummyEffect(&position, 0x77, EffectLifetime(0x77) + 10, 0); if (this->statusEffects[0] != 0) { const std::int64_t address = reinterpret_cast(&position); - reinterpret_cast(this->statusEffects[0])->SendMsg(nullptr, AM_REQ_ATTACK, 0, static_cast(address), static_cast(address >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + reinterpret_cast(this->statusEffects[0])->SendMsg(nullptr, AM_REQ_ATTACK, address, 0, 0, 0, 0, 0); } break; case AS_VENOMDUST: @@ -1335,7 +1335,7 @@ void CGameActor::SetState(int state, int resetPosition) { target = mode->scene->GetGameActorByAID(this->hitTargetAid); } if (target) { - target->SendMsg(nullptr, AM_DELETE_MAGIC_TARGET, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_DELETE_MAGIC_TARGET, 0, 0, 0, 0, 0, 0); } this->SetAction(action, 5, 1); const int job = this->GetEffectiveJob(-1); @@ -1376,8 +1376,8 @@ void CGameActor::SetState(int state, int resetPosition) { this->render.timedSequenceActive = 0; this->render.isMotionFreezed = false; if (this->bodyState == BODYSTATE_FREEZING) { - this->SendMsg(nullptr, AM_DELETE_ICEEFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_MAKE_ICEBREAKE_FFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_ICEEFFECT, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_ICEBREAKE_FFECT, 0, 0, 0, 0, 0, 0); } this->render.isLieOnGround = true; this->render.isMotionFinished = false; @@ -1431,10 +1431,10 @@ void CGameActor::SetState(int state, int resetPosition) { this->render.sequenceInterval = 10; this->SetAnimationSequence(action, 0, action, 0, action, 0, action, 1, action, 1, 1, 3000, 0); while (HasEffectOfType(this->state.effects, 0x1be)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1be, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1be, 0, 0, 0, 0, 0); } while (HasEffectOfType(this->state.effects, 0x1bd)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1bd, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1bd, 0, 0, 0, 0, 0); } this->LaunchEffect(0x1bd, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); this->LaunchEffect(0x19b, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -1591,10 +1591,10 @@ void CGameActor::SetState(int state, int resetPosition) { this->render.sequenceInterval = 20; this->SetAnimationSequence(action, 0, action, 0, action, 0, action, 1, action, 1, 1, 3000, 0); while (HasEffectOfType(this->state.effects, 0x1be)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x1be, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x1be, 0, 0, 0, 0, 0); } while (HasEffectOfType(this->state.effects, 0x430)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 0x430, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 0x430, 0, 0, 0, 0, 0); } this->LaunchEffect(0x430, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); this->LaunchEffect(0x19b, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); @@ -2732,12 +2732,12 @@ static __forceinline void FillCharacterNpcRenderSecondary(CCharacterNpc* self, C // OFFSET: 0x005A1530 // FUNCTION: fn_03053 void CCharacterNpc::SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) { - CharacterNpcViewInfo* info = reinterpret_cast(b); - switch (static_cast(static_cast(static_cast(a)) << 32 | static_cast(message))) { + CharacterNpcViewInfo* info = reinterpret_cast(static_cast(b)); + switch (message) { case AM_INITSTANDENTRY: - this->CGameActor::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + this->CGameActor::SendMsg(sender, message, b, c, d, e, 0, 0); this->render.visible = g_session.IsVisibleJob(info->job); this->SetGuildInfo(info->guildId, info->guildEmblemVersion); if (this->characterRender != nullptr) { @@ -2747,7 +2747,7 @@ void CCharacterNpc::SendMsg( FillCharacterNpcRenderPrimary(this, info); return; case AM_STANDENTRY: - this->CGameActor::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + this->CGameActor::SendMsg(sender, message, b, c, d, e, 0, 0); if (this->characterRender == nullptr) { return; } @@ -2755,7 +2755,7 @@ void CCharacterNpc::SendMsg( return; case AM_INITMOVEENTRY: case AM_INITMOVEENTRY2: - this->CGameActor::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + this->CGameActor::SendMsg(sender, message, b, c, d, e, 0, 0); if (this->characterRender != nullptr) { return; } @@ -2764,14 +2764,14 @@ void CCharacterNpc::SendMsg( return; case AM_MOVEENTRY: case AM_MOVEENTRY2: - this->CGameActor::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + this->CGameActor::SendMsg(sender, message, b, c, d, e, 0, 0); if (this->characterRender == nullptr) { return; } FillCharacterNpcRenderSecondary(this, info); return; default: - CNpc::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + CNpc::SendMsg(sender, message, b, c, d, e, 0, 0); return; } } @@ -3147,7 +3147,7 @@ void CGameActor::SetHatEffect(int effectId, bool on) { } const std::int64_t value = hatEffect; - this->SendMsg(this, AM_DELETE_EFFECT, 0, static_cast(value), static_cast(value >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, value, 0, 0, 0, 0, 0); CPc* pc; if (hatEffect == 254 && IsPlayerJob(this->GetEffectiveJob(-1)) && (pc = dynamic_cast(this)) != nullptr) { @@ -3194,30 +3194,30 @@ void CGameActor::SetEffectInstance(int effectId, int instance, bool on) { // FUNCTION: fn_21022 void CGameActor::ResetJobEffects() { this->levelAuraType = 0; - this->SendMsg(this, AM_DELETE_EFFECT, 0, 200, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(this, AM_DELETE_EFFECT, 0, 976, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(this, AM_DELETE_EFFECT, 0, 977, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(this, AM_DELETE_EFFECT, 0, 978, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(this, AM_DELETE_EFFECT, 0, 979, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(this, AM_DELETE_EFFECT, 0, 1022, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(this, AM_DELETE_EFFECT, 0, 1023, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(this, AM_DELETE_EFFECT, 0, 1226, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(this, AM_DELETE_EFFECT, 0, 1227, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 757, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 880, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 200, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 397, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 398, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 362, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 362, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 201, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 202, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 202, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 200, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 976, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 977, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 978, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 979, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 1022, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 1023, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 1226, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 1227, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 757, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 880, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 200, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 397, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 398, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 362, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 362, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 201, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 202, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 202, 0, 0, 0, 0, 0); const std::int64_t first = g_session.m_maxLevelEffect4th; - this->SendMsg(this, AM_DELETE_EFFECT, 0, static_cast(first), static_cast(first >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, first, 0, 0, 0, 0, 0); const std::int64_t second = g_session.m_maxLevelEffect4thSub; - this->SendMsg(this, AM_DELETE_EFFECT, 0, static_cast(second), static_cast(second >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, second, 0, 0, 0, 0, 0); } // OFFSET: 0x00CAB020 @@ -3755,13 +3755,10 @@ void CGameActor::ProcessHitMessage(CGameObject*, const ActorHitInfo* info, int, const std::int64_t address = reinterpret_cast(&message); if (hitCount == 1) { - target->SendMsg(this, AM_WILL_BE_ATTACKED, 0, static_cast(address), static_cast(address >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(this, AM_WILL_BE_ATTACKED, address, 0, 0, 0, 0, 0); } else { const std::int64_t value = damage; - target->SendMsg( - this, AM_WILL_BE_ATTACKED, 0, static_cast(address), static_cast(address >> 32), static_cast(value), static_cast(value >> 32), 0, 0, 0, - 0, 0, 0, 0, 0 - ); + target->SendMsg(this, AM_WILL_BE_ATTACKED, address, value, 0, 0, 0, 0); } const int job = this->GetEffectiveJob(-1); @@ -3773,10 +3770,7 @@ void CGameActor::ProcessHitMessage(CGameObject*, const ActorHitInfo* info, int, total += damage; message.damage = damage; const std::int64_t value = total; - target->SendMsg( - this, AM_WILL_BE_ATTACKED, 0, static_cast(address), static_cast(address >> 32), static_cast(value), static_cast(value >> 32), 0, 0, - 0, 0, 0, 0, 0, 0 - ); + target->SendMsg(this, AM_WILL_BE_ATTACKED, address, value, 0, 0, 0, 0); message.time -= g_multiHitInterval / 2; } } @@ -3785,13 +3779,10 @@ void CGameActor::ProcessHitMessage(CGameObject*, const ActorHitInfo* info, int, message.time += g_multiHitInterval / 2 + (g_multiHitInterval / 4 + g_multiHitInterval); message.damage = extraDamage; if (hitCount == 1) { - target->SendMsg(this, AM_WILL_BE_ATTACKED, 0, static_cast(address), static_cast(address >> 32), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(this, AM_WILL_BE_ATTACKED, address, 0, 0, 0, 0, 0); } else { const std::int64_t value = total + extraDamage; - target->SendMsg( - this, AM_WILL_BE_ATTACKED, 0, static_cast(address), static_cast(address >> 32), static_cast(value), static_cast(value >> 32), 0, 0, 0, - 0, 0, 0, 0, 0 - ); + target->SendMsg(this, AM_WILL_BE_ATTACKED, address, value, 0, 0, 0, 0); } return; } @@ -3803,10 +3794,7 @@ void CGameActor::ProcessHitMessage(CGameObject*, const ActorHitInfo* info, int, total += damage; message.damage = damage; const std::int64_t value = total; - target->SendMsg( - this, AM_WILL_BE_ATTACKED, 0, static_cast(address), static_cast(address >> 32), static_cast(value), static_cast(value >> 32), 0, 0, 0, - 0, 0, 0, 0, 0 - ); + target->SendMsg(this, AM_WILL_BE_ATTACKED, address, value, 0, 0, 0, 0); } } break; @@ -4265,10 +4253,10 @@ void C3dGrannyGameActor::RenderShadowed(int argument) { // OFFSET: 0x00CC3E50 // FUNCTION: fn_21156 void CGameActor::SetCharm(int type, int count) { - this->SendMsg(this, AM_DELETE_EFFECT, 0, 0x2E1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(this, AM_DELETE_EFFECT, 0, 0x2E2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(this, AM_DELETE_EFFECT, 0, 0x2DF, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(this, AM_DELETE_EFFECT, 0, 0x2E0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 0x2E1, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 0x2E2, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 0x2DF, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 0x2E0, 0, 0, 0, 0, 0); if (count <= 0 || StateFlag01(this->GetStateFlags()) || StateFlag02(this->GetStateFlags())) { return; } @@ -4334,7 +4322,7 @@ void CGameActor::UpdateMaxLevelAura() { if (g_session.IsTreeGroupTwo(this->GetEffectiveJob(-1))) { if (g_session.m_maxLevel == static_cast(this->characterLevel)) { - this->SendMsg(nullptr, 0x96, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, 0x96, 0, 0, 0, 0, 0, 0); return; } this->hasLevelAura = 0; @@ -4343,7 +4331,7 @@ void CGameActor::UpdateMaxLevelAura() { if (g_session.IsTreeGroupThree(this->GetEffectiveJob(-1)) == true) { if (*reinterpret_cast(&g_session.jobLevelLimits[0x74]) == static_cast(this->characterLevel)) { - this->SendMsg(nullptr, AM_MAKE_LEVEL4TH_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_LEVEL4TH_EFFECT, 0, 0, 0, 0, 0, 0); return; } this->hasLevelAura = 0; @@ -4352,7 +4340,7 @@ void CGameActor::UpdateMaxLevelAura() { if (g_session.IsSuperNovice2Job(this->GetEffectiveJob(-1))) { if (*reinterpret_cast(&g_session.jobLevelLimits[0]) == static_cast(this->characterLevel)) { - this->SendMsg(nullptr, AM_MAKE_LEVEL160_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_LEVEL160_EFFECT, 0, 0, 0, 0, 0, 0); return; } this->hasLevelAura = 0; @@ -4361,7 +4349,7 @@ void CGameActor::UpdateMaxLevelAura() { if (g_session.IsExpandedJob(this->GetEffectiveJob(-1))) { if (*reinterpret_cast(&g_session.jobLevelLimits[4]) == static_cast(this->characterLevel)) { - this->SendMsg(nullptr, AM_MAKE_LEVEL160_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_LEVEL160_EFFECT, 0, 0, 0, 0, 0, 0); return; } this->hasLevelAura = 0; @@ -4371,7 +4359,7 @@ void CGameActor::UpdateMaxLevelAura() { if (g_session.IsMercenaryJob(this->GetEffectiveJob(-1))) { const int skill = static_cast(this->characterLevel); if (*reinterpret_cast(&g_session.jobLevelLimits[8]) == skill) { - this->SendMsg(nullptr, 0x93, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, 0x93, 0, 0, 0, 0, 0, 0); return; } if (*reinterpret_cast(g_session.maxBaseLevel) != skill || g_session.IsNewMercenaryJob(this->GetEffectiveJob(-1)) != 0) { @@ -4380,7 +4368,7 @@ void CGameActor::UpdateMaxLevelAura() { } } else if (g_session.IsDoramJob(this->GetEffectiveJob(-1)) == true) { if (*reinterpret_cast(&g_session.jobLevelLimits[0x28]) == static_cast(this->characterLevel)) { - this->SendMsg(nullptr, AM_MAKE_LEVEL160_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_LEVEL160_EFFECT, 0, 0, 0, 0, 0, 0); return; } this->hasLevelAura = 0; @@ -4390,7 +4378,7 @@ void CGameActor::UpdateMaxLevelAura() { return; } - this->SendMsg(nullptr, AM_MAKE_LEVEL99_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_LEVEL99_EFFECT, 0, 0, 0, 0, 0, 0); } // OFFSET: 0x00CC2340 @@ -4628,9 +4616,7 @@ __declspec(noinline) void CGameActor::ProcessActorEffects() { } ActorDamageMessage& message = *it; - this->SendMsg( - nullptr, message.action, message.action >> 31, reinterpret_cast(&message.targetAid), 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0); + this->SendMsg(nullptr, message.action, reinterpret_cast(&message.targetAid), 0, 0, 0, 0, 0); it = this->willBeAttackedList.erase(it); } } @@ -4717,7 +4703,7 @@ void CGameActor::SpawnDamageDigits(int, int damage, std::uint32_t color, int typ CMsgEffect* effect = static_cast(*it); if (effect->m_type == 22) { this->ClearStatusEffectInstance(reinterpret_cast(effect)); - effect->SendMsg(this, AM_MASTER_DEAD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_MASTER_DEAD, 0, 0, 0, 0, 0, 0); it = this->msgEffectList.erase(it); static_cast(g_modeMgr.GetGameMode())->scene->RemoveObject(effect); } else { @@ -4730,19 +4716,19 @@ void CGameActor::SpawnDamageDigits(int, int damage, std::uint32_t color, int typ for (auto it = digits.begin(); it != digits.end(); ++it, ++index) { CMsgEffect* effect = new CMsgEffect; effect->render.color = color; - effect->SendMsg(nullptr, AM_SETMASTERGID, 0, this->render.accountId, 0, type, type >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(nullptr, AM_SETMASTERGID, static_cast(this->render.accountId), type, 0, 0, 0, 0); const std::intptr_t position = reinterpret_cast(&this->render.position); const int count = static_cast(digits.size()); if (value >= 100000000 && g_session.m_damageMillionUnit == 2) { if (index == 0) { - effect->SendMsg(nullptr, AM_SETPOS2, 0, position, position >> 31, *it, *it >> 31, (count - 1) * 3 + 4, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(nullptr, AM_SETPOS2, position, *it, static_cast((count - 1) * 3 + 4), 0, 0, 0); } else { - effect->SendMsg(nullptr, AM_SETPOS2, 0, position, position >> 31, *it, *it >> 31, (count - 1) * 3 - index * 8, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(nullptr, AM_SETPOS2, position, *it, static_cast((count - 1) * 3 - index * 8), 0, 0, 0); } } else { - effect->SendMsg(nullptr, AM_SETPOS2, 0, position, position >> 31, *it, *it >> 31, (count - index * 2) * 4 - 4, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(nullptr, AM_SETPOS2, position, *it, static_cast((count - index * 2) * 4 - 4), 0, 0, 0); } - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); effect->render.useGroundLighting = 0; if (type == 22) { effect->render.scale = 0.5f; @@ -4794,12 +4780,12 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef if (StateFlag01Changed(this->stateFlags, previousFlags)) { this->ResetJobEffects(); if (this->GetEffectiveJob(-1) == 45) { - this->SendMsg(this, AM_DELETE_EFFECT, 0, 321, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_DELETE_EFFECT, 321, 0, 0, 0, 0, 0); } if (StateFlag01(this->stateFlags)) { if (notify) { - this->SendMsg(nullptr, AM_MAKE_SMOKE_FFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_SMOKE_FFECT, 0, 0, 0, 0, 0, 0); if (this->GetEffectiveJob(-1) != 25 && this->GetEffectiveJob(-1) != 4222) { this->LaunchEffect(16, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } @@ -4808,17 +4794,17 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef this->render.enabled = 0; if (this->render.accountId != g_session.m_aid && g_session.IsAdminSubMode(7) == 0) { this->render.visibilityOptions[0] = 0; - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 159, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_REMOVEGAGE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 159, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_REMOVEGAGE, 0, 0, 0, 0, 0, 0); } if (this->maxHp > 0) { - this->SendMsg(nullptr, AM_DELETE_CART, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_CART, 0, 0, 0, 0, 0, 0); } if (StateFlag04(this->stateFlags)) { - this->SendMsg(nullptr, AM_DELETE_BIRD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_BIRD, 0, 0, 0, 0, 0, 0); } if (StateFlag20(this->stateFlags)) { - this->SendMsg(nullptr, AM_DELETE_WOLF, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_WOLF, 0, 0, 0, 0, 0, 0); } if (!g_session.IsGuildMemberAccount(this->render.accountId)) { this->ClearSiegeNameWindow(); @@ -4829,7 +4815,7 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef } } else { if (notify) { - this->SendMsg(nullptr, AM_MAKE_SMOKE_FFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_SMOKE_FFECT, 0, 0, 0, 0, 0, 0); static_cast(g_modeMgr.GetGameMode())->waitingUseItemAck = 0; } @@ -4838,13 +4824,13 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef this->render.visibilityOptions[0] = 1; } if (this->maxHp > 0) { - this->SendMsg(nullptr, AM_MAKE_CART, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_CART, 0, 0, 0, 0, 0, 0); } if (StateFlag04(this->stateFlags)) { - this->SendMsg(nullptr, AM_MAKE_BIRD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_BIRD, 0, 0, 0, 0, 0, 0); } if (StateFlag20(this->stateFlags)) { - this->SendMsg(nullptr, AM_MAKE_WOLF, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_WOLF, 0, 0, 0, 0, 0, 0); } this->RefreshGuildEmblemWindow(); if (this->hasLevelAura != 0) { @@ -4863,17 +4849,17 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef this->render.enabled = 0; if (this->render.accountId != g_session.m_aid && g_session.IsAdminSubMode(7) == 0) { this->render.visibilityOptions[0] = 0; - this->SendMsg(nullptr, AM_REMOVEGAGE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 159, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_REMOVEGAGE, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 159, 0, 0, 0, 0, 0); } if (this->maxHp > 0) { - this->SendMsg(nullptr, AM_DELETE_CART, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_CART, 0, 0, 0, 0, 0, 0); } if (StateFlag04(this->stateFlags)) { - this->SendMsg(nullptr, AM_DELETE_BIRD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_BIRD, 0, 0, 0, 0, 0, 0); } if (StateFlag20(this->stateFlags)) { - this->SendMsg(nullptr, AM_DELETE_WOLF, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_WOLF, 0, 0, 0, 0, 0, 0); } if (!g_session.IsGuildMemberAccount(this->render.accountId)) { this->ClearSiegeNameWindow(); @@ -4889,13 +4875,13 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef this->render.visibilityOptions[0] = 1; } if (this->maxHp > 0) { - this->SendMsg(nullptr, AM_MAKE_CART, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_CART, 0, 0, 0, 0, 0, 0); } if (StateFlag04(this->stateFlags)) { - this->SendMsg(nullptr, AM_MAKE_BIRD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_BIRD, 0, 0, 0, 0, 0, 0); } if (StateFlag20(this->stateFlags)) { - this->SendMsg(nullptr, AM_MAKE_WOLF, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_WOLF, 0, 0, 0, 0, 0, 0); } this->RefreshGuildEmblemWindow(); if (this->hasLevelAura != 0) { @@ -4906,36 +4892,36 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef if (!StateFlag01(this->stateFlags) && !StateFlag02(this->stateFlags) && !StateFlag06(this->stateFlags)) { if (StateFlag04Changed(this->stateFlags, previousFlags)) { - this->SendMsg(nullptr, StateFlag04(this->stateFlags) ? AM_MAKE_BIRD : AM_DELETE_BIRD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, StateFlag04(this->stateFlags) ? AM_MAKE_BIRD : AM_DELETE_BIRD, 0, 0, 0, 0, 0, 0); } if (StateFlag20Changed(this->stateFlags, previousFlags)) { - this->SendMsg(nullptr, StateFlag20(this->stateFlags) ? AM_MAKE_WOLF : AM_DELETE_WOLF, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, StateFlag20(this->stateFlags) ? AM_MAKE_WOLF : AM_DELETE_WOLF, 0, 0, 0, 0, 0, 0); } } if (StateFlag19Changed(this->stateFlags, previousFlags)) { - this->SendMsg(nullptr, StateFlag19(this->stateFlags) ? AM_MAKE_CHICKEN : AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, StateFlag19(this->stateFlags) ? AM_MAKE_CHICKEN : AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0); } if (StateFlag23Changed(this->stateFlags, previousFlags)) { - this->SendMsg(nullptr, StateFlag23(this->stateFlags) ? AM_MAKE_CHICKEN : AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, StateFlag23(this->stateFlags) ? AM_MAKE_CHICKEN : AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0); } if (StateFlag24Changed(this->stateFlags, previousFlags)) { - this->SendMsg(nullptr, StateFlag24(this->stateFlags) ? AM_MAKE_CHICKEN : AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, StateFlag24(this->stateFlags) ? AM_MAKE_CHICKEN : AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0); } if (StateFlag25Changed(this->stateFlags, previousFlags)) { - this->SendMsg(nullptr, StateFlag25(this->stateFlags) ? AM_MAKE_CHICKEN : AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, StateFlag25(this->stateFlags) ? AM_MAKE_CHICKEN : AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0); } if (StateFlag26Changed(this->stateFlags, previousFlags)) { - this->SendMsg(nullptr, StateFlag26(this->stateFlags) ? AM_MAKE_CHICKEN : AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, StateFlag26(this->stateFlags) ? AM_MAKE_CHICKEN : AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0); } if (StateFlag21Changed(this->stateFlags, previousFlags)) { - this->SendMsg(nullptr, StateFlag21(this->stateFlags) ? AM_MAKE_CHICKEN : AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, StateFlag21(this->stateFlags) ? AM_MAKE_CHICKEN : AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0); } if (StateFlag05Changed(this->stateFlags, previousFlags)) { - this->SendMsg(nullptr, StateFlag05(this->stateFlags) ? AM_MAKE_CHICKEN : AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, StateFlag05(this->stateFlags) ? AM_MAKE_CHICKEN : AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0); } if (StateFlag15Changed(this->stateFlags, previousFlags)) { - this->SendMsg(nullptr, StateFlag15(this->stateFlags) ? AM_MAKE_CHICKEN : AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, StateFlag15(this->stateFlags) ? AM_MAKE_CHICKEN : AM_DELETE_CHICKEN, 0, 0, 0, 0, 0, 0); } if (StateFlag06Changed(this->stateFlags, previousFlags)) { @@ -4945,7 +4931,7 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef this->render.visibilityOptions[0] = 0; if (admin == 0) { this->render.visible = 0; - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 159, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 159, 0, 0, 0, 0, 0); if (this->msgEffectList.size() != 0) { for (CGameObject* object : this->msgEffectList) { static_cast(object)->m_visible = this->render.accountId == g_session.m_aid; @@ -4955,13 +4941,13 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef this->render.visible = 1; } if (this->maxHp > 0) { - this->SendMsg(nullptr, AM_DELETE_CART, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_CART, 0, 0, 0, 0, 0, 0); } if (StateFlag04(this->stateFlags)) { - this->SendMsg(nullptr, AM_DELETE_BIRD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_BIRD, 0, 0, 0, 0, 0, 0); } if (StateFlag20(this->stateFlags)) { - this->SendMsg(nullptr, AM_DELETE_WOLF, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_WOLF, 0, 0, 0, 0, 0, 0); } if (!g_session.IsGuildMemberAccount(this->render.accountId)) { this->ClearSiegeNameWindow(); @@ -4982,13 +4968,13 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef } } if (this->maxHp > 0) { - this->SendMsg(nullptr, AM_MAKE_CART, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_CART, 0, 0, 0, 0, 0, 0); } if (StateFlag04(this->stateFlags)) { - this->SendMsg(nullptr, AM_MAKE_BIRD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_BIRD, 0, 0, 0, 0, 0, 0); } if (StateFlag20(this->stateFlags)) { - this->SendMsg(nullptr, AM_MAKE_WOLF, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_WOLF, 0, 0, 0, 0, 0, 0); } this->RefreshGuildEmblemWindow(); if (this->hasLevelAura != 0) { @@ -5011,8 +4997,8 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef break; } case OPT1_FREEZE: { - this->SendMsg(nullptr, AM_DELETE_ICEEFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_MAKE_ICEBREAKE_FFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_ICEEFFECT, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_ICEBREAKE_FFECT, 0, 0, 0, 0, 0, 0); const vector3d& player = reinterpret_cast(static_cast(g_modeMgr.GetGameMode())->scene->player)->render.position; g_soundMgr->PlayWave( "_frozen_explosion.wav", this->render.position.x - player.x, 0.0f, this->render.position.z - player.z, 250, 40, 1.0f, 0 @@ -5027,19 +5013,19 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef break; } case OPT1_STUN: - this->SendMsg(nullptr, AM_DELETE_STUN_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_STUN_EFFECT, 0, 0, 0, 0, 0, 0); static_cast(g_modeMgr.GetGameMode())->waitingUseItemAck = 0; break; case OPT1_SLEEP: - this->SendMsg(nullptr, AM_DELETE_SLEEP_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_SLEEP_EFFECT, 0, 0, 0, 0, 0, 0); static_cast(g_modeMgr.GetGameMode())->waitingUseItemAck = 0; break; case OPT1_BURNING: - this->SendMsg(nullptr, AM_DELETE_BURNING_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_BURNING_EFFECT, 0, 0, 0, 0, 0, 0); break; case OPT1_IMPRISON: while (this->HasId(802)) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 802, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 802, 0, 0, 0, 0, 0); } break; default: @@ -5056,7 +5042,7 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef color[0] = 0x40; break; case OPT1_FREEZE: - this->SendMsg(nullptr, AM_MAKE_ICEEFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_ICEEFFECT, 0, 0, 0, 0, 0, 0); this->render.isMotionFinished = true; this->render.isMotionFreezed = true; this->render.colorLocked = 1; @@ -5071,7 +5057,7 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef } break; case OPT1_STUN: - this->SendMsg(nullptr, AM_MAKE_STUN_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_STUN_EFFECT, 0, 0, 0, 0, 0, 0); if (notify) { const vector3d& player = reinterpret_cast(static_cast(g_modeMgr.GetGameMode())->scene->player)->render.position; g_soundMgr->PlayWave( @@ -5080,7 +5066,7 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef } break; case OPT1_SLEEP: - this->SendMsg(nullptr, AM_MAKE_SLEEP_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_SLEEP_EFFECT, 0, 0, 0, 0, 0, 0); break; case OPT1_STONEWAIT: this->render.colorLocked = 1; @@ -5089,7 +5075,7 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef color[0] = 0x80; break; case OPT1_BURNING: - this->SendMsg(nullptr, AM_MAKE_BURNING_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_BURNING_EFFECT, 0, 0, 0, 0, 0, 0); break; case OPT1_IMPRISON: if (!this->HasId(802)) { @@ -5124,7 +5110,7 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef poisonSound = true; } else if (this->render.accountId == g_session.m_aid) { if (g_playerPoisoned == 1) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 335, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 335, 0, 0, 0, 0, 0); } g_playerPoisoned = 0; } @@ -5141,7 +5127,7 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef } if (this->effectState & 0x02) { - this->SendMsg(nullptr, AM_MAKE_CURSE_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_CURSE_EFFECT, 0, 0, 0, 0, 0, 0); this->render.colorLocked = 1; color[1] = 0x32; color[2] = 0xC8; @@ -5153,7 +5139,7 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef ); } } else { - this->SendMsg(nullptr, AM_DELETE_CURSE_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_CURSE_EFFECT, 0, 0, 0, 0, 0, 0); } if (this->effectState & 0x04) { @@ -5163,12 +5149,12 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef "_silence.wav", this->render.position.x - player.x, 0.0f, this->render.position.z - player.z, 250, 40, 1.0f, 0 ); } - this->SendMsg(nullptr, AM_MAKE_SILENCE_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_SILENCE_EFFECT, 0, 0, 0, 0, 0, 0); } else { - this->SendMsg(nullptr, AM_DELETE_SILENCE_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_SILENCE_EFFECT, 0, 0, 0, 0, 0, 0); } - this->SendMsg(nullptr, (this->effectState & 0x20) ? AM_MAKE_ANGELUS_EFFECT : AM_DELETE_ANGELUS_EFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, (this->effectState & 0x20) ? AM_MAKE_ANGELUS_EFFECT : AM_DELETE_ANGELUS_EFFECT, 0, 0, 0, 0, 0, 0); if ((this->effectState & 0x08) && notify) { const vector3d& player = reinterpret_cast(static_cast(g_modeMgr.GetGameMode())->scene->player)->render.position; @@ -5194,7 +5180,7 @@ void CGameActor::SetStatusStates(int bodyState, std::uint32_t stateFlags, int ef } else if (this->render.accountId == g_session.m_aid) { if (static_cast(this->render.instant.Get(16)) == 0) { if (g_overrideColor == 1) { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 334, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 334, 0, 0, 0, 0, 0); } g_overrideColor = 0; } @@ -5352,7 +5338,7 @@ void CGameActor::ProcessSkillMessage(CGameObject*, const ActorSkillInfo* info, i message.blueDamage = 0; message.skillId = skillId; message.skillTarget = 0; - target->SendMsg(this, AM_WILL_BE_ATTACKED, 0, address, address >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(this, AM_WILL_BE_ATTACKED, address, 0, 0, 0, 0, 0); return; } } else if (skillId == SO_CLOUD_KILL || skillId == NPC_CLOUD_KILL || skillId == SU_SV_ROOTTWIST_ATK || skillId == GN_CARTCANNON) { @@ -5377,7 +5363,7 @@ void CGameActor::ProcessSkillMessage(CGameObject*, const ActorSkillInfo* info, i message.blueDamage = 0; message.skillId = skillId; message.skillTarget = 0; - target->SendMsg(this, AM_WILL_BE_ATTACKED, 0, address, address >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(this, AM_WILL_BE_ATTACKED, address, 0, 0, 0, 0, 0); return; } } else if (skillId == SO_CLOUD_KILL || skillId == NPC_CLOUD_KILL) { @@ -5630,26 +5616,26 @@ void CGameActor::ProcessSkillMessage(CGameObject*, const ActorSkillInfo* info, i case SR_EARTHSHAKER: case SR_FALLENEMPIRE: case SR_TIGERCANNON: - target->SendMsg(this, AM_WILL_BE_ATTACKED, 0, address, address >> 31, damage, damage >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(this, AM_WILL_BE_ATTACKED, address, damage, 0, 0, 0, 0); break; case WL_TETRAVORTEX_WATER: message.time += 500; - target->SendMsg(this, AM_WILL_BE_ATTACKED, 0, address, address >> 31, damage, damage >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(this, AM_WILL_BE_ATTACKED, address, damage, 0, 0, 0, 0); break; case WL_TETRAVORTEX_WIND: message.time += 1000; - target->SendMsg(this, AM_WILL_BE_ATTACKED, 0, address, address >> 31, damage, damage >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(this, AM_WILL_BE_ATTACKED, address, damage, 0, 0, 0, 0); break; case WL_TETRAVORTEX_GROUND: message.time += 1500; - target->SendMsg(this, AM_WILL_BE_ATTACKED, 0, address, address >> 31, damage, damage >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(this, AM_WILL_BE_ATTACKED, address, damage, 0, 0, 0, 0); break; case TK_DOWNKICK: case TK_TURNKICK: case SJ_SOLARBURST: case SJ_PROMINENCEKICK: message.time += 300; - target->SendMsg(this, AM_WILL_BE_ATTACKED2, 0, address, address >> 31, damage, damage >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(this, AM_WILL_BE_ATTACKED2, address, damage, 0, 0, 0, 0); break; case TK_STORMKICK: case TK_COUNTER: @@ -5659,16 +5645,16 @@ void CGameActor::ProcessSkillMessage(CGameObject*, const ActorSkillInfo* info, i case SR_CRESCENTELBOW_AUTOSPELL: case SJ_FULLMOONKICK: case SJ_FLASHKICK: - target->SendMsg(this, AM_WILL_BE_ATTACKED2, 0, address, address >> 31, damage, damage >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(this, AM_WILL_BE_ATTACKED2, address, damage, 0, 0, 0, 0); break; case PR_TURNUNDEAD: message.time += 500; [[fallthrough]]; default: if (hitCount == 1) { - target->SendMsg(this, AM_WILL_BE_ATTACKED, 0, address, address >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(this, AM_WILL_BE_ATTACKED, address, 0, 0, 0, 0, 0); } else { - target->SendMsg(this, AM_WILL_BE_ATTACKED, 0, address, address >> 31, damage, damage >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(this, AM_WILL_BE_ATTACKED, address, damage, 0, 0, 0, 0); } break; } @@ -5818,7 +5804,7 @@ void CGameActor::ProcessSkillMessage(CGameObject*, const ActorSkillInfo* info, i total += damage; message.action = action; message.damage = damage; - target->SendMsg(this, AM_WILL_BE_ATTACKED, 0, address, address >> 31, total, total >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(this, AM_WILL_BE_ATTACKED, address, total, 0, 0, 0, 0); continue; } @@ -5830,7 +5816,7 @@ void CGameActor::ProcessSkillMessage(CGameObject*, const ActorSkillInfo* info, i message.effectId = 122; } else if (skillId == CH_CHAINCRUSH) { message.action = 0x6C; - this->SendMsg(this, AM_WILL_BE_ATTACKED, 0, address, address >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(this, AM_WILL_BE_ATTACKED, address, 0, 0, 0, 0, 0); } else if (skillId == CG_ARROWVULCAN) { } else if (skillId == WL_CRIMSONROCK) { message.effectId = 0x512; @@ -5900,6 +5886,6 @@ void CGameActor::ProcessSkillMessage(CGameObject*, const ActorSkillInfo* info, i break; } - target->SendMsg(this, kind, 0, address, address >> 31, total, total >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(this, kind, address, total, 0, 0, 0, 0); } } diff --git a/Source/Contents/Actors/RenderObject.h b/Source/Contents/Actors/RenderObject.h index 1bcb0d504..c0a42876a 100644 --- a/Source/Contents/Actors/RenderObject.h +++ b/Source/Contents/Actors/RenderObject.h @@ -30,7 +30,7 @@ public: CRenderObject(); ~CRenderObject() override; bool OnProcess() override; - void SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m) override; + void SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) override; void Render(int argument) override; virtual void SetRenderInfo(const float* bounds, float x, float y); diff --git a/Source/Contents/Actors/Skill.cpp b/Source/Contents/Actors/Skill.cpp index 5a550b024..347a45813 100644 --- a/Source/Contents/Actors/Skill.cpp +++ b/Source/Contents/Actors/Skill.cpp @@ -321,12 +321,12 @@ __declspec(safebuffers) void CSkill::ShowModel(const char* modelName) { // OFFSET: 0x00E51BD0 // FUNCTION: fn_24302 -void CSkill::SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int, int, int, int) { +void CSkill::SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) { CGameMode* mode = static_cast(g_modeMgr.GetGameMode()); - switch (static_cast(a) << 32 | static_cast(message)) { + switch (message) { case AM_CHAT: { - const char* text = reinterpret_cast(b); + const char* text = reinterpret_cast(static_cast(b)); if (std::strlen(text) == 0) { return; } @@ -349,7 +349,7 @@ void CSkill::SendMsg(CGameObject* sender, int message, int a, int b, int c, int return; } case AM_SKILL: { - const SkillHitMessage* hit = reinterpret_cast(b); + const SkillHitMessage* hit = reinterpret_cast(static_cast(b)); const int skillId = hit->skillId; const int monsterValue = hit->monsterValue; const int cellX = hit->cellX; @@ -456,13 +456,13 @@ void CSkill::SendMsg(CGameObject* sender, int message, int a, int b, int c, int const int address = reinterpret_cast(&damageMessage); int total = damage; - target->SendMsg(this, AM_WILL_BE_ATTACKED, 0, address, address >> 31, total, total >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(this, AM_WILL_BE_ATTACKED, address, total, 0, 0, 0, 0); for (int index = 0; index < hitCount - 1;) { ++index; damageMessage.time += g_multiHitInterval; total += damage; damageMessage.skillTarget = index; - target->SendMsg(this, AM_WILL_BE_ATTACKED, 0, address, address >> 31, total, total >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(this, AM_WILL_BE_ATTACKED, address, total, 0, 0, 0, 0); } } @@ -472,7 +472,7 @@ void CSkill::SendMsg(CGameObject* sender, int message, int a, int b, int c, int return; } case AM_SKILLSTANDENTRY: { - const SkillUnitMessage* unit = reinterpret_cast(b); + const SkillUnitMessage* unit = reinterpret_cast(static_cast(b)); this->range = unit->range; this->skillAid = unit->aid; this->render.accountId = unit->aid; @@ -879,7 +879,7 @@ void CSkill::SendMsg(CGameObject* sender, int message, int a, int b, int c, int } } case AM_SETJOB: - this->SetActorJob(b); + this->SetActorJob(static_cast(b)); switch (this->GetEffectiveJob(-1)) { case UNT_WARP_WAITING: { const vector3d& player = static_cast(g_modeMgr.GetGameMode())->scene->player->render.position; @@ -943,7 +943,7 @@ void CSkill::SendMsg(CGameObject* sender, int message, int a, int b, int c, int } return; default: - this->CGameActor::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + this->CGameActor::SendMsg(sender, message, b, c, d, e, 0, 0); return; } } diff --git a/Source/Contents/Actors/Skill.h b/Source/Contents/Actors/Skill.h index 0e2426ff4..b34c8a04d 100644 --- a/Source/Contents/Actors/Skill.h +++ b/Source/Contents/Actors/Skill.h @@ -15,7 +15,7 @@ public: explicit CSkill(std::uint32_t aid); ~CSkill() override; bool OnProcess() override; - void SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m) override; + void SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) override; const char* GetTrapModelName(); void ReleaseModel(); diff --git a/Source/Contents/ClientState.cpp b/Source/Contents/ClientState.cpp index 35ef5fcbb..c1dbfb15e 100644 --- a/Source/Contents/ClientState.cpp +++ b/Source/Contents/ClientState.cpp @@ -213,9 +213,9 @@ std::uint32_t CSession::ReadReplayStats(const std::vector& data) if (player) { player->SetMadogearType(this->madogearType); if (this->madogearType) { - player->SendMsg(nullptr, 105, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, 105, 0, 0, 0, 0, 0, 0); } else { - player->SendMsg(nullptr, 106, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, 106, 0, 0, 0, 0, 0, 0); } } break; diff --git a/Source/Contents/Configuration/ServiceOptions.cpp b/Source/Contents/Configuration/ServiceOptions.cpp index c348b1978..fb024f449 100644 --- a/Source/Contents/Configuration/ServiceOptions.cpp +++ b/Source/Contents/Configuration/ServiceOptions.cpp @@ -1350,7 +1350,7 @@ void NotifyGameModeOptionFirst() { void RequestPlayerAction31() { CGameMode* mode = static_cast(g_modeMgr.GetGameMode()); if (CPlayer* player = mode->scene->player) { - player->SendMsg(nullptr, AM_REQ_SIT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, AM_REQ_SIT, 0, 0, 0, 0, 0, 0); } } diff --git a/Source/Contents/Effects/Core/DummyEffectLauncher.cpp b/Source/Contents/Effects/Core/DummyEffectLauncher.cpp index 1d2e3426c..69ebb56b7 100644 --- a/Source/Contents/Effects/Core/DummyEffectLauncher.cpp +++ b/Source/Contents/Effects/Core/DummyEffectLauncher.cpp @@ -17,30 +17,30 @@ bool CDummyEffectLauncher::OnProcess() { // OFFSET: 0x00E50A60 // FUNCTION: fn_24296 -__declspec(safebuffers) void CDummyEffectLauncher::SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int, int, int, int) { - if (message != AM_SETPOS || a != 0) { - this->EffectActor::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); +__declspec(safebuffers) void CDummyEffectLauncher::SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) { + if (message != AM_SETPOS) { + this->EffectActor::SendMsg(sender, message, b, c, d, e, 0, 0); return; } - const vector3d* position = reinterpret_cast(b); + const vector3d* position = reinterpret_cast(static_cast(b)); this->render.position.x = position->x; this->render.position.y = position->y; this->render.position.z = position->z; this->render.visible = 0; this->render.motionStartTime = timeGetTime(); - if (g_effectMgr->Spawn(0, d, this->render.position, 0, -1, 0, 0) != nullptr) { + if (g_effectMgr->Spawn(0, static_cast(c), this->render.position, 0, -1, 0, 0) != nullptr) { return; } - CRagEffect* effect = this->LaunchEffect(d, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); - if ((f | g) != 0) { - this->lifeFrames = f; - if (f == 333 && g == 0) { + CRagEffect* effect = this->LaunchEffect(static_cast(c), vector3d{0.0f, 0.0f, 0.0f}, 0.0f); + if (d != 0) { + this->lifeFrames = static_cast(d); + if (d == 333) { vector3d value; value.y = 0.0f; value.z = 0.0f; - value.x = static_cast(static_cast(i) << 32 | static_cast(h)); + value.x = static_cast(e); if (effect != nullptr) { effect->SendMsg(nullptr, AM_SETPOS, 0, reinterpret_cast(&value), 0, 0, 0, 0); } diff --git a/Source/Contents/Effects/Core/DummyEffectLauncher.h b/Source/Contents/Effects/Core/DummyEffectLauncher.h index 09a77d844..f79b07158 100644 --- a/Source/Contents/Effects/Core/DummyEffectLauncher.h +++ b/Source/Contents/Effects/Core/DummyEffectLauncher.h @@ -8,7 +8,7 @@ class CDummyEffectLauncher : public EffectActor { public: bool OnProcess() override; - void SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m) override; + void SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) override; /* 0158 */ int lifeFrames; /* 015C */ int padding_015C; diff --git a/Source/Contents/Effects/Core/EffectActor.h b/Source/Contents/Effects/Core/EffectActor.h index 27e741fa5..a05a241c1 100644 --- a/Source/Contents/Effects/Core/EffectActor.h +++ b/Source/Contents/Effects/Core/EffectActor.h @@ -25,7 +25,7 @@ struct EffectActorState { struct EffectActor : CRenderObject { EffectActor(); ~EffectActor() override; - void SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m) override; + void SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) override; bool EffectVisible() const; bool HasId(int id) const; bool Contains(const RagEffectState* effect) const; diff --git a/Source/Contents/Effects/Core/EffectMaker.cpp b/Source/Contents/Effects/Core/EffectMaker.cpp index dd3224abc..10c231844 100644 --- a/Source/Contents/Effects/Core/EffectMaker.cpp +++ b/Source/Contents/Effects/Core/EffectMaker.cpp @@ -70,13 +70,13 @@ void CEffectMaker::Render(int) { // OFFSET: 0x00E50BB0 // FUNCTION: fn_24297 -void CEffectMaker::SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int, int, int, int) { - if (message != 14 || a != 0) { - this->EffectActor::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); +void CEffectMaker::SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) { + if (message != 14) { + this->EffectActor::SendMsg(sender, message, b, c, d, e, 0, 0); return; } - const WorldEffectRecord* record = reinterpret_cast(b); + const WorldEffectRecord* record = reinterpret_cast(static_cast(b)); this->effectId = record->id; if (this->effectId != 45) { this->spawnInterval = static_cast(record->delay); diff --git a/Source/Contents/Effects/Core/EffectMaker.h b/Source/Contents/Effects/Core/EffectMaker.h index d71d3bce6..9379aa979 100644 --- a/Source/Contents/Effects/Core/EffectMaker.h +++ b/Source/Contents/Effects/Core/EffectMaker.h @@ -8,7 +8,7 @@ struct CEffectMaker : EffectActor { CEffectMaker(); bool OnProcess() override; - void SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m) override; + void SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) override; void Render(int argument) override; void Reset(); diff --git a/Source/Contents/Effects/Core/MsgEffect.cpp b/Source/Contents/Effects/Core/MsgEffect.cpp index 1ab7ac8a4..e29882590 100644 --- a/Source/Contents/Effects/Core/MsgEffect.cpp +++ b/Source/Contents/Effects/Core/MsgEffect.cpp @@ -78,7 +78,7 @@ CMsgEffect::CMsgEffect() { // FUNCTION: fn_24258 CMsgEffect::~CMsgEffect() { if (this->m_owner != nullptr) { - this->m_owner->SendMsg(this, AM_MSGEFFECT_DEAD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->m_owner->SendMsg(this, AM_MSGEFFECT_DEAD, 0, 0, 0, 0, 0, 0); } } @@ -464,7 +464,7 @@ bool CMsgEffect::OnProcess() { { const int frame = static_cast(elapsed); if (frame % 34 == 0) { - this->m_owner->SendMsg(nullptr, 0x4D, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->m_owner->SendMsg(nullptr, 0x4D, 0, 0, 0, 0, 0, 0); } } return true; @@ -1536,9 +1536,9 @@ void CMsgEffect::Render(int argument) { // OFFSET: 0x00E512B0 // FUNCTION: fn_24301 -void CMsgEffect::SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int, int, int, int) { - const vector3d* position = reinterpret_cast(b); - switch (static_cast(a) << 32 | static_cast(message)) { +void CMsgEffect::SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) { + const vector3d* position = reinterpret_cast(static_cast(b)); + switch (message) { case AM_REQ_ATTACK: if (this->m_type == 18) { this->m_velocity.x = (position->x - this->render.position.x) / 10.0f; @@ -1610,9 +1610,9 @@ void CMsgEffect::SendMsg(CGameObject* sender, int message, int a, int b, int c, return; case AM_SETMASTERGID: - this->m_type = d; - this->m_value = b; - switch (d) { + this->m_type = static_cast(c); + this->m_value = static_cast(b); + switch (static_cast(c)) { case MET_CART: case 31: this->render.flatDepth = 0; @@ -1699,14 +1699,14 @@ void CMsgEffect::SendMsg(CGameObject* sender, int message, int a, int b, int c, break; } - this->render.curMotion = d; + this->render.curMotion = static_cast(c); this->render.visible = 1; - if (d < 0 || d > 11) { + if (static_cast(c) < 0 || static_cast(c) > 11) { this->render.curMotion = 0; } - this->render.spriteOffsetX = f; - this->m_digit = f; + this->render.spriteOffsetX = static_cast(d); + this->m_digit = static_cast(d); this->render.scale = 5.0f; this->m_scale = 5.0f; this->render.depthLayer = static_cast(-2); @@ -1717,18 +1717,18 @@ void CMsgEffect::SendMsg(CGameObject* sender, int message, int a, int b, int c, case AM_SETPOS: { this->render.visible = 1; this->render.motionStartTime = timeGetTime(); - if ((static_cast(e) << 32 | static_cast(d)) != 0) { - const std::string* names = reinterpret_cast(d); + if (c != 0) { + const std::string* names = reinterpret_cast(static_cast(c)); this->SetSpriteName(ResourceMgr::Instance(), names[0].c_str()); this->SetActionName(ResourceMgr::Instance(), names[1].c_str()); } - if ((static_cast(g) << 32 | static_cast(f)) == 1000) { + if (d == 1000) { this->SetAction(10, 4, 0); this->render.state = 10000; this->render.color = 0xFFFF0000; } else { - this->SetAction(f, 4, 1); + this->SetAction(static_cast(d), 4, 1); } switch (this->m_type) { @@ -1809,5 +1809,5 @@ void CMsgEffect::SendMsg(CGameObject* sender, int message, int a, int b, int c, } } - this->EffectActor::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + this->EffectActor::SendMsg(sender, message, b, c, d, e, 0, 0); } diff --git a/Source/Contents/Effects/Core/MsgEffect.h b/Source/Contents/Effects/Core/MsgEffect.h index b9b274e86..368bc28fd 100644 --- a/Source/Contents/Effects/Core/MsgEffect.h +++ b/Source/Contents/Effects/Core/MsgEffect.h @@ -15,7 +15,7 @@ public: ~CMsgEffect() override; bool OnProcess() override; - void SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m) override; + void SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) override; void Render(int argument) override; void FollowOwner(); diff --git a/Source/Contents/Effects/Core/RagEffect.cpp b/Source/Contents/Effects/Core/RagEffect.cpp index e066d88b3..7e11d9145 100644 --- a/Source/Contents/Effects/Core/RagEffect.cpp +++ b/Source/Contents/Effects/Core/RagEffect.cpp @@ -114,7 +114,7 @@ CRagEffect::~CRagEffect() { } if (this->state.parent) { - this->state.parent->SendMsg(this, AM_EFFECT_DEAD, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->state.parent->SendMsg(this, AM_EFFECT_DEAD, 0, 0, 0, 0, 0, 0); } if (this->state.resource) { @@ -184,7 +184,7 @@ static __forceinline void SendAfterimageColor(CGameObject& target, CRagEffect& s const int red = static_cast(color.x); const int green = static_cast(color.y); const int blue = static_cast(color.z); - target.SendMsg(&sender, 0, 0, red, red >> 31, green, green >> 31, blue, blue >> 31, 0, 0, 0, 0, 0, 0); + target.SendMsg(&sender, 0, red, green, blue, 0, 0, 0); } @@ -2564,7 +2564,7 @@ void CRagEffect::PotionPillar(float heightSpeed, int duration) { // FUNCTION: fn_20094 bool CRagEffect::Potion_Berserk() { if (this->state.stateCnt == 0) { - this->state.parent->SendMsg(nullptr, AM_CHANGE_COLOR, 0, 250, 0, 120, 0, 120, 0, 0, 0, 0, 0, 0, 0); + this->state.parent->SendMsg(nullptr, AM_CHANGE_COLOR, 250, 120, 120, 0, 0, 0); this->PotionPillar(1.0f, 50); } @@ -2603,7 +2603,7 @@ bool CRagEffect::Potion_Berserk() { return true; } - this->state.parent->SendMsg(nullptr, AM_RETURN_COLOR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->state.parent->SendMsg(nullptr, AM_RETURN_COLOR, 0, 0, 0, 0, 0, 0); return false; } @@ -11451,7 +11451,7 @@ void CRagEffect::Sightrasher() { this->state.tlvertY = vertex.y; if (this->state.stateCnt == 0) { - this->state.parent->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 22, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->state.parent->SendMsg(nullptr, AM_DELETE_EFFECT, 22, 0, 0, 0, 0, 0); PlayEffectWave(*this, "effect\\wizard_sightrasher.wav"); } @@ -15211,14 +15211,14 @@ void CRagEffect::AlphaCenterRise() { } if (this->state.stateCnt == 35 && this->state.parent != nullptr) { - this->state.parent->SendMsg(nullptr, AM_MAKE_SMOKE_FFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->state.parent->SendMsg(nullptr, AM_MAKE_SMOKE_FFECT, 0, 0, 0, 0, 0, 0); } } // OFFSET: 0x00C36710 // FUNCTION: fn_20093 bool CRagEffect::Potion_Awakening() { if (this->state.stateCnt == 0) { - this->state.parent->SendMsg(nullptr, AM_CHANGE_COLOR, 0, 250, 0, 250, 0, 200, 0, 0, 0, 0, 0, 0, 0); + this->state.parent->SendMsg(nullptr, AM_CHANGE_COLOR, 250, 250, 200, 0, 0, 0); this->PotionPillar(1.0f, 50); } @@ -15256,7 +15256,7 @@ bool CRagEffect::Potion_Awakening() { return true; } - this->state.parent->SendMsg(nullptr, AM_RETURN_COLOR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->state.parent->SendMsg(nullptr, AM_RETURN_COLOR, 0, 0, 0, 0, 0, 0); return false; } // OFFSET: 0x00C3C4E0 @@ -17280,7 +17280,7 @@ void CPlayer::UpdateFootprints(int kind) { // OFFSET: 0x00C74B60 // FUNCTION: fn_20334 void CPlayer::RefreshEffect164() { - this->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 164, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_EFFECT, 164, 0, 0, 0, 0, 0); this->skillEffect = this->LaunchEffect(164, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } @@ -21070,17 +21070,17 @@ bool CRagEffect::OnProcess3() { if (this->state.stateCnt == 0) { this->render.position = this->state.parent->render.position; PlayEffectWave(*this, "effect\\EF_hit2.wav"); - this->state.parent->SendMsg(nullptr, AM_MAKE_NUMBER, 0, 1, 0, 0xFFFF0000, 0, 114, 0, 0, 0, 0, 0, 0, 0); + this->state.parent->SendMsg(nullptr, AM_MAKE_NUMBER, 1, 0xFFFF0000, 114, 0, 0, 0); } break; case EF_DAMAGE1_2: if (this->state.stateCnt == 0) { - this->state.parent->SendMsg(nullptr, AM_MAKE_NUMBER, 0, 1, 0, 0xFFFF0000, 0, 114, 0, 0, 0, 0, 0, 0, 0); + this->state.parent->SendMsg(nullptr, AM_MAKE_NUMBER, 1, 0xFFFF0000, 114, 0, 0, 0); } break; case EF_DAMAGE1_3: if (this->state.stateCnt == 0) { - this->state.parent->SendMsg(nullptr, AM_MAKE_NUMBER, 0, 1, 0, 0xFFFF00FF, 0, 114, 0, 0, 0, 0, 0, 0, 0); + this->state.parent->SendMsg(nullptr, AM_MAKE_NUMBER, 1, 0xFFFF00FF, 114, 0, 0, 0); } break; case EF_SPREADATTACK: @@ -21336,7 +21336,7 @@ bool CRagEffect::OnProcess3() { break; case EF_NPC_STOP2_DEL: if (this->state.stateCnt == 0) { - this->state.parent->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 604, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->state.parent->SendMsg(nullptr, AM_DELETE_EFFECT, 604, 0, 0, 0, 0, 0); } break; case EF_SIGHT2: @@ -22236,7 +22236,7 @@ bool CRagEffect::OnProcess3() { hallu->render.position.x = this->state.deltaPos[0]; hallu->render.position.y = this->state.deltaPos[1]; hallu->render.position.z = this->state.deltaPos[2]; - hallu->SendMsg(this, 0, 0, 200, 0, 200, 0, 0, 0, 0, 0, 0, 0, 0, 0); + hallu->SendMsg(this, 0, 200, 200, 0, 0, 0, 0); WorldObjects().push_back(hallu); this->state.deltaPos[0] += x * step; this->state.deltaPos[1] += y * step; diff --git a/Source/Contents/Effects/Core/ShowEffect.cpp b/Source/Contents/Effects/Core/ShowEffect.cpp index 60346f29f..16c8d0e77 100644 --- a/Source/Contents/Effects/Core/ShowEffect.cpp +++ b/Source/Contents/Effects/Core/ShowEffect.cpp @@ -77,8 +77,7 @@ void CShowEffect::Close() { for (auto it = this->effects.begin(); it != this->effects.end(); ++it) { if (target) { - target->SendMsg(nullptr, AM_DELETE_TAGGED_EFFECT, 0, static_cast(static_cast(it->first)), - static_cast(static_cast(it->first) >> 32), it->second, 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_DELETE_TAGGED_EFFECT, it->first, static_cast(it->second), 0, 0, 0, 0); } else if (g_effectMgr->HasAllocator(it->second)) { g_effectMgr->Retire(actorId, it->first, it->second); } @@ -105,7 +104,6 @@ void CShowEffect::Remove(int tag) { return; } - target->SendMsg(target, AM_DELETE_TAGGED_EFFECT, 0, static_cast(static_cast(tag)), - static_cast(static_cast(tag) >> 32), this->effects[tag], 0, 0, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(target, AM_DELETE_TAGGED_EFFECT, tag, static_cast(this->effects[tag]), 0, 0, 0, 0); this->effects.erase(tag); } diff --git a/Source/Contents/Effects/Skills/ArrowEffect.cpp b/Source/Contents/Effects/Skills/ArrowEffect.cpp index 56eed2039..292221080 100644 --- a/Source/Contents/Effects/Skills/ArrowEffect.cpp +++ b/Source/Contents/Effects/Skills/ArrowEffect.cpp @@ -99,11 +99,11 @@ __declspec(safebuffers) bool CArrowEffect::OnProcess() { // OFFSET: 0x00E50500 // FUNCTION: fn_24295 -void CArrowEffect::SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int, int, int, int) { - if (message == 14 && a == 0) { +void CArrowEffect::SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) { + if (message == 14) { const char* sprite; const char* action; - switch (static_cast(static_cast(static_cast(i)) << 32 | static_cast(h))) { + switch (static_cast(static_cast(e))) { case JT_PARASITE: case JT_G_PARASITE: action = "몬스터\\PARASITE_BULLET.act"; @@ -245,31 +245,31 @@ void CArrowEffect::SendMsg(CGameObject* sender, int message, int a, int b, int c this->SetSpriteName(sprite); this->SetActionName(action); this->speedScale = 1.0f; - this->render.position = *reinterpret_cast(b); + this->render.position = *reinterpret_cast(static_cast(b)); this->render.position.y -= 10.0f; this->startPos.x = this->render.position.x; this->startPos.y = this->render.position.y; this->startPos.z = this->render.position.z; - this->targetAid = d; + this->targetAid = static_cast(c); this->render.visible = 0; - this->GetTargetPos(d, this->targetPos); + this->GetTargetPos(static_cast(c), this->targetPos); this->render.motionStartTime = timeGetTime(); - } else if (message == 64 && a == 0) { + } else if (message == 64) { this->SetSpriteName("몬스터\\skel_archer_arrow.spr"); this->SetActionName("몬스터\\skel_archer_arrow.act"); this->speedScale = 1.0f; - this->render.position = *reinterpret_cast(b); + this->render.position = *reinterpret_cast(static_cast(b)); this->render.position.y -= 10.0f; this->startPos.x = this->render.position.x; this->startPos.y = this->render.position.y; this->startPos.z = this->render.position.z; - this->targetPos = *reinterpret_cast(d); + this->targetPos = *reinterpret_cast(static_cast(c)); this->targetPos.y -= 10.0f; this->render.visible = 0; this->targetAid = 0; this->render.motionStartTime = timeGetTime(); } else { - this->CRenderObject::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + this->CRenderObject::SendMsg(sender, message, b, c, d, e, 0, 0); return; } diff --git a/Source/Contents/Effects/Skills/ArrowEffect.h b/Source/Contents/Effects/Skills/ArrowEffect.h index ad4b75a4d..babd41c59 100644 --- a/Source/Contents/Effects/Skills/ArrowEffect.h +++ b/Source/Contents/Effects/Skills/ArrowEffect.h @@ -12,7 +12,7 @@ public: CArrowEffect(); bool OnProcess() override; - void SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m) override; + void SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) override; void Reset(); diff --git a/Source/Contents/Effects/Skills/MandraAttackEffect.cpp b/Source/Contents/Effects/Skills/MandraAttackEffect.cpp index 46901c193..0f5c9d612 100644 --- a/Source/Contents/Effects/Skills/MandraAttackEffect.cpp +++ b/Source/Contents/Effects/Skills/MandraAttackEffect.cpp @@ -41,15 +41,15 @@ bool CMandraAttackEffect::OnProcess() { // OFFSET: 0x00E50F30 // FUNCTION: fn_24300 -void CMandraAttackEffect::SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int, int, int, int) { - if (message != 14 || a != 0) { - this->CRenderObject::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); +void CMandraAttackEffect::SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) { + if (message != 14) { + this->CRenderObject::SendMsg(sender, message, b, c, d, e, 0, 0); return; } const char* sprite; const char* action; - switch (f) { + switch (static_cast(d)) { case JT_HYDRA: sprite = "몬스터\\hydra_atk.spr"; action = "몬스터\\hydra_atk.act"; @@ -157,18 +157,18 @@ void CMandraAttackEffect::SendMsg(CGameObject* sender, int message, int a, int b this->SetSpriteName(sprite); this->SetActionName(action); vector3d target{0.0f, 0.0f, 0.0f}; - this->GetTargetPos(b, target); + this->GetTargetPos(static_cast(b), target); this->render.position.x = target.x; this->render.position.y = target.y; this->render.position.z = target.z; this->render.visible = 1; this->render.motionStartTime = timeGetTime(); this->SetAnimationSpeed(this->GetActRes()->Speed(0)); - if (f == 0x42C) { + if (static_cast(d) == 0x42C) { this->SetAnimationSpeed(2.0f); } - if (d != 0 || e != 0) { - this->startFrame = *reinterpret_cast(d); + if (c != 0) { + this->startFrame = *reinterpret_cast(static_cast(c)); } } diff --git a/Source/Contents/Effects/Skills/MandraAttackEffect.h b/Source/Contents/Effects/Skills/MandraAttackEffect.h index b3f9c302e..341d5d193 100644 --- a/Source/Contents/Effects/Skills/MandraAttackEffect.h +++ b/Source/Contents/Effects/Skills/MandraAttackEffect.h @@ -9,7 +9,7 @@ class CMandraAttackEffect : public CRenderObject { public: CMandraAttackEffect(); bool OnProcess() override; - void SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m) override; + void SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) override; /* 0138 */ float startFrame; /* 013C */ int padding_013C; diff --git a/Source/Contents/Effects/Skills/ShadowExceedEffect.cpp b/Source/Contents/Effects/Skills/ShadowExceedEffect.cpp index c7e787d6a..a90daa184 100644 --- a/Source/Contents/Effects/Skills/ShadowExceedEffect.cpp +++ b/Source/Contents/Effects/Skills/ShadowExceedEffect.cpp @@ -48,7 +48,7 @@ void CShadowExceed::Close() { CRenderObject* actor = FindRenderObject(this->actor); if (actor) { while (static_cast(actor)->HasId(1004) == true) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 1004, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 1004, 0, 0, 0, 0, 0); } } } @@ -136,7 +136,7 @@ void CShadowExceed::OnProcess() { CRenderObject* actor = FindRenderObject(this->actor); if (actor) { while (static_cast(actor)->HasId(1004) == true) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 1004, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 1004, 0, 0, 0, 0, 0); } static_cast(actor)->LaunchEffect(1004, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); } diff --git a/Source/Contents/Items/ClientItemLists.cpp b/Source/Contents/Items/ClientItemLists.cpp index f5b0689a4..fee2acfaf 100644 --- a/Source/Contents/Items/ClientItemLists.cpp +++ b/Source/Contents/Items/ClientItemLists.cpp @@ -1307,7 +1307,7 @@ void CSession::ClearPartyMembers() { for (auto member = this->m_partyMembers.begin(); member != this->m_partyMembers.end(); ++member) { CRenderObject* actor = mode->scene->GetGameActorByAidIncludeMe(member->accountId); if (actor && static_cast(actor)->HasId(160) == true) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 160, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 160, 0, 0, 0, 0, 0); } } } diff --git a/Source/Contents/Monster/ChampionMonsterMgr.cpp b/Source/Contents/Monster/ChampionMonsterMgr.cpp index 9c7e8211f..4a8b8de4f 100644 --- a/Source/Contents/Monster/ChampionMonsterMgr.cpp +++ b/Source/Contents/Monster/ChampionMonsterMgr.cpp @@ -118,7 +118,7 @@ int CChampionMonsterMgr::ApplyEffects(int id, CGameActor* actor, int aid) { } else { for (unsigned int i = 0; i < effects.size(); ++i) { const int effect = effects[i]; - actor->SendMsg(actor, AM_DELETE_EFFECT, 0, effect, effect >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(actor, AM_DELETE_EFFECT, effect, 0, 0, 0, 0, 0); } } diff --git a/Source/Contents/SignBoard/SignBoard.cpp b/Source/Contents/SignBoard/SignBoard.cpp index 1062b8bc1..2127d1bf6 100644 --- a/Source/Contents/SignBoard/SignBoard.cpp +++ b/Source/Contents/SignBoard/SignBoard.cpp @@ -361,9 +361,9 @@ void CIcon::Render(int argument) { // OFFSET: 0x008220A0 // FUNCTION: fn_10273 -void CIcon::SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m) { +void CIcon::SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) { g_modeMgr.GetGameMode(); - this->CRenderObject::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + this->CRenderObject::SendMsg(sender, message, b, c, d, e, 0, 0); } // OFFSET: 0x008220F0 diff --git a/Source/Contents/SignBoard/SignBoard.h b/Source/Contents/SignBoard/SignBoard.h index bc8afeffb..b82b1ebf9 100644 --- a/Source/Contents/SignBoard/SignBoard.h +++ b/Source/Contents/SignBoard/SignBoard.h @@ -39,7 +39,7 @@ public: CIcon(); ~CIcon() override; bool OnProcess() override; - void SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m) override; + void SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) override; void Render(int argument) override; void SetRenderInfo(const float* bounds, float x, float y) override; void Load(const std::string& name); diff --git a/Source/Contents/Skills/GraffiSkill.cpp b/Source/Contents/Skills/GraffiSkill.cpp index 450a4239d..1155f4d4a 100644 --- a/Source/Contents/Skills/GraffiSkill.cpp +++ b/Source/Contents/Skills/GraffiSkill.cpp @@ -137,20 +137,20 @@ void CGraffiSkill::Render(int argument) { // OFFSET: 0x00E50D10 // FUNCTION: fn_24298 -void CGraffiSkill::SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int, int, int, int, int, int) { - const std::uint64_t id = static_cast(static_cast(a)) << 32 | static_cast(message); +void CGraffiSkill::SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) { + const std::uint64_t id = static_cast(message); if (id == 22) { - this->skillAid = b; + this->skillAid = static_cast(b); return; } if (id == 117) { - std::strcpy(this->m_text, reinterpret_cast(b)); - this->m_cellX = d; - this->m_cellY = f; + std::strcpy(this->m_text, reinterpret_cast(static_cast(b))); + this->m_cellX = static_cast(c); + this->m_cellY = static_cast(d); this->BuildTexture(); return; } - this->CGameActor::SendMsg(sender, message, a, b, c, d, e, f, g, 0, 0, 0, 0, 0, 0); + this->CGameActor::SendMsg(sender, message, b, c, d, 0, 0, 0); } diff --git a/Source/Contents/Skills/GraffiSkill.h b/Source/Contents/Skills/GraffiSkill.h index 1f0f13f83..49f130bc0 100644 --- a/Source/Contents/Skills/GraffiSkill.h +++ b/Source/Contents/Skills/GraffiSkill.h @@ -12,7 +12,7 @@ public: CGraffiSkill(); ~CGraffiSkill() override; bool OnProcess() override; - void SendMsg(CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m) override; + void SendMsg(CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g) override; void Render(int argument) override; virtual void BuildTexture(); diff --git a/Source/Contents/Skills/SkillActionMeister.cpp b/Source/Contents/Skills/SkillActionMeister.cpp index 429bf5667..c81374529 100644 --- a/Source/Contents/Skills/SkillActionMeister.cpp +++ b/Source/Contents/Skills/SkillActionMeister.cpp @@ -281,7 +281,7 @@ void CEfstAction_GRADUAL_GRAVITY::OnEfstBegin(int efstId, int value, int argumen void CEfstAction_GRADUAL_GRAVITY::OnEfstEnd(int efstId, int argument2, int argument3, int argument4, CRenderObject* actor) { if (actor) { while (static_cast(actor)->HasId(779)) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 779, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 779, 0, 0, 0, 0, 0); } } } diff --git a/Source/Contents/Skills/SkillActionShinkiroShiranui.cpp b/Source/Contents/Skills/SkillActionShinkiroShiranui.cpp index 0fcab853b..506ee56a6 100644 --- a/Source/Contents/Skills/SkillActionShinkiroShiranui.cpp +++ b/Source/Contents/Skills/SkillActionShinkiroShiranui.cpp @@ -559,7 +559,7 @@ void CEfstAction_SHADOW_CLOCK::OnEfstBegin(int efstId, int value, int argument3, void CEfstAction_SHADOW_CLOCK::OnEfstEnd(int efstId, int argument2, int argument3, int argument4, CRenderObject* actor) { if (actor) { while (static_cast(actor)->HasId(963)) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 963, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 963, 0, 0, 0, 0, 0); } } } diff --git a/Source/Contents/Skills/SkillActionSoulAscetic.cpp b/Source/Contents/Skills/SkillActionSoulAscetic.cpp index 83e26f88d..cbaddabac 100644 --- a/Source/Contents/Skills/SkillActionSoulAscetic.cpp +++ b/Source/Contents/Skills/SkillActionSoulAscetic.cpp @@ -189,7 +189,7 @@ void CSkillAction_SOA_TALISMAN_OF_SOUL_STEALING::OnSkillCast(int level, CGameAct void CSkillAction_SOA_TALISMAN_OF_SOUL_STEALING::OnSkillEffect(int level, CGameActor* source, CGameActor* target) { if (target) { target->LaunchEffect(253, vector3d{0.0f, 0.0f, 0.0f}, 0.0f); - target->SendMsg(nullptr, AM_MAKE_NUMBER, 0, level, level >> 31, static_cast(0xFF0000FF), 0, 114, 0, 0, 0, 0, 0, 0, 0); + target->SendMsg(nullptr, AM_MAKE_NUMBER, level, 0xFF0000FFu, 114, 0, 0, 0); } } diff --git a/Source/Contents/Skills/SkillInfo.cpp b/Source/Contents/Skills/SkillInfo.cpp index 7af1f5fed..41cc7b104 100644 --- a/Source/Contents/Skills/SkillInfo.cpp +++ b/Source/Contents/Skills/SkillInfo.cpp @@ -1043,7 +1043,7 @@ void CEfstAction_SHADOW_EXCEED::OnEfstEnd(int efstId, int argument2, int argumen auto* effectActor = static_cast(actor); while (effectActor->HasId(1004)) { - actor->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 1004, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + actor->SendMsg(nullptr, AM_DELETE_EFFECT, 1004, 0, 0, 0, 0, 0); } } diff --git a/Source/Contents/Sound/SoundMaker.cpp b/Source/Contents/Sound/SoundMaker.cpp index de064e449..3fb0a825c 100644 --- a/Source/Contents/Sound/SoundMaker.cpp +++ b/Source/Contents/Sound/SoundMaker.cpp @@ -532,36 +532,35 @@ void CSoundMaker::Render(int) { // OFFSET: 0x00DA4970 // FUNCTION: fn_22418 void CBlowEffect::SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int, int, int, int + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) { - if (message != 14 || a != 0) { - CRenderObject::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + if (message != 14) { + CRenderObject::SendMsg(sender, message, b, c, d, e, 0, 0); return; } - const float* position = reinterpret_cast(b); + const float* position = reinterpret_cast(static_cast(b)); this->render.position.x = position[0]; this->render.position.y = position[1]; this->render.position.z = position[2]; this->render.visible = 1; - this->render.color = (d | e) ? 0xFFFF0000u : 0xFFFFFFFFu; + this->render.color = c ? 0xFFFF0000u : 0xFFFFFFFFu; this->render.motionStartTime = timeGetTime(); } // OFFSET: 0x00DA4A00 // FUNCTION: fn_22419 void CBlurPC::SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int, int, int, int + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) { - if (a == 0) { switch (message) { case BM_RGB: - this->SetColor(180, b, d, f); + this->SetColor(180, static_cast(b), static_cast(c), static_cast(d)); this->destCellZ = 0x8000000; return; case BM_ALPHA: - this->render.color &= (b << 24) + 0xFFFFFF; - this->destCellZ = d << 24; + this->render.color &= (static_cast(b) << 24) + 0xFFFFFF; + this->destCellZ = static_cast(c) << 24; return; case BM_MOTIONY: this->destCellX = *reinterpret_cast(&b); @@ -570,26 +569,25 @@ void CBlurPC::SendMsg( this->render.isMotionFreezed = 1; return; } - } - CPc::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + CPc::SendMsg(sender, message, b, c, d, e, 0, 0); } // OFFSET: 0x00DA4AD0 // FUNCTION: fn_22420 void CCorpse::SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int, int, int, int + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) { - CRenderObject::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + CRenderObject::SendMsg(sender, message, b, c, d, e, 0, 0); } // OFFSET: 0x00DA4B10 // FUNCTION: fn_22421 void CGndRiser::SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int, int, int, int + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) { - if (message == 14 && a == 0) { - const float* position = reinterpret_cast(b); + if (message == 14) { + const float* position = reinterpret_cast(static_cast(b)); this->render.position.x = position[0]; this->render.position.y = position[1]; this->render.position.z = position[2]; @@ -606,23 +604,22 @@ void CGndRiser::SendMsg( return; } - EffectActor::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + EffectActor::SendMsg(sender, message, b, c, d, e, 0, 0); } // OFFSET: 0x00DA4BF0 // FUNCTION: fn_22422 void CHalluNPC::SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int, int, int, int + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) { - if (a == 0) { switch (message) { case BM_RGB: - this->SetColor(180, b, d, f); + this->SetColor(180, static_cast(b), static_cast(c), static_cast(d)); this->fadeStep = 0x8000000; return; case BM_ALPHA: - this->render.color &= (b << 24) + 0xFFFFFF; - this->fadeStep = d << 24; + this->render.color &= (static_cast(b) << 24) + 0xFFFFFF; + this->fadeStep = static_cast(c) << 24; return; case BM_MOTIONY: this->hallucinationOffset = *reinterpret_cast(&b); @@ -631,25 +628,23 @@ void CHalluNPC::SendMsg( this->render.isMotionFreezed = 1; return; } - } - CNpc::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + CNpc::SendMsg(sender, message, b, c, d, e, 0, 0); } // OFFSET: 0x00DA4CC0 // FUNCTION: fn_22423 void CHalluPC2::SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int, int, int, int + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) { - if (a == 0) { switch (message) { case BM_RGB: this->SetColor(180, 255, 55, 55); this->destCellZ = 0x8000000; return; case BM_ALPHA: - this->render.color &= (b << 24) + 0xFFFFFF; - this->destCellZ = d << 24; + this->render.color &= (static_cast(b) << 24) + 0xFFFFFF; + this->destCellZ = static_cast(c) << 24; return; case BM_MOTIONY: this->destCellX = *reinterpret_cast(&b); @@ -658,25 +653,23 @@ void CHalluPC2::SendMsg( this->render.isMotionFreezed = 1; return; } - } - CPc::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + CPc::SendMsg(sender, message, b, c, d, e, 0, 0); } // OFFSET: 0x00DA4D90 // FUNCTION: fn_22424 void CHalluPC::SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int, int, int, int + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) { - if (a == 0) { switch (message) { case BM_RGB: - this->SetColor(180, b, d, f); + this->SetColor(180, static_cast(b), static_cast(c), static_cast(d)); this->destCellZ = 0x8000000; return; case BM_ALPHA: - this->render.color &= (b << 24) + 0xFFFFFF; - this->destCellZ = d << 24; + this->render.color &= (static_cast(b) << 24) + 0xFFFFFF; + this->destCellZ = static_cast(c) << 24; return; case BM_MOTIONY: this->destCellX = *reinterpret_cast(&b); @@ -685,30 +678,29 @@ void CHalluPC::SendMsg( this->render.isMotionFreezed = 1; return; } - } - CPc::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + CPc::SendMsg(sender, message, b, c, d, e, 0, 0); } // OFFSET: 0x00DA4E60 // FUNCTION: fn_22425 void CHalluPlant::SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int, int, int, int + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) { - if ((message | a) != 0) { - if (message == 1 && a == 0) { - this->render.color &= (b << 24) + 0xFFFFFF; + if (message != 0) { + if (message == 1) { + this->render.color &= (static_cast(b) << 24) + 0xFFFFFF; return; } - if (message == 3 && a == 0) { + if (message == 3) { this->render.isMotionFreezed = 1; return; } - CNpc::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + CNpc::SendMsg(sender, message, b, c, d, e, 0, 0); } else { - this->SetColor(180, b, d, f); + this->SetColor(180, static_cast(b), static_cast(c), static_cast(d)); } } struct NpcAppearInfo { @@ -724,11 +716,11 @@ struct NpcAppearInfo { // OFFSET: 0x00DA4EF0 // FUNCTION: fn_22426 void CNpc::SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int, int, int, int + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) { - if (message == 4 && a == 0) { - CGameActor::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); - const NpcAppearInfo* info = reinterpret_cast(b); + if (message == 4) { + CGameActor::SendMsg(sender, message, b, c, d, e, 0, 0); + const NpcAppearInfo* info = reinterpret_cast(static_cast(b)); switch (this->objectType) { case 8: case 9: @@ -743,7 +735,7 @@ void CNpc::SendMsg( return; } - if (message == AM_UPDATEGAGE && a == 0) { + if (message == AM_UPDATEGAGE) { if (g_session.IsCompanionAid(this->render.accountId)) { if (this->playerGaugeWindow == nullptr) { this->playerGaugeWindow = new UIPlayerGage(); @@ -840,22 +832,22 @@ void CNpc::SendMsg( return; } } - static_cast(this->pcGaugeWindow)->SetValues(b, d); + static_cast(this->pcGaugeWindow)->SetValues(static_cast(b), static_cast(c)); static_cast(this->pcGaugeWindow)->SetLimits(0, 0); const int y = this->render.screenY + ScaleByScreenHeight(12); this->pcGaugeWindow->Move(this->render.screenX - 30, y); return; } - CGameActor::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + CGameActor::SendMsg(sender, message, b, c, d, e, 0, 0); } // OFFSET: 0x00DA5610 // FUNCTION: fn_22427 void CNumEffect::SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int, int, int, int + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) { - if (message == 14 && a == 0) { - const float* position = reinterpret_cast(b); + if (message == 14) { + const float* position = reinterpret_cast(static_cast(b)); this->render.position.x = position[0]; this->render.position.y = position[1]; this->render.position.z = position[2]; @@ -863,36 +855,37 @@ void CNumEffect::SendMsg( this->render.position.y -= 12.0f; this->baseHeight = this->render.position.y; - this->render.curMotion = d; - if (d > 9 || d < 0) { + const int motion = static_cast(c); + this->render.curMotion = motion; + if (motion > 9 || motion < 0) { this->render.curMotion = 0; } - this->render.spriteOffsetX = f; + this->render.spriteOffsetX = static_cast(d); this->render.scale = 5.0f; this->baseScale = 5.0f; this->render.motionStartTime = timeGetTime(); return; } - if (message == 22 && a == 0) { + if (message == 22) { return; } - CRenderObject::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + CRenderObject::SendMsg(sender, message, b, c, d, e, 0, 0); } // OFFSET: 0x00DA56E0 // FUNCTION: fn_22428 void CSoundMaker::SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int, int, int, int + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) { - if (message != 14 || a != 0) { - CRenderObject::SendMsg(sender, message, a, b, c, d, e, f, g, h, i, 0, 0, 0, 0); + if (message != 14) { + CRenderObject::SendMsg(sender, message, b, c, d, e, 0, 0); return; } - const WorldSoundRecord& sound = *reinterpret_cast(b); + const WorldSoundRecord& sound = *reinterpret_cast(static_cast(b)); this->file = sound.file; this->volume = sound.volume; this->width = sound.width; @@ -1324,7 +1317,7 @@ void CNpc::UpdateMinimapMarker() { return; } if (this->attachedEffect) { - this->attachedEffect->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->attachedEffect->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); this->attachedEffect = nullptr; this->attachedEffectId = 9999; } @@ -1332,7 +1325,7 @@ void CNpc::UpdateMinimapMarker() { const int base = marker->effectType < 6 ? 0x24 : 0x36; CMsgEffect* effect = mode->SpawnMsgEffect(base + marker->effectType, &this->render.position, this->render.accountId, true); this->msgEffectList.push_back(effect); - effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(this, AM_SET_MASTER_POINTER, 0, 0, 0, 0, 0, 0); this->attachedEffect = effect; this->minimapMarkerCell[0] = marker->effectType; this->minimapMarkerCell[1] = marker->questIconId; @@ -1340,7 +1333,7 @@ void CNpc::UpdateMinimapMarker() { } if (this->attachedEffect) { - this->attachedEffect->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->attachedEffect->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); this->attachedEffect = nullptr; this->attachedEffectId = 9999; } @@ -1407,7 +1400,7 @@ bool CNpc::OnProcess() { } else { reinterpret_cast(this->homunAI)->Load(".\\AI\\AI.lua"); } - this->SendMsg(nullptr, AM_UPDATEGAGE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_UPDATEGAGE, 0, 0, 0, 0, 0, 0); } } else { this->homunAI = reinterpret_cast(new CMercenaryAI(0)); @@ -1432,7 +1425,7 @@ bool CNpc::OnProcess() { path = ".\\AI\\AI_M.lua"; } reinterpret_cast(this->merAI)->Load(path); - this->SendMsg(nullptr, AM_UPDATEGAGE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_UPDATEGAGE, 0, 0, 0, 0, 0, 0); } } else { this->merAI = reinterpret_cast(new CMercenaryAI(1)); @@ -1440,17 +1433,17 @@ bool CNpc::OnProcess() { } if (g_session.IsPetAid(this->render.accountId)) { - this->SendMsg(nullptr, AM_UPDATEGAGE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_UPDATEGAGE, 0, 0, 0, 0, 0, 0); } this->UpdateBubblePositions(); if (g_session.homunAlive && g_groundMarkAid == this->render.accountId) { - this->SendMsg(nullptr, 0x86, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, 0x86, 0, 0, 0, 0, 0, 0); } else if (g_session.mercenaryAlive && g_groundMarkAltAid == this->render.accountId) { - this->SendMsg(nullptr, 0x86, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, 0x86, 0, 0, 0, 0, 0, 0); } else { - this->SendMsg(nullptr, 0x87, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, 0x87, 0, 0, 0, 0, 0, 0); } this->UpdateMinimapMarker(); @@ -1732,8 +1725,8 @@ void CNpc::SetState(int state, int) { this->render.timedSequenceActive = 0; this->render.isMotionFreezed = false; if (this->bodyState == 2) { - this->SendMsg(nullptr, AM_DELETE_ICEEFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_MAKE_ICEBREAKE_FFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_ICEEFFECT, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_ICEBREAKE_FFECT, 0, 0, 0, 0, 0, 0); } this->render.isLieOnGround = true; this->render.isMotionFreezed = false; @@ -1779,8 +1772,8 @@ void CNpc::SetState(int state, int) { break; case ST_SLEEP: if (this->bodyState == 2) { - this->SendMsg(nullptr, AM_DELETE_ICEEFFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - this->SendMsg(nullptr, AM_MAKE_ICEBREAKE_FFECT, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_DELETE_ICEEFFECT, 0, 0, 0, 0, 0, 0); + this->SendMsg(nullptr, AM_MAKE_ICEBREAKE_FFECT, 0, 0, 0, 0, 0, 0); } this->render.isLieOnGround = false; this->render.isMotionFinished = true; diff --git a/Source/Contents/Sound/SoundMaker.h b/Source/Contents/Sound/SoundMaker.h index 5abab7504..2cd178eec 100644 --- a/Source/Contents/Sound/SoundMaker.h +++ b/Source/Contents/Sound/SoundMaker.h @@ -11,7 +11,7 @@ public: ~CSoundMaker() override; bool OnProcess() override; void SendMsg( - CGameObject* sender, int message, int a, int b, int c, int d, int e, int f, int g, int h, int i, int j, int k, int l, int m + CGameObject* sender, std::int64_t message, std::int64_t b, std::int64_t c, std::int64_t d, std::int64_t e, std::int64_t f, std::int64_t g ) override; void Render(int argument) override; diff --git a/Source/Contents/Sprites/SpriteLayerDrawing.cpp b/Source/Contents/Sprites/SpriteLayerDrawing.cpp index d13b02180..a2a21bbac 100644 --- a/Source/Contents/Sprites/SpriteLayerDrawing.cpp +++ b/Source/Contents/Sprites/SpriteLayerDrawing.cpp @@ -659,7 +659,7 @@ void SpriteLayerRenderer::DrawLayer( quad.image = resolved.image; const std::uint32_t* palette = this->GetPalette(layer, sprite, action); int effect = 0xA6; - this->pc->SendMsg(nullptr, AM_IS_HAVE_EFFECT, 0, reinterpret_cast(&effect), reinterpret_cast(&effect) >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + this->pc->SendMsg(nullptr, AM_IS_HAVE_EFFECT, reinterpret_cast(&effect), 0, 0, 0, 0, 0); int blend; switch (layer) { diff --git a/Source/Contents/World/WorldEffects.cpp b/Source/Contents/World/WorldEffects.cpp index e97c7c615..346b345b7 100644 --- a/Source/Contents/World/WorldEffects.cpp +++ b/Source/Contents/World/WorldEffects.cpp @@ -29,7 +29,7 @@ void CWorld::LoadMapEffects() { } else { CEffectMaker* effect = new CEffectMaker; const int address = reinterpret_cast(record); - effect->SendMsg(nullptr, AM_SETPOS, 0, address, address >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(nullptr, AM_SETPOS, address, 0, 0, 0, 0, 0); this->objects.push_back(effect); } } @@ -41,7 +41,7 @@ void CWorld::LoadMapEffects() { WorldSoundRecord* record = *it; CSoundMaker* sound = new CSoundMaker; const int address = reinterpret_cast(record); - sound->SendMsg(nullptr, AM_SETPOS, 0, address, address >> 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + sound->SendMsg(nullptr, AM_SETPOS, address, 0, 0, 0, 0, 0); this->objects.push_back(sound); } } diff --git a/Source/Contents/World/WorldObjects.cpp b/Source/Contents/World/WorldObjects.cpp index a2875873a..585957d7f 100644 --- a/Source/Contents/World/WorldObjects.cpp +++ b/Source/Contents/World/WorldObjects.cpp @@ -190,7 +190,7 @@ void CWorld::OnProcess() { continue; } - skill->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); if (skill->HasPendingDamage() == true) { if (std::find(this->pendingActorIds.begin(), this->pendingActorIds.end(), aid) == this->pendingActorIds.end()) { this->pendingActorIds.push_back(aid); @@ -270,7 +270,7 @@ void CWorld::SendObjectMessage(CGameObject* sender, std::uint64_t identity, int auto it = std::find_if(this->objects.begin(), this->objects.end(), [identity](CRenderObject* object) { return identity == object->identity; }); if (it != this->objects.end()) { - (*it)->SendMsg(sender, message, message >> 31, a, a >> 31, b, b >> 31, c, c >> 31, d, d >> 31, 0, 0, 0, 0); + (*it)->SendMsg(sender, message, a, b, c, d, 0, 0); } } @@ -285,8 +285,7 @@ void CGameMode::SpawnArrowEffect(std::uint32_t aid, int target, char flag, int a if (effect) { this->scene->objects.push_back(effect); - effect->SendMsg(nullptr, AM_SETPOS, 0, static_cast(aid), static_cast(aid) >> 31, target, 0, reinterpret_cast(&flag), - reinterpret_cast(&flag) >> 31, argument, argument >> 31, 0, 0, 0, 0); + effect->SendMsg(nullptr, AM_SETPOS, static_cast(aid), static_cast(target), reinterpret_cast(&flag), argument, 0, 0); } } @@ -297,8 +296,7 @@ void CGameMode::SpawnArrowEffect64(const vector3d* source, const vector3d* targe if (effect) { this->scene->objects.push_back(effect); - effect->SendMsg(nullptr, AM_SETPOS2, 0, reinterpret_cast(source), reinterpret_cast(source) >> 31, reinterpret_cast(target), - reinterpret_cast(target) >> 31, reinterpret_cast(&speed), reinterpret_cast(&speed) >> 31, 0, 0, 0, 0, 0, 0); + effect->SendMsg(nullptr, AM_SETPOS2, reinterpret_cast(source), reinterpret_cast(target), reinterpret_cast(&speed), 0, 0, 0); } } @@ -591,9 +589,8 @@ CMsgEffect* CGameMode::SpawnCashEmotion(int aid, int packId, int emotionId, std: this->scene->objects.emplace_back(effect); } - effect->SendMsg(nullptr, AM_SETMASTERGID, 0, duration, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0); - effect->SendMsg(nullptr, AM_SETPOS, 0, aid, aid >> 31, reinterpret_cast(&names), reinterpret_cast(&names) >> 31, data->actionIndex, - data->actionIndex >> 31, 0, 0, 0, 0, 0, 0); + effect->SendMsg(nullptr, AM_SETMASTERGID, duration, 1, 0, 0, 0, 0); + effect->SendMsg(nullptr, AM_SETPOS, aid, reinterpret_cast(&names), data->actionIndex, 0, 0, 0); } return effect; @@ -626,7 +623,7 @@ void CGameMode::SpawnMandraAttack(std::uint32_t aid, int target, char flag) { if (effect) { this->scene->objects.push_back(effect); - effect->SendMsg(nullptr, AM_SETPOS, 0, aid, 0, reinterpret_cast(&flag), reinterpret_cast(&flag) >> 31, target, target >> 31, 0, 0, 0, 0, 0, 0); + effect->SendMsg(nullptr, AM_SETPOS, aid, reinterpret_cast(&flag), target, 0, 0, 0); } } @@ -913,7 +910,7 @@ bool CWorld::RemoveSkill(std::uint32_t aid) { return false; } - skill->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + skill->SendMsg(nullptr, AM_DISAPPEAR, 0, 0, 0, 0, 0, 0); if (skill->HasPendingDamage() == true) { for (std::uint32_t pending : this->pendingActorIds) { @@ -948,9 +945,8 @@ CMsgEffect* CGameMode::SpawnDamageMsgEffect(const vector3d* position, std::uint3 CMsgEffect* effect = new CMsgEffect; if (effect) { this->scene->objects.push_back(effect); - effect->SendMsg(nullptr, AM_SETMASTERGID, 0, accountId, 0, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0); - effect->SendMsg(nullptr, AM_SETPOS, 0, reinterpret_cast(position), reinterpret_cast(position) >> 31, reinterpret_cast(&names), - reinterpret_cast(&names) >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(nullptr, AM_SETMASTERGID, accountId, 13, 0, 0, 0, 0); + effect->SendMsg(nullptr, AM_SETPOS, reinterpret_cast(position), reinterpret_cast(&names), 0, 0, 0, 0); effect->render.color = color; effect->render.useGroundLighting = 0; } @@ -1358,10 +1354,9 @@ CMsgEffect* CGameMode::SpawnMsgEffect(int effectId, const vector3d* position, st if (effect) { this->scene->objects.push_back(effect); - effect->SendMsg(nullptr, AM_SETMASTERGID, 0, accountId, 0, type, type >> 31, 0, 0, 0, 0, 0, 0, 0, 0); + effect->SendMsg(nullptr, AM_SETMASTERGID, accountId, type, 0, 0, 0, 0); effect->m_visible = visible; - effect->SendMsg(nullptr, AM_SETPOS, 0, reinterpret_cast(position), reinterpret_cast(position) >> 31, reinterpret_cast(names), - reinterpret_cast(names) >> 31, animation, animation >> 31, 0, 0, 0, 0, 0, 0); + effect->SendMsg(nullptr, AM_SETPOS, reinterpret_cast(position), reinterpret_cast(names), animation, 0, 0, 0); } return effect; diff --git a/Source/UI/Window/UIWindowMgr.cpp b/Source/UI/Window/UIWindowMgr.cpp index 0d5eeb6fb..bfcccd565 100644 --- a/Source/UI/Window/UIWindowMgr.cpp +++ b/Source/UI/Window/UIWindowMgr.cpp @@ -1781,7 +1781,7 @@ void UIWindowMgr::CycleWindowVisibility(int) { this->CloseWindow(WID_MINIMAPZOOMWND); CPlayer* player = static_cast(g_modeMgr.GetGameMode())->scene->player; if (player) { - player->SendMsg(nullptr, AM_DELETE_EFFECT, 0, 164, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + player->SendMsg(nullptr, AM_DELETE_EFFECT, 164, 0, 0, 0, 0, 0); player->skillEffect = 0; } this->windowVisibilityState = 2;