Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags

TIC-80

Fantasy computer for making, playing and sharing tiny games. · By Nesbox

Can I turn off the mouse cursor?

A topic by Altrix Studios created Oct 19, 2022 Views: 383 Replies: 1
Viewing posts 1 to 2

Currently, my game supports keyboard inputs only. I want to support gamepad inputs as well, but as I understand it, the only way to do that is to allow all three input types. That causes the mouse cursor to appear during gameplay, and I don't want it to, because my game doesn't support mouse inputs and I don't want players to get confused about why mouse clicks aren't doing anything.

I've tried using the solution suggested here but it doesn't work for me, the cursor is still visible. Is there actually a way of turning it off, or will I have to stick to just keyboard input? Or is there a way to turn on keyboard and gamepad input but not mouse input?

(1 edit)

So I kept Googling and found a slightly hacky solution to this. Just set:

poke(0x7FC3F,1,1)

This turns on some special mouse capture mode that disables the cursor. That should do the trick for me, and for anyone else who gets stuck on this problem.