Error when attempting to give an entity an image.
See original GitHub issueHere’s my code:
window.onload = function() {
var $h = $(window).height();
var $w = $(window).width();
var $nw = ($h-$h/10) / 3 * 4
var $nh = $nw / 4 * 3
Crafty.init($nw,$nh, document.getElementById('game'));
Crafty.e('Floor, 2D, Canvas, Color')
.attr({x: 0, y: 250, w: 250, h: 10})
.color('green');
var queen = Crafty.e('2D, Canvas, Image, Fourway')
.attr({x: 0, y: 0, w: 50, h: 50})
.image("assets/queen.png", "no-repeat")
.fourway(200)
};
Here’s the error: 'CanvasRenderingContext2D.webkitImageSmoothingEnabled' is deprecated. Please use 'CanvasRenderingContext2D.imageSmoothingEnabled' instead.
Issue Analytics
- State:
- Created 7 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
Catchable Fatal Error: Argument 1 passed to \Entity\Image ...
I've got a similar error message. I solved it by adding <form method="post" {{ form_enctype(form) }}> to my form tag.
Read more >Liquid error : Show Account/contact Entity Image o...
I'm trying to show account or contact entity image on portals but when I try to run I receive an error message :...
Read more >Error when I upload an image with entity browser media - Drupal
TypeError: Argument 1 passed to Drupal\lightning_media\MediaHelper::getSourceField() must be an instance of Drupal\media\MediaInterface, null ...
Read more >Fix common Google Ads Editor errors
This error is caused by attempting to exceed some type of entity limit in Google Ads. For example, ... Contact the Google Ads...
Read more >Error Message: There are errors below. Hover over each for ...
This error message can occur because of: Layers - Layers make editing images easier, but they have a larger size that prevents uploads....
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
This shouldn’t cause any functional problem. It’s done for older browser compatibility, I believe.
Maybe
"assets/queen.png"
fails to load? Try preloading them withCrafty.load
.