|
var spawnOffset = exit == null ? WVec.Zero : exit.Info.SpawnOffset; |
|
slave.Trait<IPositionable>().SetVisualPosition(slave, centerPosition + spawnOffset); |
|
|
|
var location = self.World.Map.CellContaining(centerPosition + spawnOffset); |
The most worthwhile refactor sounds like to turn SetSpawnedFacing into a function returning this value because it already does the syncing between the spawner and the spawnee.
Related: OpenRA/ra2#719 (which shares this block).