1. Trouble with the game?
    Try the troubleshooter!

    Dismiss Notice
  2. Issues with the game?
    Check the Known Issues list before reporting!

    Dismiss Notice
  3. Before reporting issues or bugs, please check the up-to-date Bug Reporting Thread for the current version.
    0.32 Bug Reporting thread
    Solutions and more information may already be available.

I put a tow hitch on the pigeon, but it spawns behind the pigeon

Discussion in 'Troubleshooting: Bugs, Questions and Support' started by 147689, Feb 16, 2016.

  1. 147689

    147689
    Expand Collapse

    Joined:
    Jun 10, 2014
    Messages:
    378
    Ok, I have modified the pigeon and added a tow hitch, but the tow hitch spawn lookin like its not attached to the pigeon, and when I drive forward, the hitch stretches
    screenshot_00968.png
    screenshot_00969.png
    The files I have for the hitch to work are pigeon.jbeam and pigeon_towhitch.jbeam
    Code:
    {
    "pigeon_towhitch": {
        "information":{
            "authors":"BeamNG",
            "name":"Tow Hitch",
            "value":70,
        }
        "slotType" : "pigeon_towhitch",
        "flexbodies": [
             ["mesh", "[group]:", "nonFlexMaterials"],
             ["towhitch", ["pigeon_frame","pigeon_towhitch"],[],{"pos":{"x":0.0, "y":0.0, "z":0.0}}],
        ],
        "slots": [
            ["type", "default", "description"]
            ["trailer_small","","Small Trailer"],
        ],
        "nodes": [
             ["id", "posX", "posY", "posZ"],
             {"collision":true}
             {"frictionCoef":0.5},
             {"selfCollision":true}
             //--TOW HITCH--
             {"nodeMaterial":"|NM_METAL"},
             {"group":"pigeon_towhitch"}
             {"nodeWeight":5},
             ["tw", 0.0, 2.76, 0.58,{"magnet":"true"}],
             ["tw2", 0.0, 2.76, 0.49,{"magnet":"true"}],
             {"group":""}
        ],
    
        "ties":[
            ["id1:", "maxLen", "rate", "short", "long", "group", "maxforce"],
            ["tw", 0.75, 1, 1, 1, "pigeon_towhitch", 10000000],
        ],
    
        "beams": [
              ["id1:", "id2:"],
              {"beamPrecompression":1, "beamType":"|NORMAL", "beamLongBound":1.0, "beamShortBound":1.0},
              //--TOW HITCH--
              {"beamSpring":1344840,"beamDamp":195},
              {"beamDeform":129000,"beamStrength":890000},
              ["tw","fr19r"],
              ["tw","fr19"],
              ["tw","fr19l"],
              ["tw","fr20r"],
              ["tw","fr20"],
              ["tw","fr20l"],
    
              ["tw2","fr19r"],
              ["tw2","fr19"],
              ["tw2","fr19l"],
              ["tw2","fr20r"],
              ["tw2","fr20"],
              ["tw2","fr20l"],
    
              ["tw","tw2"],
    
        ],
        "triangles": [
                ["id1:","id2:","id3:"],
                //towhitch
                {"group":"pigeon_towhitch"},
                {"group":""},
    
        ],
    }
    }
    Would anyone know why its looking like its not attached to the pigeon and how I could fix that?
     
  2. Nadeox1

    Nadeox1
    Expand Collapse
    Spinning Cube
    BeamNG Team

    Joined:
    Aug 5, 2012
    Messages:
    14,685
    Because you have to adjust the offset.

    Code:
             ["towhitch", ["pigeon_frame","pigeon_towhitch"],[],{"pos":{"x":0.0, "y":0.0, "z":0.0}}],
     
  3. ThreeDTech21

    ThreeDTech21
    Expand Collapse

    Joined:
    Sep 27, 2013
    Messages:
    1,616
    also make sure the tow hitch has a location of zero and the origin must be located in the center of your 3D program.
     
  4. Nadeox1

    Nadeox1
    Expand Collapse
    Spinning Cube
    BeamNG Team

    Joined:
    Aug 5, 2012
    Messages:
    14,685
    The tow hitch is a shared mesh, so zero origin doesn't count as the author didn't not add it to the pigeon mesh files.
    That's why we got that offset thing now.
     
  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