jenchanws / create-track-map

Create train track map mod for Minecraft (Fabric & Forge)
https://modrinth.com/mod/create-track-map
MIT License
65 stars 19 forks source link

Smooth train movement #35

Open pernydev opened 1 year ago

pernydev commented 1 year ago

Hiya! This is my first ever PR to a Minecraft mod so I don't know if I did everything right. Thankfully I only had to edit the frontend so it was within my knowledge. The idea was told in #33 so I made it! I hope the code is good and readable enough. Sorry for the extra 3.98 kilobytes it added.

creeper6530 commented 11 months ago

I just built it on my machine using gradlew.bat build, and it crashes right away.

Logs:

pernydev commented 11 months ago

I don't see a way adding stuff to the webserver would result in a game crash. This branch is pretty outdated currently which might've caused the problem.

creeper6530 commented 11 months ago

I don't either. Your theory seems believable though, so it might be a good idea to consider syncing your fork.

creeper6530 commented 11 months ago

I just build an up-to-date version, which I created by forking the upstream myself and then merging your fork into mine.

It doesn't crash nor show anything unusual in Minecraft logs, however, there aren't any trains visible on the map, even though the track occupancy and signals do work. The "Trains" list in the top left is empty as well. You can see proof here.

The browser console is chock-full of errors, as seen here. I'm no frontend dev though, so I'll leave the debugging to you.

pernydev commented 11 months ago

I didn't consider the trains list at the top and by changing the train variable to a map might've broken it.