0

I want to translate AS3 code to haxe using AS3HX toolkit, but AS3HX doesn't know how to do that. Whether somebody can tell me how to deal with it?

namespace mx_internal;
using namespace mx_internal;

public myfun():void
{
   mx_internal::setDocumentDescriptor();
}

mx_internal setDocumentDescriptor():void
{
   ...
   ...    
}

private setDocumentDescriptor():void
{
  ...
  ...
}
Peter Zhou
  • 21
  • 3
  • From research AS3 Namespaces are replaced by **Packages** in Haxe. You will have to do a `package mx_internal;` and setup some classes/functions in such a way that your usage of `mx_internal.setDocumentDescriptor()` will access that specific function (not that other local/private `setDocumentDescriptor()`). – VC.One Jan 15 '22 at 02:29
  • **PS**: See if **(1)** [this Question](https://stackoverflow.com/questions/35211755/type-not-found-after-turning-class-into-a-haxelib) (read the text after first code block) has useful info about how they setup their own project. **(2)** This [other link](https://community.haxe.org/t/im-not-sure-about-how-packages-work-in-haxe/) might also help you to understand. – VC.One Jan 15 '22 at 02:30

0 Answers0