public void SetPortal(int portalId, bool visible, bool enabled, bool minimapVisible, bool arg5) { if (Field.State.Portals.IsEmpty) { return; } IFieldObject <Portal> portal = Field.State.Portals.Values.First(p => p.Value.Id == portalId); if (portal == null) { return; } portal.Value.Update(visible, enabled, minimapVisible); Field.BroadcastPacket(FieldPacket.UpdatePortal(portal)); }