diff --git a/main/source/mod/AvHMiniMap.cpp b/main/source/mod/AvHMiniMap.cpp index 4b90f03..9c552ec 100644 --- a/main/source/mod/AvHMiniMap.cpp +++ b/main/source/mod/AvHMiniMap.cpp @@ -62,7 +62,7 @@ bool AvHMiniMap::GetIsProcessing(float* outPercentageDone) const { bool theIsProcessing = false; - if(this->mIsProcessing) + if(this->mIsProcessing || (this->mNumSamplesProcessed == this->mNumSamplesToProcess && this->mNumSamplesProcessed > 0)) { if(outPercentageDone) { @@ -327,7 +327,7 @@ bool AvHMiniMap::WriteMapToSprite() { bool theSuccess = false; - if(!this->GetIsProcessing()) + if(this->GetIsProcessing()) { // Open file // puzl: 1064 @@ -435,6 +435,14 @@ bool AvHMiniMap::WriteSpritesIfJustFinished() { bool theSuccess = false; + // test + char test[255]; + sprintf(test, "this->GetIsProcessing() = %d, this->mNumSamplesProcessed = %d, this->mNumSamplesToProcess = %d\n", this->GetIsProcessing(), this->mNumSamplesProcessed, this->mNumSamplesToProcess); + gEngfuncs.pfnConsolePrint(test); + + // :test + + if(this->GetIsProcessing() && (this->mNumSamplesProcessed == this->mNumSamplesToProcess)) { this->mIsProcessing = false; diff --git a/main/source/mod/AvHNetworkMessages.cpp b/main/source/mod/AvHNetworkMessages.cpp index a86c304..5bb5e66 100644 --- a/main/source/mod/AvHNetworkMessages.cpp +++ b/main/source/mod/AvHNetworkMessages.cpp @@ -1182,6 +1182,7 @@ union float_converter height = READ_LONG(); *map = new uint8[num_samples]; finished = false; + break; case 1: { int packet_samples = READ_BYTE(); @@ -1189,9 +1190,12 @@ union float_converter { (*map)[processed_samples++] = READ_BYTE(); } + finished = false; + break; } case 2: finished = true; + break; } END_READ(); }