Can I convert AS3 to haXe automagically ?

classic Classic list List threaded Threaded
12 messages Options
Reply | Threaded
Open this post in threaded view
|

Can I convert AS3 to haXe automagically ?

Blue Sans douze
Hello list !

I was using in as3 a small library called TweenMax, which is really
usefull to make tween using mxmlc. I've seen FEffects for haXe, which
is nice too, but less powerfull (more code for less things). I've
tried to port TweenMax to haXe, and failed, because it's really
painfull : it has many files, and some complex syntax.

Is there a way I can convert it to haXe or use it in haXe (I've heard
about swc files, but I don't know what they can be usefull to) ?

Thanks for reading, and sorry for my english.

--
Blue112.
Free frutiparc.

--
haXe - an open source web programming language
http://haxe.org
Reply | Threaded
Open this post in threaded view
|

Re: Can I convert AS3 to haXe automagically ?

Philipp Klose-2
You can try to use TweenerHX (which is available via haxelib) as an
alternative tweening engine or try to use TweenMax as a swf-lib/swc like
described here:
http://haxe.org/doc/flash/aswingas3
and here:
http://haxe.org/doc/flash/usingas3classes

Blue Sans douze schrieb:

> Hello list !
>
> I was using in as3 a small library called TweenMax, which is really
> usefull to make tween using mxmlc. I've seen FEffects for haXe, which
> is nice too, but less powerfull (more code for less things). I've
> tried to port TweenMax to haXe, and failed, because it's really
> painfull : it has many files, and some complex syntax.
>
> Is there a way I can convert it to haXe or use it in haXe (I've heard
> about swc files, but I don't know what they can be usefull to) ?
>
> Thanks for reading, and sorry for my english.
>
> --
> Blue112.
> Free frutiparc.
>
>  

--
haXe - an open source web programming language
http://haxe.org
Reply | Threaded
Open this post in threaded view
|

Re: Can I convert AS3 to haXe automagically ?

Nicolas Cannasse
In reply to this post by Blue Sans douze
Blue Sans douze a écrit :

> Hello list !
>
> I was using in as3 a small library called TweenMax, which is really
> usefull to make tween using mxmlc. I've seen FEffects for haXe, which
> is nice too, but less powerfull (more code for less things). I've
> tried to port TweenMax to haXe, and failed, because it's really
> painfull : it has many files, and some complex syntax.
>
> Is there a way I can convert it to haXe or use it in haXe (I've heard
> about swc files, but I don't know what they can be usefull to) ?
>
> Thanks for reading, and sorry for my english.

There's http://github.com/geekrelief/as3tohaxe/tree/master

Nicolas

--
haXe - an open source web programming language
http://haxe.org
Reply | Threaded
Open this post in threaded view
|

Re: Can I convert AS3 to haXe automagically ?

Blue Sans douze
Thanks for that fasts answers !

I'll try all of your solutions.

haXe powered.

--
Blue112.
Free frutiparc.

2009/8/9 Nicolas Cannasse <[hidden email]>:

> Blue Sans douze a écrit :
>>
>> Hello list !
>>
>> I was using in as3 a small library called TweenMax, which is really
>> usefull to make tween using mxmlc. I've seen FEffects for haXe, which
>> is nice too, but less powerfull (more code for less things). I've
>> tried to port TweenMax to haXe, and failed, because it's really
>> painfull : it has many files, and some complex syntax.
>>
>> Is there a way I can convert it to haXe or use it in haXe (I've heard
>> about swc files, but I don't know what they can be usefull to) ?
>>
>> Thanks for reading, and sorry for my english.
>
> There's http://github.com/geekrelief/as3tohaxe/tree/master
>
> Nicolas
>
> --
> haXe - an open source web programming language
> http://haxe.org
>

--
haXe - an open source web programming language
http://haxe.org
Reply | Threaded
Open this post in threaded view
|

Re: Can I convert AS3 to haXe automagically ?

Blue Sans douze
Hello again !

After fighting a long with as3tohaxe, I've finally give up.
So, I've tried make a swf lib with TweenMax, which was successful and
works really well.

There's still a problem : In my haXe project, I'm using some assets
compiled with swfmill (fonts and graphics). When I try to set two
swf-lib, haXe compiler explains me that I can't include two swf-lib,
but doesn't give me an answer.
How can I do to make that work ?

Thanks.

--
Blue112
Free frutiparc.

2009/8/9 Blue Sans douze <[hidden email]>:

> Thanks for that fasts answers !
>
> I'll try all of your solutions.
>
> haXe powered.
>
> --
> Blue112.
> Free frutiparc.
>
> 2009/8/9 Nicolas Cannasse <[hidden email]>:
>> Blue Sans douze a écrit :
>>>
>>> Hello list !
>>>
>>> I was using in as3 a small library called TweenMax, which is really
>>> usefull to make tween using mxmlc. I've seen FEffects for haXe, which
>>> is nice too, but less powerfull (more code for less things). I've
>>> tried to port TweenMax to haXe, and failed, because it's really
>>> painfull : it has many files, and some complex syntax.
>>>
>>> Is there a way I can convert it to haXe or use it in haXe (I've heard
>>> about swc files, but I don't know what they can be usefull to) ?
>>>
>>> Thanks for reading, and sorry for my english.
>>
>> There's http://github.com/geekrelief/as3tohaxe/tree/master
>>
>> Nicolas
>>
>> --
>> haXe - an open source web programming language
>> http://haxe.org
>>
>

--
haXe - an open source web programming language
http://haxe.org
Reply | Threaded
Open this post in threaded view
|

Re: Can I convert AS3 to haXe automagically ?

Laurent Auneau
After fighting a long with as3tohaxe, I've finally give up.

Sounds familiar.

So, I've tried make a swf lib with TweenMax, which was successful and
works really well.

There's still a problem : In my haXe project, I'm using some assets
compiled with swfmill (fonts and graphics). When I try to set two
swf-lib, haXe compiler explains me that I can't include two swf-lib,
but doesn't give me an answer.
How can I do to make that work ?

I asked this twice here, and never got a ready to use answer.
The stuff that was supposed to work is to use SWFMill to embed both your swf in one.
It looks like it works, but it never really did for me (final swf got bigger, but couldn't access functions embedded)
I even got in a fight with mxmlc.

IMHO, haXe is really painful when it comes to use extern not-developped-in-haXe libraries.
What you experienced with as3tohaxe is only the beginning.

L.


--
haXe - an open source web programming language
http://haxe.org
Reply | Threaded
Open this post in threaded view
|

Re: Can I convert AS3 to haXe automagically ?

Blue Sans douze
I've tried to use swfmill as you said, but it doesn't works.

I've tried to load my lib swf with a Loader object, but I can't access
to method i've load (even with Security.allowDomain into the loaded
swf...)

So there's no way to do what I want ? Would be really sad.

2009/8/9 Laurent Auneau <[hidden email]>:

>> After fighting a long with as3tohaxe, I've finally give up.
>
> Sounds familiar.
>
>> So, I've tried make a swf lib with TweenMax, which was successful and
>> works really well.
>>
>> There's still a problem : In my haXe project, I'm using some assets
>> compiled with swfmill (fonts and graphics). When I try to set two
>> swf-lib, haXe compiler explains me that I can't include two swf-lib,
>> but doesn't give me an answer.
>> How can I do to make that work ?
>
> I asked this twice here, and never got a ready to use answer.
> The stuff that was supposed to work is to use SWFMill to embed both your swf
> in one.
> It looks like it works, but it never really did for me (final swf got
> bigger, but couldn't access functions embedded)
> I even got in a fight with mxmlc.
>
> IMHO, haXe is really painful when it comes to use extern
> not-developped-in-haXe libraries.
> What you experienced with as3tohaxe is only the beginning.
>
> L.
>
>
> --
> haXe - an open source web programming language
> http://haxe.org
>

--
haXe - an open source web programming language
http://haxe.org
Reply | Threaded
Open this post in threaded view
|

Re: Can I convert AS3 to haXe automagically ?

Heinz Hölzer-2
In reply to this post by Blue Sans douze
I've just compiled a windows version of as3tohaxe.

you can get it here:

http://rapidshare.com/files/265541217/as3tohaxe.exe.html

Blue Sans douze schrieb:

> Hello again !
>
> After fighting a long with as3tohaxe, I've finally give up.
> So, I've tried make a swf lib with TweenMax, which was successful and
> works really well.
>
> There's still a problem : In my haXe project, I'm using some assets
> compiled with swfmill (fonts and graphics). When I try to set two
> swf-lib, haXe compiler explains me that I can't include two swf-lib,
> but doesn't give me an answer.
> How can I do to make that work ?
>
> Thanks.
>
> --
> Blue112
> Free frutiparc.
>
> 2009/8/9 Blue Sans douze <[hidden email]>:
>  
>> Thanks for that fasts answers !
>>
>> I'll try all of your solutions.
>>
>> haXe powered.
>>
>> --
>> Blue112.
>> Free frutiparc.
>>
>> 2009/8/9 Nicolas Cannasse <[hidden email]>:
>>    
>>> Blue Sans douze a écrit :
>>>      
>>>> Hello list !
>>>>
>>>> I was using in as3 a small library called TweenMax, which is really
>>>> usefull to make tween using mxmlc. I've seen FEffects for haXe, which
>>>> is nice too, but less powerfull (more code for less things). I've
>>>> tried to port TweenMax to haXe, and failed, because it's really
>>>> painfull : it has many files, and some complex syntax.
>>>>
>>>> Is there a way I can convert it to haXe or use it in haXe (I've heard
>>>> about swc files, but I don't know what they can be usefull to) ?
>>>>
>>>> Thanks for reading, and sorry for my english.
>>>>        
>>> There's http://github.com/geekrelief/as3tohaxe/tree/master
>>>
>>> Nicolas
>>>
>>> --
>>> haXe - an open source web programming language
>>> http://haxe.org
>>>
>>>      
>
>  


--
haXe - an open source web programming language
http://haxe.org
Reply | Threaded
Open this post in threaded view
|

Re: Can I convert AS3 to haXe automagically ?

Baluta Cristian
i'm using external swfs with fonts and some movieclips, when they are too large to embed in the main app. you need something like this to get something from there:

if (e.target.applicationDomain.hasDefinition ( key )) {
var def = e.target.applicationDomain.getDefinition ( key );
var C :Class<Dynamic> = cast (def, Class<Dynamic>);trace(C);
var mc = Type.createInstance (C, []);
}

e - is the event of the loaded swf. it works for swfs made from flash, don't know about swfmill.

2009/8/9 Heinz Hölzer <[hidden email]>
I've just compiled a windows version of as3tohaxe.

you can get it here:

http://rapidshare.com/files/265541217/as3tohaxe.exe.html

Blue Sans douze schrieb:

Hello again !

After fighting a long with as3tohaxe, I've finally give up.
So, I've tried make a swf lib with TweenMax, which was successful and
works really well.

There's still a problem : In my haXe project, I'm using some assets
compiled with swfmill (fonts and graphics). When I try to set two
swf-lib, haXe compiler explains me that I can't include two swf-lib,
but doesn't give me an answer.
How can I do to make that work ?

Thanks.

--
Blue112
Free frutiparc.

2009/8/9 Blue Sans douze <[hidden email]>:
 
Thanks for that fasts answers !

I'll try all of your solutions.

haXe powered.

--
Blue112.
Free frutiparc.

2009/8/9 Nicolas Cannasse <[hidden email]>:
   
Blue Sans douze a écrit :
     
Hello list !

I was using in as3 a small library called TweenMax, which is really
usefull to make tween using mxmlc. I've seen FEffects for haXe, which
is nice too, but less powerfull (more code for less things). I've
tried to port TweenMax to haXe, and failed, because it's really
painfull : it has many files, and some complex syntax.

Is there a way I can convert it to haXe or use it in haXe (I've heard
about swc files, but I don't know what they can be usefull to) ?

Thanks for reading, and sorry for my english.
       
There's http://github.com/geekrelief/as3tohaxe/tree/master

Nicolas

--
haXe - an open source web programming language
http://haxe.org

     

 


--
haXe - an open source web programming language
http://haxe.org



--
Băluță Cristian
http://ralcr.com
http://imagin.ro

--
haXe - an open source web programming language
http://haxe.org
Reply | Threaded
Open this post in threaded view
|

Re: Can I convert AS3 to haXe automagically ?

Blue Sans douze
@Heinz : Thanks, but I'm on linux, and I successfully compiled it, but it just doesn't work as well (it produce bugfull hx files).

@Batula : Is there a way to use that method to load a code library, as TweenMax is ? I don't have to include my medias (fonts and bitmap) with that code, it would be painful.

Thanks.


2009/8/9 Baluta Cristian <[hidden email]>:
> i'm using external swfs with fonts and some movieclips, when they are too
> large to embed in the main app. you need something like this to get
> something from there:
> if (e.target.applicationDomain.hasDefinition ( key )) {
> var def = e.target.applicationDomain.getDefinition ( key );
> var C :Class<Dynamic> = cast (def, Class<Dynamic>);trace(C);
> var mc = Type.createInstance (C, []);
> }
> e - is the event of the loaded swf. it works for swfs made from flash, don't
> know about swfmill.
> 2009/8/9 Heinz Hölzer <[hidden email]>
>>
>> I've just compiled a windows version of as3tohaxe.
>>
>> you can get it here:
>>
>> http://rapidshare.com/files/265541217/as3tohaxe.exe.html
>>
>> Blue Sans douze schrieb:
>>>
>>> Hello again !
>>>
>>> After fighting a long with as3tohaxe, I've finally give up.
>>> So, I've tried make a swf lib with TweenMax, which was successful and
>>> works really well.
>>>
>>> There's still a problem : In my haXe project, I'm using some assets
>>> compiled with swfmill (fonts and graphics). When I try to set two
>>> swf-lib, haXe compiler explains me that I can't include two swf-lib,
>>> but doesn't give me an answer.
>>> How can I do to make that work ?
>>>
>>> Thanks.
>>>
>>> --
>>> Blue112
>>> Free frutiparc.
>>>
>>> 2009/8/9 Blue Sans douze <[hidden email]>:
>>>  
>>>>
>>>> Thanks for that fasts answers !
>>>>
>>>> I'll try all of your solutions.
>>>>
>>>> haXe powered.
>>>>
>>>> --
>>>> Blue112.
>>>> Free frutiparc.
>>>>
>>>> 2009/8/9 Nicolas Cannasse <[hidden email]>:
>>>>    
>>>>>
>>>>> Blue Sans douze a écrit :
>>>>>      
>>>>>>
>>>>>> Hello list !
>>>>>>
>>>>>> I was using in as3 a small library called TweenMax, which is really
>>>>>> usefull to make tween using mxmlc. I've seen FEffects for haXe, which
>>>>>> is nice too, but less powerfull (more code for less things). I've
>>>>>> tried to port TweenMax to haXe, and failed, because it's really
>>>>>> painfull : it has many files, and some complex syntax.
>>>>>>
>>>>>> Is there a way I can convert it to haXe or use it in haXe (I've heard
>>>>>> about swc files, but I don't know what they can be usefull to) ?
>>>>>>
>>>>>> Thanks for reading, and sorry for my english.
>>>>>>        
>>>>>
>>>>> There's http://github.com/geekrelief/as3tohaxe/tree/master
>>>>>
>>>>> Nicolas
>>>>>
>>>>> --
>>>>> haXe - an open source web programming language
>>>>> http://haxe.org
>>>>>
>>>>>      
>>>

>>>  
>>
>>
>> --
>> haXe - an open source web programming language
>> http://haxe.org
>
>
>
> --
> Băluță Cristian
> http://ralcr.com
> http://imagin.ro
>
> --
> haXe - an open source web programming language
> http://haxe.org
>


--
haXe - an open source web programming language
http://haxe.org
Reply | Threaded
Open this post in threaded view
|

Re: Can I convert AS3 to haXe automagically ?

Cauê W.
Hey, just like to mention that I am developing a fully haXe-written as3 parser to rightfully convert them to haXe syntax. It's still in development, but I am trying to make it the most automatic possible, so keep your eyes on the list for the next couple of months!

This said, in the case of the Tweenmax, I guess you would still be better off with haXe's alternatives, as they support some great additions to syntax, such as passing an onComplete function as a parameter, along with the called function's arguments. Do you need to use any functionality not available with the haXe's native classes?

2009/8/9 Blue Sans douze <[hidden email]>
@Heinz : Thanks, but I'm on linux, and I successfully compiled it, but it just doesn't work as well (it produce bugfull hx files).

@Batula : Is there a way to use that method to load a code library, as TweenMax is ? I don't have to include my medias (fonts and bitmap) with that code, it would be painful.

Thanks.


2009/8/9 Baluta Cristian <[hidden email]>:

> i'm using external swfs with fonts and some movieclips, when they are too
> large to embed in the main app. you need something like this to get
> something from there:
> if (e.target.applicationDomain.hasDefinition ( key )) {
> var def = e.target.applicationDomain.getDefinition ( key );
> var C :Class<Dynamic> = cast (def, Class<Dynamic>);trace(C);
> var mc = Type.createInstance (C, []);
> }
> e - is the event of the loaded swf. it works for swfs made from flash, don't
> know about swfmill.
> 2009/8/9 Heinz Hölzer <[hidden email]>
>>
>> I've just compiled a windows version of as3tohaxe.
>>
>> you can get it here:
>>
>> http://rapidshare.com/files/265541217/as3tohaxe.exe.html
>>
>> Blue Sans douze schrieb:
>>>
>>> Hello again !
>>>
>>> After fighting a long with as3tohaxe, I've finally give up.
>>> So, I've tried make a swf lib with TweenMax, which was successful and
>>> works really well.
>>>
>>> There's still a problem : In my haXe project, I'm using some assets
>>> compiled with swfmill (fonts and graphics). When I try to set two
>>> swf-lib, haXe compiler explains me that I can't include two swf-lib,
>>> but doesn't give me an answer.
>>> How can I do to make that work ?
>>>
>>> Thanks.
>>>
>>> --
>>> Blue112
>>> Free frutiparc.
>>>
>>> 2009/8/9 Blue Sans douze <[hidden email]>:
>>>  
>>>>
>>>> Thanks for that fasts answers !
>>>>
>>>> I'll try all of your solutions.
>>>>
>>>> haXe powered.
>>>>
>>>> --
>>>> Blue112.
>>>> Free frutiparc.
>>>>
>>>> 2009/8/9 Nicolas Cannasse <[hidden email]>:
>>>>    
>>>>>
>>>>> Blue Sans douze a écrit :
>>>>>      
>>>>>>
>>>>>> Hello list !
>>>>>>
>>>>>> I was using in as3 a small library called TweenMax, which is really
>>>>>> usefull to make tween using mxmlc. I've seen FEffects for haXe, which
>>>>>> is nice too, but less powerfull (more code for less things). I've
>>>>>> tried to port TweenMax to haXe, and failed, because it's really
>>>>>> painfull : it has many files, and some complex syntax.
>>>>>>
>>>>>> Is there a way I can convert it to haXe or use it in haXe (I've heard
>>>>>> about swc files, but I don't know what they can be usefull to) ?
>>>>>>
>>>>>> Thanks for reading, and sorry for my english.
>>>>>>        
>>>>>
>>>>> There's http://github.com/geekrelief/as3tohaxe/tree/master
>>>>>
>>>>> Nicolas
>>>>>
>>>>> --
>>>>> haXe - an open source web programming language
>>>>> http://haxe.org
>>>>>
>>>>>      
>>>
>>>  
>>
>>
>> --
>> haXe - an open source web programming language
>> http://haxe.org
>
>
>
> --
> Băluță Cristian
> http://ralcr.com
> http://imagin.ro
>
> --
> haXe - an open source web programming language
> http://haxe.org
>


--
haXe - an open source web programming language
http://haxe.org


--
haXe - an open source web programming language
http://haxe.org
Reply | Threaded
Open this post in threaded view
|

Re: Can I convert AS3 to haXe automagically ?

Blue Sans douze
It seems interesting, I'll keep a look on it.

I used to try FEffect, which I dislike and isn't as powerful as TweenMax.

I've just tested TweenerHX, it's actually good, and I'm rewriting my project using it. So the problem is "closed" for me, but it still a problem we can't include more than one swflib in a project.

Thanks for your help !

2009/8/9 Cauê Waneck <[hidden email]>
Hey, just like to mention that I am developing a fully haXe-written as3 parser to rightfully convert them to haXe syntax. It's still in development, but I am trying to make it the most automatic possible, so keep your eyes on the list for the next couple of months!

This said, in the case of the Tweenmax, I guess you would still be better off with haXe's alternatives, as they support some great additions to syntax, such as passing an onComplete function as a parameter, along with the called function's arguments. Do you need to use any functionality not available with the haXe's native classes?


2009/8/9 Blue Sans douze <[hidden email]>
@Heinz : Thanks, but I'm on linux, and I successfully compiled it, but it just doesn't work as well (it produce bugfull hx files).

@Batula : Is there a way to use that method to load a code library, as TweenMax is ? I don't have to include my medias (fonts and bitmap) with that code, it would be painful.

Thanks.


2009/8/9 Baluta Cristian <[hidden email]>:

> i'm using external swfs with fonts and some movieclips, when they are too
> large to embed in the main app. you need something like this to get
> something from there:
> if (e.target.applicationDomain.hasDefinition ( key )) {
> var def = e.target.applicationDomain.getDefinition ( key );
> var C :Class<Dynamic> = cast (def, Class<Dynamic>);trace(C);
> var mc = Type.createInstance (C, []);
> }
> e - is the event of the loaded swf. it works for swfs made from flash, don't
> know about swfmill.
> 2009/8/9 Heinz Hölzer <[hidden email]>
>>
>> I've just compiled a windows version of as3tohaxe.
>>
>> you can get it here:
>>
>> http://rapidshare.com/files/265541217/as3tohaxe.exe.html
>>
>> Blue Sans douze schrieb:
>>>
>>> Hello again !
>>>
>>> After fighting a long with as3tohaxe, I've finally give up.
>>> So, I've tried make a swf lib with TweenMax, which was successful and
>>> works really well.
>>>
>>> There's still a problem : In my haXe project, I'm using some assets
>>> compiled with swfmill (fonts and graphics). When I try to set two
>>> swf-lib, haXe compiler explains me that I can't include two swf-lib,
>>> but doesn't give me an answer.
>>> How can I do to make that work ?
>>>
>>> Thanks.
>>>
>>> --
>>> Blue112
>>> Free frutiparc.
>>>
>>> 2009/8/9 Blue Sans douze <[hidden email]>:
>>>  
>>>>
>>>> Thanks for that fasts answers !
>>>>
>>>> I'll try all of your solutions.
>>>>
>>>> haXe powered.
>>>>
>>>> --
>>>> Blue112.
>>>> Free frutiparc.
>>>>
>>>> 2009/8/9 Nicolas Cannasse <[hidden email]>:
>>>>    
>>>>>
>>>>> Blue Sans douze a écrit :
>>>>>      
>>>>>>
>>>>>> Hello list !
>>>>>>
>>>>>> I was using in as3 a small library called TweenMax, which is really
>>>>>> usefull to make tween using mxmlc. I've seen FEffects for haXe, which
>>>>>> is nice too, but less powerfull (more code for less things). I've
>>>>>> tried to port TweenMax to haXe, and failed, because it's really
>>>>>> painfull : it has many files, and some complex syntax.
>>>>>>
>>>>>> Is there a way I can convert it to haXe or use it in haXe (I've heard
>>>>>> about swc files, but I don't know what they can be usefull to) ?
>>>>>>
>>>>>> Thanks for reading, and sorry for my english.
>>>>>>        
>>>>>
>>>>> There's http://github.com/geekrelief/as3tohaxe/tree/master
>>>>>
>>>>> Nicolas
>>>>>
>>>>> --
>>>>> haXe - an open source web programming language
>>>>> http://haxe.org
>>>>>
>>>>>      
>>>
>>>  
>>
>>
>> --
>> haXe - an open source web programming language
>> http://haxe.org
>
>
>
> --
> Băluță Cristian
> http://ralcr.com
> http://imagin.ro
>
> --
> haXe - an open source web programming language
> http://haxe.org
>


--
haXe - an open source web programming language
http://haxe.org


--
haXe - an open source web programming language
http://haxe.org


--
haXe - an open source web programming language
http://haxe.org