From 39751891f49afb07d57fadd3002655b498698e31 Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Mon, 3 Jul 2017 22:47:27 +0100 Subject: ubOde: dont do avatar step climb on small true spheres. lets play simple football --- OpenSim/Region/PhysicsModules/ubOde/ODECharacter.cs | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'OpenSim/Region') diff --git a/OpenSim/Region/PhysicsModules/ubOde/ODECharacter.cs b/OpenSim/Region/PhysicsModules/ubOde/ODECharacter.cs index 6016530..3c4675c 100644 --- a/OpenSim/Region/PhysicsModules/ubOde/ODECharacter.cs +++ b/OpenSim/Region/PhysicsModules/ubOde/ODECharacter.cs @@ -944,6 +944,12 @@ namespace OpenSim.Region.PhysicsModule.ubOde return true; } + if (gtype == d.GeomClassID.SphereClass) + { + if(d.GeomSphereGetRadius(other) < 0.5) + return true; + } + if (offset.Z > 0 || contact.normal.Z > 0.35f) { if (offset.Z <= 0) @@ -980,12 +986,12 @@ namespace OpenSim.Region.PhysicsModule.ubOde offset.Normalize(); float tdp = contact.depth; - float t = contact.normal.Z * contact.normal.Z; + float t = offset.X; t = Math.Abs(t); if(t > 1e-6) { tdp /= t; - tdp *= offset.Z * offset.Z; + tdp *= contact.normal.X; } else tdp *= 10; -- cgit v1.1