Copy link to clipboard
Copied
Any help? My boxMC is inside of my background(WorldMC) but I get an error saying
TypeError: Error #1007: Instantiation attempted on a non-constructor.
at MainGameFile/gameLoop()
This is where the code is giving me trouble:
//-----------------------------------
// -----Box Spawning------------
//------------------------------------
//only spawn a box if there are less tan 100 already on screen
{
// Make a new instance of the box class
var bx = new WorldMC.boxMC();
// add the ship to the display list
addChild(bx);
//position and rotate the Box
WorldMC.bx.x = Math.random() * stage.stageWidth;
WorldMC.bx.y = Math.random() * stage.stageHeight;
WorldMC.bx.rotation = 40;
}
Copy link to clipboard
Copied
Please post the name of the program you use so a Moderator may move this message
A program would be Photoshop or Dreamweaver or Muse or Premiere Pro or ???
Copy link to clipboard
Copied
This is in Adobe Flash Professional CS 5.5
Copy link to clipboard
Copied
This has been answered from a different post that i have made.
Copy link to clipboard
Copied
found this maybe it applies
flash - AS3 Error #1007: Instantiation attempted on a non-constructor - Stack Overflow