fix left click lost after right click bug

This commit is contained in:
evanpelle
2024-09-20 19:50:35 -07:00
parent d8cb5b1847
commit df99457867
2 changed files with 1 additions and 8 deletions
+1 -1
View File
@@ -127,9 +127,9 @@
* notification for alliance request DONE 9/20/2024
* comfirm alliance DONE 9/20/2024
* create event box DONE 9/20/2024
* BUG: left click lost after right click DONE 9/20/2024
* make fake humans easier
* first place has crown
* alliance has icon
* BUG: FakeHuman don't be enemy if don't share border
* BUG: when send boat only captures one pixel
* store cookies
-7
View File
@@ -39,8 +39,6 @@ export class DragEvent implements GameEvent {
export class InputHandler {
private contextMenuActive = false
private lastPointerX: number = 0;
private lastPointerY: number = 0;
@@ -67,10 +65,6 @@ export class InputHandler {
}
private onPointerDown(event: PointerEvent) {
if (this.contextMenuActive) {
this.contextMenuActive = false
return
}
if (event.button > 0) {
return
@@ -142,7 +136,6 @@ export class InputHandler {
private onRightClick(event: MouseEvent) {
event.preventDefault()
this.contextMenuActive = true
this.eventBus.emit(new RightClickEvent(event.clientX, event.clientY))
}