Due to its characteristics of carrying passengers and vehicles, the passenger-roller ship needs to consider the safety performance and economic cost comprehensively. In this paper, ballast water is introduced as an indicator of economic cost when constructing the integer planning model of electric vehicle pre-allocation scheme for passenger-roller ships. At the same time, vehicle safety constraints and ship safety constraints are combined as safety performance indicators. The integrated cabin utilization rate and lateral overturning moment are modeled to balance the cabin loading capacity and stability. Combined with the pheromone attenuation mechanism of ant colony algorithm, the optimal computational solution of the loading scheme is carried out to maximize the benefits and minimize the risks of EV transportation on both passenger and ro-ro ships. The results show that the ant colony algorithm can achieve stable and fast convergence and the objective function value is smaller than the comparison algorithm when setting the information heuristic factor α, the expectation heuristic factor β, and the number of ants to 1.2, 2.0, and 65, respectively. In the 15 different scenarios of EV allocation schemes for passenger and rollon/roll-off vessels based on the ant colony algorithm, the ship area utilization rate is more than 95%, and at the same time, the standard deviation is less than 0.005.