Add right click edit grid interaction
This commit is contained in:
parent
2fbabc785e
commit
548fb99c8b
9 changed files with 65 additions and 28 deletions
|
@ -2,9 +2,10 @@ import * as gui from './index.mjs';
|
|||
import GuiButton from './button.mjs';
|
||||
|
||||
export default class GuiItemButton extends GuiButton {
|
||||
constructor(module, onclick, x, y, w = 50, h = 50) {
|
||||
constructor(tile, onclick, x, y, w = 50, h = 50) {
|
||||
super(null, onclick, x, y, w, h);
|
||||
this.image = module === null ? null : module.currentImage;
|
||||
this.module = tile.module;
|
||||
this.image = tile.image;
|
||||
this.type = 'itemButton';
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue