- Home /
GUI style causing problem
GUIUtility.RotateAroundPivot(angle, new Vector2(Screen.width - (71 Screen.width / 480) + ((61 Screen.width / 480)/2), 5 + ((61 * Screen.height / 320)/2)));
if (GUI.Button(new Rect((Screen.width - (71 Screen.width / 480)), 5, 61 Screen.width / 480, 61 * Screen.height / 320), pcont))
Here pcont is a GUIContent having Texture. I am trying to rotate image continuously. This code is working perfectly. So the image rotates 360 degrees. But when I add "new GUIStyle()" in GUI.Button, it changes pivot point and I am getting bizarre result.
Comment
Your answer
Follow this Question
Related Questions
Change Button GUIStyle on Click 1 Answer
Create 3D GUI Button? 2 Answers
Semitransparent GUI Buttons 3 Answers
Change GUI.Box color when click button 1 Answer
Unable to find style in skin repaint 1 Answer