RenCloud / scs-sdk-plugin

ETS2 (Euro Truck Simulator 2) & ATS (American Truck Simulator) SDK plug-in. Telemetry data is shared via SharedMemory/Memory Mapped Files.
MIT License
185 stars 35 forks source link

Events getting called too often #96

Open Er0nax opened 2 years ago

Er0nax commented 2 years ago

Each time, the sdk gets an event (e.g. fined), the function gets called more then once. This isn't just once every x times. Might it be a bug from ets2 side?

ndelta0 commented 2 years ago

The plugin passes everything it receives directly, so it probably is something with the game, although it should be possible to change that

Er0nax commented 2 years ago

Well, if you are trying to use the included Demo, its even sending any event 4 times. I do not have a problem with that as there are many workarounds, but I thought I let you guys know in case its a problem with the actual code from this repo.

RenCloud commented 2 years ago

Thank you for reporting this. Like ndelta0 wrote the events are basically just past through.

I will check that. It could be the bug of another issue than i would try to prevent this.

RenCloud commented 2 years ago

Could not reproduce it in a 10 minute drive. But another person reported it to me, too. So I probably need more information e.g. game version and game (ats or ets2)

Er0nax commented 2 years ago

I was trying it in ETS2 on 1.42 aswell as 1.43

mrnat7471 commented 1 year ago

Could I ask if this is similar to the event job.delivered spamming many times? Our client will flush (Write over) the memory location of the event once it been dealt with but for some people, it will just spam forever, not every job and its not limited to job.delivered event. Its very random and I haven't found a pattern yet.