mirror of
https://github.com/OpenFusionProject/OpenFusion.git
synced 2025-12-19 03:00:35 +00:00
Group warping & mob movement smoothing
* Warping into IZs and Fusion Lairs now will also take into account your group members. * MobManager lerp does not confusingly divide speed by 2 anymore. * Mobs pursue their targets more smoothly, they will avoid phasing into the player during combat. * Nerfed retreat speed by a factor of 1.5, normal mobs retreated way too quickly however mobs like Don Doom and Bad Max do not retreat fast enough. * Bugfixed sendPlayerTo, it did not call updatePlayerPosition leaving undesirable anomalies.
This commit is contained in:
@@ -261,6 +261,7 @@ void PlayerManager::sendPlayerTo(CNSocket* sock, int X, int Y, int Z, uint64_t I
|
||||
PlayerManager::removePlayerFromChunks(plrv.currentChunks, sock);
|
||||
plrv.currentChunks.clear();
|
||||
sock->sendPacket((void*)&resp, P_FE2CL_REP_PC_WARP_USE_NPC_SUCC, sizeof(sP_FE2CL_REP_PC_WARP_USE_NPC_SUCC));
|
||||
updatePlayerPosition(sock, X, Y, Z);
|
||||
}
|
||||
|
||||
ChunkManager::destroyInstanceIfEmpty(fromInstance);
|
||||
@@ -279,6 +280,7 @@ void PlayerManager::sendPlayerTo(CNSocket* sock, int X, int Y, int Z) {
|
||||
plrv.currentChunks.clear();
|
||||
plrv.chunkPos = std::make_tuple(0, 0, plrv.plr->instanceID);
|
||||
sock->sendPacket((void*)&pkt, P_FE2CL_REP_PC_GOTO_SUCC, sizeof(sP_FE2CL_REP_PC_GOTO_SUCC));
|
||||
updatePlayerPosition(sock, X, Y, Z);
|
||||
}
|
||||
|
||||
void PlayerManager::enterPlayer(CNSocket* sock, CNPacketData* data) {
|
||||
|
||||
Reference in New Issue
Block a user