• Dear Cerberus X User!

    As we prepare to transition the forum ownership from Mike to Phil (TripleHead GmbH), we need your explicit consent to transfer your user data in accordance with our amended Terms and Rules in order to be compliant with data protection laws.

    Important: If you accept the amended Terms and Rules, you agree to the transfer of your user data to the future forum owner!

    Please read the new Terms and Rules below, check the box to agree, and click "Accept" to continue enjoying your Cerberus X Forum experience. The deadline for consent is April 5, 2024.

    Do not accept the amended Terms and Rules if you do not wish your personal data to be transferred to the future forum owner!

    Accepting ensures:

    - Continued access to your account with a short break for the actual transfer.

    - Retention of your data under the same terms.

    Without consent:

    - You don't have further access to your forum user account.

    - Your account and personal data will be deleted after April 5, 2024.

    - Public posts remain, but usernames indicating real identity will be anonymized. If you disagree with a fictitious name you have the option to contact us so we can find a name that is acceptable to you.

    We hope to keep you in our community and see you on the forum soon!

    All the best

    Your Cerberus X Team

Extending different targets?

Wingnut

Well-known member
3rd Party Module Dev
Tutorial Author
Joined
Jan 2, 2020
Messages
1,414
Is it possible to use any supported language on the different targets? What I mean is, could you use C# as well as C/C++ on Windows? Both Objective C and Swift on macOS & iOS? And Kotlin as well as JAVA on Android?

If not, what stops you from doing it?
 
Well, TransCC can translate your CX code to one target language at the translation process. Javascript, Java, C++ or C#. ActionScript is obsolete.
Then its about the build process to bind/build the translated code with various tools like MSVC, MingW, Android Studio or XCode.

Did I understood that correctly, you want to add multiple languages for native code to a project?
The only thing I see where this could be done is in Xcode, where you could mix C++ and Objective C files. But the other platforms, i dunno?

If not, what stops you from doing it?
I have no need for it and I think it is not possible to a a certain extend.

What is the mindset/motivation behind this question?
 
I will use specific hardware for a few tiny and very simple games. So I'm about to extend CX and it's valuable for me to know beforehand what languages I may use.

I'm adding two pieces of custom hardware (only for macOS and Windows for now, but Android will be the most interesting platform for me to code because it's the hardest one when it comes to adding hardware. So I'm planning to dig right into macOS and shortly after Windows and keeping everyone interested posted.
 
But why the need for building different native languages in one project. Which compiler can do that?
 
A multi-target language gets more bang for the buck by having one target per platform!
 
Well, maybe I'm misunderstanding you. But on each target Cerberus translates code into a specific language that gets compiled along with the native library for that target. There would be little benefit in writing Java libraries for desktop, say. I suppose you could leave out mojo and just compile a main program to transpile Cerberus code, but that would have no special support for any given target.

Do you want to write externs in one language while compiling to a target based on another? Well, as people have said, few compilers support that.
 
Back
Top Bottom