package crash
{
function wheeledVehicle::onCollision(%this,%obj)
{
%vehicleclient = %this.client;
%vel = %this.getVelocity();
%speed = getWord(%vel,0) + getWord(%vel,1) + getWord(%vel,2);
if(%speed > 10)
{
%this.damage(%vehicleclient,%this.getWorldBoxCenter(),%this.getDatablock().maxdamage);
}
}
};
activatepackage(crash);
getVelocity returns a three part vector. Just add the three parts together. Maybe average the three parts.