fixed raycasting with the gargoyle