Mudflows are catastrophic events that cause immense damage to infrastructure and life every year. Local authorities have been trying to mitigate the risk by zoning regulations as well as by building protection structures for many years. These measures have, however, in most cases been designed based on knowledge from past events. Numerical models have started emerging about 30 years ago. While a variety of depth-averaged models are available and implemented in commercial software almost no continuum models exist, that would allow the extraction of forces acting on buildings and protection structures. Moreover, no two-phase material models exist that allow the simulation of the complete process of initiation, propagation and stopping of a flow. This work attempts to fill in an important part of this gap. First, the basic components of the model are developed for free-surface flow of a single phase fluid. On this formulation we investigate a meshless method, and come to the conclusion that the main advantages of the meshless method can be obtained by using simple finite elements in conjunction with a re-meshing strategy. We show that the method retains optimal order of convergence. The two-phase model proposed subsequently formulates the equations of the flow of a two-phase mixture in a moving reference frame. The problem of updating the positions of the nodes of two phases is solved by re-creating a new mesh after each update. The nodal variables are mapped onto this new mesh by linear interpolation. The computation of volume fractions of the two phases is de-coupled from the computation of the main nodal variables, the phase velocities and the pressure. The volume fractions are computed by evaluating the change of local density of nodal masses of the phases. On a series of test problems we demonstrate the performance of the two-phase formulation. We show in particular that sedimentation of a solid phase within a mixture can be simulated and the results can be verified with an analytical solution. Finally, the impact of a mudflow on an obstacle is simulated and a time history of the force acting on the obstacle is extracted. The test problems illustrate the versatility of the method for simulating a wide variety of problems of two-phase flow.