removed also g_update_rectangle_energy