Immersive Vehicles (Formerly Transport Simulator)

Immersive Vehicles (Formerly Transport Simulator)

4M Downloads

[BUG] radarWidth (seems) to only be usable as 0.0 or 180.0

boot2big opened this issue ยท 16 comments

commented

If I set it to anything below 180, it doesn't work. If I set it equal to or above 180, it will work.
What do I mean, you ask?
image
^ This will not work
image
^ This will work

Yes, I circled around the vehicle all away around, and it did nuffin. Zilch, nada.
(I am aware that Range happens to be set to 180 as well, but radarRange is irrelevant here as the range parameter works just fine.)

This is on a part that actively uses radar variables, and so I would assume that this would force the part's radar variables to only search in a 180 degree radius in-front of the part (and by extension vehicle)

commented

P.S would have outsourced to conman in his DMs but it has been weeks since I sent him a Friend Request, and I do not think you'd be up to discussion of other options on the MTS issues tracker, even though you don't wanna do DMs.

commented

Do you have a video showing that it doesn't work? I made sure to test that it worked. All my radars in my pack have a width of 60 set. I also set the radar variables to the vehicle itself rather than a part.

commented

Can provide a video in a jiffy.

commented

It would also be nice to have a description of what you're trying to use the radar variables for as it was initially intended for use in instruments as an animation variable. The only change I made to how the radars work is to not index a contact unless it is within the width and range. as indexing all could cause some gameplay issues.

commented

Semi-Self Driving, seen in Discussions tab (Show & Tell)

commented
radar.mp4

Id need a video of what yours is doing as it works fine on my end.

commented

It is indeed set to radar_ground_1_X, however this is because setting it to the conventional 0 results in the LIDAR bar following nothing. Will send you a beta copy over Discord.

commented
2023-03-04.22-24-11.mp4
2023-03-04.22-23-37.mp4

Red car equipped with 90-degree radar (Does not work, should work when nearest radar target is in front of vehicle)
Blue car equipped with 180-degree radar (Works, see text above vehicle VS red car)

commented
2023-03-04.22-26-20.mp4

New, buggier behavior found. I don't yet know how to convey what's exactly wrong here, but when the motorcycle is in the red car's vision it will attempt to follow the blue car (Not logical as the motorcycle is closer) and when the motorcycle is out of the red car's vision it will cease to see anything (Default behavior for SSD models is to hold brake)

commented

interesting. my radars are set to 60 and they detect things fine. Where is the part positioned on the car with the radar?

commented

Is the 90 degree car variable set to radar_ground_1_distance and radar_ground_1_direction? If so that could be the issue. the radar starts at 0 being the closest. the most recent video reminds me of a json mistake i made initially where if it only sees one thing, nothing shows up, however if it sees 2, and is configured to animate based on 1 rather than 0, it'll point at the second closest. Also record another video with a 3rd vehicle within the configured limits and see if it still points at the second closest vehicle.

commented

also re send the friend request on discord, I wasnt putting 2 and 2 together on who was sending as the name differs here.

commented

The radar is mounted on top of the car, using the generic_lightbar slot.

commented
radar.mp4

tested myself and this is what should happen right? set radar width to 90.

commented

Exactly, yes! ๐Ÿ‘

commented

Therefore, this can be closed, correct?