Index: src/map/script.c =================================================================== --- src/map/script.c (revision 14995) +++ src/map/script.c (working copy) @@ -7578,6 +7578,25 @@ return 0; } +/// Checks if the player is sitting +/// +/// is_sitting() -> +BUILDIN_FUNC(is_sitting) +{ + TBL_PC* sd; + + sd = script_rid2sd(st); + if (sd == NULL) + return 0;// no player attached, report source + + if (pc_issit(sd)) + script_pushint(st, 1); + else + script_pushint(st, 0); + + return 0; +} + /// Sets the save point of the player. /// /// save "",, @@ -15062,6 +15081,7 @@ BUILDIN_DEF(checkfalcon,""), BUILDIN_DEF(setriding,"?"), BUILDIN_DEF(checkriding,""), + BUILDIN_DEF(is_sitting,""), BUILDIN_DEF2(savepoint,"save","sii"), BUILDIN_DEF(savepoint,"sii"), BUILDIN_DEF(gettimetick,"i"),