- Home /
Question by
TrivialRoo · Aug 26, 2014 at 11:24 PM ·
guibuttonfunctionparametersvoid
Button is unable to grab functions with two parameters?
Hello. For my project I wanted to simplify the job of using the new GUI Buttons, so I am using this function:
public void assignMenu(int menuNum, bool menuEnabled) {
buildMenu[menuNum] = menuEnabled;
}
But the GUI Button cannot assign an event to this function. Is it because it cannot do it if I set 2 parameters? What would be the best way to allow the button to choose a number/element from the array and assign it a bool?
Comment
Your answer
Follow this Question
Related Questions
Create GUI based on an array 2 Answers
Attach a function to different buttons and pass different parameters 1 Answer
How to set GUI button "1" to "0"? 1 Answer
Whether or not to use Unity GUI functions 1 Answer
UI Button multiple parameters 6 Answers