Skip to content

Commit

Permalink
experiment 2123
Browse files Browse the repository at this point in the history
  • Loading branch information
APercy committed Apr 21, 2022
1 parent 6b41081 commit 87c0031
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions supercub_utilities.lua
Expand Up @@ -49,8 +49,8 @@ function supercub.attach(self, player, instructor_mode)
--player:set_physics_override({gravity = 0})
-- make the driver sit
minetest.after(0.3, function()
player = minetest.get_player_by_name(name)
if player then
--minetest.chat_send_all("okay")
player_api.set_animation(player, "sit")
--apply_physics_override(player, {speed=0,gravity=0,jump=0})
end
Expand Down Expand Up @@ -557,7 +557,9 @@ function supercub.flightstep(self)
self._last_accell = new_accel
self.object:move_to(curr_pos)
--self.object:set_velocity(velocity)
self.object:set_acceleration(self.object:get_acceleration())
if player then
supercub.attach(self, player, self._instruction_mode)
end
mobkit.set_acceleration(self.object, new_accel)
else
if stop == true then
Expand Down

0 comments on commit 87c0031

Please sign in to comment.