Download

Portal Gun

So i made portal gun mod, i made it in such a way that if a portal created from gun the previous portal which was created earlier will destroy. its running fine in single player,however in multi player it has issue if any player creates one portal from gun and at the same time if other player creates same portal , one portal will destroy.
here are my codes.i want to make it unique for all players, how to do it

You need an ownership check in there, as well as modifying your destroy logic. You will always destroy the first one created, because you’re referencing index 0 for all actors of class.