ha, that looks very funny. But well done for getting it working!
If the train moves slow enough, it should stay on track
Use the braking volumes to slow the vehicle down as on that racetrack.
obj = 0;
function onInit(objID)
sky.lprint("LUA: Script Active!");
obj = objID;
end
function onUpdate( timeDelta )
w,x,y,z = camera.getWorldOrientation();
rotateQuat = newType.vec4(quat.rotateOrientation(180, 0, 1, 0, w,x,y,z));
entity.setWorldOrientation(obj, rotateQuat.w, rotateQuat.x, rotateQuat.y, rotateQuat.z);
end
Users browsing this forum: No registered users and 9 guests