From 8cb40e903e4f353a91a663441445d474a55544ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johnny=20Bergstr=C3=B6m?= Date: Thu, 29 Apr 2004 09:42:00 +0000 Subject: [PATCH] added entity_is_on_ground --- plugins/include/engine_stocks.inc | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/plugins/include/engine_stocks.inc b/plugins/include/engine_stocks.inc index 5c8bb4a2..d33c5246 100755 --- a/plugins/include/engine_stocks.inc +++ b/plugins/include/engine_stocks.inc @@ -132,7 +132,7 @@ stock make_deathmsg(killer,victim,headshot,weapon[]) write_byte( killer ) write_byte( victim ) write_byte( headshot ) - write_string( weapon ) + write_string( weapon[] ) message_end() return 1 @@ -205,12 +205,7 @@ stock get_entity_visibility(entity) { return (entity_get_int(entity, EV_INT_effects) & EF_NODRAW) } -stock set_user_velocity(entity, Float:vec[3]) -{ - return entity_set_vector(entity, EV_SZ_velocity, vec) -} - -stock get_user_velocity(entity, Flaot:vec[3]) -{ - return entity_get_vector(entity, EV_SZ_velocity, vec) +/* Returns true if entity is on ground, else false. */ +stock entity_is_on_ground(entity) { + return entity_get_int(entity, EV_INT_flags) & FL_ONGROUND } \ No newline at end of file