This is the spawning handler code from a sample of one of NienerWiener's template code for which I based the companion on.
Code: Select all
Class FriendDoomGuySpawnHandler : EventHandler
{
Override Void PlayerEntered(PlayerEvent e)
{
Let pl = players[e.PlayerNumber].mo;
let dke = pl.Spawn("NNR_FriendEY",pl.pos,ALLOW_REPLACE);
If(dke)
{
dke.Master = pl;
dke.Translation = pl.Translation;
dke.A_FaceMaster();
}
}
}Anyone know how to make the spawning position offset a little away from the player position? This is to prevent the player screen from being needlessly obscured, which can be annoying and intrusive for players on more hectic maps or wads where immediate reactions are necessary. Any help would be greatly appreciated. Thanks in advance!