Created
June 11, 2018 15:00
-
-
Save Kaundur/c34dd71e991b7029805d53faf6824e62 to your computer and use it in GitHub Desktop.
Unity Simple Crosshair
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void OnGUI() | |
{ | |
const int crossHairWidth = 10; | |
const int crossHairHeight = 10; | |
GUI.Box(new Rect(Screen.width/2 - crossHairWidth/2, Screen.height/2 - crossHairHeight/2, crossHairWidth, crossHairHeight), ""); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment