The deployment of model-predictive control (MPC) for a building’s energy system is a challenging task due to high computational and modeling costs. In this study, an MPC controller based on EnergyPlus and MATLAB is developed, and its performance is evaluated through a case study in terms of energy savings, optimality of solutions, and computational time. The MPC determines the optimal setpoint trajectories of supply air temperature and chilled water temperature in a simulated office building. A comparison between MPC and rule-based control (RBC) strategies for three test days showed that the MPC achieved 49.7% daily peak load reduction and 17.6% building energy savings, which were doubled compared to RBC. The MPC optimization problem was solved multiple times using the Ant Colony Optimization (ACO) algorithm with different starting points. Results showed that ACO consistently delivered high-quality optimized control sequences, yielding less than a 1% difference in energy savings between the worst and best solutions across all three test days. Moreover, the computational time for solving the MPC problem and obtaining nearly optimal control sequences for a three-hour prediction horizon was observed to be around 22 min. Notably, reasonably good solutions were attained within 15 min by the ACO algorithm.