mirror of
https://github.com/APercy/automobiles_pck
synced 2025-11-05 22:53:05 +01:00
set pos changed
This commit is contained in:
parent
1c5c870321
commit
881db52904
@ -490,6 +490,7 @@ minetest.register_entity("automobiles_buggy:buggy", {
|
||||
end
|
||||
|
||||
local curr_pos = self.object:get_pos()
|
||||
self.object:move_to(curr_pos)
|
||||
if is_attached then --and self.driver_name == self.owner then
|
||||
local impact = automobiles_lib.get_hipotenuse_value(velocity, self.lastvelocity)
|
||||
if impact > 1 then
|
||||
@ -612,7 +613,6 @@ minetest.register_entity("automobiles_buggy:buggy", {
|
||||
accel.y = -automobiles_lib.gravity
|
||||
|
||||
if stop ~= true then
|
||||
self.object:move_to(curr_pos)
|
||||
self.object:set_velocity(velocity)
|
||||
self.object:set_acceleration(accel)
|
||||
else
|
||||
|
||||
@ -497,6 +497,7 @@ minetest.register_entity("automobiles_coupe:coupe", {
|
||||
end
|
||||
|
||||
local curr_pos = self.object:get_pos()
|
||||
self.object:move_to(curr_pos)
|
||||
if is_attached then --and self.driver_name == self.owner then
|
||||
local impact = automobiles_lib.get_hipotenuse_value(velocity, self.lastvelocity)
|
||||
if impact > 1 then
|
||||
@ -640,7 +641,6 @@ minetest.register_entity("automobiles_coupe:coupe", {
|
||||
accel.y = -automobiles_lib.gravity
|
||||
|
||||
if stop ~= true then
|
||||
self.object:move_to(curr_pos)
|
||||
self.object:set_velocity(velocity)
|
||||
self.object:set_acceleration(accel)
|
||||
else
|
||||
|
||||
@ -463,6 +463,7 @@ minetest.register_entity("automobiles_roadster:roadster", {
|
||||
end
|
||||
|
||||
local curr_pos = self.object:get_pos()
|
||||
self.object:move_to(curr_pos)
|
||||
if is_attached then --and self.driver_name == self.owner then
|
||||
local impact = automobiles_lib.get_hipotenuse_value(velocity, self.lastvelocity)
|
||||
if impact > 1 then
|
||||
@ -585,7 +586,6 @@ minetest.register_entity("automobiles_roadster:roadster", {
|
||||
accel.y = -automobiles_lib.gravity
|
||||
|
||||
if stop ~= true then
|
||||
self.object:move_to(curr_pos)
|
||||
self.object:set_velocity(velocity)
|
||||
self.object:set_acceleration(accel)
|
||||
else
|
||||
|
||||
Loading…
Reference in New Issue
Block a user