{"id":28440304,"url":"https://github.com/haxefoundation/as3hx","last_synced_at":"2026-02-24T18:36:37.967Z","repository":{"id":8633550,"uuid":"10280139","full_name":"HaxeFoundation/as3hx","owner":"HaxeFoundation","description":"Convert AS3 sources to their Haxe equivalent","archived":false,"fork":false,"pushed_at":"2020-11-17T08:00:36.000Z","size":1119,"stargazers_count":176,"open_issues_count":56,"forks_count":54,"subscribers_count":28,"default_branch":"master","last_synced_at":"2025-06-06T03:41:53.116Z","etag":null,"topics":["actionscript","haxe"],"latest_commit_sha":null,"homepage":"","language":"Haxe","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/HaxeFoundation.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGES.md","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-05-25T05:39:53.000Z","updated_at":"2025-06-03T10:20:49.000Z","dependencies_parsed_at":"2022-09-10T03:52:41.721Z","dependency_job_id":null,"html_url":"https://github.com/HaxeFoundation/as3hx","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"purl":"pkg:github/HaxeFoundation/as3hx","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HaxeFoundation%2Fas3hx","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HaxeFoundation%2Fas3hx/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HaxeFoundation%2Fas3hx/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HaxeFoundation%2Fas3hx/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/HaxeFoundation","download_url":"https://codeload.github.com/HaxeFoundation/as3hx/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HaxeFoundation%2Fas3hx/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":262238664,"owners_count":23280175,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["actionscript","haxe"],"created_at":"2025-06-06T03:39:27.048Z","updated_at":"2025-10-28T04:13:40.982Z","avatar_url":"https://github.com/HaxeFoundation.png","language":"Haxe","funding_links":[],"categories":[],"sub_categories":[],"readme":"# as3hx [![Build Status](https://travis-ci.org/HaxeFoundation/as3hx.svg?branch=master)](https://travis-ci.org/HaxeFoundation/as3hx)\nConvert ActionScript 3 to Haxe 3 code.\n\n**Note**: This repository is no longer actively maintained. Please refer to https://github.com/innogames/ax3 as an alternative!\n\n### Build\nYou'll need Haxe 3.* to build the project and Neko 2.* to run it.\n    \n    haxe --no-traces as3hx.hxml\nBuild the as3hx tool.\n\n    haxe -debug as3hx.hxml\nBuild with debug output when converting files.\n\n### Use\n\n    neko run.n test/ out/\n    \nThis will take all the ActionScript 3 files in the test/ directory \nand generate the corresponding Haxe files in out/\n\nTo generate the tests you can also use :\n\n    make run-test\n\nThis will generate the tests in test-out\n\nTo get the basic tool usage :\n\n    neko run.n -help\n\n### Config\n\nThere are many configuration options to choose how the Haxe code\nis generated, check the src/as3hx/Config.hx file for the full list.\n\nas3hx looks for, or creates, a config file in your home directory\ncalled \".as3hx_config.xml\". You can also create one in the directory\nyou are running as3hx from, which will override the home file.\n\n\n#### Licence\n\nMIT, see [LICENCE.md](LICENCE.md)\n\n\n\n### Current failures:\n\n#### 'delete' keyword:\nIn ActionScript, the `delete` keyword will cause an intentional failure in the\ngenerated .hx file. Take a close look at the object being deleted.\n\n1. if it is a local variable, replace `delete varname` with `varname = null`\n2. if it is a class member variable, remove the `delete` entirely\n3. it it is an E4X (FastXML), well, hmmm... still working on that one.\n\nSenocular did a little writeup on `delete` that might make it more clear\nhttp://www.kirupa.com/forum/showthread.php?223798-ActionScript-3-Tip-of-the-Day/page3\n\n\n#### E4X:\nE4X is currently partly done. This will fail in some cases, just examine source\nand output carefully.\n\n#### For Initializations:\nThe output of\n\n```as3\nif (true) {\n    for (var i:uint = 0; i \u003c 7; i++)\n        val += \"0\";\n} else {\n    for (i = 0; i \u003c 8; i++)\n        val += \"0\";\n}\n```\n\nis\n\n```haxe\nif (true) {\n    var i:UInt = 0;\n    while (i \u003c 7) {\n        val += \"0\";\n        i++;\n    }\n} else {\n    i = 0;\n    while (i \u003c 8) {\n        val += \"0\";\n        i++;\n    }\n}\n```\n\nAs you can see, the scope of `i` in Flash is not the same as in Haxe,\nso the `else` section will produce Unknown identifier : i. The solution\nis to move the `var i : UInt = 0;` outside of the blocks in the generated\ncode.\n\nThis can not be avoided by always creating the `i` variable, as the code\n\n```as3\nfor (var i:uint = 0; i \u003c 7; i++)\n    val += \"0\";\nfor (i = 0; i \u003c 8; i++)\n    val += \"0\";\n```\n\nwould then produce a double initialization of `i`, also causing a compiler error.\n\n```haxe\nvar i:UInt = 0;\nwhile (i \u003c 7) {\n    val += \"0\";\n    i++;\n}\nvar i = 0;\nwhile (i \u003c 8) {\n    val += \"0\";\n    i++;\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhaxefoundation%2Fas3hx","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhaxefoundation%2Fas3hx","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhaxefoundation%2Fas3hx/lists"}