Hinge Constraint Stiffness

I wanted to change Hinge Constraints stiffness and so I found this topic:

Could anyone tell me please, how do I use this script, because I dont know python and how to use it in Blender

Welcome to BA!

I wouldn’t normally answer this because I know nothing much about your specific problem, nor about scripting specifically in Blender, nor Blender’s game engine, and that link is 7 years old; I have no idea how much the game engine has changed since. But you’ve waited for 11 hours, and that’s not the best welcome. :wink:

I can at least tell you how to use a Python script in Blender.

Blender has a Scripting Workspace all the way on the upper right of the header, with a Viewport, a Console and a Text Editor. You can save the script to a file and then open it from the editor. Or you can press “New”, and copy-paste the script. After that press the Run button (right-facing arrow up on the right in the header of the editor).

And then you’ll get a “Python Script failed” message and are told to look in the Console. Which is where alas I have to leave you. I can’t even tell you whether this is a valid script as is, or whether it needs some extra initialization. Sorry!

I’m hoping somebody else can help, like @josephhansen when he wakes up. This might also be better placed in the Game Engine section or the Coding one. He’ll fix that if it needs to be.

1 Like

Thank you for reply!
I am making tracked vehicle and I need to make tracks to be more stretched. They are made with Hinge Constraint in chain one by one, but now they are too loose.
I would like to send you .blend file here, but it says “New users are not allowed to attach files”
So I uploaded it on Google Drive: https://drive.google.com/file/d/1wSocOqMKZDtUpgOm2pehvz6cR2N9QM4d/view?usp=sharing

I just woke up- relatively speaking- still not quite seeing in a straight line yet but I think that #coding:python-support was a good call :slight_smile: beyond that, I have no idea what’s going on here, sadly

Hello.


You can do it yourself, it’s one of the perks of having Regular status. :slightly_smiling_face:


I’m hesitant to say it, but I think this is actually a #game-engine:game-engine-support-and-discussion question, looking at the blend in UPBGE 0.3, but I’ll leave it as is until the OP says otherwise.


@artem_krasnov you can use Object Constraints via Blender UI instead of using BGE API code if you’d prefer. The former should work at runtime.

Here is an alternate working vehicle demo too. Make sure you download the script as well as the blend. :slightly_smiling_face:

Note: To download just those two files, you can use this link. Or you can alternatively download the files individually via GitHub’s web interface.

1 Like

Thanks for your reply, but its not quite what I was asking.
I am making just an animation, rather than the game. And my vehicle is tracked, rather than on wheels.

Thats what I am talking about, I cant change stiffness of my Hinge Constraints with Blender UI, so I wanted to ask here how do I make it. I have seen that its possible (in this video on youtube and it is said Rigid Body 100% ), but dont know how to make it. You can see that tracks in my .blend file are too loose here