0

Website opening animation using javascript....

Hey guys I need a source code to make my own opening website animation.( is more like an alert animation that shows when you open the website .) I want it to be a fork rolling a spaghetti. Pls guys I really need help with that....đŸ˜„đŸ˜„đŸ˜„đŸ˜„

19th Sep 2019, 7:13 PM
clint🩒
clint🩒 - avatar
2 Answers
+ 1
That would be kind of hard to do on sololearn because you don't have the ability to download/make sprites on this editor. I would recommend downloading a different editor with the ability to make sprites. Then, you could use the code: Sprite.prototype.draw = function (ctx, x ,y) { if (this.angle == 0) { ctx.drawImage(this.img, this.x, this.y, this.width, this.height, x, y, this.width, this.height); } else { ctx.save(); ctx.translate(x, y); ctx.rotate(this.angle * this._TORADIANS); ctx.drawImage(this.img, this.x, this.y, this.width, this.height, x, y, this.width, this.height); ctx.restore(); } }
8th Oct 2019, 6:11 PM
Liam Rahlfs - Games, Examples, & Projects
Liam Rahlfs - Games, Examples, & Projects - avatar
0
Thanks man
8th Oct 2019, 6:42 PM
clint🩒
clint🩒 - avatar