Unsolved Tiny assistance needed with something.

Discussion in 'Mod Support' started by mehio, Jul 28, 2018.

  1. mehio

    mehio
    Expand Collapse

    Joined:
    Jun 20, 2018
    Messages:
    153
    Tires and rims are spinning around the car and floating around but not the brakes.
    Yes i did apply center to geometry in blender and did not apply location with ctrl A.
    This method fixed the brakes and did not let them float around but it did not fix the tires and rims.
    Could someone take a quick glance and see whats happening?
    Thanks
     

    Attached Files:

  2. torsion

    torsion
    Expand Collapse

    Joined:
    May 31, 2015
    Messages:
    1,600
    "Universal wheels" are different from the rest of the vehicle. I'm not sure where this is documented, if at all. Fortunately it's pretty easy once you know what you're supposed to do! Basically you should put your tires and wheels/rims at 0,0,0 in Blender and apply that.

    As is often the case, the easiest way to understand the correct format is to open some official content and look at that.

    Grab this file:
    Steam\SteamApps\common\BeamNG.drive\content\vehicles\common.zip

    Unzip it somewhere convenient, for example "Desktop\common\". Now look in here:
    Desktop\common\vehicles\common\wheels\

    Import "wheels.dae" into Blender and emulate what's been done there. Same thing applies to tires, they are in "common\vehicles\tires".

    You should keep your wheels and tires separate from the rest of the car once you do this, so inside your mod you'll have something like:
    \vehicles\mehio_mycar\mycar.jbeam
    \vehicles\mehio_mycar\mycar.dae
    \vehicles\common\wheels\mehio_mycar_wheels.jbeam
    \vehicles\common\wheels\mehio_mycar_wheels.dae
    \vehicles\common\tires\mehio_mycar_tires.jbeam
    \vehicles\common\tires\mehio_mycar_tires.dae

    It's important to maintain unique filenames using a technique like I've described above. Otherwise you'll constantly find yourself explaining things like "oh, your problem is that you have XYZ mod and mymod installed at the same time. XYZ mod breaks mymod" due to filename collisions. Same thing applies to the part names within your jbeams actually - especially in the universal wheel system.
     
  3. mehio

    mehio
    Expand Collapse

    Joined:
    Jun 20, 2018
    Messages:
    153
    Thanks alot, worked like a charm!
    I still have a problem with the gauge needles and the steering wheel. I tried to do it like the wheels and rims it ddnt work , or even like the driveshaft and radiator fan. Which line in the jbeam controls the way the object should rotate?
     
    • Like Like x 1
  4. fufsgfen

    fufsgfen
    Expand Collapse

    Joined:
    Jan 10, 2017
    Messages:
    6,774
    It is rot in props line that controls which way to rotate you can have like -1 or 1 which are different directions.

    Sometimes with props one need to do this, especially if you accidentally apply rotation or location in Blender, first one prevents them to moved by setting baseTranslation and second makes them rotate funny way, but you set object to 0,0,0 apply rotation and location, then move it where you want again and NOT apply rotation or location anymore:
    https://www.beamng.com/threads/how-to-incorporate-a-steering-wheel-into-a-car-mod.41532/#post-624838

    For needles, surface you want to look in car, must face up unless I remember wrong.

    Then be very careful when selection reference nodes for a prop (each prop needs those to be set) as it all is related to reference nodes axis, not global axis, so try to find nodes that run exactly same as global axis, that makes setting them much easier.

    Also, translation and baseTranslation are different, translation is how much prop will move when action is performed, while baseTranslation sets position related to prop's refnode (again different from vehicle's refnodes).

    I set my 53Turbo this way, notice at the end I have baseTranslation:
    ["rpm", "hatch_needle_tacho", "a14", "a15", "a18",{"x":-18, "y":180, "z":10}, {"x":0, "y":0, "z":-0.034}, {"x":0.0, "y":0.0, "z":0.0}, -0, 7500, 1500, 1,{ "baseTranslation":{"x":0.17, "y":0.761, "z":0.766}},],

    I could of set it on these headings, but above way works too. These headings are important, these are what define which column does what, they are not just headings for a modder to know, but they define for game which is which, you can add and remove things, but ALL lines must then contain ALL values, but using it way I did above line allows one line to differ from others for example.
    "props": [
    ["func", "mesh", "idRef:", "idX:", "idY:", "baseRotation", "rotation", "translation", "min", "max", "offset", "multiplier"]

    And then setting needles to show up correct reading, that is trial and error, trough frustration, sometimes 0.02 in rotation is a lot (like almost full turn), sometimes 100 is not much more than quarter of turn, there is no any kind of logic that I know of, you just try different numbers, see what happens and somehow it all is related to prop's refnodes, you can't copy values from other vehicle and have it work, even using same needles, dash etc.

    Like my speedo which is same size etc, as rpm gauge, but it has to have -4.1 in z rotation, instead of -0.034, even height has to be different for them to end up same height, same refnodes, same height in Blender, but that is how it works, completely random or then I just suck, but maybe this all helps a little.
    ["wheelspeed", "hatch_needle_speedo", "a14", "a15", "a18",{"x":20, "y":168, "z":-140}, {"x":0, "y":0, "z":-4.1}, {"x":0.0, "y":0.0, "z":0.0}, 0, 53.5, 2000, 1,{ "baseTranslation":{"x":-0.01, "y":0.763, "z":0.775}},],

    Anyway that "z":-4.1 made it turn clockwise for those paramters, it really depends from lot of variables. Also it is bit silly how baseRotation had to be so much different, but you randomly try different settings, see what happens and adjust based on that, then numbers end up being something and it hopefully works.
     
    • Like Like x 1
  5. mehio

    mehio
    Expand Collapse

    Joined:
    Jun 20, 2018
    Messages:
    153
    Hi i tried everything it still wont work. The steering wheel and the needles are in their correct places but they spawn parallel to the Y axis.And they turn arround the y axis.
     

    Attached Files:

    #5 mehio, Aug 2, 2018
    Last edited: Aug 2, 2018
  6. torsion

    torsion
    Expand Collapse

    Joined:
    May 31, 2015
    Messages:
    1,600
    Have you looked at official content? Be sure to look at both OEM and option parts for a better understanding. Also you should certainly reference the props wiki page: https://wiki.beamng.com/Props
     
    • Agree Agree x 1
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice