Posts RSS Comments RSS Digg Technorati Blinklist Furl reddit 105 Posts and 7 Comments till now
This wordpress theme is downloaded from wordpress themes website.

Archive for October, 2016 (2016/10)

Gamepad Controls

I implemented gamepad controls which I tested on Windows desktop with an Xbox 360 Controller (USB).  Using this same control system, it’s also possible to control the game entirely with a keyboard (though I think keyboard + mouse is better).  This is in addition to the touch screen only interface (which I’m testing on an Android tablet).

The UMG menu uses D-Pad, A for select, B for back (also keyboard arrow keys, Enter / Space, Esc / Backspace).  The game view uses the following (each also has corresponding keyboard shortcuts).  Left Stick free camera (WASD), Left Stick button toggle view (V).  Right Stick rotate/zoom, Right Stick button toggle zoom vs. tilt (QE rotate, home/end zoom, PgUp/PgDn tilt).  D-Pad Move or Attack adjacent (arrow keys).  LT toggles card zoom (C).  RT toggles combobox (B).  LL RR cycles Attack targets (tab, shift+tab), A selects target (enter, space).  B for back (Esc).  Mouse wheel zoom.  Mouse or Touch can click UMG or highlight actors (to select move or action target).

Other controls I plan to add later…  More finger touch screen controls such as pinch zoom, two finger rotate, tilt, pan.  Fluid mouse control (maybe right-click) for rotate/tilt.  In the long-term I plan to implement a VR interface.

Below is a video where I showcase using an XBox 360 controller to control the game.  Most of the functionality is the same as (keyboard + mouse) but with gamepad controls.

Some changes that stand out…  Navigate UMG menus with D-Pad.  Character menu is updated (also bigger UMG widgets for touch screen) (work in progress).  In addition to using D-Pad to select orthogonal move/action, you can also select any move/action with (left bumper, right bumper) then A.

Image result for xbox 360 controllerButton layout of a wireless Xbox 360 controller

Search for Doors (dynamic textures)


In HeroQuest, a hero can do one action per turn (move then action or action then move).  The choices for an action are – attack, spell, search for traps, search for secret doors, search for treasure, and disarm trap.  Three of the six actions are “search”.  If you’re in a room, search checks the current room.  If you’re in a corridor, search checks corridor line of sight.  This is similar to visibility in terms of ranged attacks and spells with the anti-door camping rule ( link ).  One key difference is that you can’t search when a monster is visible.


Search treasure only applies to rooms (there’s no treasure in corridors), and each hero can only search a room for treasure one time.  So one quirk of HeroQuest is that the players have to keep track of which heroes searched which rooms.  It also makes sense to remember which areas you searched for traps and secret doors – because otherwise you may end up forgetting to search an area or you may end up searching the same area repeatedly.

For the video game version of HeroQuest, it’s useful to allow the player to see where they’ve searched. 


I decided to convey this information using a dynamic texture, so the implementation is similar to what I did for fog of war (see my previous post).

For my board material’s pixels, we start from the board texture, multiply by fog of war, then add search highlighting.

I added a UMG combobox in the bottom-right corner of the screen.  This let’s you select which search type you want highlighted on the board – none, trap, door, or treasure.

In the screen shots below, you can see the first room’s squares highlight in cyan when “door” is selected.  You can also see the secret doors revealed (I added lots of secret doors for testing).

I tested it on Windows desktop and on an Android tablet (Fire HD 6) with a relatively small screen.  The UMG combobox is a reasonable size even on tiny Android tablet.

No videos this post – just screen shots:

image image image

image image image