I have a problem. I am trying to create a monkey target that will work with stage3D. for those that don't know Stage3D is a flash hardware accelerated graphics Api. I am implementing hardware 2D accelerated graphics to replace the slow flash graphics. I got pretty much everything in place and working. its' very limited as it just works with sprites. A little demo to show that it's working:
it should work pretty good on handheld devices although I don't know. I haven't tested it.
it's working but not usable as a normal monkey target. what is happening is that the graphics need to be requested and then when the graphics is available a trigger and a function is called. The problem is the Oncreate is done processing before the graphics object is available. so I can not create any graphics while on the onCreate. I have to do a check while on Update and see if the graphics object is ready and then start to load all of the assets and object creation. which is not ideal. I am new to flash programming so I don't know if there is a way I can get the graphics object to be created and available before the On create is called?
anybody has any idea how I can resolve that?
I am thinking that maybe I can have a loop check until the graphics object is loaded and then continue to OnCreate. But I don't know.