var Snake = (function () { const INITIAL_TAIL = 4; var fixedTail = true; var intervalID; var tileCount = 10; var gridSize = 400/tileCount; const INITIAL_PLAYER = { x: Math.floor(tileCount / 2), y: Math.floor(tileCount / 2) }; var velocity = { x:0, y:0 }; var player = { x: INITIAL_PLAYER.x, y: INITIAL_PLAYER.y }; var walls = false; var fruit = { x:1, y:1 }; var trail = []; var tail = INITIAL_TAIL; var reward = 0; var points = 0; var pointsMax = 0; var ActionEnum = { 'none':0, 'up':1, 'down':2, 'left':3, 'right':4 }; Object.freeze(ActionEnum); var lastAction = ActionEnum.none; function setup () { canv = document.getElementById('gc'); ctx = canv.getContext('2d'); game.reset(); } var game = { reset: function () { ctx.fillStyle = 'grey'; ctx.fillRect(0, 0, canv.width, canv.height); tail = INITIAL_TAIL; points = 0; velocity.x =...
Posts
- Get link
- X
- Other Apps
My Website Welcome to My Website Facebook .About All in one This a simple page aboute our service. Which one is made by me. Our Services 1.Photo and video editing 2.Website coding 3.Graphic Design Contact Us:01715176755 Name: Email: Message: Send Message © 2023 My Website. All rights reserved. Students Possition Possition Name Total Marks 1. Jinan 988 2. Mohsin ...
My first writing
- Get link
- X
- Other Apps
Application for Increasing Common room facilities The Principal Shahjalal Jamia Islamia Schol and College Sub: Application for Increase Common Room Facilities Sir, We, the students of your college in Class 12, would like to bring to your attention the growing number of students in our college. As the student population increases, we are facing a shortage of facilities in our common room. Currently, we do not have enough resources to play games such as carrom, chess, and other recreational activities. Therefore, we kindly request you to consider increasing the facilities in our common room. Yours faithfully, On behalf of the students of SJISC Nur Alam Roll: 104 Class: XII