I've added a awd(1) parser to Broomstick,
Prefab 1.0 exports these and they are displayed in latest version in svn
Prefab 2.0 will hold as3 4.0 compatible, once I can go cruise speed on this 
baby. For now, Away is prio #1.

Your loop doesn't makes much sens to me at first sight. What is it suposed to 
do? 100 duplicates?
you should consider loop and clone instead. Here you seam to asign same 
instance over and over and addChild it.

Its probably me, but what is the issue with awd exactly, is it not showing up 
if you addChild e.resource?
or is it the duplicate part?

Fabrice

On Apr 26, 2011, at 6:43 PM, seacloud9 wrote:

> for(var i:int = 0; i <= 100; i++){
>        fishArr.push(new ObjectContainer3D());
>        fishArr[i] = ObjectContainer3D(e.resource);
>        fishArr[i].name = 'fish'+i;
>        fishArr[i].z = randRange(-600,600);
>        fishArr[i].x = randRange(-600,600);
>        fishArr[i].y = randRange(-600,600);
>        trace(fishArr[i]);
>        _view.scene.addChild(fishArr[i] as ObjectContainer3D);
> }
> 
> any help on this matter would be greatly appreciated thanks in
> advance.
> 
> On Apr 26, 7:33 am, seacloud9 <[email protected]> wrote:
>> Help on this issue would be greatly appreciated.
>> 
>> Prefab currently does not appear able to export to Broomstick has
>> anyone else been able to export a model as a class is as3 for
>> broomstick?  I am of course using models where the textures are a
>> power of 2.
>> 
>> Currently when it loops it is populating all AWD1 with a random x,y,z
>> although when it comes to the last item in the loop it overrides all
>> the others that were previously pushed to the array.  I can see this
>> information in the debug output.
>> 
>> On Apr 25, 10:24 pm,seacloud9<[email protected]> wrote:
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>>> Side note I was originally trying to use fish.clone() where I had
>>> assigned the fish to an ObjectContainer3D above the loop and then
>>> convert it to an ObjectContainer3D when I add it to the scene because
>>> fish.clone() returns an Object3D.
>>>      _view.scene.addChild(fishArr[i] as ObjectContainer3D);
>> 
>>> On Apr 25, 10:00 pm,seacloud9<[email protected]> wrote:
>> 
>>>> RandRange is a custom function for a random number for a range and I
>>>> have used it for a long time so I know this is not the issue.
>> 
>>>> On Apr 25, 7:23 pm,seacloud9<[email protected]> wrote:
>> 
>>>>> I created an AWD1 file with prefab.  I can import it in and display
>>>>> one my problem comes in when I try to loop through and create more or
>>>>> clone.
>> 
>>>>> The code below will not create a new ObjectContainer3D for some reason
>>>>> and I am sorry my error might be something simple.  When I loop
>>>>> through this function and push and push a model into the array and
>>>>> then display it in the view all items in the array have the same x,y,z
>>>>> and name.  So I am kind of perplexed.  For some reason right now I
>>>>> also noticed with prefab I am having issues with export to as3 class
>>>>> file.  I have done these things before and I am trying to redo an old
>>>>> demo I made with away3d.
>> 
>>>>> I have also tried to clone the model but this has not been successful
>>>>> either.
>> 
>>>>> for(var i:int = 0; i <= 100; i++){
>>>>>         fishArr.push(new ObjectContainer3D());
>>>>>         fishArr[i] = ObjectContainer3D(e.resource);
>>>>>         fishArr[i].name = 'fish'+i;
>>>>>         fishArr[i].z = randRange(-600,600);
>>>>>         fishArr[i].x = randRange(-600,600);
>>>>>         fishArr[i].y = randRange(-600,600);
>>>>>         trace(fishArr[i]);
>>>>>         _view.scene.addChild(fishArr[i] as ObjectContainer3D);
>> 
>>>>> }
>> 
>>>>> Original Demo might donkey punch an old 
>>>>> processor.http://i-create.org/actionscript/TweetTank/
>> 
>>>>> I also tried to export a wavefront .obj but I ran into the same issue
>>>>> that is discussed 
>>>>> here:http://ultravisual.co.uk/blog/2011/03/22/more-molehill-away3d-fun/
>> 
>>>>> Any help on this endeavor would be greatly appreciated.  Thank you in
>>>>> advance.

Reply via email to