Nope! That must be why. Ill rewrite it and test out using the
RETRIEVED listeners and let you know if that works.

On Mar 2, 3:30 pm, Fabrice3D <[email protected]> wrote:
> Do you do like this?
>
> [..]
> ResourceManager.instance.addEventListener(ResourceEvent.RESOURCE_RETRIEVED, 
> onResourceRetrieved);
> ResourceManager.instance.addEventListener(LoaderEvent.LOAD_ERROR, 
> onResourceLoadingError);
> ResourceManager.instance.addEventListener(LoaderEvent.LOAD_MAP_ERROR, 
> onResourceMapsLoadingError);
>
> ResourceManager.instance.getResource("mymd2url.md2" );
>
> }
>
> private function onResourceRetrieved(e : ResourceEvent) : void
> {
>         _mesh = Mesh(e.resource);
>         BitmapMaterial(_mesh.material).bitmapData = myDiffuseMap;
>
> Fabrice
>
> On Mar 2, 2011, at 7:53 PM, Andrew wrote:
>
> > I tried :
>
> > _meshMaterial = new BitmapMaterial(new Texture().bitmapData);
> > _mesh = Mesh(_resourceManager.getResource("assets/modelpack25/
> > generator.md2"));
> > _mesh.material = _meshMaterial;
>
> > It's still coming up white.
>
> > -Andrew
>
> > On Mar 2, 1:35 pm, Andrew <[email protected]> wrote:
> >> Hey, I have a quick questions about using MD2 Models and Applying
> >> Material.
>
> >> I noticed in the LoaderMD2Test.as that it uses the:
>
> >> var material : DefaultMaterialBase;
>
> >> material = DefaultMaterialBase(_mesh.modelMaterial);
>
> >> material.normalMap = new Norm().bitmapData;
> >> material.specularMap = new Spec().bitmapData;
> >> material.diffuseMethod = new EnvMapDiffuseMethod(_diffuseMap);
>
> >> Is the DefaultMaterialBase inheriting the skin that is used on
> >> the .MD2 model.
>
> >> I added another MD2 model and changed the skins but I'm not getting
> >> the skin to be applied.
>
> >> When I removed the normalMap, Spec, & Diffuse it's basically just a
> >> mesh with white.
>
> >> Can anyone lead me to get just the blank mesh with the default skin
> >> that is currently textured on it.
>
> >> I tried just using:
>
> >> var material : BitmapMaterial = new
> >> BitmapMaterial(Texture().bitmapData, true, false, true);
> >> material = BitmapMaterial(_mesh.material);
> >> material.normalMap = new Norm().bitmapData;
>
> >> Texture() is the class Embed associated with the regular texture. I'm
> >> sure im doing this completely wrong.
>
> >> Thanks,
> >> -Andrew

Reply via email to