Accessibility: One Button (L3) alternates to act as two (Cross or Circle)

Useful for some games, such as Unchartered 4 to give a single button the facility to dive or ascend in the diving stages for example.
Version1.00
AuthorSpecialEffect
Publish DateWed, 18 May 2016 - 12:42
Last UpdateWed, 18 May 2016 - 12:42
Downloads28
RATE


1

0

Code: Select all
// L3 ACTS AS CROSS OR CIRCLE (ALTERNATES)
 
// TOGGLES FOR EXPLORATION
define DeadZoneLeftStick = 20;
define DeadZoneRightStick = 20;
 
int ButtonSwapper = FALSE; // FALSE = move right; TRUE = move left;
 
main {
 
           // Look L3 = CROSS or CIRCLE
          if (event_press(PS3_L3)) {ButtonSwapper = !ButtonSwapper;} // Toggles between TRUE/FALSE states
          if (get_val(PS3_L3) && ButtonSwapper) {set_val(PS4_CROSS,100);set_val(PS3_L3,0);} // CROSS
          if (get_val(PS3_L3) && !ButtonSwapper) {set_val(PS4_CIRCLE,100);set_val(PS3_L3,0);} // CIRCLE
          }