mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2024-11-15 01:01:33 +00:00
Expose P_XYMovement to Lua.
It was so easy; it took a grand total of one compile to implement! Why wasn't this done before...
This commit is contained in:
parent
bc2f83ec05
commit
fe67781d68
1 changed files with 12 additions and 0 deletions
|
@ -913,6 +913,17 @@ static int lib_pRailThinker(lua_State *L)
|
|||
return 1;
|
||||
}
|
||||
|
||||
static int lib_pXYMovement(lua_State *L)
|
||||
{
|
||||
mobj_t *actor = *((mobj_t **)luaL_checkudata(L, 1, META_MOBJ));
|
||||
NOHUD
|
||||
INLEVEL
|
||||
if (!actor)
|
||||
return LUA_ErrInvalid(L, "mobj_t");
|
||||
P_XYMovement(actor);
|
||||
return 0;
|
||||
}
|
||||
|
||||
// P_USER
|
||||
////////////
|
||||
|
||||
|
@ -3271,6 +3282,7 @@ static luaL_Reg lib[] = {
|
|||
{"P_CanRunOnWater",lib_pCanRunOnWater},
|
||||
{"P_MaceRotate",lib_pMaceRotate},
|
||||
{"P_RailThinker",lib_pRailThinker},
|
||||
{"P_XYMovement",lib_pXYMovement},
|
||||
|
||||
// p_user
|
||||
{"P_GetPlayerHeight",lib_pGetPlayerHeight},
|
||||
|
|
Loading…
Reference in a new issue