mirror of
https://github.com/OpenFusionProject/OpenFusion.git
synced 2024-11-22 13:30:06 +00:00
fixed NPC spawning bug
This commit is contained in:
parent
8f84c4c2f8
commit
874479d1cf
@ -22,8 +22,7 @@ public:
|
||||
appearanceData.iBarkerType = 0;
|
||||
appearanceData.iNPC_ID = id;
|
||||
|
||||
chunkPos = ChunkManager::grabChunk(x, y);
|
||||
currentChunks = ChunkManager::grabChunks(chunkPos);
|
||||
chunkPos = std::pair<int, int>(0, 0);
|
||||
};
|
||||
BaseNPC(int x, int y, int z, int type, int id, NPCClass classType) : BaseNPC(x, y, z, type, id) {
|
||||
npcClass = classType;
|
||||
|
@ -530,7 +530,6 @@ void NPCManager::npcSummonHandler(CNSocket* sock, CNPacketData* data) {
|
||||
NPCs[resp.NPCAppearanceData.iNPC_ID] = new BaseNPC(plr->x, plr->y, plr->z, req->iNPCType, resp.NPCAppearanceData.iNPC_ID);
|
||||
|
||||
updateNPCPosition(resp.NPCAppearanceData.iNPC_ID, plr->x, plr->y, plr->z);
|
||||
ChunkManager::addNPC(plr->x, plr->y, resp.NPCAppearanceData.iNPC_ID);
|
||||
}
|
||||
|
||||
void NPCManager::npcWarpHandler(CNSocket* sock, CNPacketData* data) {
|
||||
|
Loading…
Reference in New Issue
Block a user