Guest User

Untitled

a guest
Feb 18th, 2018
48
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.71 KB | None | 0 0
  1. public void Show(string _title , string _message, bool _showYesButton, bool _showNoButton, bool _showCancelButton) {
  2. this.gameObject.SetActive (true);
  3. Title.text = _title;
  4. Message.text = _message;
  5. btnYes.SetActive (_showYesButton);
  6. btnNo.SetActive (_showNoButton);
  7. btnCancel.SetActive (_showCancelButton);
  8.  
  9.  
  10. }
  11.  
  12. MyMessageBoxScript _script = MyMsgBoxGameObject.GetComponent<MyMessageBoxScript >();
  13. _script.Show("Hey..","Are you sure you want to overwrite this save ?",true,true,false);
  14.  
  15. buttonPressed = _script.Show("Hey.:", "Are you sure...");
  16.  
  17. _script.Show(CallBackFunction; "Hey..","Are you sure you want to overwrite this save ?",true,true,false);
  18.  
  19. void CallBackFunction () {
  20. ...
  21. }
Add Comment
Please, Sign In to add comment