complete letter G
This commit is contained in:
@@ -102,39 +102,9 @@ import Layout from "../../layouts/Layout.astro";
|
||||
this.load.image('sun', '/assets/sun.png');
|
||||
this.load.image('bgMobile', '/assets/bgMobile.png');
|
||||
this.load.image('canvasStand', '/assets/stand2.png');
|
||||
// this.load.image('customCursor', '/assets/pencile.png');
|
||||
// this.load.image('eye', '/assets/pencile.png');
|
||||
this.load.image('customCursor', '/assets/pencile.png');
|
||||
|
||||
|
||||
}
|
||||
|
||||
function create() {
|
||||
this.input.setDefaultCursor('none');
|
||||
|
||||
// Set the initial position of the custom cursor
|
||||
const initialCursorX = customWidth / 2 - 8;
|
||||
const initialCursorY = customHeight / 2 - 100;
|
||||
|
||||
// Create a sprite for the custom cursor at the initial position
|
||||
customCursor = this.add.sprite(initialCursorX, initialCursorY, 'customCursor');
|
||||
// customCursor.setOrigin(0.5, 0.5);
|
||||
customCursor.setOrigin(0.0, 0.98).setDepth(2.1).setScale(0.18);
|
||||
|
||||
// Set the custom cursor to follow the pointer
|
||||
this.input.on('pointermove', (pointer) => {
|
||||
customCursor.x = pointer.x;
|
||||
customCursor.y = pointer.y;
|
||||
});
|
||||
|
||||
// Hide cursor on click
|
||||
this.input.on('pointerdown', () => {
|
||||
customCursor.setVisible(true);
|
||||
});
|
||||
|
||||
this.input.on('pointerup', () => {
|
||||
customCursor.setVisible(true);
|
||||
});
|
||||
this.add.image(customWidth / 2 * 1.6 - 0.5, 50, 'topLogo');
|
||||
this.add.text(customWidth / 10, 20, "Letter : A", { font: '700 40px quicksand', fill: '#05b3a4', });
|
||||
const cloud = this.add.tileSprite(customWidth / 2, customHeight / 2 - cloudHeight, customWidth, cloudeSize, 'cloud').setAlpha(0.9);
|
||||
@@ -376,9 +346,6 @@ import Layout from "../../layouts/Layout.astro";
|
||||
}
|
||||
|
||||
function update() {
|
||||
this.input.x = 100; // X coordinate
|
||||
this.input.y = 200;
|
||||
|
||||
}
|
||||
|
||||
</script>
|
||||
Reference in New Issue
Block a user