Added Overlay try-catch
This commit is contained in:
parent
756924f1b7
commit
515301deda
|
@ -403,9 +403,14 @@ public class Clicker implements Runnable{
|
|||
|
||||
public void toggleOverlay() {
|
||||
if(ov == null) {
|
||||
ov = new Overlay();
|
||||
ov.set(playout, cardslots, end, battle, arena_switch);
|
||||
ov.init();
|
||||
try {
|
||||
ov = new Overlay();
|
||||
ov.set(playout, cardslots, end, battle, arena_switch);
|
||||
ov.init();
|
||||
} catch(Exception e) {
|
||||
System.out.println("Catched Exception, while inflateing Overlay: ");
|
||||
e.printStackTrace();
|
||||
}
|
||||
} else {
|
||||
ov.close();
|
||||
ov = null;
|
||||
|
|
Loading…
Reference in New Issue