Search found 2 matches

by box
Thu Jan 11, 2018 1:10 pm
Forum: Java
Topic: Linear acceleration
Replies: 1
Views: 43

Re: Linear acceleration

Hm, I found this code inside or "Island" class: if (translationx * translationx + translationy * translationy > Settings.maxTranslationSquared) { double ratio = Settings.maxTranslation / MathUtils.sqrt(translationx * translationx + translationy * translationy); v.x *= ratio; v.y *= ratio; ...
by box
Thu Jan 11, 2018 7:42 am
Forum: Java
Topic: Linear acceleration
Replies: 1
Views: 43

Linear acceleration

Each iteration I call method "body.applyForce(new Vec2(10, 0), new Vec(0, 0));" I expect that after each iteration body linear speed will be increased to appropriate value, and position will be look like step 1: speed is (0, 0), position is (0, 0) step 2: speed is (1, 0), position is (1, 0...

Go to advanced search