User prompt
Fix Bug: 'ReferenceError: Can't find variable: viewfinder' in this line: 'if (Math.sqrt(Math.pow(viewfinder.x - ghost.x, 2) + Math.pow(viewfinder.y - ghost.y, 2)) <= viewfinder.width / 2) {' Line Number: 36
User prompt
Viewfinder and camera move together. Ghosts must enter the space of the viewfinder and not just the camera to be captured.
User prompt
Create viewfinder asset
User prompt
When ghost is captured, destroy ghost.
User prompt
Remove camera flash for the camera catching ghost in viewfinder
User prompt
2. **Tap to Snap**: In the `Game` class, set up an event listener for the 'down' event on the stage. When the player taps the screen, this event listener should be triggered. Screen flash occurs when player taps the screen when ghost is in camera frame
User prompt
Implement suggestions above
User prompt
Only one ghost on screen at a time.
User prompt
Increase speed of ghosts by 150%
User prompt
Only one ghost on screen at a time.
User prompt
Reduce ghost spawn rate by 50%
User prompt
Fix Bug: 'TypeError: undefined is not an object (evaluating 'LK.gui.bottomCenter.addChild')' in this line: 'LK.gui.bottomCenter.addChild(photo);' Line Number: 63
User prompt
Fix Bug: 'TypeError: undefined is not an object (evaluating 'LK.gui.bottomCenter.addChild')' in this line: 'LK.gui.bottomCenter.addChild(photo);' Line Number: 63
User prompt
When camera catches ghost, screen flashes white for 0.3 secs. Destroy ghost and display photograph graphic. Photo graphic displays on bottom of screen.
User prompt
Ghosts scroll randomly around screen. Ghosts pass from one side of the screen to the other either up, down, left or right, but never stop on screen
User prompt
Fix Bug: 'TypeError: undefined is not a constructor (evaluating 'new Graphics()')' in this line: 'var cameraOutline = new Graphics();' Line Number: 17
User prompt
Outline outside of camera icon with color #25ff9b
User prompt
The level 1 background is an abandoned house
User prompt
First person view. Player controls camera movement. Ghosts fly on and off screen at random. Player must catch ghosts in the camera frame circle.
Initial prompt
Spooky Ghost SNAP! 📸
===================================================================
--- original.js
+++ change.js
@@ -31,9 +31,9 @@
return true;
}
return false;
};
- self.snap = function (ghost) {
+ self.snap = function (ghost, viewfinder) {
if (Math.sqrt(Math.pow(viewfinder.x - ghost.x, 2) + Math.pow(viewfinder.y - ghost.y, 2)) <= viewfinder.width / 2) {
return true;
}
return false;
@@ -74,9 +74,9 @@
for (var i = 0; i < ghosts.length; i++) {
ghosts[i].move();
}
for (var i = 0; i < ghosts.length; i++) {
- if (camera.snap(ghosts[i])) {
+ if (camera.snap(ghosts[i], viewfinder)) {
LK.effects.flashScreen(0xffffff, 300);
var photo = self.createAsset('photo', 'Photograph Graphic', 0.5, 0.5);
photo.x = 2048 / 2;
photo.y = 2732 - photo.height / 2;
Frame of Camera viewfinder, inside viewfinder view, realistic camera, frame Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Creepy abandoned house, interior Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Subtle orb of green light, floating, realistic, glowing ghost orb Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Polaroid photo of ghost, Japanese ghost Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Floating ghost head Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Ghost camera game win screen. YOU WIN! Horror game asset Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Pointed finger, realistic hand, Tap!, game asset Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.