Restrict the analog control to it's own drawing area

This commit is contained in:
pjgat09 2013-05-10 23:25:31 +00:00
parent 6849f72baf
commit e25d58eecb
1 changed files with 4 additions and 1 deletions

View File

@ -48,7 +48,10 @@ namespace BizHawk.MultiClient
private int GFXToReal(int val)
{
return (val * 2) - 128;
int ret = (val * 2) - 128;
if (ret > 127) ret = 127;
if (ret < -128) ret = -128;
return ret;
}
private void AnalogControlPanel_Paint(object sender, PaintEventArgs e)