wrong direction. Reason was an incorrect rotation in the projection
code. Instead of fixing it, I let the kart fall a little bit, so the
code is now correct, much easier to understand, and the bounce after
a reset fits the game imho.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@12852 178a84e3-b1eb-0310-8ba1-8eac791a3b58
different rigid bodies in bullet. Some layout fixes, removed unused or unnecessary
functions and constructors.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@12779 178a84e3-b1eb-0310-8ba1-8eac791a3b58
I have to confirm with bullet developers why this only happens sometimes.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@12513 178a84e3-b1eb-0310-8ba1-8eac791a3b58
to their initial position (which was used to reset stones
falling down a volcano) must now be explicitely requested
(reset-when-below). This fixes the prpblem of floating
barrels in sandtrack.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@12461 178a84e3-b1eb-0310-8ba1-8eac791a3b58
'too different' from the normal of the triangle with the
normal of the triangle for interpolating the normals which
are used by the physics.
This should make 'smooth normals' more useful for tracks where
track and (say) a wall are connected, resulting in incorrect
normals for the physics.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@11989 178a84e3-b1eb-0310-8ba1-8eac791a3b58
(just acting along the normal). This solves some of the odd
behaviour with the previous implementation if the kart is
off track. The new way is now the default, but the 'push
towards driveline' can be set in stk_config.xml.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@11923 178a84e3-b1eb-0310-8ba1-8eac791a3b58
example to lighthouse track. Note atm both needs to be set: smooth-normals
in the track.xml file and in stk_config.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@11217 178a84e3-b1eb-0310-8ba1-8eac791a3b58
reported p to 4 times by bullet), a crash would be caused when the rigid body is
removed (meaning that all further collisions with this body are invalid/removed,
while the loop in physics still tries to access them).
This patches removes bodies only when it is safe to do so, i.e. after the collision
loop. Removals done in the loop will be stored and executed later.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@11198 178a84e3-b1eb-0310-8ba1-8eac791a3b58
using a fixed object in the kart, now each animation
(rescue, explosion, canon) has its own object and
implementation using a common interface. This
simplifies AbstractKartInterface, and makes it
easier to add new functionailty.
Instead of using: kart->rescue(...), or kart->explode(...)
you use new ExplosionAnimation(kart, ...) etc. Memory
handling is done by the object (and abstract kart).
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@11070 178a84e3-b1eb-0310-8ba1-8eac791a3b58
location) support. ATM only linear interpolation of the position
is used (i.e. no rotation).
2) To be consistend renamed 'forceRescue' to 'rescue',
'handleExplosion' to 'explode' (and added shootTo for the canon).
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@11021 178a84e3-b1eb-0310-8ba1-8eac791a3b58
de-couple kart implementation and its interface. This
significantly reduces compile time when changing kart.hpp,
but is at this stage still work in progress.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@10997 178a84e3-b1eb-0310-8ba1-8eac791a3b58
were for bonuses were changed, but are still not considered to be tweaked).
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@10963 178a84e3-b1eb-0310-8ba1-8eac791a3b58
GhostKart was not called, since it was called during when
the contrsuctor of Kart was executed (at this time the
GhostKart vtable wasn't set up, so Kart::createPhysics)
was called - which resulted in a memory leak since all
physics parts of the kart were actually allocated (just
not used). To fix this, karts are not constructed in two
phases: first a constructor, followed by a call to init
(during which virtual function can be used).
Fixed several bugs were physics data for a GhostKart
were accessed.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@10947 178a84e3-b1eb-0310-8ba1-8eac791a3b58
it possible to intentionally push karts off track by crashing into them
sideways. This is experimental ;)
Also renamed some variables to better describe what they are.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@10830 178a84e3-b1eb-0310-8ba1-8eac791a3b58
collisions. Made collisions more bouncy than before (but I am
still tuning).
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@10827 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2) Split Kart::crashed into two public functions for collisions with
kart and collisions with track, and one private function with code
common to both collisions.
3) Removed #include of attachment.hpp from kart.hpp to reduce compile
time.
Sorry for not splitting this up into three parts.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@10775 178a84e3-b1eb-0310-8ba1-8eac791a3b58
to the interpolated world transform. This fixes a bug for
rotations that are applied only once, since kart.cpp would
use the interpolated world transform, which is otherwise
not updated till the next time step, resulting in a jump
of the kart rotation.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@10706 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2) Renamed setTimedImpulse to setTimedCentralImpulse.
New skidding is still disabled.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@10652 178a84e3-b1eb-0310-8ba1-8eac791a3b58