So ive added that code into myworld and have changed actor to Ogre (which is my enemy) when i kill the enemy its not respawning, any ideas?
You do not have to change the method at all. Any actor passed to it, whether of Ogre type or not will be initially placed at a random edge point. You will need to call this method from where you remove an ogre from the world (when one is killed):