In the general case the optical tensor of a nematic liquid crystal consists of nine nonzero elements, which makes it difficult to calculate light propagation in a liquid-crystal cell. For a two-dimensional (2-D) problem with TM polarization and a parallel liquid-crystal orientation where the molecules are only tilted and not twisted, the full problem can be calculated by using one magnetic field component, thus reducing the problem to a scalar one. This geometry is used to simulate the self-focusing effect which can lead to the generation of spatial optical solitary waves. This self-focusing occurs due to the optical nonlinear effect of field-induced director reorientation. Due to nondiagonal elements of the optical tensor, however, it is expected that the Poynting vector will deviate from the original propagation direction. Our simulations reveal that, in this case, the deviation will not cause the loss of the soliton-like beam propagation regime, but will rather give rise to a transverse undulating behaviour.