Use consistent semantics for gate_in_robot

Fixes an ancient bug where the wrong object would be mapped to a remote
object number if the gate_in_robot call failed.
Use objptridx_t in create_gated_robot
Return objptridx_t from create_gated_robot
Use objptridx_t in boss_spew_robot