mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2024-11-29 07:32:02 +00:00
Expose P_TouchSpecialThing
This commit is contained in:
parent
d6d424f102
commit
39869b4492
1 changed files with 14 additions and 0 deletions
|
@ -2195,6 +2195,19 @@ static int lib_pDoMatchSuper(lua_State *L)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int lib_pTouchSpecialThing(lua_State *L)
|
||||
{
|
||||
mobj_t *special = *((mobj_t **)luaL_checkudata(L, 1, META_MOBJ));
|
||||
mobj_t *toucher = *((mobj_t **)luaL_checkudata(L, 2, META_MOBJ));
|
||||
boolean heightcheck = lua_optboolean(L, 3);
|
||||
NOHUD
|
||||
INLEVEL
|
||||
if (!special || !toucher)
|
||||
return LUA_ErrInvalid(L, "mobj_t");
|
||||
P_TouchSpecialThing(special, toucher, heightcheck);
|
||||
return 0;
|
||||
}
|
||||
|
||||
// P_SPEC
|
||||
////////////
|
||||
|
||||
|
@ -4133,6 +4146,7 @@ static luaL_Reg lib[] = {
|
|||
{"P_FloorzAtPos",lib_pFloorzAtPos},
|
||||
{"P_CeilingzAtPos",lib_pCeilingzAtPos},
|
||||
{"P_DoSpring",lib_pDoSpring},
|
||||
{"P_TouchSpecialThing",lib_pTouchSpecialThing},
|
||||
{"P_TryCameraMove", lib_pTryCameraMove},
|
||||
{"P_TeleportCameraMove", lib_pTeleportCameraMove},
|
||||
|
||||
|
|
Loading…
Reference in a new issue