enabled OK button on GuiCombat screen when choosing defenders/attackers. iOS solution only currently. To implement in Android, we need to create a mask/invisible button above the OK button coordinates and add a listener to activate when a user touches the appropriate area. Not ideal, but it works for now.
TODO: translate functionality into core of engine.
This commit is contained in:
@@ -144,6 +144,16 @@
|
||||
[self.glViewController toggleKeyboardWithState: initialState];
|
||||
}
|
||||
|
||||
- (void) handleWEngineCommand:(NSString *) command
|
||||
withUIParameters: (CGFloat) x
|
||||
yCoordinate: (CGFloat) y
|
||||
width: (CGFloat) width
|
||||
height: (CGFloat) height
|
||||
{
|
||||
CGRect uiFrame = CGRectMake(x, y, width, height);
|
||||
if ( [command isEqualToString: @"okbuttoncreated"] )
|
||||
[glViewController addOkButtonListener: uiFrame];
|
||||
}
|
||||
|
||||
- (void)handleWEngineCommand:(NSString *) command withParameter: (NSString *) parameter
|
||||
{
|
||||
@@ -165,6 +175,10 @@
|
||||
{
|
||||
[self initializeKeyboard: parameter];
|
||||
}
|
||||
else if ([command isEqualToString: @"combatGuiEndDamage"])
|
||||
{
|
||||
[glViewController removeOkButtonListener];
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user