several changes here,

first, i added a timer to hide the big card after 5 secs or until a movement is registered. 

2nd, removed the advancing of phases with flick up.

3rd added a flick left to "show/hide hand"

4th, fixed an error in the logic of "getDifficulty" part of the reason optimizedhand was not working.

finally, unrefactored the checks of optimized hand, it was FAR to difficult to see what was actually happening the way it was coded.

optimizedhand is finally working again, 
toggledifficulty and optimizedhand will again trigger and greatly improve ai vs player matches
This commit is contained in:
omegablast2002@yahoo.com
2013-02-21 00:48:39 +00:00
parent 2330e6a613
commit 9a52ae28a2
7 changed files with 78 additions and 31 deletions

View File

@@ -971,8 +971,19 @@ void GameStateDuel::OnScroll(int inXVelocity, int inYVelocity)
// ignore magnitude for now, since no action requires scrolling
if (abs(inYVelocity) > 300)
{
bool flickUpwards = (inYVelocity < 0);
mEngine->HoldKey_NoRepeat(flickUpwards ? JGE_BTN_PREV : JGE_BTN_SEC);
/*bool flickUpwards = (inYVelocity < 0);*/
mEngine->HoldKey_NoRepeat(/*flickUpwards ? JGE_BTN_PREV : */JGE_BTN_SEC);
//removing the activation of "left trigger" or "advance phase" because on high end tablets this gesture
//is picked up by simply looking at the cards in your hand if the resolution of tablet exceed 1800 X ANY.
}
if (abs(inXVelocity) > 300)
{
bool flickLeft = (inYVelocity > 0);
if(flickLeft)
{
JButton trigger = (options[Options::REVERSETRIGGERS].number ? JGE_BTN_PREV : JGE_BTN_NEXT);
mEngine->HoldKey_NoRepeat(trigger);
}
}
}