public void RemoveMessage(MessagePlacement placement, int token) { switch (placement) { case MessagePlacement.Center: centerMsgQueue.Remove(token); break; case MessagePlacement.BottomLeft: bottomLeftMsgQueue.Remove(token); break; } }
public int DisplayMessage(MessagePlacement placement, string text) { int token = Random.Range(0, int.MaxValue); switch (placement) { case MessagePlacement.Center: centerMsgQueue.Add(token, new HUDMessage(text)); break; case MessagePlacement.BottomLeft: bottomLeftMsgQueue.Add(token, new HUDMessage(text)); break; } return(token); }