forked from MoonsideGames/MoonWorks
parent
3b83eb41da
commit
681e620477
|
@ -82,6 +82,8 @@ namespace MoonWorks
|
||||||
{
|
{
|
||||||
while (accumulator >= timestep)
|
while (accumulator >= timestep)
|
||||||
{
|
{
|
||||||
|
Inputs.Mouse.Wheel = 0;
|
||||||
|
|
||||||
HandleSDLEvents();
|
HandleSDLEvents();
|
||||||
|
|
||||||
Inputs.Update();
|
Inputs.Update();
|
||||||
|
@ -112,6 +114,10 @@ namespace MoonWorks
|
||||||
case SDL.SDL_EventType.SDL_TEXTINPUT:
|
case SDL.SDL_EventType.SDL_TEXTINPUT:
|
||||||
HandleTextInput(_event);
|
HandleTextInput(_event);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case SDL.SDL_EventType.SDL_MOUSEWHEEL:
|
||||||
|
Inputs.Mouse.Wheel += _event.wheel.y;
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,6 +13,8 @@ namespace MoonWorks.Input
|
||||||
public int DeltaX { get; private set; }
|
public int DeltaX { get; private set; }
|
||||||
public int DeltaY { get; private set; }
|
public int DeltaY { get; private set; }
|
||||||
|
|
||||||
|
public int Wheel { get; internal set; }
|
||||||
|
|
||||||
private bool relativeMode;
|
private bool relativeMode;
|
||||||
public bool RelativeMode
|
public bool RelativeMode
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue