(java script) how to make mouse invisible.

iv noticed alot of games make the mouse go invisible and stick to the middle of the screen (no matter where you move it). Is it possible to do this in unity?

Screen.showCursor

Screen.lockCursor