1 decade ago by BBreitenbach
What do I need to do to get the level editor to recognize a class I extended from ig.Class ?
I created a custom class to write text using the canvas context, and I put it as a speaking text object to draw within my character entity.
ERROR: Uncaught TypeError: undefined is not a function
EXAMPLE:
*******
******
I then use a write method during the draw to display it and all the lines if it is multiline.
It just looks like the level editor can't see the class, but I am not sure what else to do. I am fairly amateur, so I just copied another class that looked similar in nature, and everything was working great until I went to edit my level.
I created a custom class to write text using the canvas context, and I put it as a speaking text object to draw within my character entity.
ERROR: Uncaught TypeError: undefined is not a function
EXAMPLE:
*******
speakCanvasText: new ig.Canvastext({ fontcolor: "white", text: "Test Text", width: 30, location: { x: 25, y: 25 } }),
******
I then use a write method during the draw to display it and all the lines if it is multiline.
It just looks like the level editor can't see the class, but I am not sure what else to do. I am fairly amateur, so I just copied another class that looked similar in nature, and everything was working great until I went to edit my level.