Merge pull request #65 from web3gamedev/master

cast jitter to double before dividing by 1000
This commit is contained in:
Nathan authored and GitHub committed 2024-07-22 18:44:06 +02:00
commit c5d34df9fd
1 file changed
+1 -1
+1 -1
View File
@@ -5885,7 +5885,7 @@ int NBN_PacketSimulator_EnqueuePacket(NBN_PacketSimulator *packet_simulator, NBN
NBN_PacketSimulatorEntry *entry = (NBN_PacketSimulatorEntry *)MemoryManager_Alloc(NBN_MEM_PACKET_SIMULATOR_ENTRY);
entry->delay = packet_simulator->ping + jitter / 1000; /* and converted back to seconds */
entry->delay = packet_simulator->ping + (double)jitter / 1000; /* and converted back to seconds */
entry->receiver = receiver;
entry->enqueued_at = packet_simulator->endpoint->time;