TheTermos / mobkit

Entity API for Minetest
MIT License
27 stars 12 forks source link

Invalid float vector dimension range 'y' (expected -2.14748e+06 < y < 2.14748e+06 got 4.2413e+09). #38

Open Bastrabun opened 2 years ago

Bastrabun commented 2 years ago
2022-02-12 07:51:28: WARNING[Server]: collisionMoveSimple: Loop count exceeded, aborting to avoid infiniite loop
2022-02-12 07:51:45: ERROR[Main]: ServerError: AsyncErr: ServerThread::run Lua: Runtime error from mod 'petz' in callback luaentity_Step(): Invalid float vector dimension range 'y' (expected -2.14748e+06 < y < 2.14748e+06 got 4.2413e+09).
2022-02-12 07:51:45: ERROR[Main]: stack traceback:
2022-02-12 07:51:45: ERROR[Main]:   [C]: in function 'set_velocity'
2022-02-12 07:51:45: ERROR[Main]:   /home/mtlive1/.minetest/mods/mobkit/init.lua:702: in function 'physics'
2022-02-12 07:51:45: ERROR[Main]:   /home/mtlive1/.minetest/mods/mobkit/init.lua:843: in function 'stepfunc'
2022-02-12 07:51:45: ERROR[Main]:   /home/mtlive1/.minetest/mods/petz/petz/petz/pony_mobkit.lua:121: in function 'func'
2022-02-12 07:51:45: ERROR[Main]:   ...inetest_live/bin/../builtin/profiler/instrumentation.lua:106: in function <...inetest_live/bin/../builtin/profiler/instrumentation.lua:100>

The issue arose when someone put a petz pony on a trampoline, resulting in the pony reaching faster than light velocity :D:D:D:D

Even though the pony was removed eventually, I captured its y speed:

2022-02-12 09:15:35: ERROR[Server]: [mobkit] #1476 vnew={
    y = 34507632640,
    x = 0,
    z = 0
}

Could you please defend in the function against crazy horses?

I initially reported to petz: https://github.com/runsy/petz/issues/93

For my reference 1476

ghost commented 2 years ago
2022-02-12 07:51:28: WARNING[Server]: collisionMoveSimple: Loop count exceeded, aborting to avoid infiniite loop
2022-02-12 07:51:45: ERROR[Main]: ServerError: AsyncErr: ServerThread::run Lua: Runtime error from mod 'petz' in callback luaentity_Step(): Invalid float vector dimension range 'y' (expected -2.14748e+06 < y < 2.14748e+06 got 4.2413e+09).
2022-02-12 07:51:45: ERROR[Main]: stack traceback:
2022-02-12 07:51:45: ERROR[Main]:     [C]: in function 'set_velocity'
2022-02-12 07:51:45: ERROR[Main]:     /home/mtlive1/.minetest/mods/mobkit/init.lua:702: in function 'physics'
2022-02-12 07:51:45: ERROR[Main]:     /home/mtlive1/.minetest/mods/mobkit/init.lua:843: in function 'stepfunc'
2022-02-12 07:51:45: ERROR[Main]:     /home/mtlive1/.minetest/mods/petz/petz/petz/pony_mobkit.lua:121: in function 'func'
2022-02-12 07:51:45: ERROR[Main]:     ...inetest_live/bin/../builtin/profiler/instrumentation.lua:106: in function <...inetest_live/bin/../builtin/profiler/instrumentation.lua:100>

The issue arose when someone put a petz pony on a trampoline, resulting in the pony reaching faster than light velocity :D:D:D:D

Even though the pony was removed eventually, I captured its y speed:

2022-02-12 09:15:35: ERROR[Server]: [mobkit] #1476 vnew={
  y = 34507632640,
  x = 0,
  z = 0
}

Could you please defend in the function against crazy horses?

I initially reported to petz: runsy/petz#93

For my reference 1476

Put a pony on a Trampoline is literal?! The isssue then on the trampoline mod that pushes the entity velocity to the infinite. The trampoline is only for players. Not mobkit nor petz fault.

TheTermos commented 2 years ago

Mobkit is by design agnostic about other mods and games, if another mod decides to implement warp speed it should be allowed to.

Actually I'm a little bit worried about 'Loop count exceeded'. Collisions broken again? I'll try to find the time to check.