added custom fonts to Text() object
This commit is contained in:
parent
70f1226c48
commit
03692b426e
1 changed files with 2 additions and 2 deletions
|
@ -7,9 +7,9 @@ function Text(x,y,text,font,color,incrementFunction){
|
|||
this.text = text;
|
||||
this.alive=1;
|
||||
this.draw = function(){
|
||||
if(this.alive>0){
|
||||
if (this.alive>0) {
|
||||
ctx.globalAlpha = this.opacity;
|
||||
renderText((this.x + gdx), (this.y + gdy),36,this.color,this.text);
|
||||
renderText((this.x + gdx), (this.y + gdy),36,this.color,this.text,this.font);
|
||||
ctx.globalAlpha =1;
|
||||
incrementFunction(this);
|
||||
return true;
|
||||
|
|
Loading…
Reference in a new issue