Skip to content

Commit

Permalink
Fixed wren's TIC.btn(_)
Browse files Browse the repository at this point in the history
Updated bitmask from 0xf to 0x1f to support 3rd and 4th gamepads
  • Loading branch information
txgruppi committed Mar 4, 2021
1 parent 69079e0 commit 48c3dad
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/api/wren.c
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,7 @@ static void wren_btn(WrenVM* vm)
}
else if (top == 2)
{
s32 index = getWrenNumber(vm, 1) & 0xf;
s32 index = getWrenNumber(vm, 1) & 0x1f;
wrenSetSlotBool(vm, 0, core->memory.ram.input.gamepads.data & (1 << index));
}

Expand Down

0 comments on commit 48c3dad

Please sign in to comment.