Ballz.Logic.LogicControl.RaiseMessageEvent C# (CSharp) Method

RaiseMessageEvent() protected method

protected RaiseMessageEvent ( Message msg ) : void
msg Ballz.Messages.Message
return void
        protected virtual void RaiseMessageEvent(Message msg)
        {
            Message?.Invoke(this, msg);
            if(state == GameState.MenuState)
                Ballz.The().Services.GetService<SoundControl>().StartMusic(SoundControl.MenuMusic);
            else
                Ballz.The().Services.GetService<SoundControl>().StopMusic(SoundControl.MenuMusic);
        }