Mobile device localization is still an actual research problem. In many cases, we have a lack in all the positions but there is enough data to calculate position with the use of the multilateration. Our research proves that the order in which we calculate the positions with multilateration matters. We consider a network with mobile and stationary devices which are represented in the form of a graph with calculated distances as edges. Our contribution to solving the problem of indoor localization is true-range multilateration with a node sorting approach (TriSort). We based our research on an existing problem of smartphone localization in an enclosed indoor space using the BLE connection. The proposed algorithm is evaluated in a simulator. The distances are calculated using the BLE signal level estimation. We use the Genetic Algorithm commonly used for such problems to assess our TriSort approach. We compare the results of both methods according to obtained errors and their processing times, showing that the proposed TriSort method provides a minimal decrease in accuracy compared to global optimization (below 14%), with almost four orders of magnitudes lower complexity.